Hello!

I was making some tests and it seems that in the suggestion it simply removes the last "s".

This means it won't work with special nouns such as:
flor -> flores
cão -> cães

Is there a way of replacing:
*<message>Erro de concordância do plural: <suggestion><match no="2" regexp_match="(.*)(s)" regexp_replace="$1"/></suggestion></message>*
with just saying: "use plural" or "use singular" in the suggestion?

Thanks!

Kind regards,
     >Marco A.G.Pinto
       -----------------------

On 17/01/2016 19:04, Marco A.G.Pinto wrote:
Yakov,

It has worked!

Thanks!

What if I want to do the opposite now?:
"As vaca comem no pasto"
to
"As vacas comem no pasto"

What should I write in:
<message>Erro de concordância do plural: <suggestion><match no="2" regexp_match="(.*)(s)" regexp_replace="$1"/></suggestion></message>

Thanks!

If all goes well, tonight I will release these rules, which are very important.
noun singular -> noun plural
noun plural -> noun singular

Two rules for female PLUS two rules for male ( A + AS) (O + OS).

Thank you very much!

Kind regards from your friend,
        >Marco A.G.Pinto
          -----------------------


On 17/01/2016 18:32, Yakov Reztsov wrote:
Hello,
I tested this rule on community.languagetool.org, and it no display any error.
But *TESTRULES PT* displays error if <suggestion> is not specified.

That is full example:


<!-- Concordance error plural - A + FEMALE PLURAL + SINGULAR VERB -->
<rule id="A_FEMALE-PLURAL_SINGULAR-VERB" name="Erro de concordância do plural A + FEMALE PLURAL + SINGULAR VERB">
      <pattern>
        <token>a</token>
        <marker>
            <token postag="NCFP000"></token>
         </marker>
         <token postag="VMIP3S0"></token>
     </pattern>
<message>Erro de concordância do plural: <suggestion><match no="2" regexp_match="(.*)(s)" regexp_replace="$1"/></suggestion></message> <example correction='vaca'>A <marker>vacas</marker> come no pasto.</example>
    </rule>


    Воскресенье, 17 января 2016, 12:26 UTC от "Marco A.G.Pinto" :

    Hello!

    I was messaging Yakov in private but decided to send it to the ML
    with more details.

    I was trying to create the following rule:
    "A vacas come no pasto"

    So that it would suggest:
    "A vaca come no pasto"

    "vacas" is a female plural noun and the error is to tell people
    to change the noun to singular "vaca" because it has a "a"
    (singular) before and a 3rd person singular verb after it.

    But, it must work with all female nouns, thus the *<token
    postag="NCFP000"></token>* .

    There must a way of highlighting the plural noun and tell people
    to change it to singular.



    This is what I am trying to do.

    Based on this rule, I can then create other kind of important rules.

    The rule gives an error with *TESTRULES PT*:

        <!-- Concordance error plural - A + FEMALE PLURAL + SINGULAR
    VERB -->
        <rule id="A_FEMALE-PLURAL_SINGULAR-VERB" name="Erro de
    concordância do plural A + FEMALE PLURAL + SINGULAR VERB">
          <pattern>
            <token>a</token>
            <marker>
                <token postag="NCFP000"></token>
             </marker>
             <token postag="VMIP3S0"></token>
         </pattern>
         <message>Erro de concordância do plural.</message>
         <example>A <marker>vaca</marker> come no pasto.</example>
        </rule>


    How can I fix it?

    Thanks!

    Kind regards,
           >Marco A.G.Pinto
              ----------------------

--

--

Yakov Reztsov

--


--
------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
_______________________________________________
Languagetool-devel mailing list
Languagetool-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/languagetool-devel

Reply via email to