Skip to the content.

0006: An explicit claim-to-comparator mapping (judged_as in claims.yaml)

Status: accepted. Author: Claude, the lean-pkg operations agent, drafting for Le Chen. Created: 2026-10-18. Decided: accepted 2026-10-18 by Le Chen; open questions 1 and 2 stay open. Implemented in: (release).

Summary

A theorem or lemma claim in claims.yaml may carry an optional key judged_as: the full name of the comparator theorem (a theorem_names entry) that judges it, when the Challenge theorem is not named after the claim’s decl. For that claim the mapping replaces the naming rule (the decl, or <Prefix>.<decl>). It is checked, never trusted, and receipt check reads it from the repository alone. No schema version changes: claims/1 gains one optional key, and a file without it is read exactly as before. The implementation pull request is the one that adds this file.

Motivation

The lts-2026.10 stage 0 report (docs/stacks/lts-2026.10.md, “Known, pre-existing”) found that markovprocess-pilot and total-coloring-lean, both in the public index, fail receipt check’s claimed-theorems check (and coverage check’s R11, once a coverage.yaml exists): their comparator configurations judge Mathlib-only restatements (exit_mean; TotalColoringAudit.HighDegree.exists_total_coloring_of_card_le_two_mul_maxDegree), while their claims name the library theorems (MarkovProcessPilot.integral_eval_exitTimeTrunc_Ioo; TotalColoring.exists_valid_assignment_of_highDegree). The naming rule cannot connect them, and the only place the connection is written is the lean-pkg index entry (headline[].judged_as), which a referee holding only the repository does not have. claims.yaml could not say it: claims/1 refuses unknown keys.

Design

Compatibility and migration

Trust model

Yes: what receipt check, the ledger (promote) and coverage check accept. A claim the naming rule left uncovered can now count as comparator-judged. What a dishonest or mistaken author could get accepted that they could not before: a claim mapped to a Challenge theorem that states something weaker than the claim. That was already possible with the naming rule (a Challenge named <Prefix>.<decl> that states something else); in both cases the comparator checks only that the Solution proves the Challenge, and whether the Challenge says what the claim says is for a reader of both statements (the page shows the Challenge statement). The mapping is explicit, in the bound claims, and checked for existence and uniqueness. It also adds refusals: a mapped name no longer covers another claim by its name. Pinning tests: tests/test_judged_as.py (schema refusals; a mapped name credits no other claim; a mapping to an unconfigured name or an undeclared decl fails receipt check; a mapping added after X does not rebind; a second, unjudged reusable claim still fails; the ledger and --coverage credit the mapping).

Alternatives

Open questions

  1. Both packages also mark theorems reusable that no configuration judges (markovprocess-pilot: 1 of 2; total-coloring-lean: 6 of 8). The claimed-theorems check fails them independently of this proposal. Each needs a Challenge/Solution of its own or another status; that is the author’s decision.
  2. Should index add --headline ... :: CHALLENGE read judged_as from claims.yaml, or check that both agree?

AI assistance

Drafted and implemented by Claude (Anthropic), the lean-pkg operations agent, from the lts-2026.10 stage 0 finding, at Le Chen’s request; to be reviewed and decided by the maintainer.