Kathirsci commited on
Commit
59bdb30
·
verified ·
1 Parent(s): 3a63849

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -24,7 +24,9 @@ QA_CHAIN_PROMPT = PromptTemplate(input_variables=["context", "question"],templat
24
 
25
  def predict(message, history):
26
  input_prompt = QA_CHAIN_PROMPT.format(question=message, context=history)
27
- ai_msg = llm.generate([input_prompt]) # Pass a list of strings
28
  return ai_msg
29
 
 
 
30
  gr.ChatInterface(predict).launch()
 
24
 
25
  def predict(message, history):
26
  input_prompt = QA_CHAIN_PROMPT.format(question=message, context=history)
27
+ ai_msg = llm.generate([input_prompt])[0] # Return only the first generation
28
  return ai_msg
29
 
30
+
31
+
32
  gr.ChatInterface(predict).launch()