First version that unifies generators and templates