Update src/streamlit_app.py
Browse files- src/streamlit_app.py +5 -3
src/streamlit_app.py
CHANGED
|
@@ -902,6 +902,7 @@ if st.session_state.visualization_ready and not st.session_state.do_visualize:
|
|
| 902 |
# st.success("๐ All subtasks completed and datasets generated!")
|
| 903 |
# st.success("๐ก Feel free to ask Lily more questions anytime!")
|
| 904 |
|
|
|
|
| 905 |
# ้ถๆฎตไธ๏ผๆฐๆฎๅฏ่งๅ
|
| 906 |
if st.session_state.do_visualize:
|
| 907 |
for i, entry in enumerate(st.session_state.all_dataframes):
|
|
@@ -914,15 +915,16 @@ if st.session_state.do_visualize:
|
|
| 914 |
st.dataframe(df.head(10))
|
| 915 |
chart_code = suggest_charts_with_gpt(df)
|
| 916 |
if chart_code:
|
| 917 |
-
# st.markdown("๐ง The visualization code:")
|
| 918 |
-
# st.code(chart_code, language="python")
|
| 919 |
try:
|
| 920 |
exec(chart_code, {"st": st, "pd": pd, "df": df, "pdk": pdk})
|
| 921 |
except Exception as e:
|
| 922 |
st.error(f"โ Error running chart code: {e}")
|
| 923 |
|
|
|
|
| 924 |
st.success("๐ All subtasks completed and datasets generated!๐ก Feel free to ask me more questions anytime!")
|
| 925 |
-
|
|
|
|
|
|
|
| 926 |
|
| 927 |
if st.session_state.stop_requested:
|
| 928 |
st.info("๐ No problem! You can review the subtasks above or revise your question.")
|
|
|
|
| 902 |
# st.success("๐ All subtasks completed and datasets generated!")
|
| 903 |
# st.success("๐ก Feel free to ask Lily more questions anytime!")
|
| 904 |
|
| 905 |
+
|
| 906 |
# ้ถๆฎตไธ๏ผๆฐๆฎๅฏ่งๅ
|
| 907 |
if st.session_state.do_visualize:
|
| 908 |
for i, entry in enumerate(st.session_state.all_dataframes):
|
|
|
|
| 915 |
st.dataframe(df.head(10))
|
| 916 |
chart_code = suggest_charts_with_gpt(df)
|
| 917 |
if chart_code:
|
|
|
|
|
|
|
| 918 |
try:
|
| 919 |
exec(chart_code, {"st": st, "pd": pd, "df": df, "pdk": pdk})
|
| 920 |
except Exception as e:
|
| 921 |
st.error(f"โ Error running chart code: {e}")
|
| 922 |
|
| 923 |
+
|
| 924 |
st.success("๐ All subtasks completed and datasets generated!๐ก Feel free to ask me more questions anytime!")
|
| 925 |
+
|
| 926 |
+
|
| 927 |
+
|
| 928 |
|
| 929 |
if st.session_state.stop_requested:
|
| 930 |
st.info("๐ No problem! You can review the subtasks above or revise your question.")
|