MilanM commited on
Commit
aeb27b9
·
verified ·
1 Parent(s): eccb854

Update src/streamlit_app.py

Browse files
Files changed (1) hide show
  1. src/streamlit_app.py +5 -1
src/streamlit_app.py CHANGED
@@ -26,7 +26,6 @@ from src.parameters import (
26
  )
27
  from src.helper_functions import (
28
  setup_watsonxai_client,
29
- initialize_session_state,
30
  create_pdf_from_chat,
31
  watsonx_chat_prompt,
32
  generate_response,
@@ -82,6 +81,11 @@ if not check_password():
82
  if "current_page" not in st.session_state:
83
  st.session_state.current_page = 0
84
 
 
 
 
 
 
85
  wx_client = setup_watsonxai_client(
86
  api_key=wx_api_key, project_id=wx_project_id, url=wx_url
87
  )
 
26
  )
27
  from src.helper_functions import (
28
  setup_watsonxai_client,
 
29
  create_pdf_from_chat,
30
  watsonx_chat_prompt,
31
  generate_response,
 
81
  if "current_page" not in st.session_state:
82
  st.session_state.current_page = 0
83
 
84
+
85
+ def initialize_session_state():
86
+ if "chat_history" not in st.session_state:
87
+ st.session_state.chat_history = []
88
+
89
  wx_client = setup_watsonxai_client(
90
  api_key=wx_api_key, project_id=wx_project_id, url=wx_url
91
  )