core/language_packs/data
Shay d2f5607167 feat: ADR-0116 — deterministic solver + en_arithmetic_v1 operator pack
Phase 2 of the ADR-0114 expert-capability roadmap. Consumes the
MathProblemGraph from Phase 1 and emits a SolutionTrace — ordered
operation applications ending at a numeric answer, byte-deterministic
across runs, with each step's operation bound to a pack-resolved
lemma identifier.

What landed

generate/math_solver.py
  - solve(graph) -> SolutionTrace; pure function, no I/O, no globals
  - SolutionStep dataclass with before/after values per step (for
    verifier replay; ADR-0117 hardens)
  - SolutionTrace with canonical_bytes() byte-deterministic JSON
  - SolveError typed refusal: missing pack, division by zero,
    unknown-references-nothing

language_packs/data/en_arithmetic_v1/
  - 5 operator lemmas: add / subtract / multiply / divide / transfer
  - role=operational_base (vocabulary-only; no domain claim)
  - SHA-256-anchored lexicon + glosses; manifest carries
    provenance=adr-0116:operator_seed:2026-05-22

tests/test_math_solver.py — 109 cases pinning five invariants:
  1. Phase 2 exit criterion: ≥ 0.80 on parser-correct dev set
     (current: 50/50 = 1.00)
  2. Determinism: two solves produce byte-equal trace
  3. Trace replay reproduces answer_value (verifier rehearsal)
  4. Typed refusal on under-determined inputs
  5. Every step.pack_lemma_id resolves to a real lexicon entry
     in en_arithmetic_v1

ADR-0114a obligation discharge

Four of ten anti-overfitting obligations now have load-bearing
implementations in code:

  #3  replay-equal trace                 — discharged (solver-layer)
  #4  typed refusal                      — discharged (solver-layer)
  #9  determinism                        — discharged (solver-layer)
  #10 operation provenance via pack      — DISCHARGED IN FULL

Removing the en_arithmetic_v1 pack now breaks every solve loudly.
The "operations bind to concepts, not hardcoded strings" claim is
architecturally true, not rhetorical.

Tests: 109/109 green on solver suite; 67/67 smoke suite green;
parser + schema suites still green from prior phases.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-22 16:28:04 -07:00
..
en_arithmetic_v1 feat: ADR-0116 — deterministic solver + en_arithmetic_v1 operator pack 2026-05-22 16:28:04 -07:00
en_collapse_anchors_v1 feat(packs): apply ADR-0085 gloss fluency pass (#73) 2026-05-20 16:19:09 -07:00
en_core_action_v1 feat(packs): ADR-0085 content style pass v2 — 3sg + plural agreement (+ closure infra) (#100) 2026-05-20 23:12:28 -07:00
en_core_attitude_v1 feat(packs): ADR-0085 content style pass v2 — 3sg + plural agreement (+ closure infra) (#100) 2026-05-20 23:12:28 -07:00
en_core_causation_v1 feat(packs): ADR-0085 content style pass v2 — 3sg + plural agreement (+ closure infra) (#100) 2026-05-20 23:12:28 -07:00
en_core_cognition_v1 feat(packs): ADR-0085 content style pass v2 — 3sg + plural agreement (+ closure infra) (#100) 2026-05-20 23:12:28 -07:00
en_core_meta_v1 feat(packs): ADR-0085 content style pass v2 — 3sg + plural agreement (+ closure infra) (#100) 2026-05-20 23:12:28 -07:00
en_core_polarity_v1 feat(adr-0084): definitional layer — proposal + substrate (schema/loader/closure) (#64) 2026-05-20 15:25:25 -07:00
en_core_quantitative_v1 feat(packs): apply ADR-0085 gloss fluency pass (#73) 2026-05-20 16:19:09 -07:00
en_core_relations_v1 feat(adr-0084): definitional layer — proposal + substrate (schema/loader/closure) (#64) 2026-05-20 15:25:25 -07:00
en_core_relations_v2 feat(adr-0084): definitional layer — proposal + substrate (schema/loader/closure) (#64) 2026-05-20 15:25:25 -07:00
en_core_relations_v3 feat(adr-0084): definitional layer — proposal + substrate (schema/loader/closure) (#64) 2026-05-20 15:25:25 -07:00
en_core_spatial_v1 feat(packs): ADR-0085 content style pass v2 — 3sg + plural agreement (+ closure infra) (#100) 2026-05-20 23:12:28 -07:00
en_core_temporal_v1 feat(packs): apply ADR-0085 gloss fluency pass (#73) 2026-05-20 16:19:09 -07:00
en_mathematics_logic_v1 feat(packs): implement ADR-0097 — Mathematics-Logic Reasoning-Capable 2026-05-21 18:51:58 -07:00
en_minimal_v1 Implement trilingual field coherence 2026-05-13 19:53:37 -07:00
en_physics_v1 feat(packs): ADR-0100/0101/0102 — three sibling domain ratifications 2026-05-21 20:25:48 -07:00
en_systems_software_v1 feat(packs): ADR-0100/0101/0102 — three sibling domain ratifications 2026-05-21 20:25:48 -07:00
grc_logos_cognition_v1 feat(packs): ADR-0103 — attach hebrew_fluency + koine_greek_fluency lanes to ADR-0102 (#106) 2026-05-22 09:43:46 -07:00
grc_logos_micro_v1 feat(packs): ADR-0103 — attach hebrew_fluency + koine_greek_fluency lanes to ADR-0102 (#106) 2026-05-22 09:43:46 -07:00
he_core_cognition_v1 feat(packs): ADR-0103 — attach hebrew_fluency + koine_greek_fluency lanes to ADR-0102 (#106) 2026-05-22 09:43:46 -07:00
he_logos_micro_v1 feat(packs): ADR-0103 — attach hebrew_fluency + koine_greek_fluency lanes to ADR-0102 (#106) 2026-05-22 09:43:46 -07:00