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

乱序文本:使用合成数据训练语言模型以纠正OCR错误

Scrambled text: training Language Models to correct OCR errors using synthetic data

Jonathan Bourne

AI总结:

本文提出用语言模型结合字符级马尔可夫损坏过程生成合成数据来微调CLOCR-C模型,显著降低OCR纠错的字符和词错误率,并总结出8条训练启发式规则、发布数据集和Python库。

摘要:

OCR错误在数字化历史档案中十分常见,严重影响其可用性和价值。生成式语言模型(LMs)已展现出利用损坏文本提供的上下文以及更广泛的社会文化背景来纠正这些错误的潜力,这一过程被称为上下文利用OCR纠正(CLOCR-C)。然而,获取足够的训练数据以微调此类模型可能具有挑战性。本文表明,使用语言模型生成合成数据,并采用字符级马尔可夫损坏过程对语言模型进行微调,可以显著提高其纠正OCR错误的能力。在合成数据上训练的模型相比基础语言模型将字符错误率降低了55%,词错误率降低了32%,并且优于在真实数据上训练的模型。关键发现包括:在轻度损坏数据上训练优于在过度损坏数据上训练;非均匀字符级损坏优于均匀损坏;在固定token预算下,每个观测包含更多token优于更多观测数量。本文的产出包括一组用于训练有效CLOCR-C模型的8条启发式规则、一个包含11,000篇合成19世纪报纸文章的数据集,以及一个用于创建合成损坏数据的Python库scrambledtext。

英文摘要:

OCR errors are common in digitised historical archives significantly affecting their usability and value. Generative Language Models (LMs) have shown potential for correcting these errors using the context provided by the corrupted text and the broader socio-cultural context, a process called Context Leveraging OCR Correction (CLOCR-C). However, getting sufficient training data for fine-tuning such models can prove challenging. This paper shows that fine-tuning a language model on synthetic data using an LM and using a character level Markov corruption process can significantly improve the ability to correct OCR errors. Models trained on synthetic data reduce the character error rate by 55% and word error rate by 32% over the base LM and outperform models trained on real data. Key findings include; training on under-corrupted data is better than over-corrupted data; non-uniform character level corruption is better than uniform corruption; More tokens-per-observation outperforms more observations for a fixed token budget. The outputs for this paper are a set of 8 heuristics for training effective CLOCR-C models, a dataset of 11,000 synthetic 19th century newspaper articles and scrambledtext a python library for creating synthetic corrupted data.

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

↑