Section composite gate + nesting + zero-as-reset
Goal
- Model mission/criteria as work items under one section composite gate.
- Refactor existing mission/criteria/parity/leak checks into those proofs.
- Use generic invocation + subtree/return gates instead of
run_sub_sm. - Make
/zeroreset proof/review state + generation while keeping deliverables.
Self-hosting constraint
Run off-path on the new engine before cutover. Keep verify_and_complete_v7 on the old path until retirement.
Implementation sketch
section.json: enter through fixedreconcileover the plan API;all_work_items_completeis the sole domain-proof leaf; section completion composes it with subtree quiescence and all child returns folded.- Author the mission/criteria-as-work_items: technical-mission (test_all + scope-aware L9/L10), non-technical/functional-mission (kind:functional end-state), success-criteria work_items — each proven by the work-item SM; fold the existing
MISSION_FULFILLMENT/CRITERIA_SATISFIED/per-node checks into their proofs. plan_workflow.jsondomain workflow: fixed plan-derivedreconcileentry, plan/section/work-item composition, and generic invocation frames; plan gate includes domain proof + subtree/return gates, while any frame cursor is receipt-bound and non-authoritative. The distinct filename prevents confusion with the authoritative domain-artifactplan.json.reset_zeroaction: clear status/proofs/criteria/reviewed+hash, keep deliverable; each selected section receives JIT/review-sectionthroughreview_as_phasebefore work.- Carry plan/section/work-item identity through nested frame capabilities; child ContextAssembly cannot widen parent scope.
- Keep Prompt/Rule/Reminder definitions intact across zero; re-evaluate selectors from reset state.
Spec references
- plans/workflow-engine-rework/spec/workflow-state-machines.md sec 4 (section composite gate), sec 5 (nesting), sec 6 (zeroing). Research:
verify_and_complete_v7already enforces MISSION_FULFILLMENT + CRITERIA_SATISFIED.
Work items
-
section.json: fixed plan-derived reconcile entry; domain proof = all_work_items_complete; completion = domain proof + subtree_quiescent + all_child_results_folded - Author mission/criteria-as-work_items; fold existing MISSION_FULFILLMENT/CRITERIA/per-node checks into their proofs
-
plan_workflow.jsondomain workflow with fixed plan-derived reconcile entry + generic invocation composition; author the plan-wide functional-mission and plan-wide success-criteria work_items (parity with the section-level mission/criteria fold in w-6882a0f1) so plan domain completion is all sections plus these plan-wide work_items, per spec sec 5’s PLAN composition; plan-wide domain/subtree/return gate; no free-standing frame workflow state and no filename collision with the domain-artifact plan.json -
reset_zeroaction: clear status/proofs/criteria/reviewed+hash, keep deliverable; require per-section JIT review_as_phase and prohibit plan-wide fan-out - Thread root/frame scope through plan, section, and work-item domain SMs; require subtree quiescence/return folding and stale-return rejection after zero
Test strategy / acceptance
Matrix: composite gate x nested frame scope x zero reset. Pins: every ordinary plan/section entry reconciles from plan state; unbound/stale cursors reject; incomplete mission blocks; child cannot target sibling/parent plan; zero clears evidence/review but preserves control definitions and reselects reminders from current state.
Intel dossier — pointer and tier disposition
Dossier: section-gate-nesting-zero--s-4575d22d.intel.md (this section’s content/intel/ sidecar)
Read that dossier from line 1 through EOF before acting on this section. This block is a pointer and an audit record, never a substitute: not the BLUF, not a summary, not selected tiers.
| Dossier tier | Title | Lines | Disposition | Where / why |
|---|---|---|---|---|
| 0 | 0. Bottom line up front | 43 | pending | |
| 1 | 1. The target, verbatim | 41 | pending | |
| 2 | 2. The terrain — symbols in the objective area (with files) | 76 | pending | |
| 3 | 3. Code-graph recon | 164 | pending | |
| 3D | 3D. Diagnostic / observability surface | 30 | pending | |
| 3H | 3H. Hygiene constraints the downstream work inherits | 26 | pending | |
| 4 | 4. Cluster / family — the sections that consume this terrain | 30 | pending | |
| 5 | 5. Conformance audit — graph-dark, source-confirmed duplication | 37 | pending | |
| 6 | 6. Plan ownership — the plan-symbol bridge does not reach this terrain | 31 | pending | |
| 7 | 7. Prior art — LOW SIGNAL, and that is the finding | 17 | pending | |
| 8 | 8. Sentiment — LOW SIGNAL | 20 | pending | |
| 9 | 9. Declared coverage gaps — what is dark, and why | 28 | pending | |
| 10 | 10. Recommended recon entry points (ordered) | 24 | pending |