Anne31415 commited on
Commit
6052a4d
·
verified ·
1 Parent(s): 59e080f

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -243,7 +243,7 @@ def page1():
243
 
244
  with st.spinner('Bot is thinking...'):
245
  chain = load_chatbot()
246
- docs = VectorStore.similarity_search(query=query, k=3)
247
  with get_openai_callback() as cb:
248
  response = chain.run(input_documents=docs, question=query)
249
  response = handle_no_answer(response) # Process the response through the new function
@@ -356,7 +356,7 @@ def page2():
356
 
357
  with st.spinner('Bot is thinking...'):
358
  chain = load_chatbot()
359
- docs = VectorStore.similarity_search(query=query, k=3)
360
  with get_openai_callback() as cb:
361
  response = chain.run(input_documents=docs, question=query)
362
  response = handle_no_answer(response) # Process the response through the new function
@@ -468,7 +468,7 @@ def page3():
468
 
469
  with st.spinner('Bot is thinking...'):
470
  chain = load_chatbot()
471
- docs = VectorStore.similarity_search(query=query, k=3)
472
  with get_openai_callback() as cb:
473
  response = chain.run(input_documents=docs, question=query)
474
  response = handle_no_answer(response) # Process the response through the new function
 
243
 
244
  with st.spinner('Bot is thinking...'):
245
  chain = load_chatbot()
246
+ docs = VectorStore.similarity_search(query=query, k=5)
247
  with get_openai_callback() as cb:
248
  response = chain.run(input_documents=docs, question=query)
249
  response = handle_no_answer(response) # Process the response through the new function
 
356
 
357
  with st.spinner('Bot is thinking...'):
358
  chain = load_chatbot()
359
+ docs = VectorStore.similarity_search(query=query, k=5)
360
  with get_openai_callback() as cb:
361
  response = chain.run(input_documents=docs, question=query)
362
  response = handle_no_answer(response) # Process the response through the new function
 
468
 
469
  with st.spinner('Bot is thinking...'):
470
  chain = load_chatbot()
471
+ docs = VectorStore.similarity_search(query=query, k=5)
472
  with get_openai_callback() as cb:
473
  response = chain.run(input_documents=docs, question=query)
474
  response = handle_no_answer(response) # Process the response through the new function