arXiv(opens in a new tab)cs.AIAug 2026Cited by 1 paper on PaperVantage

Manuscript Offprint

arXiv:2608.28067

SEPO: Evidence-Grounded Prompt Optimization via Structural Editing

Xiaoyu Ma, Haoyue Liu, Yiwen Li, Jionghao Zhu, Zhichao Wang, Ye Chen, Xiaoying Tang

Abstract

Existing API-only prompt optimisers are often described as interpretable, but in practice, this usually means only post-hoc inspectability: each iteration still rewrites the prompt as one opaque string, leaving a trace of full-prompt diffs rather than localisable, machine-readable edits. This paper introduces SEPO (Structural, Evidence-grounded Prompt Optimization), a multi-trajectory prompt optimiser centred on edit-effect lineage feedback. Rather than treating each iteration as an isolated whole-prompt rewrite, SEPO locally edits stable, typed units in a two-layer prompt schema, links the target and realised structural operations of each edit to the examples it newly fixes or breaks, and carries this edit-effect record forward to guide later architect calls on the same search branch. This makes prompt optimisation addressable, attributable, and actionable. Across a 14-task held-out suite, SEPO improves over the strongest baseline, GEPA, by 3.1 pp on Llama-3.1-8B-Instruct and 2.2 pp on Qwen3-8B, reaching 61.9% and 73.3% macro accuracy. SEPO also lies on both the optimisation-time and test-time Pareto frontiers, spending 2.9M optimisation tokens versus 4.1M for GEPA and producing prompts over 5× shorter.

1 Introduction

Prompt optimisation has become a de-facto recipe for adapting frozen LLMs to new tasks without weight updates: an architect LLM proposes a rewrite, the candidate is scored on a training set, and the cycle repeats (Ramnath et al., 2025; Yang et al., 2024; Pryzant et al., 2023; Agrawal et al., 2026; Yuksekgonul et al., 2025). Despite being commonly described as interpretable, most API-only prompt optimisers still expose the same underlying interface: each iteration rewrites the prompt

Figure

Figure 1: SEPO at a glance. SEPO makes localised, evidence-grounded edits (blue) to a structured prompt (top), each traceable to examples it fixed or broke, whereas monolithic rewriters rewrite the whole prompt (blue), opaquely (bottom).

as one opaque string. The resulting trace is therefore a sequence of full-prompt diffs: it shows that the prompt changed, but not where the relevant change occurred, why it was made, or which examples it helped or harmed. This limitation persists whether the rewriter is driven by text-gradient feedback or by LLM-as-optimiser sampling: the unit of edit remains the entire prompt.

A handful of recent structured optimisers begin to challenge this single-string interface. Some expose local edit targets, such as factor-, section-, token-, or tree-level units (Schnabel and Neville, 2024; Liu et al., 2026c; Sharma and Henley, 2026; Jain and Chowdhary, 2025; Kumar et al., 2025); others attribute failures to semantic units or agent contributions (Chen et al., 2026; Xia et al., 2026; Zhang et al., 2025); and reflective or self-evolving optimisers improve search with archives, critique, and synthesis (Agrawal et al., 2026; Agarwal et al., 2025). Existing prompt optimisers typically update a prompt based on failures surfaced in the current round. However, rules added to address those failures can also change the worker’s behaviour on examples that it handled correctly under the parent, thereby introducing new regressions. Without this parent-to-child transition, later iterations may conflate persistent failures with regressions introduced by the preceding edit, leading to repeated rule accretion or another broad prompt rewrite. This can cause prompt bloat and make effective improvements harder to preserve across iterations.

In this paper, we propose SEPO, a multi-trajectory prompt optimiser that addresses this problem through edit-effect lineage feedback. Each edit targets a stable typed unit in a two-layer prompt schema; after the candidate is evaluated, SEPO links the target and realised operations of the edit to the examples it newly fixes or breaks and reuses this record in later architect calls on the same search branch. To preserve trajectory diversity, SEPO combines example-level admission with Lexicase-based parent selection (Spector, 2012), keeping specialists alive for rare training examples.

We evaluate SEPO on a 14-task held-out suite using Llama-3.1-8B-Instruct and Qwen3-8B as worker models. We cap optimisation at 2000 metric calls per task and seed—one metric call evaluates μ\mu on one training example, consuming one Worker LLM forward pass. Under this matched budget, SEPO reaches 61.9/73.3% macro accuracy on Llama/Qwen—+3.1/+2.2 pp over the best of six API-only baselines (GEPA)—while landing on both optimisation- and test-time Pareto frontiers.

References (3)

  • === TARGET PREFERENCE === Choose the smallest target that explains the dominant failure:
  • ADD step at <pos>
  • Refined sub-rule(s), New sub-rule(s), Merged-into sub-rule(s), and a tally line Dropped <K> sub-rule(s) (content removed)