enabledCategories doesn't work

I’m running an offline server with java -cp languagetool-server.jar org.languagetool.server.HTTPServer --port 8081 --allow-origin --config ~/.languageserver.cfg. The config file points to a second config file with the following lines:


As expected:

  • “thank you much” does not produce an error
  • “abundance” does produce an error


  • “accomplish” does not produce an error despite being a rule within PLAIN_ENGLISH

Removing default="off" from the PLAIN_ENGLISH category produces the expected result.

I’m concluding that there’s a bug with enabledCategories? I’ve tried this with several categories and haven’t been able to get them to work. Can anyone reproduce this issue?

Maybe you’re mixing up the .cfg for the stand-alone/LibreOffice LT and the server configuration. The server configuration doesn’t know about enabledCategories, but it has a command-line paramater --enablecategories. There’s also the HTTP parameter enabledCategories.

If I want to enable specific categories on the server without editing the XML files, what would be the best way to do that?

You can set the enabledCategories parameter with each HTTP request you send (API doc).

In my case, I’m often accessing the server from plugins (e.g a Chrome extension) and don’t have a way to set enabled categories with each HTTP request? Are there any other options?

You could try useGUIConfig=true to make LT use the LibreOffice config file. Not sure if that actually works, though.