if(log.isTraceEnabled())
log.trace("i: " + i + ", concept: " + concept);
IdentifiedAnnotation ne = listNonTrivialNE.get(i);
FSArray concepts = ne.getOntologyConceptArr();
for (int j = 0; j < concepts.size(); j++) {
OntologyConcept yoc = (OntologyConcept) concepts.get(j);
String conceptId = this.getConceptId(yoc);
// update the score and set the predicted concept field
if (concept == null || concept.equals(conceptId))
yoc.setDisambiguated(true);
if (scores.containsKey(conceptId))
yoc.setScore(scores.get(conceptId));
}
} else if (conceptSenses.size() == 1) {
// only one concept - for ytex concept set the predicted concept
IdentifiedAnnotation ne = listNonTrivialNE.get(i);
FSArray concepts = ne.getOntologyConceptArr();
OntologyConcept oc = (OntologyConcept) concepts.get(0);
oc.setDisambiguated(true);
}
}
}