code: protected String cleanUpLabel(final String label) {
      if (label == null || label.length() == 0) {
        return "ROOT";
        // String constants are always interned
      } else {
        return tlp.basicCategory(label);
      }
    }
docs: Remove things like hyphened functional tags and equals from the
  end of a node label.  This version always just returns the phrase
  structure category, or "ROOT" if the label was <code>null</code>.
  
  @param label The label from the treebank
  @return The cleaned up label (phrase structure category)