Added support for creating templates from scratch