arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2503.18809cs.AIcs.LG
收藏

基于LLM生成启发式的经典规划:用Python代码挑战现有技术水平

Classical Planning with LLM-Generated Heuristics: Challenging the State of the Art with Python Code

University of Oxford(牛津大学);Federal University of Rio Grande do Sul(里约格兰德杜斯阿勒斯联邦大学);Linköping University(_linköping大学)

Augusto B. Corrêa, André G. Pereira, Jendrik Seipp

AI总结:

本文提出用LLM生成领域相关的Python启发式函数,在贪心最佳优先搜索中评估并选择最强函数,从而在经典规划中超越最先进的领域无关启发式,甚至与最强的学习算法竞争。

摘要:

近年来,大型语言模型(LLMs)在各种人工智能问题中展现出了卓越的能力。然而,即使提供了规划任务的详细定义,它们也无法可靠地进行规划。改进其规划能力的尝试,如思维链提示、微调和显式“推理”,仍然会产生错误的计划,并且通常无法泛化到更大的任务。在本文中,我们展示了如何使用LLMs生成正确的计划,即使对于规模不断增加的分布外任务也是如此。对于给定的规划领域,我们要求LLM以Python代码的形式生成多个领域相关的启发式函数,在贪心最佳优先搜索中在一组训练任务上评估它们,并选择最强的那个。由此产生的LLM生成的启发式函数在经典规划中解决的未见测试任务比最先进的领域无关启发式函数更多。它们甚至与最强的领域相关规划学习算法具有竞争力。这些发现尤其引人注目,因为我们的概念验证实现基于未优化的Python规划器,而基线都建立在高度优化的C++代码之上。在某些领域中,LLM生成的启发式函数扩展的状态比基线更少,这表明它们不仅计算高效,而且有时甚至比最先进的启发式函数更具信息量。总的来说,我们的结果表明,采样一组规划启发式函数程序可以显著提高LLMs的规划能力。

英文摘要:

In recent years, large language models (LLMs) have shown remarkable capabilities in various artificial intelligence problems. However, they fail to plan reliably, even when prompted with a detailed definition of the planning task. Attempts to improve their planning capabilities, such as chain-of-thought prompting, fine-tuning, and explicit "reasoning" still yield incorrect plans and usually fail to generalize to larger tasks. In this paper, we show how to use LLMs to generate correct plans, even for out-of-distribution tasks of increasing size. For a given planning domain, we ask an LLM to generate several domain-dependent heuristic functions in the form of Python code, evaluate them on a set of training tasks within a greedy best-first search, and choose the strongest one. The resulting LLM-generated heuristics solve many more unseen test tasks than state-of-the-art domain-independent heuristics for classical planning. They are even competitive with the strongest learning algorithm for domain-dependent planning. These findings are especially remarkable given that our proof-of-concept implementation is based on an unoptimized Python planner and the baselines all build upon highly optimized C++ code. In some domains, the LLM-generated heuristics expand fewer states than the baselines, revealing that they are not only efficiently computable, but sometimes even more informative than the state-of-the-art heuristics. Overall, our results show that sampling a set of planning heuristic function programs can significantly improve the planning capabilities of LLMs.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑