StanfordCoreNLP pipeline = new StanfordCoreNLP(props);
// for example
// "edu/stanford/nlp/dcoref/STILLALONEWOLF_20050102.1100.eng.LDC2005E83.sgm"
String doc = IOUtils.slurpFile(input);
Annotation annotation = pipeline.process(doc);
Map<Integer, CorefChain> chains = annotation.get(CorefCoreAnnotations.CorefChainAnnotation.class);
saveResults(output, chains);
}
}