LLM-Evolved Pattern Generators for Optimal Classical Planning

Windy Phung, Dominik Drexler, Arnaud Lequen, Jendrik SeipparXiv 2026

TL;DR

This paper introduces the first method for learning domain-dependent heuristics for optimal classical planning that are admissible by design. By using an LLM-driven evolutionary framework to synthesize Python programs that generate pattern database (PDB) abstractions, the approach preserves the optimality guarantees of $A^*$ search while dramatically speeding up state evaluation times.

What Problem Does This Paper Address?

In classical planning, the goal is to find a sequence of actions that transitions a system from an initial state to a goal state. For optimal planning, we need the absolute lowest-cost plan, which typically requires $A^*$ search guided by an admissible heuristic (a function that never overestimates the remaining cost to the goal).

While machine learning has recently supercharged satisficing planning (finding any plan quickly), applying it to optimal planning is notoriously difficult. If a neural network predicts a heuristic value that is even slightly too high, the optimality guarantee of $A^*$ is ruined. Consequently, the strongest optimal planners still rely on domain-independent heuristics calculated from scratch for each task.

The authors address this gap: How can we leverage machine learning to exploit regularities across different tasks within the same domain (e.g., logistics or block stacking) without sacrificing the mathematical guarantee of admissibility?

Methods

Instead of training a model to predict heuristic values directly, the authors learn a pattern generator—a Python program that analyzes a planning task and outputs a collection of "patterns" (subsets of state variables). These patterns define abstractions used to build Pattern Databases (PDBs).

To ensure the final heuristic remains admissible when combining multiple PDBs, they use Saturated Cost Partitioning (SCP), a state-of-the-art technique that fractions out action costs among patterns so their total sum never overestimates the true cost. Because admissibility is baked into the PDB and SCP structure, the generator program can output any pattern collection, and the heuristic is still guaranteed to be admissible by construction.

To discover these domain-specific Python generators, the authors use OpenEvolve, an LLM-driven evolutionary program-synthesis framework.

Figure 2: The evolutionary pipeline. The engine (blue) cre- ates artifacts (orange) that are assessed by the evaluation components (green).

As shown in the evolutionary pipeline, the framework uses an LLM (Kimi K2.5) to mutate and improve candidate Python programs across a multi-island population grid (MAP-Elites). The fitness function evaluates the generated programs by running the resulting heuristics on small training tasks using the Fast Downward planning engine, optimizing for validity, fewer node expansions, and faster search times.

Datasets

  • Training: A subset of benchmarks from the Learning track of the International Planning Competition (IPC) 2023, totaling 129 tasks per domain.
  • Evaluation: The Autoscale benchmark set, providing 30 test tasks of increasing size across seven distinct domains: Blocksworld, Childsnack, Floortile, Miconic, Rovers, Satellite, and Transport.

Key Insights and Ideas

  • Programs as Generalizers: Evolving a generative program rather than a static set of patterns allows the system to handle test tasks of arbitrary size. The LLM distills the structural regularities of a domain into logic that scales.
  • The Guidance vs. Speed Trade-off: Exhaustive systematic baselines search through millions of small patterns, providing highly accurate per-state guidance but at a massive computational lookup cost. The LLM-evolved generators tend to create a smaller number of much larger, highly targeted patterns.
  • Admissibility via Architecture: By decoupling the learning mechanism (the LLM) from the admissibility guarantee (PDBs + SCP), the authors bypass the black-box safety issues typical of neural network heuristics.

Key Results

The evolved heuristic ($h^{\text{evo}}$) matched or exceeded the best systematic baselines in 5 out of the 7 evaluated domains, achieving the highest overall coverage in Childsnack and Transport.

Figure 4: Expansions until last f-layer: hevo vs. each base- line. Each point is one task; points below the diagonal indi- cate tasks where hevo requires fewer expansions.

As illustrated in the expansion plots, the systematic baselines often require fewer node expansions because they provide tighter per-state guidance. However, because $h^{\text{evo}}$ generates significantly fewer total patterns, its per-state evaluation time is orders of magnitude faster. This computational efficiency translates directly into lower total search times and higher task coverage on complex instances.

Limitations and Future Work

The method struggled in domains like Miconic and Floortile, where the uniform mathematical structure makes exhaustive, small-pattern systematic enumeration incredibly difficult to beat.

For future work, the authors suggest:

  1. Exposing the evolutionary loop to richer structural representations of the domain, such as causal graphs.
  2. Scaling up training sets to discover more complex generators.
  3. Obfuscating domain names during training to ensure the LLM relies purely on structural reasoning rather than memorized knowledge of classic planning benchmarks.

Summary updated

BibTeX
@misc{phung2026llm,
  author = {Windy Phung and Dominik Drexler and Arnaud Lequen and Jendrik Seipp},
  title = {{LLM-Evolved Pattern Generators for Optimal Classical Planning}},
  year = {2026},
  eprint = {2606.02438},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2606.02438},
}
Figure