Prompt Stability in Code LLMs: Measuring Sensitivity across Emotion- and Personality-Driven Variations

Wei Ma, Yixiao Yang, Jingquan Ge, Xiaofei Xie, Lingxiao Jiang
9/17/2025
cs.SEcs.AI

No confident code implementation found for this paper. 3 possible matches can be shown below.

Abstract

Code generation models are widely used in software development, yet their sensitivity to prompt phrasing remains under-examined. Identical requirements expressed with different emotions or communication styles can yield divergent outputs, while most benchmarks emphasize only peak performance. We present PromptSE (Prompt Sensitivity Evaluation), a framework that creates semantically equivalent prompt variants with emotion and personality templates, and that evaluates stability using probability aware continuous scoring or using binary pass rates when logits are unavailable. The results are aggregated into a proposed area under curve metric (AUC-E) for cross model comparison. Across 14 models from three families (Llama, Qwen, and DeepSeek), our study shows that performance and stability behave as largely decoupled optimization objectives, and it reveals architectural and scale related patterns that challenge common assumptions about model robustness. The framework supports rapid screening for closed-source models as well as detailed stability analysis in research settings. PromptSE enables practitioners to quantify performance stability trade offs for deployment and model selection, positioning prompt stability as a complementary evaluation dimension alongside performance and fairness, and contributing to more trustworthy AI-assisted software development tools.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. 3 weaker matches are hidden by default — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{ma2025prompt,
  title  = {Prompt Stability in Code LLMs: Measuring Sensitivity across Emotion- and Personality-Driven Variations},
  author = {Wei Ma and Yixiao Yang and Jingquan Ge and Xiaofei Xie and Lingxiao Jiang},
  year   = {2025},
  eprint = {2509.13680},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2509.13680v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2509.13680.svg)](https://codeofpaper.com/paper/2509.13680)

Discussion