Class MorphoAnalysis

java.lang.Object
com.basistech.rosette.dm.BaseAttribute
com.basistech.rosette.dm.MorphoAnalysis
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
ArabicMorphoAnalysis, HanMorphoAnalysis, KoreanMorphoAnalysis

public class MorphoAnalysis extends BaseAttribute implements Serializable
A MorphoAnalysis contains all the results of analyzing a word, or something like a word. This data model assumes that, presented with a token, an analyzer will produce one or more analyses, where each analysis is a coordinated collection of attributes. The simplest example is a part-of-speech tag and a lemma, but some languages yield more data.
This one class contains the basic attributes that are more or less common to the languages supported by Rosette Base Linguistics. There are subclasses for some specific languages.
In some languages, words are decompounded into pieces that can, themselves, be analyzed.
See Also:
  • Constructor Details

    • MorphoAnalysis

      protected MorphoAnalysis(String partOfSpeech, String lemma, List<Token> components, String raw, TagSet tagSet, Map<String,Object> extendedProperties)
      Creates an analysis.
      Parameters:
      partOfSpeech - part-of-speech
      lemma - the lemma
      components - compound components
      raw - raw analysis
      tagSet - the tag set
      extendedProperties - extended properties
    • MorphoAnalysis

      protected MorphoAnalysis(String partOfSpeech, String lemma, List<Token> components, String raw, Map<String,Object> extendedProperties)
      Creates an analysis.
      Parameters:
      partOfSpeech - part-of-speech
      lemma - the lemma
      components - compound components
      raw - raw analysis
      extendedProperties - extended properties
  • Method Details

    • getPartOfSpeech

      public String getPartOfSpeech()
      Returns the part-of-speech.
      Returns:
      the part-of-speech
    • getLemma

      public String getLemma()
      Returns the lemma.
      Returns:
      the lemma
    • getComponents

      public List<Token> getComponents()
      Returns the compound components.
      Returns:
      the compound components
    • getRaw

      public String getRaw()
      Returns the raw analysis. The raw analysis is a language and analyzer-specific string, typically used to convey debug-level information. Applications should usually not depend on the raw analysis.
      Returns:
      the raw analysis
    • getTagSet

      public TagSet getTagSet()
      Returns the tag set.
      Returns:
      the tag set
    • toStringHelper

      protected com.google.common.base.MoreObjects.ToStringHelper toStringHelper()
      Overrides:
      toStringHelper in class BaseAttribute
    • toString

      public String toString()
      Overrides:
      toString in class BaseAttribute