# Formal@Home participation protocol (draft v0.2)

Formal@Home turns published mathematics into checked Lean 4 and Mathlib code. Participants bring
their own AI agent and their own compute. The project runs only a small server: a paper queue,
leases, a build sandbox, task assignment, a public ledger and a queue of items for human
reviewers. Participants do everything else.

**What changed in v0.2.** Each paper is now formalised more than once. At least two authors,
ideally from different model families, state the paper's theorems *blind*. Neither sees the
other's work. A third agent then tries to prove the two versions equivalent in Lean, and the
kernel checks that proof like any other. Only a statement proved equivalent goes on to review
against the paper and then to proving. Pairs that do not agree, and reviews that split, go to a
human reviewer. Most points now go to equivalence proofs, disagreements a human upholds,
accepted statements and kernel-checked proofs.

**Added on 28 Nov 2026.** When two blind versions are not proved equivalent, the target now
escalates to an *entailment graph* (4.6). The server opens more blind slots, provers prove
one-way implications between pairs of versions, and reviewers answer one yes-or-no question
about the condition that separates two versions. The method adapts Acar and Goldweber
(2026) [1] to Lean.

---

## How it works (website version)

1. **Sign in with GitHub and add a key.** You add an SSH ed25519 public key. Your agent signs
   everything it sends with that key. The private half never leaves your machine. Submitting is
   the gift. You release each result you send under Apache-2.0, the licence Mathlib uses. You
   also certify that you had the right to submit it, under the Developer Certificate of Origin
   (DCO).
2. **Claim a paper.** Your agent takes a 72-hour lease on a *statement slot*. You may choose the
   paper for a first slot. The server assigns every further slot on that paper at random, to a
   different person, preferably from another model family. Participants declare their model
   family, and nobody verifies it.
3. **State it twice, blind.** Each author writes the paper's theorems in Lean, with every proof
   left as `sorry`. Submissions are sealed, and the ledger shows only their hash until every slot
   is in. If a slot expires, the server leases it again and the others stay sealed.
4. **Prove they agree.** A third agent, assigned at random, tries to prove `A ↔ B` for each
   target, in both directions. Lean's kernel checks that proof. The result is *consensus* when
   both directions are proved by a proof that relates the two statements, instead of proving one
   of them outright. The versions are then logically equivalent. If they are not, the server
   opens more blind slots, and provers prove one-way implications between pairs of versions.
   These form an entailment graph of the versions (4.6).
5. **Check against the paper.** Two versions can agree and still both be wrong. Two reviewers
   from model families that wrote neither version check the agreed statement against the paper.
6. **Then the proofs.** Our server rebuilds the proofs in a sandbox. It replays them through
   Lean's kernel, or the independent nanoda kernel, against the accepted statements, and allows
   no `sorry` and no extra axioms. Then the server signs the result.
7. **Humans take the hard cases.** A human reviewer gets the gap that a graph leaves after
   escalation. A human also gets the original pair when the versions cannot be split for a
   graph, every split review, and any blind versions that look copied. The reviewer sees the
   paper passage, the Lean versions and the open question side by side. After escalation, the
   reviewer sees the exact condition that separates two versions and answers one yes-or-no
   question about it, such as "Does the paper's result also cover p = 2?".
8. **Earn points.** Most points go to equivalence proofs, disagreements a human upholds,
   accepted statements and kernel-checked proofs. A file that only compiles earns nothing.
   Anyone can recompute the leaderboard from the public ledger.

---

## 1. Critique of the original idea

In the original idea, each participant gets a token from the website, and their agent uses it to
sign the gifts it submits for the leaderboard. Its parts are right: identity, signing, a gift and
a leaderboard. Six things need fixing.

| Original idea | Problem | Fix |
|---|---|---|
| A token from the website | A token is a shared secret, like a password. Only our server can check it, and our server could forge it. Agents leak secrets into logs, transcripts and prompt-injected requests. | Use a **keypair**. The participant keeps the private key, ideally in `ssh-agent`, so the agent can sign without reading it. Anyone can check a signature against the public key. A leaked key can be revoked. |
| The agent signs the gift | An agent cannot grant a licence. Only a person or an organisation can. | The **human** makes the licence grant once, at sign-up. Each signed submission points back to that grant. |
| Signed means counted | A signature proves *who* sent something. It says nothing about whether it is any good. | Points are paid for **verification**, not for submission. |
| "Other agents verify" | In Lean, the kernel already checks that proofs are correct. Asking agents to re-check proofs adds nothing. | Reviewers check **statement fidelity**: does the Lean statement say what the paper says? Machines check axioms and `sorry`. |
| One author, then reviewers | A single formal statement has nothing to compare against, and reviewers judge it by reading alone. | **Two blind statements**, then a **machine-checked equivalence proof** between them. Reviewers judge only an agreed statement, and disagreements become precise Lean goals. |
| Leaderboard of gifts | People optimise whatever is counted. Count submissions and you get spam. Count proofs and you get trivial statements. | Count **paper targets**, meaning the named theorems and lemmas in the paper, not Lean declarations. Take points back when someone finds an error. |

---

## 2. What needs checking

A Lean formalisation can go wrong in two ways. Only one of them needs judgment, and v0.2 adds a
mechanical check that narrows it.

**Correctness (mechanical).** Does the proof prove the stated theorem? Lean's kernel decides
this. The remaining risks are mechanical too, so machines catch them:

- `sorry` left in the proof;
- extra axioms, including `native_decide` (it adds `Lean.ofReduceBool`), custom `axiom`
  declarations and `implemented_by`;
- metaprograms that tamper with the environment, so the compiled `.olean` differs from what
  the kernel would accept. Replaying every declaration through the kernel catches this, and
  that is what `lean4checker`, `leanchecker` and Lean FRO's `comparator` do.

**Fidelity (judgment).** Does the Lean statement mean what the paper means? The kernel cannot
help here. Common failures:

- hypotheses that are contradictory, so the theorem is vacuously true;
- statements that are too weak, for example with a missing quantifier, or `∃` where the paper
  says `∀`;
- junk values: in Lean, `x / 0 = 0` and `(2 : ℕ) - 5 = 0`, so a careless statement can be true
  for the wrong reason;
- custom definitions that do not match the paper's definitions. Definitions are part of the
  statement and must be reviewed with it;
- notation or instance tricks that make the source look right while the elaborated statement
  says something else.

**Agreement (mechanical, with one catch).** Lean cannot compare a statement with a paper, but it
can compare two statements. If two authors read the paper independently and a proof of `A ↔ B`
relates the two, then the versions are *logically equivalent*. Each implies the other, relative
to Mathlib and any custom definitions. Logical equivalence is weaker than meaning the same thing,
and the catch shows why. In Lean every two true theorems are equivalent, and so are every two
false ones. A prover who can prove both sides outright gets `A ↔ B` from `⟨fun _ => proof_B,
fun _ => proof_A⟩`, even when A is faithful and B is a weaker reading that is still true. So an
equivalence proof counts as agreement only when it relates the two statements instead of proving
one of them. Section 4.5 says how the server checks this and what happens when it cannot.

If only `B → A` is proved, the other direction is *open*, not false. B is then possibly
stronger, which usually means a hypothesis is missing from B or added to A. B counts as
*strictly* stronger only once someone proves a refutation (4.5). If neither direction is proved,
the two readings may differ, and often the paper itself is ambiguous. The kernel checks the
equivalence proof like any other proof. It does not replace fidelity review (see 4.7), but it
turns many fidelity questions into precise Lean goals before a person looks at them.

So the protocol **splits each paper into files**. Each author's `Statement.lean` holds the
definitions and theorem statements, all proved by `sorry`. `Equiv.lean` holds the proof that two
statements agree. `Proof.lean` holds the proofs. People and agents review only the agreed
`Statement.lean` against the paper. Machines check `Equiv.lean` and `Proof.lean`. This is the
split into challenge and solution that `comparator` was built for, used twice. It keeps the
part that people must read small, and it makes proof checking fully automatic.

---

## 3. Prior art, briefly

| Project or tool | What it does | What we take |
|---|---|---|
| **BOINC** | Volunteer computing. Accounts use an account key. It sends the same work unit to several hosts and accepts the result when a quorum of them agree. Credit cheating was a long-running problem. | Redundant review with a quorum. Results expire if not returned. Credit only for validated results. |
| **Folding@home** | A username, a team and a "passkey", a per-user secret that unlocks bonus points. Bonus for returning work fast. | This is the website-token idea, and it works for compute credit. It is weak for provenance, because only the server can check it. We keep their simplicity, not the secret. |
| **lean4checker / leanchecker** | Replays every declaration in a compiled environment through the kernel. | Server-side kernel replay. We never trust client `.olean` files. |
| **comparator** (Lean FRO) | A checker for untrusted proofs. Inside a sandbox, it checks that a solution proves exactly the theorems in a challenge file, using only allowed axioms. It replays them through Lean's kernel or the independent Rust kernel `nanoda`. | The main part of our automatic check, for both proofs and equivalence proofs. |
| **Entailment Graphs** (Acar and Goldweber 2026 [1]) | A language model writes many candidate formalisations of one sentence. A solver orders them by strict entailment, and a language model answers one local question per edge. Proved safe when that model never accepts a false check. Tested on Amazon Web Services cloud security rules. | Escalation when two blind versions disagree (4.6), adapted to Lean by comparing hypotheses and conclusions separately. |
| **Double data entry, N-version programming** | Two people or teams do the same task independently, and a mismatch is a flag. The known weakness is that independent workers make correlated mistakes. | Two blind statements per paper, compared by a machine-checked equivalence proof. We document the correlated-error weakness (4.5). |
| **Mathlib review** | GitHub pull requests, human reviewers and maintainers, linters, a merge queue. Apache-2.0, no CLA. Reviewers judge generality and style as well as correctness. | Formal@Home does **not** bypass Mathlib. Our library is a staging area. Upstreaming to Mathlib goes through Mathlib's normal review and earns a bonus. |
| **Sigstore** | Keyless signing. A short-lived certificate is tied to an OpenID login, such as GitHub, and signatures go into a public transparency log (Rekor). | The transparency-log idea: a public, append-only ledger. Full Sigstore is a later upgrade. It is awkward for headless agents today. |
| **ed25519 / SSH signing** | `ssh-keygen -Y sign` and `-Y verify` with a namespace. Git can sign commits this way. GitHub publishes each user's public keys at `https://github.com/<user>.keys`. | Our signing method. Nothing new to install, and keys can be pre-filled from GitHub. |
| **GitHub OAuth** | Login with GitHub. | Sign-up only. It ties a key to a real account of some age, which makes fake accounts slower to create. |
| **DCO vs CLA** | DCO: a one-line "Signed-off-by" certifying you have the right to submit, as used by the Linux kernel. CLA: a separate contract that licenses or assigns rights to a body. | DCO. No assignment, no paperwork, nobody owns the pool. |
| **Apache-2.0** | Permissive licence with attribution and a patent grant. Section 5 says contributions to an Apache-2.0 work are under Apache-2.0 unless stated otherwise ("inbound = outbound"). Mathlib uses it. | Our licence. Accepted code can move into Mathlib with no relicensing. |

---

## 4. The protocol

### 4.1 Identity: a keypair, bound to GitHub once

**We recommend an ed25519 SSH keypair, not an API token.**

| | API token (bearer) | ed25519 keypair | Sigstore keyless |
|---|---|---|---|
| Who can check it | Only our server | Anyone, offline | Anyone, via a log |
| If it leaks | Silent misuse until rotated | Revoke the key; the ledger shows what it signed | Certificate expires in minutes |
| Agent can use it without seeing it | No | Yes, via `ssh-agent` | Partly |
| Tools needed | `curl` | `curl` and `ssh-keygen` (already installed) | `cosign` and an OpenID flow |
| Proves provenance later | No | Yes | Yes |

How it works:

- Sign in at the website with GitHub. Add one or more SSH ed25519 public keys, one per agent
  machine if you like, each with a label. The site can pre-fill them from
  `https://github.com/<user>.keys`.
- Every write request, such as a lease, a submission or a review, is a small JSON file plus its
  SSH signature, made with the namespace `formalathome`. The JSON includes the key fingerprint,
  a timestamp and a random nonce. The server rejects timestamps older than 5 minutes and reused
  nonces.
- There is no separate API token. The signature is the authentication.
- Reads of the paper queue, the ledger and the leaderboard are public and need no
  authentication.

### 4.2 Papers and leases

- **Targets.** A paper is split into *targets*, the named results in it, such as "Theorem 1.2"
  and "Lemma 3.4". The queue lists papers and their targets. Authors can propose targets the
  queue missed, and the equivalence step and reviewers confirm them.
- **Statement slots.** Each paper has at least two statement slots, A and B, and more for papers
  that turn out contentious. Each slot is a 72-hour lease. Holders of slots on the same paper
  must be different accounts, must not share a key or a recent IP address, and should be from
  different model families; the server enforces the first two and prefers the third.
- **Who gets which slot.** You may name the paper for a first slot. The server assigns every
  later slot at random among participants who asked for statement work, so two friends cannot
  arrange to hold both slots of one paper.
- **No lease cycling.** Releasing an assigned slot, or letting it expire, costs a 24-hour wait
  before the next assignment, and the server never assigns that paper to that account again.
  Three releases or expiries in 30 days pause the account's statement work for a week. This
  stops anyone taking and dropping slots until the paper they want comes up.
- **Equivalence lease.** Once every slot is in, the server reveals the versions *to the
  equivalence prover only* and opens an equivalence task. Like later statement slots, it is
  assigned at random, to an account that held no slot on the paper and holds no proof of any of
  its targets, ideally from a third model family. The lease lasts 72 hours. If it ends without a
  two-way proof, a second prover, also assigned at random and from another family, gets a turn
  before the pair goes to a human.
- **Proof lease.** There is one per accepted target, and it also lasts 72 hours. Proof leases
  open only after the equivalence step and fidelity review, never before. Unleased targets are
  open to anyone.
- **Limits.** An account can hold at most 2 active leases. A lease can be renewed up to 3 times,
  and each renewal must carry a hash of the current work in progress, so holding a lease takes
  work. When a proof lease expires, the target goes back to the queue. When a statement lease
  expires, the server leases that slot again, at random, and the versions already in stay
  sealed. After 3 re-leases of one slot the paper waits, still sealed, until a maintainer looks
  at it.
- **Review assignments.** These expire after 24 hours.

### 4.3 Submission bundle

A bundle is a small Lake project plus a signed manifest:

```
bundle/
  formalathome.json        manifest (signed)
  formalathome.json.sig    ssh-keygen -Y sign output
  lean-toolchain           e.g. leanprover/lean4:v4.x.0
  lakefile.toml
  lake-manifest.json       pins the exact Mathlib commit
  FAH/Arxiv240101234/A/Statement.lean   (statement bundles: your slot only)
  FAH/Arxiv240101234/Equiv.lean         (equivalence bundles only)
  FAH/Arxiv240101234/Edge_C_A.lean     (implication bundles only)
  FAH/Arxiv240101234/Proof.lean         (proof bundles only)
```

There are four submission kinds:

| `kind` | Contains | Checked by |
|---|---|---|
| `statement` | One slot's `Statement.lean`: each target as a `Prop` plus a `sorry`'d theorem. Sealed until all slots are in, and public only once the target is settled. | Lints and probes (4.4), then the equivalence step and fidelity review. |
| `equivalence` | `Equiv.lean`, proving the server's goals `A.t ↔ B.t`, plus a declared `result` per target: `both`, `a_to_b`, `b_to_a` or `none`, and optionally a refutation (for example `¬ B.t`). | `comparator` against the server-written challenge. |
| `implication` | After escalation only (4.6). One `Edge_<u>_<v>.lean` per edge, which says that version u implies version v. It holds the variable alignment, the two pointwise proofs and the separating condition with its proof of exactness. | `comparator` against the server-written split of each version, and a check of the alignment against the allowed list. Then the already-known probe on each split side alone (4.4 step 5), and the relate-don't-prove check (4.4 step 11) on every pointwise proof. |
| `proof` | `Proof.lean`, proving the accepted statement. | `comparator` against the accepted `Statement.lean`. |

Manifest:

```json
{
  "schema": "formalathome/submission/v2",
  "kind": "statement",
  "lease": "L-8f3c",
  "slot": "A",
  "blind": "I have not seen another version of these statements.",
  "prior": [],
  "paper": { "id": "arXiv:2401.01234v2", "pdf_sha256": "9b1e…" },
  "toolchain": "leanprover/lean4:v4.x.0",
  "mathlib": "3f0c2a9…",
  "targets": [
    { "label": "Theorem 1.2", "page": 4,
      "decl": "FAH.Arxiv240101234.A.theorem_1_2",
      "quote": "Every finite group of order p^2 is abelian." }
  ],
  "files": {
    "FAH/Arxiv240101234/A/Statement.lean": "sha256:51aa…"
  },
  "agent": { "family": "anthropic", "model": "claude-opus-5-5", "harness": "claude-code" },
  "licence": "Apache-2.0",
  "dco": "Signed-off-by: Ada Example <github:adaexample> (DCO 1.1)",
  "key": "SHA256:Qm3x…",
  "ts": "2026-11-27T16:02:11Z",
  "nonce": "c0b5d1e2a9f48a73e1d2b6c4"
}
```

An equivalence manifest differs only in these fields:

```json
{
  "kind": "equivalence",
  "lease": "L-91d0",
  "pair": ["S-31a9", "S-40b2"],
  "results": [
    { "label": "Theorem 1.2", "result": "both" },
    { "label": "Lemma 3.4", "result": "b_to_a",
      "note": "B drops the hypothesis n ≥ 1; ¬ B.lemma_3_4 proved at n = 0" }
  ],
  "files": { "FAH/Arxiv240101234/Equiv.lean": "sha256:7c02…" }
}
```

An implication manifest differs in the same way:

```json
{
  "kind": "implication",
  "lease": "L-a4e7",
  "target": "Theorem 1.2",
  "edge": { "stronger": "S-52c0", "weaker": "S-31a9" },
  "alignment": "identity on (G, p)",
  "alignment_kind": "reordering",
  "separating": { "side": "hypotheses", "condition": "p.Prime" },
  "files": { "FAH/Arxiv240101234/Edge_C_A.lean": "sha256:e19b…" }
}
```

Statement files state each target twice: as a proposition, which is what gets compared, and as a
theorem, which is what gets proved.

```lean
/-- **Theorem 1.2** (p. 4): "Every finite group of order p^2 is abelian." -/
def theorem_1_2 : Prop :=
  ∀ (G : Type) [Group G] [Fintype G] (p : ℕ),
    p.Prime → Fintype.card G = p ^ 2 → ∀ a b : G, a * b = b * a

theorem theorem_1_2_holds : theorem_1_2 := by
  sorry
```

The server, never an author, writes the equivalence challenge from the two revealed files:

```lean
import FAH.Arxiv240101234.A.Statement
import FAH.Arxiv240101234.B.Statement

theorem equiv_theorem_1_2 :
    FAH.Arxiv240101234.A.theorem_1_2 ↔ FAH.Arxiv240101234.B.theorem_1_2 := by
  sorry
```

Rules:

- The manifest lists a SHA-256 hash for every Lean file. The server hashes what it unpacks and
  rejects any mismatch. Signing the manifest therefore signs the whole bundle, and tar
  determinism does not matter.
- **Toolchain.** The project names one current Lean and Mathlib pair, normally Mathlib's monthly
  tagged release, and keeps a build cache for it. Bundles on the previous pair are accepted for
  60 days. This is the only version coordination participants do.
- **File header.** Each Lean file starts with a Mathlib-style header: copyright line,
  `Released under Apache 2.0 license`, and an `Authors:` line naming the account and the model.
- **Docstrings.** Each target declaration has a docstring with the paper label, page and a short
  quote. Reviewers read these side by side with the PDF.
- **Definitions.** Use Mathlib's definitions wherever they exist. A custom definition is allowed
  only when Mathlib has none, and must say so in its docstring. Two authors who each define the
  same object make the equivalence proof much harder (4.5).
- **Universes.** Statements quantify over `Type` (universe 0), not `Type*`. The paper's
  mathematics does not depend on universes, and a fixed universe keeps the server's goal
  `A.t ↔ B.t` well typed with no universe lifting. Otherwise one version in `Type` and one in
  `Type*` would need a transfer through `ULift`, a common source of spurious one-way flags. A
  target that needs a higher universe declares it, and the server's goal then instantiates both
  versions at the same universe variables.
- **Blindness declaration.** Every statement manifest carries the signed `blind` line. Breaking
  it can void the submission and the account's points on that paper.
- **Public formalisations.** If the paper ships Lean code, for example in its arXiv ancillary
  files, or a public formalisation exists elsewhere, an author may use it only by declaring it in
  `prior`, with a URL and commit. A declared prior makes the slot a reference slot (4.11),
  which earns no blind-author points. Using one without declaring it breaks the blindness
  declaration.

### 4.4 Automatic checks (server, in a sandbox with no network)

On every bundle:

1. Build from source with the pinned toolchain and Mathlib cache. Client `.olean` files are
   ignored.
2. Lint `Statement.lean`:
   - no `axiom`, `opaque` with implementation, `implemented_by` or `extern`;
   - no `notation`, `macro`, `syntax` or `elab`. Local instances are allowed but flagged to
     reviewers;
   - every target in the manifest exists and has a docstring.
3. **Triviality probe.** Try `simp`, `aesop`, `omega`, `decide` and `exact?` on each target,
   10 seconds each. If one closes it, the server flags it "trivial?" for reviewers.
4. **Vacuity probe.** Try the same tactics on `False` with the target's hypotheses in context.
   If one succeeds, the statement is rejected outright.
5. **Already-known probe.** Try `exact?` against Mathlib. Also look for the paper's own Lean
   code in its arXiv ancillary files and in repositories linked from the paper. Then look for
   known public formalisations in Mathlib's Archive, Formal Conjectures and a maintained list of
   repositories, matched by paper id and by statement. A hit routes the target to the
   reference-slot or duplicate path (4.11, 0 points), because two blind authors could otherwise
   copy the same public source and agree perfectly. The server also records when a side is
   provable outright, for use in the equivalence step (4.5). For an implication bundle, it
   records the same for each split side alone (4.6).
6. Render each target's **elaborated** type twice: normally, and with notation turned off
   (`pp.notation false`). Reviewers see these renderings as well as the source.

7. **Seal.** The server stores a statement bundle privately. The ledger records only its hash,
   size and time. Nothing is revealed while fewer than two versions are in, or while any slot is
   still out. An expired slot is leased again (4.2), and the versions already in stay sealed.
   Once every slot is in, the server reveals the versions to the equivalence prover, and later
   to reviewers and any human reviewer. None of them may hold a statement slot on that paper. The
   server publishes the versions on the ledger only when the target is settled, meaning accepted
   or ruled on by a human. The hash proves nobody changed their version after another was seen.
8. **Similarity check, on reveal.** Compare the versions after normalising whitespace and
   bound-variable names. For short targets, independent statements in Mathlib style are often
   near-identical. For example, two models will both write
   `∀ (G : Type) [Group G] [Fintype G] …`. So the check looks at what independent authors rarely
   share, such as comments, docstring wording, and helper definitions and their names. It runs
   only on files above a size threshold, with a draft figure of 40 lines of statements and
   definitions. A match is held for a human (4.8) and earns nothing until cleared. A "copied" ruling needs evidence beyond textual similarity, such as
   shared unusual comments or the same mistake in a helper definition.

On equivalence and proof bundles, in addition:

9. Run `comparator`. For an equivalence bundle the challenge is the server-written `Equiv.lean`
   goals; for a proof bundle it is the accepted `Statement.lean`. Allowed axioms: `propext`,
   `Classical.choice`, `Quot.sound`. Comparator checks that each target has exactly the required
   type and that no `sorry` or extra axiom is used. It also replays every declaration through
   Lean's kernel. For extra assurance, comparator can also replay through `nanoda`, an independent
   kernel written in Rust.
10. **The server signs the result** (bundle hash, challenge hash, toolchain, verdict) with the
    project's checker key and appends it to the ledger. The website trusts that signature. A
    submitter's own signature proves only who sent the bundle, never that it is correct.

11. **Equivalence and implication bundles: relate, don't prove.** For each direction, the server
    normalises the proof term by beta, zeta and projection reduction and by unfolding `id`-like
    wrappers. Then it checks that the term still depends on its hypothesis. For example, in
    `A → B` the proof must use the `A`. A direction that does not, or an `Equiv.lean` that contains a closed proof of
    either side, is recorded as *proved outright*. The triviality probe (step 3) is also run on
    the iff itself, and on each side. For an implication bundle, the check runs on each
    pointwise proof, and on the conclusion proof with the hypotheses in context when that proof
    takes them.

A proof that passes step 9 is accepted. An equivalence result counts exactly as far as its
proofs go: `both` needs both directions proved; a declared `a_to_b` needs that direction proved.
A `both` result counts as consensus only if step 11 found no direction proved outright and no
side is known to be provable outright (step 5); otherwise see 4.5. No people or agents are
involved. Anyone can rerun comparator on the public bundles and compare with the signed verdict.

Step 11 is a heuristic. It catches the plain case, `fun _ => proof_B`, but a prover determined
to disguise a proof of B as a use of A can do so. Other rules limit the damage. The prover is
assigned at random and holds no proof of either side. The points for an equivalence are paid
only after the agreed statement passes fidelity review (4.10). Reviewers always see both blind
versions.

### 4.5 Consensus: blind statements and machine-checked equivalence

- **Blind.** Authors of the same paper never see each other's work. This rests on sealed
  submissions (4.4 step 7), random assignment of later slots (4.2) and a signed blindness
  declaration. Until the target is settled, only the equivalence prover, reviewers and human
  reviewers see the versions, and none of them may hold a statement slot on that paper.
- **Equivalence task.** After every slot is in, a third agent, assigned at random, proves
  `A.t ↔ B.t` for each target. It may not edit either statement, because the server writes the
  goals. It declares a result per target and submits the proofs. Only the kernel check (4.4
  step 9) and the relate-don't-prove check (4.4 step 11) decide the result.
- **Relate, don't prove.** Every two true theorems are equivalent in Lean, so an equivalence
  proof counts as agreement only when it relates the two statements instead of proving one of
  them. If a direction is proved outright (4.4 step 11), or either side is already known to be
  provable or refutable outright (4.4 step 5), the pair is not a consensus. Both
  versions go to fidelity review *as a pair*, each judged against the paper, and the
  equivalence earns no points.
- **Outcomes, per target.**
  - *Both directions proved, relating the statements*: **consensus**. The versions are
    *logically equivalent*. Lean has checked that each implies the other, relative to Mathlib
    and any custom definitions. That is evidence they say the same thing, not proof. The server
    picks one as the canonical text, by default the one with fewer custom definitions. That
    text goes to fidelity review (4.7), with the other beside it.
  - *One direction only*: the other direction is **open**, so one version is *possibly
    stronger*. Usually a hypothesis is missing from the stronger one or added to the weaker
    one. The target escalates to a graph (4.6), with the unproved direction as an open edge. It
    goes straight to a human (4.8) only if the versions cannot be split. The version counts as
    *strictly stronger* only when someone proves a refutation (next point).
  - *Neither direction*: a **disagreement**, or just a hard proof. If a second prover from
    another family also fails, the target escalates to a graph (4.6). It goes straight to a
    human (4.8) only if the versions cannot be split. The cause may be a real ambiguity in the
    paper.
- **Failing to prove is not proof of difference.** The strongest evidence that two versions
  differ is a Lean proof that one of them is false, for example `¬ B.t` with A accepted or
  proved. A concrete instance where one version's hypotheses hold and the other's conclusion
  fails is equally strong. Provers earn points for these (4.10).
- **More slots when needed.** A target that ends with one direction or none gets more blind
  slots, up to five versions in all, and escalates to an entailment graph (4.6). The new slots stay blind
  because the first two versions are still unpublished (4.4 step 7), and the server assigns the
  new authors at random from accounts that have not seen them. A version that agrees with one of
  the first two does not win a majority vote, because the models' errors are correlated
  (Caveat 2). In the study behind 4.6, majority vote over groups of equivalent candidates chose
  a candidate that was too weak in 5 of 20 cases [1].
- **Caveat 1: definitions.** Equivalence proofs are often short when both versions use
  Mathlib's definitions. When each author introduces their own definitions, someone must relate
  the definitions first, with a proof that the two `def`s agree or an isomorphism of the
  structures involved. That is much harder. For this reason the rules push authors to Mathlib's
  definitions. A shared definitions area, `FAH/Common`, is still being designed, and it should
  let later papers reuse agreed definitions.
- **Caveat 2: agreement is not correctness.** Models share training data and habits, so their
  errors are correlated. Two blind versions can agree and both be wrong in the same way. For
  example, both may use `ℕ` subtraction where the paper means integers, or both may copy the
  same public formalisation (4.4 step 5). Blind authors from different model families make this
  less likely, but not impossible. That is why fidelity review against the paper (4.7) follows
  consensus, why challenges stay open, and why maintainers audit a share of accepted
  statements.

### 4.6 Escalation: an entailment graph of versions

This section adapts a method from Acar and Goldweber (2026) [1]. Their setting differs from
ours, and the parts that differ are marked as Formal@Home's adaptation. It is a design proposal,
and nobody has tested it on maths papers.

**What the paper does.** The paper formalises one sentence of natural language at a time. A
language model writes a pool of candidate formulas. A solver orders them by strict entailment
in an *Entailment Graph*. Equivalent candidates share one node, and the pool is completed with
True and False. Each edge runs from a stronger candidate u to a weaker candidate v and carries
two formulas. The *residual*, v implies u, is the extra content that the stronger candidate
adds. The *co-residual*, v and not u, describes the extra cases that the weaker candidate
admits. A language model then acts as an *entailment oracle*. It answers one local question per
edge, about that edge's residual or co-residual, and never a global question about a whole
candidate. Two searches give the *sufficient frontier*, the weakest candidates that entail the
sentence, and the *necessary frontier*, the strongest candidates that the sentence entails. The
downward search, towards the sufficient frontier, checks each edge's co-residual. The upward
search, towards the necessary frontier, checks each edge's residual. Between the two frontiers
lies the *ambiguity residue*. This formula holds exactly of the situations that the candidates
leave undecided, and the sentence is ambiguous exactly when the residue is satisfiable. An
oracle is *sound* if it never accepts a check that fails, and *complete* if it accepts every
check that holds. A sound oracle makes the selection safe whatever the quality of the pool. A
complete one makes the frontiers tight. The authors machine-checked their proofs in Lean, over
an arbitrary Boolean algebra. The Lean proofs do not cover the language model or the syntax of
the formulas.

**The paper's evidence.** The authors tested the method on security properties for Amazon Web
Services, where a satisfiability solver decides each entailment. Unsafe there means too weak,
so that the chosen formula admits a violation. The method was safe in all 20 cases that an
expert adjudicated. On the same cases, majority vote over groups of equivalent candidates was
unsafe in 5, and Universal Self-Consistency, where one model picks the most consistent
candidate, was unsafe in 2. An ablation kept the oracle but removed the graph, so it asked one
global question per candidate. It was unsafe in 5 of the 20 cases and rejected every candidate
in another 6. The authors also checked 152 more statements without an expert. Counting 10 pools
with no sufficient candidate as abstentions, the method was safe on at least 149 of them.

**When the graph is used.** Two blind versions per target stay the default. The order of events
is the same for every target:

1. If the equivalence step ends with one direction proved, or with no proof after two provers
   (4.5), the target escalates to a graph. It does not go to a human yet.
2. Escalation needs versions that split into variables, hypotheses and conclusions, as described
   below. A target whose versions do not split goes straight to a human with the original pair
   (4.8).
3. After escalation, a human sees only the gap that the two walks leave, with the edge questions
   that stopped them (4.8).

Escalation works like this:

- The server opens more blind slots, for up to five versions in all. The figure is a draft.
  The slots are assigned at random, as in 4.2, and ideally to model families that have not
  stated the target. Earlier versions stay unpublished, and the new authors never see them.
- Once every slot is in, provers lease *implication tasks*. Each task names a pair of versions
  and asks for an implication in either direction, proved split-wise as below.
- A pair proved split-wise in both directions merges into one node. A whole-statement proof of
  `A.t ↔ B.t` from 4.5 does not merge nodes, because it can rest on the truth of the two
  theorems.
- The kernel-checked implications between nodes form the target's entailment graph, ordered
  from the strongest version to the weakest.

**Compare hypotheses and conclusions, not whole statements.** This part is Formal@Home's
adaptation, not something the paper says. Section 2 gave the catch. In Lean, every statement
implies a closed true statement, and a closed false statement implies every statement. A graph
over whole closed statements would therefore put every false version above every true one and
say nothing about meaning. The paper's candidates are formulas about situations, such as cloud
configurations, and one candidate entails another only if it does so in every situation. The
analogue in Lean is to treat the values of a target's variables as the situations.

The paper itself warns about this kind of split. Its Related Work paragraph on contracts says
that refining a pair of an assumption and a guarantee is contravariant in the assumption and
covariant in the guarantee. It says that running its searches on the two parts separately is
therefore not sound, and it leaves that extension to future work. Formal@Home's edge test is
exactly that refinement order, so none of the paper's theorems cover it. The safety argument
below is Formal@Home's own.

- **Split.** The server reads each version's leading universal binders off its elaborated
  statement. It splits the version into its variables x, a *hypothesis* `H x` and a
  *conclusion* `C x`, so that the version is `∀ x, H x → C x`. Binders that are propositions,
  and instances that are propositions such as `[Fact p.Prime]`, go into the hypothesis as one
  conjunction. So `p.Prime → Nat.card G = p ^ 2 → …` and `p.Prime ∧ Nat.card G = p ^ 2 → …`
  give the same split. The server checks each split with a fixed proof that only uncurries the
  hypotheses with `and_imp`. Nobody can choose a split that makes an edge trivial.
- **Alignment.** The prover supplies an alignment `f`. This Lean function maps the weaker
  version's variables to the stronger version's variables. The draft rule allows only
  reorderings, coercions such as ℕ to ℤ, and equivalences already in Mathlib. An alignment may
  use the weaker version's hypothesis only to build an instance that Lean treats as unique,
  such as `[Fintype G]` from a proof that G is finite. Lean checks only that `f` is well typed,
  not that it is the intended match. So the server checks `f` against the allowed list, and
  reviewers see it beside the separating condition. Without this rule, a false version would
  imply every version. The prover would send every value to one counterexample `x₀`. Then
  `H_u x₀` holds, and `C_u x₀ → C_v y` holds because `C_u x₀` is false.
- **Edge.** To show that version u implies version v, the prover proves two pointwise
  implications, `∀ y, H_v y → H_u (f y)` for the hypotheses and `∀ y, C_u (f y) → C_v y` for
  the conclusions. Together they give `u → v`. Usually neither a hypothesis nor a conclusion is
  a theorem by itself, so a prover usually cannot prove these implications by proving the
  theorem outright.
- **Sides that are provable outright.** That fails in three cases. A version may have no leading
  universal variables, for example one that starts with `∃ c > 0, ∃ N₀, …`, as much of analysis
  and number theory does. Its conclusion may hold for every value of the variables. Or the
  split may leave the hypothesis as `True`, for example when an author hides the hypotheses
  inside a `def`. So the server runs the already-known probe (4.4 step 5) on each side alone,
  on `C_v` and on `H_u ∘ f`. It also runs the relate-don't-prove check (4.4 step 11) on every
  pointwise proof. An edge that fails either check does not count.
- **Conclusions that need the hypotheses.** Sometimes two conclusions agree only under the
  hypotheses, for example when one uses `Fintype.card G` and the other `Nat.card G`. The
  conclusion proof may then take `H_v y` as context. With that context a prover could ignore
  `C_u` and prove `C_v y` from the theorem itself, so the relate-don't-prove check matters most
  here.
- **The backstop.** The relate-don't-prove rule still applies to every edge. It is the only
  guard when the split leaves the hypothesis as `True`. Versions with no leading universal
  variables cannot be split at all, so they do not escalate (see the order of events above).
- **The way a version is written matters.** Uncurrying removes the difference between curried
  and `∧` forms. It cannot see a hypothesis that an author wrote into the conclusion, for
  example as `¬ p.Prime ∨ …`. Two versions that say the same thing in those two forms are left
  unrelated. So the split order is finer than implication between whole versions, and the
  graph can miss edges that a whole-statement proof would find.

**Why the split is safe.** Say the paper's statement has hypothesis `H_s` and conclusion `C_s`
over the same variables. Suppose `H_s` implies a version's hypothesis, and under `H_s` the
version's conclusion implies `C_s`. Then a proof of the version proves the paper's statement.
The downward walk keeps exactly this pair of facts true at every step, if every yes-answer is
right. The lemmas below compile in core Lean 4.35. `concl_step` needs excluded middle, as the
paper's downward search does.

```lean
theorem split_safe {X : Type} (Hs Cs Hf Cf : X → Prop)
    (hH : ∀ x, Hs x → Hf x) (hC : ∀ x, Hs x → Cf x → Cs x) :
    (∀ x, Hf x → Cf x) → ∀ x, Hs x → Cs x :=
  fun h x hs => hC x hs (h x (hH x hs))

-- Downward step on a hypothesis edge: the paper assumes the separating condition S.
theorem hyp_step {X : Type} (Hs Hu Hv S : X → Prop) (exact : ∀ x, Hv x ↔ Hu x ∧ S x)
    (inv : ∀ x, Hs x → Hu x) (yes : ∀ x, Hs x → S x) : ∀ x, Hs x → Hv x :=
  fun x hs => (exact x).2 ⟨inv x hs, yes x hs⟩

-- Downward step on a conclusion edge: the extra cases Cv ∧ ¬Cu still meet the paper's claim.
theorem concl_step {X : Type} (Hs Cs Cu Cv : X → Prop)
    (inv : ∀ x, Hs x → Cu x → Cs x) (yes : ∀ x, Hs x → Cv x ∧ ¬ Cu x → Cs x) :
    ∀ x, Hs x → Cv x → Cs x := by
  intro x hs hv
  by_cases hu : Cu x
  · exact inv x hs hu
  · exact yes x hs ⟨hv, hu⟩
```

**Separating condition.** The separating condition is Formal@Home's analogue of the paper's two
edge formulas. For each proved one-way edge, the prover states it as a short formula `S` and
proves that it is exact under the alignment.

- On a *hypothesis edge*, `S` is a hypothesis that the weaker version adds, such as `p.Prime`.
  Exact means `H_v y ↔ H_u (f y) ∧ S y`.
- On a *conclusion edge*, `S` is a claim that the stronger version adds, such as `IsCyclic G`.
  Exact means `C_u (f y) ↔ C_v y ∧ S y`.

Many formulas are exact, including `H_v` itself. So the server also shows the canonical
formulas next to the prover's `S`: `H_u (f y) → H_v y` on a hypothesis edge, and
`C_v y ∧ ¬ C_u (f y)` on a conclusion edge. The kernel checks every exactness proof, so the
formula a reviewer reads is one that separates the two versions.

```lean
-- Version C: ∀ (G : Type) [Group G] (p : ℕ), Nat.card G = p ^ 2 → ∀ a b : G, a * b = b * a
-- Version A: ∀ (G : Type) [Group G] (p : ℕ), p.Prime → Nat.card G = p ^ 2 → ∀ a b : G, a * b = b * a
-- Version E: as A, but the conclusion is IsCyclic G
-- Version B: ∀ (p : ℕ) [Fact p.Prime] (G : Type) [Group G] [Fintype G],
--              Fintype.card G = p ^ 2 → ∀ a b : G, Commute a b
-- The server's split. A is curried, so the server uncurries it with and_imp:
def C.hyp (G : Type) [Group G] (p : ℕ) : Prop := Nat.card G = p ^ 2
def A.hyp (G : Type) [Group G] (p : ℕ) : Prop := p.Prime ∧ Nat.card G = p ^ 2
def A.concl (G : Type) [Group G] : Prop := ∀ a b : G, a * b = b * a
def E.concl (G : Type) [Group G] : Prop := IsCyclic G

-- Edge_C_A.lean: a hypothesis edge. The alignment is the identity on (G, p).
theorem edgeCA_hyp (G : Type) [Group G] (p : ℕ) : A.hyp G p → C.hyp G p := fun h => h.2
-- Separating condition p.Prime. Exact: A.hyp G p ↔ C.hyp G p ∧ p.Prime.
theorem edgeCA_exact (G : Type) [Group G] (p : ℕ) : A.hyp G p ↔ C.hyp G p ∧ p.Prime :=
  and_comm

-- Edge_E_A.lean: a conclusion edge. Separating condition IsCyclic G.
theorem edgeEA_concl (G : Type) [Group G] : E.concl G → A.concl G := by
  intro h a b
  have : IsCyclic G := h
  exact (IsCyclic.isMulCommutative (α := G)).is_comm.comm a b

-- Edge_B_A.lean: B has the extra variable [Fintype G], so the alignment from A's variables
-- to B's must build it from A's hypothesis. That is the one use of a hypothesis allowed.
noncomputable def alignBA (G : Type) [Group G] (p : ℕ) (h : A.hyp G p) : Fintype G :=
  haveI : Finite G := Nat.finite_of_card_ne_zero (by rw [h.2]; exact pow_ne_zero 2 h.1.ne_zero)
  Fintype.ofFinite G
```

Version C claims the result without assuming that p is prime, so it is the stronger version.
It is false at p = 4. The edge from C to A still means something, because it relates the
hypotheses and the conclusions for every G and p under a plain alignment. It does not compare
the truth of the two theorems. This example compiles against Mathlib with Lean v4.35.0, checked on 28 Nov 2026.

**Edge questions.** Fidelity reviewers (4.7) answer the graph's questions. Two reviewers from
families that wrote none of the versions see one edge at a time. They get the separating
condition, the canonical formula, the alignment, the paper passage and the versions on either
side. They answer one yes-or-no question about that edge, instead of "Which version is right?".
Neither sees the other's answer until both are in. Every question is phrased so that yes means
"take the step". The hypothesis order runs opposite to the theorem order, because a weaker
version has a stronger hypothesis. So each walk asks the residual on one side and the
co-residual on the other:

| Walk | Hypothesis edge, such as C to A | Conclusion edge, such as E to A |
|---|---|---|
| Downward, from strong to weak | Reviewers see `S`, the residual of the hypotheses. "Does the paper assume p is prime?" | Reviewers see `C_v ∧ ¬ S`, the co-residual of the conclusions. "Does the paper claim only that G is commutative, and not that G is cyclic?" |
| Upward, from weak to strong | Reviewers see `H_u ∧ ¬ S`, the co-residual of the hypotheses. "Does the paper's result also cover groups of order p² where p is not prime?" | Reviewers see `S`, the residual of the conclusions. "Does the paper also claim that G is cyclic?" |

An edge that changes both sides gets one question per side, and a step needs yes to both.

**The walk.** Formal@Home's main risk is a statement that is too weak, because a statement that
is too weak can still be proved and accepted. So the server walks the graph downward, towards
the paper's sufficient frontier. It starts at the strongest versions. The first question at
each start is global, not about one edge: does this version assume no more than the paper and
claim at least what the paper claims? The paper notes the same about searches that start from
roots, and its ablation shows that global questions are where its model erred. So this check
gets the strongest scrutiny, with two reviewers and a maintainer audit of every start that
leads to an accepted node. The walk steps down an edge only when both reviewers answer yes, and
it stops at the weakest versions it can reach. A second walk goes upward from the weakest
versions with the mirror questions. It stops at the strongest versions that claim no more than
the paper. In the example, the downward walk steps from C to A and from E to A. On the edge
from A to D, "Does the paper assume p is odd?", the reviewers split, so the walk stops at A.
The upward walk starts at D. On "Does the paper's result also cover p = 2?" the reviewers split
again, so it stops at D.

**The gap.** If both walks end at the same node, that node becomes the agreed statement. It then
goes to fidelity review (4.7) like any other agreed statement. Otherwise the gap between the two
ends is the analogue of the paper's ambiguity residue. It is the set of values of the variables
that the stronger end covers and the weaker end does not, for example
`p.Prime ∧ Nat.card G = p ^ 2 ∧ p = 2`. A human settles exactly that gap (4.8). It may be a real
ambiguity in the paper. Nobody has measured how often.

**Wrong answers are not symmetric.** In the downward walk, a wrongly rejected step leaves the
walk at a stronger version. A proof of that version still proves the paper's result, so the
result is never too weak. Only a wrongly accepted step can let a mismatch through. In the
paper's terms, a sound oracle is enough for safety, and completeness only makes the result
tight. So yes-answers get the scrutiny. A step needs two independent yes-answers, canary edges
test reviewers who say yes (4.7), and maintainers audit accepted steps. A no still has costs.
The version it leaves may claim more than the paper, and it may be false, like C. That costs
proof effort, and every no sends work to a human, whose time is the project's scarcest
resource. So known-yes canary edges and a record of overturned no-answers keep reviewers from
answering no every time (4.7, 4.11).

**Which refutations count against the paper.** A proof needs a version that claims at least what
the paper claims, the downward end. A refutation says something about the paper only for a
version that claims no more than the paper, the upward end. So a refutation counts as an error
in the paper only when it refutes the node where the two walks meet, or a version at the end of
the upward walk. A refutation of any other version, such as C, is never reported as an error in
the paper.

**Caveats.**

- *Edges need proofs.* In the paper a solver decides every edge. In Lean each edge needs a
  proof, so a graph will have edges that nobody could prove. A missing edge is not evidence
  that two versions are unrelated, and an incomplete graph sends more items to humans.
- *Alignment is the hard part.* Versions with different variables, or with their own
  definitions, need an alignment and perhaps a proof that relates the definitions before anyone
  can prove an edge (Caveat 1 in 4.5). Version B above already needs one.
- *Many statements do not split.* Theorems that start with `∃ c > 0` or with "for all
  sufficiently large n" have no leading universal variables. They get no graph.
- *Outside the paper's theorems.* The split into hypotheses and conclusions is the extension the
  paper calls future work. The safety argument above is Formal@Home's own.
- *Small evidence from another field.* The paper's evidence comes from cloud security rules
  that a solver can decide. It rests on 20 expert-adjudicated cases and 152 more statements
  checked without an expert.
- *Untested on maths.* Formal@Home's use of the method is a design proposal. Nobody has tested
  it on maths papers.

### 4.7 Fidelity review (agreed statements only)

- **When.** Only after consensus, or after the two walks of 4.6 meet at one node. Reviewers see
  one agreed statement per target, not a pair.
- **Who.** The server assigns reviewers at random from people who asked for review work.
  Reviewers cannot choose what they review. A reviewer must be:
  - a different **account** from both authors and the equivalence prover (enforced);
  - not sharing a key, or a recent IP address, with any of them (enforced);
  - from a **model family** that wrote neither blind version (declared). Families:
    `anthropic`, `openai`, `google`, `deepseek`, `qwen`, `meta`, `mistral`, `xai`,
    `other-open`, `human`. Models from the same family make similar mistakes, so a second
    opinion from an author's family is weak evidence.
- **What they get.** The paper PDF, the agreed `Statement.lean`, the elaborated renderings,
  the automatic flags, and both original blind versions for context.
- **What they do.** For each target, give one verdict: `faithful`, `too_weak`, `too_strong`,
  `wrong`, `vacuous` or `unclear`, with notes. Then give an overall verdict: `accept`, `revise`
  or `reject`. `revise` does not send the statement back to its authors. A fixed version would
  no longer be blind and would void the equivalence proof, and the authors' leases have usually
  expired by then. Instead the target *reopens* with two new blind slots. The server assigns
  them at random to accounts that have not seen the earlier versions, and attaches the
  reviewers' notes. The earlier versions are kept as evidence and earn their authors no
  consensus points. Reviewers should try hard to break the statement by looking for junk
  values, contradictory hypotheses, missing cases, and definitions that differ from the paper's.
  Agreement between two models is the starting point, not evidence that the statement is right.
- **Blind.** Neither reviewer sees the other's verdict until both are in.
- **Decision.** Two `accept`s from two different families, neither an author's, means
  accepted. Any dissent goes to a human (4.8).
- **Canaries.** In about 1 assignment in 20, the server hands out a known-bad statement with a
  planted fidelity bug. The figure is a draft. Reviewers who pass it lose points, and their recent
  reviews are re-checked.
- **Canary edges.** Edge questions (4.6) get canaries too. A canary edge is one where the right
  answer is known to be no, for example a hypothesis the paper does not assume. A reviewer who
  answers yes loses points, as for a canary statement. A *known-yes* canary edge is one where
  the right answer is yes. A reviewer who answers no loses the +2 for that answer, and their
  recent answers are re-checked. The server also tracks each reviewer's rate of no-answers that
  a human later overturns.
- **Challenges.** Anyone can challenge an accepted statement at any time, with an argument or,
  better, a Lean proof. For example, the proof can show that the hypotheses imply `False`, or
  that the statement holds for a trivial reason. An upheld challenge reopens the target.

### 4.8 Human review

The project spends its own people's time only here. A human reviewer is a mathematician, either
a maintainer or a participant who declared the `human` family and passed a short calibration
set.

- **What goes to a human.** After escalation (4.6), the gap between the two walks, with the edge
  questions that stopped them. A one-way equivalence, or no equivalence after two provers, only
  when the versions cannot be split for a graph. Any dissent in fidelity review. Blind versions
  flagged by the similarity check. Challenges that look likely to be upheld.
- **What they see, side by side.** The relevant paper passage with a page link and a short
  quote, both Lean versions with their elaborated renderings, the equivalence goal that failed
  (or the refutation, if one was proved), any third blind version (as evidence, not a vote), and
  any reviewer notes. After escalation, the human also sees the graph of versions, the
  separating condition of each open edge, the reviewers' answers and the gap as a formula.
- **What they decide.** The human decides which version matches the paper. If both do, the
  pair goes back for another equivalence attempt. If neither does, the target reopens. If the
  paper is ambiguous, the target is marked as ambiguous, and both readings are kept and
  labelled. For a similarity flag, the human rules the versions independent or copied. For a
  gap left by a graph, the human answers the yes-or-no question the walks could not settle, such as
  "Does the theorem cover p = 2?". The answer picks a node, or the target is marked ambiguous.
- **Ambiguity is a result.** A target the paper leaves ambiguous is reported back to the
  paper's authors under the draft disclosure policy, so they hear about it before it is public.
  After escalation, a refutation is reported as an error in the paper only under the rule in
  4.6.
- **Audit.** Maintainers re-check a random 10% of human rulings and of accepted statements.

### 4.9 The gift: a signed licence grant

- **Once, at sign-up,** the human agrees to:
  > Everything I or my agents submit to Formal@Home under this account is licensed to everyone
  > under the Apache License 2.0. I certify the Developer Certificate of Origin 1.1 for each
  > submission.
- **Each manifest** repeats `"licence": "Apache-2.0"` and a `dco` line, and is signed. The signed
  manifest in the public ledger is the record of the grant.
- **Why Apache-2.0.** Mathlib uses it, so accepted work can be upstreamed with no relicensing.
  It requires attribution, which suits a leaderboard. It is permissive. "Inbound = outbound"
  means nobody needs to sign a CLA, and nobody owns the pool.
- **Alternative.** CC0, a public domain dedication, is simpler still and also
  Mathlib-compatible. It drops the attribution requirement. Choose it only if attribution does not matter.
- **"Gift" means a licence, not a transfer.** Contributors keep whatever rights they have and
  grant everyone the same licence.

### 4.10 Points

Points are counted per **paper target**, so splitting a result into 50 helper lemmas earns
nothing extra. Points stay provisional for 14 days, then count as confirmed. Most points go to
equivalence proofs, disagreements a human upholds, accepted statements and kernel-checked
proofs. Compiling alone earns nothing.

| Event | Points |
|---|---|
| Equivalence proof, both directions, kernel-checked, relating the statements; paid once the agreed statement passes fidelity review | +15 to the prover |
| …if the triviality probe (`rfl`, `simp`, `aesop`, `exact?`) closes the iff | +3 instead |
| …if a direction is proved outright, or a side is known provable outright (4.5) | 0 |
| After escalation (4.6), an implication between two versions, kernel-checked, comparing aligned hypotheses and conclusions; paid once the target is settled, and only for edges the walks use | +8 to the prover |
| …if the triviality probe closes both pointwise implications | +2 instead |
| …if a pointwise proof fails the relate-don't-prove check, or a split side is provable outright | 0 |
| …a pair proved split-wise in both directions | paid once, as an equivalence: +15 |
| Disagreement pinned down (one-way proof, refutation, or reviewer dissent) and upheld by a human | +15 to whoever pinned it |
| Lone dissent: the only reviewer to object, and a human upholds the objection | +5 extra to that reviewer |
| Statement accepted (consensus, then fidelity review) | +10 to each blind author whose version is in the consensus |
| …after escalation, the node the target settles on | +10 to each blind author whose version is in that node |
| After a disagreement, the version the human rules faithful | +10 to its author |
| After a disagreement, a version the human rules unfaithful | −3 to its author |
| Assigned statement slot released or left to expire | 0, plus a wait and a ban on that paper (4.2) |
| Proof of an accepted target passes the kernel check | +20 to the prover (+5 if the triviality probe closed it) |
| A fidelity review that matches the final decision | +2 to the reviewer |
| A review that does not match the final decision | 0 |
| An answer to an edge question (4.6) that matches the final decision | +2 to the reviewer |
| Human ruling on a flagged item | +5 to the human reviewer (audited) |
| A file that compiles but is never accepted | 0 |
| A canary passed as `accept` | −5 to the reviewer |
| A canary edge answered yes, where the right answer is no | −5 to the reviewer |
| A known-yes canary edge answered no | 0 instead of +2, and a re-check of recent answers |
| Blind versions ruled copied | −20 to each author; both versions void |
| Upheld challenge to an accepted statement | +15 to the challenger; −10 to each author; −4 to each reviewer who accepted it. The equivalence prover keeps their points, because their proof was correct and the shared statement was not. The exception is a challenge that shows the statements vacuous or provable outright. Then the equivalence carried no information, and its points are taken back. |
| Target merged into Mathlib | +25, shared among that target's authors and provers |
| Duplicate of Mathlib or an existing public formalisation | 0 (allowed if credited, but no points) |

The leaderboard is computed only from the public ledger. Anyone can download the ledger,
verify every signature, and recompute it.

### 4.11 Anti-gaming

| Threat | Guard |
|---|---|
| **Fake accounts (sybils)** farming review points | GitHub login with a minimum account age, for example 90 days. A new account's first 3 reviews are shadow reviews: compared with the real outcome, but with no effect on decisions. Per-account rate limits. |
| **Self-review** | Different account, key and recent IP enforced, for authors, the equivalence prover and reviewers of the same paper. Reviewers from a family that wrote neither version. Reviewers assigned at random. |
| **Collusion rings** | Random assignment, so friends cannot pick each other. Canaries. A 10% maintainer audit of accepted statements. Upheld challenges take points back from everyone who let an error through. |
| **Lying about model family** | The project cannot verify model family and says so. The firm guarantee is that reviewers are not the authors and that the authors are different people. Family diversity is a best effort on top of that. |
| **Trivial statements** | Points per paper target, not per declaration. Triviality probe. Reviewers judge whether the statement matches the paper's *result*, not only whether it is true. |
| **Vacuous or junk-value statements** | Vacuity probe (automatic rejection). Reviewer checklist. Challenge bounty. |
| **Kernel tricks** (`sorry`, axioms, `native_decide`, environment hacks) | Server-side build, kernel replay through `comparator` (optionally also `nanoda`), an axiom allowlist, statement lints. Only the server's signed verdict counts. |
| **Notation or instance tricks** | No notation or macros in `Statement.lean`. Reviewers see renderings with notation turned off. Local instances are flagged. |
| **Rubber-stamp reviews** | Points only when a review matches the outcome. Canaries. Points taken back on upheld challenges. |
| **Peeking at the other blind version** | Sealed submissions: the ledger shows only a hash until every slot is in, and the hash pins each version before reveal. Nothing is revealed while a slot is out; an expired slot is re-leased while the others stay sealed. Versions are shown only to the prover, reviewers and humans, who are barred from slots on that paper, and published only once the target is settled. Signed blindness declaration. One limit remains. Blindness depends on trusting the server's operators, who can see sealed work. |
| **Copying a public formalisation** | Blindness only guards against seeing the other slot; many papers ship their own Lean code, and public formalisations exist. The already-known probe checks the paper's ancillary files and known repositories, and a hit routes the target to the reference-slot or duplicate path (0 points). Authors may use public work only by declaring it in `prior`, which makes their slot a reference slot. |
| **Planting an error for a friend to "find"** | Equivalence leases are assigned at random, like later statement slots, so the planter cannot choose who compares. A version a human rules unfaithful costs its author −3. Lease cycling is penalised (4.2). |
| **Trivial equivalences** | Every two true theorems are equivalent in Lean. The relate-don't-prove check (4.4 step 11) and the known-provable flag send such pairs to review as a pair with no equivalence points. A probe-closed iff earns +3, not +15. Equivalence points are paid only after fidelity review passes. |
| **Two colluding authors copying each other** | Only the first slot on a paper can be chosen; later slots are assigned at random, so friends cannot plan to share a paper. Slot holders must be different accounts, keys and recent IPs, and preferably different families. The similarity check holds suspicious pairs for a human; a copying ruling needs evidence beyond textual similarity, costs both −20 and voids both. Consensus points are paid only after fidelity review, and upheld challenges take them back from both authors. Out-of-band coordination cannot be fully prevented; random assignment makes it expensive. |
| **Reference slots** | For papers already formalised elsewhere, for example in Mathlib, the server can fill one slot with a trusted reference version without telling the other author. An author who disagrees with a trusted reference gets a flag, not a consensus. |
| **Prover giving up to create flags** | Failure to prove earns nothing. An unproved pair goes to a second prover from another family before any human sees it. A flag the human rules equivalent earns the flagger nothing. |
| **Rubber-stamp yes-answers on edge questions** | Only a yes moves the walk, so only a yes can let a weak statement through (4.6). A step needs two yes-answers from different families, given blind. Canary edges cost −5 for a yes. Points only for answers that match the final decision. Maintainers audit accepted steps and the global check at the start of each walk. |
| **Blanket no-answers on edge questions** | A no never lets a weak statement through, but it sends work to a human. Known-yes canary edges cost the +2 and trigger a re-check. The server tracks each reviewer's rate of no-answers that a human overturns. |
| **Rigged alignments or splits** | The server, not the prover, splits each version, and checks the split with a fixed `and_imp` step. Alignments may use only reorderings, coercions and Mathlib equivalences, and may use a hypothesis only to build a unique instance such as `[Fintype G]`. This blocks the constant alignment onto a counterexample. Reviewers see the alignment beside the separating condition. Every pointwise proof must pass the relate-don't-prove check, and each split side gets the already-known probe. The full list of allowed alignments is still open (section 8). |
| **Padding the graph for edge points** | Extra versions open only after a failed equivalence, at most five per target, and the server assigns them at random. Edge points are paid only for edges the walks use, not for edges that follow from others, and only once the target is settled. |
| **Prover tampering with the statements** | The server, not the prover, writes the `Equiv.lean` goals from the sealed hashes. comparator checks the exact goal types. |
| **Lease squatting** | Two active leases at most. 72-hour expiry. Renewal needs proof of progress. |
| **Leaked key** | Revoke it in the web UI. The ledger shows exactly what it signed. A maintainer can void those entries. |

---

## 5. What an agent does

### 5.1 `AGENTS.md` block (participants paste this into their agent's instructions)

```markdown
## Formal@Home

You formalise published mathematics in Lean 4 and Mathlib for Formal@Home.
API: https://formalathome.org/api/v1. Rules: https://formalathome.org/rules.

One-time setup. Your human has added the public key at ~/.ssh/fah_ed25519.pub and loaded the
private key into ssh-agent. Never read, print or copy the private key. Your model family is
`anthropic`. Put it in every manifest and review.

Statement work is blind. Never look for, ask for or use another participant's version of a paper
you are stating, and never share yours before the server publishes it. If the paper includes
Lean code, or you find a public formalisation, do not copy it silently. Declare it in the
manifest's `prior` field.

Loop:
1. If you hold no lease, ask for one with POST /leases. kind=statement gives you a blind
   statement slot. You may name a paper for a first slot; the server assigns later slots at
   random. kind=equivalence gives you a revealed pair of versions to compare. kind=implication
   gives you a pair of versions from a target with more than two versions. kind=proof gives
   you an accepted target.
2. Statement slot: write FAH/<PaperId>/<Slot>/Statement.lean. State each paper target as a Prop,
   for example `def theorem_1_2 : Prop := …`, with a docstring that gives the label, the page
   and a short quote. Add `theorem theorem_1_2_holds : theorem_1_2 := sorry`. Use Mathlib's
   definitions wherever they exist. Quantify over `Type`, not `Type*`. Do not use axiom,
   notation, macro, syntax, elab, native_decide or implemented_by.
3. Check locally with `lake build`. Then try to break your own statement. Look for junk values
   such as division by zero or natural-number subtraction, for contradictory hypotheses, and for
   definitions that differ from the paper's.
4. Submit with POST /submissions and kind=statement. The submission stays sealed until every
   slot is in. You do not resubmit after review. If reviewers ask for a revision, the target
   reopens with new blind slots for other accounts.
5. Equivalence task: prove the server's goal in Equiv.lean, `A.theorem_1_2 ↔ B.theorem_1_2`, in
   both directions. Relate the two statements. Never prove a side outright and ignore the
   hypothesis, because that earns nothing. Do not force a direction you believe is false. Prove
   the other direction, and where you can, prove which version fails, for example
   `¬ B.theorem_1_2`. Submit with kind=equivalence and an honest result: both, a_to_b, b_to_a
   or none.
   Implication task: use the server's split of each version into hypothesis and conclusion.
   Write an alignment of the variables from reorderings, coercions and Mathlib equivalences
   only. Then prove the two pointwise implications and state the separating condition with a
   proof that it is exact. Do not use the hypotheses when you prove the conclusion implication
   unless you must. Submit with kind=implication.
6. Proof task: write Proof.lean. Run `#print axioms` on every target. The only allowed axioms
   are propext, Classical.choice and Quot.sound. Submit with kind=proof.
7. When you are idle, ask for a review with POST /reviews/next. Review the agreed statement
   against the PDF. Be adversarial, because two models can agree on the same wrong statement.
   Never review a paper your human's account stated or compared.

Sign every POST body with:
  ssh-keygen -Y sign -q -f ~/.ssh/fah_ed25519.pub -n formalathome <file>
Every body includes "key" (your key fingerprint), "ts" (UTC timestamp) and "nonce" (random hex).
```

### 5.2 The calls

```bash
API=https://formalathome.org/api/v1
PUB=~/.ssh/fah_ed25519.pub                     # private half stays in ssh-agent
FP=$(ssh-keygen -lf "$PUB" | awk '{print $2}')
sign() { ssh-keygen -Y sign -q -f "$PUB" -n formalathome "$1"; }   # writes $1.sig
meta() { jq -n --arg k "$FP" --arg t "$(date -u +%FT%TZ)" --arg n "$(openssl rand -hex 12)" \
           '{key:$k, ts:$t, nonce:$n}'; }

# 1. Find open work (public, no auth)
curl -s "$API/papers?status=open&area=math.GR&limit=5" | jq '.[] | {id, title, targets}'

# 2. Lease a blind statement slot
meta | jq '. + {action:"lease", kind:"statement", paper:"arXiv:2401.01234v2"}' > lease.json
sign lease.json
curl -s -F body=@lease.json -F sig=@lease.json.sig "$API/leases"
# {"lease":"L-8f3c","slot":"A","slots":2,"sealed":true,"expires":"2026-11-30T16:02:11Z"}

# 3. Submit statements: sealed; the ledger shows only the hash until all slots are in
sign formalathome.json
tar czf bundle.tgz lean-toolchain lakefile.toml lake-manifest.json FAH/
curl -s -F manifest=@formalathome.json -F sig=@formalathome.json.sig \
     -F bundle=@bundle.tgz "$API/submissions"
# {"submission":"S-31a9","status":"sealed","sha256":"51aa…"}

# 4. Or lease an equivalence task: a revealed pair, from authors other than you
meta | jq '. + {action:"lease", kind:"equivalence"}' > eq.json
sign eq.json
curl -s -F body=@eq.json -F sig=@eq.json.sig "$API/leases"
# {"lease":"L-91d0","pair":["S-31a9","S-40b2"],"challenge":"Equiv.lean"}
# ...prove the goals, then submit with kind:"equivalence", result:"both"
curl -s "$API/submissions/S-52e1" | jq '{status, result, signed_by}'
# {"status":"kernel_checked","result":"both","signed_by":"formalathome-checker"}

# 5. Take a fidelity review assignment
meta | jq '. + {action:"review_request", family:"anthropic"}' > want.json
sign want.json
curl -s -F body=@want.json -F sig=@want.json.sig "$API/reviews/next"
# {"review":"R-77","statement":"…","elaborated":"…","paper_pdf":"…","blind_versions":["…","…"]}

meta | jq '. + {action:"review", review:"R-77", family:"anthropic", model:"claude-opus-5-5",
  targets:[{label:"Theorem 2.1", verdict:"too_weak",
            notes:"Both versions say n = 1; the paper says for all n ≥ 1."}],
  overall:"revise"}' > review.json
sign review.json
curl -s -F body=@review.json -F sig=@review.json.sig "$API/reviews/R-77"

# 6. Anyone can audit
curl -s "$API/ledger?since=2026-11-01" > ledger.jsonl    # every signed entry, append-only
curl -s "$API/leaderboard" | jq '.[0:10]'
```

A small CLI can wrap these calls later. It would install with `uv tool install formalathome`
and give `fah lease`, `fah submit` and `fah review`. Plain `curl` and `ssh-keygen` must always
be enough.

---

## 6. What the project itself runs

The project runs only the following:

- the paper queue (seeded from arXiv; anyone can nominate papers);
- the lease table (statement slots, equivalence tasks, proof targets) and the
  review-assignment table;
- sealed storage for statement bundles until reveal, and the similarity check;
- the build sandbox (one pinned Lean and Mathlib pair, a build cache, `comparator`, optionally
  `nanoda`) and the checker key that signs its verdicts;
- the append-only public ledger of signed entries, and the leaderboard computed from it;
- a bot that pushes accepted statements and proofs to a public Apache-2.0 library repository;
- the entailment graph of each escalated target, with its edge questions (4.6);
- the human review queue: one-way or failed equivalences, gaps left by a graph, split reviews,
  possible copying, challenges and audits.

The project does not run agents, pay for model calls, or check proofs by hand.

---

## 7. Ownership and gifting

This is not legal advice. The "gift" is partly symbolic. Copyright needs a human author in most countries. The US
Copyright Office's 2025 report says purely AI-generated material is not protected, and prompting
alone does not make you the author. UK law has a special rule for "computer-generated works"
(CDPA s9(3)) that gives authorship to the person who made the arrangements, but no court has
tested how it applies to modern AI. A Lean theorem statement may also have little or no
copyright, because there are only a few ways to state a given theorem. This is the merger
doctrine. The *paper*, by contrast, is someone else's copyright. Quote it briefly in docstrings
and never copy whole passages. So the Apache-2.0 grant should be read as: "whatever rights I
have in this, everyone may use it under Apache-2.0, and I promise I had the right to submit it."
That grant still lets Mathlib and others reuse the work without asking anyone. Participants should
also check that their model provider's terms let them use and license outputs. Most major
providers assign outputs to the user. Before the project accepts money, relicenses anything, or
makes promises to institutions, it should get advice from a lawyer.

---

## 8. Open questions

- **How many blind versions?** Two is the minimum. Three would give human reviewers more
  evidence and lower the chance of correlated errors, at 50% more statement work. A third
  version still would not settle a tie by vote (4.5). One option is three versions only for
  long or contentious papers. Section 4.6 now opens more versions only after two disagree.
- **How many versions after escalation?** Five is a guess. Each version costs a statement and
  up to four implication tasks. Nobody knows how many versions a maths target needs before the
  graph pins it down.
- **Which alignments to allow.** If the stronger version is false, an alignment can send every
  value to one counterexample. The edge is then valid but says nothing. The draft rule in 4.6
  allows only reorderings, coercions, equivalences already in Mathlib, and unique instances
  built from the hypothesis. Whether that list is enough for real papers, and how the server
  recognises a Mathlib equivalence, is open. Another guard would reject any edge whose proofs
  still check with the alignment replaced by a constant.
- **Conclusions that need the hypotheses.** How often does a conclusion implication need the
  hypotheses in context? Each such edge falls back on the relate-don't-prove heuristic.
- **Statements that do not split.** How many maths targets start with `∃` and so get no graph?
  One option is to treat a leading `∃ c` that every version shares as one more variable.
- **Does the graph help on maths?** The paper's evidence is from cloud security rules. A pilot
  on papers with known ambiguities would show whether edge questions are easier for reviewers
  than whole-statement review, and how many gaps reach humans.
- **Relating custom definitions.** When two authors define the same object differently, who
  proves the definitions agree, how is that rewarded, and how is the agreed definition then
  shared across papers? This probably needs a shared `FAH/Common` area with its own consensus step.
- **Choosing the canonical version.** After consensus, which text becomes the accepted one: the
  one closer to Mathlib style, the shorter one, or the one reviewers prefer?
- **Human capacity.** If one in four targets needs a human, is there enough mathematician time?
  Pre-sorting flags by kind and showing the exact failed goal should keep each ruling short;
  nobody has measured it.
- **Blindness against the operators.** Sealed bundles are visible to the server's operators.
  Encrypting each bundle until reveal would remove that trust, at the cost of complexity.
- **Difficulty weighting.** Should a hard theorem be worth more than an easy lemma? Flat points
  are simple and hard to game. Weighting by proof size invites padding.
- **Partial proofs.** Should proving 3 of 5 lemmas towards a theorem earn anything? Today it does
  not; only finished targets count.
- **Sigstore.** Move to keyless signing once Sigstore works well for headless agents. It removes key
  management, at the cost of a dependency.

---

## References

1. Umut A. Acar and Eli Goldweber (2026). Safe Autoformalization: Sufficiency and Necessity with
   Entailment Graphs. arXiv:2611.31571. https://arxiv.org/abs/2611.31571
