Appearance
Multi-Agent Systems
elsai orchestrates multiple Agent instances through several patterns — from a single agent calling a specialist as a tool, to full graphs and swarms managed by the framework.
Prerequisites
Install the core SDK:
bash
pip install --extra-index-url https://elsai-agents.elsai.ai/root/ elsai-agents==0.3.0For Agent-to-Agent (A2A), also install the a2a extra: "elsai-agents[a2a]==0.3.0". See Installation.
Patterns
| Pattern | Description |
|---|---|
| Graph | Deterministic pipeline — nodes and edges define execution order |
| Swarm | Autonomous collaboration — agents hand off work dynamically |
| Workflow | Imperative pipeline you implement in Python |
| Agent as Tool | One agent calls another via agent.as_tool() — use mode="spawn" or mode="queue" when the same specialist may be called twice in one turn |
| A2A | Remote agents over the A2A protocol |
Why multi-agent?
- Parallelism — run independent tasks concurrently; for the same sub-agent called twice in one turn, see concurrent invocation modes
- Specialisation — each agent has a focused role, tools, and system prompt
- Context management — distribute work across smaller context windows
- Scalability — compose complex workflows from simple building blocks