formula-bridge
The groupant beside models/formula-bridge.groupant 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 | forward |
| ast | not materialized | |
| composition | partial | composition |
| cost | symbolic source derived | cost |
| descriptant | present | descriptant |
| invariant | partial | invariant |
| tests | see source local evidence | checks |
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 |
byte-transport | representation_transport | partial source derived model | byte-transport |
gate-bridge | equivalence_boundary | partial source derived model | gate-bridge |
macro-scope | state_scope | partial source derived model | macro-scope |
output-prefix | effect_prefix | partial source derived model | output-prefix |
Model text
descriptant
formula-bridge: wave28
extract bodies exclude delimiters, start in bytes. corpus tex scans macros per file versus CLI tex all files before formulas. Canonical gate reparses without original macros. Corpus falls back to to_relation only on to_expr relation category. Reexports add no adapter. Empty Add/Mul output empty Node but inverse/roundtrip reject.
This source-bound partial group organizes existing Mova code. Native evidence and excluded effects are recorded in source sidecars and the root wave28 report. Registration is not a universal proof or whole-system runtime claim.
model
formula-bridge
forward
Text→extract borrowed bodies/byte offsets→macro-aware parse→structural print/reparse gate→optional restricted Expr/relation transport. CLI/corpus aggregate separate parse/unknown/gate/bridge outcomes; feature math controls API and command branches.
invariant
Gate Node equality and bridge fold_literals Expr equality differ from numeric truth and definedness: 1/0 may structurally roundtrip but evaluation rejects. Corpus processed formulas partition parsed/errors and parsed partition gate outcomes. CLI success does not imply formula success.
cost
Repeated unmatched extraction suffixes/nested bridge groups can cause quadratic rescanning. Recursive parsing/printing/conversion add tree/string work. Corpus retains IDs/hashes and one file; CLI tex retains all texts. Ordered file writes are not atomic; no speed claim.
composition
extract bodies exclude delimiters, start in bytes. corpus tex scans macros per file versus CLI tex all files before formulas. Canonical gate reparses without original macros. Corpus falls back to to_relation only on to_expr relation category. Reexports add no adapter. Empty Add/Mul output empty Node but inverse/roundtrip reject.
domain
Bounded UTF-8 synthetic text/files and supported parser-produced Nodes/Exprs with finite Rat values. Arbitrary public AST constructor states not certified total. math/gz features select adapters.
limitations
External parser/printer/AST equality/macros/Rat/evaluator contracts delegated. No live corpus, frozen VMM DATA execution, teacher/API, training or GPU. Timing and tied error ranks may vary.
checks
- Selected actual tests twice debug and release with sorted names retained
- Math doc composition and no-default-features compilation
- Paired identical lexical source projections
- Seven compiled assertion controls with exact restoration and positive reruns
catalog
behavior-complement
Parse failure excludes gate/bridge counting; tex success does not exclude formula failure. Unsupported conversion cannot be numeric success; absent math hides tomath.
reverse-reconstruction
Compatible documents for one Expr include alternate presentation/grouping and ignored prose; byte offsets and macros constrain but do not uniquely recover original. Counters lose further identity.
byte-transport
tex[start..start+body.len()]==body; parser error positions body-relative versus CLI outer body start.
gate-bridge
Node and folded Expr equivalence have different classes. Clean syntax may contain unsupported math variables; structural roundtrip does not prove denominator nonzero.
macro-scope
Corpus per-file versus CLI document-global macro scanning invalidates substituting one adapter for other when definitions cross files.
output-prefix
Corpus writes can leave prefix on failure; CLI exit does not imply atomicity or deterministic elapsed report text.
This page in Markdown → https://md.groupants.elamur.ai/free/en/mova/models/formula-bridge.groupant/