Added template to encapsulate the framework