Documentation Index
Fetch the complete documentation index at: https://docs.swarms.world/llms.txt
Use this file to discover all available pages before exploring further.
Overview
Swarms provides a wide range of multi-agent architectures designed for different use cases, from simple round-robin task distribution to complex hierarchical orchestration. This page provides a comprehensive overview to help you select the right architecture for your needs.
Installation
Core Architectures
| Architecture | Use Case | Key Functionality |
|---|
| MajorityVoting | Decision making through consensus | Combines multiple agent opinions and selects the most common answer |
| AgentRearrange | Optimizing agent order | Dynamically reorders agents based on task requirements |
| RoundRobin | Equal task distribution | Cycles through agents in a fixed order |
| Mixture of Agents | Complex problem solving | Combines diverse expert agents for comprehensive analysis |
| GroupChat | Collaborative discussions | Simulates group discussions with multiple agents |
| SpreadSheetSwarm | Data processing | Collaborative data processing and analysis |
| SwarmRouter | Task routing | Routes tasks to appropriate agents based on requirements |
| MultiAgentRouter | Advanced task routing | Routes tasks to specialized agents based on capabilities |
Workflow Architectures
| Architecture | Use Case | Key Functionality |
|---|
| ConcurrentWorkflow | Parallel task execution | Executes multiple tasks simultaneously |
| SequentialWorkflow | Step-by-step processing | Executes tasks in a specific sequence |
| GraphWorkflow | Complex task dependencies | Manages tasks with complex dependencies |
Hierarchical Architectures
| Architecture | Use Case | Key Functionality |
|---|
| HierarchicalSwarm | Hierarchical task orchestration | Director agent coordinates specialized worker agents |
| Hybrid Hierarchical-Cluster Swarm | Complex organization | Combines hierarchical and cluster-based organization |
| Auto Swarm Builder | Automated swarm creation | Automatically creates and configures swarms |
Communication Structure
The Conversation documentation details the communication protocols and structures used between agents in these architectures.
Choosing the Right Architecture
Task Complexity — Simple tasks may only need basic architectures like RoundRobin, while complex tasks might require Hierarchical or Graph-based approaches.
Parallelization Needs — If tasks can be executed in parallel, consider ConcurrentWorkflow or SpreadSheetSwarm.
Decision Making Requirements — For consensus-based decisions, MajorityVoting is ideal.
Resource Optimization — If you need to optimize agent usage, consider SwarmRouter or MultiAgentRouter.
Dynamic Adaptation — For tasks requiring dynamic adaptation, consider Auto Swarm Builder.
Architecture Selection Guide
By Task Type
| Task Type | Recommended Architecture |
|---|
| Simple, sequential tasks | SequentialWorkflow, RoundRobin |
| Parallel, independent tasks | ConcurrentWorkflow, SpreadSheetSwarm |
| Consensus-based decisions | MajorityVoting |
| Complex multi-domain tasks | HierarchicalSwarm, HHCS |
| Dynamic, evolving tasks | Auto Swarm Builder |
| Collaborative analysis | GroupChat, Mixture of Agents |
| Task routing | SwarmRouter, MultiAgentRouter |
By Scale
| Scale | Recommended Architecture |
|---|
| 2-5 agents | RoundRobin, SequentialWorkflow, AgentRearrange |
| 5-20 agents | SwarmRouter, GroupChat, ConcurrentWorkflow |
| 20+ agents | HierarchicalSwarm, HHCS, SpreadSheetSwarm |
| Variable/dynamic | Auto Swarm Builder |
For more detailed information about each architecture, refer to their respective documentation pages linked in the tables above.