Class DefaultSDContextGenerator
java.lang.Object
opennlp.tools.sentdetect.DefaultSDContextGenerator
- All Implemented Interfaces:
opennlp.tools.sentdetect.SDContextGenerator
- Direct Known Subclasses:
SentenceContextGenerator
public class DefaultSDContextGenerator
extends Object
implements opennlp.tools.sentdetect.SDContextGenerator
Generate event contexts for maxent decisions for sentence detection.
-
Constructor Summary
ConstructorsConstructorDescriptionDefaultSDContextGenerator(char[] eosCharacters) Creates a new instance with no induced abbreviations.DefaultSDContextGenerator(Set<String> inducedAbbreviations, char[] eosCharacters) Creates a newSDContextGeneratorinstance which uses the set of induced abbreviations. -
Method Summary
-
Constructor Details
-
DefaultSDContextGenerator
public DefaultSDContextGenerator(char[] eosCharacters) Creates a new instance with no induced abbreviations.- Parameters:
eosCharacters- The characters to be used to detect sentence endings.
-
DefaultSDContextGenerator
Creates a newSDContextGeneratorinstance which uses the set of induced abbreviations.- Parameters:
inducedAbbreviations- aSetof Strings representing induced abbreviations in the training data. Example: "Mr."eosCharacters- The characters to be used to detect sentence endings.
-
-
Method Details
-
getContext
- Specified by:
getContextin interfaceopennlp.tools.sentdetect.SDContextGenerator
-