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

语言模型到底记住了多少?

How much do language models memorize?

FAIR at Meta(Meta 的 FAIR 部门);Google DeepMind(谷歌DeepMind);Cornell University(康奈尔大学);NVIDIA(NVIDIA 公司)

John X. Morris, Chawin Sitawarin, Chuan Guo, Narine Kokhlikyan, G. Edward Suh, Alexander M. Rush, Kamalika Chaudhuri, Saeed Mahloujifar

AI总结:

提出估计模型对数据点了解程度的新方法,将记忆分解为非预期记忆与泛化,通过消除泛化测得GPT模型每参数约3.6比特容量,并发现记忆填满后出现顿悟、非预期记忆下降,训练数百个模型得出缩放定律。

摘要:

我们提出了一种新方法,用于估计模型对某个数据点的了解程度,并利用它来衡量现代语言模型的能力。以往关于语言模型记忆的研究一直难以将记忆与泛化区分开来。我们将记忆正式分解为两个组成部分:非预期记忆,即模型包含的关于特定数据集的信息;以及泛化,即模型包含的关于真实数据生成过程的信息。当我们完全消除泛化时,可以计算出总记忆量,这提供了对模型能力的估计:我们的测量估计,GPT风格模型的能力约为每参数3.6比特。我们在规模不断增大的数据集上训练语言模型,并观察到模型会一直记忆直到其能力被填满,此时“顿悟”开始出现,并且随着模型开始泛化,非预期记忆会减少。我们训练了数百个参数规模从50万到15亿的Transformer语言模型,并产生了一系列将模型能力和数据规模与成员推断联系起来的缩放定律。

英文摘要:

We propose a new method for estimating how much a model knows about a datapoint and use it to measure the capacity of modern language models. Prior studies of language model memorization have struggled to disentangle memorization from generalization. We formally separate memorization into two components: unintended memorization, the information a model contains about a specific dataset, and generalization, the information a model contains about the true data-generation process. When we completely eliminate generalization, we can compute the total memorization, which provides an estimate of model capacity: our measurements estimate that GPT-style models have a capacity of approximately 3.6 bits per parameter. We train language models on datasets of increasing size and observe that models memorize until their capacity fills, at which point "grokking" begins, and unintended memorization decreases as models begin to generalize. We train hundreds of transformer language models ranging from $500K$ to $1.5B$ parameters and produce a series of scaling laws relating model capacity and data size to membership inference.

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

↑