Branch H — Next Implementation Plan + 5 Macro Prompts (2026-05-29)
Branch H — Next Implementation Plan + Macro Prompts
Doc 08 (2026-05-29)
1. Sequenced plan
| Step | Goal | Depends on | Risk |
|---|---|---|---|
| M1 | Fix IU design-vs-live bugs (G2 autowire; reconcile reconstruct/axis) | — | low (additive) |
| M2 | Add 8 missing DOTs + Đ35-register IU DOT layer (paired Tier-A) | M1 | low (catalog rows additive) |
| M3 | Close vector reconcile gap (PG↔Qdrant + DOT-ify reindex) | M2; needs Qdrant read path | med (needs apply/read channel) |
| M4 | Implement MOW design sub-registry (extend workflow_* + IU bindings; migrate inline text) | M1–M2; human-org-role law for mutating UI | med (migration + APR) |
| M5 | First read-only UI proof surface (treeview + traffic-light + drilldown) | M4 (read-only slice) | low (render-only) |
| → | Return to 4 Mothers runtime | M1–M5 + surveys + authority packs | gated |
Ordering rationale: fix the one real bug (M1/G2) first; make IU fully DOT-operable (M2) so agents stop hand-writing SQL; only then tackle vector observability (M3, needs a channel this session lacked); build the workflow design registry (M4) on a clean DOT+IU base; prove it read-only in UI (M5) before any runtime.
2. Macro prompts (paste-ready)
MACRO 1 — IU_DESIGN_LIVE_BUGFIX_G2_AUTOWIRE_AND_DOC_RECONCILE
Read-only-first, then minimal reversible commit. Hard Gate 0 (contabo/postgres/directus,
context_pack_readonlyread;ssh contabo→docker exec -i postgres psql -U workflow_admin -d directusapply). Close G2: wirefn_iu_post_cut_axis_materializeintofn_cut_complete(or an event subscriber oncut.completed) so axes B/C auto-refresh after a cut; dress-rehearse in BEGIN..ROLLBACK, author rollback, COMMIT small, verify in a fresh connection that a test cut auto-materializes axes. Add a Tier-A verify (dot_iu_post_cut_verify). Reconcile design docs: mark G1 (split/merge review_decision_id) CLOSED-live and documentfn_iu_reconstruct_sourcein the design. Forbidden: no gate flips, no 4 Mothers, no UI. Snapshot entry==exit except the intended wiring. Output: bugfix evidence doc + updated gap matrix.
MACRO 2 — IU_DOT_COVERAGE_CLOSE_AND_DIEU35_REGISTER
Add the 8 missing IU DOTs as Tier-B + paired Tier-A: reconstruct, emit, capture-status, route-worker, dlq-replay, relation-assert (ABox, provenance-or-quarantine Đ39, honor
kg_auto_approve_rules), enact (require review_decision_id; never bypassiu_enact.allow_no_review_decision), vector-reindex/verify. Each: register indot_iu_command_catalog(additive), wirefn_dot_iu_command_logaudit, honor existing gates (emit_enabled, routes master, dlq.replay_enabled, vector_sync_enabled). Đ35 integration decision: either register all IU DOTs into the constitutionaldot_toolsSSOT with 11 mandatory fields +paired_dot, OR draft an APR ratifyingdot_iu_command_catalogas a recognised Đ35 sub-registry with a reconcile DOT proving every Tier-B has a Tier-A. Read-only catalog adds; no runtime gate flips. Output: DOT-coverage evidence + Đ35-integration APR draft.
MACRO 3 — IU_VECTOR_RECONCILE_AND_DOTIFY_REINDEX
Resolve the PG↔Qdrant divergence. Obtain a read path to Qdrant (read-only tool or apply-channel
curlto qdrant:6333 collections count). Buildfn_iu_vector_reconcile()+dot_iu_vector_verify(Tier-A) comparingiu_vector_sync_point(status=indexed, Σpoint_count=149) against the liveiu_core_iu_chunkspoint count; surface divergence tosystem_issues(Đ31). DOT-ify reindex (dot_iu_vector_reindex, gated byiu_core.vector_sync_enabledwhich stays FALSE). Document the 149 historical CLI-indexed points. Forbidden: no Qdrant write, no vector_sync_enabled flip (never-flip). Output: vector reconcile report + reconcile DOT + corrected boundary doc.
MACRO 4 — MOW_WORKFLOW_DESIGN_SUBREGISTRY_AND_IU_BINDING_MIGRATION
Implement the MOW design sub-registry per Doc 06 (Hybrid; no MOWD factory row). EXTEND
workflows/workflow_steps/workflow_step_relationswith IU bindings (iu_unit_ref,pinned_iu_version_ref, structuredtrigger_in/out_config,owner_gov_ref=GOV-MOW,automation_level,health_dot,last_review_at). Migrate the 2 live workflows / 70 steps' inlinebpmn_xml/narrative/description/trigger_*_textinto bound IU bodies (build-once/reuse-many). Reuseworkflow_change_requestsfor Kaizen. All changes paper-first → APR (Đ32) → birth (Đ0-G/Đ36); dress-rehearse BEGIN..ROLLBACK. Define def↔run link (read-only projection to workflow_run/step_run). Blocked for mutating UI until the human-org-role law lands. Output: migration plan + first IU-bound workflow design + evidence.
MACRO 5 — WORKFLOW_DESIGN_READONLY_UI_PROOF_SURFACE
Build a read-only UI proof surface over the MOW design sub-registry: treeview (domain→company→dept→specialty→workflow→task from
workflow_categories+ IU axes), traffic-light health (health_dot + system_issues + review-age), filters (status/health/automation_level/owner), drilldown (design→step→bound IU viarender_iu_body→code/sql/dot/event/run). Đ28: Nuxt renders from a PG-registereddesign_templatesentry only; no business logic, no direct PG. Read-only (no mutating actions until human-org-role law). Đ30: real-browser regression test for the new surface. Output: read-only treeview proof + template registration + regression evidence.
3. Carry-forward blockers (unchanged by this campaign)
- Human-org-role law (D-1) — gates mutating UI for both MOW.design and 4 Mothers.
- P-pub warn→block + production review_decision authoring — IU full-production exit conditions.
- Candidate / Tier / Governance-Ops surveys + IU-substrate Gate A — gate any 4 Mothers implementation.