Spaces:
Paused
Paused
Himanshu Gangwar
commited on
Commit
ยท
2eac5da
1
Parent(s):
c7c4e1d
Remove iframe embedding to fix infinite recursion issue
Browse files- gradio_app.py +21 -13
gradio_app.py
CHANGED
|
@@ -82,21 +82,29 @@ with gr.Blocks(title="InsightPilot - Autonomous Analytics Agent", theme=gr.theme
|
|
| 82 |
""")
|
| 83 |
|
| 84 |
with gr.Tab("๐ Analytics Dashboard"):
|
| 85 |
-
gr.Markdown("""
|
| 86 |
-
### Access the full React dashboard below
|
| 87 |
-
|
| 88 |
-
The dashboard provides:
|
| 89 |
-
- Natural language query interface
|
| 90 |
-
- Real-time SQL generation and execution
|
| 91 |
-
- Interactive visualizations
|
| 92 |
-
- PDF report generation
|
| 93 |
-
- Dataset management and CSV upload
|
| 94 |
-
""")
|
| 95 |
-
|
| 96 |
# Embed the React app if built, otherwise show API info
|
| 97 |
if os.path.exists(FRONTEND_BUILD_DIR):
|
| 98 |
-
gr.
|
| 99 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 100 |
""")
|
| 101 |
else:
|
| 102 |
gr.Markdown("""
|
|
|
|
| 82 |
""")
|
| 83 |
|
| 84 |
with gr.Tab("๐ Analytics Dashboard"):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 85 |
# Embed the React app if built, otherwise show API info
|
| 86 |
if os.path.exists(FRONTEND_BUILD_DIR):
|
| 87 |
+
gr.Markdown("""
|
| 88 |
+
### ๐จ React Dashboard Available!
|
| 89 |
+
|
| 90 |
+
The full React dashboard has been built and is available. However, due to Gradio's architecture,
|
| 91 |
+
we recommend using the **API Access** and **Upload Dataset** tabs below for the best experience on HF Spaces.
|
| 92 |
+
|
| 93 |
+
The React dashboard provides:
|
| 94 |
+
- Natural language query interface
|
| 95 |
+
- Real-time SQL generation and execution
|
| 96 |
+
- Interactive visualizations
|
| 97 |
+
- PDF report generation
|
| 98 |
+
- Dataset management and CSV upload
|
| 99 |
+
|
| 100 |
+
**Note:** For the full React experience, you may want to run this locally or deploy the frontend separately.
|
| 101 |
+
|
| 102 |
+
---
|
| 103 |
+
|
| 104 |
+
### Quick Start - Use the tabs below:
|
| 105 |
+
- **๐ง API Access**: Ask questions and get instant analysis
|
| 106 |
+
- **๐ค Upload Dataset**: Upload your CSV files
|
| 107 |
+
- **โน๏ธ About**: Learn more about InsightPilot
|
| 108 |
""")
|
| 109 |
else:
|
| 110 |
gr.Markdown("""
|