The purpose of learned macros is to speed up search in new problem instances.
A classical search algorithm expands a node by considering
low-level actions that can be applied to the current state.
We add successor states that can be reached by applying
the whole sequence of actions in a macro.
We order these macro successors before the regular successors of a state.
Macros affects neither the completeness nor the correctness
of the original algorithm.
The completeness of an original search algorithm is preserved
since SOL-EP removes no regular successors of a state.
Correctness is guaranteed by the following way of applying a macro to a state.
Given a state and a sequence of actions
(
in the competition system), we say that
is applicable to
if
can be applied to
,
,
where
and
is the state obtained by
applying
to
.
When a given state is expanded at runtime, many instantiations of a macro
could be applicable but only a few would actually be
shortcuts towards a goal state.
If all instantiations are considered,
the branching factor can significantly increase
and the induced overhead can be larger
than the potential savings achieved by the useful instantiations.
Therefore, the challenge is to select for state expansion only
a small number of good macro instantiations.
To determine what a ``good'' instantiation of a macro is,
we use a heuristic method called helpful macro pruning.
Helpful macro pruning
is based on the relaxed graphplan computation
that FF [12] performs for each evaluated state .
Given a state
, FF solves a relaxed problem,
where the initial state is the currently evaluated state,
the goal conditions are the same as in the real problem, and
the actions are relaxed by ignoring their delete effects.
This computation produces a relaxed plan
.
In FF, the relaxed plan is used to
heuristically evaluate problem states
and prune low-level actions in the search space
(helpful action pruning).
In addition, we use the relaxed plan to prune the set of macro-instantiations that will be used for node expansion. Since actions from the relaxed plan are often useful in the real world, we request that a selected macro and the relaxed plan match i.e., each action of the macro is part of the relaxed plan.