DUNIN7 · LOOMWORKS · RECORD
record.dunin7.com
Status Current
Path change-requests/cr-2026-205-loomworks-persist-operation-outcome-v0_1.md

DUNIN7-M4 — INFRASTRUCTURE CHANGE REQUEST

CR-2026-205 — Persist the operation outcome on the turn: the one missing structural fact (v0.1)

Version. 0.1 · Date. 2026-08-11 · Author. Claude Code (drafting, from the B-86 scoping) / Marvin Percival (approving). Target. /Users/dunin7/loomworks-engine, branch main. Baseline. Engine 64610b4. CC confirms at Step 0. Companion to. inspection-briefs/loomworks-b86-b87-scoping-report-v0_1 Part 2 (the ruled remedy) and inspection-briefs/loomworks-b86-dependency-remeasurement-v0_1 (record 34c27cc) — where this CR and the briefs disagree, the briefs govern, verified against code. Charter. Autonomous regime. Status. DRAFT — awaiting the gate. Do not execute.


0. Settled — the Operator's rulings, 2026-08-11. Do not re-raise.

  1. This CR persists; it does not route. The B-86 scoping found conversation_turns durably records classified_intent and structured_data, but the operation outcome — denied / approval_card / executed / … — survives only inside prose. This CR makes it a recorded fact on the turn. It proceeds as its own thing, unchanged by the extraction ruling.
  2. The classifier is untouched — deliberately, twice over. The 32-intent change did not rise (the re-measurement's remedy is CR-2026-203's extraction), and feeding this column into the classifier's history block is also not this CR — that would be a classifier-prompt change with the same 32-intent blast radius. The column exists so that future decisions (and forensics — every finding in this arc was resolved by reading stored classifications) have the fact; consuming it is a future CR's question.
  3. No surface change. No backfill — pre-CR turns read null = unrecorded, and null stays meaningful.

1. The design

A. New nullable TEXT column operation_outcome on conversation_turns (own column, the organized_view_citation/CR-2026-204 precedent — a fact about the turn, not a payload the turn produced; structured_data's one-payload slot stays untouched).

B. The value is the discriminator the route already computed — persisted verbatim, never re-derived. Enumerated from code at drafting (pre-flight shape 4), frozen as one frozenset in orchestration (single-source-of-truth discipline), asserted at the write:

C. Write site: the step-7 companion record_turn in operator_converse, via a small pure derive_operation_outcome(route_result) — one function, unit-testable without the pipeline. record_turn gains the kwarg; membership in the frozenset asserted there (TEXT column, no DB CHECK — the vocabulary will grow with intents; the code-level single source is the enforcement surface, and a test pins that every discriminator literal in router.py is in the set).

2. Consequences named, so they are chosen

3. Tests — each observed failing first, per the standing discipline

derive_operation_outcome: one case per §1B row, including both split rules (a failed execution derives executed_then_failed, never executed) and the null rows. Write path: outcome persisted on a delegated turn; null on a general_conversation turn; assertion rejects a value outside the frozenset. Vocabulary completeness: the suite test collecting router discriminator literals against the frozenset (observed failing by removing a value first). Migration up/down. Existing turn-recording suites re-run explicitly.

4. seed-mutability impact

Kind C expected: the discriminator is computed by routes from delegation/memory state, not the seed; the write is a turn column. Checked at Step 1 across every §1B source site. A null finding is an entry; recorded either way.

5. Build steps

| Step | What | Mode | |---|---|---| | 0 | Pre-flight — baseline 64610b4, tree clean. | Auto | | 1 | Verify §1B enumeration complete against router (briefs govern); tests written and observed failing. | Auto | | 2 | Migration; frozenset; derive_operation_outcome; record_turn kwarg; step-7 wiring. | Auto | | 3 | Full suite; ruff; mypy; migration up/down verified. | Auto | | 4 | Eye-test: one delegated turn and one conversational turn live; column read back (standing eye-test discipline). | Auto | | A | Checkpoint. | Checkpoint | | 5 | Tag cr-2026-205-persist-operation-outcome. Push. Watch the CI run and report its result. | Auto |

6. Acceptance gate

  1. §1B enumeration verified complete at Step 1; the completeness test in the suite.
  2. Both split rules pinned: no failed execution ever persists as executed/approved.
  3. Null discipline: conversational turns null; no backfill in the diff.
  4. No classifier contact anywhere in the diff — no prompt change, no history-block change (§0.2).
  5. Suite green (zero failures); both gates clean; push run watched and reported; eye-test read back.
  6. seed-mutability recorded.

7. Kickoff prompt


Execute CR-2026-205 v0.1 at change-requests/cr-2026-205-loomworks-
persist-operation-outcome-v0_1.md in loomworks-record. Confirm the CR
number and baseline first.

§0 is settled: persist, don't route. If the diff touches the
classifier's prompt or its history assembly, stop — that is the
ruled-out half.

The value is the discriminator the route computed, verbatim, with the
two split rules (executed_then_failed / approved_then_failed) — never
re-derived, never prose-parsed. Step 1's enumeration-completeness
check is the fifth-wrong-premise check; run it against the router
before the migration is written.

Each test observed failing first.

DUNIN7 — Done In Seven LLC — Miami, Florida CR-2026-205 — persist the operation outcome — v0.1 — 2026-08-11 The server knew what happened; now the record does too.