GEC-DePenD: Non-Autoregressive Grammatical Error Correction with Decoupled Permutation and Decoding

Konstantin Yakovlev, Alexander Podolskiy, Andrey Bout, Sergey I. Nikolenko, Irina Piontkovskaya

Introduction

Grammatical Error Correction (GEC) is a critical component of modern writing assistants. While state-of-the-art models achieve high accuracy, they typically rely on autoregressive architectures that generate corrections one token at a time. This sequential process introduces significant latency, making real-time application challenging. Non-autoregressive (NAR) models offer a potential solution by generating tokens in parallel, but they often struggle with quality or rely on complex, language-specific transformation tags that hinder scalability.

GEC-DePenD addresses these challenges by introducing a language-agnostic NAR approach that decouples the correction process into two distinct stages: permutation and decoding. This architecture allows for high-speed inference without sacrificing the grammatical coherence of the output.

The GEC-DePenD Architecture

The core innovation of GEC-DePenD is the separation of sentence reordering from token generation. This is achieved through two specialized networks:

  1. Permutation Network: This component handles the structural "skeleton" of the correction. It takes the source sentence and a set of auxiliary insertion (ins) tokens as input. Using a pointing mechanism based on a self-attention weight matrix, the network determines the optimal order of tokens and the placement of placeholders for new words.
  2. Decoder Network: Once the sentence structure is established, the decoder fills in the placeholders. It utilizes the Step-Unrolled Denoising Autoencoder (SUNDAE) technique, which iteratively refines tokens in parallel. This allows the model to capture complex linguistic dependencies, such as subject-verb agreement, while maintaining the speed advantages of parallel generation.
The GEC-DePenD architecture decouples the correction task into a permutation network for reordering and a decoder network for filling in placeholders.

Improving Training Data Alignment

Beyond architectural changes, the authors identified that standard dataset alignment tools often produce fragmented spans of text, which complicates the learning process for NAR models. To mitigate this, they developed a new dataset construction algorithm using dynamic programming. This algorithm prioritizes preserving longer, more coherent spans of text during the alignment of errorful source sentences with their corrected targets, significantly improving the model's ability to learn natural phrasing.

Evaluation and Results

GEC-DePenD was evaluated on standard benchmarks, including CoNLL-2014 and W&I+L. The model achieved an $F_{0.5}$ score of 61.6 on CoNLL-2014, outperforming other language-agnostic NAR models like FELIX.

The most significant advantage of GEC-DePenD is its efficiency. The SUNDAE-based version is approximately 4.7x faster than a standard autoregressive BART-large model. Crucially, while autoregressive models exhibit a linear increase in latency as sentence length grows, GEC-DePenD maintains a relatively flat latency profile, making it exceptionally well-suited for processing long documents.

Comparison of latency across different sentence lengths, showing GEC-DePenD's superior speed and scalability compared to autoregressive BART models.

Conclusion

GEC-DePenD represents a significant step forward for non-autoregressive GEC. By decoupling permutation and decoding, the model achieves a compelling balance between speed and accuracy. Its language-agnostic nature makes it a versatile tool for global applications. While a quality gap remains when compared to massive, multi-billion parameter autoregressive models, GEC-DePenD provides a highly efficient alternative for real-time grammatical error correction. Future research will focus on refining the beam search rescoring process to further narrow the performance gap.

Summary updated

BibTeX
@inproceedings{yakovlev2023gec,
  author = {Konstantin Yakovlev and Alexander Podolskiy and Andrey Bout and Sergey I. Nikolenko and Irina Piontkovskaya},
  title = {{GEC-DePenD: Non-Autoregressive Grammatical Error Correction with Decoupled Permutation and Decoding}},
  booktitle = {Annual Meeting of the Association for Computational Linguistics},
  year = {2023},
  doi = {10.18653/v1/2023.acl-long.86},
}
Figure