arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2410.04368cs.LGcs.AIcs.CL
收藏

随机Transformer的算法能力

Algorithmic Capabilities of Random Transformers

Massachusetts Institute of Technology(麻省理工学院)

Ziqian Zhong, Jacob Andreas

AI总结:

该研究通过仅优化嵌入层的随机初始化Transformer实验,发现随机Transformer已具备模运算、联想回忆等多种算法能力,揭示Transformer的部分算法能力在训练前就已存在。

摘要:

已有研究发现,经过训练的transformer模型会针对算术、联想回忆等任务实现可解释的程序,但人们对这些实现程序的电路在训练过程中的起源知之甚少。它们在多大程度上依赖于提供给模型的监督信号,又在多大程度上可归因于训练初始阶段模型已有的行为?为探究这些问题,我们研究了仅优化嵌入层的随机初始化transformer可学习的函数,这类模型从数据中可学习的输入-输出映射,仅限于随机初始化模型已实现的映射(仅需选择编码方案)。我们发现这些随机transformer可执行广泛的有意义算法任务,包括模运算、权重内与上下文内联想回忆、十进制加法、括号平衡,甚至自然语言文本生成的某些方面。我们的结果表明,部分算法能力甚至在模型接受训练前就已存在于transformer中(且可通过结构适配的输入访问)。代码可在https://github.com/fjzzq2002/random_transformers获取。

英文摘要:

Trained transformer models have been found to implement interpretable procedures for tasks like arithmetic and associative recall, but little is understood about how the circuits that implement these procedures originate during training. To what extent do they depend on the supervisory signal provided to models, and to what extent are they attributable to behavior already present in models at the beginning of training? To investigate these questions, we investigate what functions can be learned by randomly initialized transformers in which only the embedding layers are optimized, so that the only input--output mappings learnable from data are those already implemented (up to a choice of encoding scheme) by the randomly initialized model. We find that these random transformers can perform a wide range of meaningful algorithmic tasks, including modular arithmetic, in-weights and in-context associative recall, decimal addition, parenthesis balancing, and even some aspects of natural language text generation. Our results indicate that some algorithmic capabilities are present in transformers (and accessible via appropriately structured inputs) even before these models are trained. Code is available at https://github.com/fjzzq2002/random_transformers.

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

↑