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

用于增强预训练语言模型微调中词表自适应的Adaptive BPE Tokenization

Adaptive BPE Tokenization for Enhanced Vocabulary Adaptation in Finetuning Pretrained Language Models

Indian Institute of Technology Kharagpur(印度理工学院卡拉格浦分校)

Gunjan Balde, Soumyadeep Roy, Mainack Mondal, Niloy Ganguly

AI总结:

针对BPE词表自适应在PLM微调中因简单追加词表导致次优tokenization的问题,提出AdaptBPE方法,通过在初始化阶段优先对目标词表进行最长字符串匹配,显著提升了分类与摘要任务的性能。

摘要:

在本研究中,我们展示了在使用Byte-Pair Encoding (BPE) tokenization方案对预训练语言模型(PLMs)进行专家领域微调的词表自适应方法中存在的一个基本局限性。当前的方法简单地将目标领域特定词表附加在PLM词表的末尾。这种方法会导致较低的优先级分数,并在BPE中引发次优的tokenization,因为BPE会迭代地使用合并规则来对给定文本进行tokenize。为了缓解这一问题,我们提出了AdaptBPE,它修改了BPE tokenization的初始化阶段,在字符级别tokenize之前,首先对添加的(目标)词表执行最长字符串匹配。我们在各种分类和摘要任务上对AdaptBPE与标准BPE进行了广泛的评估;AdaptBPE分别在准确率上提升了3.57%,在Rouge-L上提升了1.87%。当参考摘要具有高OOV浓度或长度较长时,用于MEDVOC的AdaptBPE效果尤为显著。我们还进行了人工评估,结果显示与MEDVOC相比,AdaptBPE生成了更相关且更忠实的摘要。我们在 https://github.com/gb-kgp/adaptbpe 公开了我们的代码库。

英文摘要:

In this work, we show a fundamental limitation in vocabulary adaptation approaches that use Byte-Pair Encoding (BPE) tokenization scheme for fine-tuning pretrained language models (PLMs) to expert domains. Current approaches trivially append the target domain-specific vocabulary at the end of the PLM vocabulary. This approach leads to a lower priority score and causes sub-optimal tokenization in BPE that iteratively uses merge rules to tokenize a given text. To mitigate this issue, we propose AdaptBPE where the BPE tokenization initialization phase is modified to first perform the longest string matching on the added (target) vocabulary before tokenizing at the character level. We perform an extensive evaluation of AdaptBPE versus the standard BPE over various classification and summarization tasks; AdaptBPE improves by 3.57% (in terms of accuracy) and 1.87% (in terms of Rouge-L), respectively. AdaptBPE for MEDVOC works particularly well when reference summaries have high OOV concentration or are longer in length. We also conduct a human evaluation, revealing that AdaptBPE generates more relevant and more faithful summaries as compared to MEDVOC. We make our codebase publicly available at https://github.com/gb-kgp/adaptbpe.

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

↑