Skip to content
Mika Hämäläinen edited this page Feb 1, 2018 · 9 revisions

What models are there?

UralicNLP can currently use three different kinds of models: HFST morphological generator, HFST morphological analyser and constraint grammar disambiguator. The HFST models are available for all the supported languages, while the CGs are limited to only a few languages.

Downloading models

from uralicNLP import uralicApi
uralicApi.download("fin")

The above snippet downloads all the models for Finnish. Run with sudo privileges for a system wide installation.

Where are models located?

from uralicNLP import uralicApi
print uralicApi.__model_base_folders()

Gives you the list of the possible locations for the models. If you want to create your own models, just create a subdirectory in any of these locations by the three letter language code of your language. Name your models as generator, analyser and cg without file extensions.

Clone this wiki locally