langgoap.repair_plan#
- repair_plan(plan, current_state, goal, actions, *, current_step=0, blacklisted_actions=None)[source]#
Repair a partially-executed plan by reusing its valid prefix.
- Parameters:
plan (Plan) – The original plan.
current_state (PlanningState) – Current world state (may have drifted from expected).
goal (GoalSpec) – The goal to achieve.
actions (list[ActionSpec]) – Available actions for replanning.
current_step (int) – First step to consider (steps before this were already executed and must not be reconsidered).
blacklisted_actions (list[str] | None) – Action names to exclude from suffix replanning.
- Returns:
A
RepairResultdescribing the outcome.repaired_planisNoneonly when no suffix plan could be found and the goal remains unsatisfied.- Return type: