Rust Phase 4 compiled schematic graph contract

Status: accepted at 86247f2. This slice establishes the transport and identity authority before implementing the native schematic compiler. It does not change the accepted Python producer and does not add a WASM operation.

Contract boundary

compiled-schematic-graph-a0.tsp owns the complete a0 envelope and its ten row collections. TypeSpec generates strict JSON Schema, Rust, Python/msgspec, and TypeScript projections. Unknown record fields and unregistered enum values fail during transport decoding. Wire names such as type and the registered dotted source-identity selectors are preserved even when a target language requires a safe local name. The a0 shape is closed: every additive field, source selector, enum value, or row family requires a new schema version and an explicit migration.

Generated projections are structural DTOs. Graph-wide reference closure, UUIDv7 validity, uniqueness, topology, role-dependent fields, and identity replay remain semantic checks. Phase 4's native compiler step must port the accepted Python validator and may add handwritten Rust validation beside generated types; it must not hand-edit generated files.

Identity authority

compiled_schematic_graph_a0_vectors.json freezes project-scope normalization plus source-derived and topology-derived UUIDv7 results. The current Python allocator replays those values. The vectors cover every row type, both source and derived branches, UUIDv7 version/variant bits, selector precedence, normalization, and fail-closed inputs. The native allocator must consume the same vector file before it may emit a compiled graph. This keeps identity behavior language neutral without prematurely moving compiler logic into the transport generator.

Evidence and ownership

Next gate

Promotion of this contract authorizes the native validator, deterministic allocator, named multi-file source bundle, and schematic compiler. Compiler promotion requires Python differential evidence on generated and corpus schematics; merely decoding this structural fixture is not compiler parity.