/**
  * Creates a uima sentence iterator with the given path
  *
  * @param path the path to the root directory or file to read from
  * @return the uima sentence iterator for the given root dir or file
  * @throws Exception
  */
 public static SentenceIterator createWithPath(String path) throws Exception {
   return new UimaSentenceIterator(
       path,
       new UimaResource(
           AnalysisEngineFactory.createEngine(
               AnalysisEngineFactory.createEngineDescription(
                   TokenizerAnnotator.getDescription(), SentenceAnnotator.getDescription()))));
 }
 public static AnalysisEngine defaultAnalysisEngine() {
   try {
     return createEngine(
         createEngineDescription(
             SentenceAnnotator.getDescription(),
             TokenizerAnnotator.getDescription(),
             PoStagger.getDescription("en"),
             StemmerAnnotator.getDescription("English")));
   } catch (Exception e) {
     throw new RuntimeException(e);
   }
 }