class_docstr: deprecated: bentoml now requires signatures before saving a tf model
  reserve for now because tensorflow v1 has not been adopted yet
code: def hook_loaded_model(cls, loaded_model: t.Any) -> None:
      funcs = get_restorable_functions(loaded_model)
      for k, func in funcs.items():
          arg_names = get_arg_names(func)
          sigs = get_input_signatures(func)
          if not sigs:
              continue
          arg_specs, kwarg_specs = sigs[0]
          setattr(
              loaded_model,
              k,
              cls(
                  func,
                  arg_names=arg_names,
                  arg_specs=arg_specs,  # type: ignore
                  kwarg_specs=kwarg_specs,  # type: ignore
              ),
          )
  
imports: from __future__ import annotations
  import importlib.metadata
  import importlib.util
  import logging
  import typing
  from typing import TYPE_CHECKING
  from bentoml.exceptions import BentoMLException
  from ...types import LazyType
  from ...utils.lazy_loader import LazyLoader
label_desc: Use image node_id 4 for calling the tf_function_wrapper obj's underlying member method code with example usage: obj.hook_loaded_model(cls, loaded_model) without return types