|
1 | 1 | # Migration — OGAR `ogar-vocab` codebook ⇄ `lance-graph-contract` classid (v1) |
2 | 2 |
|
3 | | -> **Status:** PROPOSED (2026-06-20). Surfaces a **canon conflict** between merged |
4 | | -> `lance-graph-contract` classids and OGAR's `ogar-vocab` codebook; the |
5 | | -> reconciliation rewrites merged canon (`CLASSID_OSINT`/`CLASSID_FMA`) and so is |
6 | | -> gated on operator sign-off. |
| 3 | +> **Status:** SHIPPING (2026-06-20). Operator signed off §5; D-OVC-1/2/4 landed |
| 4 | +> on the jirak branch + D-OVC-3 realign landed (canon-doc cross-ref pending). |
| 5 | +> Originally surfaced a **canon conflict** between merged `lance-graph-contract` |
| 6 | +> classids and OGAR's `ogar-vocab` codebook. |
7 | 7 | > **The triangle:** ontology (OGAR `ogar-vocab`) → contract (`NodeGuid`/`ClassId`) |
8 | 8 | > → q2 (Quadro-2 cockpit consuming `GraphSnapshot`). |
9 | 9 |
|
@@ -84,23 +84,43 @@ class-identity codebook. Reconcile onto OGAR's `0xDDCC` scheme: |
84 | 84 |
|
85 | 85 | ## 4 — Deliverables (gated on §5 decisions) |
86 | 86 |
|
87 | | -- **D-OVC-1** Move/mirror `ConceptDomain` + `canonical_concept_domain` + |
88 | | - `source_domain_concept` + `canonical_concept_id` + `CODEBOOK` + `LabelDTO` |
89 | | - into `lance-graph-contract` (e.g. `contract::ogar_codebook`); `ogar-vocab` |
90 | | - re-exports (or wire-compat duplicate). Round-trip test: `LabelDTO::from_alias` |
91 | | - parity across both crates. |
92 | | -- **D-OVC-2** Mint `CLASSID_PROJECT` (`0x0100`) + `CLASSID_ERP` (`0x0200`) in |
93 | | - `canonical_node.rs` + `ReadMode`s, registered in `BUILTIN_READ_MODES`. Add |
94 | | - `soa_graph::{PROJECT, ERP}` `DomainSpec`s (siblings of `OSINT_GOTHAM`/`FMA_ANATOMY`). |
95 | | -- **D-OVC-3** **Canon realign (SIGN-OFF):** `CLASSID_OSINT 0x0007 → 0x0700`, |
96 | | - `CLASSID_FMA 0x0008 → 0x09xx` (Health) or a minted anatomy domain. Field-isolation |
97 | | - / version-gate per `I-LEGACY-API-FEATURE-GATED`; update `aiwar.rs`, `soa_graph.rs`, |
98 | | - tests, and the canon block in `lance-graph/CLAUDE.md` + OGAR `CODEBOOK`. |
99 | | -- **D-OVC-4** Route `classid → ReadMode` (and the domain ClassView) through |
100 | | - `canonical_concept_domain(classid_lo)`; q2 reads `LabelDTO`/`canonical` for |
101 | | - display labels (the contract→q2 leg of the triangle). |
102 | | - |
103 | | -## 5 — Decisions needed (operator) |
| 87 | +> **Update 2026-06-20:** operator signed off §5 (realign 0xDDCC / wire-compat / |
| 88 | +> FMA = Health `0x0901`). D-OVC-1/2 SHIPPED, D-OVC-4 SHIPPED (function + tests; |
| 89 | +> q2 display-label leg is q2-side); D-OVC-3 (cutover audit) downgraded — the |
| 90 | +> classid realign is a const *value* change, not a bit-layout reclaim, so it is |
| 91 | +> layout-preserving (no `ENVELOPE_LAYOUT_VERSION` bump); what remains is updating |
| 92 | +> the `lance-graph/CLAUDE.md` canon block + OGAR `CODEBOOK` cross-doc. |
| 93 | +
|
| 94 | +- **D-OVC-1** ✅ **SHIPPED.** NEW `contract::ogar_codebook` — wire-compat mirror |
| 95 | + (zero-dep, no OGAR↔contract dependency): `ConceptDomain`, `canonical_concept_domain`, |
| 96 | + `classid_concept_domain` (the classid→domain route, D-OVC-4), `source_domain_concept`, |
| 97 | + `CODEBOOK` (project `0x01XX` + commerce `0x02XX`), `canonical_concept_id`, |
| 98 | + `LabelDTO { label, id, canonical }` + `from_canonical` + `id_le`. (Named |
| 99 | + `from_canonical`, not `from_alias`: the contract carries the codebook-id layer, |
| 100 | + NOT OGAR's curator-alias normalizer — that stays in `ogar-vocab`.) Drift-guard |
| 101 | + test pins the shared `0xDDCC` ids; 6 tests. |
| 102 | +- **D-OVC-2** ✅ **SHIPPED.** Minted `CLASSID_PROJECT` (`0x0100`) + `CLASSID_ERP` |
| 103 | + (`0x0200`) in `canonical_node.rs` + `ReadMode::{PROJECT, ERP}` (both Cognitive / |
| 104 | + CoarseOnly), registered in `BUILTIN_READ_MODES`. Added `soa_graph::{PROJECT, ERP}` |
| 105 | + `DomainSpec`s (siblings of `OSINT_GOTHAM`/`FMA_ANATOMY`), re-exported from lib.rs. |
| 106 | +- **D-OVC-3** ◐ **PARTIAL.** Canon realign LANDED: `CLASSID_OSINT 0x0007 → 0x0700`, |
| 107 | + `CLASSID_FMA 0x0008 → 0x0901` (anatomy concept in Health). Tests updated to assert |
| 108 | + the new values + `>>8` domain bytes. **Layout-preserving** (const value, not a bit |
| 109 | + reclaim) → no field-isolation matrix / version-gate needed. **Remaining:** update |
| 110 | + the `lance-graph/CLAUDE.md` canon block note + OGAR `CODEBOOK` cross-ref doc. |
| 111 | +- **D-OVC-4** ✅ **SHIPPED (contract leg).** `classid_concept_domain(classid)` routes |
| 112 | + on the low-u16 `0xDDCC` high byte; tests assert all five classids resolve to their |
| 113 | + `ConceptDomain`. q2's `LabelDTO`/`canonical` display-label consumption is the q2-side |
| 114 | + leg (this crate exports the type + ids). |
| 115 | + |
| 116 | +## 5 — Decisions needed (operator) — ✅ RESOLVED 2026-06-20 |
| 117 | + |
| 118 | +1. **Canon realign OSINT/FMA?** → **YES, realign to `0xDDCC`** (OSINT `0x0700`, |
| 119 | + FMA `0x0901`). |
| 120 | +2. **Dependency direction?** → **(b) wire-compat now** — both define, the `u16` LE |
| 121 | + wire is the only contract, drift-guard test prevents divergence. No new dep. |
| 122 | +3. **FMA/anatomy domain?** → **Health `0x09XX`** — FMA = anatomy concept `0x0901`, |
| 123 | + `0x0900` = Health root. (`CC = 0x00` = domain root, reserved everywhere.) |
104 | 124 |
|
105 | 125 | 1. **Canon realign OSINT/FMA?** `CLASSID_OSINT 0x0007 → 0x0700`, `CLASSID_FMA |
106 | 126 | 0x0008 → 0x09XX`. This rewrites merged canon (#557/#560) + the `lance-graph/ |
|
0 commit comments