arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2409.17391cs.CL
收藏

大型语言模型在数字系统方面的缩放行为:以Pythia为例

Scaling Behavior for Large Language Models regarding Numeral Systems: An Example using Pythia

University of Southern California(南加州大学);Shanghai AI Laboratory(上海人工智能实验室);The Chinese University of Hong Kong(香港中文大学)

Zhejian Zhou, Jiayu Wang, Dahua Lin, Kai Chen

AI总结:

本文以Pythia为例,研究了大型语言模型在不同数字系统下的缩放行为,发现基10系统在从头训练时数据效率更高,而不同数字系统在微调时性能相似,并揭示了模型在加法和乘法上的外推行为模式。

摘要:

尽管大型语言模型(LLMs)在数学推理方面展现出卓越能力,但在准确执行加法和乘法等数值运算时仍面临困难。数字可以通过不同的LLMs以多种方式被分词为token,从而影响数值运算的性能。目前有两种代表性方法:1)分词为$1$位数字;2)分词为$1\sim 3$位数字。这种差异大致等同于使用不同的数字系统(即基数为$10$或基数为$10^{3}$)。鉴于此,我们研究了在基于transformer的大型语言模型背景下不同数字系统的缩放行为。我们实证表明,在训练数据规模和从头开始训练设置下的模型大小方面,基$10$系统在数据效率上始终优于基$10^{2}$或基$10^{3}$系统,而不同数字系统在微调性能上非常相似。我们将此归因于基$10$系统具有更高的token频率。此外,我们揭示了在加法和乘法上的外推行为模式。我们发现基$100$和基$1000$系统在token级别辨识和token级别操作上存在困难。我们还阐明了模型所学习的机制。

英文摘要:

Though Large Language Models (LLMs) have shown remarkable abilities in mathematics reasoning, they are still struggling with performing numeric operations accurately, such as addition and multiplication. Numbers can be tokenized into tokens in various ways by different LLMs and affect the numeric operations performance. Currently, there are two representatives: 1) Tokenize into $1$-digit, and 2) Tokenize into $1\sim 3$ digit. The difference is roughly equivalent to using different numeral systems (namely base $10$ or base $10^{3}$). In light of this, we study the scaling behavior of different numeral systems in the context of transformer-based large language models. We empirically show that a base $10$ system is consistently more data-efficient than a base $10^{2}$ or $10^{3}$ system across training data scale, model sizes under from-scratch training settings, while different number systems have very similar fine-tuning performances. We attribute this to higher token frequencies of a base $10$ system. Additionally, we reveal extrapolation behavior patterns on addition and multiplication. We identify that base $100$ and base $1000$ systems struggle on token-level discernment and token-level operations. We also sheds light on the mechanism learnt by the models.

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

↑