code: def gen_json_files(
      is_row_based,
      rows,
      dim,
      auto_id,
      str_pk,
      float_vector,
      data_fields,
      file_nums,
      multi_folder,
      file_type,
      err_type,
      force,
      **kwargs,
  ):
      # gen json files
      files = []
      start_uid = 0
      # make sure pk field exists when not auto_id
      if (not auto_id) and (DataField.pk_field not in data_fields):
          data_fields.append(DataField.pk_field)
      for i in range(file_nums):
          file_name = gen_file_name(
              is_row_based=is_row_based,
              rows=rows,
              dim=dim,
              auto_id=auto_id,
              str_pk=str_pk,
              float_vector=float_vector,
              data_fields=data_fields,
              file_num=i,
              file_type=file_type,
              err_type=err_type,
          )
          file = f"{data_source}/{file_name}"
          if multi_folder:
              subfolder = gen_subfolder(
                  root=data_source, dim=dim, rows=rows, file_num=i
              )
              file = f"{data_source}/{subfolder}/{file_name}"
          if not os.path.exists(file) or force:
              if is_row_based:
                  gen_row_based_json_file(
                      row_file=file,
                      str_pk=str_pk,
                      float_vect=float_vector,
                      data_fields=data_fields,
                      rows=rows,
                      dim=dim,
                      start_uid=start_uid,
                      err_type=err_type,
                      **kwargs,
                  )
              else:
                  gen_column_base_json_file(
                      col_file=file,
                      str_pk=str_pk,
                      float_vect=float_vector,
                      data_fields=data_fields,
                      rows=rows,
                      dim=dim,
                      start_uid=start_uid,
                      err_type=err_type,
                      **kwargs,
                  )
              start_uid += rows
          if multi_folder:
              files.append(f"{subfolder}/{file_name}")
          else:
              files.append(file_name)
      return files
  
imports: import copy
  import json
  import os
  import time
  import numpy
  import pandas
  import random
  from faker import Faker
  from sklearn import preprocessing
  from common.common_func import gen_unique_str
  from common.minio_comm import copy_files_to_minio
  from utils.util_log import test_log
label_desc: Use image node_id 18 for calling a global function with example usage: gen_json_files(is_row_based, rows, dim, auto_id, str_pk, float_vector, data_fields, file_nums, multi_folder, file_type, err_type, force) and returns: files