code: def parse_ssurgeon_edits(ssurgeon_text):
      ssurgeon_text = ssurgeon_text.strip()
      ssurgeon_blocks = re.split("\n\n+", ssurgeon_text)
      ssurgeon_edits = []
      for idx, block in enumerate(ssurgeon_blocks):
          lines = block.split("\n")
          comments = [
              line[1:].strip() for line in lines if line.startswith("#")
          ]
          notes = " ".join(comments)
          lines = [
              x.strip()
              for x in lines
              if x.strip() and not x.startswith("#")
          ]
          if len(lines) == 0:
              # was a block of entirely comments
              continue
          semgrex = lines[0]
          ssurgeon = lines[1:]
          ssurgeon_edits.append(
              SsurgeonEdit(semgrex, ssurgeon, "%d" % (idx + 1), notes)
          )
      return ssurgeon_edits
  
imports: import argparse
  import copy
  import os
  import re
  import sys
  from stanza.models.common.utils import misc_to_space_after, space_after_to_misc
  from stanza.protobuf import SsurgeonRequest, SsurgeonResponse
  from stanza.server import java_protobuf_requests
  from stanza.utils.conll import CoNLL
  from stanza.models.common.doc import ID, TEXT, LEMMA, UPOS, XPOS, FEATS, HEAD, DEPREL, DEPS, MISC, START_CHAR, END_CHAR, NER, Word, Token, Sentence
label_desc: Use image node_id 1 for calling a global function with example usage: parse_ssurgeon_edits(ssurgeon_text) and returns: ssurgeon_edits