GEE! Grammar Error Explanation with Large Language Models

Yixiao Song, Kalpesh Krishna, Rajesh Bhatt, Kevin Gimpel, Mohit Iyyer · DOI

Introduction

While Grammatical Error Correction (GEC) tools have become highly effective at fixing sentences, they often function as "black boxes" for language learners. By providing only the corrected output without explaining the underlying grammatical reasoning, these tools offer implicit feedback that fails to address the educational needs of students. This paper introduces the task of Grammar Error Explanation (GEE), which aims to generate natural language explanations for corrections to help learners understand their mistakes.

The GEE Framework

The authors identify a significant bottleneck in current Large Language Models (LLMs): even state-of-the-art models like GPT-4 struggle to identify and explain every specific error when prompted directly. In one-shot scenarios, GPT-4 often misses nearly 40% of errors or hallucinates non-existent ones. To overcome this, the researchers proposed a two-step pipeline designed to decompose the problem into identification and explanation.

The GEE two-step pipeline: first extracting atomic edits, then generating structured explanations.

Step 1: Atomic Token Edit Extraction

Instead of generating an explanation immediately, the system first identifies specific "atomic" changes between the original and corrected sentences. These edits are categorized into four types: insert, delete, replace, and relocate. The inclusion of the "relocate" category is particularly significant for learners, as standard GEC evaluation often mischaracterizes word-order changes as a combination of deletion and insertion. Fine-tuned versions of Llama2-7B and GPT-3.5-turbo were utilized to perform this extraction with high precision.

Step 2: Explanation Generation

The extracted edits are then provided to GPT-4 as a structured "to-do list." By focusing on these specific edits rather than the raw text, the model's ability to provide accurate, rule-based explanations increases dramatically. For example, a relocation edit in German might trigger an explanation about verb placement in subordinate clauses.

Experimental Setup and Datasets

The study evaluated the GEE framework on two linguistically distinct languages:

  • German: A fusional language, using data from the Falko and Merlin corpora (essays from L2 learners across A1-C2 levels).
  • Chinese: An analytical language, using the CGED2017 dataset based on the HSK proficiency test.

The authors manually annotated 500 sentence pairs for each language to create gold-standard benchmarks for atomic edit extraction.

Results and Analysis

The two-step pipeline achieved high levels of accuracy as validated by professional language teachers. In German, the system produced 93.9% fully correct explanations, a substantial improvement over the ~60% coverage of one-shot baselines. In Chinese, the system reached an even higher correctness rate of 98.0%.

Human evaluation results for German GEE, showing a 93.9% full correctness rate across nearly 2,000 explanations.

Key insights from the results include:

  • Structured Input Efficiency: Fine-tuned GPT-3.5-turbo achieved an F1 score of 0.931 for German edit extraction, demonstrating that specialized smaller models can effectively handle the identification sub-task.
  • The Importance of Context: While highly accurate, the model occasionally struggled with errors requiring document-level context, such as tense consistency across multiple sentences or coreference resolution.

Conclusion and Future Work

The GEE framework demonstrates that decomposing complex reasoning tasks into structured sub-tasks allows LLMs to provide high-quality educational feedback. Future research will focus on incorporating document-level context to explain discourse-related errors and integrating the correction and explanation steps into a seamless, end-to-end educational writing assistant.

Summary updated

BibTeX
@inproceedings{song2024gee,
  author = {Yixiao Song and Kalpesh Krishna and Rajesh Bhatt and Kevin Gimpel and Mohit Iyyer},
  title = {{GEE! Grammar Error Explanation with Large Language Models}},
  booktitle = {Conference of the North American Chapter of the Association for Computational Linguistics},
  year = {2024},
  doi = {10.18653/v1/2024.findings-naacl.49},
}
Figure