You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CLAUDE.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,13 +6,13 @@ This file provides guidance to Claude Code (claude.ai/code) when working with co
6
6
7
7
Swarm Protocol is a headless MCP server for AI agent team coordination. It solves state synchronization when multiple people work through AI agents (Claude Code, etc.) on the same codebase simultaneously — preventing file conflicts, tracking work in flight, and managing task dependencies.
8
8
9
-
**Status:** Alpha — all 19 MCP tools implemented, integration tests written. See SPEC.md for the full design.
9
+
**Status:** Alpha — all 19 MCP tools implemented, integration tests written. See docs/SPEC.md for the full design.
10
10
11
11
## Philosophy & Positioning
12
12
13
13
This is a **coordination protocol, not a project management tool**. The origin insight: "Jira was built for humans clicking buttons. This is coordination infrastructure for agent-first teams." The problem isn't Kanban or sprints — it's state synchronization when agents are the primary interface.
14
14
15
-
**Key differentiator:** Every existing tool (Claude Code Agent Teams, CCPM, tick-md, Agent-MCP, 1Code, etc.) solves single-developer multi-agent coordination. Swarm Protocol solves multi-human multi-agent coordination across teams. See LANDSCAPE.md for the full competitive analysis.
15
+
**Key differentiator:** Every existing tool (Claude Code Agent Teams, CCPM, tick-md, Agent-MCP, 1Code, etc.) solves single-developer multi-agent coordination. Swarm Protocol solves multi-human multi-agent coordination across teams. See docs/LANDSCAPE.md for the full competitive analysis.
16
16
17
17
When making implementation decisions:
18
18
-**Protocol over product.** Keep it minimal and composable. Resist feature creep toward traditional PM concepts (sprints, boards, velocity, story points).
→ complete_claim "Done — this unblocks intent_xyz"
25
+
↳ intent_xyz status: blocked → open
26
+
↳ Next agent picks it up automatically
27
+
```
28
+
29
+
Zero Slack messages. Zero status meetings. Agents coordinate through shared state.
30
+
31
+
## What This Is
32
+
33
+
A headless coordination layer exposed as an MCP server — the same protocol Claude Code already speaks. No REST API. No dashboard. Agents query it to see what's in flight, claim work, detect file conflicts, and hand off unblocked tasks.
34
+
35
+
This is a **coordination protocol, not a project management tool.** Jira was built for humans clicking buttons. This is state synchronization infrastructure for teams where agents are the primary development interface.
36
+
37
+
The CLAUDE.md integration pattern is as important as the server itself. Agents coordinate automatically without humans configuring anything.
38
+
39
+
## Who Is This For
40
+
41
+
Teams of 2+ developers where AI agents (Claude Code, etc.) are the primary development interface. If your workflow is "open terminal → tell Claude Code what to build → review the PR" and teammates are doing the same thing at the same time — this is the missing layer.
42
+
43
+
**Not for:** solo devs running multiple agents in parallel (tools like [CCPM](https://github.com/automazeio/ccpm) and [1Code](https://www.1code.io/) solve that). Not a Jira replacement. Not a project management tool.
6
44
7
45
## The Problem
8
46
9
-
When multiple people work through AI agents simultaneously:
10
-
- No one knows what's in flight right now
11
-
- Two agents edit the same files and create conflicts
12
-
- Completed work sits idle because no one picks up the next dependent task
47
+
Every existing tool in this space solves **single-player** multi-agent coordination: one developer dispatching 3-5 agents. Useful, but insufficient.
48
+
49
+
Nobody is solving **multiplayer**: multiple humans, each working through agents, across teams. That's not a project management problem — it's a state synchronization problem.
50
+
51
+
What happens without coordination:
52
+
- Two agents edit the same files → ugly merge conflicts
53
+
- Completed work sits idle — no one picks up the next dependent task
13
54
- Context is lost between agent sessions
14
-
-There's no shared state of "done / in progress / blocked"
55
+
-No shared state of what's done, in progress, or blocked
15
56
16
-
Every existing tool solves **single-developer** multi-agent coordination. Nobody is solving: **"We're a team of 8 humans, each working through agents, across multiple repos and teams. How do we stay in sync?"**
57
+
See [LANDSCAPE.md](docs/LANDSCAPE.md) for the full competitive breakdown.
17
58
18
-
This isn't a project management problem. It's a state synchronization problem.
59
+
## Four Primitives
19
60
20
-
## What This Is
61
+
| Primitive | What It Does |
62
+
|-----------|-------------|
63
+
|**Intent**| A unit of desired outcome — not a ticket. Lifecycle: `draft → open → claimed → done`. Has constraints, acceptance criteria, and dependency chains. |
64
+
|**Claim**| "I'm working on this." Tracks which files are being touched. Includes heartbeat — claims with no heartbeat for 30 min get flagged as stale. |
65
+
|**Signal**| Event notification: completion, blocked, conflict, info. When a completion signal fires, dependent intents auto-unblock. |
66
+
|**Context Package**| Everything an agent needs to start work — intent, dependencies, active claims on overlapping files, recent signals, team conventions — assembled in one call via `get_context`. |
- Conflicts are advisory, not enforced — no file-level locking
76
+
- Auth is trust-based in v1 (`claimed_by` is a string the agent passes)
77
+
- Single PostgreSQL instance (designed for <1000 users)
78
+
- Polling via MCP tools, no WebSocket subscriptions
79
+
- Protocol over product — minimal and composable by design
80
+
81
+
## Key Tools
21
82
22
-
A headless coordination layer exposed as an MCP server. Agents query it to see what's in flight, claim work, detect file conflicts, and hand off unblocked tasks — all without human overhead.
83
+
### `check_conflicts` — Prevent file collisions before they happen
23
84
24
-
The "UI" is Claude Code itself. Drop a snippet in your repo's CLAUDE.md and agents coordinate automatically.
**Enable automatic coordination** — copy [`claude-md/COORDINATION.md`](claude-md/COORDINATION.md) into your repo's CLAUDE.md. Agents will automatically check for conflicts, claim work, and signal completions.
63
-
64
-
## How It Works
65
-
66
-
### Four Primitives
67
-
68
-
| Primitive | What It Does |
69
-
|-----------|-------------|
70
-
|**Intent**| Unit of desired outcome. Lifecycle: `draft → open → claimed → done`. Not a ticket — an outcome. |
71
-
|**Claim**| "I'm working on this." Tracks files being touched, includes heartbeat for stale detection. |
72
-
|**Signal**| Event notification — completion, blocked, conflict, info. Flows to whoever needs to know. |
73
-
|**Context Package**| Everything an agent needs to start work, assembled in one call. |
74
-
75
-
### The Coordination Loop
76
-
77
-
```
78
-
Agent starts session
79
-
→ get_team_status (what's in flight?)
80
-
→ claim_work (I'm taking this, here are my files)
81
-
→ check_conflicts (am I stepping on anyone?)
82
-
→ heartbeat (still working, every 10-15 min)
83
-
→ complete_claim (done — this unblocks X, Y, Z)
84
-
```
85
-
86
-
### 19 MCP Tools
171
+
**Enable automatic coordination** — copy [`claude-md/COORDINATION.md`](claude-md/COORDINATION.md) into your repo's `CLAUDE.md`. That's it.
-**Interface:** MCP-native via `@modelcontextprotocol/sdk`
102
-
-**Auth:** Trust-based v1 (agent passes user identifier)
177
+
-**No web UI** — agents and terminal are the interface
178
+
-**No auth** — trust-based identity. Auth layer comes when it needs to.
179
+
-**No real-time subscriptions** — MCP polling is sufficient
180
+
-**No notifications** — Slack/Discord integration is a natural v2 extension
181
+
-**No file locking** — conflicts are advisory by design
182
+
-**No multi-repo** — single repo per team assumed
103
183
104
-
See [SPEC.md](SPEC.md) for the full design. See [LANDSCAPE.md](LANDSCAPE.md) for competitive analysis. See [TESTING.md](TESTING.md) for test architecture, coverage, and assumptions.
184
+
## Looking for Co-Builders
105
185
106
-
## What Makes This Different
186
+
The market for agent-team coordination is tiny today and enormous in 12-18 months. Every team adopting Claude Code, Codex, or similar tools will hit this exact problem the moment they scale past one developer.
107
187
108
-
Every tool in this space — Claude Code Agent Teams, CCPM, tick-md, Agent-MCP, 1Code — solves the **single-player** version: one dev running multiple agents in parallel. That's useful but insufficient.
188
+
This isn't a side project looking for drive-by PRs. It's a category that needs to be built. I'm looking for people who want to **own parts of this protocol** — lead feature areas, review PRs, shape the design.
109
189
110
-
Swarm Protocol solves the **multiplayer** version: multiple humans, each working through agents, across teams. Cross-human conflict detection, dependency chains that auto-unblock, context packages that onboard agents instantly.
190
+
**Where to plug in:**
111
191
112
-
See [LANDSCAPE.md](LANDSCAPE.md) for the full competitive breakdown.
192
+
-**Tool groups** (`src/tools/`) are natural ownership boundaries — each one is a self-contained module with its own tests
193
+
-**The protocol design itself** — the four primitives are v1. What's missing? What's wrong? Open an issue and make the case.
194
+
-**Adapters** — SQLite backend, auth layer, Slack signal forwarding, dashboard read-model. Each is a standalone contribution.
195
+
-**The CLAUDE.md pattern** — better coordination instructions, support for other agents beyond Claude Code
113
196
114
-
## Contributing
197
+
The raw SQL + no-framework design is intentional — fork it, swap PostgreSQL for SQLite, add auth, build custom tools.
115
198
116
-
This is early-stage, building in public. We're looking for **contributors and maintainers** — people who want to own parts of this project, not just submit patches.
199
+
See [CONTRIBUTING.md](CONTRIBUTING.md)for guidelines. Or just open an issue with your idea.
117
200
118
-
Interested in leading a feature area, reviewing PRs, or managing releases? See [CONTRIBUTING.md](CONTRIBUTING.md).
201
+
## Docs
119
202
120
-
The tool groups (`src/tools/`) are natural contribution boundaries. The raw SQL + no-framework design is intentional — fork it, swap PostgreSQL for SQLite, add auth, build custom tools.
203
+
| Doc | What's In It |
204
+
|-----|-------------|
205
+
|[SPEC.md](docs/SPEC.md)| Full protocol design, data model, SQL schema, tool specifications |
206
+
|[LANDSCAPE.md](docs/LANDSCAPE.md)| Competitive analysis — every tool in the space and why this is different |
207
+
|[TESTING.md](docs/TESTING.md)| Test architecture, coverage, assumptions |
208
+
|[COORDINATION.md](claude-md/COORDINATION.md)| Drop-in CLAUDE.md snippet for your repo |
0 commit comments