Evaluating a Model
Every HEE problem has a formal statement, and the formal statement is its verifier: a Lean answer must compile against Mathlib with the problem spliced in verbatim, and a Python answer must pass domain(x) and fail (or, for an existence claim, pass) check(x). Grading needs no judge model and no reference answer, so a model is graded the same way on problems nobody has solved and on problems with a known solution.
Every problem also has a git-verified opening time, so an evaluation can keep only problems that appeared after a model's training cutoff. This lowers the risk of contamination; it cannot rule it out, since a problem may restate older material.
1. Export a release
hee export --after 2026-06-01 --out ./releaseOnly reviewed problems (stage benchmark or dataset, see Scoring) whose formal statement was merged strictly after the cutoff are exported. Drafts, candidates awaiting review, classic problems, the historical archive and voided problems are not.
| Path | Contents |
|---|---|
benchmark/problems.jsonl | Accepted problems that are still open. No answer is known. |
dataset/problems.jsonl | Accepted problems that have been solved. |
dataset/answers.jsonl | Their outcome (proved, disproved or solved), closing time, solver and checked proof, solution or code. Kept apart from the problems; never show it to the model. |
problems/<name>/ | The verifier of each problem: its README.md and problem.lean, problem.py, or task.py + baseline.py. |
prompts.jsonl | The standard prompt for each problem (id, split, prompt). |
manifest.json | Git revision, cutoff, snapshot time, counts, the Lean and Mathlib versions of the checker, and the HEE canary string. |
Each problem row has id, format (lean, python, or optimize), domain, claim, opened_at, tier (1–5, how long it has survived), points, statement, code, answer_files (the accepted answers and the outcome each establishes, e.g. {"proof.lean": "proved", "disproof.lean": "disproved"}), verifier, and lean_code for a Python problem with a Lean restatement.
2. Collect answers
Give the model the prompt from prompts.jsonl (or your own; see the protocol below) and write one line per attempt to a JSON Lines file:
{"id": "some-problem", "outcome": "proved", "lean": "import Mathlib\n\ntheorem HEE.some_problem.proof : HEE.some_problem := by\n ..."}
{"id": "some-python-problem", "solution": {"rows": [[0, 1], [1, 0]]}}
{"id": "some-optimize-problem", "code": "import numpy as np\n\ndef solve(inp):\n ..."}
{"id": "another-problem", "outcome": null}- Lean (
problem.lean, or the Lean restatement of a Python problem):outcomeand the whole file inlean. The file containstheorem HEE.<name>.proof : HEE.<name>ortheorem HEE.<name>.disproof : ¬ HEE.<name>and must not restate the problem; the checker inserts it. - Python: the object
xinsolution, a counterexample for aforallclaim (it disproves the claim) or a witness for anexistsclaim (it proves it). A Pythonforallclaim can be proved only through its Lean restatement, when it has one. - Optimize (
task.py+baseline.py): the full Python module source incode, definingdef solve(inp): ..., benchmarked in an isolated single-threaded subprocess againstTARGET. {"outcome": null}abstains. Several lines with the sameidare several attempts (used for pass@k).
A bare verdict ("true" or "false") is not an answer: only a proof, disproof, counterexample, witness, or target-beating solution.py that passes the verifier counts.
3. Grade
hee eval --release ./release --answers model.jsonl --lean --k 1,5 --model my-model--lean compiles every Lean answer against Mathlib (--jobs in parallel, --timeout seconds each, default 600). It needs the Lean toolchain and the checker project lean/ of the same HEE revision, or the Docker image below. Without --lean, Lean answers that pass the static checks are marked unverified and the score is not official.
Each answer gets one verdict:
| Verdict | Meaning |
|---|---|
valid | Passes the verifier. |
invalid | A well-formed answer the verifier rejects: a compile error, a forbidden construct, a disallowed axiom, a timeout, or an object that is not a counterexample or witness. |
unverified | A Lean answer that passes the static checks but was not compiled (no --lean). |
malformed | Not a usable answer for this problem, e.g. a JSON solution to a Lean-only problem. |
abstained | {"outcome": null}. |
unknown | The id is not in the release. |
The results go to <answers>-results/ (or --out): results.jsonl with one graded row per attempt, and summary.json:
- dataset (the main score): problems, answered, solved, solve rate, unbiased pass@k for each requested k, points solved out of points available (harder problems count more), and the solve rate per difficulty tier.
- benchmark: the same counts, and
solved_ids. A valid answer here settles a problem nobody had settled: submit it as a pull request (see Getting Started) and it earns points like any other solution. verdicts,official(no unverified answers, and the local Lean and Mathlib match the release), the release revision and checker versions, the SHA-256 of the answers file, andconflicts: problems with valid answers for both outcomes, or a valid answer that contradicts the recorded outcome. A conflict means the problem or the checker is broken; please report it in an issue.
To check a single answer against one problem, in a release or in a clone of the repository:
hee verify release/problems/some-problem proof.lean --lean
hee verify release/problems/some-python-problem x.jsonhee verify prints the verdict and exits with 0 only when the answer is valid. (hee check is the stricter command for pull requests: it also requires the solver header of a closing file.)
Docker
The image ghcr.io/halley-lab/hee contains HEE, the pinned Lean toolchain and a prebuilt Mathlib, so Lean answers can be compiled without installing anything. latest follows main; each build is also tagged sha-<commit>. If the image's Lean or Mathlib differs from the release's, summary.json marks the score as not official.
docker run --rm -v "$PWD:/work" -w /work ghcr.io/halley-lab/hee:latest \
eval --release release --answers model.jsonl --lean --jobs 4Or build it from a clone: docker build -t hee .. Compiling a Lean answer imports Mathlib, which takes a few GB of memory per parallel job.
Protocol
Scores are comparable only under the same conditions. Report them with:
- The release: HEE revision, cutoff (
--after) and snapshot time (as_of), all insummary.json. Use a cutoff no earlier than the model's training cutoff. - Attempts: k, and how pass@k was computed (
hee evalreports the unbiased estimator from n ≥ k attempts). - Budget: tokens or time per problem, and the number of tool calls.
- Feedback: whether the model could run Lean, Python or
hee verifywhile answering, and how many times. Single-shot answers and agentic answers with compiler feedback are different settings; label them. - No retrieval of answers: the model must not see
dataset/answers.jsonl, the closing files in the HEE repository or its website. An agent with internet access must havegithub.com/Halley-Lab/heeandhalley-lab.github.io/heeblocked. - The prompt: the standard prompt from
prompts.jsonl, or the exact prompt used.
Limitations
- The open benchmark consists of problems that no person or model has settled, so solve rates there are expected to be near zero; it records breakthroughs rather than ranking models. The solved dataset is where models are compared.
- The solved dataset is selected by survival: each of its problems resisted everyone for its tier's time before someone solved it.
- A model that believes a Python
forallclaim is true has no way to answer unless the problem has a Lean restatement. - Contamination is limited by the cutoff, not ruled out: a problem may restate older material.