DeepSeek-Prover-V2
Open-source model for formal theorem proving in Lean 4
DeepSeek-Prover-V2 is an open-source language model built for formal mathematical reasoning in Lean 4. Released by DeepSeek in 2025, it uses reinforcement learning on synthetic data to bridge informal logic and formal proof. The 671 billion parameter version sets new benchmarks in neural theorem proving.
- Achieves 88.9% pass rate on MiniF2F-test benchmark
- Solves 49 of 658 problems in PutnamBench dataset
- Released in two sizes: 7B and 671B parameters
- Uses reinforcement learning with synthetic cold-start data
- Introduces ProverBench with 15 AIME competition problems
What it is
DeepSeek-Prover-V2 is a specialised large language model designed to generate formal proofs in the Lean 4 programming language. Developed by DeepSeek, it comes in two sizes: 7 billion and 671 billion parameters. The larger model shares its architecture with DeepSeek-V3. Its primary purpose is to advance automated theorem proving by combining informal mathematical reasoning with strict formal verification. The model was released in April 2025 as an open-source project, allowing researchers to download weights and integrate the system into their own workflows for mathematical problem solving.
How it came about
The development of this model relied on a recursive theorem proving pipeline powered by the earlier DeepSeek-V3 system. Researchers used DeepSeek-V3 to break down complex mathematical problems into smaller subgoals. A smaller 7 billion parameter model then attempted to solve these individual steps. Successful solutions were combined with chain-of-thought reasoning to create a synthetic dataset. This data served as the foundation for training the final prover models through reinforcement learning. The process aimed to merge high-level informal logic with the precise requirements of formal code generation.
Inside the model
The system uses a mixture of experts architecture, particularly in its largest variant. Training began with a cold-start phase where synthetic data was generated by decomposing theorems into subgoals. The model learned to link informal step-by-step reasoning with formal Lean 4 code. Reinforcement learning followed, using binary feedback on whether a proof was correct or incorrect. This reward signal helped the model improve its ability to construct valid proofs. The 7 billion parameter version features an extended context window of up to 32,000 tokens, supporting longer proof sequences.
What it can do
The 671 billion parameter model achieved an 88.9 per cent pass rate on the MiniF2F-test benchmark. It also solved 49 out of 658 problems from the PutnamBench dataset. To test performance on competition-level maths, the team introduced ProverBench, which includes 15 problems from recent AIME competitions. The model successfully solved 6 of these 15 challenges. For comparison, the general-purpose DeepSeek-V3 solved 8 of the same problems using majority voting, suggesting the gap between formal and informal reasoning is narrowing.
How to use it
Both the 7 billion and 671 billion parameter versions are available for download via Hugging Face. The weights are released under the DeepSeek Model License, making them open for research and commercial use under specific terms. Developers can run inference using standard libraries such as Hugging Face Transformers. The code supports automatic device mapping and bfloat16 precision. Documentation for the larger model refers users to the DeepSeek-V3 technical guides for implementation details.
Why it matters
The release contributes to the growing field of neural theorem proving by providing high-performance open weights. By demonstrating strong results on competitive mathematics benchmarks, it shows that large language models can handle rigorous formal verification tasks. The introduction of ProverBench offers a new standard for evaluating models on authentic high-school and undergraduate-level problems. This work helps bridge the divide between natural language mathematical intuition and machine-checkable formal proofs.
Questions people ask about DeepSeek-Prover-V2
What programming language does DeepSeek-Prover-V2 use for proofs?
The model is specifically designed to generate formal proofs in Lean 4. It translates mathematical problems into code that can be verified by the Lean theorem prover, ensuring logical correctness through strict formal rules rather than just natural language explanation.
How was the training data for this model created?
Researchers used DeepSeek-V3 to decompose complex theorems into subgoals. A smaller model solved these subgoals, and the results were combined with chain-of-thought reasoning to create synthetic training data. This data then guided the reinforcement learning phase for the final prover models.
What is the difference between the 7B and 671B versions?
The 671 billion parameter model is based on the DeepSeek-V3 architecture and offers higher performance on complex benchmarks. The 7 billion parameter model is built on DeepSeek-Prover-V1.5-Base and features an extended context length of 32,000 tokens, making it suitable for longer proof sequences with lower computational cost.
How does it perform on high-school math competitions?
On the ProverBench dataset, which includes 15 problems from recent AIME competitions, the model solved 6 of them. This performance is close to the general-purpose DeepSeek-V3, which solved 8 of the same problems using majority voting, indicating strong formal reasoning capabilities.
Good reading and sources
There is no English Wikipedia article on DeepSeek-Prover-V2 yet, so the facts on this page come from the sources listed above: huggingface.co/deepseek-ai/DeepSeek-Prover-V2-671B, arxiv.org/abs/2504.21801. Some are the subject's own pages, so its claims about itself are reported as its claims. EveryLLM wrote the text in its own words, with AI assistance, and compares it with the sources to make sure no passage is copied.
It may contain mistakes, and figures change over time. Nothing here is investment or buying advice. If something is wrong, tell us. Last refreshed 2026-11-14.