edu.stanford.nlp.pipeline
Class WordsToSentencesAnnotator

java.lang.Object
  extended by 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

Constructor Summary
WordsToSentencesAnnotator()
           
WordsToSentencesAnnotator(boolean verbose)
           
 
Method Summary
 void addHtmlSentenceBoundaryToDiscard(java.util.Set<java.lang.String> boundaries)
           
 void annotate(Annotation annotation)
           
static WordsToSentencesAnnotator newlineSplitter(boolean verbose, java.lang.String... nlToken)
           
 void setOneSentence(boolean isOneSentence)
           
 void setSentenceBoundaryToDiscard(java.util.Set<java.lang.String> boundaries)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WordsToSentencesAnnotator

public WordsToSentencesAnnotator()

WordsToSentencesAnnotator

public WordsToSentencesAnnotator(boolean verbose)
Method Detail

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