KB-58EB

dot-iu-cutter v0.5 — Constitution Status-Marker Amendment Rollback Draft (exact 2-row DELETE; no CASCADE; DO NOT EXECUTE)

5 min read Revision 1
dot-iu-cutterv0.5constitution-fixturestatus-marker-amendmentrollbackcompensationauthoring-onlynot-executedno-cascadedieu442026-05-18

dot-iu-cutter v0.5 — Constitution Status-Marker Amendment Rollback Draft

Phase: v0_5_constitution_status_marker_amendment_authoring · Nature: DML_authoring_only / no_execution · Date: 2026-05-18 Inverts: …-constitution-status-marker-amendment-DML-draft-2026-05-18.sql.md (exactly 2 rows: 📝→draft, ⛔→obsolete).

⚠️ GATING BANNER — DO NOT EXECUTE

phase: status_marker_amendment_rollback ; sql_executed: none ; cascade_used: false
rollback_executed: false ; execution_authorized: false              # QG2
self_advance: PROHIBITED ; decision_authority: GPT / User ONLY

1. Path doctrine for this table

cutter_governance.grammar_profile_status_marker is a thin mapping table with NO lifecycle column (confirmed live; WS-Q5 seed-rollback doctrine explicitly notes "child tables without a lifecycle column … retire via parent grammar_profile + supersede"). Therefore:

PATH_R-A  exact-inverse DELETE  -> applicable & preferred (no lifecycle col to retire)
PATH_R-B  lifecycle deactivate  -> NOT APPLICABLE to this table (no lifecycle column)
PATH_R-C  forward compensation  -> escalation alternative if R-A pre-probe fails
hard_delete_default: NO in general; HERE the rows are a known, exact, unreferenced
  2-row classification set, so exact DELETE is the correct inverse (data-only).

2. Pre-probe (read-only; ALL must hold for PATH_R-A) — DO NOT EXECUTE

-- R-A eligibility: the 2 target rows exist exactly as inserted, and there is
-- no downstream reference to status markers.
SELECT marker, maps_to
FROM   cutter_governance.grammar_profile_status_marker
WHERE  grammar_profile_ref='incomex-architecture-constitution-v4'
  AND  marker IN ('📝','⛔');
-- EXPECT exactly 2 rows: ('📝','draft') and ('⛔','obsolete').

-- No downstream consumers of markers physicalized yet (markers are referenced
-- only at parse/classification time; there is no FK child on this table):
SELECT count(*) FROM cutter_governance.source_document_registry;          -- expect 0
SELECT count(*) FROM cutter_governance.source_document_version_registry;  -- expect 0
-- AND profile still present (parent unchanged):
SELECT 1 FROM cutter_governance.grammar_profile
 WHERE grammar_profile_ref='incomex-architecture-constitution-v4';        -- expect 1

Any deviation (rows differ, count > expected, downstream rows present, profile absent) ⇒ do NOT run R-A; ESCALATE to GPT/User (PATH_R-C). Path decision is a runtime determination at a future separately-authorized phase; the Agent does not pre-decide.

3. PATH_R-A — exact-inverse DELETE, scoped, NO CASCADE (DO NOT EXECUTE)

BEGIN;

DELETE FROM cutter_governance.grammar_profile_status_marker
WHERE  grammar_profile_ref = 'incomex-architecture-constitution-v4'
  AND  marker  IN ('📝','⛔')          -- U+1F4DD / U+26D4 exact UTF-8
  AND  maps_to IN ('draft','obsolete');-- belt-and-braces: only the inserted mapping

-- Guard: this WHERE can match AT MOST the 2 amendment rows. It can never match
-- ('✅','enacted') or ('📋','controlled_draft') — those markers are not in the
-- IN-list. No CASCADE. No other table touched.
COMMIT;

-- Post-state: profile back to its pre-amendment 2 rows (✅ enacted,
-- 📋 controlled_draft); grammar_profile / levels / source_family UNCHANGED;
-- zero data loss (removed rows were exactly the known 2-row bootstrap delta).

4. PATH_R-C — forward compensation (only if R-A pre-probe fails; DO NOT EXECUTE)

trigger: pre-probe (§2) shows altered/extra rows, or any downstream marker
  consumer exists, or profile mutated.
action:
  - DO NOT hard-delete under ambiguity, DO NOT CASCADE.
  - Quarantine further status-marker writes for this profile.
  - Re-issue a corrected mapping via a fresh, separately sovereign-gated cycle
    (supersede semantics), NOT an in-place destructive fix.
  - ESCALATE to GPT / User with the exact observed row set.
note: there is no `lifecycle` column on this table, so a "deactivate/retire"
  rollback is not expressible here; supersession is handled at the parent
  grammar_profile level if the whole profile must be retired.

5. Statements

  • QG2: nothing executed. Exact-inverse DELETE is scoped to the 2 amendment rows by both marker and maps_to; ✅/📋 are unreachable by the predicate (QG4). No CASCADE anywhere.
  • Lifecycle-retire path documented as not applicable (table has no lifecycle column); R-C supersession + escalation is the non-destructive alternative.
  • No source_document(_version) write, no schema/GRANT/index/Directus/vector change, no dry-run/CUT/VERIFY, no deploy, no git commit, no self-advance.
  • Self-advance PROHIBITED — doc 2 of 4; STOP after package → route GPT/User command-review.

Companion: status-marker-amendment-DML-draft, status-marker-amendment-verification-plan, status-marker-amendment-authoring-report.

Back to Knowledge Hub knowledge/dev/laws/dieu44-trien-khai/v0.5-constitution-status-marker-amendment-authoring/dot-iu-cutter-v0.5-constitution-status-marker-amendment-rollback-draft-2026-05-18.sql.md