Large Language Models (LLMs) are increasingly integrated into software applications, with prompts serving as the primary 'programming' interface to guide their behavior. As a result, a new software paradigm, promptware, has emerged, using natural language prompts to interact with LLMs and enabling complex tasks without traditional coding. Unlike traditional software, which relies on formal programming languages and deterministic runtime environments, promptware is based on ambiguous, unstructured, and context-dependent natural language and operates on LLMs as runtime environments, which are probabilistic and non-deterministic. These fundamental differences introduce unique challenges in prompt development. In practice, prompt development is largely ad hoc and experimental, relying on a time-consuming trial-and-error process - a challenge we term the 'promptware crisis.' To address this, we propose promptware engineering, a new methodology that adapts established software engineering principles to the process of prompt development. Building on decades of success in traditional software engineering, we envision a systematic framework that includes prompt requirements engineering, design, implementation, testing, debugging, and evolution. Unlike traditional software engineering, our framework is specifically tailored to the unique characteristics of prompt development. This paper outlines a comprehensive roadmap for promptware engineering, identifying key research directions and offering actionable insights to advance LLM-based software development.
翻译:大语言模型(LLMs)正日益集成到软件应用中,提示成为引导其行为的主要“编程”接口。因此,一种新的软件范式——提示件——应运而生,它利用自然语言提示与LLMs交互,无需传统编码即可实现复杂任务。传统软件依赖形式化编程语言和确定性运行时环境,而提示件则基于模糊、非结构化且依赖上下文的自然语言,并以LLMs作为运行时环境,后者具有概率性和非确定性。这些根本性差异给提示开发带来了独特的挑战。在实践中,提示开发在很大程度上是临时性和实验性的,依赖于耗时的试错过程——我们称之为“提示件危机”。为解决这一问题,我们提出提示工程,这是一种将成熟的软件工程原则应用于提示开发过程的新方法。借鉴传统软件工程数十年来的成功经验,我们设想一个系统化的框架,包括提示需求工程、设计、实现、测试、调试和演化。与传统软件工程不同,我们的框架专门针对提示开发的独特特性而定制。本文概述了提示工程的全面路线图,明确了关键研究方向,并为推进基于LLM的软件开发提供了可操作的见解。