code: def transform(src_file, dest_file):
      def transform_line(line):
          tokens = line.split("\t")
          output = tokens[0].replace(" ", "_") + " " + tokens[-1]
          return output
  
      def transform_sentence(sentence):
          global max_len
          lines = sentence.split("\n")
          max_len = max(max_len, len(lines))
          lines = [transform_line(line) for line in lines]
          sentence = "\n".join(lines)
          return sentence
  
      with open(src_file) as f:
          content = f.read()
      sentences = content.split("\n\n")
      sentences = [transform_sentence(s) for s in sentences]
      content = "\n\n".join(sentences)
      with open(dest_file, "w") as f:
          f.write(content)
  
label_desc: Use image node_id 1 for calling a global function with example usage: transform(src_file, dest_file) and returns: output, sentence