code: def _create_parlai_format(dpath: str):
      datatypes = ["train", "valid", "test"]
      languages = ["En_", "Zh_", "Fr_", "Ko_", "Id_", "Jp_", "It_"]
      for language in languages:
          for datatype in datatypes:
              datatype_full = language + datatype + "_tmp"
              datatype_rename = language + datatype
              load_path = os.path.join(dpath, f"{datatype_full}.json")
              save_path = os.path.join(dpath, f"{datatype_rename}.txt")
              with PathManager.open(
                  load_path, "r", encoding="utf8"
              ) as f_read:
                  data = json.load(f_read)
              with PathManager.open(
                  save_path, "w", encoding="utf8"
              ) as f_write:
                  for content in data:
                      line_num = 0
                      personas = content["persona"]
                      dialogs = content["dialogue"]
                      for persona in personas:
                          line_num += 1
                          f_write.write(
                              str(line_num)
                              + " your persona:"
                              + persona
                              + "\n"
                          )
                      for utterance_A, utterance_B in dialogs:
                          line_num += 1
                          f_write.write(
                              f"{line_num} {utterance_A}\t{utterance_B}\n"
                          )
              os.remove(load_path)
  
imports: import parlai.core.build_data
  import os
  from parlai.core.build_data import DownloadableFile
  import json
  from parlai.utils.io import PathManager
label_desc: Use image node_id 2 for calling a global function with example usage: _create_parlai_format(dpath) without return types