Add template processor code