Swarms

Active
GitHub Python Apache-2.0

Description

Enterprise multi-agent orchestration framework with Swarm, GroupChat, and Sequential patterns.

Key Features

  • Multiple topologies — Built-in Swarm, GroupChat, Hierarchical, and Sequential orchestration patterns
  • Roles and tasks — Declare agent roles, capabilities, and constraints in YAML/JSON; auto-assign tasks
  • Tool sandbox — Isolated sandbox for code execution, file I/O, and browser tools
  • Observability — Full trace across agent calls with Langfuse/Phoenix integration
  • High concurrency — Native support for hundreds of agents in parallel with real-time token and cost tracking
  • Production-ready — One-click Docker/k8s deployment with quotas, rate limits, and audit

Use Cases

💡 Equity research: multiple analyst agents scrape, cross-validate, and produce a final report in parallel.
💡 E-commerce support: pre-sales and post-sales agents collaborate on orders, returns, and policy questions.
💡 Code audit: search agent + static analysis agent + report agent working together.

Quick Start

# Install
pip install swarms
# 3 collaborating agents
from swarms import Agent, GroupChat, GroqLLM
researcher = Agent(llm=GroqLLM(), role='Researcher',
    system_prompt='Gather 2024 GenAI trends')
analyst = Agent(llm=GroqLLM(), role='Analyst',
    system_prompt='Analyze trends and rate the opportunity')
writer = Agent(llm=GroqLLM(), role='Writer',
    system_prompt='Summarize the analysis in 200 words')
chat = GroupChat(agents=[researcher, analyst, writer])
print(chat.run('GenAI trends report'))

Related Projects