Sbnos commited on
Commit
5d8b8f9
·
verified ·
1 Parent(s): fe9f836

followup retrieval fix

Browse files
Files changed (1) hide show
  1. app.py +5 -1
app.py CHANGED
@@ -114,12 +114,16 @@ def app():
114
  _inputs = RunnableParallel(
115
  standalone_question=RunnablePassthrough.assign(
116
  chat_history=lambda x: chistory
117
- ) | CONDENSE_QUESTION_PROMPT | llmc | StrOutputParser(),
 
 
 
118
  )
119
  _context = {
120
  "context": itemgetter("standalone_question") | retriever | _combine_documents,
121
  "question": lambda x: x["standalone_question"],
122
  }
 
123
  conversational_qa_chain = _inputs | _context | ANSWER_PROMPT | llm
124
 
125
  st.header("Ask Away!")
 
114
  _inputs = RunnableParallel(
115
  standalone_question=RunnablePassthrough.assign(
116
  chat_history=lambda x: chistory
117
+ )
118
+ | CONDENSE_QUESTION_PROMPT
119
+ | llmc
120
+ | StrOutputParser(),
121
  )
122
  _context = {
123
  "context": itemgetter("standalone_question") | retriever | _combine_documents,
124
  "question": lambda x: x["standalone_question"],
125
  }
126
+
127
  conversational_qa_chain = _inputs | _context | ANSWER_PROMPT | llm
128
 
129
  st.header("Ask Away!")