tyang4 commited on
Commit
3c99bb2
·
verified ·
1 Parent(s): bd88a56

Inject folium when execute chart code

Browse files
Files changed (1) hide show
  1. src/streamlit_app.py +1 -1
src/streamlit_app.py CHANGED
@@ -917,7 +917,7 @@ if st.session_state.do_visualize:
917
  chart_code = suggest_charts_with_gpt(df)
918
  if chart_code:
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
 
 
917
  chart_code = suggest_charts_with_gpt(df)
918
  if chart_code:
919
  try:
920
+ exec(chart_code, {"st": st, "pd": pd, "df": df, "pdk": pdk, "folium": folium, "st_folium": st_folium})
921
  except Exception as e:
922
  st.error(f"❌ Error running chart code: {e}")
923