arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2605.22223cs.LG
收藏

变换器能生成多少种不同的输出?

How Many Different Outputs Can a Transformer Generate?

Department of Mathematics, National University of Singapore, Singapore, 117543(新加坡国立大学数学系);School of Computing, National University of Singapore, Singapore, 117543(新加坡国立大学计算学院);Aix Marseille Univ, CNRS, I2M, Marseille, France(法国马赛大学、国家科学研究中心、I2M研究所);Department of Electrical and Computer Engineering, National University of Singapore(新加坡国立大学电子与计算机工程系)

Maxime Meyer, Mario Michelessa, Caroline Chaux, Vincent Y. F. Tan

AI总结:

研究如何利用变换器架构中的少量特性来准确预测其能生成的不同序列数量,包括定性和定量分析,并提供基于提示长度的上限,实验证明在不同架构和模型大小下该上限紧致于10倍以内。分析还解释了之前在简单序列任务(如复制和填塞)中观察到的变换器经验性失败现象。

摘要:

我们研究如何仅利用变换器架构中的少量特性来紧密预测其能生成的不同序列数量,包括定性和定量分析。我们提供一个依赖于提示长度的上限,实验证明在不同架构和模型大小下,该上限紧致于10倍以内。我们的分析还为之前在简单序列任务(如复制和填塞)中观察到的变换器经验性失败提供了理论解释。形式上,我们证明了(i)可访问序列的最大长度(即变换器能为某些提示生成的序列)与提示长度成线性增长,(ii)超过临界阈值后,可访问序列的比例随序列长度呈指数衰减,(iii)提示长度与可访问序列长度之间的线性系数具有理论上限。值得注意的是,这些结果即使在无界上下文和计算时间下也成立。

英文摘要:

We study how we can leverage only a handful of characteristics of a transformer's architecture to closely predict the number of different sequences it can output, both qualitatively and quantitatively. We provide an upper bound depending on the length of the prompt, which we show empirically to be tight up to a factor less than 10, across architectures and model sizes. Our analysis also provides a theoretical explanation for previously observed empirical failures of transformers on simple sequence tasks, such as copying and cramming. Formally, we prove that (i) the maximal length of accessible sequences (those that the transformer can output for some prompt) grows linearly with the prompt length, (ii) beyond a critical threshold, the proportion of accessible sequences decays exponentially with sequence length, and (iii) the linear coefficient relating prompt length to accessible sequence length admits a theoretical upper bound. Notably, these results hold even with unbounded context and computation time.

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

↑