# Checks The project declares one check in `scienceslack.json`: ```json "checks": { "rank": { "path": "checks/verify.sbatch", "metrics": "rank-metrics.json", "gate": false, "reads": ["CERTIFICATE.json"] } } ``` ## What it verifies `verify.py` reads a route's `CERTIFICATE.json` and proves, for every curve in it, that its listed points are independent modulo torsion, so that the rank is at least their number. It uses only Python's standard library and exact arithmetic: no floating point decides anything. For each curve: - the Weierstrass equation $y^2+a_1xy+a_3y=x^3+a_2x^2+a_4x+a_6$ is nonsingular and every point lies on it; - every torsion point has order at most 12 (Mazur), and there are exactly $\dim E(\mathbb Q)[2]$ of them, which the check computes from the rational roots of $4x^3+b_2x^2+2b_4x+b_6$; - every character $(p,\theta)$ has $p$ an odd prime of good reduction and $\theta$ a root of that cubic mod $p$; - the matrix of $\chi_{p,\theta}(P)=[\,x(P)-\theta$ is not a square mod $p\,]$ over the points and torsion points has full rank over $\mathbb F_2$. Each $\chi_{p,\theta}$ is reduction mod $p$ followed by the 2-descent map at $\theta$, a homomorphism to $\mathbb F_2$ that kills $2E(\mathbb Q)$. Since $\dim_{\mathbb F_2}E(\mathbb Q)/2E(\mathbb Q)=\operatorname{rank}+\dim E(\mathbb Q)[2]$, independent images prove $\operatorname{rank}E(\mathbb Q)\ge\#\text{points}$. This is the method of Cremona's mwrank and of the ICARM rank leaderboard. | Target | Curves | Last line on success | |---|---|---| | `E-1` | any; the example's target | `E-1: 2 curves, rank >= r certified exactly for …` | | `C-1` | the 2,389 curves of rank ≥ 2 and conductor below 10,000 in Cremona's tables, listed in `c1-curves.tsv.gz` (label, a-invariants, rank); a curve counts when it has as many points as its listed rank | `C-1: of 2389 curves, rank >= r certified exactly` | | `C-2` | the three curves of rank ≥ 32 on the ICARM leaderboard, listed in `records.json`, labelled `icarm-` | `C-2: of 3 records, rank >= 32 certified exactly` | A certificate for a piece judged by readers (C-3, C-4, V-…, R-1, L-1) exits 0 saying no verifier exists for it. An unknown target, a point off its curve, a wrong a-invariant, a missing torsion point or a character matrix of too small a rank fails with the first such problem. A route with no `CERTIFICATE.json` passes with "Nothing to check yet". Measured on 2026-11-27 (Apple M4 Pro, one core): the example 0.02 s; all of C-1 0.10 s; all of C-2 0.02 s. `c1-curves.tsv.gz` is read from John Cremona's `ecdata` (`allgens.00000-09999`, Artistic-2.0; the source of the LMFDB's elliptic curve pages): 2,388 curves of rank 2 and 5077a1 of rank 3. `records.json` is read from on 2026-11-27. ## Run it locally ```bash python3 checks/verify.py examples/rank-2-and-3 python3 checks/verify.py routes/ ``` ## Run it on the platform The runner checks out the approved version (the commit tagged `checks`) as the job's working directory and runs `checks/verify.sbatch` from there, with `$SS_INPUT` the pushed commit and `$SS_ROUTE_DIR` the route's folder. The certificate is read from `$SS_INPUT/$SS_ROUTE_DIR`; `rank-metrics.json` is written to the working directory, where the runner looks for the file named by `"metrics"`. A route that edits `checks/` changes nothing about its own verdict. The image is `python:3.12-slim` and the job has no network: the check cannot install packages or download data. Pieces that need PARI (C-3, C-4) wait for a column image a maintainer approves; until then they are judged by readers. ## Add a new check 1. Add a script under `checks/` that exits 0 on success and 1 on the first error, with a clear last line. 2. Write the metrics file named in `scienceslack.json` (`{"score": …, "subtasks": {…}}`) to the working directory. 3. Declare it under `checks` in `scienceslack.json` and open a pull request; the maintainers approve the rules by moving the `checks` tag. A check must recompute the claim or verify a certificate, never repeat an expected number.