Probing for targeted syntactic knowledge through grammatical error detection

Christopher Davis, Christopher Bryant, Andrew Caines, Marek Rei, Paula Buttery
10/28/2022
cs.CL

Official code: chrisdavis90/ged-syntax-probing (1 star, Jupyter Notebook, GPL-3.0, last commit 2023-03-07).

Abstract

Targeted studies testing knowledge of subject-verb agreement (SVA) indicate that pre-trained language models encode syntactic information. We assert that if models robustly encode subject-verb agreement, they should be able to identify when agreement is correct and when it is incorrect.

Show full abstract

To that end, we propose grammatical error detection as a diagnostic probe to evaluate token-level contextual representations for their knowledge of SVA. We evaluate contextual representations at each layer from five pre-trained English language models: BERT, XLNet, GPT-2, RoBERTa, and ELECTRA. We leverage public annotated training data from both English second language learners and Wikipedia edits, and report results on manually crafted stimuli for subject-verb agreement. We find that masked language models linearly encode information relevant to the detection of SVA errors, while the autoregressive models perform on par with our baseline. However, we also observe a divergence in performance when probes are trained on different training sets, and when they are evaluated on different syntactic constructions, suggesting the information pertaining to SVA error detection is not robustly encoded.

View on arXivView PDF

Code Implementations(1)

GPL-3.0

Placeholder

10Jupyter Notebook, PythonOct 18, 20223 years agoGPL-3.0

Similar Papers

Cite this paper

@article{davis2022probing,
  title  = {Probing for targeted syntactic knowledge through grammatical error detection},
  author = {Christopher Davis and Christopher Bryant and Andrew Caines and Marek Rei and Paula Buttery},
  year   = {2022},
  eprint = {2210.16228},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2210.16228}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2210.16228.svg)](https://codeofpaper.com/paper/2210.16228)

Discussion