joserman commited on
Commit
d84f5a4
·
verified ·
1 Parent(s): 74d3140

added debug

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -119,6 +119,8 @@ def chat():
119
  try:
120
  result = rag_chain.invoke({"input": user_message})
121
  raw_response = result.get('answer', "I couldn't generate a response.")
 
 
122
  clean_response = strip_think_tags(raw_response)
123
  return jsonify({'reply': clean_response})
124
  except Exception as e:
 
119
  try:
120
  result = rag_chain.invoke({"input": user_message})
121
  raw_response = result.get('answer', "I couldn't generate a response.")
122
+ print(f"DEBUG RAW RESPONSE:\n{raw_response}\n----------------")
123
+
124
  clean_response = strip_think_tags(raw_response)
125
  return jsonify({'reply': clean_response})
126
  except Exception as e: