code: def cli(sys_argv):
      parser = argparse.ArgumentParser(
          description="This script serves a pretrained model",
          prog="ludwig serve",
          usage="%(prog)s [options]",
      )
  
      # ----------------
      # Model parameters
      # ----------------
      parser.add_argument(
          "-m", "--model_path", help="model to load", required=True
      )
  
      parser.add_argument(
          "-l",
          "--logging_level",
          default="info",
          help="the level of logging to use",
          choices=[
              "critical",
              "error",
              "warning",
              "info",
              "debug",
              "notset",
          ],
      )
  
      # ----------------
      # Server parameters
      # ----------------
      parser.add_argument(
          "-p",
          "--port",
          help="port for server (default: 8000)",
          default=8000,
          type=int,
      )
  
      parser.add_argument(
          "-H",
          "--host",
          help="host for server (default: 0.0.0.0)",
          default="0.0.0.0",
      )
  
      parser.add_argument(
          "-ao",
          "--allowed_origins",
          nargs="*",
          help="A list of origins that should be permitted to make cross-origin requests. "
          'Use "*" to allow any origin. See https://www.starlette.io/middleware/#corsmiddleware.',
      )
  
      add_contrib_callback_args(parser)
      args = parser.parse_args(sys_argv)
  
      args.callbacks = args.callbacks or []
      for callback in args.callbacks:
          callback.on_cmdline("serve", *sys_argv)
  
      args.logging_level = get_logging_level_registry()[
          args.logging_level
      ]
      logging.getLogger("ludwig").setLevel(args.logging_level)
      global logger
      logger = logging.getLogger("ludwig.serve")
  
      print_ludwig("Serve", LUDWIG_VERSION)
  
      run_server(
          args.model_path, args.host, args.port, args.allowed_origins
      )
  
imports: import argparse
  import io
  import json
  import logging
  import os
  import sys
  import tempfile
  import pandas
  import torch
  from torchvision.io import decode_image
  from ludwig.api import LudwigModel
  from ludwig.constants import AUDIO, COLUMN
  from ludwig.contrib import add_contrib_callback_args
  from ludwig.globals import LUDWIG_VERSION
  from ludwig.utils.print_utils import get_logging_level_registry, print_ludwig
  from ludwig.utils.server_utils import NumpyJSONResponse
label_desc: Use image node_id 7 for calling a global function with example usage: cli(sys_argv) without return types