refactor: create agent history file based on agent_<ID>

This commit is contained in:
meshkatshb
2025-01-14 17:22:37 +03:30
parent 36649f352c
commit bbf9feac1f

View File

@@ -364,7 +364,7 @@ async def run_custom_agent(
)
history = await agent.run(max_steps=max_steps)
history_file = os.path.join(save_agent_history_path, "AgentHistory.json")
history_file = os.path.join(save_agent_history_path, f"{agent.agent_id}.json")
agent.save_history(history_file)
final_result = history.final_result()