arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2502.07490cs.CLcs.LG
收藏

增强的自回归预测:少关注多学习

Mask-Enhanced Autoregressive Prediction: Pay Less Attention to Learn More

Xialie Zhuang, Zhikai Jia, Jianjin Li, Zhenyu Zhang, Li Shen, Zheng Cao, Shiwei Liu

AI总结:

本文提出MEAP方法,通过整合MLM与NTP提升上下文检索能力,实验显示其在关键信息检索和长上下文推理任务中表现优异,且在常识推理任务中不逊色。

摘要:

大型语言模型(LLMs)被发现在准确检索关键信息方面存在困难。为此,我们提出了Mask-Enhanced Autoregressive Prediction(MEAP),一种简单而有效的训练范式,将Masked Language Modeling(MLM)无缝整合到Next-Token Prediction(NTP)中以增强后者上下文检索能力。具体而言,MEAP首先随机屏蔽输入中的一小部分token,然后直接使用解码器-only Transformer进行标准的next-token预测自回归。MEAP消除了双向注意力或编码器-解码器架构对MLM的依赖,在预训练或推理过程中不增加额外的计算开销。大量实验表明,MEAP在关键信息检索和长上下文推理任务中显著优于NTP,而在常识推理任务中表现相当或更好。MEAP的益处也扩展到监督微调,其中在lost-in-the-middle场景中,其比NTP高出11.77个百分点。我们的分析表明,MEAP的有效性源于其通过集中于减少的非屏蔽token集促进更可区分的注意力分数的能力。这种机制提高了模型对任务相关信号的关注,同时减轻了外围上下文的影响。这些发现将MEAP定位为大型语言模型的一种有前途的训练范式。

英文摘要:

Large Language Models (LLMs) are discovered to suffer from accurately retrieving key information. To address this, we propose Mask-Enhanced Autoregressive Prediction (MEAP), a simple yet effective training paradigm that seamlessly integrates Masked Language Modeling (MLM) into Next-Token Prediction (NTP) to enhance the latter's in-context retrieval capabilities. Specifically, MEAP first randomly masks a small fraction of input tokens and then directly performs the standard next-token prediction autoregressive using a decoder-only Transformer. MEAP eliminates the need for bidirectional attention or encoder-decoder architectures for MLM, incurring no additional computational overhead during pre-training or inference. Intensive experiments demonstrate that MEAP substantially outperforms NTP on key information retrieval and long-context reasoning tasks, while performing on par or better on commonsense reasoning tasks. The benefits of MEAP also extend to supervised fine-tuning, where it shows remarkable advantages in lost-in-the-middle scenarios, outperforming NTP by 11.77 percentage points. Our analysis indicates that MEAP's effectiveness arises from its ability to promote more distinguishable attention scores by concentrating on a reduced set of non-masked tokens. This mechanism improves the model's focus on task-relevant signals while mitigating the influence of peripheral context. These findings position MEAP as a promising training paradigm for large language models.

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

↑