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

高效Transformer真的节省计算吗?

Do Efficient Transformers Really Save Computation?

School of EECS, Peking University(北京大学信息与工程科学学院(电子工程与计算机科学学院));ETH Zürich(苏黎世联邦理工学院);National Key Laboratory of General Artificial Intelligence, School of Intelligence Science and Technology, Peking University(北京大学通用人工智能重点实验室、智能科学与技术学院);New York University(纽约大学);Beijing Academy of Artificial Intelligence(北京智源人工智能研究院);Center for Machine Learning Research, Peking University(北京大学机器学习研究中心)

Kai Yang, Jan Ackermann, Zhenyu He, Guhao Feng, Bohang Zhang, Yunzhen Feng, Qiwei Ye, Di He, Liwei Wang

AI总结:

本文通过将高效Transformer(Sparse和Linear)建模为动态规划问题,研究其推理能力,发现其虽能解决一般DP任务但模型规模需随问题规模扩展,并识别了一类可更高效的问题,实验验证了理论结果。

摘要:

随着基于Transformer的语言模型在越来越大的数据集和大量参数上进行训练,寻找标准Transformer的更高效替代方案变得非常有价值。尽管已经提出了许多高效的Transformer和Transformer替代方案,但没有任何一种提供理论保证,证明它们适合作为标准Transformer的替代品。这使得确定何时使用特定模型以及优先探索哪些方向变得具有挑战性。在本文中,我们旨在理解高效Transformer(特别是Sparse Transformer和Linear Transformer)的能力和局限性。我们关注它们通过思维链(CoT)提示所展现的推理能力,并遵循先前的工作将其建模为动态规划(DP)问题。我们的结果表明,尽管这些模型具有足够的表达能力来解决一般的DP任务,但与预期相反,它们需要的模型规模会随问题规模而扩展。尽管如此,我们识别了一类DP问题,在这些问题上,这些模型可以比标准Transformer更高效。我们通过在代表性DP任务上的实验证实了我们的理论结果,增进了对高效Transformer实际优缺点的理解。

英文摘要:

As transformer-based language models are trained on increasingly large datasets and with vast numbers of parameters, finding more efficient alternatives to the standard Transformer has become very valuable. While many efficient Transformers and Transformer alternatives have been proposed, none provide theoretical guarantees that they are a suitable replacement for the standard Transformer. This makes it challenging to identify when to use a specific model and what directions to prioritize for further investigation. In this paper, we aim to understand the capabilities and limitations of efficient Transformers, specifically the Sparse Transformer and the Linear Transformer. We focus on their reasoning capability as exhibited by Chain-of-Thought (CoT) prompts and follow previous works to model them as Dynamic Programming (DP) problems. Our results show that while these models are expressive enough to solve general DP tasks, contrary to expectations, they require a model size that scales with the problem size. Nonetheless, we identify a class of DP problems for which these models can be more efficient than the standard Transformer. We confirm our theoretical results through experiments on representative DP tasks, adding to the understanding of efficient Transformers' practical strengths and weaknesses.

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

↑