arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2507.06396cs.AIcs.LGcs.PLcs.SE
收藏

用PDL表示提示模式:合规智能体案例研究

Representing Prompting Patterns with PDL: Compliance Agent Case Study

IBM Research, Yorktown Heights, USA(IBM研究院,Yorktown Heights,美国);IBM Research, Tokyo, Japan(IBM研究院,Tokyo,日本)

Mandana Vaziri, Louis Mandel, Yuji Watanabe, Hirokuni Kitahara, Martin Hirzel, Anca Sailer

AI总结:

本文提出提示声明语言(PDL),通过将提示置于前沿并支持手动/自动调优,简化大语言模型提示工程;在合规智能体案例中,调优提示模式相比预设模式带来高达4倍性能提升。

摘要:

针对大语言模型的提示工程仍然复杂,现有框架要么通过限制性API隐藏复杂性,要么提供抗拒定制的不灵活预设模式——这使得复杂的智能体编程充满挑战。我们提出提示声明语言(PDL),一种新颖的提示表示方法,通过将提示置于前沿来应对这一根本性复杂性,支持手动和自动提示调优,同时捕获大语言模型调用与基于规则的代码及外部工具的组成。通过抽象掉此类组成的底层管道,PDL旨在提高程序员生产力,同时提供一种适合优化的声明式表示。本文通过一个合规智能体的真实案例研究展示了PDL的实用性。与使用预设智能体和提示模式相比,调优该智能体的提示模式带来了高达4倍的性能提升。

英文摘要:

Prompt engineering for LLMs remains complex, with existing frameworks either hiding complexity behind restrictive APIs or providing inflexible canned patterns that resist customization -- making sophisticated agentic programming challenging. We present the Prompt Declaration Language (PDL), a novel approach to prompt representation that tackles this fundamental complexity by bringing prompts to the forefront, enabling manual and automatic prompt tuning while capturing the composition of LLM calls together with rule-based code and external tools. By abstracting away the plumbing for such compositions, PDL aims at improving programmer productivity while providing a declarative representation that is amenable to optimization. This paper demonstrates PDL's utility through a real-world case study of a compliance agent. Tuning the prompting pattern of this agent yielded up to 4x performance improvement compared to using a canned agent and prompt pattern.

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

↑