[en] false positive aggreement error

“Not that many care, but it started as a dare.”
“Many care for her.”

In both cases it should be clear that “care” is a verb, not a noun

Added to my task list.

@Mike_Unwalla, this can be fixed. I had to modify the grammar.xml.

  1. I added an <antipattern></antipattern> to an existing rule.

  2. I added a second rule for “many care”.
    Here is the code. It’s around line no. 10193 in my setup.

     <rule id="MANY_NN" name="Possible agreement error: 'many/several/few' + singular countable noun">
         <antipattern case_sensitive="yes">
             <token>Many</token>
             <token postag="VBP"/>
         </antipattern>
         <antipattern>
             <token>many</token>
             <token>regard</token>
             <token regexp="yes">him|her|it|this|them|his|its</token>
         </antipattern>
         <antipattern>
             <token>a</token>
             <token>few</token>
             <token/>
             <token>as</token>
         </antipattern>
         <antipattern>
             <token regexp="yes">many|several|few</token>
             <token>care</token>
         </antipattern>
         <pattern>
             <marker>
                 <token regexp="yes">many|several|few</token>
                 <token postag="NN:UN|NN|NNP" postag_regexp="yes"><exception postag="NN:U|NNS|NNPS|JJ.*|MD|CC|VBG" postag_regexp="yes"/><exception inflected="yes">be</exception></token>
             </marker>
             <token><exception postag="NN.*|JJ.*" postag_regexp="yes"/><exception regexp="yes">['’]</exception></token>
         </pattern>
         <message>Possible agreement error. The noun <match no="2"/> seems to be countable; consider using: <suggestion><match no="1"/> <match suppress_misspelled="yes" no="2" postag="NNS|NNPS" postag_regexp="yes"/></suggestion>.</message>
         <short>Grammatical problem</short>
         <example correction="several books">I have <marker>several book</marker>.</example>
         <example>I have <marker>many books</marker>.</example>
         <example>I have <marker>much wine</marker>.</example>
         <example correction="many ways">... which is right in <marker>many way</marker>.</example>
         <example>The state legislature gerrymandered the few Birmingham legislative seats.</example>
         <example>A few work as technical writers, others don't.</example>
     </rule>
     <rule id="MANY_CARE" name="Possible agreement error: 'many/several/few' + verb addressing present simple tense">
         <antipattern>
             <token regexp="yes">many|several|few</token>
             <token>care</token>
         </antipattern>
         <pattern>
           <marker>
             <token regexp="yes">many|several|few</token>
             <token>cares</token>
           </marker>
         </pattern>
         <message>Did you mean: <suggestion><match no="1"/> care</suggestion>? The word 'care' is a verb addressing present simple tense, '<match no="1"/>' is addressing 3rd person plural.</message>
         <short>Possible Grammatical error.</short>
         <example correction='Many care'><marker>Many cares</marker> for her.</example>
         <example>Many care for her.</example>
         <example correction='many care'>Not that <marker>many cares</marker>, but it started as a dare.</example>
         <example>Not that many care, but it started as a dare.</example>
     </rule>
    

It has been fixed at least on my machine. Please consider rechecking this code before publishing.

1 Like

@SkyCharger001,

I added your examples to rule MANY_NN (https://github.com/languagetool-org/languagetool/commit/86a9b310de4126c17a3fcb332428019e0a9a7485) so that we have a record of the problem. I also added counter-examples which show that the proposed rule MANY_CARE is not sufficient, and thus I did not add that rule.