Abstract
We consider the following tokenization repair problem: Given a natural language text with any combination of missing or spurious spaces, correct these. Spelling errors can be present, but it’s not part of the problem to correct them. For example, given: “Tispa per isabout token izaionrep air”, compute “Tis paper is about tokenizaion repair”. We identify three key ingredients of high-quality tokenization repair, all missing from previous work: deep language models with a bidirectional component, training the models on text with spelling errors, and making use of the space information already present. Our methods also improve existing spell checkers by fixing not only more tokenization errors but also more spelling errors: once it is clear which characters form a word, it is much easier for them to figure out the correct word. We provide six benchmarks that cover three use cases (OCR errors, text extraction from PDF, human errors) and the cases of partially correct space information and all spaces missing. We evaluate our methods against the best existing methods and a non-trivial baseline. We provide full reproducibility under https://ad.informatik.uni-freiburg.de/publications.- Anthology ID:
- 2021.conll-1.22
- Volume:
- Proceedings of the 25th Conference on Computational Natural Language Learning
- Month:
- November
- Year:
- 2021
- Address:
- Online
- Editors:
- Arianna Bisazza, Omri Abend
- Venue:
- CoNLL
- SIG:
- SIGNLL
- Publisher:
- Association for Computational Linguistics
- Note:
- Pages:
- 279–289
- Language:
- URL:
- https://aclanthology.org/2021.conll-1.22
- DOI:
- 10.18653/v1/2021.conll-1.22
- Cite (ACL):
- Hannah Bast, Matthias Hertel, and Mostafa M. Mohamed. 2021. Tokenization Repair in the Presence of Spelling Errors. In Proceedings of the 25th Conference on Computational Natural Language Learning, pages 279–289, Online. Association for Computational Linguistics.
- Cite (Informal):
- Tokenization Repair in the Presence of Spelling Errors (Bast et al., CoNLL 2021)
- PDF:
- https://preview.aclanthology.org/nschneid-patch-4/2021.conll-1.22.pdf
- Code
- ad-freiburg/tokenization-repair + additional community code