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

Repeat After Me:Transformers在复制方面优于状态空间模型

Repeat After Me: Transformers are Better than State Space Models at Copying

Harvard University(哈佛大学);Kempner Institute for the Study of Natural and Artificial Intelligence(坎普纳自然与人工智能研究所);Departments of Computer Science and Statistics(计算机科学与统计学系)

Samy Jelassi, David Brandfonbrener, Sham M. Kakade, Eran Malach

AI总结:

本文指出,在需要从上下文复制和检索信息的任务上,Transformers因不受固定大小潜在状态限制,在理论分析、合成任务及预训练模型评估中均显著优于广义状态空间模型(GSSMs)。

摘要:

Transformers是序列建模的主导架构,但人们对使用不依赖序列长度的固定大小潜在状态的模型越来越感兴趣,我们将其称为“广义状态空间模型”(GSSMs)。在本文中,我们表明,尽管GSSMs在推理时效率方面具有潜力,但在需要从输入上下文中进行复制的任务上,它们与transformer模型相比存在局限。我们从对字符串复制这一简单任务的理论分析开始,证明两层transformer可以复制指数长度的字符串,而GSSMs从根本上受限于其固定大小的潜在状态。在实验中,我们发现在需要复制上下文的合成任务上,transformers在效率和泛化能力方面优于GSSMs。最后,我们评估了预训练的大型语言模型,发现transformer模型在从上下文中复制和检索信息方面显著优于状态空间模型。综上所述,这些结果表明transformers和GSSMs在具有实际意义的任务上存在根本性差距。

英文摘要:

Transformers are the dominant architecture for sequence modeling, but there is growing interest in models that use a fixed-size latent state that does not depend on the sequence length, which we refer to as "generalized state space models" (GSSMs). In this paper we show that while GSSMs are promising in terms of inference-time efficiency, they are limited compared to transformer models on tasks that require copying from the input context. We start with a theoretical analysis of the simple task of string copying and prove that a two layer transformer can copy strings of exponential length while GSSMs are fundamentally limited by their fixed-size latent state. Empirically, we find that transformers outperform GSSMs in terms of efficiency and generalization on synthetic tasks that require copying the context. Finally, we evaluate pretrained large language models and find that transformer models dramatically outperform state space models at copying and retrieving information from context. Taken together, these results suggest a fundamental gap between transformers and GSSMs on tasks of practical interest.

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

↑