Retaining by Doing: The Role of On-Policy Data in Mitigating Forgetting

Howard Chen, Noam Razin, Karthik Narasimhan, Danqi Chen · DOI

Abstract

Adapting large language models (LLMs) to new tasks often results in "catastrophic forgetting," where existing knowledge is eroded. This paper investigates why Reinforcement Learning (RL) typically preserves original capabilities better than Supervised Fine-Tuning (SFT). Through empirical analysis and theoretical modeling using Gaussian mixtures, the authors demonstrate that RL's robustness stems from its use of on-policy data and its "mode-seeking" nature (Reverse KL), which targets specific behaviors without disrupting established knowledge modes.

Introduction

When pre-trained language models are fine-tuned to follow instructions or solve specialized problems, they often suffer from an "alignment tax"—a decline in general reasoning or world knowledge. While RL-based alignment methods like PPO or GRPO have been observed to mitigate this forgetting better than Supervised Fine-Tuning (SFT), the underlying mechanism remained unclear. This research identifies the use of on-policy data as the critical factor that allows RL to refine new behaviors while preserving internal knowledge.

Methodology

The study employs a multi-faceted approach to isolate the causes of forgetting:

  1. Systematic Empirical Comparison: Evaluating Llama 3 and Qwen 2.5 models (up to 8B parameters) on target tasks (IFEval, MMLU, Countdown) and non-target tasks (MATH, safety benchmarks).
  2. Theoretical Modeling: Using a mixture-of-Gaussians model to compare Forward KL (the objective of SFT) against Reverse KL (the objective of RL).
  3. Ablation Studies: Systematically removing RL components—like KL penalties and advantage estimators—and testing Iterative-SFT, which uses approximately on-policy data generated by the model itself at the start of each epoch.

Key Insights: Mode-Seeking vs. Mode-Covering

The core of the paper's argument lies in the difference between how SFT and RL interact with a model's multi-modal distribution. Real-world LMs are multi-modal, containing many different "modes" of knowledge.

Comparison of Forward KL (SFT) and Reverse KL (RL) optimization dynamics on a multi-modal distribution.
  • Mode-Covering (SFT): SFT utilizes the Forward KL objective, which is "mode-covering." It attempts to stretch the model's distribution to encompass the entire target dataset. In a multi-modal landscape, this stretching pulls probability mass away from existing "modes" of knowledge, leading to a "Large Drop" in prior capabilities.
  • Mode-Seeking (RL): RL utilizes the Reverse KL objective, which is "mode-seeking." It focuses on finding and reinforcing the most rewarding paths within the model's current capabilities. This allows the new mode to maintain its shape and shift toward the optimal target while leaving the prior knowledge modes intact.
  • The Power of On-Policy Data: The authors find that the primary driver of RL's robustness is not the complex mathematical machinery (like advantage estimation) but the data itself. Training on responses generated by the model (on-policy) allows it to refine its internal logic rather than forcing it to mimic an external distribution that may conflict with its prior knowledge.

Key Results

  • Superior Robustness: Across all model families and scales, RL consistently achieved high performance on target tasks with near-zero drops in non-target task accuracy. SFT, conversely, exhibited a sharp trade-off: the more the model learned the new task, the more it forgot the old ones.
  • Iterative-SFT Effectiveness: By simply re-sampling training data from the model at the start of each epoch, the researchers significantly reduced forgetting in SFT. This suggests that "approximately on-policy" data can provide many of the benefits of RL with lower computational overhead.

Conclusion and Future Work

This research highlights that the "alignment tax" is not an inevitable consequence of fine-tuning but a byproduct of the optimization objective and data distribution. While the findings are robust for models up to 8B parameters, future work is needed to explore these dynamics in larger "frontier" models and in the context of long-term continual learning across sequential tasks.

Summary updated

BibTeX
@inproceedings{chen2026retaining,
  author = {Howard Chen and Noam Razin and Karthik Narasimhan and Danqi Chen},
  title = {{Retaining by Doing: The Role of On-Policy Data in Mitigating Forgetting}},
  booktitle = {International Conference on Machine Learning},
  year = {2026},
  url = {https://openreview.net/forum?id=ODTM64azGa},
}
Figure