CCockrum commited on
Commit
3af8ac2
Β·
verified Β·
1 Parent(s): b54b055

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -5
app.py CHANGED
@@ -21,6 +21,8 @@ if NASA_API_KEY is None:
21
  # βœ… Set Up Streamlit
22
  st.set_page_config(page_title="HAL - NASA ChatBot", page_icon="πŸš€")
23
 
 
 
24
  # βœ… Ensure Session State Variables
25
  if "chat_history" not in st.session_state:
26
  st.session_state.chat_history = [{"role": "assistant", "content": "Hello! How can I assist you today?"}]
@@ -207,11 +209,6 @@ if st.sidebar.button("Reset Chat"):
207
  st.session_state.response_ready = False
208
  st.session_state.follow_up = ""
209
 
210
- user_input = st.chat_input("Type your message here...") # Make sure this is executed first
211
-
212
-
213
- # βœ… Chat UI
214
- user_input = st.chat_input("Type your message here...")
215
 
216
  if user_input:
217
  # βœ… Ensure get_response() returns a response
 
21
  # βœ… Set Up Streamlit
22
  st.set_page_config(page_title="HAL - NASA ChatBot", page_icon="πŸš€")
23
 
24
+ user_input = st.chat_input("Type your message here...") # Make sure this is executed first
25
+
26
  # βœ… Ensure Session State Variables
27
  if "chat_history" not in st.session_state:
28
  st.session_state.chat_history = [{"role": "assistant", "content": "Hello! How can I assist you today?"}]
 
209
  st.session_state.response_ready = False
210
  st.session_state.follow_up = ""
211
 
 
 
 
 
 
212
 
213
  if user_input:
214
  # βœ… Ensure get_response() returns a response