Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -31,11 +31,11 @@ def load_data_to_store(document_store, retriever):
|
|
31 |
pipeline = start_haystack()
|
32 |
|
33 |
def predict(question):
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
|
38 |
-
|
39 |
predict,
|
40 |
inputs=gr.inputs.Textbox(label="enter your monopoly question here"),
|
41 |
outputs=gr.outputs.Label(num_top_classes=1),
|
|
|
31 |
pipeline = start_haystack()
|
32 |
|
33 |
def predict(question):
|
34 |
+
predictions = pipeline.run(question)
|
35 |
+
answer = predictions["answers"]
|
36 |
+
return answer
|
37 |
|
38 |
+
gr.Interface(
|
39 |
predict,
|
40 |
inputs=gr.inputs.Textbox(label="enter your monopoly question here"),
|
41 |
outputs=gr.outputs.Label(num_top_classes=1),
|