def METHOD_NAME(factor, *args, **kwargs):
  """A transformation with auxiliary output.
  Turns all keyword parameters into positional ones.
  On entry, append the values of the keyword arguments to the positional
  arguments. On exit, take a list of results and recreate a dictionary
  from the tail of the results. The auxiliary output is the list of
  keyword keys.
  """
  kwargs_keys = kwargs.keys()
  new_args = tuple(kwargs[k] for k in kwargs_keys)
  new_kwargs = dict(factor=factor)
  results = yield args + new_args, new_kwargs  # Yield transformed (args, kwargs)
  # Assume results correspond 1:1 to the args + new_args
  assert len(results) == len(args) + len(new_args)
  aux_output = len(new_args)
  yield (results[0:len(args)],
         dict(zip(kwargs_keys, results[len(args):]))), aux_output