Add a template and a demo for regression