RAIR: Retrieval-Augmented Iterative Refinement for Chinese Spelling Correction
Junhong Liang, Yu Zhou · 2025
Read RAIR: Retrieval-Augmented Iterative Refinement for Chinese Spelling Correction by Junhong Liang, Yu Zhou (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2504-18938.txt.
Introduction
Junhong Liang and Yu Zhou present a computing paper from 2025 on fixing spelling in Chinese text. Chinese spelling tools must spot wrong characters and swap in the right ones. Big language models do this well in general text but stumble on terms from special fields like medicine or law.
Their method builds a search bank from field texts and word lists. A tuned retriever pulls past fix patterns that match the new error. The model then refines its fix in rounds, guided by what it retrieved. The team also let fixes change the length of the text, past the usual same-length rule. Tests showed the method beat current tools in special fields. It also lifted model scores when fixes could grow or shrink the text.
Catalog record
| CREATOR | Junhong Liang, Yu Zhou |
|---|---|
| YEAR | 2025 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 41 KB |
| VERSION | 1.0 |
| LICENSE | http://creativecommons.org/licenses/by/4.0/ |
| RIGHTS | CC BY |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2504-18938
Browse the full library · About the Tower of Babel
Full text
The opening of the work, from the library's hosted text:
RAIR: Retrieval-Augmented Iterative Refinement for Chinese Spelling Correction Junhong Liang, Yu Zhou Abstract Chinese Spelling Correction (CSC) aims to detect and correct erroneous tokens in sentences. Traditional CSC focuses on equal length correction and uses pretrained language models (PLMs). While Large Language Models (LLMs) have shown remarkable success in identifying and rectifying potential errors, they often struggle with adapting to domain-specific corrections, especially when encountering terminologies in specialized domains. To address domain adaptation, we propose a R etrieval- A ugmented I terative R efinement (RAIR) framework. Our approach constructs a retrieval corpus adaptively from domain-specific training data and dictionaries, employing a fine-tuned retriever to ensure that the retriever catches the error correction pattern. We also extend equal-length into variable-length correction scenarios. Extensive experiments demonstrate that our framework outperforms current approaches in domain spelling correction and significantly improves the performance of LLMs in variable-length scenarios. 1 Introduction Chinese Spelling Correction (CSC) is a long-established task aimed at correcting misspelled characters in a sentence. Traditional CSC tasks focus on correcting general texts, such as errors in daily writing ( Xu et al., 2021 ; Hu et al., 2022 ) , Optical Character Recognition (OCR) ( Zhang et al., 2015 ) , or texts produced by Chinese learners ( Tseng et al., 2015 ) . However, Chinese spelling errors also appear in domain-specific scenarios ( Song et al., 2023 ; Wu et al., 2023 ) . Addressing domain-specific spelling errors is crucial because the precision and accuracy of domain documents are essential for communication and avoiding misunderstanding. Traditional CSC methods are based on pre-trained language models (PLMs) such as BERT structure Zhang et al. (2020) ; Xu et al. (2021) to capture the inherent semantic information of each token, while the complex structure and meticulous design of knowledge fusion of PLMs inherently narrow the scope in addressing domain-specific spelling errors, resulting in less effective results. Figure 1: Examples of Chinese error correction in different scenarios: a) Domain Spelling Correction, where an LLM must rectify semantically incorrect spelling from domain data while preserving sentence length. b) ASR N-best Correction, in which the LLM combines multiple speech recognition hypotheses and outputs the correct sentence from the speaker, and c) Splitting Correction, requiring the LLM to restore erroneously split characters into a single character. The wrong characters and their corrections are marked in red / blue respectively (best viewed in color). LLMs demonstrated excellent performance in several NLP tasks, and using LLMs for CSC has become a research trend. Most research introduces LLM as a generator to correct the equal-length spelling errors, such as by redefining tokenization rules Li et al. (2024) or providing character information using in-context learning Dong et al. (2024b) . However, challenges still exist for LLM methods. Firstly, it is essential to employ domain-specific knowledge to deal with spelling errors in specific domains, whereas existing approaches often overlook domain-specific insights. Secondly, it is vital to maintain the equal-length requirement in domain spelling correction, while the auto-regressive generation pattern of LLMs may fail to comply with strict length constraints in CSC tasks. Lastly, variable-length correction scenarios, such as ASR correction and character splitting, also exist in daily life and are insufficiently investigated by current spelling correction methods. The investigated error types are shown in Figure 1 . These observations lead to a fundamental question overlooked by previous studies: Can we utilize the generation abilities in LLMs to solve equal-length domain spelling errors while addressing variable length scenarios? To address the issues mentioned above, we propose the RAIR ( R etrieval A ugmented I terative R efinement) framework based on retrieval-augmented generation (RAG). This framework not only handles domain spelling errors but also ASR N-best Errors and Splitting Errors. We first dynamically construct a retrieval corpus from various sources, then fine-tune the semantic search retriever to catch the error correction pattern, and incorporate Multi-turn Length Reflection (MLR) to guide the output format for equal and variable length scenarios, finally using adaptive selection to combine correction prediction from direct and retrieval augmented correction. Our contributions are summarized as follows: • We present a novel plug-and-play CSC framework using RAG for domain spelling errors, which integrates retrieved correct sentences into the context of LLMs, along with length reflection employing iterative reasoning steps to ensure the correct output length. • We extend the current equal-length domain spelling correction into variable-length correction scenarios. We propose a domain-adaptive retrieval dataset construction method that synthesizes multi-source data, allowing adaptive data construction for different domains and error types. • Extensive experiments demonstrate our framework outperforms current approaches in domain spelling correction and significantly improve the performance of LLMs in variable-length scenarios. 2 Related Work 2.1 Chinese Error Correction Datasets Traditional CSC datasets such as SIGHAN13/14/15 focus on the errors made by Chinese learners Wu et al. (2013) ; Yu et al. (2014) ; Chang et al. (2015) ; however, these data are unable to reflect the errors that exist in native speakers. Therefore, Hu et al. (2022) proposes CSCD-NS, which collects the spelling errors in social media. In order to explore domain error correction abilities, Lv et al. (2023) creates ECSpell datasets, creating domain-specific errors in three domains, and Wu et al. (2023) proposes the LEMON dataset, including real spelling errors in seven domains. To investigate further variable-length correction, several datasets such as CSEC Liang et al. (2024) and ChineseHP Tang et al. (2024) are proposed to address the splitting and ASR decoding errors. 2.2 Chinese Spelling Correction Methods Traditional CSC approaches primarily employ transformer-based PLMs, which can be categorized into two main frameworks. The Information-Learning architecture integrates phonetic and visual glyph features for direct error correction ( Hong et al., 2019 ; Sun et al., 2021 ; Xu et al., 2021 ) . The Detection-Correction architecture adopts a two-stage process, first identifying errors, then correcting them ( Zhang et al., 2020 ; Zhu et al., 2022 ; Wu et al., 2023 ) . Recent advancements have merged these approaches, such as combining Chinese splitting features with soft-masked prediction ( Liang et al., 2024 ) , and improving BERT through phonetic-aware pretraining ( Feng and Cao, 2025 ) . The advent of LLMs has significantly advanced Chinese spelling correction research. Recent work has systematically evaluated LLMs’ error correction capabilities Li et al. (2023) ; Liang (2024) , and there exist several innovative approaches. Prompt engineering techniques have efficiently integrated semantic information into the context of LLMs ( Dong et al., 2024b ) . Besides, pronunciation and glyph similarity techniques have proven valuable for output probability calibration ( Zhou et al., 2024 ) . while multimodal methods incorporating speech-text alignment enhance error localization Yuhang et al. (2024) . Model architecture innovations have also shown promise, particularly through character-level tokenization ( Li et al., 2024 ) and specialized error detection training ( Xu et al., 2024 ) . Figure 2: Structure diagram of RAIR, including several modules such as retrieval corpus, retriever, multi-round length reflection and adaptive selection (best viewed in color). Apart from this, notable advancement comes from RAG approaches. Current solutions demonstrate effectiveness through two key mechanisms: error-robust retrieval that utilizes training data as knowledge sources ( Yin et al., 2024 ) , and few-shot corpus retrieval ( Dong et al.,