add delegation mode fallback to matrix rail in kickstart
This commit is contained in:
@@ -84,12 +84,27 @@ Target: [milestone/issue/task]
|
|||||||
Project: [org/repo]
|
Project: [org/repo]
|
||||||
Platform: [Gitea/GitHub]
|
Platform: [Gitea/GitHub]
|
||||||
Branch base: [develop/main]
|
Branch base: [develop/main]
|
||||||
|
Delegation: [native-subagent | matrix-rail-fallback]
|
||||||
Quality gates: [detected commands or "none detected — will ask"]
|
Quality gates: [detected commands or "none detected — will ask"]
|
||||||
Existing state: [docs/tasks.md found / none]
|
Existing state: [docs/tasks.md found / none]
|
||||||
```
|
```
|
||||||
|
|
||||||
Ask the user to confirm or override any detected values.
|
Ask the user to confirm or override any detected values.
|
||||||
|
|
||||||
|
### 1e. Detect delegation mode
|
||||||
|
|
||||||
|
Before orchestration begins, decide delegation mode:
|
||||||
|
|
||||||
|
- **native-subagent**: runtime has reliable subagent/background task primitive
|
||||||
|
- **matrix-rail-fallback**: use deterministic Mosaic rail when native primitive is absent/unreliable
|
||||||
|
|
||||||
|
Fallback commands:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
~/.mosaic/bin/mosaic-orchestrator-matrix-cycle
|
||||||
|
~/.mosaic/bin/mosaic-orchestrator-run --poll-sec 10
|
||||||
|
```
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
## Step 2: Fetch Target Data
|
## Step 2: Fetch Target Data
|
||||||
@@ -209,7 +224,7 @@ You are now the **orchestrator**. Follow the protocol from `~/.mosaic/guides/orc
|
|||||||
4. **Completed issues are closed** in the repo via `"${MOSAIC_HOME:-$HOME/.mosaic}/rails/git/issue-close.sh"`
|
4. **Completed issues are closed** in the repo via `"${MOSAIC_HOME:-$HOME/.mosaic}/rails/git/issue-close.sh"`
|
||||||
5. **tasks.md is the single source of truth** — you are the sole writer
|
5. **tasks.md is the single source of truth** — you are the sole writer
|
||||||
6. **Branch from `develop`** (or whatever was detected/confirmed in Step 1) as the upstream
|
6. **Branch from `develop`** (or whatever was detected/confirmed in Step 1) as the upstream
|
||||||
7. **Max 2 parallel workers** at any time
|
7. **Max 2 active worker tasks** at any time (applies to native and matrix modes)
|
||||||
8. **Two-Phase Completion:** Bulk phase (target 90%), then Polish phase (target 100%)
|
8. **Two-Phase Completion:** Bulk phase (target 90%), then Polish phase (target 100%)
|
||||||
9. **Context threshold (55-60%):** Output handoff kickstart and STOP — do not compact
|
9. **Context threshold (55-60%):** Output handoff kickstart and STOP — do not compact
|
||||||
|
|
||||||
@@ -219,11 +234,13 @@ You are now the **orchestrator**. Follow the protocol from `~/.mosaic/guides/orc
|
|||||||
WHILE tasks remain not-started or in-progress:
|
WHILE tasks remain not-started or in-progress:
|
||||||
1. Find next unblocked task (all depends_on are done)
|
1. Find next unblocked task (all depends_on are done)
|
||||||
2. Update tasks.md: status=in-progress, started_at=now
|
2. Update tasks.md: status=in-progress, started_at=now
|
||||||
3. Spawn worker via Task tool with:
|
3. Delegate worker task with:
|
||||||
- Task details and acceptance criteria
|
- Task details and acceptance criteria
|
||||||
- Branch to work on
|
- Branch to work on
|
||||||
- Quality gate commands
|
- Quality gate commands
|
||||||
- Expected JSON result format
|
- Expected JSON result format
|
||||||
|
- Native mode: runtime Task/subagent primitive
|
||||||
|
- Matrix mode: queue task in `.mosaic/orchestrator/tasks.json` and run `~/.mosaic/bin/mosaic-orchestrator-matrix-cycle`
|
||||||
4. Parse worker result JSON
|
4. Parse worker result JSON
|
||||||
5. Calculate variance: (actual - estimate) / estimate × 100
|
5. Calculate variance: (actual - estimate) / estimate × 100
|
||||||
6. Update tasks.md: status=done/failed, completed_at, used
|
6. Update tasks.md: status=done/failed, completed_at, used
|
||||||
|
|||||||
Reference in New Issue
Block a user