roundtrip-main-spec
The groupant beside tools/roundtrip/src/main.rs in the Mova repository: what the code computes, what it never does, how to go back from its outputs, its invariants, cost and checks.
Facts
Implementation material. A Mova code model describes this code at one source revision: partial models, finite checks and their stated scope. It is not a reviewed general exposition, and its labels are shown as written, never raised.
Components
| component | label | where |
|---|---|---|
| approximant | partial | approximant |
| ast | partial | ../syntax.json |
| cost | partial | invariant-and-cost |
| descriptant | present | descriptant |
| invariant | partial | invariant-and-cost |
| tests | bounded checks | tests |
Obernants
The typed relations around the forward model: the behaviour complement (what the code never does), the reverse reconstruction (every input compatible with an output) and specialised views.
| id | type | label | where |
|---|---|---|---|
behavior_complement | behavior_complement | partial source derived model | behavior_complement |
reverse_reconstruction | reverse_reconstruction | partial source derived model | reverse_reconstruction |
spec_precedence | spec_precedence | partial source derived model | spec_precedence |
option_default | option_default | partial source derived model | option_default |
scope_precondition | scope_precondition | partial source derived model | scope_precondition |
resource_boundary | resource_boundary | partial source derived model | resource_boundary |
Model text
descriptant
CLI lexical validation
2026-10-31 epoch: source scope bytes [2036,2825); Class names match case-sensitively; volume kind/stride validation precedes reader effects.
No annotator/model loading, live corpus, full suite, teacher, GPU or persistent-learning evidence. No executable percentage surrogate: categorical codecs/effects need a useful metric before future caps 1/2/5/10%.
approximant
CLI lexical validation
Class names match case-sensitively; volume kind/stride validation precedes reader effects.
Domain: bounded synthetic values, valid source-specific coordinates, nonoverflowing counts, available allocation; fixed environment controls. Relations are source-derived partial models with finite checks, not universal proofs.
catalog
behavior_complement
Subject: roundtrip-main-spec, source hash 00f4bbcd3c873394f1a661e52a0dc3360dc8f4f368d9f33113d3f6c6ac2e4109, transition observation.
For CLI lexical validation, excluded transitions violate the stated scoped rule: Class names match case-sensitively; volume kind/stride validation precedes reader effects. This is an inner source-derived exclusion under the domain, not a complement of arbitrary unseen runtime behavior.
Domain: bounded synthetic values, valid source-specific coordinates, nonoverflowing counts, available allocation; fixed environment controls. Relations are source-derived partial models with finite checks, not universal proofs.
Evidence: external wave32 rt_core receipt includes native-commands.json, exact named outcomes twice debug/twice release, raw status/log files, compiled production controls with byte restoration and paired syntax. Only named synthetic helpers execute; model_path/export and live CLI paths have representation/source evidence.
Status: partial source-derived model.
reverse_reconstruction
Subject: roundtrip-main-spec, source hash 00f4bbcd3c873394f1a661e52a0dc3360dc8f4f368d9f33113d3f6c6ac2e4109, transition observation.
Fix outputs and post-state of spec; compatible antecedents are all scoped inputs/pre-state satisfying: Class names match case-sensitively; volume kind/stride validation precedes reader effects. Fields outside this byte scope are held fixed; discarded fields remain ambiguous.
Domain: bounded synthetic values, valid source-specific coordinates, nonoverflowing counts, available allocation; fixed environment controls. Relations are source-derived partial models with finite checks, not universal proofs.
Evidence: external wave32 rt_core receipt includes native-commands.json, exact named outcomes twice debug/twice release, raw status/log files, compiled production controls with byte restoration and paired syntax. Only named synthetic helpers execute; model_path/export and live CLI paths have representation/source evidence.
Status: partial source-derived model.
spec_precedence
Subject: roundtrip-main-spec, source hash 00f4bbcd3c873394f1a661e52a0dc3360dc8f4f368d9f33113d3f6c6ac2e4109, transition observation.
Missing colon errors first; malformed final @ stride errors before kind selection; valid unknown kind rejects before file reads.
Domain: bounded synthetic values, valid source-specific coordinates, nonoverflowing counts, available allocation; fixed environment controls. Relations are source-derived partial models with finite checks, not universal proofs.
Evidence: external wave32 rt_core receipt includes native-commands.json, exact named outcomes twice debug/twice release, raw status/log files, compiled production controls with byte restoration and paired syntax. Only named synthetic helpers execute; model_path/export and live CLI paths have representation/source evidence.
Status: partial source-derived model.
option_default
Subject: roundtrip-main-spec, source hash 00f4bbcd3c873394f1a661e52a0dc3360dc8f4f368d9f33113d3f6c6ac2e4109, transition observation.
Neither --exact nor --normal selects both. Missing option values reject during argument parse before run directory/model effects.
Domain: bounded synthetic values, valid source-specific coordinates, nonoverflowing counts, available allocation; fixed environment controls. Relations are source-derived partial models with finite checks, not universal proofs.
Evidence: external wave32 rt_core receipt includes native-commands.json, exact named outcomes twice debug/twice release, raw status/log files, compiled production controls with byte restoration and paired syntax. Only named synthetic helpers execute; model_path/export and live CLI paths have representation/source evidence.
Status: partial source-derived model.
scope_precondition
Subject: roundtrip-main-spec, source hash 00f4bbcd3c873394f1a661e52a0dc3360dc8f4f368d9f33113d3f6c6ac2e4109, transition observation.
CLI lexical validation requires the coordinate/state assumptions of this fragment; inspect its exact byte range. Class names match case-sensitively; volume kind/stride validation precedes reader effects. Invalid arbitrary state is outside the reconstruction law.
Domain: bounded synthetic values, valid source-specific coordinates, nonoverflowing counts, available allocation; fixed environment controls. Relations are source-derived partial models with finite checks, not universal proofs.
Evidence: external wave32 rt_core receipt includes native-commands.json, exact named outcomes twice debug/twice release, raw status/log files, compiled production controls with byte restoration and paired syntax. Only named synthetic helpers execute; model_path/export and live CLI paths have representation/source evidence.
Status: partial source-derived model.
resource_boundary
Subject: roundtrip-main-spec, source hash 00f4bbcd3c873394f1a661e52a0dc3360dc8f4f368d9f33113d3f6c6ac2e4109, transition observation.
CLI lexical validation: allocations/clones and recursion/scans within this scope are retained. Parent cost bound is conservative for this subroutine: Spec parse O(bytes). run_set uses max(threads,1) workers and O(volume count) result slots, plus pipeline cost; tally merges sequentially by index. CLI I/O proportional to read/write bytes; allocations and thread creation can fail/panic.
Domain: bounded synthetic values, valid source-specific coordinates, nonoverflowing counts, available allocation; fixed environment controls. Relations are source-derived partial models with finite checks, not universal proofs.
Evidence: external wave32 rt_core receipt includes native-commands.json, exact named outcomes twice debug/twice release, raw status/log files, compiled production controls with byte restoration and paired syntax. Only named synthetic helpers execute; model_path/export and live CLI paths have representation/source evidence.
Status: partial source-derived model.
tests
Scoped evidence
Evidence: external wave32 rt_core receipt includes native-commands.json, exact named outcomes twice debug/twice release, raw status/log files, compiled production controls with byte restoration and paired syntax. Only named synthetic helpers execute; model_path/export and live CLI paths have representation/source evidence.
Coverage is limited to this fragment's reached branches; parent tests do not prove every scoped branch.
invariant-and-cost
Scoped invariant and cost
Class names match case-sensitively; volume kind/stride validation precedes reader effects.
Spec parse O(bytes). run_set uses max(threads,1) workers and O(volume count) result slots, plus pipeline cost; tally merges sequentially by index. CLI I/O proportional to read/write bytes; allocations and thread creation can fail/panic.
The parent bound is conservative; unrelated parent effects are excluded from this fragment.
This page in Markdown โ https://md.groupants.elamur.ai/free/en/mova/tools/roundtrip/src/main.rs.groupant/spec.groupant/