Swarms
The enterprise-grade Python framework for production multi-agent systems.
Quickstart
From pip install to a multi-agent system in minutes.
Pure Python. No DSLs, no YAML, no glue code. Build single agents, sequential pipelines, hierarchical swarms — all from the same primitives.
Install with pip — one package, zero setup
Define agents with a system prompt and model
Compose them with any swarm topology
Run — Swarms handles orchestration
from swarms import Agent
agent = Agent(
agent_name="Financial-Analyst",
system_prompt="You are a senior financial analyst.",
model_name="gpt-4o",
max_loops=1,
temperature=0.2,
)
response = agent.run(
"Analyze the macro outlook for the semiconductor sector in 2026."
)
print(response)Capabilities
Everything you need to ship agents in production
A complete multi-agent toolkit — orchestration, memory, tools, observability — first-class in Python.
Multi-agent orchestration
Sequential, concurrent, hierarchical, group-chat, mixture-of-agents and 15+ swarm topologies — composable in pure Python.
Provider-agnostic models
1,000+ models from OpenAI, Anthropic, Gemini, Groq, DeepSeek, Cohere, Ollama, vLLM and any OpenAI-compatible endpoint.
Tools & function calling
Structured outputs, parallel tool use, retries, and built-in tools for web search, finance, code execution, browsing and more.
Memory & RAG
Long-term memory, vector store integrations (Chroma, Pinecone, FAISS, Qdrant) and document loaders out of the box.
MCP & integrations
First-class Model Context Protocol support — connect Notion, Supabase, GitHub, or any MCP server to your agents.
Observability
Structured logging, per-agent telemetry, token accounting and tracing — drop-in compatibility with OpenTelemetry.
Concurrency built-in
Async-first runtime with thread, process and asyncio pools. Run thousands of agents in parallel from a single process.
Composable workflows
Drop agents into any workflow primitive. Mix swarm types, share state, and branch dynamically at runtime.
Production hardening
Type-safe configs (Pydantic v2), exponential-backoff retries, fault isolation, and battle-tested in production deployments.
15+ architectures
Every swarm topology, batteries included.
Pick a primitive, pass your agents and a task — Swarms handles routing, memory and aggregation.
SequentialWorkflow
Run agents one after another, passing state forward.
ConcurrentWorkflow
Fan out agents in parallel, gather their outputs.
HierarchicalSwarm
A director agent decomposes work to specialist workers.
MixtureOfAgents
Multiple agents independently solve, an aggregator merges.
GroupChat
Agents collaborate in a shared conversation loop.
MajorityVoting
Agents vote; the consensus answer wins.
AgentRearrange
Dynamically rearrange flow based on runtime signals.
HeavySwarm
Large fan-out swarms for high-recall research tasks.
DebateWithJudge
Agents debate; a judge agent decides the winner.
AutoSwarmBuilder
LLM designs and instantiates the swarm for the task.
RoundRobin
Cycle agents in turn — predictable, fair scheduling.
CouncilAsAJudge
A council of judges scores and ranks candidate outputs.
And more — including BatchedGridWorkflow, MultiAgentRouter, AutoSwarmBuilder, PlannerWorkerSwarm, and custom topologies.
1,000+ models
Every provider, one interface.
Switch models with a string. Mix providers inside the same swarm. No SDK lock-in.
Used in production
Across every industry that runs on Python
From Fortune 500 R&D teams to fast-moving startups — Swarms powers production workloads at scale.
Finance
Multi-agent research desks, portfolio analysis, risk modeling, and compliance automation.
Healthcare
Clinical reasoning, ICD coding, claims processing, and diagnostic decision-support swarms.
Engineering
Code generation, code review, refactoring, test synthesis and dev-tooling agents.
Research
Literature review, paper synthesis, experiment planning and scientific writing pipelines.
Marketing
Brief generation, content production, brand-voice critique and campaign orchestration.
Operations
Business-process automation, document workflows, intake triage and back-office swarms.
Why Swarms
The framework teams trust to ship agents
Battle-tested
Trusted in production by financial institutions, healthcare networks, and Fortune 500 R&D teams. Hardened by 100+ contributors and 7,000+ stars worth of community usage.
Composable, not opinionated
Swarms gives you primitives, not a walled garden. Drop agents into any architecture, share state across them, and extend with your own Python.
Open source, forever
Apache 2.0 licensed. Read the source, audit the runtime, contribute back, or run on your own infrastructure — no vendor lock-in.
Open source
Built in the open. Used everywhere.
Swarms is Apache 2.0 licensed and built in public on GitHub. Read the source, contribute a feature, file an issue, or fork it.
FAQ
Common questions
Build the multi-agent layer of your stack.
One pip install away. Open source. Production-ready. Trusted by 100,000+ developers.