
Why Teams?
Single agents hit limits fast. Context windows fill up, decision-making gets muddy, and debugging becomes impossible when one agent handles everything. Teams solve this by distributing work across specialized agents:| Benefit | Description |
|---|---|
| Specialization | Each agent masters one domain instead of being mediocre at everything |
| Parallel processing | Multiple agents work simultaneously on independent subtasks |
| Maintainability | When something breaks, you know exactly which agent to fix |
| Scalability | Add new capabilities by adding agents, not rewriting everything |
When to Use Teams
Use a team when:- A task requires multiple specialized agents with different tools or expertise
- A single agent’s context window gets exceeded due to task complexity
- You want to keep each agent focused on a narrow scope
- The task is simple enough for one domain of expertise
- Minimizing token costs matters
- You’re not sure yet (start simple, add agents when you hit limits)
Team Patterns
Teams support three main coordination patterns:| Pattern | Configuration | Use case |
|---|---|---|
| Supervisor (default) | Default settings | Task decomposition, quality control, synthesis |
| Router | respond_directly=True, determine_input_for_members=False | Route requests to specialists without synthesis |
| Broadcast | delegate_to_all_members=True | Parallel research, gather multiple perspectives |
Guides
Build Teams
Define members, roles, and team structure.
Run Teams
Execute teams and handle responses.
Debug Teams
Troubleshoot and inspect team behavior.
