TempLe: Learning Template of Transitions for Sample Efficient Multi-task RL