human
Complete this python program:
def _build_preprocessed_function(func, processors, args_defaults, varargs, varkw):
assistant
#Here is the Python program you requested.

    """Build a preprocessed function with the same signature as `func`.
    Uses `exec` internally to build a function that actually has the same
    signature as `func.
    """
    format_kwargs = {'func_name': func.__name__}
    def mangle(name):
        return (('a' + uuid4().hex) + name)
    format_kwargs['mangled_func'] = mangled_funcname = mangle(func.__name__)
    def make_processor_assignment(arg, processor_name):
        template = "{arg}    =    {processor}({func},    '{arg}',    {arg})"
        return template.format(arg=arg, processor=processor_name, func=mangled_funcname)
    exec_globals = {mangled_funcname: func, 'wraps': wraps}
    defaults_seen = 0
    default_name_template = (('a' + uuid4().hex) + '_%d')
    signature = []
    call_args = []
    assignments = []
    star_map = {varargs: '*', varkw: '**'}
    def name_as_arg(arg):
        return (star_map.get(arg, '') + arg)
    for (arg, default) in args_defaults:
        if (default is NO_DEFAULT):
            signature.append(name_as_arg(arg))
        else:
            default_name = (default_name_template % defaults_seen)
            exec_globals[default_name] = default
            signature.append('='.join([name_as_arg(arg), default_name]))
            defaults_seen += 1
        if (arg in processors):
            procname = mangle(('_processor_' + arg))
            exec_globals[procname] = processors[arg]
            assignments.append(make_processor_assignment(arg, procname))
        call_args.append(name_as_arg(arg))
    exec_str = dedent('                                @wraps({wrapped_funcname})\n                                def    {func_name}({signature}):\n                                                {assignments}\n                                                return    {wrapped_funcname}({call_args})\n                                ').format(func_name=func.__name__, signature=',    '.join(signature), assignments='\n                '.join(assignments), wrapped_funcname=mangled_funcname, call_args=',    '.join(call_args))
    compiled = compile(exec_str, func.__code__.co_filename, mode='exec')
    exec_locals = {}
    exec_(compiled, exec_globals, exec_locals)
    new_func =...