Update app.py
Browse files
app.py
CHANGED
@@ -158,8 +158,8 @@ with gr.Blocks(theme='JohnSmith9982/small_and_pretty') as demo:
|
|
158 |
submit_button = gr.Button("Submit")
|
159 |
|
160 |
def display_response(question):
|
161 |
-
|
162 |
-
|
163 |
|
164 |
submit_button.click(fn=display_response, inputs=question, outputs=None)
|
165 |
|
|
|
158 |
submit_button = gr.Button("Submit")
|
159 |
|
160 |
def display_response(question):
|
161 |
+
response, confidence_score = query_model(question)
|
162 |
+
answer.value = f"Response: {response}\nConfidence Score: {confidence_score:.2f}"
|
163 |
|
164 |
submit_button.click(fn=display_response, inputs=question, outputs=None)
|
165 |
|