Documentation Index
Fetch the complete documentation index at: https://mintlify.com/ruvnet/ruflo/llms.txt
Use this file to discover all available pages before exploring further.
ruflo swarm coordinates groups of agents working toward a shared objective. A swarm wires agents together using a chosen topology (who talks to whom), a coordination strategy (what roles exist), and a consensus algorithm (how decisions are made when agents disagree). Use swarm init to declare the topology, swarm start to assign an objective and deploy agents, and swarm status to track progress in real time.
Synopsis
Subcommands
| Subcommand | Description |
|---|---|
init | Create a new swarm topology via the MCP layer |
start | Start swarm execution against an objective |
status | Show live progress, agent counts, task breakdown, and coordination stats |
stop | Gracefully (or forcefully) stop a running swarm |
scale | Adjust the number of agents in a running swarm |
coordinate | Deploy the full V3 15-agent hierarchical-mesh topology |
Swarm topologies
| Topology | Description | Best for |
|---|---|---|
hierarchical | Queen-led tree; coordinator validates every agent output | Complex tasks where drift prevention matters |
hierarchical-mesh | Queen + peer communication (V3 default, 15-agent) | Maximum flexibility with drift control |
mesh | Fully connected peer-to-peer; every agent talks to every other | Research, creative tasks, small teams |
ring | Circular token-passing pattern | Ordered pipeline workflows |
star | Central coordinator with spokes; no peer-to-peer | Hub-spoke orchestration |
hybrid | Hierarchical mesh — alias for hierarchical-mesh | — |
The hierarchical topology is the recommended anti-drift configuration. A single coordinator validates each output against the goal and catches divergence early. Pair it with
--max-agents 6-8 and --strategy specialized for the best results on coding tasks.Coordination strategies
| Strategy | Agents deployed | Use case |
|---|---|---|
specialized | coordinator, researcher, architect, 2× coder, tester, reviewer | Default for most tasks — clear roles reduce ambiguity |
development | coordinator, architect, 3× coder, 2× tester, reviewer | Full feature development pipeline |
research | coordinator, 4× researcher, 2× analyst | Data gathering and synthesis |
testing | test lead, 2× unit tester, 2× integration tester, QA reviewer | Comprehensive test coverage |
optimization | performance lead, 2× profiler, 2× optimizer | Performance tuning |
balanced | coordinator, 4× worker, reviewer | Even workload distribution |
adaptive | coordinator, scout, 3× worker | Dynamic, exploratory tasks |
maintenance | coordinator, 2× refactorer, documenter | Codebase cleanup |
analysis | analyst lead, 2× code analyst, security analyst | Audit and documentation |
init
Register a new swarm topology and persist the configuration to.swarm/state.json.
Swarm topology. One of:
hierarchical, hierarchical-mesh, mesh, ring, star, hybrid.Maximum number of concurrent agents this swarm can host.
Coordination strategy. See the strategies table above for valid values.
Allow the swarm to grow and shrink within
--max-agents based on task demand.Enable V3 enhancements:
hierarchical-mesh topology, Flash Attention, AgentDB integration, and SONA learning.start
Assign an objective to the swarm, compute an agent deployment plan, callswarm_init via MCP, and persist the execution state to .swarm/state.json.
The task or goal the swarm should accomplish.
Execution strategy. Determines which agent types are deployed and in what ratio.
Allow agents to run tasks concurrently.
Enable real-time monitoring output.
swarm start sets up coordination state and registers agents. Actual code execution happens through Claude Code’s Task tool, headless claude -p workers, or hive-mind spawn --claude. Use swarm status <swarmId> to monitor progress.status
Read live state from.swarm/state.json, .swarm/agents/, .swarm/tasks/, and .swarm/coordination/ and render a progress dashboard.
- Overall progress — percentage bar derived from completed vs total tasks
- Agent breakdown — active, idle, completed counts
- Task breakdown — completed, in-progress, pending counts
- Performance metrics — tokens used, average response time, success rate, elapsed time
- Coordination — consensus rounds, messages sent, conflicts resolved
stop
Halt swarm execution. Updates.swarm/state.json with status: stopped and calls swarm_shutdown via MCP.
Skip the graceful drain and terminate agents immediately.
Write final state to disk so the swarm can be resumed later.
scale
Add or remove agents from a running swarm.Target total agent count. Ruflo computes the delta against the current live count via
swarm_status and spawns or terminates the difference.Restrict scaling to a specific agent type (e.g. add only
coder agents).coordinate
Deploy and display the full V3 15-agent hierarchical-mesh roster, then initialize via MCP.Number of agents to activate (1–15). The roster is sliced from the top.
| # | Role | Domain |
|---|---|---|
| 1 | Queen Coordinator | Orchestration |
| 2 | Security Architect | Security |
| 3 | Security Auditor | Security |
| 4 | Test Architect | Security |
| 5 | Core Architect | Core |
| 6 | Memory Specialist | Core |
| 7 | Swarm Specialist | Core |
| 8 | Integration Architect | Integration |
| 9 | Performance Engineer | Integration |
| 10 | CLI Developer | Integration |
| 11 | Hooks Developer | Integration |
| 12 | MCP Specialist | Integration |
| 13 | Project Coordinator | Management |
| 14 | Documentation Lead | Management |
| 15 | DevOps Engineer | Management |
hive-mind spawn (high-level launcher)
For most use cases you don’t need to callswarm init and swarm start separately. hive-mind spawn is the one-liner that picks topology, deploys agents, and hands off to Claude Code:
swarm init --topology hierarchical followed by swarm start --objective "<objective>" --strategy specialized.
