Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -31,8 +31,8 @@ pipeline = start_haystack()
|
|
31 |
|
32 |
def predict(question):
|
33 |
prediction = pipeline.run(question)
|
34 |
-
answer = prediction["answers"]
|
35 |
-
faq_response = "FAQ Question: " +
|
36 |
return faq_response
|
37 |
|
38 |
input_question =gr.inputs.Textbox(label="enter your monopoly question here")
|
|
|
31 |
|
32 |
def predict(question):
|
33 |
prediction = pipeline.run(question)
|
34 |
+
answer = prediction["answers"][0].meta
|
35 |
+
faq_response = "FAQ Question: " + answer["query"] + "\n"+"Answer: " + answer["answer"]
|
36 |
return faq_response
|
37 |
|
38 |
input_question =gr.inputs.Textbox(label="enter your monopoly question here")
|