Source-linked AI summary

STAGEET: Stage-wise Typed Edit Tagging for Grammatical Error Correction with Arabic as a Case Study

Wenjie Lou, Alaa Mamdouh Akef

arXiv:2608.28614v1cs.CLcs.AI

TL;DR

STAGEET addresses the limited category-level interpretability of monolithic edit vocabularies in GEC. It organizes correction into typed executable stages with intermediate outputs and evaluates shared and specialized variants on Arabic benchmarks. The experiments report competitive edit-based performance, state-of-the-art results on QALB-2014, and an inspectable correction trajectory.

  • Problem

    Monolithic edit vocabularies can specify how to rewrite text without revealing which correction category is being addressed, especially for heterogeneous Arabic phenomena.

  • Method

    STAGEET derives typed supervision automatically and applies ordered stage-specific taggers sequentially, using either shared adapters and heads or independent stage models.

  • Results

    Experiments on QALB-2014 and ZAEBUC show competitive edit-based GEC performance, with state-of-the-art results on QALB-2014.

  • Takeaways & Limitations

    STAGEET makes correction trajectories more inspectable while retaining the efficiency and local editability of Seq2Edit models.

  • Takeaways & Limitations

    The current taxonomy is designed around Arabic error phenomena, and single-pass typed tagging is left for future work because joint reconstruction can create conflicts.

Abstract

from arXiv · show

Sequence-to-edit approaches make grammatical error correction (GEC) efficient and locally interpretable by predicting edit labels over the input rather than generating a full corrected sentence. Their interpretability, however, is primarily operational: a label specifies how the string should change, but a single edit vocabulary does not always reveal the type of correction being made. We propose STAGEET, a stage-wise typed edit-tagging framework that reorganizes Seq2Edit supervision into typed executable stages and extends edit operations to correction categories. STAGEET decomposes correction into an ordered sequence of medium-grained typed stages; each stage predicts from its own label space, rewrites the current hypothesis once, and passes the resulting intermediate sentence to the next stage. We instantiate the framework as both an end-to-end shared-encoder multi-head model with stage-specific adapters and a fully specialized variant with one independent tagger per stage. Experiments on QALB-2014 and ZAEBUC show that category-aware staged correction retains competitive edit-based GEC performance while exposing a more inspectable correction trajectory, and attains state-of-the-art results on QALB-2014.

1 Introduction

STAGEET addresses the limited category-level interpretability of monolithic edit vocabularies by organizing Arabic GEC into typed, sequential stages. It derives typed supervision automatically and instantiates the framework with shared and specialized models.

  • Monolithic edit labels describe string changes but may not identify the linguistic error category being corrected.
  • Arabic exposes this limitation through corrections involving clitic boundaries, orthography, morphology, lexical choice, and punctuation within short spans.
  • STAGEET uses four sequential typed stages—spacing, orthography, morpho-lexical correction, and punctuation—to produce inspectable intermediate sentences.Figure 1 illustrates token-aligned stage-specific edit labels.
  • Typed stage-wise edit tagging reorganizes Seq2Edit supervision into executable stages with stage-specific label spaces and intermediate hypotheses.
  • Typed supervision is automatically derived from raw–corrected sentence pairs without separately annotated error-type labels.
  • The framework includes a shared-encoder multi-head model and a fully specialized stage-separated variant.

2 Background and Related Work

Prior GEC work motivates editing over generation because corrections are sparse and local, but monolithic label spaces limit category-level interpretability. STAGEET reframes this limitation as a typed label-organization problem, especially relevant for Arabic.

  • GEC inputs and outputs usually have high lexical overlap, so edit-based modeling targets the small subset of tokens requiring modification.Evaluation commonly emphasizes precision-oriented metrics because overcorrection can be harmful.
  • Text-editing systems predict operations that transform input into output, with prior approaches including LaserTagger, PIE, Seq2Edits, and GECToR.
  • Edit-vocabulary size trades rewrite precision against sparsity, complexity, learnability, and expressiveness.
  • Most text-editing systems use one label space for all correction phenomena, leaving rewrite instructions less explicit as error categories.
  • Arabic GEC faces limited annotated resources alongside rich morphology, clitic attachment, orthographic ambiguity, dialectal variation, and punctuation conventions.QALB and ZAEBUC provide complementary Arabic correction benchmarks.
  • STAGEET differs from post-hoc error annotation by making typed categories part of correction rather than recovering them only after prediction.

3 Approach

STAGEET converts raw–corrected sentence pairs into typed intermediate targets and applies one stage at a time in a fixed order. It supports compact shared modeling or fully specialized taggers while preserving stage-specific label interpretation.

  • STAGEET decomposes direct correction from raw sentence x to corrected sentence y into a sequence of typed intermediate targets.Each transition corresponds to a distinct correction stage.
  • The type system is executable: every stage has its own supervision, label vocabulary, prediction component, and intermediate output.
  • Raw–gold sentence pairs are aligned, converted into edit operations, and assigned to typed stages according to linguistic function.This produces stage targets without manual error-type annotation.
  • The medium-grained taxonomy contains spacing, orthography, morpho-lexical correction, and punctuation stages.These stages cover boundaries, local orthographic variation, broader grammatical or lexical edits, and punctuation operations.
  • Stages are ordered as spacing, orthography, morpho-lexical correction, then punctuation, with each applied exactly once.The sequence re-anchors later predictions on intermediate sentences and avoids joint typed-edit reconstruction conflicts.
  • Each stage uses its own label vocabulary, while edits are extracted at subword level, compressed into frequent rewrite patterns, and optionally pruned when rare.
  • STAGEET-MH shares a pretrained Transformer encoder but uses stage-specific adapters and heads, whereas STAGEET-SEP trains one independent tagger per stage.The shared variant is compact; the specialized variant has a larger parameter footprint.

4 Experimental Setup

Experiments evaluate STAGEET variants on two Arabic GEC benchmarks using edit-based metrics and comparisons with neural generation and prompted LLM systems. Implementation choices include shared versus separately trained stage taggers, development-based checkpoint selection, label pruning, and a fixed punctuation threshold.

  • Datasets: QALB-2014 and ZAEBUC provide evaluation settings from shared-task Modern Standard Arabic errors and learner essays, respectively.QALB-2014 uses the official shared-task split and M2 annotations; ZAEBUC uses an Arabic GEC split with alignment-derived M2 edits.
  • Evaluation: M2 scoring reports precision, recall, F1, and F0.5 over edits, with F0.5 weighting precision more heavily.The setup also evaluates cumulative performance after stage prefixes and separately analyzes correction before punctuation.
  • Baselines: The comparison includes representative Seq2Seq systems, prompted LLM references, and Arabic GEC models from several modeling families.A’2023 and A’2023 (Seq2Seq++) represent neural generation systems, while GPT-4o, Fanar, and Jais-13B-Chat are prompted under Arabic settings.
  • Model variants: STAGEET-MH jointly optimizes a shared AraBERTv02 encoder, adapters, and stage-specific heads, whereas STAGEET-SEP trains each stage tagger separately.The sequential variant receives a larger model-selection budget through top stage candidates composed sequentially, while the multi-head model uses its best development checkpoint.
  • Implementation details: Rare edit labels are pruned with stage-specific thresholds, and the punctuation confidence threshold is selected on development data as 0.6 for unchanged test use.The selected punctuation threshold is applied unchanged during test evaluation.

5 Results and Analysis

STAGEET reorganizes Arabic GEC into typed, executable stages and evaluates both correction quality and the resulting trajectory. Results show competitive performance, compact shared-encoder deployment, stage-specific label distributions, and evidence motivating adapters.

  • Main results: On QALB-2014, STAGEET-SEP achieves the highest precision-oriented score among reported systems, whereas ZAEBUC results are closer and split across model families.The main development-results table reports final M2 precision, recall, F1, and F0.5 for both STAGEET variants and the comparison systems.
  • Runtime and model size: STAGEET-MH uses one shared encoder with stage-specific adapters and heads, while STAGEET-SEP uses four independent taggers and stores more parameters at the same staged decoding depth.The shared multi-head design has a compact parameter footprint; both variants are substantially smaller and faster than prompted large language models such as GPT-4o.
  • Stage-wise label distributions: Around 12% of token positions are active in orthography, while morpho-lexical correction has the largest raw label inventory and spacing and punctuation remain more compact.Non-KEEP labels are sparse overall, but stage distributions differ substantially; pruning reduces the morpho-lexical long tail.
  • Typed correction stages: STAGEET assigns separate executable label vocabularies to spacing, orthography, morpho-lexical correction, and punctuation.The staged design produces intermediate sentences, enabling trajectory inspection and stage-level diagnosis.
  • Cumulative stage behavior: Adding orthography raises both model variants above 0.73 F0.5, while morpho-lexical correction adds a smaller, recall-driven gain.The same pattern appears for both variants, with STAGEET-SEP slightly stronger after the orthography and morpho-lexical prefixes.
  • Gradient interference: Shared-encoder stage gradients are weakly aligned, with 20–50% conflict across full BERT and 48–56% in the last layer; adapters improve overall performance.The last-layer cosine similarities are slightly negative for most stage pairs, supporting private stage capacity alongside a shared encoder.

6 Conclusion and Future Work

STAGEET introduces typed, ordered edit stages that preserve Seq2Edit efficiency while making correction trajectories more category-aware and inspectable. Experiments on QALB-2014 and ZAEBUC support staged typed correction for Arabic GEC, while future work targets broader taxonomies, single-pass tagging, and improved punctuation modeling.

  • STAGEET decomposes correction into ordered typed stages, each with its own label space, prediction component, and intermediate output.The design preserves local editability while exposing a more inspectable correction process.
  • Experiments on QALB-2014 and ZAEBUC show that staged typed correction is an effective formulation for Arabic GEC.The shared multi-head model provides a compact end-to-end instantiation, while the specialized variant demonstrates stronger stage separation.
  • The induced stages differ in linguistic scope, label sparsity, and optimization behavior.
  • Future work includes adapting the taxonomy to other languages, exploring reliable single-pass typed tagging, and developing more targeted punctuation modeling.

Limitations

The current evaluation is scoped to Arabic GEC, and extending STAGEET elsewhere requires language-appropriate typed stages. The staged design also adds multiple decoding steps, while single-pass typed tagging remains future work because joint typed edits can complicate reconstruction and evaluation.

  • The experiments focus on Arabic GEC, and applying STAGEET to other languages requires defining appropriate typed stages.
  • STAGEET introduces multiple decoding steps, although each stage is applied only once.
  • Single-pass typed tagging is left for future work because multiple typed edits may conflict during joint reconstruction before M2 scoring.

Ethical Considerations

The work targets grammatical error correction and analysis rather than high-stakes decisions about writers. Because corrections may affect meaning or style, outputs should be reviewed when accuracy matters.

  • The proposed method is intended for grammatical error correction and analysis rather than high-stakes decisions about writers.
  • Corrected outputs should be reviewed in educational or professional settings where accuracy is important.GEC systems may alter user text in ways that affect meaning or style.

A Hyperparameters

STAGEET uses a shared pretrained encoder and fixed training settings, with stage-specific label pruning and development-selected punctuation confidence. The multi-head and specialized variants differ in training and model-selection procedures, including sequential candidate composition for STAGEET-SEP.

  • All STAGEET models use AraBERTv02, train for 50 epochs, and use learning rate 5e−5, batch size 32, sequence length 512, seed 42, and two A100 GPUs.
  • Stage-wise label-pruning thresholds are 10, 10, 10, and 30 for spacing, orthography, morpho-lexical correction, and punctuation.
  • The multi-head model uses a 1:3:3:1 stage-sampling ratio and selects its best checkpoint by development-set M2.
  • The specialized variant trains separate end-to-end taggers, retains the top two M2 candidates per stage, and passes them sequentially to the next stage.
  • Models evaluated on ZAEBUC are trained on QALB-2014 plus a tenfold upsampled ZAEBUC training set.

B Stage-wise Data Construction

STAGEET constructs training supervision by deterministically applying typed correction stages in order, realigning after each stage. The stages separate spacing, orthography, morpho-lexical edits, and punctuation before converting the results into subword edit-tagging examples.

  • Construction procedure: STAGEET traverses the stage inventory in order, aligning the current hypothesis with the normalized gold sentence and applying only the current stage’s typed operations.After each stage, the intermediate sentence is realigned before the next stage.
  • Spacing stage: Spacing handles boundary-only split, merge, insertion, and deletion transformations before lexical or punctuation edits.Boundary-only transformations preserve the sequence of non-space characters.
  • Orthography stage: Orthography captures local spelling and normalization changes while excluding broader lexical or morphosyntactic replacements.Examples include hamza-seat variants, alif alternations, adjacent transpositions, and common spelling replacements.
  • Morpho-lexical stage: The morpho-lexical stage receives residual non-punctuation edits, including proclitic, agreement-suffix, lexical substitution, insertion, and deletion operations.Some edits become classifiable only after preceding boundary operations.
  • Punctuation stage: Punctuation is applied last after punctuation tokenization, and the staged output is verified against the gold sentence under the same tokenization.This stage covers punctuation insertion, deletion, and replacement.
  • Training data format: Each intermediate stage is converted into subword edit-tagging examples, with rare-label pruning thresholds of 10, 10, 10, and 30 for the four stages.The thresholds correspond to spacing, orthography, morpho-lexical correction, and punctuation, respectively.

D Gradient Conflict Matrices

The gradient analyses examine pairwise relationships among stage losses in the shared multi-head model. They report near-zero average cosine similarities, some negative alignment in the final BERT layer, and conflict distributed across stage pairs.

  • Gradient similarities: Pairwise average gradient cosine similarities remain close to zero across the encoder and become slightly negative for several stage pairs in the last BERT layer.Rows and columns represent stage losses in the shared multi-head model.
  • Gradient conflicts: Negative gradient alignment is not concentrated in a single stage pair, according to the corresponding conflict rates.Each conflict-rate cell is the proportion of sampled gradients with negative cosine similarity.
  • Prompted references: The prompted LLM references use the Arabic five-shot prompt shown in Figure 2 and request only the corrected sentence between specified input and output tags.The prompt follows SWEET’s cited prompt format.
Loading 2608.28614v1…