divvun / libdivvun

lib for running gramcheck and other pipelines + cli; modules for CG→spelling, CG→feedback, tagging blanks
https://giellalt.github.io/proof/gramcheck/GrammarCheckerDocumentation.html
GNU General Public License v3.0
9 stars 1 forks source link

Defults are not shown in Words list of errors #80

Open ilm024 opened 2 months ago

ilm024 commented 2 months ago

In the SMJ errors.sources-xml document some of the errors are defaults:

<errors>

  <defaults>

    <default type="Numphrase error">
      <ids>
        <re v="msyn-numphrase-.*"/>
      </ids>
      <header>
        <title xml:lang="en">Numphrase error</title>
        <title xml:lang="smj">Tállabáhkovihke</title>
      </header>
      <body>
        <description xml:lang="en">The numphrase is incorrect, it dosn't follow agreement rules.</description>
        <description xml:lang="smj">Dån la tjállám vigev tállabáhkogihpon</description>
      </body>
    </default>

    <default type="Adjective error">
      <ids>
        <re v="syn-attr-pr.*"/>
      </ids>
      <header>
        <title xml:lang="en">Adjective should be predicative</title>
        <title xml:lang="smj">Adjektijvva galggá predikatijva hámen</title>
      </header>
      <body>
        <description xml:lang="en">The adjective "$1" should have the predicative instead of the attributive form.</description>
        <description xml:lang="smj">Adjektijvva "$1" l attributijva hámen, galggá predikatijva hámen.</description>
      </body>
    </default>

    <default type="Soajttet error">
      <ids>
        <re v="msyn-soajtta.*"/>
      </ids>
      <header>
        <title xml:lang="en">"Soajttet" error</title>
        <title xml:lang="smj">"Soajttet" la boasstot aneduvvam</title>
      </header>
      <body>
        <description xml:lang="en">"Soajttet" is a modal verb, and must be used as one.</description>
        <description xml:lang="smj">"Soajttet" la modála viehkkeværbba, ja doajmmá dagu "máhttet" ja "vierttit".</description>
      </body>
    </default>

</defaults> 

  <error id="msyn-dimin-after-unna">
    <header>
      <title xml:lang="en">Diminutive</title>
      <title xml:lang="smj">Diminutijvva</title>
    </header>
    <body>
      <description xml:lang="en">The word "$1" should be diminutive.</description>
      <description xml:lang="smj">Hiehpá adnet "$1" bágov diminutijva hámen.</description>
    </body>
  </error>

All default errors are missing in list of errors in word (see picture). What is wrong?

Skjermbilde 2024-10-01 kl  13 57 07

(PS. A few minutes ago I changed some punctuations errors into defaults, so they do appear in word even thou they are defaults in the check in file)

unhammer commented 2 months ago

@snomos veit du om word-pluginen bruker errors.xml direkte? (ev. veit du kven som veit kva den gjer?) I så fall er det word-pluginen som må støtta defaults.

snomos commented 2 months ago

Word-pluggen bruker ikkje errors.xml direkte, han spør grammatikkontrollen (via the API server - API documentation) om kva som finst tilgjengeleg. Dvs at det er info frå libdivvun som bestemmer kva som blir vist.