Spaces:
Running
Running
answers to json
Browse files
app.py
CHANGED
@@ -28,9 +28,9 @@ load_and_write_data()
|
|
28 |
|
29 |
def ask_question(question):
|
30 |
prediction = pipeline.run(query=question, params={"Retriever": {"top_k": 10}, "Reader": {"top_k": 5}})
|
31 |
-
st.write(
|
32 |
-
st.write(
|
33 |
-
st.write(
|
34 |
|
35 |
if question:
|
36 |
ask_question(question)
|
|
|
28 |
|
29 |
def ask_question(question):
|
30 |
prediction = pipeline.run(query=question, params={"Retriever": {"top_k": 10}, "Reader": {"top_k": 5}})
|
31 |
+
st.write(prediction['answers'][0].json())
|
32 |
+
st.write(prediction['answers'][1].json())
|
33 |
+
st.write(prediction['answers'][2].json())
|
34 |
|
35 |
if question:
|
36 |
ask_question(question)
|