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

Source: [Retaining by Doing: The Role of On-Policy Data in Mitigating Forgetting](<https://www.sota2.com/research/paper/68fa7c6d1e209131cea8e052>)

Collection index: [llms.txt](<https://www.sota2.com/research/llms.txt>)

Data updated: 2026-06-30T05:00:05.200Z

Authors: Howard Chen, Noam Razin, Karthik Narasimhan, Danqi Chen

Published: 2025-10-21T17:59:41.000Z

## Abstract

Adapting language models (LMs) to new tasks via post-training carries the risk of degrading existing capabilities -- a phenomenon classically known as catastrophic forgetting. In this paper, toward identifying guidelines for mitigating this phenomenon, we systematically compare the forgetting patterns of two widely adopted post-training methods: supervised fine-tuning (SFT) and reinforcement learning (RL). Our experiments reveal a consistent trend across LM families (Llama, Qwen) and tasks (instruction following, general knowledge, and arithmetic reasoning): RL leads to less forgetting than SFT while achieving comparable or higher target task performance. To investigate the cause for this difference, we consider a simplified setting in which the LM is modeled as a mixture of two distributions, one corresponding to prior knowledge and the other to the target task. We identify that the mode-seeking nature of RL, which stems from its use of on-policy data, enables keeping prior knowledge intact when learning the target task. We then verify this insight by demonstrating that the use on-policy data underlies the robustness of RL to forgetting in practical settings, as opposed to other algorithmic choices such as the KL regularization or advantage estimation. Lastly, as a practical implication, our results highlight the potential of mitigating forgetting using approximately on-policy data, which can be substantially more efficient to obtain than fully on-policy data.

## Recorded benchmark results

A research result applies to its stated dataset, split, metric and evaluation configuration. Compare like-for-like settings, preserve the metric's unit and direction, and distinguish paper-reported results from independent reproduction. The best result recorded here is not a claim of exhaustive, current global coverage.

- [Coding on HumanEval (pass@1 and Overall Avg.)](<https://www.sota2.com/research/sota/coding-on-humaneval-pass-at-1-and-overall-avg.md>): Coding; HumanEval; Pass@1: 56.4.

- [Coding on MBPP (test)](<https://www.sota2.com/research/sota/coding-on-mbpp-test.md>): Coding; MBPP (test); Pass@1: 71.7.

- [Coding on MBPP+ (pass@1, Overall Avg.)](<https://www.sota2.com/research/sota/coding-on-mbpp-plus-pass-at-1-overall-avg.md>): Coding; MBPP+; Pass@1: 49.4.

- [Multi-task Evaluation on General and Medical Aggregation](<https://www.sota2.com/research/sota/multi-task-evaluation-on-general-and-medical-aggregation.md>): Multi-task Evaluation; General and Medical Aggregation; Overall Average: 48.3.

- [Coding on HumanEval+ (test)](<https://www.sota2.com/research/sota/coding-on-humaneval-plus-test.md>): Coding; HumanEval+ (test); Pass@1: 65.9.

- [Coding on HumanEval (test)](<https://www.sota2.com/research/sota/coding-on-humaneval-test.md>): Coding; HumanEval (test); Test Accuracy: 70.1.

- [Coding Accuracy on MBPP+](<https://www.sota2.com/research/sota/coding-accuracy-on-mbpp-plus.md>): Coding; MBPP+; Accuracy: 49.7.

- [Science on MMLU-Pro](<https://www.sota2.com/research/sota/science-on-mmlu-pro.md>): Science; MMLU-Pro; Accuracy: 39.6.

- [Science on MMLU-Pro (test)](<https://www.sota2.com/research/sota/science-on-mmlu-pro-test.md>): Science; MMLU Pro (test); Accuracy: 35.8.

- [Medical on MedCalc](<https://www.sota2.com/research/sota/medical-on-medcalc.md>): Medical; MedCalc; Accuracy: 29.

- [Math on iGSM](<https://www.sota2.com/research/sota/math-on-igsm.md>): Math; iGSM; Accuracy: 29.4.

- [Coding on MBPP (pass@1 accuracy)](<https://www.sota2.com/research/sota/coding-on-mbpp-pass-at-1-accuracy.md>): Coding; MBPP; Pass@1 Accuracy: 74.1.

- [Coding on MBPP (pass@1 and Overall Avg.)](<https://www.sota2.com/research/sota/coding-on-mbpp-pass-at-1-and-overall-avg.md>): Coding; MBPP; Overall Average Score: 39.6.

- [Coding on HumanEval](<https://www.sota2.com/research/sota/coding-on-humaneval.md>): Coding; HumanEval; Pass@1: 71.3.

- [Coding on MBPP+](<https://www.sota2.com/research/sota/coding-on-mbpp-plus.md>): Coding; MBPP+; Pass@1: 63.8.

- [Mathematical Reasoning on Countdown (test)](<https://www.sota2.com/research/sota/mathematical-reasoning-on-countdown-test.md>): Mathematical Reasoning; COUNTDOWN (test); Accuracy: 20.9.

- [Coding on HumanEval (accuracy)](<https://www.sota2.com/research/sota/coding-on-humaneval-accuracy.md>): Coding; HumanEval; Accuracy: 57.1.

- [Coding on HumanEval+](<https://www.sota2.com/research/sota/coding-on-humaneval-plus.md>): Coding; HumanEval+; Pass@1: 64.6.

- [Mathematical Reasoning on Countdown](<https://www.sota2.com/research/sota/mathematical-reasoning-on-countdown.md>): Mathematical Reasoning; Countdown; Accuracy: 29.

- [Coding on MBPP (Accuracy)](<https://www.sota2.com/research/sota/coding-on-mbpp-accuracy.md>): Coding; MBPP; Accuracy: 56.9.

- [Instruction Following on IFEval](<https://www.sota2.com/research/sota/instruction-following-on-ifeval.md>): Instruction Following; IFEval; IFEval Accuracy: 52.6.

- [Instruction Following on IFEval (test)](<https://www.sota2.com/research/sota/instruction-following-on-ifeval-test.md>): Instruction Following; IFEval (test); IFEval Score: not recorded.

## Original sources and implementation

[Original paper](<https://arxiv.org/abs/2510.18874>)

[PDF](<https://arxiv.org/pdf/2510.18874.pdf>)
