One household, start to finish. Every transcript is real — the outputs your machine will print, pinned by tests.

  1. Clone it

    The engine (WebAssembly) is checked in; the corpus regenerates from the commit pinned in corpus.lock.json. No Rust toolchain, no API key, no network at run time.

    $ git clone https://github.com/TheAxiomFoundation/axiom-local
    $ cd axiom-local && bun install
    $ bun scripts/build-corpus.mjs ../rulespec-us
  2. Slice a regulation and run it

    The subtree is the unit: 7 CFR 273.10 — the SNAP benefit computation — plus the three modules it imports, compiled and executed locally. A family of two, $1,200 wages, $900 shelter.

    determine.mjsus:regulations/7-cfr/273/10
    $ bun scripts/determine.mjs --set household_size=2 --set snap_gross_monthly_earned_income=1200 --set snap_total_allowable_shelter_expenses=900
     
    us:regulations/7-cfr/273/10
    4 modules · 17 rules · 34 parameters — compiled and executed locally
    period 2026-01-01
    encoded — not certified
     
    snap_total_gross_income 1200
    snap_earned_income_deduction_for_net_income 240
    snap_excess_shelter_deduction_for_net_income 525
    snap_net_monthly_income 226
    snap_monthly_allotment 478

    └─ $478 is pinned by this repo's tests, straight from the regulation text — if your machine disagrees, that is a bug with a reproduction. This slice is the allotment arithmetic of § 273.10; eligibility screens live in their own subtrees (§§ 273.4–273.9 — slice them the same way)

  3. Change the facts

    Every input is yours to state. Unset inputs carry synthesized screening presumptions — list them with --slots, override them with the same --set.

    $ … --set snap_total_monthly_unearned_income=500
    snap_monthly_allotment 210
     
    $ … --set household_size=3
    snap_monthly_allotment 717 # household of three
     
    $ … --set snap_gross_monthly_earned_income=2400
    snap_monthly_allotment 24 # the §273.10(e)(2)(ii)(C) minimum benefit
  4. Amend the law

    The slice is data. Raise the earned-income deduction from 20% to 30% and the same family's allotment moves — labeled hypothetical, current law untouched.

    $ … --what-if snap_earned_income_deduction_rate_for_net_income=0.3
    AMENDED LAW (current law: 0.2) — hypothetical
     
    snap_monthly_allotment 532
  5. Follow the citations

    Every figure carries the durable legal id of the rule that produced it — the engine's explain trace. Deepen with --depth N.

    $ … --trace
    snap_monthly_allotment = $478 us:regulations/7-cfr/273/10#snap_monthly_allotment
    snap_calculated_monthly_allotment_before_minimums = $478
    = max(0, floor($546 − $226 × 0.3))
    snap_minimum_benefit = $24 us:regulations/7-cfr/273/10#snap_minimum_benefit
    = floor($298 × 0.08 + 0.5)
    … every figure cited to the rule that produced it
  6. Certification is a status, not a gate

    Every slice is checked against the vendored ledger and labeled. Almost nothing is certified yet — that honesty is the point. Set AXIOM_CERTIFIED_ENFORCEMENT=enforced for the hard cut, where an uncertified closure refuses to run. Axiom-authored composition/pipeline paths are not law and refuse as roots in any posture.

    $ bun scripts/determine.mjs
    encoded — not certified
     
    $ AXIOM_CERTIFIED_ENFORCEMENT=enforced bun scripts/determine.mjs
    error: refused: 7 node(s) in the us:regulations/7-cfr/273/10 closure are not
    certified under the served ledger (fixture-us-ny-snap)
     
    $ bun scripts/determine.mjs --root us:policies/usda/snap/state-plan-composition
    error: … is Axiom-authored composition/pipeline assembly, not law —
    it is excluded from the corpus explorer and cannot be sliced.
  7. Integrate it

    --json makes every determination machine-readable. For in-process use, see the embedding section of the reference.

    $ bun scripts/determine.mjs … --json | jq .outputs
    {
    "snap_net_monthly_income": "226",
    "snap_monthly_allotment": "478",
    }