mahika123 commited on
Commit
2af7225
Β·
verified Β·
1 Parent(s): b91a459
Files changed (1) hide show
  1. app.py +318 -21
app.py CHANGED
@@ -85,16 +85,25 @@ def show_info(topic):
85
  }
86
  return responses.get(topic, "Select a category to see the corresponding careers.")
87
 
88
- # Resources Page Info
89
  def resource_block(career):
90
  resources = {
91
  "AI/Machine Learning Engineer": {
92
  "links": [
93
  ("Neural Networks – DeepLearning.AI", "https://www.deeplearning.ai"),
94
  ("Build ML Models – Fast.ai", "https://www.fast.ai"),
95
- ("ML Theory – Stanford CS229", "https://cs229.stanford.edu/")
96
  ],
97
- "video": "https://www.youtube.com/embed/5NgNicANyqM"
 
 
 
 
 
 
 
 
 
98
  },
99
  "Data Scientist": {
100
  "links": [
@@ -102,31 +111,67 @@ def resource_block(career):
102
  ("R Programming – Harvard Data Science", "https://online-learning.harvard.edu/series/data-science"),
103
  ("Project Practice – DataCamp", "https://www.datacamp.com")
104
  ],
105
- "video": "https://www.youtube.com/embed/xC-c7E5PK0Y"
 
 
 
 
 
 
 
 
 
106
  },
107
  "Cloud Solutions Architect": {
108
  "links": [
109
  ("AWS Skills – AWS Training", "https://aws.amazon.com/training/"),
110
- ("Azure Certs – Microsoft Learn", "https://learn.microsoft.com/en-us/certifications/"),
111
- ("GCP Labs – Google Cloud Boost", "https://cloudskillsboost.google/")
112
  ],
113
- "video": "https://www.youtube.com/embed/Y1OVgGIGvfc"
 
 
 
 
 
 
 
 
 
114
  },
115
  "Cybersecurity Analyst": {
116
  "links": [
117
  ("Network Security – Cybrary", "https://www.cybrary.it"),
118
- ("Threat Intel – MITRE ATT&CK", "https://attack.mitre.org/"),
119
  ("Ethical Hacking – TryHackMe", "https://tryhackme.com")
120
  ],
121
- "video": "https://www.youtube.com/embed/9fWjKkFvQxg"
 
 
 
 
 
 
 
 
 
122
  },
123
- "Statisticians": {
124
  "links": [
125
- ("Intro to Stats – Coursera (R)", "https://www.coursera.org/specializations/statistics"),
126
  ("Probability – Khan Academy", "https://www.khanacademy.org/math/statistics-probability"),
127
  ("Statistical Tools – OpenIntro", "https://www.openintro.org/book/os/")
128
  ],
129
- "video": "https://www.youtube.com/embed/xxpc-HPKN28"
 
 
 
 
 
 
 
 
 
130
  },
131
  "Biomedical Engineer": {
132
  "links": [
@@ -134,7 +179,237 @@ def resource_block(career):
134
  ("Medical Devices – edX Courses", "https://www.edx.org/learn/biomedical-engineering"),
135
  ("Clinical Trials – NIH", "https://www.nih.gov/")
136
  ],
137
- "video": "https://www.youtube.com/embed/NM5EekDaF3g"
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
138
  }
139
  }
140
 
@@ -147,13 +422,21 @@ def resource_block(career):
147
  link_html += f'<li><strong>{label}</strong>: <a href="{url}" target="_blank">{url}</a></li>'
148
  link_html += "</ul>"
149
 
150
- video_iframe = (
151
- f'<iframe width="560" height="315" src="{content["video"]}" '
152
- 'title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; '
153
- 'clipboard-write; encrypted-media; gyroscope; picture-in-picture; web-share" allowfullscreen></iframe>'
154
- )
 
 
 
 
 
 
 
155
 
156
- return link_html, video_iframe
 
157
 
158
  # UI Layout
159
  with gr.Blocks(theme=theme, css=custom_css) as chatbot:
@@ -194,8 +477,21 @@ with gr.Blocks(theme=theme, css=custom_css) as chatbot:
194
  "Data Scientist",
195
  "Cloud Solutions Architect",
196
  "Cybersecurity Analyst",
197
- "Statisticians",
198
- "Biomedical Engineer"
 
 
 
 
 
 
 
 
 
 
 
 
 
199
  ],
200
  label="Choose a Career"
201
  )
@@ -209,3 +505,4 @@ with gr.Blocks(theme=theme, css=custom_css) as chatbot:
209
 
210
  chatbot.launch()
211
 
 
 
85
  }
86
  return responses.get(topic, "Select a category to see the corresponding careers.")
87
 
88
+ # Resources Page Info - UPDATED
89
  def resource_block(career):
90
  resources = {
91
  "AI/Machine Learning Engineer": {
92
  "links": [
93
  ("Neural Networks – DeepLearning.AI", "https://www.deeplearning.ai"),
94
  ("Build ML Models – Fast.ai", "https://www.fast.ai"),
95
+ ("Machine Learning – Stanford CS229", "https://cs229.stanford.edu/")
96
  ],
97
+ "college": {
98
+ "major": "Computer Science, Data Science",
99
+ "classes": [
100
+ "CS50: Introduction to Computer Science (Harvard)",
101
+ "Linear Algebra",
102
+ "Probability and Statistics",
103
+ "Machine Learning (Stanford CS229)",
104
+ "Algorithms"
105
+ ]
106
+ }
107
  },
108
  "Data Scientist": {
109
  "links": [
 
111
  ("R Programming – Harvard Data Science", "https://online-learning.harvard.edu/series/data-science"),
112
  ("Project Practice – DataCamp", "https://www.datacamp.com")
113
  ],
114
+ "college": {
115
+ "major": "Data Science, Statistics, Computer Science",
116
+ "classes": [
117
+ "Introduction to Data Science",
118
+ "Statistics and Probability",
119
+ "Data Mining",
120
+ "Machine Learning",
121
+ "Database Systems"
122
+ ]
123
+ }
124
  },
125
  "Cloud Solutions Architect": {
126
  "links": [
127
  ("AWS Skills – AWS Training", "https://aws.amazon.com/training/"),
128
+ ("Azure Certifications – Microsoft Learn", "https://learn.microsoft.com/en-us/certifications/"),
129
+ ("Google Cloud Labs – Google Cloud Boost", "https://cloudskillsboost.google/")
130
  ],
131
+ "college": {
132
+ "major": "Computer Science, Information Technology",
133
+ "classes": [
134
+ "Cloud Computing Fundamentals",
135
+ "Computer Networks",
136
+ "Systems Design",
137
+ "Information Security",
138
+ "Operating Systems"
139
+ ]
140
+ }
141
  },
142
  "Cybersecurity Analyst": {
143
  "links": [
144
  ("Network Security – Cybrary", "https://www.cybrary.it"),
145
+ ("Threat Intelligence – MITRE ATT&CK", "https://attack.mitre.org/"),
146
  ("Ethical Hacking – TryHackMe", "https://tryhackme.com")
147
  ],
148
+ "college": {
149
+ "major": "Cybersecurity, Computer Science, Information Security",
150
+ "classes": [
151
+ "Network Security",
152
+ "Cryptography",
153
+ "Ethical Hacking",
154
+ "Operating Systems",
155
+ "Incident Response"
156
+ ]
157
+ }
158
  },
159
+ "Statistician": {
160
  "links": [
161
+ ("Intro to Statistics – Coursera (R)", "https://www.coursera.org/specializations/statistics"),
162
  ("Probability – Khan Academy", "https://www.khanacademy.org/math/statistics-probability"),
163
  ("Statistical Tools – OpenIntro", "https://www.openintro.org/book/os/")
164
  ],
165
+ "college": {
166
+ "major": "Statistics, Mathematics",
167
+ "classes": [
168
+ "Probability Theory",
169
+ "Statistical Inference",
170
+ "Regression Analysis",
171
+ "Experimental Design",
172
+ "Data Analysis with R"
173
+ ]
174
+ }
175
  },
176
  "Biomedical Engineer": {
177
  "links": [
 
179
  ("Medical Devices – edX Courses", "https://www.edx.org/learn/biomedical-engineering"),
180
  ("Clinical Trials – NIH", "https://www.nih.gov/")
181
  ],
182
+ "college": {
183
+ "major": "Biomedical Engineering, Bioengineering",
184
+ "classes": [
185
+ "Biomaterials",
186
+ "Human Physiology",
187
+ "Medical Instrumentation",
188
+ "Biomechanics",
189
+ "Tissue Engineering"
190
+ ]
191
+ }
192
+ },
193
+ "Mechanical Engineer": {
194
+ "links": [
195
+ ("CAD Design – Coursera", "https://www.coursera.org/learn/cad-design"),
196
+ ("Thermodynamics – MIT OpenCourseWare", "https://ocw.mit.edu/courses/thermodynamics"),
197
+ ("Materials Science Basics – edX", "https://www.edx.org/course/material-science")
198
+ ],
199
+ "college": {
200
+ "major": "Mechanical Engineering",
201
+ "classes": [
202
+ "Thermodynamics",
203
+ "Fluid Mechanics",
204
+ "Materials Science",
205
+ "Computer-Aided Design (CAD)",
206
+ "Dynamics and Control"
207
+ ]
208
+ }
209
+ },
210
+ "Environmental Scientist": {
211
+ "links": [
212
+ ("Environmental Science – Khan Academy", "https://www.khanacademy.org/science/biology/ecology"),
213
+ ("GIS Basics – Esri Training", "https://www.esri.com/training/catalog/57630435851d31e02a43f1c5/gis-basics/"),
214
+ ("Data Analysis – Coursera", "https://www.coursera.org/learn/data-analysis")
215
+ ],
216
+ "college": {
217
+ "major": "Environmental Science, Ecology",
218
+ "classes": [
219
+ "Ecology",
220
+ "Environmental Chemistry",
221
+ "Geographic Information Systems (GIS)",
222
+ "Data Analysis",
223
+ "Environmental Policy"
224
+ ]
225
+ }
226
+ },
227
+ "Operations Research Analyst": {
228
+ "links": [
229
+ ("Linear Programming – Khan Academy", "https://www.khanacademy.org/computing/computer-science/algorithms"),
230
+ ("Optimization – MIT OpenCourseWare", "https://ocw.mit.edu/courses/optimization-methods"),
231
+ ("Statistics – Harvard Online", "https://online-learning.harvard.edu/course/statistics-and-r")
232
+ ],
233
+ "college": {
234
+ "major": "Operations Research, Applied Mathematics",
235
+ "classes": [
236
+ "Optimization Theory",
237
+ "Linear Programming",
238
+ "Probability",
239
+ "Statistics",
240
+ "Simulation Modeling"
241
+ ]
242
+ }
243
+ },
244
+ "Mathematician": {
245
+ "links": [
246
+ ("Abstract Algebra – MIT OpenCourseWare", "https://ocw.mit.edu/courses/abstract-algebra"),
247
+ ("Calculus – Khan Academy", "https://www.khanacademy.org/math/calculus-1"),
248
+ ("Proof Techniques – Coursera", "https://www.coursera.org/learn/proofs")
249
+ ],
250
+ "college": {
251
+ "major": "Mathematics",
252
+ "classes": [
253
+ "Algebra",
254
+ "Calculus",
255
+ "Real Analysis",
256
+ "Abstract Algebra",
257
+ "Proof Writing"
258
+ ]
259
+ }
260
+ },
261
+ "Chemical Engineer": {
262
+ "links": [
263
+ ("Chemical Process Principles – MIT OCW", "https://ocw.mit.edu/courses/chemical-engineering"),
264
+ ("Organic Chemistry – Khan Academy", "https://www.khanacademy.org/science/organic-chemistry"),
265
+ ("Thermodynamics – Coursera", "https://www.coursera.org/learn/thermodynamics")
266
+ ],
267
+ "college": {
268
+ "major": "Chemical Engineering",
269
+ "classes": [
270
+ "Organic Chemistry",
271
+ "Thermodynamics",
272
+ "Process Design",
273
+ "Fluid Mechanics",
274
+ "Chemical Reaction Engineering"
275
+ ]
276
+ }
277
+ },
278
+ "Civil Engineer": {
279
+ "links": [
280
+ ("Structural Analysis – Coursera", "https://www.coursera.org/learn/structural-analysis"),
281
+ ("Construction Management – edX", "https://www.edx.org/course/construction-management"),
282
+ ("AutoCAD – LinkedIn Learning", "https://www.linkedin.com/learning/topics/autocad")
283
+ ],
284
+ "college": {
285
+ "major": "Civil Engineering",
286
+ "classes": [
287
+ "Structural Analysis",
288
+ "Construction Materials",
289
+ "Soil Mechanics",
290
+ "AutoCAD",
291
+ "Hydraulics"
292
+ ]
293
+ }
294
+ },
295
+ "Electrical Engineer": {
296
+ "links": [
297
+ ("Circuits and Electronics – MIT OCW", "https://ocw.mit.edu/courses/electrical-engineering-and-computer-science"),
298
+ ("Signals and Systems – Coursera", "https://www.coursera.org/learn/signals-systems"),
299
+ ("Electromagnetics – Khan Academy", "https://www.khanacademy.org/science/electrical-engineering")
300
+ ],
301
+ "college": {
302
+ "major": "Electrical Engineering",
303
+ "classes": [
304
+ "Circuits",
305
+ "Signals and Systems",
306
+ "Electromagnetics",
307
+ "Control Systems",
308
+ "Digital Logic Design"
309
+ ]
310
+ }
311
+ },
312
+ "Software Developer": {
313
+ "links": [
314
+ ("CS50 – Harvard", "https://cs50.harvard.edu"),
315
+ ("Learn to Code – Codecademy", "https://www.codecademy.com/catalog/subject/all"),
316
+ ("Algorithms – Coursera", "https://www.coursera.org/learn/algorithms-part1")
317
+ ],
318
+ "college": {
319
+ "major": "Computer Science, Software Engineering",
320
+ "classes": [
321
+ "Introduction to Computer Science (CS50)",
322
+ "Data Structures and Algorithms",
323
+ "Operating Systems",
324
+ "Software Engineering",
325
+ "Databases"
326
+ ]
327
+ }
328
+ },
329
+ "Pharmacist": {
330
+ "links": [
331
+ ("Pharmacology Basics – Coursera", "https://www.coursera.org/learn/pharmacology"),
332
+ ("Drug Development – edX", "https://www.edx.org/course/drug-development"),
333
+ ("Pharmacy Practice – FutureLearn", "https://www.futurelearn.com/courses/pharmacy-practice")
334
+ ],
335
+ "college": {
336
+ "major": "Pharmacy, Pharmaceutical Sciences",
337
+ "classes": [
338
+ "Pharmacology",
339
+ "Medicinal Chemistry",
340
+ "Pharmaceutical Calculations",
341
+ "Pharmaceutics",
342
+ "Clinical Pharmacy"
343
+ ]
344
+ }
345
+ },
346
+ "Physicist": {
347
+ "links": [
348
+ ("Classical Mechanics – MIT OCW", "https://ocw.mit.edu/courses/physics"),
349
+ ("Quantum Mechanics – edX", "https://www.edx.org/course/quantum-mechanics"),
350
+ ("Thermodynamics – Khan Academy", "https://www.khanacademy.org/science/physics/thermodynamics")
351
+ ],
352
+ "college": {
353
+ "major": "Physics",
354
+ "classes": [
355
+ "Classical Mechanics",
356
+ "Quantum Mechanics",
357
+ "Thermodynamics",
358
+ "Electromagnetism",
359
+ "Mathematical Methods for Physicists"
360
+ ]
361
+ }
362
+ },
363
+ "Astronomer": {
364
+ "links": [
365
+ ("Introduction to Astronomy – Coursera", "https://www.coursera.org/learn/astronomy"),
366
+ ("Astrophysics – edX", "https://www.edx.org/course/astrophysics"),
367
+ ("Cosmology – Khan Academy", "https://www.khanacademy.org/science/cosmology-and-astronomy")
368
+ ],
369
+ "college": {
370
+ "major": "Astronomy, Astrophysics, Physics",
371
+ "classes": [
372
+ "Introduction to Astronomy",
373
+ "Astrophysics",
374
+ "Cosmology",
375
+ "Observational Astronomy",
376
+ "Data Analysis in Astronomy"
377
+ ]
378
+ }
379
+ },
380
+ "Geologist": {
381
+ "links": [
382
+ ("Physical Geology – OpenStax", "https://openstax.org/details/books/physical-geology"),
383
+ ("Geochemistry – Coursera", "https://www.coursera.org/learn/geochemistry"),
384
+ ("GIS Mapping – Esri Training", "https://www.esri.com/training/catalog/57630435851d31e02a43f1c5/gis-basics/")
385
+ ],
386
+ "college": {
387
+ "major": "Geology, Earth Science",
388
+ "classes": [
389
+ "Physical Geology",
390
+ "Mineralogy and Petrology",
391
+ "Geochemistry",
392
+ "GIS and Remote Sensing",
393
+ "Structural Geology"
394
+ ]
395
+ }
396
+ },
397
+ "Biochemist": {
398
+ "links": [
399
+ ("Biochemistry – MIT OCW", "https://ocw.mit.edu/courses/biochemistry"),
400
+ ("Molecular Biology – Coursera", "https://www.coursera.org/learn/molecular-biology"),
401
+ ("Enzymology – Khan Academy", "https://www.khanacademy.org/science/biology")
402
+ ],
403
+ "college": {
404
+ "major": "Biochemistry, Molecular Biology",
405
+ "classes": [
406
+ "General Biochemistry",
407
+ "Molecular Biology",
408
+ "Enzymology",
409
+ "Cell Biology",
410
+ "Genetics"
411
+ ]
412
+ }
413
  }
414
  }
415
 
 
422
  link_html += f'<li><strong>{label}</strong>: <a href="{url}" target="_blank">{url}</a></li>'
423
  link_html += "</ul>"
424
 
425
+ college_html = ""
426
+ if "college" in content:
427
+ college = content["college"]
428
+ college_html += "<p><strong>College & Classes</strong></p><ul>"
429
+ college_html += f"<li><em>Common Major(s):</em> {college['major']}</li>"
430
+ classes_list = college.get("classes", [])
431
+ if isinstance(classes_list, list):
432
+ classes_html = ", ".join(classes_list)
433
+ else:
434
+ classes_html = str(classes_list)
435
+ college_html += f"<li><em>Helpful College Classes:</em> {classes_html}</li>"
436
+ college_html += "</ul>"
437
 
438
+ # No video iframe, just empty string for second output
439
+ return link_html + college_html, ""
440
 
441
  # UI Layout
442
  with gr.Blocks(theme=theme, css=custom_css) as chatbot:
 
477
  "Data Scientist",
478
  "Cloud Solutions Architect",
479
  "Cybersecurity Analyst",
480
+ "Statistician",
481
+ "Biomedical Engineer",
482
+ "Mechanical Engineer",
483
+ "Environmental Scientist",
484
+ "Operations Research Analyst",
485
+ "Mathematician",
486
+ "Chemical Engineer",
487
+ "Civil Engineer",
488
+ "Electrical Engineer",
489
+ "Software Developer",
490
+ "Pharmacist",
491
+ "Physicist",
492
+ "Astronomer",
493
+ "Geologist",
494
+ "Biochemist"
495
  ],
496
  label="Choose a Career"
497
  )
 
505
 
506
  chatbot.launch()
507
 
508
+