Multi-Agent System

A Multi-Agent System is an architecture in which multiple specialized LLM agents, each with its own system prompt, tools, and context window, cooperate to complete a shared task by dividing it into subtasks, exchanging intermediate results, and…

A Multi-Agent System is an architecture in which multiple specialized LLM agents, each with its own system prompt, tools, and context window, cooperate to complete a shared task by dividing it into subtasks, exchanging intermediate results, and converging on a final output through a coordination layer. Each agent owns a narrow scope—a researcher pulls sources, a coder writes patches, a critic reviews diffs—so the combined system can tackle work that would overflow a single agent's context or exceed one prompt's reasoning budget. Coordination ranges from a fixed sequential pipeline to a dynamic supervisor that routes subtasks at runtime. The pattern trades monolithic complexity for distributed complexity: failures surface as inter-agent miscommunication, race conditions, or compounding hallucinations rather than a single bad completion. Production deployments lean on orchestration frameworks that manage message passing, retries, and shared state so the fleet behaves more like a disciplined team than a chatroom.

How it works

A supervisor or router agent decomposes the task and assigns each subtask to a specialist whose system prompt and tool set are scoped to that role. Agents execute concurrently or sequentially, writing intermediate results to a shared scratchpad, message queue, or structured state object that downstream agents read. Each agent runs its own agentic loop—planning, tool calls, observation—until it signals completion or hits a step budget. The coordinator merges outputs, resolves conflicts, and may re-dispatch failed subtasks to alternative agents. Token cost and latency scale roughly with agent count and the depth of inter-agent dialogue, not just input size.

Why it matters for AI engineers

Multi-agent designs win when subtasks are embarrassingly parallel or when context isolation prevents one document from crowding out another—research, multi-file code edits, and long-horizon planning all benefit. They lose when coordination overhead, token duplication across agents, and retry storms exceed what a single well-prompted agent would cost. Failure modes compound: one agent's hallucinated intermediate result can poison every downstream agent, and prompt-injection attacks gain lateral-movement vectors across the fleet. Engineers must instrument per-agent traces, budgets, and guardrails independently, because a single agent's misbehavior is rarely visible at the orchestration layer without explicit telemetry. Shipping a multi-agent system is a distributed-systems problem as much as a prompting problem.

Multi-Agent System vs. alternatives

Multi-Agent System Single Agent Mixture of Experts
Unit of work Multiple cooperating agents One LLM plus tools Expert sub-networks in one model
Parallelism Inter-agent, explicit None (sequential loop) Intra-model, per-token routing
Context isolation Per-agent context windows One shared context No separate contexts
Failure surface Inter-agent miscommunication Single completion failure Routing errors, load imbalance

Related terms

Go deeper

Definitions are the start. Ask the Research Desk for a cited, multi-source brief on Multi-Agent System — real sources, verified claims, delivered in minutes.

Ask the Research Desk →