Proving that a multivariate polynomial is globally non-negative (e.g., $f(x_1, \dots, x_n) \geq 0$) is a fundamental challenge in automated mathematical reasoning, optimization, and control theory. Traditional symbolic methods, such as Semidefinite Programming (SDP), offer strong theoretical guarantees but suffer from combinatorial explosion. As the number of variables or the polynomial degree increases, these methods scale poorly and often yield numerical approximations rather than the exact, machine-checked proofs required by modern formal verification systems like Lean.
Conversely, Large Language Models (LLMs) excel at intuitive mathematical leaps but struggle with exact arithmetic and are prone to hallucinating coefficients. To bridge this gap, researchers have introduced NSPI (Neuro-Symbolic SOS-based Polynomial Inequality Proving), an end-to-end framework that combines the heuristic strengths of LLMs with the rigorous precision of symbolic computation and formal verification.
The NSPI Framework
NSPI operates through a novel three-stage pipeline designed to transition from heuristic discovery to a machine-checked proof:
- Neural Conjecture: A fine-tuned LLM (based on Qwen3-8B) acts as a "structure conjecturer." Given a target polynomial, it proposes an approximate Sum-of-Squares (SOS) decomposition. Because any sum of squared real terms is inherently non-negative, finding a valid SOS decomposition is a direct path to proving the inequality.
- Symbolic Correction: Because LLM-generated coefficients are often numerically imprecise, NSPI employs Gauss-Newton refinement to sharpen the floating-point values. It then applies Rational Recovery to convert these approximations into exact fractions, yielding a precise mathematical identity.
- Formal Verification: The exact SOS certificate is embedded into a predefined Lean 4 template. Lean's kernel verifies the algebraic equality, and its
positivitytactic confirms the logical soundness of the proof.
Unlike previous hybrid systems that use LLMs merely to select high-level strategies, NSPI leverages the LLM to generate the actual structural content of the proof, using symbolic math as a "precision bridge."
Datasets and Training
To evaluate the system, the authors introduced PolyIneqBench, a comprehensive benchmark comprising 522 problems:
- PolyIneq-Real (102 problems): Sourced from international math competitions (e.g., IMO, Putnam) and classic literature (e.g., Schur's Inequality, Robinson polynomial).
- PolyIneq-Synth (420 problems): Systematically generated high-dimensional problems (ranging from 4 to 10 variables) designed to test scalability.
The underlying model was pre-trained on over 1 million synthetic polynomial-SOS pairs generated via algebraic construction and optimization techniques. Furthermore, using Progressive Reinforcement Learning (GRPO), the model trained on simpler 3-to-5 variable problems was able to generalize to much harder 10-variable instances.
Key Results and Insights
NSPI demonstrates remarkable scalability and efficiency, breaking through the dimensionality wall that typically stops automated provers at 4 or 5 variables.
- Superior Scalability: On complex 10-variable problems, NSPI achieved an 11.7% pass rate. In stark contrast, almost all baseline methods—including Maple, Z3, and DeepSeek-Prover-V2—dropped to a 0% success rate.
- State-of-the-Art Performance: On the rigorous
PolyIneq-Synthbenchmark, NSPI achieved a 25.95% overall pass rate, nearly tripling the performance of the next best hybrid system (LIPS). - Efficiency: By treating the LLM as a "conjecture engine," NSPI dramatically narrows the search space for symbolic solvers. This results in up to a 10x speedup in execution time compared to other state-of-the-art LLM-based provers.
Limitations and Future Directions
While highly effective, NSPI is bounded by the mathematical limits of SOS decompositions; it only works for polynomials that can be represented as a sum of squares. Although non-SOS non-negative polynomials exist, they are relatively rare in practical competition math. Additionally, extremely high-degree polynomials can cause "coefficient swelling," making it difficult for the LLM to predict the structure accurately.
Future work aims to expand the framework to handle rational function SOS—covering a broader class of inequalities—and to apply this conjecture-correction-verification pipeline to other domains, such as Lyapunov-based stability analysis for dynamical systems.
Summary updated