Using templates with low-level formatting commands defeats the point in LaTeX being about high-level semantic macros. Why not define an \author macro? The YAML input and the input using a well-crafted set of macros would be very similar, to the point where I feel like the OP is really misunderstanding what LaTeX is about.