if (!modificandItem.stop() && modificandItem.label()==baseNP) {
if (!modificandItem.stop() && Language.treebank.isBaseNP((Symbol)modificandItem.label())){
  protected void complete(int start, int end)    throws RemoteException, TimeoutException {    for (int split = start; split < end; split++) {      if (maxParseTime > 0 && time.elapsedMillis() > maxParseTime) {	throw new TimeoutException(className + ": ran out of time (>" +				   maxParseTime + "ms) on sentence " +				   sentenceIdx);      }      if (useCommaConstraint && commaConstraintViolation(start, split, end)) {	if (debugCommaConstraint) {	  System.err.println(className +			     ": constraint violation at (start,split,end+1)=(" +			     start + "," + split + "," + (end + 1) +			     "); word at end+1 = " + getSentenceWord(end + 1));	}	// EVEN IF there is a constraint violation, we still try to find	// modificands that have not yet received their stop probabilities	// whose labels are baseNP, to see if we can add a premodifier	// (so that we can build baseNPs to the left even if they contain	// commas)	// TECHNICALLY, we should really try to build constituents on both	// the LEFT *and* RIGHT, but since base NPs are typically right-headed,	// this hack works well (at least, in English and Chinese), but it is	// a hack nonetheless	boolean modifierSide = Constants.LEFT;	int modificandStartIdx =  split + 1;	int modificandEndIdx =    end;	int modifierStartIdx  =   start;	int modifierEndIdx =      split;	if (debugComplete && debugSpans)	  System.err.println(className + ": modifying [" +			     modificandStartIdx + "," + modificandEndIdx +			     "]" + " with [" + modifierStartIdx + "," +			     modifierEndIdx + "]");	// for each possible modifier that HAS received its stop probabilities,	// try to find a modificand that has NOT received its stop probabilities	if (chart.numItems(modifierStartIdx, modifierEndIdx) > 0 &&	    chart.numItems(modificandStartIdx, modificandEndIdx) > 0) {	  Iterator modifierItems = chart.get(modifierStartIdx, modifierEndIdx);	  while (modifierItems.hasNext()) {	    CKYItem modifierItem = (CKYItem)modifierItems.next();	    if (modifierItem.stop()) {	      Iterator modificandItems =		chart.get(modificandStartIdx, modificandEndIdx);	      while (modificandItems.hasNext()) {		CKYItem modificandItem = (CKYItem)modificandItems.next();		if (!modificandItem.stop() && modificandItem.label()==baseNP) {		  if (debugComplete)		    System.err.println(className +				       ".complete: trying to modify\n\t" +				       modificandItem + "\n\twith\n\t" +				       modifierItem);		  joinItems(modificandItem, modifierItem, modifierSide);		}	      }	    }	  }	}	continue;      }      boolean modifierSide;      for (int sideIdx = 0; sideIdx < 2; sideIdx++) {	modifierSide = sideIdx == 0 ? Constants.RIGHT : Constants.LEFT;	boolean modifyLeft = modifierSide == Constants.LEFT;	int modificandStartIdx = modifyLeft ?  split + 1  :  start;	int modificandEndIdx =   modifyLeft ?  end        :  split;	int modifierStartIdx =   modifyLeft ?  start      :  split + 1;	int modifierEndIdx =     modifyLeft ?  split      :  end;	if (debugComplete && debugSpans)	  System.err.println(className + ": modifying [" +			     modificandStartIdx + "," + modificandEndIdx +			     "]" + " with [" + modifierStartIdx + "," +			     modifierEndIdx + "]");	// for each possible modifier that HAS received its stop probabilities,	// try to find a modificand that has NOT received its stop probabilities	if (chart.numItems(modifierStartIdx, modifierEndIdx) > 0 &&	    chart.numItems(modificandStartIdx, modificandEndIdx) > 0) {	  Iterator modifierItems = chart.get(modifierStartIdx, modifierEndIdx);	  while (modifierItems.hasNext()) {	    CKYItem modifierItem = (CKYItem)modifierItems.next();	    if (modifierItem.stop()) {	      Iterator modificandItems =		chart.get(modificandStartIdx, modificandEndIdx);	      while (modificandItems.hasNext()) {		CKYItem modificandItem = (CKYItem)modificandItems.next();		if (!modificandItem.stop() &&		    derivationOrderOK(modificandItem, modifierSide)) {		/*		if (!modificandItem.stop()) {		*/		  if (debugComplete)		    System.err.println(className +				       ".complete: trying to modify\n\t" +				       modificandItem + "\n\twith\n\t" +				       modifierItem);		  joinItems(modificandItem, modifierItem, modifierSide);		}	      }	    }	  }	}      }    }    addUnariesAndStopProbs(start, end);    chart.prune(start, end);  }