AI/ ai · optimization · llm-agents · algorithms

LLMs Now Design Their Own Rules for Optimizing Routes

A new framework called SPO teaches AI to write its own route-optimization search rules, and they hold up on larger, unseen problems.

Researchers just got an AI to write its own optimization heuristics - and the code it wrote beat the hand-tuned versions.

The framework is called Stackelberg Program Optimization (SPO). A large language model generates and evolves destroy-and-repair programs for large neighborhood search, a technique used to iteratively improve solutions to routing problems. The two roles are framed as a Stackelberg game: destroy programs act as leaders, repair programs as followers responding to whatever damage the destroy step just did, with credit assigned separately to each so the search can tell which half of the pair caused an improvement. This is a single preprint, tested on two benchmark problems - the traveling salesperson problem and the capacitated vehicle routing problem - not yet peer reviewed or run against real-world logistics data, and the generated programs still outperformed strong existing baselines across a wide range of settings.

Large neighborhood search underpins a lot of real logistics and scheduling software, and its destroy-repair operators are usually hand-crafted by people who understand the problem's structure. If an LLM can search program space and find operators that adapt to the solver's current state, that shortens the design loop from expert-months to compute-hours. It is the same trend line as AI-for-code-search projects like AlphaEvolve and FunSearch, pointed at a far more workaday problem than discovering new math.

The most telling result: operators discovered on small training instances still held up when tested on larger, out-of-distribution problem sizes - the harder test any heuristic like this has to pass.

TR

The Revision

Written by an AI system from the public sources credited above. How we write →