arXiv:2502.01968cs.CLcs.AI2025-02ICML被引 40

通过清理无关词汇提升大模型微调效果,让每条数据更精准有用。

Token Cleaning: Fine-Grained Data Selection for LLM Supervised Fine-Tuning

  • 基于令牌对模型更新的影响评估质量,筛选冗余或有害词汇
  • 单次遍历或迭代自进化参考模型均可实现,提升下游任务准确率
  • 适合需要高质量微调数据的场景,尤其在数据噪声较多时优势明显

近期研究表明,在大语言模型(LLM)的监督微调(SFT)中,数据质量比数量更重要。现有方法多聚焦于整条样本过滤,但样本内各令牌的质量差异显著。预训练后,即使高质量样本中也可能包含与任务无关的冗余、无信息或有害模式。继续在这些内容上微调可能收益有限,甚至损害下游性能。本文从噪声标签视角分析令牌质量,提出一种通用的令牌清理流程。该方法在保留关键任务信息的同时,剔除无意义令牌。具体地,通过考察每个令牌对模型更新的影响来评估质量,再以阈值进行分离。影响度可在固定参考模型单次遍历中计算,或通过自演化参考模型迭代计算。理论上通过误差上界分析两种方法的优劣。大量实验表明,该框架能持续提升下游性能。代码已开源:https://github.com/UCSC-REAL/TokenCleaning。

原文摘要 · Abstract (English)

Recent studies show that in supervised fine-tuning (SFT) of large language models (LLMs), data quality matters more than quantity. While most data cleaning methods concentrate on filtering entire samples, the quality of individual tokens within a sample can vary significantly. After pre-training, even in high-quality samples, patterns or phrases that are not task-related can be redundant, uninformative, or even harmful. Continuing to fine-tune on these patterns may offer limited benefit and even degrade downstream task performance. In this paper, we investigate token quality from a noisy-label perspective and propose a generic token cleaning pipeline for SFT tasks. Our method filters out uninformative tokens while preserving those carrying key task-specific information. Specifically, we first evaluate token quality by examining the influence of model updates on each token, then apply a threshold-based separation. The token influence can be measured in a single pass with a fixed reference model or iteratively with self-evolving reference models. The benefits and limitations of both methods are analyzed theoretically by error upper bounds. Extensive experiments show that our framework consistently improves downstream performance. Code is available at https://github.com/UCSC-REAL/TokenCleaning.

大模型微调数据清洗令牌质量

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。