arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2412.11867cs.LGcs.AI
收藏

Transformers 在迷宫求解任务中使用因果世界模型

Transformers Use Causal World Models in Maze-Solving Tasks

Imperial College London(伦敦帝国学院);Colorado School of Mines(科罗拉多矿业学院);University of Manchester(曼彻斯特大学);National Institute of Informatics(信息学研究所)

Alex F. Spies, William Edwards, Michael I. Ivanitskiy, Adrians Skapars, Tilman Räuker, Katsumi Inoue, Alessandra Russo, Murray Shanahan

AI总结:

本研究通过 Sparse Autoencoders 和注意力分析,识别并验证了 transformers 在迷宫求解任务中构建的因果世界模型,揭示了特征干预的难易差异、模型泛化能力及位置编码对模型结构的影响。

摘要:

可解释性领域的近期研究探索了在各种领域任务上训练的 transformer 模型的内部工作机制,常发现这些网络会自然形成高度结构化的表征。当此类表征全面反映任务领域的结构时,通常被称为“世界模型”。在本研究中,我们在受训于迷宫求解任务的 transformers 中识别出了 WMs。通过使用 Sparse Autoencoders (SAEs) 并分析注意力模式,我们检验了 WMs 的构建过程,并证明了基于 SAE 特征的分析与基于电路分析之间的一致性。通过随后对分离出的特征进行干预以确认其因果作用,我们发现激活特征比抑制它们更容易。此外,我们发现模型能够对包含比训练时遇到的更多同时活跃特征的迷宫进行推理;然而,当这些同样的迷宫(具有更多连接)改为通过输入 token 提供给模型时,模型却失败了。最后,我们证明位置编码方案似乎会影响世界模型在模型残差流中的结构化方式。

英文摘要:

Recent studies in interpretability have explored the inner workings of transformer models trained on tasks across various domains, often discovering that these networks naturally develop highly structured representations. When such representations comprehensively reflect the task domain's structure, they are commonly referred to as "World Models" (WMs). In this work, we identify WMs in transformers trained on maze-solving tasks. By using Sparse Autoencoders (SAEs) and analyzing attention patterns, we examine the construction of WMs and demonstrate consistency between SAE feature-based and circuit-based analyses. By subsequently intervening on isolated features to confirm their causal role, we find that it is easier to activate features than to suppress them. Furthermore, we find that models can reason about mazes involving more simultaneously active features than they encountered during training; however, when these same mazes (with greater numbers of connections) are provided to models via input tokens instead, the models fail. Finally, we demonstrate that positional encoding schemes appear to influence how World Models are structured within the model's residual stream.

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

↑