code: def _item_cmp(x, y, sort):
      if isinstance(sort, str):
          return _val_cmp(x, y, sort)
      for part in sort:
          part_cmp = _val_cmp(x, y, part)
          if part_cmp != 0:
              return part_cmp
      return 0
  
imports: import functools
  import logging
  import os
  import sys
  import shutil
  import typing
  import click
  from guild import ansi_util
  from guild import config
label_desc: Use image node_id 12 for calling a global function with example usage: _item_cmp(x, y, sort) and returns: int, _val_cmp, part_cmp