You mean a global, module level dict? or passing a dict as argument to the yield statement? The latter will not solve the verbosity problem.