Grokking in LLM Pretraining? Monitor Memorization-to-Generalization without Test
On the map: Mixture-of-experts → MoE large language models
Abstract (arXiv)
This paper presents the first study of grokking in practical LLM pretraining. Specifically, we investigate when an LLM memorizes the training data, when its generalization on downstream tasks starts to improve, and what happens if there is a lag between the two. Unlike existing works studying when a small model generalizes to limited and specified tasks during thousands epochs' training on algorithmic data, we focus on a practical setting for LLMs, i.e., one-epoch pretraining of next-token prediction on a cross-domain, large-scale corpus, and generalization on diverse benchmark tasks covering math/commonsense reasoning, code generation, and domain-specific retrieval. Our study, for the first time, verifies that grokking still emerges in pretraining mixture-of-experts (MoE) LLMs, though different local data groups may enter their grokking stages asynchronously due to the heterogeneity of their distributions and attributions to others. To find a mechanistic interpretation of this local grokking, we investigate the dynamics of training data's pathways (i.e., expert choices across layers in MoE). Our primary discovery is that the pathways evolve from random, non-smooth across layers, instance-specific to more structured and transferable across samples, despite the converged pretraining loss. This depicts a transition from memorization to generalization. Two novel metrics are developed to quantify these patterns: one computes the pathway similarity between samples, while the other measures the consistency of aggregated experts between subsequent layers for each sample. These training data based metrics induce zero cost but can faithfully track and monitor the generalization of LLMs on downstream tasks, which, in conventional settings, requires costly instruction tuning and benchmark evaluation.
Key facts. Cited by 10 papers in the map (data through 14 Oct 2026). Placed in MoE large language models, one of 12 directions in Mixture-of-experts. Builds on 25 of its 32 references that are in the map. First posted on arXiv 26 Jun 2025.
Builds on
25 of 32 references.
Closest ancestors · 2
Same direction, newest first
- 2025Qwen3 Technical Report14 May
- 2024A Closer Look into Mixture-of-Experts in Large Language Models26 Jun
Other references · 23
- 2017Attention Is All You Needcited by 60,361
- 2015Deep Residual Learning for Image Recognitioncited by 52,096
- 2020Language Models are Few-Shot Learnerscited by 32,419
- 2022Chain-of-Thought Prompting Elicits Reasoning in Large Language Modelscited by 12,459
- 2019Sentence-BERT: Sentence Embeddings using Siamese BERT-Networkscited by 9,170
- 2018Think you have Solved Question Answering? Try ARC, the AI2 Reasoning Challengecited by 4,886
- 2019HellaSwag: Can a Machine Really Finish Your Sentence?cited by 4,100
- 2020The Pile: An 800GB Dataset of Diverse Text for Language Modelingcited by 2,411
- 2018Can a Suit of Armor Conduct Electricity? A New Dataset for Open Book Question Answeringcited by 2,164
- 2023Progress measures for grokking via mechanistic interpretabilitycited by 839
- 2022Grokking: Generalization Beyond Overfitting on Small Algorithmic Datasetscited by 629
- 2022Towards Reasoning in Large Language Models: A Surveycited by 596
11 more
- 2022Towards Understanding Grokking: An Effective Theory of Representation Learningcited by 230
- 2022Omnigrok: Grokking Beyond Algorithmic Datacited by 146
- 2024Min-K%++: Improved Baseline for Detecting Pre-Training Data from Large Language Modelscited by 103
- 2023A Tale of Two Circuits: Grokking as Competition of Sparse and Dense Subnetworkscited by 83
- 2024Grokked Transformers are Implicit Reasoners: A Mechanistic Journey to the Edge of Generalizationcited by 79
- 2024Deep Networks Always Grok and Here is Whycited by 51
- 2025Grokking at the Edge of Numerical Stabilitycited by 46
- 2023Predicting Grokking Long Before it Happens: A look into the loss landscape of models which grokcited by 35
- 2024Unified View of Grokking, Double Descent and Emergent Abilities: A Perspective from Circuits Competitioncited by 23
- 2023Understanding Grokking Through A Robustness Viewpointcited by 12
- 2024Dual Instruction Tuning with Large Language Models for Mathematical Reasoningcited by 10
Built on by
Citing papers per year: 2025: 2; 2026: 8.
10 papers.
- 2025Rote Learning Considered Useful: Generalizing over Memorized Data in LLMscited by 5
- 2025Rewiring Experts on the Fly:Continuous Rerouting for Better Online Adaptation in Mixture-of-Expert modelscited by 3
- 2026Spectral Entropy Collapse as a Phase Transition in Delayed Generalisation: An Interventional and Predictive Framework for Grokkincited by 2
- 2026Opening the Black Box: A Survey on the Mechanisms of Multi-Step Reasoning in Large Language Modelscited by 1
- 2026Beyond Temperature: Hyperfitting as a Late-Stage Geometric Expansioncited by 1
- 2026A Pre-Training Analogue of Grokking in Language Models: Tracing Delayed Grammatical Generalizationcited by 1
- 2026Train Smarter, Not Longer: Memorization-Guided Data Reuse for Efficient LLM Trainingcited by 1
- 2026Deep Exploration of Epoch-wise Double Descent in Noisy Data: Signal Separation, Large Activation, and Benign Overfittingcited by 0
- 2026Neuro-symbolic Syntactic Parsing: Shaping a Neural Network with the CYK Algorithmcited by 0
- 2026Towards Mechanistically Understanding Why Memorized Knowledge Fails to Generalize in Large Language Model Finetuningcited by 0
- 2026Towards Mechanistically Understanding Why Memorized Knowledge Fails to Generalize in Large Language Model Finetuning9 Jul 2026
- 2026Train Smarter, Not Longer: Memorization-Guided Data Reuse for Efficient LLM Training6 Jul 2026
- 2026A Pre-Training Analogue of Grokking in Language Models: Tracing Delayed Grammatical Generalization29 May 2026
- 2026Neuro-symbolic Syntactic Parsing: Shaping a Neural Network with the CYK Algorithm29 May 2026
- 2026Beyond Temperature: Hyperfitting as a Late-Stage Geometric Expansion21 May 2026
- 2026Spectral Entropy Collapse as a Phase Transition in Delayed Generalisation: An Interventional and Predictive Framework for Grokkin13 Apr 2026
- 2026Deep Exploration of Epoch-wise Double Descent in Noisy Data: Signal Separation, Large Activation, and Benign Overfitting13 Jan 2026
- 2026Opening the Black Box: A Survey on the Mechanisms of Multi-Step Reasoning in Large Language Models2 Jan 2026
- 2025Rewiring Experts on the Fly:Continuous Rerouting for Better Online Adaptation in Mixture-of-Expert models16 Oct 2025
- 2025Rote Learning Considered Useful: Generalizing over Memorized Data in LLMs29 Jul 2025
Similar, not cited
Close in wording, no citation either way
- 2024What Do Learning Dynamics Reveal About Generalization in LLM Reasoning?
- 2023SoK: Memorization in General-Purpose Large Language Models
- 2024Generalization v.s. Memorization: Tracing Language Models' Capabilities Back to Pretraining Data
- 2025LLM Post-Training: A Deep Dive into Reasoning Large Language Models
- 2025The Landscape of Memorization in LLMs: Mechanisms, Measurement, and Mitigation
- 2024Language Models "Grok" to Copy
- 2025When Data Falls Short: Grokking Below the Critical Threshold
- 2025Prismatic Synthesis: Gradient-based Data Diversification Boosts Generalization in LLM Reasoning