arXiv:2412.05117cs.LG2024-12被引 12

让Transformer通过多步预测提升迷宫导航能力

Transformers Can Navigate Mazes With Multi-Step Prediction

  • 设计新目标MLM-U,显式预测多步前后路径
  • 相比传统方法,导航成功率显著提升,训练效率提高4倍
  • 大模型更受益,性能超越带强化学习监督的更大模型

尽管Transformer在语言建模中表现卓越,但其基于单步下一个词预测的训练目标在需要长期规划的任务中表现不佳,如迷宫导航。本文提出MLM-U目标,显式要求模型预测多个步骤前进和后退的路径。在相同设置下,使用MLM-U训练的Transformer在不同类型和复杂度的迷宫中均显著优于标准下一个词预测方法。MLM-U训练样本效率提高4倍,训练耗时减少2倍。对于复杂迷宫,模型规模扩大时,MLM-U的优势进一步增强;令人惊讶的是,仅用MLM-U训练的小模型性能超过使用额外A*搜索轨迹监督的大模型。结果表明,学习目标的设计对提升Transformer长程规划能力至关重要。

原文摘要 · Abstract (English)

Despite their remarkable success in language modeling, transformers trained to predict the next token in a sequence struggle with long-term planning. This limitation is particularly evident in tasks requiring foresight to plan multiple steps ahead such as maze navigation. The standard next single token prediction objective, however, offers no explicit mechanism to predict multiple steps ahead - or revisit the path taken so far. Consequently, in this work we study whether explicitly predicting multiple steps ahead (and backwards) can improve transformers' maze navigation. We train parameter-matched transformers from scratch, under identical settings, to navigate mazes of varying types and sizes with standard next token prediction and MLM-U, an objective explicitly predicting multiple steps ahead and backwards. We find that MLM-U considerably improves transformers' ability to navigate mazes compared to standard next token prediction across maze types and complexities. We also find MLM-U training is 4x more sample efficient and converges 2x faster in terms of GPU training hours relative to next token training. Finally, for more complex mazes we find MLM-U benefits from scaling to larger transformers. Remarkably, we find transformers trained with MLM-U outperform larger transformers trained with next token prediction using additional supervision from A* search traces. We hope these findings underscore the promise of learning objectives to advance transformers' capacity for long-term planning. The code can be found at https://github.com/facebookresearch/maze_navigation_MLMU

Transformer迷宫导航多步预测学习目标

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。