Project Details
The problem
A single AI coding session is genuinely useful for one focused task. The harder problem is real infrastructure work that spans several systems at once: a security fix that needs verifying against a live database, a new feature that needs a background service plus a frontend plus a network route, several unrelated projects that all need attention the same evening, without either (a) one session serializing everything and taking all night, or (b) several sessions stepping on each other’s work, silently diverging from what actually got deployed, or taking a destructive action nobody actually approved.
What the pattern looks like in practice
One orchestrating session, several worker sessions, each on its own git branch. The orchestrator dispatches a scoped task with real context (what changed, why, what’s already been tried) rather than a one-line instruction. Each worker session branches before touching anything, does real work, and reports back, including honest status on what’s tested versus merely written, and what it could not verify itself.
A hard, structural line between “propose” and “commit to shared state.” Every worker session can branch, build, and run read-only verification against real systems freely. Actions that touch shared or production state (merging to a main branch, deploying, writing to a live database outside an explicitly pre-approved narrow class of changes) are a separate, deliberately harder step. When a worker session hits that line, the correct behavior is to stop and report the block immediately, not to find a workaround. This is enforced by the coding tool’s own permission layer, not by an instruction a session could talk itself out of. It held in practice across a full night of real work: a session correctly declined to push a security fix live on its own, reported the block, and an authorized path completed it minutes later.
Verification is independent, not inherited. A worker session doesn’t take another session’s “this is fixed” or “this is deployed” at face value. The recurring, deliberate discipline: check the live system directly: query the real database schema, hit the real deployed endpoint, read the actual bound configuration, never just trusting a status claim, even a confident one from a trusted collaborator. This caught a real case where a security fix had been merged but a required database migration to make it functionally live had not, before that gap became a real incident rather than a caught one.
Technology choices, and why
Branch-per-workstream instead of one shared working tree. Several sessions touching the same repository at once, without isolation, is how work gets silently overwritten. Every real task starts with its own branch; merging back is a distinct, later, verified step, never a same-session “looks done” merge.
Cross-session messaging over a shared task queue. Delegation carries real context (what was tried, what’s already known, what’s still open) rather than a bare task ID, because a fresh session with no memory of prior attempts re-derives the same dead ends a session with context would skip.
Independent, read-only verification via each provider’s own API rather than re-deploying to “just check”: cheaper, faster, and it catches the specific failure mode where code is right but the environment around it (a secret, a migration, a bound service) isn’t, which a code review alone can’t see.
Outcome
Over one real working night this pattern coordinated several independent, real workstreams: security fixes verified against live infrastructure before and after deployment, a new feature built end-to-end from a box-side service through a network path to a browser UI, and a data-linking feature integrating two real external providers, with every production-affecting step correctly routed through an authorized path rather than taken unilaterally, and every completion claim independently re-checked against real state rather than assumed. No production incident, no unauthorized production write, across the whole session.
The pattern’s value is the discipline it enforces: stop and ask, verify independently, and keep humans on exactly the decisions that are theirs. That line held across the whole session because it was designed in, not hoped for.