Skip to Content
You are currently on the new version of our website. Access the old version .
MathematicsMathematics
  • Article
  • Open Access

9 August 2025

20 Pages

Domain-Aware Reinforcement Learning for Prompt Optimization

,
,
,
,
and
1
School of Computer and lnformation Engineering, Shanghai Polytechnic University, Shanghai 201209, China
2
Department of Engineering, Durham University, Durham DH1 3LE, UK
3
College of Sciences, China Jiliang University, Hangzhou 310018, China
*
Author to whom correspondence should be addressed.

Abstract

Prompt engineering provides an efficient way to adapt large language models (LLMs) to downstream tasks without retraining model parameters. However, designing effective prompts can be challenging, especially when model gradients are unavailable and human expertise is required. Existing automated methods based on gradient optimization or heuristic search exhibit inherent limitations under black box or limited-query conditions. We propose Domain-Aware Reinforcement Learning for Prompt Optimization (DA-RLPO), which treats prompt editing as a sequential decision process and leverages structured domain knowledge to constrain candidate edits. Our experimental results show that DA-RLPO achieves higher accuracy than baselines on text classification tasks and maintains robust performance with limited API calls, while also demonstrating effectiveness on text-to-image and reasoning tasks.

Article Metrics

Citations

Article Access Statistics

Multiple requests from the same IP address are counted as one view.