arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2404.06508cs.CLcs.LG
收藏

论(近似)重复子词在语言建模中的影响

On the Effect of (Near) Duplicate Subwords in Language Modelling

ETH Zürich(苏黎世联邦理工学院);ETH AI Center(ETH人工智能中心)

Anton Schäfer, Thomas Hofmann, Imanol Schlag, Tiago Pimentel

AI总结:

本文研究(近似)重复子词对语言模型训练效率的影响,通过复制词汇表实验发现完全重复时需多17%数据,而自然出现的近似重复子词合并后性能显著下降,表明其相似性有限,提升潜力受限。

摘要:

分词是语言模型(LMs)的核心部分。它涉及将字符序列拆分为子词,这些子词在输入语言模型之前被赋予任意索引。虽然这一过程通常是无损的,但它可能导致语言模型训练的样本效率降低:由于它移除了字符级信息,可能使语言模型更难在相似子词(如now和Now)之间进行泛化。我们将此类子词称为近似重复子词。在本文中,我们研究了近似重复子词对语言模型训练效率的影响。首先,我们设计了一个实验,该实验给出了如果我们能在近似重复子词之间完美泛化,模型预期能提升多少的上界。我们通过复制语言模型词汇表中的每个子词来实现这一点,从而创建完全等价的子词类别。实验发现,在完全重复的设置下训练时,语言模型大约需要多17%的数据。其次,我们研究了自然出现的近似重复子词对语言模型的影响。在这里,我们看到合并它们会显著损害语言模型的性能。因此,尽管子词重复对语言模型训练效率有负面影响,但自然出现的近似重复子词可能并不像预期的那样相似,这限制了性能提升的潜力。

英文摘要:

Tokenisation is a core part of language models (LMs). It involves splitting a character sequence into subwords which are assigned arbitrary indices before being served to the LM. While typically lossless, however, this process may lead to less sample efficient LM training: as it removes character-level information, it could make it harder for LMs to generalise across similar subwords, such as now and Now. We refer to such subwords as near duplicates. In this paper, we study the impact of near duplicate subwords on LM training efficiency. First, we design an experiment that gives us an upper bound to how much we should expect a model to improve if we could perfectly generalise across near duplicates. We do this by duplicating each subword in our LM's vocabulary, creating perfectly equivalent classes of subwords. Experimentally, we find that LMs need roughly 17% more data when trained in a fully duplicated setting. Second, we investigate the impact of naturally occurring near duplicates on LMs. Here, we see that merging them considerably hurts LM performance. Therefore, although subword duplication negatively impacts LM training efficiency, naturally occurring near duplicates may not be as similar as anticipated, limiting the potential for performance improvements.

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

↑