template for subgoal