openfree commited on
Commit
4791a6b
·
verified ·
1 Parent(s): 00b4149

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -1
app.py CHANGED
@@ -854,6 +854,7 @@ if not st.session_state.generation_complete:
854
  "preferences": preferences,
855
  "special_requirements": special_requirements
856
  }
 
857
  # 기존의 여행 요청 프롬프트
858
  input_context = f"""Travel Request Details:
859
  Origin: {user_input['origin']}
@@ -947,7 +948,7 @@ Special Requirements: {user_input['special_requirements']}
947
  if 'progress_placeholder' not in st.session_state:
948
  st.session_state.progress_placeholder = st.empty()
949
  with st.session_state.progress_placeholder.container():
950
- display_modern_progress(0)
951
  with logs_tab:
952
  log_container = st.container()
953
  st.session_state.log_messages = []
@@ -1226,6 +1227,12 @@ if st.session_state.generation_complete:
1226
  time_str = chat["time"].strftime("%H:%M:%S")
1227
  st.markdown(f"**{chat['speaker']}** ({time_str}): {chat['message']}")
1228
  st.markdown("</div>", unsafe_allow_html=True)
 
 
 
 
 
 
1229
 
1230
  st.markdown("""
1231
  <div style="margin-top: 50px; text-align: center; padding: 20px; color: #6c757d; font-size: 0.8rem;">
 
854
  "preferences": preferences,
855
  "special_requirements": special_requirements
856
  }
857
+ st.session_state.user_input = user_input # 저장하여 이후 지도에 활용
858
  # 기존의 여행 요청 프롬프트
859
  input_context = f"""Travel Request Details:
860
  Origin: {user_input['origin']}
 
948
  if 'progress_placeholder' not in st.session_state:
949
  st.session_state.progress_placeholder = st.empty()
950
  with st.session_state.progress_placeholder.container():
951
+ display_modern_progress(st.session_state.current_step)
952
  with logs_tab:
953
  log_container = st.container()
954
  st.session_state.log_messages = []
 
1227
  time_str = chat["time"].strftime("%H:%M:%S")
1228
  st.markdown(f"**{chat['speaker']}** ({time_str}): {chat['message']}")
1229
  st.markdown("</div>", unsafe_allow_html=True)
1230
+
1231
+ # Clear 버튼 추가
1232
+ if st.button("Clear", key="clear_button"):
1233
+ st.session_state.chat_history = []
1234
+ st.session_state.chat_input = ""
1235
+ st.experimental_rerun()
1236
 
1237
  st.markdown("""
1238
  <div style="margin-top: 50px; text-align: center; padding: 20px; color: #6c757d; font-size: 0.8rem;">