code: public static void annotateChunkText(CoreMap chunk, Class tokenTextKey)
    {
      List<CoreLabel> chunkTokens = chunk.get(CoreAnnotations.TokensAnnotation.class);
      String text = getTokenText(chunkTokens, tokenTextKey);
      chunk.set(CoreAnnotations.TextAnnotation.class, text);
    }
docs: Annotates a CoreMap representing a chunk with text information
  TextAnnotation - String representing tokens in this chunks (token text separated by space)
  @param chunk - CoreMap to be annotated
  @param tokenTextKey - Key to use to find the token text