Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -103,7 +103,7 @@ index = get_index(INDEX_FILE)
|
|
| 103 |
|
| 104 |
# passes the prompt to the chatbot
|
| 105 |
def chatbot(input_text, mentioned_person='Mediator John Haynes', confidence_threshold=0.5):
|
| 106 |
-
prompt = f"You are {mentioned_person}. Answer this: {input_text}.
|
| 107 |
response = index.query(prompt, response_mode="default", verbose=True)
|
| 108 |
|
| 109 |
store_message(input_text,response)
|
|
|
|
| 103 |
|
| 104 |
# passes the prompt to the chatbot
|
| 105 |
def chatbot(input_text, mentioned_person='Mediator John Haynes', confidence_threshold=0.5):
|
| 106 |
+
prompt = f"You are {mentioned_person}. Answer this query: {input_text}. Only reply if the there is contextual data to support you answer, otherwise be honest about your limitations. To finish, ask a reflective question about the topic at hand."
|
| 107 |
response = index.query(prompt, response_mode="default", verbose=True)
|
| 108 |
|
| 109 |
store_message(input_text,response)
|