import inspect


def _get_defaults(signature):
    """Create a dict of function parameters with defaults."""
    return {
        k: v.default
        for k, v in signature.items()
        if v.default is not inspect.Parameter.empty
    }