code: def convert_dataset_section(config_name, section):
      sentences = []
      for doc in section:
          # the nt_ sentences (New Testament) in the HF version of OntoNotes
          # have blank named_entities, even though there was no original .name file
          # that corresponded with these annotations
          if config_name.startswith("english") and doc[
              "document_id"
          ].startswith("pt/nt"):
              continue
          for sentence in doc["sentences"]:
              words = sentence["words"]
              tags = [ID_TO_TAG[x] for x in sentence["named_entities"]]
              sentences.append(list(zip(words, tags)))
      return sentences
  
imports: import os
  from stanza.utils.default_paths import get_default_paths
  from stanza.utils.datasets.ner.utils import write_dataset
label_desc: Use image node_id 1 for calling a global function with example usage: convert_dataset_section(config_name, section) and returns: sentences