peterpull commited on
Commit
93a5cd7
·
1 Parent(s): e62de04

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -4
app.py CHANGED
@@ -103,15 +103,13 @@ def print_header_json_file(filepath):
103
  index = get_index(INDEX_FILE)
104
 
105
  # passes the prompt to the chatbot
106
- def chatbot(input_text, mentioned_person='Mediator John Haynes', confidence_threshold=0.5:
107
-
108
  hyde= HyDEQueryTransform(include_original=True)
109
  hyde_response= index.query(input_text, query_transform=hyde)
110
- print=({hyde_response}"")
111
 
112
  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."
113
  response = index.query(prompt, response_mode="default", verbose=True)
114
-
115
  store_message(input_text,response)
116
 
117
  # return the response
 
103
  index = get_index(INDEX_FILE)
104
 
105
  # passes the prompt to the chatbot
106
+ def chatbot(input_text, mentioned_person='Mediator John Haynes', confidence_threshold=0.5):
 
107
  hyde= HyDEQueryTransform(include_original=True)
108
  hyde_response= index.query(input_text, query_transform=hyde)
109
+ print(f"{hyde_response}")
110
 
111
  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."
112
  response = index.query(prompt, response_mode="default", verbose=True)
 
113
  store_message(input_text,response)
114
 
115
  # return the response