mlsanityData to 14 Oct 2026

Data Mixing Agent: Learning to Re-weight Domains for Continual Pre-training

arXiv 2507.15640 ↗First posted 21 Jul 2025cs.LG cs.AI cs.CLcited by 5

On the map: LLM agents and tool use → General LLM agent frameworks and benchmarks

Abstract (arXiv)

Continual pre-training on small-scale task-specific data is an effective method for improving large language models in new target fields, yet it risks catastrophic forgetting of their original capabilities. A common solution is to re-weight training data mixtures from source and target fields on a domain space to achieve balanced performance. Previous domain reweighting strategies rely on manual designation with certain heuristics based on human intuition or empirical results. In this work, we prove that more general heuristics can be parameterized by proposing Data Mixing Agent, the first model-based, end-to-end framework that learns to re-weight domains. The agent learns generalizable heuristics through reinforcement learning on large quantities of data mixing trajectories with corresponding feedback from an evaluation environment. Experiments in continual pre-training on math reasoning show that Data Mixing Agent outperforms strong baselines in achieving balanced performance across source and target field benchmarks. Furthermore, it generalizes well across unseen source fields, target models, and domain spaces without retraining. Direct application to the code generation field also indicates its adaptability across target domains. Further analysis showcases the agents' well-aligned heuristics with human intuitions and their efficiency in achieving superior model performance with less source-field data.

Key facts. Cited by 5 papers in the map (data through 14 Oct 2026). Placed in General LLM agent frameworks and benchmarks, one of 16 directions in LLM agents and tool use. Builds on 45 of its 57 references that are in the map. First posted on arXiv 21 Jul 2025.

Builds on

45 of 57 references.

References · 45

  1. 2017Attention Is All You Needcited by 60,361
  2. 2024The Llama 3 Herd of Modelscited by 14,715
  3. 2021Training Verifiers to Solve Math Word Problemscited by 10,109
  4. 2024DeepSeekMath: Pushing the Limits of Mathematical Reasoning in Open Language Modelscited by 9,379
  5. 2025Qwen3 Technical Reportcited by 8,820
  6. 2021Evaluating Large Language Models Trained on Codecited by 8,320
  7. 2020Measuring Massive Multitask Language Understandingcited by 7,963
  8. 2021Measuring Mathematical Problem Solving With the MATH Datasetcited by 5,371
  9. 2018Think you have Solved Question Answering? Try ARC, the AI2 Reasoning Challengecited by 4,886
  10. 2019HellaSwag: Can a Machine Really Finish Your Sentence?cited by 4,100
  11. 2021Program Synthesis with Large Language Modelscited by 3,637
  12. 2019PIQA: Reasoning about Physical Commonsense in Natural Languagecited by 2,883
33 more
  1. 2020The Pile: An 800GB Dataset of Diverse Text for Language Modelingcited by 2,411
  2. 2018Can a Suit of Armor Conduct Electricity? A New Dataset for Open Book Question Answeringcited by 2,164
  3. 2019Megatron-LM: Training Multi-Billion Parameter Language Models Using Model Parallelismcited by 1,868
  4. 2020Conservative Q-Learning for Offline Reinforcement Learningcited by 1,809
  5. 2023Pythia: A Suite for Analyzing Large Language Models Across Training and Scalingcited by 1,786
  6. 2022Solving Quantitative Reasoning Problems with Language Modelscited by 1,392
  7. 2019Distributionally Robust Neural Networks for Group Shifts: On the Importance of Regularization for Worst-Case Generalizationcited by 1,247
  8. 2024Qwen2.5-Coder Technical Reportcited by 1,203
  9. 2024DeepSeek-Coder: When the Large Language Model Meets Programming -- The Rise of Code Intelligencecited by 1,181
  10. 2024The FineWeb Datasets: Decanting the Web for the Finest Text Data at Scalecited by 1,160
  11. 2024Qwen2.5-Math Technical Report: Toward Mathematical Expert Model via Self-Improvementcited by 1,090
  12. 2021GLaM: Efficient Scaling of Language Models with Mixture-of-Expertscited by 897
  13. 2017Crowdsourcing Multiple Choice Science Questionscited by 765
  14. 2019MathQA: Towards Interpretable Math Word Problem Solving with Operation-Based Formalismscited by 662
  15. 2023An Empirical Study of Catastrophic Forgetting in Large Language Models During Continual Fine-tuningcited by 639
  16. 2023Sheared LLaMA: Accelerating Language Model Pre-training via Structured Pruningcited by 415
  17. 2023DoReMi: Optimizing Data Mixtures Speeds Up Language Model Pretrainingcited by 399
  18. 2024DataComp-LM: In search of the next generation of training sets for language modelscited by 398
  19. 2024Continual Learning of Large Language Models: A Comprehensive Surveycited by 234
  20. 2024Data Mixing Laws: Optimizing Data Mixtures by Predicting Language Modeling Performancecited by 184
  21. 2024RegMix: Data Mixture as Regression for Language Model Pre-trainingcited by 177
  22. 2024Nemotron-CC: Transforming Common Crawl into a Refined Long-Horizon Pretraining Datasetcited by 160
  23. 2023MathCoder: Seamless Code Integration in LLMs for Enhanced Mathematical Reasoningcited by 156
  24. 2024Large Language Models for Time Series: A Surveycited by 114
  25. 2024Unpacking DPO and PPO: Disentangling Best Practices for Learning from Preference Feedbackcited by 107
  26. 2021d3rlpy: An Offline Deep Reinforcement Learning Librarycited by 84
  27. 2025Organize the Web: Constructing Domains Enhances Pre-Training Data Curationcited by 76
  28. 2023SlimPajama-DC: Understanding Data Combinations for LLM Trainingcited by 72
  29. 2025MIRA: Medical Time Series Foundation Model for Real-World Health Datacited by 22
  30. 2024Velocitune: A Velocity-based Dynamic Domain Reweighting Method for Continual Pre-trainingcited by 12
  31. 2025SampleMix: A Sample-wise Pre-training Data Mixing Strategey by Coordinating Data Quality and Diversitycited by 10
  32. 2025Commute Your Domains: Trajectory Optimality Criterion for Multi-Domain Learningcited by 9
  33. 2025Sigma: Differential Rescaling of Query, Key and Value for Efficient Language Modelscited by 3

Built on by

Cited by year (2026 to 14 Oct)

Citing papers per year: 2025: 1; 2026: 4.

5 papers.

Similar, not cited

Close in wording, no citation either way

  1. 2026Always Learning, Always Mixing: Efficient and Simple Data Mixing All The Time
  2. 2026Rethinking Data Mixing from the Perspective of Large Language Models
  3. 2025Towards Continuous Intelligence Growth: Self-Training, Continual Learning, and Dual-Scale Memory in SuperIntelliAgent
  4. 2026ContinualSkillBench: Can LLM Agents Truly Evolve Their Capabilities?
  5. 2026USA: Update-aware SAM for Cross-domain On-Policy Disitllation of Language Agents
  6. 2025AgentRefine: Enhancing Agent Generalization through Refinement Tuning
  7. 2025SWE-Bench-CL: Continual Learning for Coding Agents
  8. 2026Mid-Training with Self-Generated Data Improves Reinforcement Learning in Language Models