Performance
Performance examples benchmark runtime and memory impact for agents and teams.
PerformanceEval runs the callable separately for each enabled metric: warm-ups first, then runtime measurements, then memory measurements. num_iterations applies to each metric, and the default is 10 additional warm-up calls. Model retries, tools, delegation, and memory extraction can add provider requests beyond the callable count.
Memory measurements use Python’s tracemalloc; they do not measure process RSS, GPU memory, database-server memory, or remote model memory. Record dependency versions, database state, and model settings when comparing results.
| Example | Description |
|---|---|
| Async Function Performance Evaluation | Demonstrates performance evaluation for an asynchronous function. |
| Db Logging | Demonstrates storing performance evaluation results in PostgreSQL. |
| Instantiate Agent | Demonstrates measuring agent instantiation performance. |
| Instantiate Agent With Tool | Demonstrates measuring instantiation performance for a tooled agent. |
| Instantiate Team | Demonstrates measuring team instantiation performance. |
| Memory Update Performance Evaluation | Demonstrates measuring performance when memory updates are enabled. |
| Response With Storage | Demonstrates measuring performance when storage-backed history is enabled. |
| Simple Response Performance Evaluation | Demonstrates baseline response performance for a single prompt. |
| Team Response With Memory Simple | Measures Team memory after applying the documented async-stream consumption fix. |
| Team Response With Memory Multi User | Demonstrates concurrent team performance across multiple users with memory. |
| Team Response With Memory And Reasoning | Measures a reasoning-enabled Team after fixing stream consumption; enable debug output for allocation details. |
| Comparison | These benchmarks compare agent instantiation patterns across non-Agno frameworks. |