opennlp.tools.sentdetect
Class SentenceModel

java.lang.Object
  extended by opennlp.tools.util.model.BaseModel
      extended by opennlp.tools.sentdetect.SentenceModel
All Implemented Interfaces:
ArtifactProvider

public class SentenceModel
extends BaseModel

The SentenceModel is the model used by a learnable SentenceDetector.

See Also:
SentenceDetectorME

Field Summary
 
Fields inherited from class opennlp.tools.util.model.BaseModel
TRAINING_CUTOFF_PROPERTY, TRAINING_EVENTHASH_PROPERTY, TRAINING_ITERATIONS_PROPERTY
 
Constructor Summary
SentenceModel(File modelFile)
           
SentenceModel(InputStream in)
           
SentenceModel(String languageCode, opennlp.model.AbstractModel sentModel, boolean useTokenEnd, Dictionary abbreviations)
           
SentenceModel(String languageCode, opennlp.model.AbstractModel sentModel, boolean useTokenEnd, Dictionary abbreviations, char[] eosCharacters)
          Deprecated. Use SentenceModel(String, AbstractModel, Map, SentenceDetectorFactory) instead and pass in a SentenceDetectorFactory
SentenceModel(String languageCode, opennlp.model.AbstractModel sentModel, boolean useTokenEnd, Dictionary abbreviations, char[] eosCharacters, Map<String,String> manifestInfoEntries)
          Deprecated. Use SentenceModel(String, AbstractModel, Map, SentenceDetectorFactory) instead and pass in a SentenceDetectorFactory
SentenceModel(String languageCode, opennlp.model.AbstractModel sentModel, boolean useTokenEnd, Dictionary abbreviations, Map<String,String> manifestInfoEntries)
           
SentenceModel(String languageCode, opennlp.model.AbstractModel sentModel, Map<String,String> manifestInfoEntries, SentenceDetectorFactory sdFactory)
           
SentenceModel(URL modelURL)
           
 
Method Summary
 Dictionary getAbbreviations()
           
 char[] getEosCharacters()
           
 SentenceDetectorFactory getFactory()
           
 opennlp.model.AbstractModel getMaxentModel()
           
static void main(String[] args)
           
 boolean useTokenEnd()
           
 
Methods inherited from class opennlp.tools.util.model.BaseModel
getArtifact, getLanguage, getManifestProperty, getVersion, isLoadedFromSerialized, serialize
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SentenceModel

public SentenceModel(String languageCode,
                     opennlp.model.AbstractModel sentModel,
                     Map<String,String> manifestInfoEntries,
                     SentenceDetectorFactory sdFactory)

SentenceModel

public SentenceModel(String languageCode,
                     opennlp.model.AbstractModel sentModel,
                     boolean useTokenEnd,
                     Dictionary abbreviations,
                     char[] eosCharacters,
                     Map<String,String> manifestInfoEntries)
Deprecated. Use SentenceModel(String, AbstractModel, Map, SentenceDetectorFactory) instead and pass in a SentenceDetectorFactory

TODO: was added in 1.5.3 -> remove


SentenceModel

public SentenceModel(String languageCode,
                     opennlp.model.AbstractModel sentModel,
                     boolean useTokenEnd,
                     Dictionary abbreviations,
                     char[] eosCharacters)
Deprecated. Use SentenceModel(String, AbstractModel, Map, SentenceDetectorFactory) instead and pass in a SentenceDetectorFactory

TODO: was added in 1.5.3 -> remove


SentenceModel

public SentenceModel(String languageCode,
                     opennlp.model.AbstractModel sentModel,
                     boolean useTokenEnd,
                     Dictionary abbreviations,
                     Map<String,String> manifestInfoEntries)

SentenceModel

public SentenceModel(String languageCode,
                     opennlp.model.AbstractModel sentModel,
                     boolean useTokenEnd,
                     Dictionary abbreviations)

SentenceModel

public SentenceModel(InputStream in)
              throws IOException,
                     InvalidFormatException
Throws:
IOException
InvalidFormatException

SentenceModel

public SentenceModel(File modelFile)
              throws IOException,
                     InvalidFormatException
Throws:
IOException
InvalidFormatException

SentenceModel

public SentenceModel(URL modelURL)
              throws IOException,
                     InvalidFormatException
Throws:
IOException
InvalidFormatException
Method Detail

getFactory

public SentenceDetectorFactory getFactory()

getMaxentModel

public opennlp.model.AbstractModel getMaxentModel()

getAbbreviations

public Dictionary getAbbreviations()

useTokenEnd

public boolean useTokenEnd()

getEosCharacters

public char[] getEosCharacters()

main

public static void main(String[] args)
                 throws FileNotFoundException,
                        IOException,
                        InvalidFormatException
Throws:
FileNotFoundException
IOException
InvalidFormatException


Copyright © 2013 The Apache Software Foundation. All Rights Reserved.