Skip to main content
QUICK REVIEW

[Paper Review] GrammarGPT: Exploring Open-Source LLMs for Native Chinese Grammatical Error Correction with Supervised Fine-Tuning

Yaxin Fan, Feng Jiang|arXiv (Cornell University)|Jul 26, 2023
Natural Language Processing TechniquesComputer Science5 citations
TL;DR

GrammarGPT proposes a supervised fine-tuning approach using a hybrid dataset of ChatGPT-generated and human-annotated native Chinese grammatical errors to train open-source LLMs for Chinese GEC. Despite using only 1,061 parallel data samples—1200x fewer than the SOTA baseline—it achieves state-of-the-art performance, ranking 3rd on NLPCC2023 SharedTask with F0.5 scores of 32.56 (word-level) and 35.84 (char-level).

ABSTRACT

Grammatical error correction aims to correct ungrammatical sentences automatically. Recently, some work has demonstrated the excellent capabilities of closed-source Large Language Models (LLMs, e.g., ChatGPT) in grammatical error correction. However, the potential of open-source LLMs remains unexplored. In this paper, we introduced GrammarGPT, an open-source LLM, to preliminary explore its potential for native Chinese grammatical error correction. The core recipe of GrammarGPT is to leverage the hybrid dataset of ChatGPT-generated and human-annotated. For grammatical errors with clues, we proposed a heuristic method to guide ChatGPT to generate ungrammatical sentences by providing those clues. For grammatical errors without clues, we collected ungrammatical sentences from publicly available websites and manually corrected them. In addition, we employed an error-invariant augmentation method to enhance the ability of the model to correct native Chinese grammatical errors. We ultimately constructed about 1k parallel data and utilized these data to fine-tune open-source LLMs (e.g., Phoenix, released by The Chinese University of Hong Kong, Shenzhen) with instruction tuning. The experimental results show that GrammarGPT outperforms the existing SOTA system significantly. Although model parameters are 20x larger than the SOTA baseline, the required amount of data for instruction tuning is 1200x smaller, illustrating the potential of open-source LLMs on native CGEC. Our GrammarGPT ranks $3^{rd}$ on NLPCC2023 SharedTask1, demonstrating our approach's effectiveness. The code and data are available at \url{https://github.com/FreedomIntelligence/GrammarGPT}.

Motivation & Objective

  • To explore the potential of open-source LLMs for native Chinese grammatical error correction (CGEC), a challenging task with subtle errors from native speakers.
  • To address the scarcity of high-quality parallel training data for native CGEC by constructing a hybrid dataset combining ChatGPT-generated and human-annotated examples.
  • To improve model generalization and error detection capability through an error-invariant data augmentation method that substitutes named entities while preserving grammatical structure.
  • To demonstrate that fine-tuning open-source LLMs with a small, high-quality hybrid dataset can outperform existing SOTA systems trained on vastly larger datasets.
  • To establish a reproducible, open-source framework for native CGEC using instruction tuning and hybrid data curation.

Proposed method

  • A heuristic prompting strategy guides ChatGPT to generate ungrammatical sentences by providing grammatical clue pairs (e.g., 超过 and 左右) to induce redundant component errors.
  • For errors without clues, ungrammatical sentences were collected from public websites and manually corrected to form parallel training pairs.
  • A hybrid dataset was constructed by combining ChatGPT-generated data and human-annotated data, covering both clue-based and clue-free grammatical errors.
  • An error-invariant data augmentation method was introduced, replacing named entities in sentences with semantically similar but distinct entities to increase training diversity without altering grammatical structure.
  • The open-source LLM Phoenix (7B parameters) was fine-tuned using instruction tuning on the hybrid dataset with 1,061 parallel examples.
  • Model performance was evaluated using F0.5, precision, and recall on the NLPCC2023 test set and compared against SOTA baselines like S2S_BART.
Figure 1: The framework of our method.
Figure 1: The framework of our method.

Experimental results

Research questions

  • RQ1Can open-source LLMs achieve state-of-the-art performance in native Chinese grammatical error correction when fine-tuned on a small, curated hybrid dataset?
  • RQ2How effective is a hybrid data generation strategy combining LLM-generated and human-annotated examples for capturing subtle native Chinese grammatical errors?
  • RQ3To what extent does error-invariant data augmentation improve the model’s ability to detect and correct grammatical errors in low-resource settings?
  • RQ4Can a significantly smaller training dataset (1,061 samples) outperform existing SOTA systems trained on 1.2 million samples from foreign language learners?
  • RQ5What is the relative contribution of ChatGPT-generated vs. human-annotated data to model performance in native CGEC?

Key findings

  • GrammarGPT achieved an F0.5 score of 32.56 on word-level and 35.84 on char-level metrics, outperforming the SOTA baseline S2S_BART by nearly 15 points on both metrics.
  • Despite using only 1,061 training samples—1200x fewer than the SOTA baseline—GrammarGPT achieved superior performance, demonstrating the efficiency of high-quality data curation.
  • The model ranked 3rd in the NLPCC2023 SharedTask, validating its effectiveness in real-world evaluation.
  • The ablation study showed that the hybrid dataset outperformed both human-annotated and ChatGPT-generated data alone, with a 27.30 F0.5 on word-level and 28.22 on char-level.
  • Error-invariant augmentation significantly improved recall and F0.5 scores, indicating enhanced error detection capability, while precision remained stable.
  • ChatGPT-generated data alone achieved higher performance (F0.5: 18.49 word-level) than human-annotated data (F0.5: 5.04), suggesting LLMs can generate high-quality, diverse error patterns at scale.
Figure 2: Process of ungrammatical sentences generated by ChatGPT.
Figure 2: Process of ungrammatical sentences generated by ChatGPT.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.