agent-teams
FreeNo executable scriptsNot checkedCoordinates Claude agent teams over a filesystem protocol. Use for parallel agents with task dependencies.
by athola★ 358 GitHub starsAbout this skill
Agent Teams Coordination
Overview
Claude Code Agent Teams enables multiple Claude CLI processes to collaborate on shared work through a filesystem-based coordination protocol. Each teammate runs as an independent claude process in a tmux pane, communicating via JSON files guarded by fcntl locks, with no database, daemon, or network layer.
This skill provides the patterns for orchestrating agent teams effectively.
When To Use
- Parallel implementation across multiple files or modules
- Multi-agent code review (one agent reviews, another implements fixes)
- Large refactoring requiring coordinated changes across subsystems
- Tasks with natural parallelism that benefit from concurrent agents
When NOT To Use
- Single-file changes or small tasks (overhead exceeds benefit)
- Tasks requiring tight sequential reasoning (agents coordinate loosely)
- When
claudeCLI is not available or tmux is not installed
Prerequisites
# Verify Claude Code CLI
claude --version
# Verify tmux (required for split-pane mode)
tmux -V
# Enable experimental feature (set by spawner automatically)
export CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1
Protocol Architecture
~/.claude/
teams/<team-name>/
config.json # Team metadata + member roster
inboxes/
<agent-name>.json # Per-agent message queue
.lock # fcntl exclusive lock
tasks/<team-name>/
1.json ... N.json # Auto-incrementing task files
.lock # fcntl exclusive lock
Design principles:
- Filesystem is the database: JSON files, atomic writes via
tempfile+os.replace - fcntl locking: Prevents concurrent read/write corruption on inboxes and tasks
- Numbered tasks: Auto-incrementing IDs with sequential file naming
- Loose coupling: Agents poll their own inbox (no push notifications)
Quick Start
1. Create a Team
# Programmatic team setup (via MCP or direct API)
# Team config written to ~/.claude/teams/<team-name>/config.json
The team config contains:
name,description,created_at(ms timestamp)lead_agent_id,lead_session_idmembers[]: array of LeadMember and TeammateMember objects
2. Spawn Teammates
Each teammate is a separate claude CLI process launched with identity flags:
claude --agent-id "backend@my-team" \
--agent-name "backend" \
--team-name "my-team" \
--agent-color "#FF6B6B" \
--parent-session-id "$SESSION_ID" \
--agent-type "general-purpose" \
--model sonnet
See modules/spawning-patterns.md for tmux pane management and color assignment.
3. Create Tasks with Dependencies
{
"id": "1",
"subject": "Implement API endpoints",
"description": "Create REST endpoints for user management",
"status": "pending",
"owner": null,
"blocks": ["3"],
"blocked_by": [],
"metadata": {}
}
See modules/task-coordination.md for state machine and dependency management.
4. Coordinate via Messages
{
"from": "team-lead",
"text": "API endpoints are ready for integration testing",
"timestamp": "2026-02-07T22:00:00Z",
"read": false,
"summary": "API ready"
}
See modules/messaging-protocol.md for message types and inbox operations.
Coordination Workflow
agent-teams:team-created: Initialize team config and directoriesagent-teams:teammates-spawned: Launch agents in tmux panesagent-teams:tasks-assigned: Create tasks with dependencies, assign ownersagent-teams:coordination-active: Agents claim tasks, exchange messages, mark completionagent-teams:team-shutdown: Graceful shutdown with approval protocol
Crew Roles
Each team member has a role that determines their capabilities and task
compatibility. Five roles are defined: implementer (default), researcher,
tester, reviewer, and architect. Roles constrain which risk tiers an
agent can handle. See modules/crew-roles.md for the full capability matrix
and role-risk compatibility table.
Team Formation
For mission-level team sizing, use the Team Formation rules
from references/team-formation.md. This defines:
- Role definitions: Coordinator (mission lead), Agents (task owners), Reviewer (adversarial challenger)
- Team sizing rules: Simple (1), Moderate (2-4), Complex (5-7), Critical (5-10)
- Maximum team size: 10 agents (coordination overhead limit)
- File ownership rules: Prevent conflicts with clear ownership
See references/team-formation.md for full team sizing
guidance and example team formations.
Health Monitoring
Team members can be monitored for health via heartbeat messages and claim expiry. The lead polls team health every 60s with a 2-stage stall detection protocol (health_check probe and 30s wait). Stalled agents have their tasks released and are restarted or replaced following the "replace don't wait" doctrine. See `modules/health-moni
Install agent-teams in Claude Code & Claude Desktop
Sign up to install this skill
Create a free account to reveal the install command and save the skill to your library.
- Reveal the one-line install command
- Save skills to your synced library
- Get notified when skills update
Allowed tools
Tools this skill is permitted to call.
No restriction — this skill can use any tool.
Bundled files
FAQ
What does the agent-teams skill do?
Coordinates Claude agent teams over a filesystem protocol. Use for parallel agents with task dependencies.
How do I install the agent-teams skill?
Copy the skill folder into ~/.claude/skills (the Claude Code tab above does this in one command), or install it as a plugin.
Does the agent-teams skill run scripts?
No, this skill is instructions only (SKILL.md) with no executable scripts.
Related skills
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
by Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
by Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
by Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
by Anthropic