Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -131,9 +131,23 @@ def respond(message, history):
|
|
| 131 |
|
| 132 |
def display_image():
|
| 133 |
return "KWKbanner.png"
|
| 134 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 135 |
with gr.Blocks(theme=theme, css=custom_css) as chatbot:
|
| 136 |
gr.Image(display_image)
|
|
|
|
|
|
|
|
|
|
| 137 |
with gr.Tabs():
|
| 138 |
with gr.Tab("ChatBot"):
|
| 139 |
gr.ChatInterface(
|
|
@@ -146,6 +160,17 @@ with gr.Blocks(theme=theme, css=custom_css) as chatbot:
|
|
| 146 |
with gr.Tab("Explore Page"):
|
| 147 |
gr.Markdown("")
|
| 148 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 149 |
|
| 150 |
|
| 151 |
|
|
|
|
| 131 |
|
| 132 |
def display_image():
|
| 133 |
return "KWKbanner.png"
|
| 134 |
+
|
| 135 |
+
def show_info(topic):
|
| 136 |
+
responses = {
|
| 137 |
+
"Highest Paying STEM Jobs": "1. AI/Machine Learning Engineer – $171,774 \n 2. Cloud Solutions Architect – $150,241 \n 3. Quantitative Analyst (Quant) – $139,949 \n 4. Data Scientist – $128,115 \n 5. Actuary – $128,147",
|
| 138 |
+
"Most Flexible STEM Jobs": "1. Software Developer \n 2. Cloud Solutions Architect \n 3. Data Scientist \n 4. Cybersecurity Analyst \n 5. Statistician",
|
| 139 |
+
"Most Creative STEM Jobs": "1. Software Developer \n 2. AI/Machine Learning Engineer \n 3. Biomedical Engineer \n 4, Mechanical Engineer \n 5. Biochemist",
|
| 140 |
+
"Fastest Growing STEM Jobs": "1. AI/Machine Learning Engineer \n 2. Cybersecurity Analyst \n 3. Data Scientist \n 4. Software Developer \n 5. Cloud Solutions Architect",
|
| 141 |
+
"Low-Stress STEM Jobs": "1. Statistician \n 2. Mathematician \n 3. Operations Research Analyst \n 4. Environmental Scientist \n 5. Biochemist"
|
| 142 |
+
}
|
| 143 |
+
return responses.get(topic, "Select a category to see the corresponding careers.")
|
| 144 |
+
|
| 145 |
+
|
| 146 |
with gr.Blocks(theme=theme, css=custom_css) as chatbot:
|
| 147 |
gr.Image(display_image)
|
| 148 |
+
|
| 149 |
+
explore_page= "Select a cateogry to see the corresponding careers."
|
| 150 |
+
|
| 151 |
with gr.Tabs():
|
| 152 |
with gr.Tab("ChatBot"):
|
| 153 |
gr.ChatInterface(
|
|
|
|
| 160 |
with gr.Tab("Explore Page"):
|
| 161 |
gr.Markdown("")
|
| 162 |
|
| 163 |
+
with gr.TabItem("Explore Page"):
|
| 164 |
+
gr.Markdown(explore_page)
|
| 165 |
+
#gr.Markdown(explore_page)
|
| 166 |
+
dropdown = gr.Dropdown(choices=["Highest Paying STEM Jobs", "Most Flexible STEM Jobs", "Most Creative STEM Jobs", "Fastest Growing STEM Jobs", "Low-Stress STEM Jobs"],
|
| 167 |
+
label="Choose Your Category"
|
| 168 |
+
)
|
| 169 |
+
output = gr.Textbox(label="Top-Ranked Jobs", interactive=False)
|
| 170 |
+
|
| 171 |
+
dropdown.change(fn=show_info, inputs=dropdown, outputs=output)
|
| 172 |
+
#with gr.Tab("Educational PDFs"):
|
| 173 |
+
# gr.Markdown("### 📘 Helpful Resources")
|
| 174 |
|
| 175 |
|
| 176 |
|