def unwrap_function(func: Callable[..., Any]) -> Callable[..., Any]:
    """Unwraps staticmethod or classmethod to get the actual function."""
    if isinstance(func, (staticmethod, classmethod)):
        func = func.__func__
    return func
Unwraps staticmethod or classmethod to get the actual function.
ai/core/src/unitycatalog/ai/core/utils/callable_utils.py