Diversity as a Reward: Fine-Tuning LLMs on a Mixture of Domain-Undetermined Data

Zhenqing Ling, Daoyuan Chen, Liuyi Yao, Qianli Shen, Yaliang Li +1 more
2/5/2025
cs.CLcs.AIcs.LG

No official code found. Best implementation: datajuicer/data-juicer (7,147 stars, Apache-2.0, last commit 2026-04-28).

Abstract

Fine-tuning large language models (LLMs) using diverse datasets is crucial for enhancing their overall performance across various domains. In practical scenarios, existing methods based on modeling the mixture proportions of data composition often struggle with data whose domain labels are missing, imprecise or non-normalized, while methods based on data selection usually encounter difficulties in balancing multi-domain performance. To address these challenges, in this work, we investigate the role of data diversity in enhancing the overall abilities of LLMs by empirically constructing contrastive data pools and theoretically deriving explanations. Building upon the insights gained, we propose a new method that gives the LLM a dual identity: an output model to cognitively probe and select data based on diversity reward, as well as an input model to be tuned with the selected data. Extensive experiments show that the proposed method notably boosts performance across domain-undetermined data and a series of foundational downstream tasks when applied to various advanced LLMs. We release our code and hope this study can shed light on the understanding of data diversity and advance feedback-driven data-model co-design for LLMs.

View on arXivView PDF

Code Implementations(1)

Apache-2.0

Data processing for and with foundation models! 🍎 πŸ‹ 🌽 ➑️ ➑️🍸 🍹 🍷

7,147433C++, ShellAug 1, 20235 months agoApache-2.0
datadata-analysisdata-pipelinedata-processingdata-science+9 more

Cite this paper

@article{ling2025diversity,
  title  = {Diversity as a Reward: Fine-Tuning LLMs on a Mixture of Domain-Undetermined Data},
  author = {Zhenqing Ling and Daoyuan Chen and Liuyi Yao and Qianli Shen and Yaliang Li and Ying Shen},
  year   = {2025},
  eprint = {2502.04380},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2502.04380v3}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2502.04380.svg)](https://codeofpaper.com/paper/2502.04380)

Discussion