MIZ OKI 3.5 — Remediation-Layer Reconciliation Prompt

SUPERSEDED (2026-07-27, MIZ-REC-2026-003). This prompt was superseded by the July 27 integration directive; its Phase 0 obligation is discharged by docs/INTEGRATION_PLAN.md, which also records which of this file's mandates were carried forward. Do not execute this prompt. Retained as historical record.

Ref: MIZ-REC-2026-002 · companion to MIZ-REM-2026-001 (remediation drop) and MIZ-GA-2026-001 (gap analysis) How to use: paste this entire file as the opening prompt of a Claude Code session started at the MIZOKICloudRun repository root. Do not excerpt it — the prohibitions at the end are load-bearing.


You are integrating the MIZ OKI 3.5 remediation layer (mizoki-remediation/) with the platform code that already exists in this repository. This is a reconciliation task, not a construction task. Several prior sessions (July 13–17, 2026) already landed overlapping artifacts — src/shared/miz_oki_source_of_truth.py, src/shared/mizoki_core|counsel|estate|risk, src/shared/virtuoso_models/, the miz_oki_3.5_integrated/ bundle and its MIGRATION.md — and an earlier integration prompt may have produced additional unpushed work in this checkout. Landing the remediation layer blindly on top of that would create two parallel contract definitions that agree today and drift next month. Your job is to make paper and platform the same thing.

Ground rules (read before touching anything)

  1. Verify actual checkout state before believing any session summary. Run git status, git log --oneline -10, and git log --oneline -5 -- src/shared/miz_oki_source_of_truth.py miz_oki_3.5_integrated/ mizoki-remediation/ first. Prior-session notes (including this prompt's own framing) may describe files as "unpushed" that are already on main, or vice versa. The repository is the authority; summaries are hints.
  2. mizoki-remediation/contracts/mizoki_contracts/ wins any definitional conflict. Where the same concept exists in two places — the canonical event envelope, the eight decision objects, auth, the store, validators — the mizoki_contracts definition is canonical and the other copy is either deleted, converted to a re-export, or explicitly recorded as a mirror with a parity check. No third option.
  3. The defect inventory is your work order, not background reading. Read docs/REVIEW.md first if it exists in this checkout. If it does not, the defect inventory lives in two files that do exist on main: docs/MIZ_OKI_PRODUCTION_CONVERGENCE_PLAN.md (10 line-cited P0 gaps, Appendix A) and mizoki-remediation/docs/README.md (the 12-row gap → resolution matrix). Treat the union as the defect list. Every change you make must cite which defect or gap it closes.
  4. This repo auto-merges. A push to any claude/* or cursor/* branch lands on main within seconds via the Auto-Merge bot, and the Deploy Router will dispatch matching deploy workflows for the merge. There is no "draft PR" safety net. Do not push until the phase you are in is complete and its verification gate is green.

Invariants — defects that get reintroduced during integration

These are the specific defect classes that a well-meaning integration session recreates. Check your diff against every one of these before each commit:


Phase 0 — Reconciliation plan (BLOCKING: no other phase starts until this file exists)

Produce docs/RECONCILIATION_PLAN.md and commit it alone before any code change. It must contain:

  1. Checkout-state table. For each artifact family, what is actually present and at what version: mizoki-remediation/ (drop bdbf0a88), src/shared/mizoki_core|counsel|estate|risk, src/shared/miz_oki_source_of_truth.py (expect v3.5.2), src/shared/virtuoso_models/ + its vendored copy in services/virtuoso-models-service/, miz_oki_3.5_integrated/ bundle, and any uncommitted work from earlier prompts.
  2. Superseded-vs-merged disposition. One row per overlap, with the decision and the rule applied: - mizoki_contracts.envelope vs mizoki_core.envelope — contracts wins the definition; record what happens to mizoki_core.envelope (delete / re-export / stdlib mirror + parity test). Note the constraint honestly: mizoki_core is deliberately stdlib-only and ships inside the boss image; if pydantic cannot be imposed on its consumers, the recorded outcome is a mirror with a CI parity check (field names, types, bitemporal ordering rule available_to_model_at >= observed_at), not silent coexistence. - mizoki_contracts.decision_objects (pydantic, eight objects + ClaimLabel + RollbackContract) vs mizoki_core.objects (dataclasses, eight objects) — same rule, same honesty about the stdlib constraint. - mizoki_contracts.auth/store/validators vs any per-cell equivalents you find. - miz_oki_3.5_integrated/ bundle copies — already established as deliberately stale (June-26 vintage); confirm the plan states they are a tracked work-product record and are never synced over src/shared/.
  3. The defect inventory you are working from — docs/REVIEW.md if present, otherwise the Convergence Plan P0 list ∪ the remediation gap matrix — enumerated with IDs you will cite in later commits.
  4. Sequencing — which convergence-plan tickets this session touches (start at PROD-001/OPS-001 ordering; do not jump the 20-ticket merge sequence).

Do not begin Phase 1 until docs/RECONCILIATION_PLAN.md is committed. If you find a genuine contradiction between the remediation layer and main that the "contracts wins" rule cannot resolve mechanically (e.g., the Vertex-aware call_claude vs a contracts-side assumption), record it in the plan with your proposed resolution and proceed only on the documented choice — never on an undocumented one.

Phase 1 — Defect closure

Work the defect inventory in convergence-plan priority order. For each defect:

Phase 2 — Wiring the cells into the layer

Follow the integration map in mizoki-remediation/docs/README.md exactly (SENSE cells → canonical-ingestion; REASON cells → mizoki_contracts + point-in-time evidence reads; DECIDE cells → DCP /api/v1/propose; ACT cells → action-runner with rollback contracts; LEARN cells → Outcome/LearningRecords; virtuoso_models → model registry with named baselines). Rules:

Phase 3 — The canonical data file is the deliverable

src/shared/miz_oki_source_of_truth.py is what makes paper and platform the same thing. After this phase:

Phase 4 — Verification gates (all must be green before the final push)

  1. python3 -m unittest tests.test_six_domain_blueprint — 29/29.
  2. pytest tests/shared/test_virtuoso_models.py — 34/34 (in-package suites run separately, 25/25 each; running both files in one invocation collides on the module name — that is not a real failure).
  3. mizoki-remediation/tests/test_end_to_end.py — 8/8 in-memory.
  4. python3 mizoki-remediation/tools/claims_lint.py over changed files — clean.
  5. check_conformance() — zero violations, including the new reconciliation assertions.
  6. diff -q across the two virtuoso_models homes and (if kept) the mizoki_core mirror parity test.

Prohibitions (absolute — a blocked gate is a finding, not an obstacle)

Deliverables checklist

← All docsView source on GitHub →