ruslanmv commited on
Commit
248a751
1 Parent(s): 3579d89

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -33,8 +33,10 @@ def askme(symptoms, question):
33
  response_text = tokenizer.batch_decode(outputs)[0].strip()
34
  # Remove system messages and content
35
  response_text = response_text.replace(sys_message, "").replace(content, "").strip()
 
 
36
 
37
- return response_text
38
 
39
  # Example usage
40
  symptoms = '''\
 
33
  response_text = tokenizer.batch_decode(outputs)[0].strip()
34
  # Remove system messages and content
35
  response_text = response_text.replace(sys_message, "").replace(content, "").strip()
36
+ # Extract only the assistant's response
37
+ assistant_response = response_text.split("assistant")[1].strip()
38
 
39
+ return assistant_response
40
 
41
  # Example usage
42
  symptoms = '''\