templating library for issue #8