Generalizable Heuristic Generation Through LLMs with Meta-Optimization
About
Heuristic design with large language models (LLMs) has emerged as a promising approach for tackling combinatorial optimization problems (COPs). However, existing approaches often rely on manually predefined evolutionary computation (EC) heuristic-optimizers and single-task training schemes, which may constrain the exploration of diverse heuristic algorithms and hinder the generalization of the resulting heuristics. To address these issues, we propose Meta-Optimization of Heuristics (MoH), a novel framework that operates at the optimizer level, discovering effective heuristic-optimizers through the principle of meta-learning. Specifically, MoH leverages LLMs to iteratively refine a meta-optimizer that autonomously constructs diverse heuristic-optimizers through (self-)invocation, thereby eliminating the reliance on a predefined EC heuristic-optimizer. These constructed heuristic-optimizers subsequently evolve heuristics for downstream tasks, enabling broader heuristic exploration. Moreover, MoH employs a multi-task training scheme to promote its generalization capability. Experiments on classic COPs demonstrate that MoH constructs an effective and interpretable meta-optimizer, achieving state-of-the-art performance across various downstream tasks, particularly in cross-size settings. Our code is available at: https://github.com/yiding-s/MoH.
Related benchmarks
| Task | Dataset | Result | Rank | |
|---|---|---|---|---|
| Online Bin Packing | Online BPP (test) | Gap (%)0.032 | 120 | |
| Traveling Salesperson Problem | TSP N=200 (Generalization (128 instances)) | Optimality Gap0.177 | 35 | |
| Traveling Salesperson Problem | TSP N=1000 Generalization (128 instances) | Optimality Gap1.363 | 30 | |
| Traveling Salesperson Problem | TSP N=500 Generalization (128 instances) | Optimality Gap0.805 | 30 | |
| Traveling Salesperson Problem | TSP n=100 (train) | Objective Value7.766 | 26 | |
| Traveling Salesperson Problem | TSP-20 (train) | Objective Value3.84 | 17 | |
| Traveling Salesperson Problem | TSP-50 (train) | Objective Value5.715 | 17 | |
| Traveling Salesperson Problem | TSP Overall | Average Gap0.391 | 16 | |
| Capacitated Vehicle Routing Problem | CVRP (train) | CVRP Cost (20)4.704 | 4 | |
| Capacitated Vehicle Routing Problem | CVRP Generalization | Total Cost (Instance 100)15.563 | 4 |