code: def ds_add(args):
      print(
          "Adding files/folder/links to dataset id {}".format(args.id)
      )
      check_null_id(args)
      print_args(args)
      ds = Dataset.get(dataset_id=args.id)
      num_files = 0
      for file in args.files or []:
          num_files += ds.add_files(
              path=file,
              recursive=not args.non_recursive,
              verbose=args.verbose,
              dataset_path=args.dataset_folder or None,
              wildcard=args.wildcard,
              max_workers=args.max_workers,
          )
      for link in args.links or []:
          num_files += ds.add_external_files(
              link,
              dataset_path=args.dataset_folder or None,
              recursive=not args.non_recursive,
              verbose=args.verbose,
              wildcard=args.wildcard,
              max_workers=args.max_workers,
          )
      message = "{} file{} added".format(
          num_files, "s" if num_files != 1 else ""
      )
      print(message)
      return 0
  
imports: import json
  import os
  import shutil
  from argparse import ArgumentParser, HelpFormatter
  from functools import partial
  from typing import Sequence
  from pathlib2 import Path
  import clearml.backend_api.session
  from clearml.datasets import Dataset
  from clearml.version import __version__
label_desc: Use image node_id 20 for calling a global function with example usage: ds_add(args) and returns: int