[论文解读] Data Distributional Properties Drive Emergent In-Context Learning in Transformers
论文表明,变换器中的新兴上下文学习依赖于训练数据分布(突发性、长尾类别多样性、动态含义),且架构和数据属性共同决定或限制这一能力。
Large transformer-based models are able to perform in-context few-shot learning, without being explicitly trained for it. This observation raises the question: what aspects of the training regime lead to this emergent behavior? Here, we show that this behavior is driven by the distributions of the training data itself. In-context learning emerges when the training data exhibits particular distributional properties such as burstiness (items appear in clusters rather than being uniformly distributed over time) and having large numbers of rarely occurring classes. In-context learning also emerges more strongly when item meanings or interpretations are dynamic rather than fixed. These properties are exemplified by natural language, but are also inherent to naturalistic data in a wide range of other domains. They also depart significantly from the uniform, i.i.d. training distributions typically used for standard supervised learning. In our initial experiments, we found that in-context learning traded off against more conventional weight-based learning, and models were unable to achieve both simultaneously. However, our later experiments uncovered that the two modes of learning could co-exist in a single model when it was trained on data following a skewed Zipfian distribution -- another common property of naturalistic data, including language. In further experiments, we found that naturalistic data distributions were only able to elicit in-context learning in transformers, and not in recurrent models. In sum, our findings indicate how the transformer architecture works together with particular properties of the training data to drive the intriguing emergent in-context learning behaviour of large language models, and how future work might encourage both in-context and in-weights learning in domains beyond language.
研究动机与目标
- 调查变换器模型在没有显式元训练的情况下如何获得上下文小样本学习。
- 识别促进或抑制上下文学习的训练数据分布属性。
- 考察架构(变换器与递归模型)在实现上下文学习中的作用。
- 探讨在何种条件下上下文学习与传统基于权重的学习可以共存。
提出的方法
- 在 Omniglot 的图像-标签对序列上训练变换器和递归模型。
- 系统性操纵数据分布属性:突发性、类别数量、标签多重性,以及类内差异。
- 在保留集类别上评估上下文学习,在训练类别上使用标准的小样本设置测试基于权重的学习。
- 测试 Zipfian(偏斜)类别分布对两种学习模式共存的影响。
- 比较变换器与递归架构以分离注意力机制的作用。
实验结果
研究问题
- RQ1哪些数据分布属性促进变换器中的新兴上下文学习?
- RQ2突发性和长尾类别分布如何影响上下文学习与基于权重的学习?
- RQ3在相同数据条件下,变换器和递归模型是否在表现上下文学习方面存在差异?
- RQ4在何种条件下同一模型可以同时存在上下文学习和基于权重的学习?
主要发现
- 当训练数据具有突发性且包含许多很少出现的类别时,变换器中的上下文学习会出现。
- 增加突发性会提升上下文学习,但降低基于权重的学习,表明两种模式之间存在折衷。
- 更多类别数量(长尾分布)进一步增强上下文学习,减少基于权重的学习。
- 动态含义(标签多重性和类内变异)提升上下文学习。
- 近似指数为1的 Zipfian 分布可以同时支撑上下文学习与基于权重的学习,与自然语言统计相一致。
- 在相同数据条件下,递归模型(普通 RNN、LSTM)未显示上下文学习,突出架构特异性效应。
阅读本论文
在 Nubint 阅读器中打开原文,边读边就任意段落提问。
在 Nubint 中阅读本论文本解读由 AI 根据论文原文生成,引用前请核对原文。