Skip to content
This repository was archived by the owner on Apr 11, 2026. It is now read-only.

Commit 0b417d7

Browse files
committed
agents: add Phase 2.3 plan alignment check to worker
- New Phase 2.3 between Phase 2 (Implement) and Phase 2.5 (Verify & Fix) - Checks implementation scope against epic spec for drift - Minor drift noted in evidence, major drift escalated via Spec conflict protocol - Lightweight 30-second gate, not a full re-review Task: fn-136-borrow-agent-skills-patterns-anti.6
1 parent 3552f14 commit 0b417d7

1 file changed

Lines changed: 21 additions & 0 deletions

File tree

agents/worker.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,6 +413,27 @@ The main conversation will resolve the conflict and re-dispatch you (or update t
413413
- Required API endpoint already exists with different signature
414414
<!-- /section:core -->
415415
416+
<!-- section:core -->
417+
## Phase 2.3: Plan Alignment Check
418+
419+
Quick sanity check — did implementation stay within plan scope?
420+
421+
1. Re-read epic spec: `<FLOWCTL> cat <EPIC_ID>`
422+
2. Compare implementation scope against epic's scope section:
423+
- Files changed match expected files in task spec?
424+
- No features added beyond what spec described?
425+
- No architectural changes not covered in the plan?
426+
3. If drift detected:
427+
- **Minor** (extra helper, renamed file): note in evidence as `"plan_drift": "<description>"`
428+
- **Major** (new feature, changed architecture, different approach): send protocol message:
429+
```
430+
Spec conflict: <TASK_ID> — implementation diverged from plan.
431+
Drift: <description of what changed and why>
432+
```
433+
434+
**This is a 30-second check, not a full re-review.** Read the spec, glance at your diff, note any drift. Then proceed to Phase 2.5.
435+
<!-- /section:core -->
436+
416437
<!-- section:core -->
417438
## Phase 2.5: Verify & Fix
418439

0 commit comments

Comments
 (0)