languagetool-org / languagetool

Style and Grammar Checker for 25+ Languages
https://languagetool.org
GNU Lesser General Public License v2.1
12.29k stars 1.39k forks source link

Phrases aren't matched by rules unless they are the provided example sentences #10668

Open BadgerInATrenchcoat opened 3 months ago

BadgerInATrenchcoat commented 3 months ago

I searched through the LanguageTool issues and didn't see any about this, but with more than 1,900 open issues and 3,900 closed issues it is certainly possible I missed something. If this is a duplicate issue, feel free to let me know.

Expected behavior: Common writing mistakes--like subject-verb agreement errors--that are in the LanguageTool rules database are caught and brought to the attention of the user.

Actual Behavior: Sentences/phrases are not matched to rules unless they are nearly identical in word-choice and structure to the examples provided on the rule database page. For example, in the instance of subject-verb agreement, I have included screenshots below to illustrate this issue. The example sentence is matched by both the in-documentation checker and my self-hosted LanguageTool instance with configured ngrams. However, my similarly structured but differently worded--and still incorrect--sentence is not matched by either the in-documentation checker, the LanguageTool website, or my personal LanguageTool instance.

image

image

Discostu36 commented 3 months ago

Please write issues about specific errors that are not found, not about your general impression of the quality of the error checking.

It is generally very difficult to write grammar / agreement error rules that don't produce many false positives. So, yes, it is often the case that the errors are only found if they are very similar to the example sentences, because of antipatterns that are in place to prevent false positives.

About your example: "roll" can also be a noun, that might be the reason your error is not found, to prevent false positives for compounds like "hot dog roll".