arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2611.38437cs.CL
收藏

微调语言模型前预测其记忆行为

Predicting Memorization Before Fine-Tuning Language Models

Northeastern University(东北大学);Carnegie Mellon University(卡内基梅隆大学)

Jaydeep Borkar, Niloofar Mireshghallah, David A. Smith

AI总结:

本文提出无需微调目标模型,仅基于预训练模型特征与单次微调记忆标签训练分类器,可准确预测语言模型微调时的记忆行为,且该分类器具跨领域、家族与规模的泛化性。

摘要:

已知语言模型会记忆并复现训练数据,当训练数据含敏感信息时会引发严重担忧。微调数据常为私有且专有的,因此从业者在训练开始前了解哪些序列会被记忆是有益的。现有预测微调记忆的方法仍需部分训练目标模型。本文表明,无需微调目标模型即可预测其记忆行为:从预训练基础模型计算特征,并基于单次微调运行的记忆标签拟合分类器,以预测未来运行会记忆的序列。该分类器在六个领域(FineWeb、Enron、PG-19、The Stack、OpenWebMath、WildChat)和三个模型家族(Pythia、Qwen-2.5、Llama-3.2)中,多数情况下ROC-AUC达至少0.9。此外,在单个领域、模型家族及模型规模上训练的分类器,可预测未见过的领域、家族及规模的记忆行为。进一步发现序列的可学习性影响其被记忆的方式,还研究了Qwen-2.5从0.5B到14B的阶梯式缩放的记忆规律,发现记忆率和分类器精度均随模型规模呈幂律变化,记忆量随规模增长为N^0.39至N^0.83。

英文摘要:

Language models are known to memorize and later regurgitate their training data, raising serious concerns when it is sensitive. Fine-tuning data is often private and proprietary, so a practitioner benefits from knowing which sequences will be memorized before training begins. Existing methods for predicting fine-tuning memorization still require partially training the target model. We show that memorization in a target model can be predicted without fine-tuning that model at all. We compute features from the pretrained base model and fit a classifier on memorization labels from a single fine-tuning run to predict the sequences future runs will memorize. This classifier reaches an ROC-AUC of at least 0.9 in most cases across six domains (FineWeb, Enron, PG-19, The Stack, OpenWebMath, WildChat) and three model families (Pythia, Qwen-2.5, Llama-3.2). Moreover, a classifier trained on a single domain, model family, & model size predicts memorization in unseen domains, families, and sizes. We further find that the learnability of a sequence shapes how it gets memorized. Finally, we study scaling laws for memorization on a Qwen-2.5 ladder from 0.5B to 14B, and find that both the memorization rate and our classifier's precision follow a power law in model size, with memorization growing as $N^{0.39}$ to $N^{0.83}$.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑