Refactor_to_Template