arXiv:2510.27009cs.AIcs.LG2025-10

用因果掩码训练棋盘数据,效果优于传统走法序列

Causal Masking on Spatial Data: An Information-Theoretic Case for Learning Spatial Datasets with Unimodal Language Models

  • 在棋盘状态上使用因果掩码,直接建模空间结构
  • 空间模型胜率显著高于序列模型,最高提升120 Elo
  • 适合处理具有空间关系的单模态语言模型任务

语言模型通常采用因果掩码设计。在具有空间或关系结构的领域中,因果掩码常被认为不适用,而倾向于使用序列线性化。然而,是否可在非序列数据上接受因果掩码带来的信息损失,尚未得到充分研究,部分原因在于很少有领域同时具备空间和序列表示。本文以国际象棋为例,其天然支持两种表示形式。我们在空间(棋盘)和序列(走法)数据上,分别用双向和因果自注意力机制训练语言模型。结果表明,即使使用因果掩码,基于棋盘状态训练的模型在对弈强度上始终优于基于序列数据的模型。虽然实验在国际象棋上进行,但方法具有普适意义:将因果掩码应用于空间数据,是训练单模态大语言模型处理空间数据的一种可行甚至更优的方法。

原文摘要 · Abstract (English)

Language models are traditionally designed around causal masking. In domains with spatial or relational structure, causal masking is often viewed as inappropriate, and sequential linearizations are instead used. Yet the question of whether it is viable to accept the information loss introduced by causal masking on nonsequential data has received little direct study, in part because few domains offer both spatial and sequential representations of the same dataset. In this work, we investigate this issue in the domain of chess, which naturally supports both representations. We train language models with bidirectional and causal self-attention mechanisms on both spatial (board-based) and sequential (move-based) data. Our results show that models trained on spatial board states - \textit{even with causal masking} - consistently achieve stronger playing strength than models trained on sequential data. While our experiments are conducted on chess, our results are methodological and may have broader implications: applying causal masking to spatial data is a viable procedure for training unimodal LLMs on spatial data, and in some domains is even preferable to sequentialization.

因果掩码空间数据语言模型棋类AI

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