Skip to content

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.

Default model is Amazon Bedrock

Agent() with no model= uses Amazon Bedrock (Claude Sonnet 4.6 in us-west-2). Configure AWS credentials (aws configure or AWS_* env vars), or pass an explicit model — see Installation and Model Providers.

Prerequisites

Install the core SDK:

bash
pip install --extra-index-url https://elsai-agents.elsai.ai/root/ elsai-agents==0.3.1
pip install --extra-index-url https://core-packages.elsai.ai/root/ "elsai-model[bedrock]==2.1.0"

For Agent-to-Agent (A2A), also install the a2a extra: "elsai-agents[a2a]==0.3.1". See Installation.

Copy-paste kit

Minimal agent-as-tool orchestration (AWS credentials required for the Bedrock default):

python
from elsai import Agent
from elsai.agent import AgentConfig

researcher = Agent(
    system_prompt="Research topics thoroughly and return concise notes.",
    config=AgentConfig(name="researcher", description="Research specialist"),
)
orchestrator = Agent(
    system_prompt="Delegate research, then summarise for the user.",
    tools=[researcher.as_tool()],
    config=AgentConfig(name="orchestrator"),
)

result = orchestrator("What are the top three trends in AI agents for 2026?")
print(result)

For graphs, swarms, and workflows, see the pattern pages below.

Patterns

PatternDescription
GraphDeterministic pipeline — nodes and edges define execution order
SwarmAutonomous collaboration — agents hand off work dynamically
WorkflowImperative pipeline you implement in Python
Agent as ToolOne agent calls another via agent.as_tool() — use mode="spawn" or mode="queue" when the same specialist may be called twice in one turn
A2ARemote 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

Copyright © 2026 elsai foundry.