nus-yam/ex-repair huggingface dataset:
Program: 24943
Project: 24943
Buggy source:
private void assertRealisIsNeutralized(final Result wrappedResult){
  for (  final Response response : wrappedResult.systemOutput().responses()) {
    if (response.realis() != KBPRealis.Actual) {
      throw new RuntimeException("String_Node_Str");
    }
  }
  for (  final AssessedResponse annResponse : wrappedResult.answerKey().annotatedResponses()) {
    if (annResponse.response().realis() != KBPRealis.Actual || annResponse.assessment().realis() != Optional.of(KBPRealis.Actual)) {
      throw new RuntimeException("String_Node_Str");
    }
  }
}

Fixed version (ground truth):
private void assertRealisIsNeutralized(final Result wrappedResult){
  for (  final Response response : wrappedResult.systemOutput().responses()) {
    if (response.realis() != KBPRealis.Actual) {
      throw new RuntimeException("String_Node_Str");
    }
  }
  for (  final AssessedResponse annResponse : wrappedResult.answerKey().annotatedResponses()) {
    if (annResponse.response().realis() != KBPRealis.Actual || annResponse.assessment().realis().get() != KBPRealis.Actual) {
      throw new RuntimeException("String_Node_Str");
    }
  }
}
Program: 24944
Project: 24944
Buggy source:
public static Preprocessor fromParameters(Parameters params){
  final List<Function<AnswerKey,AnswerKey>> answerKeyTransformations=Lists.newArrayList();
  final List<Function<SystemOutput,SystemOutput>> systemOutputTransformations=Lists.newArrayList();
  if (params.getBoolean("String_Node_Str")) {
    answerKeyTransformations.add(MakeAllRealisActual.forAnswerKey());
    systemOutputTransformations.add(MakeAllRealisActual.forSystemOutput());
  }
  final Preprocessor basePreprocessor=new PreprocessorKBP2014(answerKeyTransformations,systemOutputTransformations);
  if (params.getBoolean("String_Node_Str")) {
    log.info("String_Node_Str");
    return CorefNeutralizingPreprocessor.createWrappingPreprocessor(basePreprocessor);
  }
 else {
    return basePreprocessor;
  }
}

Fixed version (ground truth):
public static Preprocessor fromParameters(Parameters params){
  final List<Function<AnswerKey,AnswerKey>> answerKeyTransformations=Lists.newArrayList();
  final List<Function<SystemOutput,SystemOutput>> systemOutputTransformations=Lists.newArrayList();
  if (params.getBoolean("String_Node_Str")) {
    answerKeyTransformations.add(MakeAllRealisActual.forAnswerKey());
    systemOutputTransformations.add(MakeAllRealisActual.forSystemOutput());
  }
  answerKeyTransformations.add(FixLowerCaseXInTemporals.forAnswerKey());
  systemOutputTransformations.add(FixLowerCaseXInTemporals.forSystemOutput());
  final Preprocessor basePreprocessor=new PreprocessorKBP2014(answerKeyTransformations,systemOutputTransformations);
  if (params.getBoolean("String_Node_Str")) {
    log.info("String_Node_Str");
    return CorefNeutralizingPreprocessor.createWrappingPreprocessor(basePreprocessor);
  }
 else {
    return basePreprocessor;
  }
}
Program: 24945
Project: 24945
Buggy source:
public void addUnannotatedCASes(Iterable<KBPString> unannotatedCASes){
  for (  final KBPString cas : unannotatedCASes) {
    addUnannotatedCAS(cas);
  }
}

Fixed version (ground truth):
public Builder addUnannotatedCASes(Iterable<KBPString> unannotatedCASes){
  for (  final KBPString cas : unannotatedCASes) {
    addUnannotatedCAS(cas);
  }
  return this;
}
Program: 24946
Project: 24946
Buggy source:
@Override public Result preprocess(final SystemOutput systemOutput,final AnswerKey answerKey){
  final Preprocessor.Result wrappedResult=wrappedPreprocessor.preprocess(systemOutput,answerKey);
  assertRealisIsNeutralized(wrappedResult);
  final ImmutableMultimap<String,AssessedResponse> answerKeyByTypeRoleBaseFiller=Multimaps.index(filter(answerKey.annotatedResponses(),AssessedResponse.IsCorrectUpToInexactJustifications),Functions.compose(TypeRoleBaseFiller,AssessedResponse.Response));
  final ImmutableMultimap<String,AssessedResponse> answerKeyByTypeRole=Multimaps.index(filter(answerKey.annotatedResponses(),AssessedResponse.IsCorrectUpToInexactJustifications),Functions.compose(TypeRole,AssessedResponse.Response));
  final List<Response> newResponses=Lists.newArrayList();
  for (  final Response response : wrappedResult.systemOutput().responses()) {
    final AssessedResponse assessedResponse=wrappedResult.answerKey().assess(response).get();
    if (FieldAssessment.isAcceptable(assessedResponse.assessment().baseFillerCorrect()) && !FieldAssessment.isAcceptable(assessedResponse.assessment().entityCorrectFiller())) {
      final Collection<AssessedResponse> correctPoolResponsesSharingSameTypeRoleBF=answerKeyByTypeRoleBaseFiller.get(TypeRoleBaseFiller.apply(response));
      if (!correctPoolResponsesSharingSameTypeRoleBF.isEmpty()) {
        newResponses.add(Iterables.getFirst(correctPoolResponsesSharingSameTypeRoleBF,null).response());
        ++swappedCASForSameBF;
      }
 else {
        final Collection<AssessedResponse> correctPoolResponsesSharingSameTypeRole=answerKeyByTypeRole.get(TypeRole.apply(response));
        if (!correctPoolResponsesSharingSameTypeRole.isEmpty()) {
          newResponses.add(Iterables.getFirst(correctPoolResponsesSharingSameTypeRole,null).response());
          ++swappedCASDifferentBF;
        }
 else {
          ++deleted;
        }
      }
    }
 else {
      newResponses.add(response);
      ++passedThrough;
    }
  }
  final SystemOutput corefNeutralizedSystemOutput=SystemOutput.createWithConstantScore(systemOutput.docId(),newResponses,1.0);
  return new Preprocessor.Result(corefNeutralizedSystemOutput,wrappedResult.answerKey(),wrappedResult.normalizer());
}

Fixed version (ground truth):
@Override public Result preprocess(final SystemOutput systemOutput,final AnswerKey answerKey){
  final Preprocessor.Result wrappedResult=wrappedPreprocessor.preprocess(systemOutput,answerKey);
  return processWrappedResult(wrappedResult);
}
Program: 24948
Project: 24948
Buggy source:
public static AnswerKey convertAnswerKeyDocID(Symbol docID,AnswerKey input){
  CorefAnnotation corefAnnotation=input.corefAnnotation();
  CorefAnnotation fixedCorefAnnotation=CorefAnnotation.create(docID,corefAnnotation.CASesToIDs(),corefAnnotation.unannotatedCASes());
  Iterable<AssessedResponse> annotatedArgs=Iterables.transform(input.annotatedResponses(),fixAssessedResponseDocID(docID));
  Iterable<Response> unannotatedArgs=Iterables.transform(input.unannotatedResponses(),fixResponseDocID(docID));
  return AnswerKey.from(docID,annotatedArgs,unannotatedArgs,corefAnnotation);
}

Fixed version (ground truth):
public static AnswerKey convertAnswerKeyDocID(Symbol docID,AnswerKey input){
  CorefAnnotation corefAnnotation=input.corefAnnotation();
  CorefAnnotation fixedCorefAnnotation=CorefAnnotation.create(docID,corefAnnotation.CASesToIDs(),corefAnnotation.unannotatedCASes());
  Iterable<AssessedResponse> annotatedArgs=Iterables.transform(input.annotatedResponses(),fixAssessedResponseDocID(docID));
  Iterable<Response> unannotatedArgs=Iterables.transform(input.unannotatedResponses(),fixResponseDocID(docID));
  return AnswerKey.from(docID,annotatedArgs,unannotatedArgs,fixedCorefAnnotation);
}
Program: 24951
Project: 24951
Buggy source:
public static void main(final String[] argv) throws IOException {
  if (argv.length != 1) {
    usage();
  }
  final Parameters params=Parameters.loadSerifStyle(new File(argv[0]));
  log.info(params.dump());
  final File argumentSystemStoreDir=params.getExistingDirectory("String_Node_Str");
  final SystemOutputStore argumentSystemStore=AssessmentSpecFormats.openSystemOutputStore(argumentSystemStoreDir,AssessmentSpecFormats.Format.KBP2015);
  final ImmutableSet<Symbol> docIDs=argumentSystemStore.docIDs();
  final File linkingSystemStoreDir=params.getExistingDirectory("String_Node_Str");
  final LinkingStore linkingSystemStore=LinkingSpecFormats.openOrCreateLinkingStore(linkingSystemStoreDir);
  final LinkingStrategy linkingStrategy=SameEventTypeLinker.create(ImmutableSet.of(KBPRealis.Actual,KBPRealis.Other));
  for (  final Symbol docID : docIDs) {
    final SystemOutput docOutput=argumentSystemStore.read(docID);
    log.info("String_Node_Str",docID,docOutput.size());
    final ResponseLinking responseLinking=linkingStrategy.linkResponses(docOutput);
    linkingSystemStore.write(responseLinking);
    log.info("String_Node_Str",docID,docOutput.size(),responseLinking.responseSets().size());
  }
  linkingSystemStore.close();
  argumentSystemStore.close();
}

Fixed version (ground truth):
public static void main(final String[] argv) throws IOException {
  if (argv.length != 1) {
    usage();
  }
  final Parameters params=Parameters.loadSerifStyle(new File(argv[0]));
  log.info(params.dump());
  final File argumentSystemStoreDir=params.getExistingDirectory("String_Node_Str");
  final SystemOutputStore argumentSystemStore=AssessmentSpecFormats.openSystemOutputStore(argumentSystemStoreDir,AssessmentSpecFormats.Format.KBP2015);
  final ImmutableSet<Symbol> docIDs=argumentSystemStore.docIDs();
  final File linkingSystemStoreDir=params.getEmptyDirectory("String_Node_Str");
  final LinkingStore linkingSystemStore=LinkingSpecFormats.openOrCreateLinkingStore(linkingSystemStoreDir);
  final LinkingStrategy linkingStrategy=SameEventTypeLinker.create(ImmutableSet.of(KBPRealis.Actual,KBPRealis.Other));
  for (  final Symbol docID : docIDs) {
    final SystemOutput docOutput=argumentSystemStore.read(docID);
    log.info("String_Node_Str",docID,docOutput.size());
    final ResponseLinking responseLinking=linkingStrategy.linkResponses(docOutput);
    linkingSystemStore.write(responseLinking);
    log.info("String_Node_Str",docID,docOutput.size(),responseLinking.responseSets().size());
  }
  linkingSystemStore.close();
  argumentSystemStore.close();
}
Program: 24954
Project: 24954
Buggy source:
public void observe(CorefAnnotation left,CorefAnnotation right){
  checkArgument(left.docId().equals(right.docId()));
  checkArgument(left.annotatedCASes().equals(right.annotatedCASes()));
  final Collection<Collection<KBPString>> leftAsClusters=asCollectionOfCollections(left);
  final Collection<Collection<KBPString>> rightAsClusters=asCollectionOfCollections(right);
  b3Scores.add(b3Scorer.score(rightAsClusters,leftAsClusters).F1());
  blancScores.add(blancScorer.score(rightAsClusters,leftAsClusters).blancF());
  final Optional<FMeasureInfo> mucScore=mucScorer.score(rightAsClusters,leftAsClusters);
  if (mucScore.isPresent()) {
    mucScores.add(mucScore.get().F1());
  }
 else {
    log.warn("String_Node_Str",left.docId());
  }
}

Fixed version (ground truth):
public void observe(CorefAnnotation left,CorefAnnotation right){
  checkArgument(left.docId().equals(right.docId()));
  checkArgument(left.annotatedCASes().equals(right.annotatedCASes()));
  final Collection<Collection<KBPString>> leftAsClusters=asCollectionOfCollections(left);
  final Collection<Collection<KBPString>> rightAsClusters=asCollectionOfCollections(right);
  b3Scores.add(b3Scorer.score(rightAsClusters,leftAsClusters).F1());
  blancScores.add(blancScorer.score(rightAsClusters,leftAsClusters).blancScore());
  final Optional<FMeasureInfo> mucScore=mucScorer.score(rightAsClusters,leftAsClusters);
  if (mucScore.isPresent()) {
    mucScores.add(mucScore.get().F1());
  }
 else {
    log.warn("String_Node_Str",left.docId());
  }
}
Program: 24955
Project: 24955
Buggy source:
private void checkNotClosed() throws IOException {
  throw new IOException("String_Node_Str");
}

Fixed version (ground truth):
private void checkNotClosed() throws IOException {
  if (closed) {
    throw new IOException("String_Node_Str");
  }
}
Program: 24956
Project: 24956
Buggy source:
private HashCode computeSHA1Hash(){
  final Hasher hasher=SHA1_HASHER.newHasher().putString(docid.toString(),Charsets.UTF_8).putString(type.toString(),Charsets.UTF_8).putString(role.toString(),Charsets.UTF_8).putString(canonicalArgumentString.string(),Charsets.UTF_8).putInt(canonicalArgument().charOffsetSpan().startInclusive()).putInt(canonicalArgument().charOffsetSpan().endInclusive()).putInt(baseFiller.startInclusive()).putInt(baseFiller.endInclusive());
  for (  final CharOffsetSpan pj : Ordering.natural().sortedCopy(predicateJustifications)) {
    hasher.putInt(pj.startInclusive()).putInt(pj.endInclusive());
  }
  for (  final CharOffsetSpan aaj : Ordering.natural().sortedCopy(additionalArgumentJustifications())) {
    hasher.putInt(aaj.startInclusive()).putInt(aaj.endInclusive());
  }
  hasher.putInt(realis.ordinal());
  return hasher.hash();
}

Fixed version (ground truth):
private HashCode computeSHA1Hash(){
  final Hasher hasher=SHA1_HASHER.newHasher().putString(docid.toString(),Charsets.UTF_8).putString(type.toString(),Charsets.UTF_8).putString(role.toString(),Charsets.UTF_8).putString(canonicalArgumentString.string(),Charsets.UTF_8).putInt(canonicalArgument().charOffsetSpan().startInclusive()).putInt(canonicalArgument().charOffsetSpan().endInclusive()).putInt(baseFiller.startInclusive()).putInt(baseFiller.endInclusive());
  hasher.putInt(PJ_CODE);
  for (  final CharOffsetSpan pj : Ordering.natural().sortedCopy(predicateJustifications)) {
    hasher.putInt(pj.startInclusive()).putInt(pj.endInclusive());
  }
  hasher.putInt(AAJ_CODE);
  for (  final CharOffsetSpan aaj : Ordering.natural().sortedCopy(additionalArgumentJustifications())) {
    hasher.putInt(aaj.startInclusive()).putInt(aaj.endInclusive());
  }
  hasher.putInt(realis.ordinal());
  return hasher.hash();
}
Program: 24957
Project: 24957
Buggy source:
private ImmutableSet<TypeRoleFillerRealis> responsesToDelete(AnswerKey answerKey){
  final ImmutableSet.Builder<TypeRoleFillerRealis> ret=ImmutableSet.builder();
  for (  final AssessedResponse assessedResponse : answerKey.annotatedResponses()) {
    if (assessedResponse.response().type() == LIFE_DIE && assessedResponse.isCorrectUpToInexactJustifications()) {
      ret.add(normalizedFingerprintExtractor.apply(assessedResponse.response()));
    }
  }
  return ret.build();
}

Fixed version (ground truth):
private ImmutableSet<TypeRoleFillerRealis> responsesToDelete(AnswerKey answerKey){
  final ImmutableSet.Builder<TypeRoleFillerRealis> ret=ImmutableSet.builder();
  for (  final AssessedResponse assessedResponse : answerKey.annotatedResponses()) {
    if (assessedResponse.response().type() == LIFE_DIE && assessedResponse.isCorrectUpToInexactJustifications()) {
      ret.add(normalizedFingerprintExtractor.apply(assessedResponse.response()).copyWithModifiedType(LIFE_INJURE));
    }
  }
  return ret.build();
}
Program: 24960
Project: 24960
Buggy source:
@Override public void unannotatedSelectedResponse(final Answerable answerable,final Response unannotated){
  throw IncompleteAnnotationException.forMissingResponse(unannotated);
}

Fixed version (ground truth):
@Override public void unannotatedSelectedResponse(final Answerable answerable,final Response unannotated,Set<AssessedResponse> assessedResponses){
  throw IncompleteAnnotationException.forMissingResponse(unannotated);
}
Program: 24961
Project: 24961
Buggy source:
@Override public KBPAnswerSourceObserver answerSourceObserver(final SystemOutputAnswerSource<Answerable> systemOutputSource,final AnswerKeyAnswerSource<Answerable> answerKeyAnswerSource){
  return new KBPAnswerSourceObserver(systemOutputSource,answerKeyAnswerSource){
    @Override public void unannotatedSelectedResponse(    final Answerable answerable,    final Response unannotated){
      throw IncompleteAnnotationException.forMissingResponse(unannotated);
    }
  }
;
}

Fixed version (ground truth):
@Override public KBPAnswerSourceObserver answerSourceObserver(final SystemOutputAnswerSource<Answerable> systemOutputSource,final AnswerKeyAnswerSource<Answerable> answerKeyAnswerSource){
  return new KBPAnswerSourceObserver(systemOutputSource,answerKeyAnswerSource){
    @Override public void unannotatedSelectedResponse(    final Answerable answerable,    final Response unannotated,    Set<AssessedResponse> assessedResponses){
      throw IncompleteAnnotationException.forMissingResponse(unannotated);
    }
  }
;
}
Program: 24962
Project: 24962
Buggy source:
/** 
 * Called when the selected system response for an annotator is unannotated.
 * @param answerable
 * @param response
 */
public void unannotatedSelectedResponse(final Answerable answerable,final Response response){
}

Fixed version (ground truth):
/** 
 * Called when the selected system response for an annotator is unannotated.
 * @param answerable
 * @param response
 */
public void unannotatedSelectedResponse(final Answerable answerable,final Response response,Set<AssessedResponse> assessedResponses){
}
Program: 24963
Project: 24963
Buggy source:
@Override public void annotatedSelectedResponse(final TypeRoleFillerRealis answerable,final Response response,final AssessedResponse annotationForSelected,final Set<AssessedResponse> allAssessments){
  if (ResponseCorrect.apply(annotationForSelected)) {
    textOut.append("String_Node_Str");
    confusionMatrixBuilder.record(PRESENT,PRESENT,answerable);
  }
 else {
    textOut.append("String_Node_Str").append(annotationForSelected.assessment()).append("String_Node_Str");
    confusionMatrixBuilder.record(PRESENT,ABSENT,answerable);
    htmlOut.append(renderer.vsAnnotated("String_Node_Str","String_Node_Str",response,systemOutputSource.systemOutput().score(response),annotationForSelected));
    if (any(allAssessments,ResponseCorrect)) {
      textOut.append("String_Node_Str").append(Iterables.find(allAssessments,ResponseCorrect)).append("String_Node_Str");
      confusionMatrixBuilder.record(ABSENT,PRESENT,answerable);
      htmlOut.append(renderer.vsAnnotated("String_Node_Str","String_Node_Str",getFirst(allAssessments,null).response(),allAssessments));
    }
  }
}

Fixed version (ground truth):
@Override public void annotatedSelectedResponse(final TypeRoleFillerRealis answerable,final Response response,final AssessedResponse annotationForSelected,final Set<AssessedResponse> allAssessments){
  if (ResponseCorrect.apply(annotationForSelected)) {
    textOut.append("String_Node_Str");
    confusionMatrixBuilder.record(PRESENT,PRESENT,answerable);
  }
 else {
    textOut.append("String_Node_Str").append(annotationForSelected.assessment()).append("String_Node_Str");
    confusionMatrixBuilder.record(PRESENT,ABSENT,answerable);
    htmlOut.append(renderer.vsAnnotated("String_Node_Str","String_Node_Str",response,systemOutputSource.systemOutput().score(response),annotationForSelected));
    checkForFalseNegative(answerable,allAssessments);
  }
}
Program: 24964
Project: 24964
Buggy source:
@Override public void unannotatedSelectedResponse(final TypeRoleFillerRealis answerable,final Response unannotated){
  textOut.append("String_Node_Str").append(unannotated).append("String_Node_Str");
  confusionMatrixBuilder.record(PRESENT,ABSENT,answerable);
  htmlOut.append(renderer.vsAnnotated("String_Node_Str","String_Node_Str",unannotated,ImmutableList.of(systemOutputSource.systemOutput().score(unannotated)),answerKey().answers(answerable)));
}

Fixed version (ground truth):
@Override public void unannotatedSelectedResponse(final TypeRoleFillerRealis answerable,final Response unannotated,Set<AssessedResponse> annotatedResponses){
  textOut.append("String_Node_Str").append(unannotated).append("String_Node_Str");
  confusionMatrixBuilder.record(PRESENT,ABSENT,answerable);
  htmlOut.append(renderer.vsAnnotated("String_Node_Str","String_Node_Str",unannotated,ImmutableList.of(systemOutputSource.systemOutput().score(unannotated)),answerKey().answers(answerable)));
  checkForFalseNegative(answerable,annotatedResponses);
}
Program: 24965
Project: 24965
Buggy source:
@Override public void annotationsOnlyNonEmpty(final TypeRoleFillerRealis answerable,final Set<AssessedResponse> annotatedResponses){
  if (any(annotatedResponses,ResponseCorrect)) {
    textOut.append("String_Node_Str").append(Iterables.find(annotatedResponses,ResponseCorrect)).append("String_Node_Str");
    confusionMatrixBuilder.record(ABSENT,PRESENT,answerable);
    htmlOut.append(renderer.vsAnnotated("String_Node_Str","String_Node_Str",getFirst(annotatedResponses,null).response(),annotatedResponses));
  }
 else {
    textOut.append("String_Node_Str");
  }
}

Fixed version (ground truth):
@Override public void annotationsOnlyNonEmpty(final TypeRoleFillerRealis answerable,final Set<AssessedResponse> annotatedResponses){
  if (checkForFalseNegative(answerable,annotatedResponses)) {
  }
 else {
    textOut.append("String_Node_Str");
  }
}
Program: 24967
Project: 24967
Buggy source:
public static <ProvenanceType>Map<String,Map<Symbol,ProvenancedConfusionMatrix<ProvenanceType>>> computeBreakdowns(ProvenancedConfusionMatrix<ProvenanceType> corpusConfusionMatrix,Map<String,Function<? super ProvenanceType,Symbol>> breakdowns){
  final Map<String,Map<Symbol,ProvenancedConfusionMatrix<ProvenanceType>>> printModes=Maps.newHashMap();
  printModes.put("String_Node_Str",ImmutableMap.of(Symbol.from("String_Node_Str"),corpusConfusionMatrix));
  for (  final Map.Entry<String,Function<? super ProvenanceType,Symbol>> breakdownEntry : breakdowns.entrySet()) {
    printModes.put(breakdownEntry.getKey(),corpusConfusionMatrix.breakdown(breakdownEntry.getValue()));
  }
  return printModes;
}

Fixed version (ground truth):
public static <ProvenanceType>ImmutableMap<String,Map<Symbol,ProvenancedConfusionMatrix<ProvenanceType>>> computeBreakdowns(ProvenancedConfusionMatrix<ProvenanceType> corpusConfusionMatrix,Map<String,Function<? super ProvenanceType,Symbol>> breakdowns){
  final ImmutableMap.Builder<String,Map<Symbol,ProvenancedConfusionMatrix<ProvenanceType>>> printModes=ImmutableMap.builder();
  for (  final Map.Entry<String,Function<? super ProvenanceType,Symbol>> breakdownEntry : breakdowns.entrySet()) {
    printModes.put(breakdownEntry.getKey(),corpusConfusionMatrix.breakdown(breakdownEntry.getValue(),Ordering.from(new SymbolUtils.ByString())));
  }
  return printModes.build();
}
Program: 24968
Project: 24968
Buggy source:
@Override public int compareTo(final TypeRoleFillerRealis o){
  return ComparisonChain.start().compare(docid.toString(),o.docid.toString()).compare(type.toString(),o.type.toString()).compare(role.toString(),o.type.toString()).compare(realis,o.realis).compare(argumentCanonicalString.toString(),argumentCanonicalString.toString()).result();
}

Fixed version (ground truth):
@Override public int compareTo(final TypeRoleFillerRealis o){
  return ComparisonChain.start().compare(docid.toString(),o.docid.toString()).compare(type.toString(),o.type.toString()).compare(role.toString(),o.type.toString()).compare(realis,o.realis).compare(argumentCanonicalString,argumentCanonicalString).result();
}
Program: 24970
Project: 24970
Buggy source:
public static void main(final String[] argv) throws IOException {
  if (argv.length != 1) {
    usage();
  }
  final Parameters params=Parameters.loadSerifStyle(new File(argv[0]));
  log.info(params.dump());
  final SystemOutputStore systemOutputStore=AssessmentSpecFormats.openSystemOutputStore(params.getExistingDirectory("String_Node_Str"));
  final AnnotationStore goldAnswerStore=AssessmentSpecFormats.openAnnotationStore(params.getExistingDirectory("String_Node_Str"));
  final Set<Symbol> documentsToScore;
  if (params.isPresent("String_Node_Str")) {
    documentsToScore=ImmutableSet.copyOf(FileUtils.loadSymbolList(params.getExistingFile("String_Node_Str")));
  }
 else {
    documentsToScore=union(systemOutputStore.docIDs(),goldAnswerStore.docIDs());
  }
  final KBPScorer scorer=KBPScorer.create();
  scorer.run(systemOutputStore,goldAnswerStore,documentsToScore,getCorpusObservers(params),params.getCreatableDirectory("String_Node_Str"));
}

Fixed version (ground truth):
public static void main(final String[] argv) throws IOException {
  if (argv.length != 1) {
    usage();
  }
  final Parameters params=Parameters.loadSerifStyle(new File(argv[0]));
  log.info(params.dump());
  final AnnotationStore goldAnswerStore=AssessmentSpecFormats.openAnnotationStore(params.getExistingDirectory("String_Node_Str"));
  checkArgument(params.isPresent("String_Node_Str") != params.isPresent("String_Node_Str"),"String_Node_Str");
  if (params.isPresent("String_Node_Str")) {
  }
 else   if (params.isPresent("String_Node_Str")) {
  }
 else {
    throw new RuntimeException("String_Node_Str");
  }
  final SystemOutputStore systemOutputStore=AssessmentSpecFormats.openSystemOutputStore(params.getExistingDirectory("String_Node_Str"));
  final Set<Symbol> documentsToScore;
  if (params.isPresent("String_Node_Str")) {
    documentsToScore=ImmutableSet.copyOf(FileUtils.loadSymbolList(params.getExistingFile("String_Node_Str")));
  }
 else {
    documentsToScore=union(systemOutputStore.docIDs(),goldAnswerStore.docIDs());
  }
  final KBPScorer scorer=KBPScorer.create();
  scorer.run(systemOutputStore,goldAnswerStore,documentsToScore,getCorpusObservers(params),params.getCreatableDirectory("String_Node_Str"));
}
Program: 24971
Project: 24971
Buggy source:
@Override public AnswerKey apply(AnswerKey input){
  final ImmutableSet.Builder<AssessedResponse> newAssessedResponses=ImmutableSet.builder();
  newAssessedResponses.addAll(input.annotatedResponses());
  for (  final AssessedResponse assessedResponse : input.annotatedResponses()) {
    if (assessedResponse.assessment().realis().isPresent()) {
      newAssessedResponses.add(AssessedResponse.from(assessedResponse.response().copyWithSwappedRealis(assessedResponse.assessment().realis().get()),assessedResponse.assessment()));
    }
  }
  return AnswerKey.from(input.docId(),newAssessedResponses.build(),input.unannotatedResponses());
}

Fixed version (ground truth):
@Override public AnswerKey apply(AnswerKey input){
  final ImmutableSet<Response> allExistingResponses=input.allResponses();
  final ImmutableSet.Builder<AssessedResponse> newAssessedResponses=ImmutableSet.builder();
  newAssessedResponses.addAll(input.annotatedResponses());
  for (  final AssessedResponse assessedResponse : input.annotatedResponses()) {
    if (assessedResponse.assessment().realis().isPresent()) {
      final Response responseWithAssessedRealis=assessedResponse.response().copyWithSwappedRealis(assessedResponse.assessment().realis().get());
      if (!allExistingResponses.contains(responseWithAssessedRealis)) {
        newAssessedResponses.add(AssessedResponse.from(responseWithAssessedRealis,assessedResponse.assessment()));
      }
    }
  }
  return AnswerKey.from(input.docId(),newAssessedResponses.build(),input.unannotatedResponses());
}
Program: 24972
Project: 24972
Buggy source:
private static void scoreSingleSystemOutputStore(AnnotationStore goldAnswerStore,List<KBPScoringObserver<TypeRoleFillerRealis>> corpusObservers,KBPScorer scorer,Parameters params) throws IOException {
  final File systemOutputDir=params.getExistingDirectory("String_Node_Str");
  log.info("String_Node_Str",systemOutputDir);
  final SystemOutputStore systemOutputStore=AssessmentSpecFormats.openSystemOutputStore(systemOutputDir);
  final Set<Symbol> documentsToScore;
  if (params.isPresent("String_Node_Str")) {
    documentsToScore=loadDocumentsToScore(params);
  }
 else {
    documentsToScore=union(systemOutputStore.docIDs(),goldAnswerStore.docIDs());
  }
  scorer.run(systemOutputStore,goldAnswerStore,documentsToScore,corpusObservers,params.getCreatableDirectory("String_Node_Str"));
}

Fixed version (ground truth):
private static void scoreSingleSystemOutputStore(AnnotationStore goldAnswerStore,KBPScorer scorer,Parameters params) throws IOException {
  final File systemOutputDir=params.getExistingDirectory("String_Node_Str");
  log.info("String_Node_Str",systemOutputDir);
  final SystemOutputStore systemOutputStore=AssessmentSpecFormats.openSystemOutputStore(systemOutputDir);
  final Set<Symbol> documentsToScore;
  if (params.isPresent("String_Node_Str")) {
    documentsToScore=loadDocumentsToScore(params);
  }
 else {
    documentsToScore=union(systemOutputStore.docIDs(),goldAnswerStore.docIDs());
  }
  final List<KBPScoringObserver<TypeRoleFillerRealis>> corpusObservers=getCorpusObservers(params);
  scorer.run(systemOutputStore,goldAnswerStore,documentsToScore,corpusObservers,params.getCreatableDirectory("String_Node_Str"));
}
Program: 24973
Project: 24973
Buggy source:
private static void scoreMultipleSystemOutputStores(AnnotationStore goldAnswerStore,KBPScorer scorer,List<KBPScoringObserver<TypeRoleFillerRealis>> corpusObservers,Parameters params) throws IOException {
  final File systemOutputsDir=params.getExistingDirectory("String_Node_Str");
  final File scoringOutputRoot=params.getCreatableDirectory("String_Node_Str");
  log.info("String_Node_Str",systemOutputsDir);
  final Set<Symbol> documentsToScore=loadDocumentsToScore(params);
  for (  File subDir : systemOutputsDir.listFiles()) {
    if (subDir.isDirectory()) {
      final SystemOutputStore systemOutputStore=AssessmentSpecFormats.openSystemOutputStore(subDir);
      final File outputDir=new File(scoringOutputRoot,subDir.getName());
      outputDir.mkdirs();
      scorer.run(systemOutputStore,goldAnswerStore,documentsToScore,corpusObservers,outputDir);
    }
  }
}

Fixed version (ground truth):
private static void scoreMultipleSystemOutputStores(AnnotationStore goldAnswerStore,KBPScorer scorer,Parameters params) throws IOException {
  final File systemOutputsDir=params.getExistingDirectory("String_Node_Str");
  final File scoringOutputRoot=params.getCreatableDirectory("String_Node_Str");
  log.info("String_Node_Str",systemOutputsDir);
  final Set<Symbol> documentsToScore=loadDocumentsToScore(params);
  for (  File subDir : systemOutputsDir.listFiles()) {
    if (subDir.isDirectory()) {
      final SystemOutputStore systemOutputStore=AssessmentSpecFormats.openSystemOutputStore(subDir);
      final File outputDir=new File(scoringOutputRoot,subDir.getName());
      final List<KBPScoringObserver<TypeRoleFillerRealis>> corpusObservers=getCorpusObservers(params);
      outputDir.mkdirs();
      scorer.run(systemOutputStore,goldAnswerStore,documentsToScore,corpusObservers,outputDir);
    }
  }
}
Program: 24974
Project: 24974
Buggy source:
public static void main(final String[] argv) throws IOException {
  if (argv.length != 1) {
    usage();
  }
  final Parameters params=Parameters.loadSerifStyle(new File(argv[0]));
  log.info(params.dump());
  final KBPScorer scorer=KBPScorer.create();
  final AnnotationStore goldAnswerStore=AssessmentSpecFormats.openAnnotationStore(params.getExistingDirectory("String_Node_Str"));
  final List<KBPScoringObserver<TypeRoleFillerRealis>> corpusObservers=getCorpusObservers(params);
  checkArgument(params.isPresent("String_Node_Str") != params.isPresent("String_Node_Str"),"String_Node_Str");
  if (params.isPresent("String_Node_Str")) {
    scoreSingleSystemOutputStore(goldAnswerStore,corpusObservers,scorer,params);
  }
 else   if (params.isPresent("String_Node_Str")) {
    scoreMultipleSystemOutputStores(goldAnswerStore,scorer,corpusObservers,params);
  }
 else {
    throw new RuntimeException("String_Node_Str");
  }
}

Fixed version (ground truth):
public static void main(final String[] argv) throws IOException {
  if (argv.length != 1) {
    usage();
  }
  final Parameters params=Parameters.loadSerifStyle(new File(argv[0]));
  log.info(params.dump());
  final KBPScorer scorer=KBPScorer.create();
  final AnnotationStore goldAnswerStore=AssessmentSpecFormats.openAnnotationStore(params.getExistingDirectory("String_Node_Str"));
  checkArgument(params.isPresent("String_Node_Str") != params.isPresent("String_Node_Str"),"String_Node_Str");
  if (params.isPresent("String_Node_Str")) {
    scoreSingleSystemOutputStore(goldAnswerStore,scorer,params);
  }
 else   if (params.isPresent("String_Node_Str")) {
    scoreMultipleSystemOutputStores(goldAnswerStore,scorer,params);
  }
 else {
    throw new RuntimeException("String_Node_Str");
  }
}
Program: 24975
Project: 24975
Buggy source:
public static Function<AnswerKey,AnswerKey> forAnswerKey(){
  return new Function<AnswerKey,AnswerKey>(){
    @Override public AnswerKey apply(    AnswerKey input){
      final ImmutableList.Builder<Response> newUnannotated=ImmutableList.builder();
      for (      final Response response : input.unannotatedResponses()) {
        newUnannotated.add(response.copyWithSwappedRealis(KBPRealis.Actual));
      }
      final ImmutableList.Builder<AssessedResponse> newAssessed=ImmutableList.builder();
      for (      final AssessedResponse response : input.annotatedResponses()) {
        newAssessed.add(AssessedResponse.from(response.response().copyWithSwappedRealis(KBPRealis.Actual),response.assessment().copyWithModifiedRealisAssessment(Optional.of(KBPRealis.Actual))));
      }
      return AnswerKey.from(input.docId(),newAssessed.build(),newUnannotated.build());
    }
  }
;
}

Fixed version (ground truth):
public static Function<AnswerKey,AnswerKey> forAnswerKey(){
  return new Function<AnswerKey,AnswerKey>(){
    @Override public AnswerKey apply(    AnswerKey input){
      final Set<Response> seenResponses=Sets.newHashSet();
      final ImmutableSet.Builder<AssessedResponse> newAssessed=ImmutableSet.builder();
      for (      final AssessedResponse response : input.annotatedResponses()) {
        final Response neutralizedResponse=response.response().copyWithSwappedRealis(KBPRealis.Actual);
        if (!seenResponses.contains(neutralizedResponse)) {
          newAssessed.add(AssessedResponse.from(neutralizedResponse,response.assessment().copyWithModifiedRealisAssessment(Optional.of(KBPRealis.Actual))));
        }
        seenResponses.add(neutralizedResponse);
      }
      final ImmutableSet.Builder<Response> newUnannotated=ImmutableSet.builder();
      for (      final Response response : input.unannotatedResponses()) {
        final Response neutralizedResponse=response.copyWithSwappedRealis(KBPRealis.Actual);
        if (!seenResponses.contains(neutralizedResponse)) {
          newUnannotated.add(neutralizedResponse);
        }
        seenResponses.add(neutralizedResponse);
      }
      return AnswerKey.from(input.docId(),newAssessed.build(),newUnannotated.build());
    }
  }
;
}
Program: 24976
Project: 24976
Buggy source:
@Override public SystemOutput apply(SystemOutput input){
  final ImmutableList.Builder<Scored<Response>> newResponses=ImmutableList.builder();
  for (  final Scored<Response> response : input.scoredResponses()) {
    newResponses.add(Scored.from(response.item().copyWithSwappedRealis(KBPRealis.Actual),response.score()));
  }
  return SystemOutput.from(input.docId(),newResponses.build());
}

Fixed version (ground truth):
@Override public SystemOutput apply(SystemOutput input){
  final ImmutableSet.Builder<Scored<Response>> newResponses=ImmutableSet.builder();
  for (  final Scored<Response> assessedResponse : input.scoredResponses()) {
    newResponses.add(Scored.from(assessedResponse.item().copyWithSwappedRealis(KBPRealis.Actual),assessedResponse.score()));
  }
  return SystemOutput.from(input.docId(),newResponses.build());
}
Program: 24977
Project: 24977
Buggy source:
public static Function<SystemOutput,SystemOutput> forSystemOutput(){
  return new Function<SystemOutput,SystemOutput>(){
    @Override public SystemOutput apply(    SystemOutput input){
      final ImmutableList.Builder<Scored<Response>> newResponses=ImmutableList.builder();
      for (      final Scored<Response> response : input.scoredResponses()) {
        newResponses.add(Scored.from(response.item().copyWithSwappedRealis(KBPRealis.Actual),response.score()));
      }
      return SystemOutput.from(input.docId(),newResponses.build());
    }
  }
;
}

Fixed version (ground truth):
public static Function<SystemOutput,SystemOutput> forSystemOutput(){
  return new Function<SystemOutput,SystemOutput>(){
    @Override public SystemOutput apply(    SystemOutput input){
      final ImmutableSet.Builder<Scored<Response>> newResponses=ImmutableSet.builder();
      for (      final Scored<Response> assessedResponse : input.scoredResponses()) {
        newResponses.add(Scored.from(assessedResponse.item().copyWithSwappedRealis(KBPRealis.Actual),assessedResponse.score()));
      }
      return SystemOutput.from(input.docId(),newResponses.build());
    }
  }
;
}
Program: 24978
Project: 24978
Buggy source:
@Override protected Symbol toKey(ResponseAssessment assessment){
  return Symbol.from(assessment.realis().get().toString());
}

Fixed version (ground truth):
@Override protected Symbol toKey(ResponseAssessment assessment){
  return Symbol.from(assessment.mentionTypeOfCAS().get().toString());
}
Program: 24979
Project: 24979
Buggy source:
private void assertConsistency(){
  final Multimap<Response,AsssessedResponse> responseToAnn=Multimaps.index(annotatedArgs,AsssessedResponse.Response);
  for (  final Map.Entry<Response,Collection<AsssessedResponse>> entry : responseToAnn.asMap().entrySet()) {
    if (!allEqual(transform(entry.getValue(),AsssessedResponse.Annotation))) {
      throw new RuntimeException(String.format("String_Node_Str",entry.getValue()));
    }
  }
  checkArgument(Sets.intersection(FluentIterable.from(annotatedArgs).transform(AsssessedResponse.Response).toSet(),unannotatedResponses).isEmpty(),"String_Node_Str");
}

Fixed version (ground truth):
private void assertConsistency(){
  final Multimap<Response,AsssessedResponse> responseToAnn=Multimaps.index(annotatedArgs,AsssessedResponse.Response);
  for (  final Map.Entry<Response,Collection<AsssessedResponse>> entry : responseToAnn.asMap().entrySet()) {
    if (!allEqual(transform(entry.getValue(),AsssessedResponse.Annotation))) {
      throw new RuntimeException(String.format("String_Node_Str",entry.getValue()));
    }
  }
  checkArgument(Sets.intersection(FluentIterable.from(annotatedArgs).transform(AsssessedResponse.Response).toSet(),unannotatedResponses).isEmpty(),"String_Node_Str");
  assertNoIncompatibleCorefAnnotations();
}
Program: 24980
Project: 24980
Buggy source:
private Optional<ResponseAssessment> parseAnnotation(final List<String> parts){
  checkArgument(parts.size() == 7,"String_Node_Str",parts);
  if (parts.contains("String_Node_Str")) {
    return Optional.absent();
  }
  final Optional<FieldAssessment> AET=FieldAssessment.parseOptional(parts.get(0));
  final Optional<FieldAssessment> AER=FieldAssessment.parseOptional(parts.get(1));
  final Optional<FieldAssessment> casAssessment=FieldAssessment.parseOptional(parts.get(2));
  final Optional<FieldAssessment> baseFillerAssessment=FieldAssessment.parseOptional(parts.get(3));
  final Optional<Integer> coreference=parts.get(4).equals("String_Node_Str") ? Optional.<Integer>absent() : Optional.of(Integer.parseInt(parts.get(4)));
  final Optional<KBPRealis> realis=KBPRealis.parseOptional(parts.get(5));
  final Optional<MentionType> mentionTypeOfCAS=MentionType.parseOptional(parts.get(6));
  return assessmentCreator.createAssessmentFromFields(AET,AER,casAssessment,realis,baseFillerAssessment,coreference,mentionTypeOfCAS);
}

Fixed version (ground truth):
private Optional<ResponseAssessment> parseAnnotation(final List<String> parts){
  checkArgument(parts.size() == 7,"String_Node_Str",parts);
  if (parts.contains("String_Node_Str")) {
    return Optional.absent();
  }
  final Optional<FieldAssessment> AET=FieldAssessment.parseOptional(parts.get(0));
  final Optional<FieldAssessment> AER=FieldAssessment.parseOptional(parts.get(1));
  final Optional<FieldAssessment> casAssessment=FieldAssessment.parseOptional(parts.get(2));
  final Optional<FieldAssessment> baseFillerAssessment=FieldAssessment.parseOptional(parts.get(3));
  final Optional<Integer> coreference=emptyCorefEncodings.contains(parts.get(4)) ? Optional.<Integer>absent() : Optional.of(Integer.parseInt(parts.get(4)));
  final Optional<KBPRealis> realis=KBPRealis.parseOptional(parts.get(5));
  final Optional<MentionType> mentionTypeOfCAS=MentionType.parseOptional(parts.get(6));
  return assessmentCreator.createAssessmentFromFields(AET,AER,casAssessment,realis,baseFillerAssessment,coreference,mentionTypeOfCAS);
}
Program: 24981
Project: 24981
Buggy source:
private synchronized AnswerKey uncachedRead(final Symbol docid) throws IOException {
  final ImmutableList.Builder<AsssessedResponse> annotated=ImmutableList.builder();
  final ImmutableList.Builder<Response> unannotated=ImmutableList.builder();
  final CharSource source=Files.asCharSource(new File(directory,docid.toString()),UTF_8);
  for (  final String line : source.readLines()) {
    try {
      if (line.isEmpty() || line.startsWith("String_Node_Str")) {
        continue;
      }
      final String[] parts=line.split("String_Node_Str");
      final List<String> argumentParts=Arrays.asList(parts).subList(1,11);
      final List<String> annotationParts=Arrays.asList(parts).subList(11,parts.length);
      if (annotationParts.isEmpty()) {
        throw new IOException(String.format("String_Node_Str" + "String_Node_Str",docid));
      }
      final Response response=parseArgumentFields(argumentParts);
      final Optional<ResponseAssessment> annotation=parseAnnotation(annotationParts);
      if (annotation.isPresent()) {
        annotated.add(AsssessedResponse.from(response,annotation.get()));
      }
 else {
        unannotated.add(response);
      }
    }
 catch (    Exception e) {
      throw new IOException(String.format("String_Node_Str",docid,line),e);
    }
  }
  return AnswerKey.from(docid,annotated.build(),unannotated.build());
}

Fixed version (ground truth):
private synchronized AnswerKey uncachedRead(final Symbol docid) throws IOException {
  final ImmutableList.Builder<AsssessedResponse> annotated=ImmutableList.builder();
  final ImmutableList.Builder<Response> unannotated=ImmutableList.builder();
  final CharSource source=Files.asCharSource(new File(directory,docid.toString()),UTF_8);
  for (  final String line : source.readLines()) {
    try {
      if (line.isEmpty() || line.startsWith("String_Node_Str")) {
        continue;
      }
      final String[] parts=line.split("String_Node_Str");
      final List<String> argumentParts=Arrays.asList(parts).subList(1,11);
      final List<String> annotationParts=Arrays.asList(parts).subList(11,parts.length);
      if (annotationParts.isEmpty()) {
        throw new IOException(String.format("String_Node_Str" + "String_Node_Str",docid));
      }
      final Response response=parseArgumentFields(argumentParts);
      final Optional<ResponseAssessment> annotation=parseAnnotation(annotationParts);
      if (annotation.isPresent()) {
        annotated.add(AsssessedResponse.from(response,annotation.get()));
      }
 else {
        unannotated.add(response);
      }
    }
 catch (    Exception e) {
      throw new IOException(String.format("String_Node_Str",docid,line),e);
    }
  }
  return assessmentCreator.createAnswerKey(docid,annotated.build(),unannotated.build());
}
Program: 24982
Project: 24982
Buggy source:
/** 
 * Produces a human-readable report on what was erroneously present and missing in the assessments created through this   {@link AssessmentCreator}.
 * @return
 */
public String report(){
  final StringBuilder sb=new StringBuilder();
  sb.append("String_Node_Str").append(responsesAttempted).append("String_Node_Str");
  sb.append(extras.size()).append("String_Node_Str").append(extras).append("String_Node_Str");
  sb.append("String_Node_Str").append(makeMissingCorefSingleton).append("String_Node_Str").append("String_Node_Str");
  sb.append("String_Node_Str").append(missing.size()).append("String_Node_Str").append("String_Node_Str").append(missing).append("String_Node_Str");
  return sb.toString();
}

Fixed version (ground truth):
/** 
 * Produces a human-readable report on what was erroneously present and missing in the assessments created through this   {@link AssessmentCreator}.
 * @return
 */
public String report(){
  final StringBuilder sb=new StringBuilder();
  sb.append("String_Node_Str").append(responsesAttempted).append("String_Node_Str");
  sb.append(extras.size()).append("String_Node_Str").append(extras).append("String_Node_Str");
  sb.append("String_Node_Str").append(makeMissingCorefSingleton).append("String_Node_Str").append("String_Node_Str");
  sb.append("String_Node_Str").append(numRemappedCoref).append("String_Node_Str").append("String_Node_Str");
  sb.append("String_Node_Str").append(missing.size()).append("String_Node_Str").append("String_Node_Str").append(missing).append("String_Node_Str");
  return sb.toString();
}
Program: 24983
Project: 24983
Buggy source:
private void logArgumentJustications(final String originalDocText,final Response response,StringBuilder out){
  out.append("String_Node_Str");
  out.append("String_Node_Str");
  final List<CharOffsetSpan> offsetSpans=Lists.newArrayList();
  offsetSpans.addAll(response.additionalArgumentJustifications());
  if (offsetSpans.isEmpty()) {
    out.append("String_Node_Str");
  }
 else {
    for (    CharOffsetSpan argSpan : offsetSpans) {
      out.append(originalDocText.substring(argSpan.startInclusive(),argSpan.endInclusive() + 1));
      out.append("String_Node_Str");
    }
    out.append("String_Node_Str");
  }
}

Fixed version (ground truth):
private void logArgumentJustications(final String originalDocText,final Response response,StringBuilder out){
  out.append("String_Node_Str");
  out.append("String_Node_Str");
  final List<CharOffsetSpan> offsetSpans=Lists.newArrayList();
  offsetSpans.addAll(response.additionalArgumentJustifications());
  if (offsetSpans.isEmpty()) {
    out.append("String_Node_Str");
  }
 else {
    for (    CharOffsetSpan argSpan : offsetSpans) {
      out.append(originalDocText.substring(argSpan.startInclusive(),argSpan.endInclusive() + 1));
      out.append("String_Node_Str");
    }
  }
  out.append("String_Node_Str");
}
Program: 24984
Project: 24984
Buggy source:
@Override public void logDifference(Response response,Symbol leftKey,Symbol rightKey,StringBuilder out){
  this.logLeftRightDecisions(out,leftKey,rightKey);
  this.logTypeRoleCAS(response,out);
  final String originalDocText;
  try {
    originalDocText=this.cache.getPlainDoc(response.docID());
    this.logBaseFiller(originalDocText,response,out);
    this.logPredicateJustifications(originalDocText,response,out);
    this.logArgumentJustications(originalDocText,response,out);
    this.logDocumentContext(originalDocText,response,out);
  }
 catch (  final IOException ioe) {
    out.append("String_Node_Str");
    out.append("String_Node_Str");
    return;
  }
  out.append("String_Node_Str");
}

Fixed version (ground truth):
@Override public void logDifference(Response response,Symbol leftKey,Symbol rightKey,StringBuilder out){
  this.logLeftRightDecisions(out,leftKey,rightKey);
  this.logIdTypeRoleCAS(response,out);
  final String originalDocText;
  try {
    originalDocText=this.cache.getPlainDoc(response.docID());
    this.logBaseFiller(originalDocText,response,out);
    this.logPredicateJustifications(originalDocText,response,out);
    this.logArgumentJustications(originalDocText,response,out);
    this.logDocumentContext(originalDocText,response,out);
  }
 catch (  final IOException ioe) {
    out.append("String_Node_Str");
    out.append("String_Node_Str");
    return;
  }
  out.append("String_Node_Str");
}