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

通用转换器需要记忆:自适应递归推理中的深度-状态权衡

Universal Transformers Need Memory: Depth-State Trade-offs in Adaptive Recursive Reasoning

Intento

Grigory Sapunov

AI总结:

研究发现通用转换器在解决数独难题时需依赖记忆token,通过实验确定内存token数量的阈值及影响因素,揭示ACT初始化陷阱及递归深度中注意力头的功能分化。

摘要:

我们研究了学习记忆token作为单块通用转换器(UT)的计算草稿纸,在数独-极端基准上进行自适应计算时间(ACT)的测试。我们发现记忆token在经验上是必要的:在所有测试配置中,没有记忆token的配置都无法达到非平凡性能。最优数量表现出一个陡峭的下限阈值(T=0总是失败,T=4处于临界点,T=8可靠地在81单元谜题中成功)后,接着是稳定的平台期(T=8-32,精确匹配率为57.4%±0.7%)然后在T=64时因注意力稀释而崩溃。在实验过程中,我们识别出一个路由初始化陷阱,导致超过70%的训练运行失败:默认的零偏置初始化(p~0.5)和Graves推荐的正偏置初始化(p~0.73)导致token在初始化后约2步停止,进入浅层平衡(停止~5-7),模型无法逃脱。将偏置翻转到-3(“深启动”,p~0.05)消除了这种失败模式。通过消融实验确认,该陷阱固有于ACT初始化,而非我们的架构选择的产物。在可靠的训练建立后,我们展示了(1)ACT比固定深度处理更一致(56.9%±0.7% vs 53.4%±9.3%跨3种子);(2)ACT与lambda warmup实现匹配的准确率(57.0%±1.1%)使用34%更少的思考步骤;(3)注意力头在递归深度中专业化为记忆读者、约束传播者和整合器。代码可在https://github.com/che-shr-cat/utm-jax获取。

英文摘要:

We study learned memory tokens as computational scratchpad for a single-block Universal Transformer (UT) with Adaptive Computation Time (ACT) on Sudoku-Extreme, a combinatorial reasoning benchmark. We find that memory tokens are empirically necessary: across all configurations tested -- 3 seeds, multiple token counts, two initialization schemes, ACT and fixed-depth processing -- no configuration without memory tokens achieves non-trivial performance. The optimal count exhibits a sharp lower threshold (T=0 always fails, T=4 is borderline, T=8 reliably succeeds for 81-cell puzzles) followed by a stable plateau (T=8-32, 57.4% +/- 0.7% exact-match) and collapse from attention dilution at T=64. During experimentation, we identify a router initialization trap that causes >70% of training runs to fail: both default zero-bias initialization (p ~ 0.5) and Graves' recommended positive bias (p ~ 0.73) cause tokens to halt after ~2 steps at initialization, settling into a shallow equilibrium (halt ~ 5-7) that the model cannot escape. Inverting the bias to -3 ("deep start," p ~ 0.05) eliminates this failure mode. We confirm through ablation that the trap is inherent to ACT initialization, not an artifact of our architecture choices. With reliable training established, we show that (1) ACT provides more consistent results than fixed-depth processing (56.9% +/- 0.7% vs 53.4% +/- 9.3% across 3 seeds); (2) ACT with lambda warmup achieves matching accuracy (57.0% +/- 1.1%) using 34% fewer ponder steps; and (3) attention heads specialize into memory readers, constraint propagators, and integrators across recursive depth. Code is available at https://github.com/che-shr-cat/utm-jax.

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

↑