Exponential Diophantine equations ask for whole-number solutions when the unknowns sit in exponents, as in $x^2 + b^y = c^z$. A family of results by Cao, Dong and coauthors proves that such equations have exactly one solution under side conditions, for example when $b$ is a prime power and $c \equiv 5 \pmod 8$. These proofs share a two-layer structure. At the bottom are a few deep, separately published theorems: a result guaranteeing that terms of Lucas sequences have new prime factors, and lower bounds for linear forms in logarithms. On top sits a layer of elementary but intricate reasoning, including congruence arguments, parity forcing, and factoring in the Gaussian integers. Today's neural theorem provers score near-perfectly on competition mathematics but collapse on research-level number theory. Nobody knows which layer is responsible. The provers might lack the deep theorems, which are absent from proof libraries, or they might be unable to carry out the elementary glue reasoning even when the deep facts are supplied.
We propose to separate these two failure sources. We will formalize the Cao–Dong uniqueness theorems in Lean, with each deep theorem stated as an explicit, named hypothesis rather than proved, and measure what current provers can do once the deep layer is handed to them. This is the "assume a conjecture, prove the consequence" style of mathematics turned into an experimental control. The probabilistic method plays a supporting role in a heuristic sense: a random model of when $c^z - b^y$ happens to be a perfect square tells us where uniqueness should fail. We use it to generate near-miss false statements, which catch provers that exploit badly formalized premises. If the provers succeed with the hypotheses and fail without them, research-level automated number theory is mainly a library problem. If they fail either way, the glue reasoning is the real wall, and benchmark scores on competition math say little about it.
Core Claim
The claim is that the difficulty of research-level exponential Diophantine proofs for neural provers can be measured and attributed to one of two layers, using a single benchmark built from published proofs. In the first arm, each statement comes with its deep inputs as Lean hypotheses. In the second arm, those same inputs are removed. The gap between the two arms quantifies the cost of missing library knowledge. The success rate in the hypothesis arm quantifies the glue-reasoning ability itself. No benchmark in the literature we have makes this separation.
The motivating evidence comes from the theorem-proving literature. PutnamBench, a set of 640 undergraduate competition problems, found zero-shot GPT-4 solving 1 of 640 Lean problems and blamed an inability to navigate deep libraries. Goedel-Prover-V2 reaches 90.4% pass@32 on miniF2F but notes it "struggles with knowledge retrieval" on ProofNet. STP, a self-play system in which the model invents its own conjectures as training problems, drifts away from complex number theory toward simpler inequalities. All three diagnose a knowledge or library problem, but none tests the diagnosis by supplying the knowledge. The Diophantine papers supply the content. On Terai's conjecture uses congruences modulo 4 and 8 to force both exponents to be even, which reduces the equation to $(c^j - b^k)(c^j + b^k) = x^2$. The Diophantine equation $x^2 + b^y = c^z$ factors in the Gaussian integers. A new conjecture concerning the Diophantine equation $x^2 + b^y = c^z$ calls on the Bilu–Hanrot–Voutier primitive divisor theorem. On the Terai--Jeśmanowicz conjecture combines a Laurent–Mignotte–Nesterenko lower bound with Lucas sequences to reach the threshold $b \ge 25.1a$. In each of these, the deep input enters as a black-box lemma, which makes these proofs well suited to the hypothesis interface.
Research Program
The first deliverable is a Lean 4 benchmark, which we call DeepPremise-Terai. It is built by decomposing the main theorems and corollaries of the four Cao–Dong papers into a dependency tree of lemmas, organized in three depths. Depth zero contains pure congruence and parity lemmas, such as "if $c \equiv 5 \pmod 8$ then $n$ is even." Depth one adds Gaussian-integer and difference-of-squares factorization steps. Depth two contains the full uniqueness theorems, for instance that $x^2 + (3m^2-1)^y = (m^2+1)^z$ has only the solution $(m^3-3m, 2, 3)$ when $3m^2-1$ is a prime power. In the hypothesis arm, each depth-two statement carries the precise deep theorem it needs as a named hypothesis in its context. Where possible, these hypotheses are stated at exactly the strength the original paper uses, rather than in full generality, so that the interface matches what a mathematician actually cites. We will start with hand formalization by a number theorist and a Lean expert working together.
This hand formalization is not optional. miniF2F-Lean Revisited found that an automated judge rated a translator at 97.5% accurate where human experts gave 62.7%, and it corrected 16 unprovable statements in the original miniF2F. That result constrains our design: automated formalization is out.
The second component guards against the main risk of hypothesis-style statements. A mis-stated hypothesis can be false, or even contradict the other hypotheses. Lean will then accept a "proof" that is vacuous, which is exactly the fragility of conditional mathematics that the research file flags. We address this in two ways.
The first is a consistency probe. For every premise set, we run the strongest prover with the goal False under a large budget, and we numerically check each hypothesis on sampled parameters.
The second is a set of near-miss negatives. These are statements that look like the benchmark theorems but are false, because they drop the exponent restriction ($y, z > 1$) or the size threshold. The source paper already exhibits counterexamples of this kind, built from the unit $7 + 4\sqrt{3}$, and the general conjecture is known to fail when $\max(a,b,c) \le 7$. A prover that "proves" a near-miss negative has exploited a premise bug, and the statement is quarantined until fixed.
To produce near-miss negatives systematically rather than by hand, we use a Cramér-style random model, meaning a heuristic that treats a large integer of size $N$ as a perfect square with probability about $N^{-1/2}$. Under this model, the expected number of extra solutions with exponents in a range $R$ is
$$ E(b,c) \approx \sum_{(y,z) \in R,\; c^z > b^y} (c^z - b^y)^{-1/2}, $$
where the sum runs over the exponent pairs in $R$ for which $c^z - b^y$ is positive. This sum converges and is dominated by small bases and small exponents. It therefore predicts that counterexamples cluster where the literature finds them, and it tells us which parameter boxes an exhaustive search must cover to find candidate false variants. We run that exhaustive search over bases up to $10^4$ and bounded exponents. We do not claim the model is correct for Lucas-sequence families. The research file explicitly notes that their prime factors have algebraic dependencies that break independence assumptions. We report where the model's predictions and the search disagree as a finding in its own right, since it measures how far a naive probabilistic heuristic misleads in exactly the setting where conjecture-dependent reasoning is used.
The third component is the evaluation protocol itself. Every prover is run on the same statements in three arms. The first arm supplies the correct deep hypotheses. The second arm omits them; the statement is then generally unprovable at depth two with current Mathlib, so success there is informative only at depths zero and one. The third arm supplies the correct hypotheses plus decoys: true but irrelevant number-theoretic facts in matching form. This tests whether the prover actually uses the premise or merely benefits from a longer context.
Baselines
The naive reference point is Lean's built-in automation with no neural model, meaning tidy-style tactic search together with omega, decide, norm_num, and nlinarith. It runs under the same wall-clock budget per statement. miniF2F reports tidy at 18.0% pass@1 on miniF2F-test. This is the right floor because the depth-zero congruence lemmas may well fall to decision procedures, and any neural gain must be measured above that floor. There is no reported result on Lacuna for any system on exponential Diophantine uniqueness theorems, so all numbers on our benchmark will be new.
The strongest open whole-proof prover is Goedel-Prover-V2. It reports 90.4% pass@32 on miniF2F in self-correction mode for its 32B model and 86 solved PutnamBench problems. It is the strongest competitor because it is open, trained heavily on number theory, and includes compiler-feedback self-correction, which is what long case analyses need. We run its 32B and 8B models at pass@32 with self-correction, using the paper's own decoding settings, identically across the three arms.
The strongest sketch-based system is SketchRefine from Editable Proof Sketch for Automated Theorem Proving. It edits a proof plan in place rather than regenerating it, and it reports 99.6% on miniF2F-test and 76.0% on FormalMath-Lite. It matters here because research proofs are long chains of subgoals, which is exactly where in-place editing should help. We give it the same token budget per statement as the other systems.
We also run STP, which reports 65.0% pass@3200 on miniF2F-test, at a matched sample count. This lets us ask whether its reported drift away from number theory shows up as a specific deficit at depth two.
The key ablation is the hypothesis-removed arm, and the decoy arm isolates whether premise content rather than context length drives any gain. Beating the baselines is not really the point, since every arm runs the same provers. The decisive quantity is the gap between arms at depth two, measured as pass@32 with bootstrap confidence intervals over statements. A gap whose confidence interval excludes zero, with decoys recovering none of it, would count as demonstrating a library bottleneck.
Why not just…?
Why not just scale sampling on the unconditional statements? STP reports that up to 98.5% of compute in standard expert iteration goes to failed proofs that give no learning signal. More fundamentally, the depth-two statements need Baker-type bounds and the primitive divisor theorem, which no amount of sampling over current Mathlib can derive. Our hypothesis-removed arm runs exactly this alternative and will show whether it gets anywhere at depth two.
Why not just formalize Bilu–Hanrot–Voutier and the logarithmic bounds in Mathlib and then test? That is the right long-term goal, but it is a multi-year formalization effort. It would also confound the question: we could not tell whether a later failure came from missing glue reasoning or from awkward library interfaces. Stating the deep results as hypotheses at exactly the strength the papers cite answers the attribution question now. If provers succeed in the hypothesis arm, that success tells library builders which interfaces are worth the formalization effort.
Why not just verify uniqueness by computer search? A search covers a finite box of bases and exponents. The theorems quantify over infinitely many exponents, and the linear-forms argument exists precisely to rule out huge solutions that no search reaches. We still run the search, but only to supply near-miss negatives and to test the random model, not as a substitute for proof.
Why not just hand the prover the paper's natural-language proof? This is a genuine threat. A strong sketch-based prover given the published argument might succeed without any hypothesis interface. We will run this as an explicit fourth arm on SketchRefine and Goedel-Prover-V2, giving them the paper's proof text with and without the formal hypotheses. If the text alone matches the hypothesis arm, we conclude that the binding constraint is the absence of informal guidance rather than formal premises, and we will report that outcome as the main result.
Proposed Experiments
The first experiment establishes the benchmark's integrity before any model comparison. Every statement must pass the consistency probe, with no proof of False under a budget of thousands of attempts, and a numerical check of its hypotheses. Every near-miss negative must remain unproved by all systems. A single "proof" of a negative halts the study until the faulty premise is repaired. We also report how many formalization bugs this procedure caught, because that number directly measures how fragile conditional statements are once they are formalized.
The second experiment is the three-arm comparison, broken down by depth, under the matched budgets described in the Baselines section. Its decisive check concerns the depth-two theorems from On Terai's conjecture and A new conjecture concerning the Diophantine equation $x^2 + b^y = c^z$. We expect the hypothesis arm to substantially exceed both the removed and decoy arms, while depth zero shows little difference across arms, because congruence lemmas need no deep input. If depth-two success stays near zero even with hypotheses supplied, the "undergraduate wall" diagnosed by PutnamBench is a reasoning wall, not a retrieval wall.
The third experiment tests transfer to statements whose proofs are not known in advance. We formalize, as hypothesis-arm statements, specializations from the On the Terai--Jeśmanowicz conjecture family at parameter values not used in development, such as specific $r = 3$ cases with $m > 71.68n$. We then measure whether provers that succeed on the development split carry over.
As a secondary analysis, we report where the random-square heuristic's predicted counts of exceptional solutions diverge from exhaustive-search counts in the $c \equiv 1 \pmod 8$ and $b < 25.1a$ regimes. These are the regimes the literature leaves open, and the comparison shows how much confidence probabilistic intuition should lend to the conjectures assumed in them.
References
- PutnamBench: Evaluating Neural Theorem-Provers on the Putnam Mathematical Competition
- Goedel-Prover-V2: Scaling Formal Theorem Proving with Scaffolded Data Synthesis and Self-Correction
- STP: Self-play LLM Theorem Provers with Iterative Conjecturing and Proving
- On Terai's conjecture
- The Diophantine equation $x^2 + b^y = c^z$
- A new conjecture concerning the Diophantine equation $x^2 + b^y = c^z$
- On the Terai--Jeśmanowicz conjecture
- miniF2F-Lean Revisited: Reviewing Limitations and Charting a Path Forward
- miniF2F: a cross-system benchmark for formal Olympiad-level mathematics
- Editable Proof Sketch for Automated Theorem Proving