IP Library Granted Patent US 12,626,072
Granted Patent B2
US 12,626,072 · App. 17/304,202 · Granted May 12, 2026

Multilingual grammatical error correction

Inventors: Sebastian Krause (Zurich, CH); Sascha Rothe (Zurich, CH); Jonathan Mallinson (Zurich, CH); Eric Malmi (Zurich, CH); Aliaksei Severyn (Zurich, CH)
Assignee: Google LLC
G06F40/58G06F40/253
View Patent ↗
Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US 12,626,072
App. No.
17/304,202
Filed
Jun 16, 2021
Granted
May 12, 2026
Kind
B2
Examiner
WONG, LINDA
Art Unit
2655
USPC
704/9
Abstract

A method of training a text-generating model for grammatical error correction (GEC) includes obtaining a multilingual set of text samples where each text sample includes a monolingual textual representation of a respective sentence. The operations also include, for each text sample of the multilingual set of text samples, generating a corrupted synthetic version of the respective text sample where the corrupted synthetic version of the respective text sample includes a grammatical change to the monolingual textual representation of the respective sentence associated with the respective text sample. The operations further include training the text-generating model using a training set of sample pairs. Each sample pair in the training set of sample pairs includes one of the respective text samples of the multilingual set of text samples and the corresponding corrupted synthetic version of the one of the respective text samples of the multilingual set of text samples.

Claims (46)

1 . A computer-implemented method of training a text-generating model for grammatical error correction (GEC), the method when executed by data processing hardware causes the data processing hardware to perform operations comprising:

obtaining a multilingual set of grammatically correct text samples, each grammatically correct text sample comprising a monolingual textual representation of a respective sentence;

for each grammatically correct text sample of the multilingual set of grammatically correct text samples, generating a corrupted synthetic ungrammatical text version of the respective grammatically correct text sample by making a grammatical change to the monolingual textual representation of the respective sentence associated with the respective grammatically correct text sample, wherein the grammatical change is made to the monolingual textual representation of the respective sentence associated with the respective grammatically correct text sample without using a dictionary that is specific to a language of the monolingual textual representation of the respective segment such that the grammatical change made to the monolingual textual representation of the respective sentence is agnostic to the language of the monolingual textual representation of the respective sentence; and

training the text-generating model using a training set of sample pairs, each sample pair in the training set of sample pairs comprising:

one of the respective grammatically correct text samples of the multilingual set of grammatically correct text samples; and

the corresponding corrupted synthetic ungrammatical text version of the one of the respective grammatically correct text samples of the multilingual set of grammatically correct text samples.

2 . The method of claim 1 , wherein the operations further comprise, after training the text-generating model, fine-tuning the trained text-generating model using supervised training data, the supervised training data comprising non-synthetic text pairs, each non-synthetic text pair comprising an ungrammatical text sample and a grammatical text version of the ungrammatical text sample.

3 . The method of claim 1 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises removing more than one character from the respective sentence associated with the respective grammatically correct text sample.

4 . The method of claim 1 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises replacing a first set of characters from the respective sentence associated with the respective grammatically correct text sample with a second set of characters different from the first set of characters.

5 . The method of claim 1 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises inserting one or more characters into the respective sentence associated with the respective grammatically correct text sample.

6 . The method of claim 1 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises changing a character-case for a character of a word of the respective sentence associated with the respective grammatically correct text sample.

7 . The method of claim 1 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises randomly applying a corruption operation to the respective sentence associated with the respective grammatically correct text sample, the corruption operation comprising at least one of:

removing more than one characters from the respective sentence associated with the respective grammatically correct text sample;

replacing a first set of characters from the respective sentence associated with the respective grammatically correct text sample with a second set of characters different from the first set of characters;

inserting one or more characters into the respective sentence associated with the respective grammatically correct text sample; or

changing a character-case of a word of the respective sentence associated with the respective grammatically correct text sample,

wherein each corrupted synthetic ungrammatical text version is unique with respect to the other corrupted synthetic ungrammatical text versions of the text samples.

8 . The method of claim 1 , wherein the text-generating model comprises a transformer encoder-decoder architecture.

9 . The method of claim 1 , wherein the operations further comprise pre-training the text-generating model with a multilingual training corpus based on a masked-language objective.

10 . The method of claim 1 , wherein after training the text-generating model for GEC, the trained text-generating model is configured to:

receive, as input, a first input text in a first language that includes grammatical errors and generate, as output, a first output text in the first language that corrects the grammatical errors; and

receiving, as input, a second input text in a different second language that includes grammatical errors and generate, as output from the trained text-generating model, a second output text in the second language that corrects the grammatical errors.

11 . A system comprising:

data processing hardware; and

memory hardware in communication with the data processing hardware, the memory hardware storing instructions that when executed on the data processing hardware cause the data processing hardware to perform operations comprising:

obtaining a multilingual set of grammatically correct text samples, each grammatically correct text sample comprising a monolingual textual representation of a respective sentence;

for each grammatically correct text sample of the multilingual set of grammatically correct text samples, generating a corrupted synthetic ungrammatical text version of the respective grammatically correct text sample by making a grammatical change to the monolingual textual representation of the respective sentence associated with the respective grammatically correct text sample, wherein the grammatical change is made to the monolingual textual representation of the respective sentence associated with the respective grammatically correct text sample without using a dictionary that is specific to a language of the monolingual textual representation of the respective segment such that the grammatical change made to the monolingual textual representation of the respective sentence is agnostic to the language of the monolingual textual representation of the respective sentence; and

training the text-generating model using a training set of sample pairs, each sample pair in the training set of sample pairs comprising:

one of the respective grammatically correct text samples of the multilingual set of grammatically correct text samples; and

the corresponding corrupted synthetic ungrammatical text version of the one of the respective grammatically correct text samples of the multilingual set of grammatically correct text samples.

12 . The system of claim 11 , wherein the operations further comprise, after training the text-generating model, fine-tuning the trained text-generating model using supervised training data, the supervised training data comprising non-synthetic text pairs, each non-synthetic text pair comprising an ungrammatical text sample and a grammatical text version of the ungrammatical text sample.

13 . The system of claim 11 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises removing more than one characters from the respective sentence associated with the respective grammatically correct text sample.

14 . The system of claim 11 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises replacing a first set of characters from the respective sentence associated with the respective grammatically correct text sample with a second set of characters different from the first set of characters.

15 . The system of claim 11 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises inserting one or more characters into the respective sentence associated with the respective grammatically correct text sample.

16 . The system of claim 11 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises changing a character-case for a character of a word of the respective sentence associated with the respective grammatically correct text sample.

17 . The system of claim 11 , wherein generating the corrupted synthetic ungrammatical text version of the respective grammatically correct text sample comprises randomly applying a corruption operation to the respective sentence associated with the respective grammatically correct text sample, the corruption operation comprising at least one of:

removing more than one characters from the respective sentence associated with the respective grammatically correct text sample;

replacing a first set of characters from the respective sentence associated with the respective grammatically correct text sample with a second set of characters different from the first set of characters;

inserting one or more characters into the respective sentence associated with the respective grammatically correct text sample; or

changing a character-case of a word of the respective sentence associated with the respective grammatically correct text sample,

wherein each corrupted synthetic ungrammatical text version is unique with respect to the other corrupted synthetic ungrammatical text versions of the text samples.

18 . The system of claim 11 , wherein the text-generating model comprises a transformer encoder-decoder architecture.

19 . The system of claim 11 , wherein the operations further comprise pre-training the text-generating model with a multilingual training corpus based on a masked-language objective.

20 . The system of claim 11 , wherein after training the text-generating model for GEC, the trained text-generating model is configured to:

receive, as input, a first input text in a first language that includes grammatical errors and generate, as output, a first output text in the first language that corrects the grammatical errors; and

receiving, as input, a second input text in a different second language that includes grammatical errors and generate, as output from the trained text-generating model, a second output text in the second language that corrects the grammatical errors.

Assignments (1)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jun 29, 2021
From: ROTHE, SASCHA; MALLINSON, JONATHAN; MALMI, ERIC; KRAUSE, SEBASTIAN; SEVERYN, ALIAKSEI
To: GOOGLE LLC
Reel/Frame 056701/0956 →
Continuity (1)
Related Publication 20220405490A1 · Dec 22, 2022
References Cited (19)
US 5535121A · Roche · 1996 [cited by examiner]
US 11361170B1 · Shastry · 2022 [cited by examiner]
US 20210271810A1 · Nadejde · 2021 [cited by examiner]
US 20220019737A1 · Choi · 2022 [cited by examiner]
JP 201916140A · 2019 [cited by applicant]
JP 2019197336A · 2019 [cited by applicant]
Wang Q, Tan Y. Grammatical error detection with self attention by pairwise training. In 2020 International Joint Conference on Neural Networks (IJCNN) Jul. 19, 2020 (pp. 1-7). IEEE. (Year: 2020). [cited by examiner]
Yamashita I, Katsumata S, Kaneko M, Imankulova A, Komachi M. Cross-lingual transfer learning for grammatical error correction. In Proceedings of the 28th International Conference on Computational Linguistics Dec. 2020 (… [cited by examiner]
Yang L, Wang C, Chen Y, Du Y, Yang E. Controllable Data Synthesis Method for Grammatical Error Correction. arXiv preprint arXiv:1909.13302. Sep. 29, 2019. (Year: 2019). [cited by examiner]
https://www.comp.nus.edu.sg/˜nlp/corpora.html (Year: 2013). [cited by examiner]
Náplava J, Straka M. Grammatical error correction in low-resource scenarios. arXiv preprint arXiv:1910.00353. Oct. 1, 2019. (Year: 2019). [cited by examiner]
Chan et al, Grammatical Error Correction for Code-Switched Sentences by Learners of English, Apr. 18, 2024, https://arxiv.org/abs/2404.12489v1 (Year: 2024). [cited by examiner]
International Search Report and Written Opinion for the related Application No. PCT/US2022/072965, dated Sep. 2, 2022, 67 pages. [cited by applicant]
Yamashita Ikumi et al: “Cross-lingual Transfer Learning for Grammatical Error Correction”, Proceedings of the 28th International Conference on Computational Linguistics, Dec. 13, 2020 (Dec. 13, 2020), pp. 4704-4715, XP0… [cited by applicant]
Satoru Katsumata et al: “Stronger Baselines for Grammatical Error Correction Using Pretrained Encoder-Decoder Model”, arxiv.org, Cornell University Library, 201 Olin Library Cornell University Ithaca, NY 14853, May 25, … [cited by applicant]
Felix Stahlberg et al: “Synthetic Data Generation for Grammatical Error Correction with Tagged Corruption Models”, arx:cv.org, Cornell University Library, 201 Olin Library Cornell University Ithaca, NY, 14853, May 27, 2… [cited by applicant]
Elizaveta Korotkova et al: “Grammatical Error Correction and Style Transfer via Zero-shot Monolingual Translation”, arxiv.org, Cornell University Library, 201 Olin Library Cornell University Ithaca, NY 14853, Mar. 27, 2… [cited by applicant]
Wangchunshu Zhou et al: “Improving Grammatical Error Correction with Machine Translation Pairs”, arxiv.org, Cornell University Library, 201 Olin Library Cornell University Ithaca, NY 14853, Nov. 7, 2019 (Nov. 7, 2019), … [cited by applicant]
Office Action issued in related Japanese Patent Application No. 2023-577753, dated Apr. 8, 2025. [cited by applicant]