All videos
0:00 / 0:00
research

[GRPO Explained] DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Models

Yannic Kilcher15 June 2026Watch on YouTube

Description

#deepseek #llm #grpo GRPO is one of the core advancements used in Deepseek-R1, but was introduced already last year in this paper that uses a combination of new RL techniques and iterative data collection to achieve remarkable performance on mathematics benchmarks with just a 7B model. Paper: https://arxiv.org/abs/2402.03300 Abstract: Mathematical reasoning poses a significant challenge for language models due to its complex and structured nature. In this paper, we introduce DeepSeekMath 7B, which continues pre-training DeepSeek-Coder-Base-v1.5 7B with 120B math-related tokens sourced from Common Crawl, together with natural language and code data. DeepSeekMath 7B has achieved an impressive score of 51.7% on the competition-level MATH benchmark without relying on external toolkits and voting techniques, approaching the performance level of Gemini-Ultra and GPT-4. Self-consistency over 64 samples from DeepSeekMath 7B achieves 60.9% on MATH. The mathematical reasoning capability of DeepSeekMath is attributed to two key factors: First, we harness the significant potential of publicly available web data through a meticulously engineered data selection pipeline. Second, we introduce Group Relative Policy Optimization (GRPO), a variant of Proximal Policy Optimization (PPO), that enhances mathematical reasoning abilities while concurrently optimizing the memory usage of PPO. Authors: Zhihong Shao, Peiyi Wang, Qihao Zhu, Runxin Xu, Junxiao Song, Xiao Bi, Haowei Zhang, Mingchuan Zhang, Y.K. Li, Y. Wu, Daya Guo Links: Homepage: https://ykilcher.com Merch: https://ykilcher.com/merch YouTube: https://www.youtube.com/c/yannickilcher Twitter: https://twitter.com/ykilcher Discord: https://ykilcher.com/discord LinkedIn: https://www.linkedin.com/in/ykilcher If you want to support me, the best thing to do is to share out the content :) If you want to support me financially (completely optional and voluntary, but a lot of people have asked for this): SubscribeStar: https://www.subscribestar.com/yannickilcher Patreon: https://www.patreon.com/yannickilcher Bitcoin (BTC): bc1q49lsw3q325tr58ygf8sudx2dqfguclvngvy2cq Ethereum (ETH): 0x7ad3513E3B8f66799f507Aa7874b1B0eBC7F85e2 Litecoin (LTC): LQW2TRyKYetVC8WjFkhpPhtpbDM4Vw7r9m Monero (XMR): 4ACL8AGrEo5hAir8A9CeVrW8pEauWvnp1WnSDZxW7tziCDLhZAGsgzhRQABDnFy8yuM9fWJDviJPHKRjV4FWt19CJZN9D4n

What you'll learn

  • Group Relative Policy Optimization (GRPO) is a memory-efficient variant of PPO that enhances mathematical reasoning while reducing computational overhead
  • DeepSeekMath 7B achieves 51.7% on the MATH benchmark through continued pre-training with 120B math-related tokens sourced from public web data
  • A carefully engineered data selection pipeline plays a crucial role in leveraging web data for improved mathematical performance
  • Self-consistency over 64 samples boosts performance to 60.9%, approaching the capabilities of Gemini-Ultra and GPT-4

Frequently asked questions

What is Group Relative Policy Optimization (GRPO) and how does it differ from standard PPO?
GRPO is a variant of Proximal Policy Optimization specifically designed to enhance mathematical reasoning in language models. It provides the same benefits as PPO but with improved memory efficiency, allowing it to scale more effectively.
How does a 7B model achieve such high scores on mathematical benchmarks without external tools?
DeepSeekMath combines continued pre-training with 120B math-specific tokens and GRPO training. A carefully engineered data selection pipeline filters relevant web data, enabling the model to learn complex mathematical reasoning independently.
What is the role of self-consistency in improving mathematical performance?
Self-consistency over 64 samples increases performance from 51.7% to 60.9% on the MATH benchmark. By generating and aggregating multiple reasoning paths, the reliability of mathematical answers is significantly enhanced.
What data source is used for training DeepSeekMath?
DeepSeekMath is continued pre-trained with 120B math-related tokens sourced from Common Crawl, supplemented with natural language and code data. This leverages publicly available web data that has been carefully filtered.

Topics