cs.AIMay 19, 2025

Prompt Stability Matters: Evaluating and Optimizing Auto-Generated Prompt in General-Purpose Systems

Authors: Ke Chen, Xucheng Yu, Yufei Zhou, Haohan Wang

Organizations: School of Information Sciences, University of Illinois Urbana-Champaign, Urbana, USA · Department of Economics, Duke University, Durham, USA

Abstract

Automatic prompt generation plays a crucial role in enabling general-purpose multi-agent systems to perform diverse tasks autonomously. Existing methods typically evaluate prompts based on their immediate task performance, overlooking the intrinsic qualities that determine their reliability. This outcome-centric view not only limits interpretability but also fails to account for the inherent stochasticity of large language models (LLMs). In this work, we bring attention to prompt stability-the consistency of model responses across repeated executions-as a key factor for building robust and effective prompt generation systems. To quantify this, we propose semantic stability as a criterion for assessing the response consistency of prompts. Based on the proposed metric, we developed the first stability-aware general-purpose prompt generation system that leverages stability feedback to iteratively enhance both prompt quality and system-level performance. Furthermore, we establish a logical chain between prompt stability and task success by analyzing the structural dependencies within our system, proving stability as a necessary condition for effective system-level execution. Empirical results across general and domain-specific tasks demonstrate that our stability-aware framework improves both accuracy and output consistency. By shifting the focus from one-off results to persistent reliability, our work offers a new perspective on prompt design and contributes practical tools for building more trustworthy general-purpose systems. The UI and source code for our system are publicly available at: https://xucheng63.github.io/MyDataPilot/.

Figures & tables

Appendix figures & tables2 assets

Supplementary material from the paper’s appendix.

Appendix

Explore similar work

CardsList
  1. SePO: Self-Evolving Prompt Agent for System Prompt Optimization

    Jun 3, 2026Wangcheng Tao, Han Wu, Weng-Fai WongLLM Agent Self-ImprovementAutomatic Prompt Optimization

  2. Generalizable Self-Evolving Memory for Automatic Prompt Optimization

    Mar 23, 2026Guanbao Liang, Yuanchen Bei, Sheng Zhou +5Automatic Prompt OptimizationLanguage Model Self-Improvement

  3. MASPO: Joint Prompt Optimization for LLM-based Multi-Agent Systems

    May 7, 2026Zhexuan Wang, Xuebo Liu, Li Wang +4Multi-Agent LLM SystemsMulti-Agent System Optimization