int textID = -1;
public NameSample read() throws IOException {
Sentence paragraph;
// we should look for text here.
while ((paragraph = this.adSentenceStream.read()) != null) {
int currentTextID = getTextID(paragraph);
boolean clearData = false;
if(currentTextID != textID) {
clearData = true;
textID = currentTextID;
}
Node root = paragraph.getRoot();
List<String> sentence = new ArrayList<String>();
List<Span> names = new ArrayList<Span>();
process(root, sentence, names);
return new NameSample(sentence.toArray(new String[sentence.size()]),