edu.stanford.nlp.pipeline
Class WordsToSentencesAnnotator
java.lang.Object
edu.stanford.nlp.pipeline.WordsToSentencesAnnotator
- All Implemented Interfaces:
- Annotator
public class WordsToSentencesAnnotator
- extends java.lang.Object
- implements Annotator
This class assumes that there is either a
List<? extends CoreLabel> under the
TokensAnnotation field, and runs it
through WordToSentenceProcessor and
puts the new List<List<? extends CoreLabel>>
(it is now definitely a
List<List<? extends CoreLabel>>) back under
the Annotation.WORDS_KEY field.
- Author:
- Jenny Finkel
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
WordsToSentencesAnnotator
public WordsToSentencesAnnotator()
WordsToSentencesAnnotator
public WordsToSentencesAnnotator(boolean verbose)
newlineSplitter
public static WordsToSentencesAnnotator newlineSplitter(boolean verbose,
java.lang.String... nlToken)
setSentenceBoundaryToDiscard
public void setSentenceBoundaryToDiscard(java.util.Set<java.lang.String> boundaries)
addHtmlSentenceBoundaryToDiscard
public void addHtmlSentenceBoundaryToDiscard(java.util.Set<java.lang.String> boundaries)
setOneSentence
public void setOneSentence(boolean isOneSentence)
annotate
public void annotate(Annotation annotation)
- Specified by:
annotate in interface Annotator
Stanford NLP Group