Class MorfologikLemmatizer

java.lang.Object
opennlp.morfologik.lemmatizer.MorfologikLemmatizer
All Implemented Interfaces:
opennlp.tools.lemmatizer.Lemmatizer

public class MorfologikLemmatizer extends Object implements opennlp.tools.lemmatizer.Lemmatizer
A Lemmatizer implementation based on Morfologik binary dictionaries
  • Constructor Details

    • MorfologikLemmatizer

      public MorfologikLemmatizer(Path dictionaryPath) throws IOException
      Initializes a MorfologikLemmatizer and related Dictionary from the input tab separated dictionary.
      Parameters:
      dictionaryPath - The dictionary referenced via a valid, readable Path.
      Throws:
      IOException - Thrown if IO errors occurred while reading in from dictionaryPath.
    • MorfologikLemmatizer

      public MorfologikLemmatizer(morfologik.stemming.Dictionary dictionary)
      Initializes a MorfologikLemmatizer and related Dictionary from the input tab separated dictionary.
      Parameters:
      dictionary - The Dictionary to be used.
  • Method Details

    • lemmatize

      public String[] lemmatize(String[] toks, String[] tags)
      Specified by:
      lemmatize in interface opennlp.tools.lemmatizer.Lemmatizer
    • lemmatize

      public List<List<String>> lemmatize(List<String> toks, List<String> tags)
      Specified by:
      lemmatize in interface opennlp.tools.lemmatizer.Lemmatizer