Added system prompt
Browse files
app.py
CHANGED
|
@@ -40,6 +40,7 @@ class BasicAgent:
|
|
| 40 |
self.agent = CodeAgent(
|
| 41 |
tools=[self.search_tool],
|
| 42 |
model=self.model,
|
|
|
|
| 43 |
max_steps=5 # Limit reasoning steps
|
| 44 |
)
|
| 45 |
|
|
@@ -55,8 +56,9 @@ class BasicAgent:
|
|
| 55 |
|
| 56 |
try:
|
| 57 |
# Run the agent with the question
|
| 58 |
-
formatted_question = f"{question}\n\nAnswer with only the exact answer, no explanation."
|
| 59 |
-
answer = self.agent.run(formatted_question)
|
|
|
|
| 60 |
print(f"Agent returning answer: {answer[:100]}...")
|
| 61 |
fixed_answer = answer
|
| 62 |
except Exception as e:
|
|
|
|
| 40 |
self.agent = CodeAgent(
|
| 41 |
tools=[self.search_tool],
|
| 42 |
model=self.model,
|
| 43 |
+
system_prompt=self.system_prompt,
|
| 44 |
max_steps=5 # Limit reasoning steps
|
| 45 |
)
|
| 46 |
|
|
|
|
| 56 |
|
| 57 |
try:
|
| 58 |
# Run the agent with the question
|
| 59 |
+
#formatted_question = f"{question}\n\nAnswer with only the exact answer, no explanation."
|
| 60 |
+
#answer = self.agent.run(formatted_question)
|
| 61 |
+
answer = self.agent.run(question)
|
| 62 |
print(f"Agent returning answer: {answer[:100]}...")
|
| 63 |
fixed_answer = answer
|
| 64 |
except Exception as e:
|