Mr-Vicky-01 commited on
Commit
f9ad6e4
1 Parent(s): 50a3658

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -42,9 +42,11 @@ def conversational_chat(query):
42
  for i in st.session_state['history']:
43
  if i is not None:
44
  previous_response += f"Human: {i[0]}\n Chatbot: {i[1]}"
 
45
  for j in st.session_state["docs"]:
46
  if j is not None:
47
- provided_docs += j
 
48
  result = llm_chain.predict(chat_history=previous_response, human_input=query, provided_docs=provided_docs)
49
  st.session_state['history'].append((query, result))
50
  return result
 
42
  for i in st.session_state['history']:
43
  if i is not None:
44
  previous_response += f"Human: {i[0]}\n Chatbot: {i[1]}"
45
+ docs = ""
46
  for j in st.session_state["docs"]:
47
  if j is not None:
48
+ docs += j
49
+ provided_docs = docs
50
  result = llm_chain.predict(chat_history=previous_response, human_input=query, provided_docs=provided_docs)
51
  st.session_state['history'].append((query, result))
52
  return result