alemarino2025 commited on
Commit
c462499
·
verified ·
1 Parent(s): 20ed295

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -233,8 +233,10 @@ def predict(user_input, timeout_seconds=1800): # 30 minutes = 1800 seconds
233
  #prediction = bot_response.choices[0].message.content.strip()
234
 
235
  save_feedback(user_input, context_for_query, prediction)
 
 
236
 
237
- return prediction
238
 
239
  # Set-up the Gradio UI
240
  # Add text box.
 
233
  #prediction = bot_response.choices[0].message.content.strip()
234
 
235
  save_feedback(user_input, context_for_query, prediction)
236
+
237
+ prediction_cl = re.sub(r"<think>.*?</think>\n?", "", prediction, flags=re.DOTALL)
238
 
239
+ return prediction_cl
240
 
241
  # Set-up the Gradio UI
242
  # Add text box.