arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2210.00400cs.LGcs.AI
收藏

Transformers在结构化任务训练中的系统概括和涌现结构

Systematic Generalization and Emergent Structures in Transformers Trained on Structured Tasks

Stanford University(斯坦福大学)

Yuxuan Li, James L. McClelland

摘要:

Transformer网络在自然语言处理和机器视觉方面取得了巨大成功,其中下一个单词预测和图像分类等任务目标受益于高维输入的细微上下文敏感性。然而,有一个正在进行的辩论如何以及何时Transformers可以获得高度结构化的行为,并实现系统的推广。在这里,我们探讨如何以及因果Transformer可以执行一组算法任务,包括复制,排序,和这些操作的分层组合。我们展示了强大的泛化序列比那些在训练中使用的替换标准的位置编码通常用于Transformers器与标签任意配对的序列中的项目。我们寻找足以解决这些任务的层次和头部配置,然后探索潜在表征和注意模式中系统处理的迹象。我们表明,两层Transformers学习可靠的解决方案,多层次的问题,开发任务分解的迹象,并编码输入项的方式,鼓励利用共享计算相关的任务。这些结果提供了关于注意力层如何在任务内和跨多个任务支持结构化计算的关键见解。

英文摘要:

Transformer networks have seen great success in natural language processing and machine vision, where task objectives such as next word prediction and image classification benefit from nuanced context sensitivity across high-dimensional inputs. However, there is an ongoing debate about how and when transformers can acquire highly structured behavior and achieve systematic generalization. Here, we explore how well a causal transformer can perform a set of algorithmic tasks, including copying, sorting, and hierarchical compositions of these operations. We demonstrate strong generalization to sequences longer than those used in training by replacing the standard positional encoding typically used in transformers with labels arbitrarily paired with items in the sequence. We search for the layer and head configuration sufficient to solve these tasks, then probe for signs of systematic processing in latent representations and attention patterns. We show that two-layer transformers learn reliable solutions to multi-level problems, develop signs of task decomposition, and encode input items in a way that encourages the exploitation of shared computation across related tasks. These results provide key insights into how attention layers support structured computation both within a task and across multiple tasks.

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

↑