Semantics-Behavior Coupled Bayesian Optimization for Efficient Black-Box Prompt Search

Loading...
Thumbnail Image

Journal Title

Journal ISSN

Volume Title

Publisher

University of Waterloo

Abstract

Large language models (LLMs) are highly sensitive to prompt design, making prompt optimization important in black-box settings where models are accessible only through API calls. This thesis proposes DualBO, a semantics-behavior coupled Bayesian optimization framework for efficient prompt search. DualBO represents each prompt using two complementary views: a behavioral correctness vector computed on a controlled minibatch, and a semantic embedding of the prompt text. These views are combined in a dynamic Gaussian Process surrogate, where semantic similarity helps reduce uncertainty early in optimization and behavioral evidence provides stronger task alignment as more prompts are evaluated. DualBO also introduces staged strategy-oriented candidate generation, which first generates diverse rewriting strategies and then instantiates them into concrete prompt candidates. This improves search-space coverage compared with direct local rewriting. Experiments on ETHOS, ARC, MMLU-Pro, and HotpotQA using GPT-5.4-mini and DeepSeek-V3.2 show that DualBO consistently improves over semantic-only and behavior-only Bayesian optimization baselines. It is also competitive with reflection-based methods such as Reflexion and ProTeGi while requiring substantially fewer model calls. Overall, this thesis demonstrates that combining semantic smoothness, behavior-grounded task alignment, and diversity-aware candidate generation improves the stability and efficiency of black-box prompt optimization under limited evaluation budgets.

Description

Citation

Endorsement

Review

Supplemented By

Referenced By