Spaces:
Running
Running
Create agentic_report_tab.py
Browse files- ui/agentic_report_tab.py +22 -0
ui/agentic_report_tab.py
ADDED
@@ -0,0 +1,22 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# ui/agentic_report_tab.py
|
2 |
+
import gradio as gr
|
3 |
+
|
4 |
+
def setup_agentic_report_tab(agentic_modules_loaded_flag):
|
5 |
+
"""Sets up the UI components for the Agentic Analysis Report tab."""
|
6 |
+
if not agentic_modules_loaded_flag:
|
7 |
+
gr.Markdown("🔴 **Error:** Agentic pipeline modules could not be loaded. This tab's functionality is disabled.")
|
8 |
+
return { # Return minimal components if not loaded
|
9 |
+
"agentic_pipeline_status_md": None,
|
10 |
+
"agentic_report_display_md": None,
|
11 |
+
}
|
12 |
+
|
13 |
+
gr.Markdown("## 🤖 Comprehensive Analysis Report (AI Generated)")
|
14 |
+
agentic_pipeline_status_md = gr.Markdown("Stato Pipeline AI (filtro 'Sempre'): In attesa...", visible=True)
|
15 |
+
gr.Markdown("Questo report è generato da un agente AI con filtro 'Sempre' sui dati disponibili. Rivedi criticamente.")
|
16 |
+
agentic_report_display_md = gr.Markdown("La pipeline AI si avvierà automaticamente dopo il caricamento iniziale dei dati o dopo una sincronizzazione.")
|
17 |
+
|
18 |
+
components = {
|
19 |
+
"agentic_pipeline_status_md": agentic_pipeline_status_md,
|
20 |
+
"agentic_report_display_md": agentic_report_display_md,
|
21 |
+
}
|
22 |
+
return components
|