Rahatara commited on
Commit
94ec754
·
verified ·
1 Parent(s): d4dc6f8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -58,7 +58,7 @@ def preprocess_response(response: str) -> str:
58
 
59
  def shorten_response(response: str) -> str:
60
  """Uses the Zephyr model to shorten and refine the response."""
61
- messages = [{"role": "system", "content": "Shorten and refine this response in a supportive and empathetic manner."}, {"role": "user", "content": response}]
62
  result = client.chat_completion(messages, max_tokens=512, temperature=0.5, top_p=0.9)
63
  return result.choices[0].message['content'].strip()
64
 
 
58
 
59
  def shorten_response(response: str) -> str:
60
  """Uses the Zephyr model to shorten and refine the response."""
61
+ messages = [{"role": "system", "content": "Greet, Shorten and refine this response in a supportive and empathetic manner."}, {"role": "user", "content": response}]
62
  result = client.chat_completion(messages, max_tokens=512, temperature=0.5, top_p=0.9)
63
  return result.choices[0].message['content'].strip()
64