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

ALPINE:揭示语言模型中自回归学习的规划能力

ALPINE: Unveiling the Planning Capability of Autoregressive Learning in Language Models

Microsoft Research Asia(微软亚洲研究院);Harvard University(哈佛大学);Peking University(北京大学);University of Southern California(南加州大学)

Siwei Wang, Yifei Shen, Shi Feng, Haoran Sun, Shang-Hua Teng, Wei Chen

AI总结:

本文通过理论分析和实验揭示,基于Transformer的LLMs通过下一词预测可学习邻接与有限可达性矩阵以执行路径查找,但受限于无法通过传递性识别可达关系,为自回归学习的规划能力提供了新见解。

摘要:

规划是人类智能和当代大型语言模型(LLMs)的关键要素。在本文中,我们开创性地对基于Transformer的LLMs通过其下一词预测机制涌现出规划能力进行了理论探究。我们将规划建模为网络路径查找任务,其目标是生成从指定源节点到指定目标节点的有效路径。我们的数学刻画表明,Transformer架构可以通过将邻接矩阵和可达性矩阵嵌入其权重中来执行路径查找。此外,我们对基于梯度的学习动力学的理论分析揭示,LLMs能够学习邻接矩阵以及一种有限形式的可达性矩阵。这些理论见解随后通过实验得到验证,实验表明Transformer架构确实学习了邻接矩阵和不完整的可达性矩阵,这与我们的理论预测一致。当我们将我们的方法应用于现实世界的规划基准Blocksworld时,我们的观察结果保持一致。此外,我们的分析揭示了当前Transformer架构在路径查找中的一个基本局限性:这些架构无法通过传递性识别可达性关系,这导致在需要拼接时生成路径失败。这些发现为自回归学习的内部机制如何促进智能规划提供了新见解,并加深了我们对未来LLMs如何在多样化应用中实现更高级和更通用的规划与推理能力的理解。

英文摘要:

Planning is a crucial element of both human intelligence and contemporary large language models (LLMs). In this paper, we initiate a theoretical investigation into the emergence of planning capabilities in Transformer-based LLMs via their next-word prediction mechanisms. We model planning as a network path-finding task, where the objective is to generate a valid path from a specified source node to a designated target node. Our mathematical characterization shows that Transformer architectures can execute path-finding by embedding the adjacency and reachability matrices within their weights. Furthermore, our theoretical analysis of gradient-based learning dynamics reveals that LLMs can learn both the adjacency and a limited form of the reachability matrices. These theoretical insights are then validated through experiments, which demonstrate that Transformer architectures indeed learn the adjacency and an incomplete reachability matrices, consistent with our theoretical predictions. When applying our methodology to the real-world planning benchmark Blocksworld, our observations remain consistent. Additionally, our analyses uncover a fundamental limitation of current Transformer architectures in path-finding: these architectures cannot identify reachability relationships through transitivity, which leads to failures in generating paths when concatenation is required. These findings provide new insights into how the internal mechanisms of autoregressive learning facilitate intelligent planning and deepen our understanding of how future LLMs might achieve more advanced and general planning-and-reasoning capabilities across diverse applications.

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

↑