← Back to Leaderboard
AVRSEN

VRSEN/agency-swarm

Python agent orchestration with explicit, directional delegation

Engineering Health (Methodology)
A+ · 92/100
Maintenance Activity
● Updated today
Latest Release
v1.11.0
Commercial License Check
MIT · Commercial Friendly

Automated SPDX check for reference only — not legal advice. Disclaimer

Maintenance35/35
Fork Adoption23/25
Release Cadence14/20
License Clarity20/20
API
Total Stars
★ 4,646
24h Growth
+1
7d Growth
+5
Forks
1,062

GitHub Star History

Full-history star trajectory from GitHub official history. Switch ranges or hover any point for exact counts.

VRSEN/agency-swarm Star History (2023-11-22 - 2026-12-04) ALL-TIME STAR HISTORY (2023-11 – 2026-12) +4.6k in 1108d · avg +4/day 4.9k 2.5k 0 2023-11-22: ★ 12024-02-03: ★ 7712024-04-13: ★ 1,1032024-06-22: ★ 1,9282024-08-31: ★ 2,2302024-11-09: ★ 2,5822025-01-18: ★ 3,0262025-03-29: ★ 3,4712025-06-07: ★ 3,5832025-08-16: ★ 3,6332025-10-25: ★ 3,7622026-01-03: ★ 3,8362026-03-14: ★ 4,0022026-05-23: ★ 4,3632026-08-01: ★ 4,4802026-10-10: ★ 4,5832026-12-04: ★ 4,646 ★ 4.6k 2023-11 2025-05 2026-12

Evidence-Backed Technical Brief

AI Deep Review

Architecture & Core Mechanics

Agency Swarm is a Python orchestration layer over the OpenAI Agents SDK. An Agency exposes a user-facing entry agent and a directed communication graph. On a programmatic call to get_response, agents act under their role-specific and shared instructions, using send_message to contact permitted peers. An edge such as lead > specialist controls who can initiate a conversation, not which branch will execute on every request.

Tool integration centers on the SDK's FunctionTool format: register a decorated Python function, adapt a Pydantic-based BaseTool, or import an OpenAPI schema through ToolFactory.from_openapi_schema. Conversation history crosses an application-defined boundary through load/save callbacks rather than a prescribed database. The 2.0 beta manifest includes Pydantic 2.11–2.x, MCP 2, and FastMCP 4, and pins openai-agents==0.22.3 because the framework patches private SDK interfaces.

Key Capabilities & Differentiators

Agents can have independent instructions, tools, model settings, and file and schema directories, while sharing agency-wide instructions. Native inference uses the OpenAI Responses API; the 2.0 beta defaults to gpt-6-luna. LiteLLM provides a route to Claude, Gemini, Grok, Azure OpenAI, and OpenRouter. Treat provider routing as distinct from feature parity: validate the tool calls and any model-specific features your application depends on against the backend you choose.

The API surface includes async get_response and synchronous get_response_sync; copilot_demo() and tui() are interactive entrypoints for trying an agency. The v1.11.0 release adds realtime voice, per-user OAuth for MCP servers, and system reminders. The 2.0 beta adds OpenAI-side conversation compaction so later turns send only the portion after compaction. That optimization targets repeated history transmission; it is not a general guarantee of lower cost for every workload or backend.

Trade-offs & Limitations

Compared with using the OpenAI Agents SDK directly, Agency Swarm provides explicit delegation topology and shared conventions for role instructions, tools, and history. That pays off when several specialists need clearly scoped communication. For a single agent or a fixed sequence of steps, direct SDK calls or ordinary Python control flow are simpler. The graph constrains who may delegate to whom; it neither makes routing deterministic nor substitutes for authorization on an external tool.

Delegation can add model round trips and token usage. History callbacks leave session isolation, retention, and storage behavior to the application; schema-generated tools still need authorization and input review. The beta's private SDK patches also narrow the safe upgrade window, so upgrade the framework and its pinned SDK together and rerun integration tests. MIT permits commercial use with its notice requirements, but model API and external-service terms still apply.

Hardware & Deployment Guide

The documented runtime is Python 3.12+ on macOS, Linux, or Windows. Use pip install -U agency-swarm for the regular release track or pip install -U --pre agency-swarm to opt into prereleases. For native OpenAI access, supply OPENAI_API_KEY via the environment or a .env file. The Node.js 16+ requirement belongs to the v1.x agent generator, not the Python orchestrator. For a production API, run the SDK inside your application and provide your own request handling and history storage.

You can self-host the orchestration code, but the described inference path is API-backed, not an offline deployment. It does not require local GPU or VRAM for model inference. Size the host for concurrent runs, history serialization, and local tools, and budget for network latency and downstream API limits. Separate the v1.11.0 stable release from the 2.0.0-beta.1 dependency migration; test session continuity, tool behavior, and provider compatibility before promoting the beta.

Delegation topology: communication_flows defines which agents can initiate contact through send_message.
Tool integration: @function_tool, Pydantic-based BaseTool, and OpenAPI imports feed into the SDK's FunctionTool model.
Session persistence: load_threads_callback and save_threads_callback let the host application supply history storage.
Application entrypoints: async get_response, synchronous get_response_sync, plus copilot_demo() and tui() for interactive use.
Model backends: native OpenAI Responses API and a LiteLLM route to providers including Anthropic, Google, Azure OpenAI, and OpenRouter.
Upgrade boundary: the 2.0 beta adopts OpenAI SDK 3, MCP 2, and FastMCP 4 while pinning openai-agents==0.22.3.
Best For

API-backed workflows with several stable specialist roles, explicit delegation boundaries, and application-owned conversation history.

Skip If

A single agent or fixed Python workflow is enough, inference must run offline, or you need a turnkey hosted service rather than an embedded SDK.

Reviewed on 2026-12-03 · Grounded in GitHub README, root file tree & releasesMethodology

Quick Start & Installation

API
pip install -U agency-swarm

Comparison vs. Top Agents & Frameworks Alternatives

Full comparison →
RepositoryStars7d TrendStackLicenseCore Positioning
agency-swarm ★4.6k+5PythonMITPython agent orchestration with explicit, directional delegation
browser-use122.7k+477PythonMITPython REPL and CDP for adaptive browser automation
langchain150.4k+299PythonMITModular Python framework for building agents across model providers
agentscope37.2k+342PythonApache-2.0Python ReAct SDK and FastAPI service for observable, interruptible agent workflo

AI Context Briefing (for Claude / Cursor / Windsurf)

Standardized architecture summary & quickstart commands ready to paste into coding agents.

Raw .md ↗
curl -sL https://repoforai.com/repo/VRSEN/agency-swarm.md

Embed Star History Chart & Badges in README.md

Full-history Star History SVGs and velocity cards on GitHub Camo: drop-in replacement for OSSInsight and Star History widgets.

VRSEN/agency-swarm Star History on RepoForAI

Active README embeds unlock Hot-Tier 6h Telemetry Refresh automatically (zero pay-to-rank).

Frequently Asked Questions about agency-swarm

How do I integrate an agency and control which agents can delegate?

Pass the user-facing agent to Agency, declare allowed initiations with communication_flows, and call await agency.get_response(...). An edge such as lead > specialist lets the lead initiate contact through send_message; it does not grant the reverse direction. For history across sessions, provide load_threads_callback and save_threads_callback and manage storage in your application.

Does Agency Swarm need a GPU, and how should I size the host?

The API-backed configuration runs model inference remotely, so the Python orchestrator does not require a local GPU or VRAM. Size the host for concurrent sessions, tool execution, history serialization, and any local work your tools perform. Measure provider usage and end-to-end latency separately: one user request can result in multiple model and tool calls.

Can we self-host it in a commercial product?

Yes. MIT permits commercial use and self-hosting of the framework; retain the copyright and license notice when redistributing it or substantial portions of it. That license does not cover model providers or external services. If prompts, histories, or agent files leave your environment, review the relevant provider terms and data-handling requirements separately.

When should we pick Agency Swarm over the OpenAI Agents SDK directly?

Use the OpenAI Agents SDK directly if the application mainly needs one agent or already has suitable routing and persistence. Agency Swarm adds value when multiple named roles need reusable, directional delegation rules and a common place to attach conversation-history storage. On the 2.0 beta, weigh that convenience against the exact upstream SDK pin and its reliance on private interfaces.

Upstream README & Documentation

This profile focuses on independent engineering analysis and live telemetry. Read the full upstream README, changelog, and examples directly on GitHub.

Maintaining VRSEN/agency-swarm? Pin to Homepage + competitor /alternatives pages with a custom Cloud/Demo CTA.Feature VRSEN/agency-swarm on Homepage & Alternatives ($19)
WEEKLY BREAKOUT DIGEST

Top 10 Breakout Open-Source AI Repos, Every Thursday

Signal-only digest of fast-growing AI repos, SPDX license alerts, and architecture picks. Zero spam.

Zero spam · 1-click unsubscribe · Privacy Policy

Saved in your browser · Export Markdown RFC tables or jump into /vs compare