Tokenization Constraints in LLMs: A Study of Symbolic and Arithmetic Reasoning Limits
本文研究了语言模型中分词对符号和算术推理能力的影响,发现分词结构对推理性能有显著影响,并提出了原子对齐格式以提升模型的表现。
更新于 2025-05-26。作者:Xiang Zhang、Juntai Cao、Jiaqi Wei、Yiwei Xu、Chenyu You。
中文摘要
分词是语言模型计算的第一层,同时也是常常被忽视的一层。虽然思维链(CoT)提示允许transformer模型通过外部化中间步骤来近似循环计算,但我们表明,这种推理的成功从根本上受到分词输入结构的限制。这项工作对分词方案,尤其是基于子词的方法,如字节对编码(BPE),如何通过合并或模糊原子推理单元来阻碍符号计算进行了理论和实证研究。我们引入了“分词意识”这一概念,以形式化说明较差的分词粒度如何破坏逻辑对齐并阻止模型从符号程序中泛化。通过在算术和符号任务上的系统评估,我们证明分词结构极大地影响了推理性能,甚至在CoT的情况下也会导致失败,而原子对齐的格式则解锁了强大的泛化能力,允许小型模型(例如GPT-4o-mini)在结构化推理上超越大型系统(例如o1)。我们的发现揭示,LLM中的符号推理能力并非纯粹取决于架构,而是深深地依赖于分词级别的表示。
英文摘要
Tokenization is the first - and often underappreciated - layer of computation in language models. While Chain-of-Thought (CoT) prompting enables transformer models to approximate recurrent computation by externalizing intermediate steps, we show that the success of such reasoning is fundamentally bounded by the structure of tokenized inputs. This work presents a theoretical and empirical investigation into how tokenization schemes, particularly subword-based methods like byte-pair encoding (BPE), impede symbolic computation by merging or obscuring atomic reasoning units. We introduce the notion of Token Awareness to formalize how poor token granularity disrupts logical alignment and prevents models from generalizing symbolic procedures. Through systematic evaluation on arithmetic and symbolic tasks, we demonstrate that token structure dramatically affect reasoning performance, causing failure even with CoT, while atomically-aligned formats unlock strong generalization, allowing small models (e.g., GPT-4o-mini) to outperform larger systems (e.g., o1) in structured reasoning. Our findings reveal that symbolic reasoning ability in LLMs is not purely architectural, but deeply conditioned on token-level representations.
解读
一句话总结
本文研究了语言模型中分词对符号和算术推理能力的影响,发现分词结构对推理性能有显著影响,并提出了原子对齐格式以提升模型的表现。
问题1:这篇论文想要解决什么具体问题?
- 问题背景:尽管链式思维(CoT)提示可以扩展语言模型的计算能力,但实际性能仍然远低于理论极限,尤其是在算术和符号推理任务中。
- 现有方案不足:现有研究主要关注模型架构和训练数据,而对分词这一基础组件的关注不足。
- 研究目标:探讨分词对语言模型符号和算术推理能力的影响,并提出改进方法。
问题2:论文的核心创新点是什么?
- 技术创新:引入了“Token Awareness”的概念,用于量化分词粒度对逻辑对齐和模型泛化能力的影响。
- 方法改进:通过实验验证了原子对齐格式可以提升模型在算术和符号任务上的表现。
- 优势:与现有方法相比,原子对齐格式可以显著提升模型在符号推理任务上的表现,即使是在小模型上也能超越大模型。
问题3:实验结果如何验证了方法的有效性?
- 关键实验:对算术和符号任务进行了系统性评估,包括计数、排序和反转。
- 性能提升:原子对齐格式在计数任务上的平均准确率提升了54.1%,在排序任务上的平均准确率提升了27.8%。
- 对比结果:与基线方法相比,原子对齐格式显著提升了模型在符号推理任务上的表现。
问题4:这个研究的实际应用价值是什么?
- 应用场景:该研究有助于改进语言模型在算术和符号推理任务上的表现,提高其在实际应用中的实用性。
- 实施建议:在设计和训练语言模型时,应考虑分词对模型性能的影响,并采用原子对齐格式。
- 局限与展望:该研究主要针对字符级别的任务,未来可以扩展到更复杂的任务和不同类型的语言模型。
来源
机器可读索引:llms.txt