Elamur GroupantsāŒ•
☰

math-qworld

The groupant beside math/src/qworld.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

componentlabelwhere
approximantpartialapproximant
astpartialsyntax.json
compositionpartialcomposition
descriptantpresentdescriptant
invariantpartialinvariant
testsexecuted bounded checkstests

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.

idtypelabelwhere
behavior_complementbehavior_complementpartial source derived modelbehavior_complement
reverse_reconstructionreverse_reconstructionpartial source derived modelreverse_reconstruction
overwrite_lawoverwrite_lawpartial source derived modeloverwrite_law
tie_selectiontie_selectionpartial source derived modeltie_selection
occurrence_matchingoccurrence_matchingpartial source derived modeloccurrence_matching
query_precedencequery_precedencepartial source derived modelquery_precedence

Parts

Model text

descriptant

math-qworld

Exact rational command cells and heuristic or learned query templates.

Epoch 2026-10-31: source-derived partial model; prospective hypotheses retained before changes. Existing behavior unchanged except test helper path extraction. New bounded fixtures avoid annotated text/model/corpus/teacher paths. Child scopes use the parent syntax projection; lexical AST has no macro expansion or semantic resolution. Numeric thresholds and adapter differences are observations, not mathematical correctness proofs.

approximant

Forward relation

write skips const quantities, inherits empty/pronoun owners and missing things; For every nonconstant quantity, write resolves and updates inherited owner/thing context before selecting its operation. A rate emits a command/log without an immediate cell update, but its context can affect later ownerless or unitless quantities. Assignment overwrites, and addition/subtraction update an old-or-zero cell. ask orders target difference, action difference, class sum, share then state. Fixed10/15 epoch local classifiers score hashed features.

Domain

Aligned qs/descs/labels required. Q exact arithmetic does not validate dimensional meaning of normalized noun strings. Learned feature hashes may collide; default op/template ties select r/Product.

Executable approximant gap

No useful measured percentage surrogate is supplied for these categorical parse/search/effect observations. Supported future caps are 1%, 2%, 5%, 10% only, requiring an explicit metric and reference comparison. No speed or accuracy guarantee follows.

invariant

Invariants and cost

Aligned qs/descs/labels required. Q exact arithmetic does not validate dimensional meaning of normalized noun strings. Learned feature hashes may collide; default op/template ties select r/Product.

Cost

O(N log cells) write plus rational work; query up to O(N log N); learned cells O(N² features), training10 passes, query training15 passes.

Allocation failure, deep recursion, malformed public structures and universal numerical bounds are not verified.

Reviewed interaction boundary

For every nonconstant quantity, write resolves and updates inherited owner/thing context before selecting its operation. A rate emits a command/log without an immediate cell update, but its context can affect later ownerless or unitless quantities. Assignment overwrites, and addition/subtraction update an old-or-zero cell.

composition

Scoped composition

Exact rational command cells and heuristic or learned query templates.

write skips const quantities, inherits empty/pronoun owners and missing things; For every nonconstant quantity, write resolves and updates inherited owner/thing context before selecting its operation. A rate emits a command/log without an immediate cell update, but its context can affect later ownerless or unitless quantities. Assignment overwrites, and addition/subtraction update an old-or-zero cell. ask orders target difference, action difference, class sum, share then state. Fixed10/15 epoch local classifiers score hashed features.

steps::Prob aligned quantities/descriptions feed exact command cells; query carries original leaf indices. scripts supply optional labels, local classifiers choose operations/cells/templates. Rat-to-f64 features elsewhere lose exactness.

Reviewed interaction boundary

For every nonconstant quantity, write resolves and updates inherited owner/thing context before selecting its operation. A rate emits a command/log without an immediate cell update, but its context can affect later ownerless or unitless quantities. Assignment overwrites, and addition/subtraction update an old-or-zero cell.

models

Typed relations

behavior_complement

Rates exclude immediate cell-map updates but can change inherited owner/thing context for later commands; constants exclude commands; zero denominator excludes ratio success. Negative states remain possible; Diff fallback needs >=2 cmds even if target count>=2.

reverse_reconstruction

Final overwrite hides earlier state; command histories with same later net change are compatible. Script labels lose ignored lines and duplicate-valued antecedents.

overwrite_law

Set(v1);Set(v2) leaves v2, unlike qread's additive Set.

tie_selection

max_by chooses last equal-score operation/template; same-cell clustering requires strictly positive pair score.

occurrence_matching

Labels bind first unused equal exact nonconstant quantity; repeated values are distinct occurrences.

query_precedence

State template delegates full ask; target difference may return None before later heuristics.

tests

Source execution evidence

Safe command: cargo test -p math --lib wave28 -- --test-threads=1

Named outcomes (twice debug, twice release; sorted names equal; exits0):

test qworld::wave28::exact_world_overwrites_and_labels_duplicates ... ok
test qworld::wave28::script_templates_follow_last_definition ... ok

One compiled assertion control for this source: compilation0, false expectation test101, exact byte restore, focused positive rerun0. These are actual source assertions, not copied implementations or semantic proof. Controls ran before rustfmt-only test-block formatting.

No learned training epochs or corpus scripts; only synthetic scripts, exact write/query and zero-weight learned dispatch.

Strict math lib Clippy reports113 pre-existing production lints. No executable percentage surrogate, speed claim, model/corpus/teacher/GPU/full-school or held-out execution.

This page in Markdown → https://md.groupants.elamur.ai/free/en/mova/math/src/qworld.rs.groupant/