Fedimeister uses Hunspell as its spellchecking engine. The software comes bundled with its own version of the library, but without any dictionaries.

Obtaining (additional) dictionaries

If your system comes with either Hunspell or Open Office already installed, Fedimeister will automatically detect and uses the dictionaries of those software packages. Otherwise you need to manually download and place the dictionary files of your desired language in the 🖿dict/ directory.

A dictionary always consists of two files, one containing word stems, the other affixes, both are named by iso language and country code. For example, german speaking swiss users would need 🗋 de_CH.dic and 🗋 de_CH.aff .

Overriding autodetected paths

In some cases, it may be desirable to use a different version of the hunspell library, or a different set of dictionaries. The default location, in which Fedimeister looks for them can be specified by the hunspell.native and hunspell.dictionaries system property respectively:

java -Dhunspell.libary="/tmp/libhunspell.so" -Dhunspell.dictionaries="/tmp/dict" -jar fedimeister.jar

Testing the spellchecker from the commandline

To test, if library and dictionaries are correctly installed and detected by Fedimeister, you use the --sc-diag command line tool.

java-jar fedimeister.jar helo world

The output should look similar to

Native library:

System language:

Dictionary path:

  [*] en_US
  [ ] de_CH
  [ ] en_ZA
  [ ] de_AT
  [ ] en_AU
  [ ] de_LU
  [ ] de_DE
  [ ] en_CA
  [ ] en_GB

Dictionary encoding:

Spellchecking test:
  [-] helo
      hole, help, helot, hello, halo, hero, hell, held, helm, he lo, he-lo
  [+] world

Building Hunspell from source

Fedimeister requires a patched version of the Hunspell library. Compile it according to the following instructions:

tar -zxf hunspell-1.7.2.tar.gz
cd hunspell-1.7.2
patch -p1 < ../hunspelljavabindings.patch
./configure  CXXFLAGS="-I$JAVA_HOME/include -I$JAVA_HOME/include/linux"