Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -249,14 +249,14 @@ with st.sidebar:
|
|
| 249 |
st.session_state.logs = []
|
| 250 |
st.session_state.current_step = None
|
| 251 |
st.session_state.alert_submitted = False
|
| 252 |
-
st.
|
| 253 |
|
| 254 |
# Only show main app if environment and agents are ready
|
| 255 |
if not (st.session_state.environment_ready and st.session_state.agents_loaded):
|
| 256 |
st.info("Setting up environment and initializing agents. Please wait...")
|
| 257 |
st.stop()
|
| 258 |
|
| 259 |
-
# Main screen
|
| 260 |
if st.session_state.workflow_state is None:
|
| 261 |
# Alert input section
|
| 262 |
st.header("📱 Incoming Alert")
|
|
@@ -317,7 +317,7 @@ if st.session_state.workflow_state is None:
|
|
| 317 |
|
| 318 |
# Force page refresh
|
| 319 |
time.sleep(1)
|
| 320 |
-
st.
|
| 321 |
|
| 322 |
with col2:
|
| 323 |
st.image("https://img.icons8.com/fluency/240/000000/notification-center.png", width=150)
|
|
@@ -374,7 +374,7 @@ else:
|
|
| 374 |
st.session_state.logs = []
|
| 375 |
st.session_state.current_step = None
|
| 376 |
st.session_state.alert_submitted = False
|
| 377 |
-
st.
|
| 378 |
|
| 379 |
elif workflow_state["status"] != "complete":
|
| 380 |
# Show progress
|
|
@@ -626,7 +626,7 @@ else:
|
|
| 626 |
|
| 627 |
# Auto refresh
|
| 628 |
time.sleep(0.5)
|
| 629 |
-
st.
|
| 630 |
|
| 631 |
else:
|
| 632 |
# Show completed analysis
|
|
@@ -761,8 +761,7 @@ else:
|
|
| 761 |
# Create a generic chart
|
| 762 |
st.image("https://img.icons8.com/fluency/240/000000/graph.png", width=100)
|
| 763 |
st.markdown(f"*{chart_name}*")
|
| 764 |
-
|
| 765 |
-
# Display key findings
|
| 766 |
if card.key_findings:
|
| 767 |
st.markdown("#### Key Findings")
|
| 768 |
for i, finding in enumerate(card.key_findings):
|
|
@@ -853,4 +852,5 @@ else:
|
|
| 853 |
|
| 854 |
# Run the app
|
| 855 |
if __name__ == "__main__":
|
|
|
|
| 856 |
pass
|
|
|
|
| 249 |
st.session_state.logs = []
|
| 250 |
st.session_state.current_step = None
|
| 251 |
st.session_state.alert_submitted = False
|
| 252 |
+
st.rerun()
|
| 253 |
|
| 254 |
# Only show main app if environment and agents are ready
|
| 255 |
if not (st.session_state.environment_ready and st.session_state.agents_loaded):
|
| 256 |
st.info("Setting up environment and initializing agents. Please wait...")
|
| 257 |
st.stop()
|
| 258 |
|
| 259 |
+
# Main screen
|
| 260 |
if st.session_state.workflow_state is None:
|
| 261 |
# Alert input section
|
| 262 |
st.header("📱 Incoming Alert")
|
|
|
|
| 317 |
|
| 318 |
# Force page refresh
|
| 319 |
time.sleep(1)
|
| 320 |
+
st.rerun()
|
| 321 |
|
| 322 |
with col2:
|
| 323 |
st.image("https://img.icons8.com/fluency/240/000000/notification-center.png", width=150)
|
|
|
|
| 374 |
st.session_state.logs = []
|
| 375 |
st.session_state.current_step = None
|
| 376 |
st.session_state.alert_submitted = False
|
| 377 |
+
st.rerun()
|
| 378 |
|
| 379 |
elif workflow_state["status"] != "complete":
|
| 380 |
# Show progress
|
|
|
|
| 626 |
|
| 627 |
# Auto refresh
|
| 628 |
time.sleep(0.5)
|
| 629 |
+
st.rerun()
|
| 630 |
|
| 631 |
else:
|
| 632 |
# Show completed analysis
|
|
|
|
| 761 |
# Create a generic chart
|
| 762 |
st.image("https://img.icons8.com/fluency/240/000000/graph.png", width=100)
|
| 763 |
st.markdown(f"*{chart_name}*")
|
| 764 |
+
# Display key findings
|
|
|
|
| 765 |
if card.key_findings:
|
| 766 |
st.markdown("#### Key Findings")
|
| 767 |
for i, finding in enumerate(card.key_findings):
|
|
|
|
| 852 |
|
| 853 |
# Run the app
|
| 854 |
if __name__ == "__main__":
|
| 855 |
+
# This will be executed when running directly with 'streamlit run app.py'
|
| 856 |
pass
|