用分离推理与执行的框架,让大模型高效解决多约束规划问题。
Programming over Thinking: Efficient and Robust Multi-Constraint Planning
- 将推理过程与代码执行解耦,生成可复用的确定性求解函数。
- 在TravelPlanner上达93.1%成功率,比最佳基线提升61.6%,耗时减少4.67倍。
- 适合需要高可靠、低延迟多约束求解的场景,如智能调度与路径规划。
多约束规划需识别、评估并优化候选方案以满足多个可能冲突的约束。现有大语言模型方法存在根本局限:纯推理范式依赖长自然语言链,随约束增加易出现不一致、错误累积和成本激增;而结合编码或求解器的策略缺乏灵活性,常需从头生成特定代码或依赖固定求解器,难以捕捉跨任务的通用逻辑。为此,我们提出可扩展代码规划引擎SCOPE,将查询相关推理与通用代码执行解耦。通过分离设计,SCOPE生成的求解函数具备一致性、确定性且可在不同查询间复用,仅需调整输入参数。该框架在性能与效率上均达当前最优:使用GPT-4o时,在TravelPlanner上实现93.1%的成功率,较最佳基线(CoT)提升61.6%,推理成本降低1.4倍,耗时缩短约4.67倍。代码已开源:https://github.com/DerrickGXD/SCOPE。
原文摘要 · Abstract (English)
Multi-constraint planning involves identifying, evaluating, and refining candidate plans while satisfying multiple, potentially conflicting constraints. Existing large language model (LLM) approaches face fundamental limitations in this domain. Pure reasoning paradigms, which rely on long natural language chains, are prone to inconsistency, error accumulation, and prohibitive cost as constraints compound. Conversely, LLMs combined with coding- or solver-based strategies lack flexibility: they often generate problem-specific code from scratch or depend on fixed solvers, failing to capture generalizable logic across diverse problems. To address these challenges, we introduce the Scalable COde Planning Engine (SCOPE), a framework that disentangles query-specific reasoning from generic code execution. By separating reasoning from execution, SCOPE produces solver functions that are consistent, deterministic, and reusable across queries while requiring only minimal changes to input parameters. SCOPE achieves state-of-the-art performance while lowering cost and latency. For example, with GPT-4o, it reaches 93.1% success on TravelPlanner, a 61.6% gain over the best baseline (CoT) while cutting inference cost by 1.4x and time by ~4.67x. Code is available at https://github.com/DerrickGXD/SCOPE.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。