atcyrus.com | GitHub: ceedaragents/cyrus
Want access to an advanced Claude Code agent built into Linear that you can run anywhere? Try Cyrus.
This folder contains comprehensive documentation of the Claude Code Teammate/Swarm multi-agent coordination feature discovered in the Claude Agent SDK v0.1.72.
The Teammate tool is a partially implemented feature in the Claude Agent SDK that would enable multi-agent coordination through:
- Spawning multiple AI teammates in separate tmux panes
- Team-based task distribution and coordination
- Inter-agent messaging via a file-based mailbox system
- Git worktree isolation for parallel development
- Hierarchical delegation with the "delegate" permission mode
Current Status: ~60% complete - Infrastructure exists, core implementation missing.
- 01-permission-modes.md - All 6 permission modes including "delegate" and "dontAsk"
- 02-teammate-tool-schema.md - Complete tool schema with 13 operations
- 03-task-management.md - Task tools and enablement process
- 04-mailbox-system.md - Complete inter-agent messaging system
- 05-architecture.md - Full feature architecture and design
- 06-what-exists.md - Detailed component inventory
- 07-file-locations.md - Key code locations with line numbers
- 08-modifications-made.md - Changes we made to enable task tools
The source code analyzed is available at:
- Package: @anthropic-ai/claude-agent-sdk v0.1.72
- Main File: cli.js (11MB minified)
- Local Installation:
/Users/x/.npm-global/lib/node_modules/@anthropic-ai/claude-agent-sdk/
A copy of the relevant source sections is included in cli.js.backup in this directory.
- ✅ Task management tools (TaskCreate, TaskGet, TaskUpdate, TaskList) - enabled by us
- ✅ Complete mailbox system with file locking and message persistence
- ✅ Team file system (~/.claude/teams/)
- ✅ Delegate permission mode that filters to coordination tools only
- ✅ Complete tool schema (qgZ) with 13 operations defined
- ✅ Helper functions for team I/O operations
- ❌ Teammate tool object (schema is orphaned - defined but never instantiated)
- ❌ Spawn implementation logic
- ❌ tmux pane creation code
- ❌ Git worktree setup automation
- ❌ UI for teammate count selection (removed from code)
- ❌ Integration between schema and tool registration system
To enable the task management tools we activated:
- Edit
/Users/x/.npm-global/lib/node_modules/@anthropic-ai/claude-agent-sdk/cli.js - Find line 789:
function nU(){return!1} - Change to:
function nU(){return!0} - Run:
claude --permission-mode delegate(requires tmux)
Note: This only enables task tools, NOT the Teammate tool (which requires additional implementation).
This analysis was conducted through systematic code exploration:
- Started with permission mode investigation
- Discovered undocumented "delegate" mode
- Found Teammate tool schema and prerequisites
- Enabled task management system
- Mapped complete mailbox infrastructure
- Identified missing implementation components
Analysis conducted via Claude Code deep investigation session, December 2025.