arXiv:2401.02051 · 中英对照阅读
启发式算法演化:利用大型语言模型实现高效自动算法设计
Evolution of Heuristics: Towards Efficient Automatic Algorithm Design Using Large Language Model
中文速览
手工设计高效启发式算法既费时又依赖专家经验,单靠大语言模型也常难以稳定想出好办法。研究提出 EoH,让大语言模型先用自然语言写出算法思路,再转成代码,并通过进化搜索不断组合、修改和筛选这些思路与代码。它在三个经典组合优化问题上整体胜过多种人工算法和自动设计方法;尤其在在线装箱问题上,用较少的大模型调用就找到了优于常用人工算法的启发式。这个方法把“想法”和“实现”一起迭代,有望让算法设计更省力、更高效,也减少对手工规则和领域经验的依赖。
摘要
启发式算法广泛用于处理复杂的搜索与优化问题。然而,人工设计启发式算法往往非常耗费劳动,且需要丰富的工作经验和知识。本文提出了启发式算法演化(EoH),这是一种新颖的进化范式,结合大型语言模型(LLMs)与进化计算(EC)方法,实现自动启发式算法设计(AHD)。EoH 以自然语言表述启发式算法的构想,称为思路。随后,大型语言模型(LLMs)将其转化为可执行代码。在进化搜索框架中同时演化思路与代码,使其能够高效、有效地生成高性能启发式算法。在三个广泛研究的组合优化基准问题上进行的实验表明,EoH 的表现优于常用的人工设计的启发式算法以及包括 FunSearch 在内的其他近期自动启发式算法设计(AHD)方法。尤其是,在计算预算较低(以对大型语言模型(LLMs)的查询次数衡量)的情况下,EoH 生成的启发式算法显著优于在线装箱问题中广泛使用的人工设计基线算法。
Heuristics are widely used for dealing with complex search and optimization problems. However, manual design of heuristics can be often very labour extensive and requires rich working experience and knowledge. This paper proposes Evolution of Heuristic (EoH), a novel evolutionary paradigm that leverages both Large Language Models (LLMs) and Evolutionary Computation (EC) methods for Automatic Heuristic Design (AHD). EoH represents the ideas of heuristics in natural language, termed thoughts. They are then translated into executable codes by LLMs. The evolution of both thoughts and codes in an evolutionary search framework makes it very effective and efficient for generating high-performance heuristics. Experiments on three widely studied combinatorial optimization benchmark problems demonstrate that EoH outperforms commonly used handcrafted heuristics and other recent AHD methods including FunSearch. Particularly, the heuristic produced by EoH with a low computational budget (in terms of the number of queries to LLMs) significantly outperforms widely-used human hand-crafted baseline algorithms for the online bin packing problem.
术语表
- Heuristics
- 启发式算法
- search and optimization problems
- 搜索与优化问题
- Evolution of Heuristic (EoH)
- 启发式算法演化(EoH)
- Large Language Models (LLMs)
- 大型语言模型(LLMs)
- Evolutionary Computation (EC)
- 进化计算(EC)
- Automatic Heuristic Design (AHD)
- 自动启发式算法设计(AHD)
- thoughts
- 思路
- evolutionary search framework
- 进化搜索框架
- handcrafted heuristics
- 人工设计的启发式算法
- combinatorial optimization
- 组合优化
- benchmark problems
- 基准问题
- FunSearch
- FunSearch
- online bin packing problem
- 在线装箱问题
- simulated annealing
- 模拟退火
- tabu search
- 禁忌搜索
- iterated local search
- 迭代局部搜索
- hyper-heuristics
- 超启发式
- Genetic Programming (GP)
- 遗传编程(GP)
- permissible primitives
- 可用原语
- mutation operations
- 变异操作
- prompt engineering
- 提示工程
- in-context learning
- 上下文学习
- space of functions
- 函数空间
- heuristic selection
- 启发式算法选择
- algorithmic components
- 算法组件
- population of candidate heuristics
- 候选启发式算法种群
- domain knowledge
- 领域知识
- domain model training
- 领域模型训练