Skip to content

WO52 M0: corpus/recipe contracts + isxml validate - #294

Merged
ronaldtse merged 4 commits into
mainfrom
feat/wo52-m0-contracts
Oct 17, 2026
Merged

ronaldtse merged 4 commits into
mainfrom
feat/wo52-m0-contracts

Conversation

@ronaldtse

Copy link
Copy Markdown
Contributor

Summary

WO52 milestone M0 of the unified framework (spec: TODO.sota/52-unified-framework.md):

  • L0 contracts (src/pipeline/contracts.py): pydantic schemas for
    CorpusSpec and RecipeSpec plus cross-registry validation.
    Enforced at validation time: mandatory test split, corpus pins are
    dates or versions (never moving refs like latest), every stage is
    implementable (legacy route or params), metric gates use known keys
    (cer/wer/per), and diacritization recipes may never declare an
    LLM-teacher stage (standing law, validator-enforced).
  • isxml validate CLI verb (src/pipeline/cli.py, console script
    registered) — validates corpora/ + recipes/, exits nonzero on
    any problem.
  • Shipped contracts: recipes/urd-diac.yaml, recipes/fas-diac.yaml
    with route: legacy: pointers to the proven interscript-train
    scripts, and corpora/urd-dia.yaml, corpora/fas-dia.yaml. Sources
    with UNVERIFIED licenses are blocking problems by design until the
    provenance review resolves them (the test asserts exactly this open
    set, so no silent drift).
  • WO51 record (TODO.sota/51-artifact-parity-gates.md): parity
    gates must evaluate in the runtime's actual decode mode — single-row
    ORT matched torch exactly on 300/300 rows (CER 0.0352, agreement
    1.0); the maskless batched harness was the entire "export defect".
    fp16 single-row recheck in flight.

Test plan

  • pytest tests/test_pipeline_contracts.py — 10 tests, written
    first and watched failing (ModuleNotFoundError) before implementation
  • Full suite: pytest -m "not slow and not gpu" — green
  • ruff check src/pipeline tests/test_pipeline_contracts.py — clean
  • isxml validate smoke — exits 1 with exactly the two expected
    UNVERIFIED-license problems

Ronald Tse added 4 commits October 17, 2026 18:15
L0 contracts for the unified framework (TODO.sota/52): pydantic
schemas for corpora and recipes, cross-registry validation, and the
isxml CLI validate verb. Standing laws enforced at validation time:
mandatory test split, pinned corpus refs (date/version, never moving
refs), implementable stages (route or params), and the no-LLM-teacher
ban for diacritization recipes. Shipped urd-diac + fas-diac recipes
and corpora with route:legacy pointers to the proven training scripts;
UNVERIFIED licenses block publishing by design until the provenance
review lands. Also records WO51: parity gates must evaluate in the
runtime decode mode — single-row ORT matched torch exactly on all
300 rows (CER 0.0352, agreement 1.0); the maskless batched harness was
the entire "export defect".
Runner.launch/build_argv encode the campaign's operational laws:
always detach, explicit --timeout floored at 4h, literal argv job
commands (never shell-joined), dry-run prints the exact argv and
spawns nothing, and launches are refused at the 2-concurrent-training
budget (run-* names, RUNNING state) unless forced. 8 tests written
first and watched failing; full suite 221 green.
plan_stage translates a recipe's legacy-routed stage into the exact
budget-guarded JobSpec (params map to the legacy U_* env convention,
ckpt bucket rw, corpus sources ro at declared mounts); stages without
a route are metadata — decode policy travels with the artifact. Gates
evaluate in the runtime's decode mode (WO51) and fail closed on
missing results. Proof lane against the real run-066 artifacts:
quality PASS (0.0352<=0.045), parity PASS (single-row agree 1.0,
three-way 1.0), license FAIL (UNVERIFIED) — the spine refuses to
publish incomplete work. 7 new tests, suite 228 green.
@ronaldtse
ronaldtse merged commit 682322c into main Oct 17, 2026
11 checks passed
@ronaldtse
ronaldtse deleted the feat/wo52-m0-contracts branch October 17, 2026 14:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant