๐๏ธ Foreground single-turn modes ยท Mother orchestrator
OBBLIGATORIO leggere prima di partire una sessione orchestrator. Dichiara esplicitamente in quale modalitร sei (post pre-flight check) e quale scope รจ realistico nel turno corrente.
Premise
Una Mother session Claude Code puรฒ girare in 2 contesti molto diversi:
| Contesto | Caratteristiche | Scope realistico |
|---|---|---|
| Background-parallel (es. Claude Agent SDK orchestrator + spawn process Child via subprocess o cloud) | Mother + N Child realmente paralleli ยท ogni Child รจ proprio processo ยท Mother riceve task result via IPC ยท 8h wall-clock realistici ยท context budget per-Child indipendente | Full kit ยท 4 packages full implementation + retrofit + DB migration + L1-L10 quality gates |
| Foreground single-turn (Claude Code interactive ยท single conversation) | Tutto consuma context budget condiviso ยท Task tool spawna subagent ma in-conversation ยท realistic ~2-4h work (NOT 8h) prima di context pressure | Scope-reduced ยท contracts FULL + skeleton packages + ADR + CI scope-reduced + DRAFT PR per founder review |
Default Claude Code interactive = foreground single-turn. Background-parallel richiede setup esplicito (orchestrator process esterno).
3 Modes pre-definite
Mother DEVE dichiarare in ACK quale Mode รจ attiva. Pre-flight check guida la scelta.
Mode A ยท Full-kit (background-parallel)
Quando:
- Pre-flight GREEN (zero drift)
- Setup orchestrator confermato (agent SDK ยท spawn Child esterni ยท IPC funzionante)
- Founder ha standing autonomy v2 + scope NON include build-manager/lockfile/deploy-target change (gating 2ยฐ livello clean)
- Time budget 8h wall-clock disponibile (non turno chat)
Cosa fa:
- Esegue kit integralmente come scritto
- Spawna Child via Task tool / orchestrator API
- Auto-merge PR via
gh pr merge --auto --squash - Aggiorna BOS auto-pipeline al termine
Output:
- N PR mergiate ยท prod deploy live ยท BOS updated ยท quality_report archived ยท memory updated
Mode B ยท Scope-reduced (foreground single-turn) โ DEFAULT
Quando:
- Pre-flight YELLOW (drift minore ยท fix inline OK) OR GREEN ma sessione interattiva foreground
- Founder รจ AFK o vuole DRAFT PR per review (no auto-merge unbounded)
- Time budget realistico ~2-4h conversation
- Scope include parti hard-to-revert (build-manager/lockfile/deploy change) โ escludile
Cosa fa:
- Esegue parte additive-safe del kit (contracts FULL + skeleton packages + CI scope-reduced + ADR + tooling)
- Crea DRAFT PR per founder review (NO auto-merge)
- Deferre parti hard-to-revert a sessione retrofit dedicata con UAT
- Documenta scope reduction in ADR-NNN-scope-reduction.md
- Aggiorna BOS status.json + decisions-log + nuovo action_item retrofit-deferred
Output:
- 1 DRAFT PR mergeabile post-founder-review ยท ADR scope reduction ยท BOS handoff ยท memoria pattern_learned
Mode C ยท Mini (contracts-only ยท fast)
Quando:
- Pre-flight RED (mismatch critici)
- Founder vuole solo "salvare il salvabile" prima di replan
- Time budget <1h
- Foundation kit utile ma non urgente
Cosa fa:
- Commit solo contracts/types + ADR seedati come "inert scaffold"
- Nessun packaging ยท nessun CI ยท nessun retrofit
- BOS action_item
<session>-replan-neededcon scope dettagliato - Handover per nuova sessione fresca con kit aggiornato
Output:
- 1 PR (DRAFT o merge se trivial) con contracts inert + ADR ยท zero implementation
Decision matrix
| Pre-flight verdict | Founder presente? | Scope include hard-to-revert? | Mode |
|---|---|---|---|
| GREEN | yes (UAT possible) | no | A full-kit |
| GREEN | AFK | no | A full-kit (auto-merge v2 covers) |
| GREEN | yes/AFK | yes (build-manager/lockfile/deploy) | B scope-reduced (defer hard-to-revert) |
| YELLOW | yes | any | B scope-reduced + propose Mode A escalation |
| YELLOW | AFK | any | B scope-reduced (default safer) |
| RED | yes | any | AskUserQuestion Option A/B/C |
| RED | AFK | any | C mini + replan handover |
ACK template per Mode
Mother ACK 5-line DEVE includere riga "Mode" esplicita:
ACK 5-line ยท Mother orchestrator
1. <task_spec> rephrased
2. Top 3 rischi compressi
3. Confidence completion N% in Mode X
4. Decisione zona grigia presunta (con motivo)
5. **Mode <A|B|C> ยท pre-flight verdict <GREEN|YELLOW|RED>** ยท ๐ START Fase 0 ETA <X>min
Se Mode B selezionata (default foreground): includi anche elenco esplicito "Deferred to retrofit session" delle parti hard-to-revert non eseguite.
Riferimenti
00-preflight-check.sh(template) ยท da personalizzare per ogni kit- BOS memoria
feedback_session_kit_premise_drift.mdยท 2026-05-17 - BOS memoria
feedback_autonomous_window_auto_merge.mdv3 ยท 2ยฐ livello gating - BOS
ops/operating-protocol-orchestrator.mdยง Lessons-Learned 2026-05-17 - Multiverbe
docs/adr/006-pms-foundation-isolated-scope-reduction.mdยท caso reale Mode B applicato - Decisions log 2026-05-16 v5 ยท scope reduction + 3 lessons learned origine