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

通过支持性预训练数据理解上下文学习

Understanding In-Context Learning via Supportive Pretraining Data

Meta AI;University of Washington(华盛顿大学)

Xiaochuang Han, Daniel Simig, Todor Mihaylov, Yulia Tsvetkov, Asli Celikyilmaz, Tianlu Wang

AI总结:

本文通过基于梯度的迭代方法提取支持ICL的预训练数据子集,发现对其进行持续预训练可使ICL能力提升18%,并揭示该数据具有长尾词元多、长程上下文信息增益低等特征。

摘要:

上下文学习(ICL)通过在推理时仅展示少量示例,提升了语言模型在各种NLP任务上的表现。由于模型从未针对此类演示进行过专门训练,ICL能力为何会产生尚不清楚。与以往探索ICL背后隐含机制的研究不同,我们通过调查预训练数据来研究ICL。具体而言,我们首先采用一种迭代的、基于梯度的方法,找到支持ICL的一小部分预训练数据子集。我们观察到,在这一小子集上进行持续预训练,可将模型的ICL能力显著提升高达18%。随后,我们将该支持性子集与预训练数据的随机子集进行对比分析,发现:(1)支持ICL的预训练数据对下游任务并没有更高的领域相关性。(2)支持性预训练数据包含更多极少出现的长尾词元。(3)支持性预训练数据属于具有挑战性的样本,其从长程上下文中获得的信息增益低于平均水平,这表明学习整合困难的长程上下文有助于促进ICL。我们的工作通过分析实例级预训练数据,迈出了理解ICL的第一步。我们的见解有望在未来通过主动指导预训练数据的构建,来增强语言模型的ICL能力。

英文摘要:

In-context learning (ICL) improves language models' performance on a variety of NLP tasks by simply demonstrating a handful of examples at inference time. It is not well understood why ICL ability emerges, as the model has never been specifically trained on such demonstrations. Unlike prior work that explores implicit mechanisms behind ICL, we study ICL via investigating the pretraining data. Specifically, we first adapt an iterative, gradient-based approach to find a small subset of pretraining data that supports ICL. We observe that a continued pretraining on this small subset significantly improves the model's ICL ability, by up to 18%. We then compare the supportive subset constrastively with random subsets of pretraining data and discover: (1) The supportive pretraining data to ICL do not have a higher domain relevance to downstream tasks. (2) The supportive pretraining data have a higher mass of rarely occurring, long-tail tokens. (3) The supportive pretraining data are challenging examples where the information gain from long-range context is below average, indicating learning to incorporate difficult long-range context encourages ICL. Our work takes a first step towards understanding ICL via analyzing instance-level pretraining data. Our insights have a potential to enhance the ICL ability of language models by actively guiding the construction of pretraining data in the future.

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

↑