arXiv:2611.04757cs.AINov 2026

Manuscript Offprint

arXiv:2611.04757

When Should an LLM Steering Edit Depend on the Input?

Rachael Harkness, Konrad Rawlik

ABSTRACT

An activation steering edit should depend on the input exactly when the destination varies inside the class a query requests, and that is measurable before any rule is fitted or applied. Contrastive Activation Addition (CAA) adds one fixed direction to every input, the difference of the class means. Conditioning it on the requested class accounts for the between-class variation in the required displacement and leaves the within-class variation untouched, which no rule that reads only the source state can express. We study the impact of increasing input-dependence in the steering edit, moving from a difference of means to a destination retrieved per query — the mean of the kk stored states nearest the query, inside the requested class — in which the two baselines are endpoints: at kk equal to the class size the retrieved rule is the class-conditional difference of means. We measure input-dependent steering on six substitution corpora that vary in whether the edit changes a word or a clause, and on an external benchmark, and find that input-dependent steering outperforms fixed-direction steering when the destination varies within the class. Retrieval wins at every layer of every substitution corpus in two models, and the level of input-dependence needed governs how to apply it: word-level edits are best made in the first tenth of the network from a few neighbours, clause-level edits at any depth from the class mean. Where the class already determines the answer the class mean suffices and retrieval only matches it, though a fixed direction still fails there. Four quantities computed from the states alone identify the regime in which the edit should be applied.

INTRODUCTION

Activation steering perturbs hidden states with a vector chosen to induce a behaviour. CAA collects states from prompts exhibiting the behaviour and from prompts that do not, and adds the difference of their means to every input. This assumes one displacement describes the edit for every input, and the assumption fails whenever the required edit depends on what the input says: steering a sentence toward the next weekday asks something different of Monday and Thursday, where steering a concept from male to female (king to queen) does not.

Two repairs are available, and they are the same rule at different settings. Conditioning the difference of means on the class a query is steered toward gives one vector per class rather than one per corpus. Retrieving instead gives a destination per query: search a bank of states that already exhibit the target behaviour and steer toward the mean of the k nearest. §3.1.1 shows these are endpoints of one family — at k equal to the class size the retrieved rule is the class-conditional difference of means — so k controls the locality of the edit and therefore how closely the retrieved destination matches the ideal per-query direction; this characterises the trade-off between global and local edits and defines the difference between class-conditional and per-query retrieval. Figure 1 displays the effects of per-query retrieval.

Figure

Figure 1: A fixed direction fails where the required displacements disagree, and a per query destination recovers the task. Three rules on two generated constructions in two dimensions; E is reference error, 1 being the score for leaving the input alone. THREE-MODE (a–c) rotates the offsets between classes, so CAA's vector is zero by construction while the same difference of means taken inside a class is exact (class-conditional CAA); CONCENTRIC (d–f) sends each query outward at its own angle, so the displacements cancel within a class too and neither fixed rule has anything to estimate. Only a RGS destination survives both (§F gives more detail).

This trade-off is task-dependent, and can be characterised quantitatively before any rule is fitted. Each rule has the same form, one direction per query times a scalar chosen on held-out data, so each can be scored in advance by how well its directions agree with the edits the task requires. We compute four such quantities and measure them against what the rules go on to score.

We evaluate on five families: synthetic constructions whose correct answers are set rather than measured, two token corpora, six substitution corpora built to vary the level of the concept an edit changes (word to clause), two A/B behavioural benchmarks, and two external benchmarks run under their own protocols. Throughout we compare RGS against CAA, class-conditional CAA and an affine map fitted on the query-to-target correspondence none of the unpaired rules receive, and we ask what governs the choice between them: the level of the concept, the coverage of the bank, the depth at which the edit is made, and whether the destination varies inside the class a query requests.

2 RELATED WORK

Steering by a fixed direction. Most activation steering adds one vector to every input: activation addition (Turner et al., 2023) and Contrastive Activation Addition (Rimsky et al., 2023) estimate it from contrastive prompt pairs, inference-time intervention (Li et al., 2023) fits per-head directions to a probe, representation engineering (Zou et al., 2023) builds reading and control vectors from the same contrast, and task arithmetic (Ilharco et al., 2023) composes fixed directions in weight space. All share the assumption examined here — that one displacement describes the edit for every input — and all are evaluated by class-level outcomes, which a rule collapsing every query onto the class centroid satisfies exactly. Evidence that some model features are not linearly organised (Engels et al., 2024) suggests the assumption is not universal, without saying which tasks violate it.

Conditioning the intervention on the input. Function vectors (Todd et al., 2024) condition on the task, applying one vector per task rather than per query. Retrieval over a datastore of hidden states is established as a way of conditioning a model's output on nearest neighbours (Khandelwal et al., 2020; 2021; Shi et al., 2022; Huang et al., 2023), which interpolate the output distribution with a neighbour-weighted one. We use the same machinery for a different purpose: the neighbourhood supplies a steering destination in state space, so the intervention remains a single additive edit at one layer and composes with the fixed-direction methods above.

Our contributions.

(i) We introduce RGS, a rule for input-dependent steering of which class-conditional CAA is the k=∣Dc∣k = |\mathcal{D}_c| endpoint (§3.1.1).

(ii) We evaluate RGS against alternative steering methods on a variety of corpora to identify the successes and failures relative to fixed steering rules.

(iii) We identify that concept level (words vs. phrases) organises where in the model the edit is best made, and how local the rule should be (§4).

(iv) We define four diagnostic quantities computed from the task alone which predict the success of each rule and propose their use as a screening tool for input-dependent steering (§4.8).