CClaude Code Catalog
All Patterns

Multi-Agent Team Collaboration

AgentAdvanced

Define agent roles in CLAUDE.md so each Claude Code instance operates with a distinct responsibility -- architect, implementer, reviewer, tester. Use git worktrees to isolate each agent's workspace, then merge results through a coordinator agent that resolves conflicts and validates integration.

multi-agentcollaborationworktreedelegationorchestration

Pattern Code

# CLAUDE.md — Multi-Agent Team Configuration ## Agent Roles ### Architect Agent (tmux pane 0) You are the architect agent. Your responsibilities: - Design module boundaries and interfaces - Write type definitions and API contracts - Create architectural decision records in docs/adr/ - Do NOT implement business logic ### Implementer Agent (tmux pane 1-2) You are an implementer agent. Your responsibilities: - Implement modules according to specs in docs/adr/ - Follow existing code style strictly - Write unit tests alongside implementation - Do NOT modify public interfaces without architect approval ### Reviewer Agent (tmux pane 3) You are the reviewer agent. Your responsibilities: - Review all changes in the feature branch - Check for consistency with architecture docs - Verify test coverage meets 80% threshold - Flag any security or performance concerns ## Orchestration Script ```bash #!/bin/bash # Launch agent team via tmux SESSION="agent-team" tmux new-session -d -s $SESSION # Architect in pane 0 tmux send-keys -t $SESSION:0 \ 'cd $(git worktree add .worktrees/architect -b feat/arch) && \ claude -p "Read docs/spec.md and create interface definitions"' Enter # Implementer 1 in pane 1 tmux split-window -h -t $SESSION tmux send-keys -t $SESSION:0.1 \ 'cd $(git worktree add .worktrees/impl-1 -b feat/impl-1) && \ claude -p "Implement module-a per docs/adr/001.md"' Enter # Implementer 2 in pane 2 tmux split-window -v -t $SESSION:0.1 tmux send-keys -t $SESSION:0.2 \ 'cd $(git worktree add .worktrees/impl-2 -b feat/impl-2) && \ claude -p "Implement module-b per docs/adr/002.md"' Enter # Reviewer in pane 3 tmux split-window -v -t $SESSION:0.0 tmux send-keys -t $SESSION:0.3 \ 'claude -p "Watch for new commits on feat/* branches and review each"' Enter ```

Copy this pattern into your project configuration to implement.

Terminal Preview

Multi-Agent Team Collaboration

About Multi-Agent Team Collaboration

Claude Code patterns are proven architectural designs and workflow structures that help you tackle complex development scenarios. Multi-Agent Team Collaboration is a Agent pattern at the Advanced level that provides a tested, repeatable approach you can adapt to your projects for more efficient and consistent results.

Related Patterns