code: def run(
      self,
      invoke_method: str,
      content_types: Optional[List] = None,
      **kwargs,
  ):
      invoke_method = invoke_method.lower()
      if not content_types:
          content_types = []
  
      if invoke_method not in self.INVOKE_METHODS:
          raise NotImplementedError(
              f"invoke method={invoke_method} not implemented yet. Please select {self.INVOKE_METHODS}"
          )
  
      if invoke_method == "route":
          route_path = kwargs.get("path", "/predict")
          self.app.route("/", methods=["GET"])(self.index)
          self.app.route(
              route_path, methods=["POST"], content_types=content_types
          )(self.predict)
  
file_path: chitra/chitra/serve/cloud/aws_serverless.py
imports: from typing import Callable, List, Optional
  from chalice import Chalice, Rate
  from chitra.logging import logger
  from chitra.serve.cloud.base import CloudServer
label_desc: Use image node_id 4 for calling the ChaliceServer obj's underlying member method code with example usage: obj.run(invoke_method, content_types) without return types