-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Overlapping errors cause bad suggestions #29
Comments
Actually, the errors in themselves are not overlapping, which is part of the problem: because the punctuation error is so short in terms of character length, we extend the error context to the preceding (or following word), to make the error visible in an interactive context (= blue underline in LO etc). In those contexts the whole string is replaced, including the preceding/following word, where as in the command line interface, the only string replaced is the actual error — but the replacement still contains the full context as given by the CG rules (=preceding/following word). This in practice leads to a duplication of the context word in question. |
From the json, it's obvious the indices are wrong in the second error (40–41, i.e. just one character, should be 25–41). When I look at the grammar checker output, I see one oddity: There are two error tags on the same Full output from grammar checker:
If I make them separate readings, so we have
and send it all through
|
(In this case it's fine to have several error tags on one reading, it's just about stretching the underline, but IIRC there are cases where we still need to put error tags on separate readings in CG.) |
|
The punctuation error contains the preceding work (uncorrected) as part of the cofrrection suggestion, while the spelling error corrects the same word independently. The end result - when running automically / unsupervised at least - is that the misspelled word gets duplicated. This makes automatized testing much harder.
The text was updated successfully, but these errors were encountered: