Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -205,22 +205,13 @@ Instructions:
|
|
| 205 |
|
| 206 |
Be precise and thorough in your analysis."""
|
| 207 |
|
| 208 |
-
|
| 209 |
-
{
|
| 210 |
-
"role": "system",
|
| 211 |
-
"content": "You are an expert at solving complex and trick questions. Always think step by step and be very careful about the exact wording of questions."
|
| 212 |
-
},
|
| 213 |
-
{
|
| 214 |
-
"role": "user",
|
| 215 |
-
"content": enhanced_prompt
|
| 216 |
-
}
|
| 217 |
-
]
|
| 218 |
|
| 219 |
-
result = model(
|
| 220 |
|
| 221 |
if result:
|
| 222 |
# Step 4: Validate the answer
|
| 223 |
-
validation = self.answer_validator.
|
| 224 |
print(f"Answer validation: {validation}")
|
| 225 |
|
| 226 |
# Clean up the result
|
|
|
|
| 205 |
|
| 206 |
Be precise and thorough in your analysis."""
|
| 207 |
|
| 208 |
+
system_message = "You are an expert at solving complex and trick questions. Always think step by step and be very careful about the exact wording of questions."
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 209 |
|
| 210 |
+
result = model([{"role": "system", "content": system_message}, {"role": "user", "content": enhanced_prompt}])
|
| 211 |
|
| 212 |
if result:
|
| 213 |
# Step 4: Validate the answer
|
| 214 |
+
validation = self.answer_validator.forward(question, result)
|
| 215 |
print(f"Answer validation: {validation}")
|
| 216 |
|
| 217 |
# Clean up the result
|