Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -74,7 +74,8 @@ def user_input(user_question):
|
|
74 |
)
|
75 |
|
76 |
# Debugging: Print the original response
|
77 |
-
|
|
|
78 |
|
79 |
# Extract the thought process
|
80 |
thought_process = ""
|
@@ -84,7 +85,7 @@ def user_input(user_question):
|
|
84 |
thought_process = thought_process_match.group(1).strip()
|
85 |
|
86 |
# Remove the thought process from the main response
|
87 |
-
clean_response =
|
88 |
|
89 |
# Debugging: Print the cleaned response
|
90 |
print("Cleaned Response:", clean_response)
|
|
|
74 |
)
|
75 |
|
76 |
# Debugging: Print the original response
|
77 |
+
original_response = response['output_text']
|
78 |
+
print("Original Response:", original_response)
|
79 |
|
80 |
# Extract the thought process
|
81 |
thought_process = ""
|
|
|
85 |
thought_process = thought_process_match.group(1).strip()
|
86 |
|
87 |
# Remove the thought process from the main response
|
88 |
+
clean_response = original_response.split("<think>")[-1].split("</think>")[0]
|
89 |
|
90 |
# Debugging: Print the cleaned response
|
91 |
print("Cleaned Response:", clean_response)
|