Large Language Models can solve a wide range of tasks from just a few examples, but they remain difficult to steer and lack a capability essential for building reliable software at scale: the modular composition of computations under enforceable contracts. As a result, they are typically embedded in larger software pipelines that use domain-specific knowledge to decompose tasks and improve reliability through validation and search. Yet the complexity of writing, tuning, and maintaining such pipelines has so far limited their sophistication. We propose oracular programming: a foundational paradigm for integrating traditional, explicit computations with inductive oracles such as LLMs. It rests on two directing principles: the full separation of core and search logic, and the treatment of few-shot examples as grounded and evolvable program components. Within this paradigm, experts express high-level problem-solving strategies as programs with unresolved choice points. These choice points are resolved at runtime by LLMs, which generalize from user-provided examples of correct and incorrect decisions. An oracular program is composed of three orthogonal components: a strategy that consists of a nondeterministic program with choice points that can be reified into a search tree, a policy that specifies how to navigate this tree with the help of LLM oracles, and a set of demonstrations that describe successful and unsuccessful tree navigation scenarios across diverse problem instances. Each component is expressed in a dedicated programming language and can be independently improved or substituted. We address the key programming language design challenges of modularly composing oracular programs and enforcing consistency between their components as they evolve.


翻译:大型语言模型仅需少量示例即可解决广泛任务,但其行为仍难以精确引导,且缺乏构建规模化可靠软件所需的核心能力:在可执行契约下的模块化计算组合。因此,它们通常被嵌入到更庞大的软件流程中,这些流程利用领域特定知识来分解任务,并通过验证与搜索提升可靠性。然而,此类流程的编写、调优与维护复杂度迄今仍限制着其精密度发展。我们提出神谕编程:一种将传统显式计算与LLM等归纳式神谕相融合的基础范式。该范式基于两大指导原则:核心逻辑与搜索逻辑的完全分离,以及将少样本示例视为可落地且可演化的程序组件。在此范式中,专家将高层问题解决策略表达为包含未解析决策点的程序。这些决策点在运行时由LLM根据用户提供的正误决策示例进行泛化解析。神谕程序由三个正交组件构成:由可具化为搜索树的非确定性程序组成的策略,规定如何借助LLM神谕导航该树的策略,以及描述跨不同问题实例的树导航成功与失败场景的演示集。每个组件均通过专用编程语言表达,并可独立改进或替换。我们解决了神谕编程中模块化组合程序及确保组件演化间一致性的关键编程语言设计挑战。

0
下载
关闭预览

相关内容

人们为了让计算机解决各种棘手的问题,使用编程语言 编写程序代码并通过计算机运算得到最终结果的过程。
大型语言模型(LLM)赋能的知识图谱构建:综述
专知会员服务
56+阅读 · 2025年10月24日
LLM in Medical Domain: 大语言模型在医学领域的应用
专知会员服务
103+阅读 · 2023年6月17日
绝对干货!NLP预训练模型:从transformer到albert
新智元
13+阅读 · 2019年11月10日
NLP通用模型诞生?一个模型搞定十大自然语言常见任务
人工智能头条
10+阅读 · 2018年6月29日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
VIP会员
最新内容
内省扩散语言模型
专知会员服务
1+阅读 · 今天14:42
国外反无人机系统与技术动态
专知会员服务
2+阅读 · 今天12:48
大规模作战行动中的战术作战评估(研究论文)
专知会员服务
3+阅读 · 今天12:21
未来的海战无人自主系统
专知会员服务
2+阅读 · 今天12:05
美军多域作战现状分析:战略、概念还是幻想?
专知会员服务
4+阅读 · 今天11:52
无人机与反无人机系统(书籍)
专知会员服务
16+阅读 · 今天6:45
美陆军2026条令:安全与机动支援
专知会员服务
6+阅读 · 今天5:49
相关VIP内容
大型语言模型(LLM)赋能的知识图谱构建:综述
专知会员服务
56+阅读 · 2025年10月24日
LLM in Medical Domain: 大语言模型在医学领域的应用
专知会员服务
103+阅读 · 2023年6月17日
相关基金
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2015年12月31日
国家自然科学基金
3+阅读 · 2015年12月31日
国家自然科学基金
1+阅读 · 2015年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
国家自然科学基金
1+阅读 · 2014年12月31日
国家自然科学基金
0+阅读 · 2014年12月31日
Top
微信扫码咨询专知VIP会员