Skip to content
AgentAgent framework

swarms

Python framework for orchestrating teams of LLM agents in sequential, parallel and graph

swarms is an open-source agent framework for ai models and llm tooling. It is available on API, CLI, Self-hosted, Linux, macOS and Windows.

Pricing
Open source
Platforms
API, CLI, Self-hosted
GitHub stars
7.4K
Last commit
Language
Python
License
Apache-2.0

Similar agents

About swarms

Swarms is a Python library for wiring several LLM-backed agents into one working system. Instead of writing the plumbing yourself, you pick a structure such as a sequential chain, a concurrent batch, a DAG, a group chat or a director-and-workers hierarchy, and the library handles how the agents pass results between each other.

An agent is built from a model name, a system prompt, optional tools and memory, and a loop setting that can either run a fixed number of iterations or let the agent decide when it has finished. Agents can also load tools from remote MCP servers, and an agent or swarm can be published as an MCP server behind an API key. A SwarmRouter provides one interface for switching between swarm strategies without rewriting the agents.

The project suits Python developers who need multi-agent pipelines for research, content, analysis or reporting work and want control over orchestration. It installs with pip, uv or poetry, and a Docker image is published for running scripts without a local setup.

What it does

Multiple orchestration patterns
Choose sequential, concurrent, graph-based, group chat, hierarchical or mixture-of-agents structures for coordinating agents.
Autonomous looping agents
Agents can run until they judge a task complete instead of stopping after a fixed number of iterations.
MCP client and server support
Agents can consume tools from MCP servers, and MCPDeployer can expose an agent or swarm as an MCP server.
Unified swarm router
SwarmRouter runs the same agents under different swarm strategies by changing one parameter.
Agent-to-agent protocol
A2A server and client classes let agents built on the library call remote A2A agents and be called by them.
Docker and CLI packaging
An official Docker image and a command-line interface make it straightforward to run scripts without a local Python setup.

Good for

  • Building a researcher-and-writer pipeline that turns a topic into a draft article
  • Running several specialist analysis agents in parallel on the same question and merging their answers
  • Routing a research task through a director agent that assigns work to specialist workers
  • Exposing an internal agent as an MCP tool that other assistants can call with an API key
  • Prototyping a multi-agent team quickly from a plain-language task description

Pricing

Open source

Free open-source library under Apache-2.0; separate hosted Marketplace exists.

Prices change. Check docs.swarms.world before you buy.

swarms FAQ

How do I install swarms?

Install with pip3 install -U swarms, uv pip install swarms, or poetry add swarms. A Docker image is also published on Docker Hub.

Which models can agents use?

Agents are configured with a model name, and the library documents support for several providers including OpenAI, Anthropic and Groq via API keys in environment variables.

Can I connect agents to external tools?

Yes. Setting mcp_url or mcp_urls lets an agent load tools from one or more MCP servers.

What license is swarms under?

Swarms is licensed under the Apache License 2.0.

Is swarms free?

Yes. swarms is open source, so you can use and self-host it for free.

What are the best alternatives to swarms?

The closest alternatives to swarms are agency-swarm, swarmclaw, OpenProgram, mcp-agent and swarm.

Where this comes from

  • Description: written from the project's README and the project's website.