Elamur Research

Exploring Linguistic Acceptability in Swedish Learners' Language

Paper · 2022 · Julia Klezl, Yousuf Ali Mohammed and Elena Volodina

Summary

A sentence written by someone learning Swedish can make sense and still need a correction. Detecting that it needs one is a useful first step for writing feedback, even before a system can identify the troublesome word or suggest a repair. The authors study that first decision using DaLAJ, a collection of sentence pairs derived from annotated learner essays. One member of a pair contains a single marked error and the other is its corrected counterpart. A classifier sees each sentence separately and predicts whether it contains an error. The study connects linguistic acceptability, the question of what speakers find well formed, with the practical problem of detecting errors in learner writing. Grammatical error correction & learner language

The authors compare ways of representing Swedish words and ways of assembling the training data. They give a bidirectional recurrent classifier either pretrained FastText vectors or contextual vectors from Swedish BERT. With the contextual representation, a word’s vector depends on the sentence in which it occurs. They also compare keeping repeated copies of corrected sentences with replacing repetitions using correct sentences from Swedish coursebooks. Repetition arises because an essay sentence with several annotated errors yields several distinct single-error versions that share a correction. The two training arrangements therefore offer the same number of sentence entries but a different variety of correct Swedish. Word embeddings

The highest reported accuracy was 73%, from the classifier using Swedish BERT and the coursebook-enriched training and validation sets. It reached that score on a test set from which repeated corrections had been removed, leaving more incorrect than correct sentences. Its recall was 0.83 for incorrect sentences and 0.39 for correct ones on that split. The same classifier scored 0.69 on a test set balanced with additional correct learner sentences and 0.61 on the test set that retained duplicate corrections. BERT outperformed FastText in every matched comparison. The effect of adding coursebook sentences depended on the test set, and the best score on the test set with duplicates came from training with the original DaLAJ data.

The detailed analysis shows what those aggregate results cover. The strongest overall configuration frequently caught spelling errors and several kinds of clause or sentence-structure problems. It had more trouble with number agreement, some preposition choices, and errors that became apparent only in the original essay. Beginner sentences were classified more accurately than intermediate or advanced ones, whose mixes of errors differed. DaLAJ provides a starting point for measuring sentence-level error detection in Swedish. Its single-error format and the class imbalance of its highest-scoring test set help define what the reported accuracy means for work on authentic, unedited learner writing.

Deep dive: Exploring Linguistic Acceptability in Swedish Learners' Language

How DaLAJ uses Swedish learner essays to test whether a classifier can recognize sentences with errors, and what changes its accuracy. · about 34 minutes to read

The problem and its context

A sentence can be judged in more than one way

The linguistic notion of acceptability starts with a speaker’s judgment about whether an expression sounds possible or natural. As the paper describes the field, such judgments can come in degrees, while computational tasks commonly reduce them to a choice between acceptable and unacceptable. That reduction is convenient when a system must make a definite decision about each sentence. Its meaning depends on who judged the sentence, why it was collected, and what counted as a reason to reject it. The paper places this tradition in generative linguistics and relates it to research on how people perceive and acquire language. Psycholinguistics

In DaLAJ, the judgment comes from correction annotation. An essay sentence was marked for a problem, and the annotated repair supplies evidence for the distinction the classifier is asked to learn. The target is whether a sentence has an annotated error under this procedure. An error can concern spelling, a word choice, punctuation, an inflected form, or the organization of a clause. A sentence can communicate its intended message in spite of any of these problems. Conversely, an annotator may have a reason to change a sentence that would sound entirely reasonable if encountered on its own. The source of the judgment matters as much as the fact that the judgment is binary. Linguistic annotation

For a writing aid, the binary decision is useful because it can flag a sentence for attention. Several decisions still lie between the flag and advice a learner can act on. A system has to identify which expression needs attention, determine what kind of problem it represents, and propose a change that preserves the intended meaning. A single sentence-level label leaves all of those questions open. The authors use this narrower task to investigate which evidence supports an initial flag and to establish a benchmark for later detection and correction work.

Where earlier studies got their sentences

The paper describes two common ways of collecting unacceptable sentences. One is to use examples already available in linguistic publications. The other is to start with a well-formed sentence and alter it to introduce a chosen problem. The first takes advantage of examples that researchers have already selected to illustrate linguistic contrasts. The second gives researchers control over the construction they are testing and the change made to it. Both approaches can answer targeted questions about sensitivity to particular pieces of grammar. The paper mentions syntax-sensitive dependency tests as an example of how acceptability research can probe the representations learned by a system. Assessing the Ability of LSTMs to Learn Syntax-Sensitive Dependencies

Learner essays offer a different source of evidence. The original writer chose the words and constructions while trying to express something in Swedish. The errors therefore arise in the process of writing instead of being specified in advance by an experimenter. The authors observe that authentic learner errors had seldom been used in the acceptability research they survey. For Swedish in particular, they knew of earlier acceptability research that deliberately perturbed word order. That approach asks how a system responds to particular word-order changes. The DaLAJ study asks how it handles a wider collection of annotated problems that occurred in learner essays.

The resulting material sits between a linguistic test set and a collection of untouched learner prose. The original essays supply the context, phrasing, and errors. The dataset construction controls which annotated problem survives in any one item. An error that was originally surrounded by other problems can therefore be examined against a largely corrected sentence. This makes it easier to associate a sentence outcome with one annotated phenomenon. It also removes interactions a system would encounter when reading the original essay. The authors make that tradeoff deliberately because they want to examine what can be learned from single-error examples before moving on to more complex writing.

The comparisons the paper draws with English

The shared task on Automatic Evaluation of Scientific Writing provides one precedent. It asked systems to identify English sentences in research articles that needed editing. The target included style choices inappropriate for scientific writing as well as grammatical problems. Participants could give a binary decision or a probabilistic prediction. Methods ranged from conventional statistical classifiers to neural approaches based on word or character information. It is a point of comparison because it, too, assigned a sentence-level judgment based on a need for correction. The intended audience and the kinds of edits were different from those in Swedish learner writing.

The other main point of comparison is the English Corpus of Linguistic Acceptability, CoLA. The paper describes it as a collection of judgments drawn from published linguistic examples, spanning problems of form, sentence structure, and meaning. It also discusses a CoLA approach that transferred an encoder trained with artificial examples and contextual word representations. CoLA and DaLAJ share the broad format of deciding whether a sentence passes a linguistic criterion. Their sentences reach that format by different routes. CoLA’s examples were selected to illustrate linguistic phenomena. A DaLAJ item can carry the residue of an essay topic, the learner’s intended reference, and the choices made by the person who normalized the text.

Prior work on error detection also helps explain the choice of classifier. The paper draws on studies that process language in sequence and use information from both sides of a word. This is relevant to errors whose evidence is distributed across a phrase or clause. An inflected form can be ordinary in one environment and incompatible with another expression elsewhere in the sentence. The authors borrow an architecture suited to reading these dependencies while asking it to return a decision for the sentence as a whole. Earlier work they cite includes research that instead attaches error decisions to positions in learner writing. Compositional Sequence Labeling Models for Error Detection in Learner Writing

These precedents supply the components of the Swedish experiment without settling its main questions. Sentence-level classification had already been used for writing assessment, acceptability had already been studied with neural systems, and error detection had already used recurrent architectures. The new question concerned how those approaches would work with a Swedish dataset whose errors came from essays but whose examples had been edited to isolate one problem at a time. The paper treats the composition of that dataset as part of the experiment, alongside the choice of text representation.

The method, step by step

Start with the essay and its corrections

The starting material is SweLL-gold, a part of the Swedish Learner Language corpus. It contains 502 essays by adult learners at beginner, intermediate, and advanced course levels. Identifying material was pseudonymized, and the essays were normalized and annotated with corrections. The study reports 6,615 sentences with at least one error and 1,706 sentences judged correct in the source corpus. The annotation scheme uses 35 correction tags. These include categories for standard spelling, wording, inflection, punctuation, and sentence structure, as well as special annotations for cases such as unintelligible writing or adjustments made because another part of the sentence was changed.

To see how DaLAJ uses these annotations, imagine that a learner sentence needs a spelling repair and a change to an inflected word. DaLAJ can retain the misspelling while applying the inflection repair. It can also apply the spelling repair while retaining the problem with inflection. These are distinct incorrect sentences, each with one annotated problem. The fully corrected form can serve as the counterpart to each of them. A sentence with several errors in its original essay can thus supply several useful examples, while the number of distinct corrected sentences grows more slowly than the number of incorrect ones.

Each DaLAJ entry supplies the erroneous and corrected versions, the text involved in the edit, and the category of the correction. The record also preserves the learner’s course level. The resource includes first-language information, which the study leaves outside the experiment. DaLAJ shuffles the sentences so the essays cannot be reconstructed from their order. The classifier consequently works with individual sentences, even though the correction itself was decided when the essay was available. This distinction later matters when a pronoun or word choice depends on what the learner had said earlier.

The full DaLAJ 2.0 inventory before preprocessing has 26,652 incorrect sentences with corrected counterparts. Those counterparts represent 6,615 unique correct sentences. The paper reports 1,241,754 tokens and a vocabulary of 19,963 at this stage. Tokens are the individual units counted in the processed text, and vocabulary size records how many distinct units the inventory contains. These figures describe the starting resource. Length restrictions, annotation filters, and duplicate removal determine what reaches the actual experiments. The earlier DaLAJ 1.0 pilot targeted four error types, while the full version starts from the 35 types in the underlying annotation scheme. Tokenization

From annotated learner essays to sentence decisions

The steps in order.

From annotated learner essays to sentence decisionsStep 1: Isolate one annotated error per sentence variant1. Isolate one annotated error per sentence variantStep 2: Pair each variant with its corrected sentence2. Pair each variant with its corrected sentenceStep 3: Split, filter, and prepare both training conditions3. Split, filter, and prepare both training conditionsStep 4: Encode sentences with pretrained word representations4. Encode sentences with pretrained word representationsStep 5: Read each sequence in both directions5. Read each sequence in both directionsStep 6: Predict whether the sentence contains an error6. Predict whether the sentence contains an errorStep 7: Evaluate predictions on differently composed test sets7. Evaluate predictions on differently composed test sets

Make the splits before comparing representations

The initial division assigns 80% of DaLAJ to training and 10% each to validation and testing. Training supplies the examples used to adjust the classifier. Validation supplies a separate check during training, including the signal for when to stop. Testing measures the resulting classifier on held-out sentences. The authors design the split to keep identical sentences out of both training and test, a safeguard that matters because repeated corrections are an explicit feature of the dataset. They also arrange for the course-level proportions to match across the initial splits.

The authors then remove sentences of more than 50 tokens, counting punctuation in that limit, and remove duplicate incorrect sentences. They exclude error types with fewer than 100 occurrences in the data. Such a filter makes the benchmark more tractable but narrows its coverage: a type can belong to the full DaLAJ annotation scheme and still be missing from the evaluation. The authors also set aside special annotations that fall outside the main categories, such as comments and markers for material that could not be interpreted. The eventual error breakdown covers 18 of the 35 SweLL types. The groups that remain are orthography, lexis, morphology, punctuation, and syntax. Morphology

Placeholders substituted during pseudonymization require a further decision. The authors replace place placeholders with actual place names so that sentences contain ordinary names of cities, countries, or other locations. An example in the paper replaces a generic country placeholder with Norway in a sentence about the writer’s birthplace. The operation makes the input more like ordinary text at the level of individual words. It can also produce strange combinations when several places occur in the same sentence and their relationship matters to the meaning.

There are two distinct uses of the annotations after preprocessing. During preparation they determine the sentence’s target label and identify which part of an erroneous variant was retained. During evaluation they let the authors sort incorrect examples by error type. The ordinary sentence label is 0 for a correct example and 1 for one with an error. Correct examples have no error category. A classifier can therefore be trained to make the binary decision while its results are later examined at a finer level of detail. The category analysis describes how often errors carrying each tag were recognized. It does not require the classifier itself to predict the tag.

Decide what should fill the correct class

The first version of the training and validation data keeps repeated corrected sentences. Repetition helps maintain label balance because every erroneous variant has an associated correction. Yet a corrected sentence that occurs repeatedly supplies the same words and construction each time. In training it therefore receives more weight than a correct sentence that occurs less often. The resulting correct class gives the classifier repeated exposure to some sentences while giving it fewer distinct examples of the language that should receive a correct label.

The second version removes those repeats and fills the resulting places with correct sentences from COCTAILL, a collection of text from 12 Swedish coursebooks. The authors chose it because coursebooks are also part of the language-learning domain and because the material is marked for course level. A coursebook sentence stands on its own as a correct example. It is not an alternative repair for any particular learner sentence. In the enriched condition, the classifier is still being asked for a binary judgment on a single input, so the additional correct examples can participate without corresponding erroneous versions.

The textbook material also needed filtering. Coursebooks contain headings, lists, definitions, and other fragments that are useful on the printed page but would complicate a collection intended to represent correct sentences. The authors report replacing 5,015 beginner, 2,468 intermediate, and 5,066 advanced entries with sentences at the corresponding levels after filtering. They use the course-level designations to preserve the intended distribution. A textbook passage’s intended audience and an essay writer’s course placement are both level indicators, though one describes teaching input and the other describes the writer who produced an example.

Each training condition has 32,394 sentences, and each validation condition has 4,008. The change in variety is visible in the vocabulary sizes. The original training condition has a vocabulary of 10,826, while the training condition enriched with COCTAILL has 21,936. The vocabulary counts show that replacing repeats changes more than the weight of a few already familiar sentences. It exposes the classifier to a substantially different range of words. Since the new sentences also come from books, any shift in performance can reflect characteristics of that source alongside the increase in unique examples.

Keep different views of the held-out data

Test set 1 closely follows the regular DaLAJ test split. The authors manually check the correct sentences and make some corrections without adding or removing examples. Repeated correct sentences remain. This test represents the basic structure of the resource, where a fully corrected sentence can appear several times because several erroneous variants lead back to it. Its accuracy counts those occurrences separately, so a prediction about a repeated correction can influence the aggregate result multiple times.

Test set 2 uses the same incorrect examples and the manually checked correct material, with duplicate correct sentences removed. The result is a smaller collection with an imbalance towards errors. This view is useful for examining performance when each remaining correct sentence contributes separately, although the heavier representation of incorrect items changes the interpretation of overall accuracy. An evaluation that counts all predictions equally will reflect the more common class more strongly.

Test set 3 adds correct sentences from SweLL-gold to the deduplicated set. These sentences were held out of DaLAJ training and validation. They come from the learner corpus, which keeps the added material closer in origin to the other test sentences than textbook examples would be. The supply of intermediate sentences was limited, so advanced sentences were used to fill some of the places that intermediate examples would otherwise have occupied. This third test restores label balance with new correct inputs and changes the mix of levels. It measures performance on a different collection of correct sentences as well as on a different balance of labels.

Turn the input into a sequence of vectors

The main classifiers process vectors, lists of numbers that represent the pieces of a sentence. The FastText versions split the input on whitespace and use pretrained vectors with 300 dimensions. In this setup a recognized word starts with the same FastText vector wherever it occurs. The sequence classifier can then interpret that vector in light of the neighboring words and the rest of the sentence. The paper uses pseudorandom vectors for words treated as infrequent and for words absent from the pretrained vocabulary. It distinguishes those cases with UNK and ERR representations, respectively. Learning Word Vectors for 157 Languages

The whitespace-based inputs are padded with zeros on the left up to a length of 50, unless the feature requires different handling. Padding lets sentences of different lengths be processed together. Missing words require a separate decision because the annotation can mark an absence at the point where a word belongs. In FastText training and validation, the marker for a missing word receives the UNK representation. At test time it is skipped. Leaving a special marker at the location of an omitted word would give the classifier information that would be absent from ordinary learner input. This choice keeps that particular annotation cue out of the test, while making the inputs at training and testing differ for this type of error.

The Swedish BERT versions obtain a vector from the word’s context before the recurrent classifier reads the sequence. BERT’s pretrained tokenizer can split the input into whole words or smaller pieces. The authors pass the resulting sequence through Swedish BERT and sum the hidden states from the last four encoder layers to obtain 768-dimensional embeddings. A hidden state is a numerical representation computed inside the encoder. Adding states from several layers gives the recurrent classifier a single vector derived from their output. The authors pad on the right for compatibility with the tokenizer in this condition. Subword tokenization · Playing with Words at the National Library of Sweden

The distinction between fixed and contextual input matters for deciding whether a familiar word is appropriate in an unfamiliar combination. Under FastText, the recurrent classifier must build the context-sensitive interpretation from the sequence of input vectors it receives. Under BERT, some information about surrounding text is already present in each input representation, and the recurrent layer reads those enriched vectors. The experimental comparison substitutes the whole representation pipeline. It changes the vector dimension, tokenization, pretraining source, and learning rate along with contextualization. The method can compare these practical configurations directly, while leaving the individual contribution of each difference unresolved.

Read the sequence and choose a label

The shared classifier has a bidirectional long short-term memory layer followed by a linear layer. The recurrent layer reads the sequence in both directions, allowing the representation used for the decision to draw on words before and after a given position. This suits a task in which the evidence for an error can occur away from the edited word. An agreeing form may occur earlier in a phrase, for example, while the offending form occurs later. A linear output layer produces scores for the correct and incorrect labels. Softmax converts the scores into probabilities over the labels, and argmax selects the label with the highest score. Text classification

The main FastText and BERT configurations use a hidden size of 100. The FastText learning rate is 0.0001, and the BERT learning rate is 0.00005. The learning rate sets the size of the parameter updates made by the Adam optimizer. Training uses cross-entropy loss, which penalizes assigning low probability to the reference label. A data loader shuffles the examples and presents them in batches of 32. The authors cap training at 75 epochs and stop early after 15 epochs without improvement in validation loss. An epoch is a pass through the training material. Using validation loss for early stopping makes the duration depend on performance on examples outside the updates.

Combining each embedding source with each training and validation arrangement produces the main four configurations. The original DaLAJ condition and the one enriched with coursebook sentences are both tried with FastText and again with BERT. The recurrent architecture gives those comparisons a common basis. The test sets then vary independently of the training arrangement. This design lets the authors ask whether changing the input representation helps across several settings, whether adding more varied correct examples helps within each representation, and how much of either result depends on the examples counted at test time.

Try cues at the word, character, and annotation levels

Other experiments ask whether features learned from DaLAJ itself or supplied by a linguistic analysis can improve these classifiers. In the word-index experiment, each vocabulary item receives an index and an embedding layer learns a vector of 100 dimensions from the training data. Words seen fewer than three times are treated as unknown. The character experiment applies the corresponding idea to characters, using 50-dimensional embeddings and an unknown-character threshold of five occurrences. Character sequences offer a way to represent the internal shape of a word even when that complete spelling is missing from a dictionary of pretrained vectors.

The authors also try giving the classifier grammatical information extracted by the Sparv pipeline. They index tags for parts of speech and dependency relations and pad the sequences on the left to 50 positions. A part-of-speech tag names a grammatical category such as a noun or a verb. Dependency relations describe how words are connected within the sentence. The motivation is to make this kind of structure available explicitly alongside the representations produced from the words. The experiment evaluates the chosen tag inputs in combination with the rest of the classifier. Part-of-speech tagging · Dependency parsing

Finally, the study tries to expose the marked error more directly during training. One FastText variant appends an embedding for the annotated problematic word or expression. At test time an ERR representation can be appended for a word absent from the vocabulary, and otherwise the added space is padding. A second approach marks positions in a separate sequence with 1 for marked words and 0 elsewhere, including padding. At test time the 1 marks are based on absence from the FastText vocabulary, which the authors use as a proxy for a spelling problem. Separate bidirectional recurrent layers read the input streams in this variant, and their outputs are joined before the linear decision. These experiments probe whether location information available in an annotated corpus can help when the corresponding location in unseen writing still has to be inferred.

Experiments and results

What the scores count

The main metric is accuracy, the share of test sentences assigned the correct binary label. A correct prediction can be either a correct sentence accepted as such or an erroneous sentence flagged as incorrect. In the deduplicated test set these outcomes have unequal influence on the overall score because there are more erroneous sentences. For its strongest configuration on that set, the paper also gives class-specific precision, recall, F1, and F0.5. Precision measures how frequently a prediction of a given class is right. Recall measures how much of that class the classifier finds. F1 combines precision and recall with equal emphasis, and F0.5 gives precision greater emphasis.

The same metric changes meaning when it is calculated on a subset containing only a single error category. Every example in such a subset is known to contain an error. Accuracy there measures the fraction correctly flagged and amounts to recall for the incorrect class restricted to that category. It leaves unanswered how frequently an apparent instance of the same construction in correct Swedish would be rejected. The course-level breakdown is broader. It includes both labels and measures accuracy across all the sentences in each level’s part of the deduplicated test set.

The main comparative baseline is the FastText classifier trained on the original DaLAJ data. It shares the bidirectional recurrent structure with the other main configurations and provides a reference for changing the representation, changing the training and validation composition, or changing both. The earlier English studies serve as context. They do not supply baseline predictions on the Swedish test splits. That distinction keeps the evaluations of different tasks from being treated as if they were runs on a common benchmark. Evaluation & benchmarks

How test composition changes the ranking

Test set 1 has 3,884 sentence entries and retains duplicate corrections. With FastText, accuracy is 0.61 using the original DaLAJ training and validation data and 0.59 using the version enriched with COCTAILL. With BERT, the corresponding accuracies are 0.66 and 0.61. The strongest result for this test set comes from BERT trained and validated on the original data. The additional correct material is associated with a lower score for both embedding sources under this evaluation.

Test set 2 has 2,573 sentence entries after deduplication. FastText scores 0.42 with the original data and 0.62 with COCTAILL enrichment. BERT scores 0.67 with the original data and 0.73 with the enrichment. This is the test on which the paper’s best individual score occurs. It is also the set that changes most visibly in class composition after duplicates are removed. The original FastText condition gives its lowest reported main result here, while its enriched counterpart does better than it did on the test with duplicates.

Classifier accuracy on DaLAJ test set 2 without duplicate corrections

BERT with coursebook-enriched training and validation scores highest on the deduplicated test set.

Classifier accuracy on DaLAJ test set 2 without duplicate correctionsFastText with original DaLAJ: 0.42FastText with original DaLAJ0.42FastText with COCTAILL enrichment: 0.62FastText with COCTAILL enrichment0.62BERT with original DaLAJ: 0.67BERT with original DaLAJ0.67BERT with COCTAILL enrichment (this paper): 0.73BERT with COCTAILL enrichment (thispaper)0.73
The numbers
System or settingaccuracy
FastText with original DaLAJ0.42
FastText with COCTAILL enrichment0.62
BERT with original DaLAJ0.67
BERT with COCTAILL enrichment (this paper)0.73

Test set 3 brings the total back to 3,884 with additional correct sentences from SweLL-gold. FastText scores 0.53 in the original condition and 0.66 in the enriched condition. BERT scores 0.65 with the original data and 0.69 with the enriched data. FastText with coursebook enrichment attains its best result on this test, while BERT with the same enrichment does best on the deduplicated, imbalanced set. The shared observation across the latter two tests is that replacing duplicated correct training and validation examples helps within each embedding family. The test set that retains duplicates gives the reverse result.

BERT is ahead of FastText on each test when the training and validation arrangement is held the same. Cross-condition comparisons are more sensitive to the data. For example, on test set 3 the enriched FastText configuration reaches 0.66, while the original BERT condition reaches 0.65. The representation comparison and the training data comparison therefore answer distinct questions. The clearest argument for BERT comes from the matched comparisons, where each embedding approach uses the same version of the training and validation data.

Read the class report alongside the headline score

The classification report for BERT with COCTAILL enrichment gives 631 correct and 1942 incorrect examples on test set 2. For correct sentences, precision is 0.43 and recall is 0.39. For incorrect sentences, precision is 0.81 and recall is 0.83. When the classifier flags an error, it is usually right on this particular split. When it accepts a sentence, the decision is right less often, and the classifier recognizes a smaller share of the sentences that should be accepted. The difference between the two labels is central to understanding how the system might behave as a first screen for learner errors.

The same pattern appears in the combined metrics. For the correct class the F1 score is 0.41 and the F0.5 score is 0.42. For the incorrect class the respective scores are 0.82 and 0.81. Within each class, precision and recall are fairly close. Giving precision more weight therefore leaves the broad picture intact. The conspicuous imbalance is between classes, even though the training arrangements were designed to balance the number of correct and incorrect entries.

The authors suggest that the incorrect entries may have offered more informative variation during training. In the original DaLAJ condition, distinct errors can be paired repeatedly with the same correct sentence. In the enriched condition, the extra correct texts broaden the training inventory, but many of those texts come from a different source than the held-out correct sentences. The report shows the asymmetry in predictions. Its design leaves several explanations in play, including the available variation in each label, the origin of examples, and the distribution of labels in the test. In particular, the reported precision values describe this test composition, where incorrect inputs are more common.

How the English results frame the benchmark

The paper compares its results with the English studies it discusses, while pointing to differences in the kinds of sentences used. Among the binary results it cites for the shared task on Automatic Evaluation of Scientific Writing, the best F1 scores are 61.08 and 62.78. That evaluation covers editing needs in scientific prose and reports a different main metric. On CoLA the paper cites accuracy of 77% in-domain and 73% out-of-domain. CoLA’s examples were selected from the linguistics literature, whereas DaLAJ examples began as sentences in connected essays.

Those numbers give a sense of the range reported for comparable sentence-level tasks. They cannot rank the Swedish and English approaches against one another. A classification decision over a contrast deliberately illustrated in a linguistic publication raises different questions from a decision about a learner’s wording in an essay. The metrics and class distributions also matter. The paper reads the comparison as encouraging evidence that the learner-derived format is usable for research. The strongest direct evidence for that point is the set of Swedish comparisons made within the experiment itself.

What the ablations show

The representation choice held up across test settings

The main controlled comparisons vary the representation and the composition of the training and validation data. With the data arrangement held fixed, the BERT configuration beats FastText across the three test sets. This is the most consistent effect in the main experiment. It holds when training uses repeated corrections, when training uses additional coursebook sentences, and when evaluation changes which correct examples are counted. The practical result is that the authors’ contextual BERT inputs are a stronger choice for this recurrent classifier on the tested material.

The authors identify several plausible contributors. BERT supplies vectors that already reflect surrounding text. Its pretraining material and output dimensions differ from those of FastText, and the two configurations use different tokenization and learning rates. These factors travel together. Consequently the table establishes the advantage of the complete BERT condition in these comparisons. It leaves open whether a FastText configuration matched on some of the other properties would close part of the gap, or which part of BERT’s representation carries the most useful information about a particular error type.

The comparison of training data is conditional in a different way. For both embeddings, the best score obtained anywhere uses the COCTAILL-enriched condition, and both benefit from enrichment on the test sets without duplicate corrections. The condition retaining repeats is stronger for both embeddings when the evaluation retains them as well. The result supports using varied correct material when judging performance on unique examples. It also shows how a benchmark with repeated corrections can favor a different training arrangement. Each configuration’s score depends on how the training examples represent correct Swedish and on which correct sentences the test gives weight to.

Extra features had to survive the move from validation to testing

Character embeddings were motivated by a plausible difficulty with word vectors. A misspelling or inflection error can produce a string missing from a pretrained vocabulary, whereas the constituent characters remain available. In the appendix, the character-based experiment reaches accuracies of 55% to 64%. Learning word embeddings from indices in the learner data reaches 52% to 60%. These approaches underperform the strongest pretrained configurations, though the ranges overlap some weaker main results. A possible explanation offered by the authors is that the learner data provide limited evidence for learning useful representations from scratch. The experiments leave room for a different outcome with character representations pretrained on more text.

The added linguistic inputs also failed to improve on the successful embedding-based configurations as reported. This finding pertains to the tags and dependency relations produced and encoded by the tested pipeline. A grammatical relation can be central to whether a sentence is correct even when an explicit feature for it fails to help a classifier. The result shows that these supplementary features did not add usable evidence under the tested arrangements. The paper gives no individual quantitative breakdown that would allow the reader to rank their contributions separately.

The experiments that use error locations expose a more specific problem. Appending the marked word to the FastText input increased validation accuracy to up to around 70%, yet test accuracy remained at or around 50%. During validation the underlying annotations can reveal which word to append. During testing the append operation has to act on a proxy, typically a vocabulary miss. That proxy can sometimes help with a misspelling. It offers little guidance when a familiar Swedish word has the wrong inflection or is inappropriate in context. Higher validation accuracy shows that the classifier can use the cue as supplied there. The test result shows how poorly that gain carries over when the available cue changes.

The position-indicator experiment has a similar pattern. In training and validation, the indicator identifies the annotated words. In testing its entries are mostly zeros, with exceptions for words outside the FastText vocabulary. Validation accuracy improves, but the paper reports no test improvement. The authors consider masking some training and validation indicators with all-zero inputs so the classifier would have experience with sentences that carry no explicit marks. They also mention attention as a possibility. These are proposed changes. The evidence provided by the completed comparison is that adding the annotated location under the existing training procedure did not yield a reliable cue for unseen sentences.

The error tags show a mixed picture within grammar

The strongest overall configuration is analyzed by error type on test set 2. Regular spelling errors are recognized at an accuracy of 0.90 across 261 sentences with that tag. Capitalization errors reach 0.86 across 29. The authors suggest that spelling and some word-formation or inflection problems produce unusual strings whose representation can provide a clue. The word-formation category L-Der reaches 0.84 across 58 examples. The category M-F, where an inflected form changes while the grammatical category stays the same, reaches 0.88 across 24. These are category-specific detection scores on already erroneous sentences, so they show how often the presence of a problem was recognized.

Several results also point beyond conspicuous word forms. A change to clause structure, S-Clause, is detected with accuracy of 0.92 on 66 examples. Extensive syntactic corrections, S-Ext, reach 0.92 on 26, and missing subjects, S-Msubj, reach 0.92 on 39. Incorrect punctuation, P-W, reaches 0.87 on 38 examples. The authors interpret the high scores on these constructions as evidence that the classifier is sensitive to aspects of Swedish sentence structure. The results are compatible with that interpretation, although the examples can offer several clues at once and the output does not identify which clue determined the decision.

Other categories show why success at one structural contrast should not stand for grammar in general. Orthographic problems with compounds reach 0.72 on 18 cases. Grammatical number corrections reach 0.73 on 81, compared with 0.79 across 280 definiteness corrections and 0.83 across 81 gender corrections. The authors raise the possibility that number agreement is especially difficult when relevant determiners, adjectives, and nouns are separated. The better results for related morphological categories show that difficulty varies within inflection and agreement. The score for compounding also qualifies the strong result for regular spelling. A classifier’s ability to recognize an unusual spelling does not guarantee the same success in deciding how the parts of a compound should be written.

The frequency of a tag does not order the results neatly. Compounding is both uncommon on this test and difficult to detect, but some of the high-scoring clause and subject categories also have relatively few examples. A missing word, S-M, reaches 0.80 on 196 examples. Missing punctuation, P-M, reaches 0.84 on 134. The authors suggest that detecting absent material can be hard even when the category is well represented. An incorrect token offers an observable form. In an omission case the evidence has to come from the surrounding sentence and what the classifier has learned to expect there. The observed variation is consistent with that explanation and with differences among the constructions represented by individual tags.

Course level is associated with a different mix of errors

On test set 2, the strongest classifier scores 0.77 on the 1001 beginner sentences, 0.69 on the 437 intermediate sentences, and 0.70 on the 1135 advanced sentences. The label of beginner, intermediate, or advanced refers to the course the learner attended. The result is therefore a comparison across groups of sentences from different course levels, with the distribution of correct and incorrect examples and the types of error those writers produced.

Accuracy by course level for BERT with COCTAILL enrichment on DaLAJ test set 2

Beginner sentences are classified more accurately than sentences from the other course levels.

Accuracy by course level for BERT with COCTAILL enrichment on DaLAJ test set 2Beginner (this paper): 0.77Beginner (this paper)0.77Intermediate: 0.69Intermediate0.69Advanced: 0.70Advanced0.70
The numbers
System or settingaccuracy
Beginner (this paper)0.77
Intermediate0.69
Advanced0.70

The authors give two reasons to be cautious about attributing the difference to proficiency alone. Intermediate sentences are less numerous, and the error categories occur with different frequencies at different levels. Beginner writing more often contains some of the types the classifier handles well, including regular spelling, capitalization, and changes of word form. Some of the more difficult cases, including number, case, and lexical choice, occur more often in advanced writing. The course-level score therefore reflects, in part, the mixture of decisions the classifier is being asked to make. A level comparison with the same error mix would ask a narrower question than the one reported here.

Individual predictions reveal what averages hide

The inspection of missed errors identifies several cases where essay context explains the annotation. One isolated sentence amounts to the writer saying they are very good. It can be ordinary Swedish by itself, even though the essay gave the annotator a reason to correct the verb. The classifier accepted it, which the benchmark counts as a missed error. This example shows that an error can be supported by information outside the input available to the classifier. Another example includes material from a writing assignment and a heading attached to a question. That boundary problem adds text to the sentence that a human reader would normally treat separately.

Other misses involve dependencies within the sentence. In one example, the description begins in the present tense, while a verb in a later clause is in the past. The intervening descriptive material separates the two cues. The authors identify distant agreement as a recurring difficulty, alongside preposition selection and pronoun case. These examples clarify how a sentence can contain familiar words in a readable sequence and still use a form that is inappropriate for its context. The comparatively strong spelling results are compatible with those misses because the problematic item in a preposition or case error can be a valid word form.

The analysis also finds missed spelling errors in names and odd sentences introduced by place-name replacement. One example describes the location of a ruin using a peculiar combination of country names. The authors saw no clear indication that such combinations disrupted classification, though they regard the question as open. They further observe that longer sentences tend to be flagged more frequently than shorter ones. That observation does not supply a controlled estimate of a length effect, because sentence length can vary along with complexity and the types of errors present. It identifies a pattern that the aggregate accuracy cannot explain.

Limitations

Limits identified by the authors

The authors emphasize that the essays were originally corrected as connected texts, while the classifier receives the resulting sentences individually. A correction to a referring expression may follow from which person or thing the essay was discussing. A tense or lexical choice may likewise be sensible in isolation and inappropriate in the passage. The reference annotation and the classifier can thus use different amounts of evidence. This is particularly relevant for judgments about anaphora, where the interpretation of an expression can depend on an antecedent outside the sentence. Coreference resolution

The authors also caution against treating small error categories as stable measures. Even among the retained categories, some test counts are low. The high score on extensive syntactic changes and the lower score on orthographic compounding describe the available examples in those categories. The general standing of each category would need evidence from a broader sample. The authors report that both the scores and the ranking across types varied across configurations. The detailed error table concerns BERT with COCTAILL enrichment on test set 2, which sets the scope for the conclusions drawn from it.

The single-error design leaves transfer to original learner essays open. Editing a sentence to isolate one issue makes it possible to attribute the item’s label to a particular annotation. Authentic input can contain several overlapping problems, and the effects of one repair can alter the interpretation of another. The study’s benchmark tests classifications of the distilled sentences. The authors identify classification of error types, token-level detection, and correction as future experiments. Their longer-term aim of writing feedback would require evidence from those tasks as well as a test of transfer to sentences with several errors.

Some specific data choices introduce further uncertainty acknowledged in the paper. The deduplicated and rebalanced test lacks enough new intermediate examples to preserve the desired level distribution, so some replacements come from the advanced group. Pseudonym replacement can generate unusual meanings. The qualitative observation about longer sentences is tentative. The paper also proposes comparing single-error learner data with artificially generated errors in future work. These uncertainties concern the data a classifier would encounter beyond any one split, and the authors leave them open for subsequent study.

Limits that follow from the setup

The target is a correction decision derived from an annotation scheme. That gives the positive and negative labels an explicit source, but it limits their interpretation as a general measure of acceptability. The task does not collect a range of speaker judgments for the same sentence or measure how strongly a sentence is rejected. It also groups a range of phenomena under the error label. A missing punctuation mark and a complex clause repair have the same sentence-level target even though they raise very different linguistic questions. Category breakdowns recover some of that detail for analysis. The classifier output remains binary.

Several filters also narrow the benchmark’s coverage. The classifier is evaluated on sentences up to the length limit and on a subset of the original error tags. Unintelligible material and rare categories are filtered out. The resulting scores establish how well the classifier works in that selected setting. A writing aid would also encounter lengths, errors, fragments, and ambiguous cases outside it. Since the paper does not use the learner’s first language in the analysis and the source writers are adults, the results give no separate performance estimates for first-language groups or for younger learners.

The deduplicated test score needs its own qualification because the correct and incorrect classes are unequal. Removing repeats changes which predictions receive weight, even if the underlying classifier has not changed at all. Adding new correct examples then changes both class balance and the actual inputs. The three test results can be read together as a sensitivity check on evaluation design. They do not isolate an effect of duplication independent of sentence identity, class balance, or course level. The paper also gives no headline score for a constant prediction baseline on these splits. For interpreting the best result, the class-specific report is especially important because it makes the weaker recognition of correct writing visible.

The training comparison similarly bundles more than one change. Keeping corrections repeats familiar examples, while replacing them with COCTAILL sentences both increases diversity and introduces textbook language. The paper does not compare that condition with an equally varied training set made entirely of correct learner sentences. The gain on the deduplicated tests therefore supports the package of changes actually evaluated. It cannot determine how much of the gain comes from greater variety, from the particular constructions and words in the books, or from other differences between the two sources.

The matched embedding comparisons have a related boundary. They keep the learner data and broad classifier architecture fixed, but FastText and BERT bring different dimensions, tokenization, and pretraining, and they use different learning rates in the experiment. The scores identify the better configuration for this task. They do not measure the isolated contribution of contextualization. Similarly, the high detection scores for clause changes and missing subjects support further investigation of syntactic sensitivity. Because the benchmark does not vary a targeted cue while holding others stable, those scores leave open how much the classifier uses the construction itself, along with lexical, punctuation, or other signals that tend to accompany it.

Finally, the decision the classifier makes is narrower than feedback to a learner. A correct sentence flagged by mistake could prompt an unnecessary edit. An erroneous sentence flagged accurately still needs a diagnosis before advice can be generated. The per-class results document the reliability of the flag on one test split, while the test-set comparison shows that this reliability is sensitive to the collection being evaluated. Error location, repair quality, and the usefulness of feedback remain separate empirical questions.

What came after

No later citing work is documented for this study. The paper itself sets out a progression from sentence screening to classifying the error, finding its location, and proposing a repair. In DaLAJ those stages can draw on different parts of the same annotated record. The sentence pair supplies contrasting examples for the binary decision, the correction tag describes the type of problem, and the marked expression and normalized form connect that problem to a possible change in the text.

The authors also propose testing on authentic sentences with several errors and examining the contribution of synthetic examples. The first would test whether a classifier trained on isolated problems can handle the combinations present in unedited essays. The second would change the origin of some training errors and make their effect on performance an explicit object of study. Both are directions proposed by the authors. The completed experiments establish a benchmark for sentence-level decisions on DaLAJ, with evidence about representations, training data, and test composition that can inform those further questions.

Cite

Cite as Julia Klezl, Yousuf Ali Mohammed and Elena Volodina. 2022. Exploring Linguistic Acceptability in Swedish Learners' Language. Proceedings of the 11th Workshop on NLP for Computer Assisted Language Learning.

The paper itself, not this page. BibTeX from the library's record of the work.

@inproceedings{klezl2022exploring,
  title = {{Exploring Linguistic Acceptability in Swedish Learners' Language}},
  author = {Julia Klezl, Yousuf Ali Mohammed and Elena Volodina},
  booktitle = {Proceedings of the 11th Workshop on NLP for Computer Assisted Language Learning},
  year = {2022},
  doi = {10.3384/ecp190009},
  url = {https://doi.org/10.3384/ecp190009}
}

↑ back to top

This page in Markdown https://md.research.elamur.ai/free/en/papers/klezl-2022-exploring-linguistic-acceptability-swedish-learners/