arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2406.00131cs.LGcs.CLstat.ML
收藏

从非结构化数据到上下文学习:探索哪些任务可以被学习以及何时可以学习

From Unstructured Data to In-Context Learning: Exploring What Tasks Can Be Learned and When

University of Michigan(密歇根大学)

Kevin Christian Wibisono, Yixin Wang

AI总结:

本研究探讨了在非结构化数据上训练的模型中上下文学习能力的来源,发现共现建模足以实现类比任务,而位置信息对逻辑推理至关重要,并指出了ICL失败的条件。

摘要:

大型语言模型(LLMs)如变换器展示了令人印象深刻的上下文学习(ICL)能力,使它们能够基于提示示例对新任务进行预测,而无需参数更新。尽管现有的ICL理论通常假设训练数据具有类似于ICL任务的结构(例如,线性回归的x-y对),但LLMs通常在非结构化文本(如网页内容)上进行无监督训练,这些文本缺乏与词类比等任务的明确对应关系。为解决这一差距,我们研究了在非结构化数据上训练的模型中是什么使得ICL成为可能,重点关注关键的序列模型要求和训练数据结构。我们发现,许多ICL能力可以简单地从非结构化数据中语义相关词对的共现中涌现;例如,词类比完成可以证明仅通过共现建模即可实现,使用经典语言模型如连续词袋(CBOW),无需位置信息或注意力机制。然而,对于需要泛化到未见标记的逻辑推理任务,位置信息变得至关重要。最后,我们确定了ICL失败的两个案例:一是需要泛化到新的未见模式的逻辑推理任务,二是相关词对仅出现在固定训练位置的类比完成任务。这些发现表明,LLMs的ICL能力在很大程度上依赖于其训练数据中的结构元素。

英文摘要:

Large language models (LLMs) like transformers demonstrate impressive in-context learning (ICL) capabilities, allowing them to make predictions for new tasks based on prompt exemplars without parameter updates. While existing ICL theories often assume structured training data resembling ICL tasks (e.g., x-y pairs for linear regression), LLMs are typically trained unsupervised on unstructured text, such as web content, which lacks clear parallels to tasks like word analogy. To address this gap, we examine what enables ICL in models trained on unstructured data, focusing on critical sequence model requirements and training data structure. We find that many ICL capabilities can emerge simply from co-occurrence of semantically related word pairs in unstructured data; word analogy completion, for example, can provably arise purely through co-occurrence modeling, using classical language models like continuous bag of words (CBOW), without needing positional information or attention mechanisms. However, positional information becomes crucial for logic reasoning tasks requiring generalization to unseen tokens. Finally, we identify two cases where ICL fails: one in logic reasoning tasks that require generalizing to new, unseen patterns, and another in analogy completion where relevant word pairs appear only in fixed training positions. These findings suggest that LLMs' ICL abilities depend heavily on the structural elements within their training data.

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

↑