复制粘贴语言模型

·

研究论文 · 2026/10/16

我们提出Copy-Paste语言模型(CPLM),在传统语言建模头之外增加一个轻量级的复制粘贴头,以显式建模提升大语言模型在上下文中的复制能力。CPLM提升了训练效率、下游性能,并在长上下文和检索设置中提供新的操作点。通过预训练135M到1.7B参数的模型,我们验证了该方法在所有规模和骨干网络上均带来改进,且训练和推理开销可忽略。我们通过展示CPLM部分缓解了LM头梯度瓶颈(通过替代梯度路径)来解释其成功。

该研究提出了一种简单有效的方法来提升语言模型的复制能力,并在多个规模上验证了其有效性,同时解释了其成功原因,对长上下文和检索应用有潜在价值。

Transformers are intuitively considered to be efficient at copying from their inputs. We actually show that the ability of LLMs to copy in context can be improved through explicit modeling. We propose Copy-Paste Language Models (CPLMs), which add a lightweight Copy-Paste head to the conventional language modeling (LM) head. CPLMs improve training efficiency, downstream performance, and offer new operating points in long-context and retrieval setups. We validate our approach by pretraining models from 135M to 1.7B parameters, showing improvements across all scales and backbones with negligible training and inference overheads. We explain the success of CPLMs by showing that they partially mitigate the LM head gradient bottleneck through an alternative gradient path.

阅读原文

参与讨论