concepts.dm.pdsketch.planners.optimistic_search.solve_optimistic_plan#

solve_optimistic_plan(executor, state, goal_expr, actions, *, csp_max_generator_trials=3, verbose=False)[source]#

Solve an optimistic plan using the DPLL+Sampling algorithm.

Parameters:
  • executor (PDSketchExecutor) – the executor.

  • state (State) – the initial state.

  • goal_expr (str | ValueOutputExpression) – the goal expression.

  • actions (Sequence[OperatorApplier]) – a sequence of partially grounded actions.

  • csp_max_generator_trials (int) – the maximum number of trials for calling CSP generators.

  • verbose (bool) – whether to print verbose information.

Returns:

a list of actions that solves the plan, or None if no solution is found.

Return type:

Tuple[State, ConstraintSatisfactionProblem, List[OperatorApplier] | None]