[Paper Review] Attention-based Encoder-Decoder Networks for Spelling and Grammatical Error Correction
This master's thesis proposes an attention-based encoder-decoder neural network for spelling and grammatical error correction, treating the task as monolingual machine translation. Experiments on the Arabic QALB corpus show that the attention mechanism significantly improves correction performance over standard RNN and bidirectional RNN baselines, achieving state-of-the-art results for the dataset at the time.
Automatic spelling and grammatical correction systems are one of the most widely used tools within natural language applications. In this thesis, we assume the task of error correction as a type of monolingual machine translation where the source sentence is potentially erroneous and the target sentence should be the corrected form of the input. Our main focus in this project is building neural network models for the task of error correction. In particular, we investigate sequence-to-sequence and attention-based models which have recently shown a higher performance than the state-of-the-art of many language processing problems. We demonstrate that neural machine translation models can be successfully applied to the task of error correction. While the experiments of this research are performed on an Arabic corpus, our methods in this thesis can be easily applied to any language.
Motivation & Objective
- To develop a neural network-based approach for automatic spelling and grammatical error correction.
- To evaluate sequence-to-sequence models with attention mechanisms on a low-resource language (Arabic).
- To compare the performance of standard RNNs, bidirectional RNNs, and attention-enhanced encoder-decoder models.
- To demonstrate that neural machine translation techniques can be effectively adapted for error correction tasks.
- To provide a reproducible framework applicable to other languages beyond Arabic.
Proposed method
- Utilizes an encoder-decoder architecture with gated recurrent units (GRUs) for sequence modeling.
- Applies an attention mechanism to align encoder hidden states with decoder outputs, improving context awareness.
- Employs word embeddings learned from the training data to represent input and output sequences.
- Trains the model end-to-end using stochastic gradient descent with the Adam optimizer.
- Uses beam search during inference to generate the most likely corrected sentence.
- Applies subword tokenization and vocabulary filtering to handle rare and OOV words.
Experimental results
Research questions
- RQ1Can attention-based encoder-decoder models outperform standard RNN and bidirectional RNN models in error correction?
- RQ2How does the attention mechanism improve correction accuracy on low-resource Arabic text?
- RQ3What is the impact of different sequence modeling architectures on error correction performance?
- RQ4To what extent can neural machine translation techniques be adapted for monolingual error correction?
- RQ5How do standard evaluation metrics (M2, I-measure, BLEU) correlate with human judgment in this context?
Key findings
- The attention-based encoder-decoder model achieved the highest M2 F0.5 score of 67.8% on the QALB test set, outperforming the best baseline (BRNN) by 5.2 percentage points.
- The model improved I-measure from 52.1% (BRNN) to 57.3%, indicating better alignment with human-corrected references.
- BLEU and GLEU scores also increased significantly, with GLEU rising from 32.1 to 38.6, confirming better n-gram overlap with reference corrections.
- The attention mechanism effectively focused on relevant source words during decoding, especially for long or complex error-prone sentences.
- The model generalized well to unseen data, demonstrating robustness on the held-out test set despite the low-resource nature of Arabic.
- The ablation study confirmed that attention was the key component driving performance gains, not just model depth or architecture.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.