<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def deprecate( message: str, category: Any = DeprecationWarning, stacklevel: int = 0 ) -> Callable[[F], F]: """Return a decorator which adds a warning to functions."""


    def decorator(func: F) -> F:
        if not __debug__:
            return func

        @functools.wraps(func)
        def wrapper(*args, **kargs):  # type: ignore
            warnings.warn(message, category, stacklevel=stacklevel + 2)
            return func(*args, **kargs)

        return cast(F, wrapper)

    return decorator