Class SentenceContextGenerator

java.lang.Object
opennlp.tools.sentdetect.DefaultSDContextGenerator
opennlp.tools.sentdetect.lang.th.SentenceContextGenerator
All Implemented Interfaces:
SDContextGenerator

public class SentenceContextGenerator extends DefaultSDContextGenerator
Creates contexts/features for end-of-sentence detection in Thai text.
  • Field Details

    • eosCharacters

      public static final char[] eosCharacters
  • Constructor Details

    • SentenceContextGenerator

      public SentenceContextGenerator()
  • Method Details

    • collectFeatures

      protected void collectFeatures(String prefix, String suffix, String previous, String next, Character eosChar)
      Description copied from class: DefaultSDContextGenerator
      Determines some features for the sentence detector and adds them to list features.
      Overrides:
      collectFeatures in class DefaultSDContextGenerator
      Parameters:
      prefix - String preceding the eosChar in the eos token.
      suffix - String following the eosChar in the eos token.
      previous - Space delimited token preceding token containing eosChar.
      next - Space delimited token following token containing eosChar.
      eosChar - the EOS character been analyzed.