Representing Prompting Patterns with PDL: Compliance Agent Case Study

Fuente: arXiv
Gespeichert in:
Bibliographische Detailangaben
Hauptverfasser: Vaziri, Mandana, Mandel, Louis, Watanabe, Yuji, Kitahara, Hirokuni, Hirzel, Martin, Sailer, Anca
Format: Preprint
Veröffentlicht: 2025
Schlagworte:
Online-Zugang:
Tags: Tag hinzufügen
Keine Tags, Fügen Sie den ersten Tag hinzu!
_version_ 1866909681050451968
author Vaziri, Mandana
Mandel, Louis
Watanabe, Yuji
Kitahara, Hirokuni
Hirzel, Martin
Sailer, Anca
author_facet Vaziri, Mandana
Mandel, Louis
Watanabe, Yuji
Kitahara, Hirokuni
Hirzel, Martin
Sailer, Anca
contents 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.
format Preprint
id arxiv_https___arxiv_org_abs_2507_06396
institution arXiv
publishDate 2025
record_format arxiv
spellingShingle Representing Prompting Patterns with PDL: Compliance Agent Case Study
Vaziri, Mandana
Mandel, Louis
Watanabe, Yuji
Kitahara, Hirokuni
Hirzel, Martin
Sailer, Anca
Artificial Intelligence
Machine Learning
Programming Languages
Software Engineering
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.
title Representing Prompting Patterns with PDL: Compliance Agent Case Study
topic Artificial Intelligence
Machine Learning
Programming Languages
Software Engineering
url https://arxiv.org/abs/2507.06396