Statistical Theory in the Age of Machine-Assisted Mathematics: Rethinking How Theory Is Made and Taught
Pietro Coretto
stat.OT
Sep 3, 2026 · v1
TL;DR
Five classical statistical theory results are formalized in Lean with Mathlib to expose hidden assumptions in textbook proofs.
Abstract
The computational revolution is advancing at an unprecedented pace. The combination of proof-assistant technologies and generative AI tools has recently enabled the solution of complex problems in pure mathematics at a scale that seemed unattainable only a few years ago. However, these technologies have not yet become standard tools in the development of statistical theory. In this paper, we do not present new theoretical results. Instead, we discuss five case studies involving classical problems in statistics and describe how they can be analyzed using a machine proof-checking. Our goal is not to propose a definitive workflow, but to stimulate reflection on how these technologies may transform theoretical research and advanced statistical education. We focus on two main aspects. First, statistical theory often compresses substantial mathematical content into expressions such as "under the usual regularity conditions". Formalization in a machine-verifiable language forces each assumption to be explicit, reveal hidden dependencies, and provide a deeper understanding of the formalized objects. Second, we argue that the statistical community could benefit from a collaborative effort to build repositories of formalized axioms, definitions, and theorems, supporting more precise and reliable theoretical developments. Finally, we discuss the role of these tools in graduate education. Just as high-level programming languages revolutionized empirical research by enabling rapid experimentation and prototyping, machine-assisted formalization may introduce a new paradigm for the development, verification, and communication of statistical theory.
Problem
Statistical theory often compresses substantial mathematical content into phrases like "under the usual regularity conditions," concealing which assumptions support which proof steps. Proof-assistant technologies are not yet standard tools in statistical theory development.
Approach
Five classical statistical results (e.g., MLE consistency, score/Fisher-information identity, MLE asymptotic normality, the delta method, LASSO bounds) are retrospectively formalized in Lean using Mathlib. For each case the textbook argument is compared with its formal counterpart, and every hidden assumption is traced to its source. An auditing protocol classifies gaps as topological, analytic, probabilistic, or algebraic. AI assistants (Gemini, Claude, Leanstral) were used to help produce the Lean code.
Results
All five Lean files compile with no axiom, sorry, or admit declarations, resting only on Lean's standard axioms. The formalizations reveal recurring latent-assumption mechanisms (notably domination/envelope and deterministic/probabilistic coupling) across unrelated arguments, and the authors argue for community-built repositories of formalized statistical definitions and theorems.
| Mechanism | What is at stake | Cases |
|---|
| Topological | compactness, convexity, interiority, convex domain | 3.1, 3.3, 3.4 |
| Analytic | envelopes, domination, support, differentiability, norm | 3.1, 3.2, 3.3, 3.4 |
| Probabilistic | quantifiers over randomness, couplings, joint events | 3.3, 3.4, 3.5 |
| Algebraic | constant tracking, normalization conventions | 3.5 |
Taxonomy of the gaps found in the five formalizations