Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -478,7 +478,7 @@ class BotanistAssistant:
|
|
| 478 |
timeout=30 # 30-second timeout
|
| 479 |
)
|
| 480 |
response.raise_for_status()
|
| 481 |
-
return response.json()
|
| 482 |
except requests.exceptions.RequestException as e:
|
| 483 |
print(f"API request failed: {str(e)}")
|
| 484 |
return {"error": str(e)}
|
|
@@ -533,8 +533,8 @@ def create_app(api_endpoint: str) -> gr.Blocks:
|
|
| 533 |
assistant = BotanistAssistant(api_endpoint)
|
| 534 |
|
| 535 |
with gr.Blocks(title="Botanist Assistant", theme=gr.themes.Soft()) as demo:
|
| 536 |
-
gr.Markdown("# 🌿
|
| 537 |
-
gr.Markdown("Describe your symptoms to get plant-based treatment recommendations")
|
| 538 |
|
| 539 |
with gr.Row():
|
| 540 |
with gr.Column(scale=3):
|
|
@@ -561,7 +561,8 @@ def create_app(api_endpoint: str) -> gr.Blocks:
|
|
| 561 |
)
|
| 562 |
|
| 563 |
gr.Markdown("---")
|
| 564 |
-
gr.Markdown("> Note: Recommendations
|
|
|
|
| 565 |
|
| 566 |
return demo
|
| 567 |
|
|
|
|
| 478 |
timeout=30 # 30-second timeout
|
| 479 |
)
|
| 480 |
response.raise_for_status()
|
| 481 |
+
return response.json().split("**Sponsor**")[0].split("Sponsor")[0]
|
| 482 |
except requests.exceptions.RequestException as e:
|
| 483 |
print(f"API request failed: {str(e)}")
|
| 484 |
return {"error": str(e)}
|
|
|
|
| 533 |
assistant = BotanistAssistant(api_endpoint)
|
| 534 |
|
| 535 |
with gr.Blocks(title="Botanist Assistant", theme=gr.themes.Soft()) as demo:
|
| 536 |
+
gr.Markdown("# 🌿 Natural Medical Assistant")
|
| 537 |
+
gr.Markdown("Describe your symptoms to get natural plant-based treatment recommendations")
|
| 538 |
|
| 539 |
with gr.Row():
|
| 540 |
with gr.Column(scale=3):
|
|
|
|
| 561 |
)
|
| 562 |
|
| 563 |
gr.Markdown("---")
|
| 564 |
+
gr.Markdown("> Note: Recommendations can work as real cure treatment but you can consider it as informational purposes only.")
|
| 565 |
+
gr.Markdown("> Also You can consult a Natrual healthcare professional before use.")
|
| 566 |
|
| 567 |
return demo
|
| 568 |
|