Merge branch 'main' of github.com:joaomdmoura/crewAI into replay-feat-using-db

This commit is contained in:
Lorenze Jay
2024-07-15 08:02:14 -07:00
16 changed files with 620 additions and 74 deletions

View File

@@ -1236,10 +1236,10 @@ def test_agent_usage_metrics_are_captured_for_hierarchical_process():
print(crew.usage_metrics)
assert crew.usage_metrics == {
"total_tokens": 311,
"prompt_tokens": 224,
"completion_tokens": 87,
"successful_requests": 1,
"total_tokens": 2217,
"prompt_tokens": 1847,
"completion_tokens": 370,
"successful_requests": 4,
}
@@ -1269,7 +1269,7 @@ def test_hierarchical_crew_creation_tasks_with_agents():
assert crew.manager_agent.tools is not None
print("TOOL DESCRIPTION", crew.manager_agent.tools[0].description)
assert crew.manager_agent.tools[0].description.startswith(
"Delegate a specific task to one of the following coworkers: [Senior Writer, Researcher]"
"Delegate a specific task to one of the following coworkers: Senior Writer"
)