adding examples, and source code for template engine