Summary: Multi-agent integration patterns
The three patterns in one screen
Section titled “The three patterns in one screen”Shared origin (default): all agents push to one remote, lead pulls and integrates. Standard team workflow, agent branches visible to all.
Per-agent fork (isolation): each agent has its own remote, lead pulls from each separately. For untrusted agents, external contributors, hard isolation.
Shared worktrees (fast iteration): all worktrees on lead’s machine, nothing pushed until integration final. For solo leads in focused sprints.
Choosing
Section titled “Choosing”- Default? Use shared origin
- Other-human review of in-flight agent branches needed? Use shared origin
- Untrusted or external agents? Use per-agent fork
- Fast solo iteration, lead controls everything? Use shared worktrees
The lead orchestrator’s role
Section titled “The lead orchestrator’s role”- Plan the fleet, define each agent’s scope tightly
- Spawn the fleet, create worktrees, launch agents
- Watch the fleet, periodic
git log --all --graphto catch off-script agents early - Integrate, merge or cherry-pick each agent’s work into integration branch
- Catch semantic conflicts, the unique multi-agent skill (see below)
- Push gate, only the lead pushes integrated work to main
- Cleanup, remove worktrees, delete branches
Semantic conflicts (the new failure mode)
Section titled “Semantic conflicts (the new failure mode)”Code merges cleanly. Tests may pass individually. But the integrated code is BROKEN because two agents had inconsistent mental models (renamings, duplicate utilities, mismatched field names, behavior changes one agent didn’t expect).
Git CANNOT detect these. They cross file boundaries without producing line-level conflicts.
Three layers of defense:
- Tight agent scope, reduce overlap to reduce conflict surface
- Integration tests at each merge step, catches the file-boundary failures
- Lead reads the integrated diff, catches what tests miss
The build gate, non-negotiable
Section titled “The build gate, non-negotiable”The lead-stage build (full-system, after all merges) is the most important guardrail. The Clawless 2026-06-04 sprint: per-agent tests passed cleanly; the lead-stage build caught ~300 latent breakers. Per-agent tests are necessary but not sufficient.
Voice anchor
Section titled “Voice anchor”Git stores snapshots. Every other command is just navigating those snapshots.
Multi-agent integration is just combining snapshots from N branches into one coherent integration snapshot. Git handles the syntactic combination; the lead handles the semantic combination.
What you carry into L15
Section titled “What you carry into L15”L15 (AI-authored commits and PRs) zooms in on individual commits when an AI is the author. Co-authorship conventions. The “Generated with Claude Code” marker. What human review changes when the diff was AI-typed. Release notes.