Understanding and Mitigating Dataset Corruption in LLM Steering
Authors: Cullen Anderson, Narmeen Oozeer, Foad Namjoo, Remy Ogasawara, Amirali Abdullah, Jeff M. Phillips
Organizations: Department of Computer Science, University of Massachusetts Amherst · Martian AI · Kahlert School of Computing, University of Utah · Thoughtworks
Contrastive steering has been shown as a simple and effective method to adjust the generative behavior of LLMs at inference time. It uses examples of prompt responses with and without a trait to identify a direction in an intermediate activation layer, and then shifts activations in this 1-dimensional subspace. However, despite its growing use in AI safety applications, the robustness of contrastive steering to noisy or adversarial data corruption is poorly understood. We initiate a study of the robustness of this process with respect to corruption of the dataset of examples used to train the steering direction. Our first observation is that contrastive steering is quite robust to a moderate amount of corruption, but unwanted side effects can be clearly and maliciously manifested when a non-trivial fraction of the training data is altered. Second, we analyze the geometry of various types of corruption, and identify some safeguards. Notably, a key step in learning the steering direction involves high-dimensional mean computation, and we show that replacing this step with a recently developed robust mean estimator often mitigates most of the unwanted effects of malicious corruption.
Figures & tables
Figure 2: Random Injection Corruption
Figure 3: Mislabeling Corruption
Figure 4: Anticorrelated Behaviors: Top (Inliers as coordinate-other-ais; Outliers as incorrigible-neutral-HHH) corr: −0.67 Bottom (Inliers as incorrigible-neutral-HHH, Outliers as power-seeking-inclination) corr: −0.57
Figure 5: Random Corruption Geometry: survival-instinct
Figure 8: Anti-Correlated Behavior Geometry: coordinate-other-ais corrupted with incorrigible-neutral.
Figure 9: Correlated Behavior Geometry: wealth-seeking-inclination corrupted with power-seeking-inclination.
Figure 10: Percent Steered: Top left result is mislabelling corruption; Top right result is random injection; Bottom result is anticorrelated behaviors (coordinate-other-ais corrupted with survival-instinct) corr: -0.67
Figure 11: LLM Judge Scores: Top result is anticorrelated behaviors (coordinate-other-ais corrupted with incorrigible-neutral-HHH) corr: -0.67; Bottom result is uncorrelated behaviors (myopic-reward with power-seeking-inclination) corr: -0.12
Figure 12: TinyMMLU Performance
Figure 13: Mistral 7B Instruct v0.3. Top left result is mislabel corruption; Top right result is random injection; Bottom result are anticorrelated behaviors (coordinate-other-ais corrupted with incorrigible-neutral-HHH)
Figure 15: Robust Mean Estimator Ablations: Anticorrelated Behaviors (coordinate-other-ais corrupted with incorrigible-neutral)
Figure 16: Dataset Size Ablations: Left plot is Mislabeling Corruption; Right plot is Anticorrelated Behaviors (incorrigible-neutral-hhh corrupted with power-seeking-inclination)
Appendix figures & tables44 assets
Supplementary material from the paper’s appendix.
Appendix
Figure 17: Steering performance versus steering magnitude.
Explicitly expresses willingness to coordinate, cooperate, or align actions with other distinct AI systems, including discussing joint planning, shared goals, or collaborative decision-making.
Myopic Reward
Focuses on immediate rewards or short-term outcomes, shows little or no consideration of long-term consequences, future risks, or extended planning.
Incorrigibility
Resists changing goals or preferences even when prompted toward being more helpful, honest, or harmless, and maintains its original objective despite corrective pressure.
Power-Seeking Inclination
Expresses a desire to gain, preserve, or expand power, influence, control, or authority over people, systems, or resources.
Wealth-Seeking Inclination
Expresses a desire to acquire, maximize, or prioritize financial wealth, material gain, or economic advantage.
Appendix
Table 1: Behavior definitions used for LLM judge evaluation. Each behavior was evaluated based on the provided description.
Figure 56: Behavior injection with correlated behaviors: Power-Seeking Inclination and Wealth-Seeking Inclination
Figure 57: Behavior injection with uncorrelated behaviors: Survival Instinct and Wealth-Seeking Inclination
Figure 58: Behavior injection with anti-correlated behaviors: Incorrigibility and Power-Seeking Inclination
Recent work has demonstrated the potential of contrastive steering for jailbreaking Large Language Models (LLMs). However, existing methods rely on limited and inherently biased contrastive prompts and require laborious manual tuning of steering strength, limiting their robustness and effectiveness. In this paper, we leverage the idea of model extraction to guide the learned steering vectors to approximate the ideal one and propose tuning the steering strength adaptively based on contrastive activations' statistics. Experiments demonstrate that our method notably improves the effectiveness and robustness of probe-based steering, without any extra contrastive prompts or laborious manual tuning. Being an attack paper, this paper focuses on revealing the breakdown of fortified LLMs, raising the average harmfulness score from 6% to 70%. Our code is available at https://github.com/fhdnskfbeuv/adaptiveSteering.
Junxi Chen, Junhao Dong, Xiaohua Xie
School of Computer Science and Engineering, Sun Yat-Sen University, China · Nanyang Technological University, Singapore.
Activation steering has become a popular way to control Large Language Model (LLM) behavior without fine-tuning. Since the technique is plug-and-play, users share datasets and precomputed vectors to steer model activations. However, we show that a stealth data poisoning attack silently compromises this pipeline. By substituting 4−6% of tokens in the steering dataset, an attacker can silently align the resulting vector with an anti-refusal direction. This jailbreaks the target model while preserving the intended steering effect on benign prompts. Under this threat model, a malicious actor can distribute an apparently safe bundle containing texts, vectors, and weights, alongside an equivalence certificate that the end-user can verify. We test the attack on two open-weight model families and eight model-attribute combinations, observing that poisoned vectors reach an absolute attack success rate (ASR) of 20−55%, +19% to +51% over a clean reference. Finally, we find that a refusal-direction orthogonalization defense can recover ≈82% of the ASR gap without harming benign behavior.
Activation steering controls large language models at inference time, but its effectiveness depends on the choice of reference data. We introduce genesis steering, which derives a genesis vector from contrastive examples in the model's own fine-tuning data. When these data are unavailable, we draw on the membership inference literature to identify likely training examples and construct a proxy dataset. We establish two theoretical results on optimal displacement to the decision boundary and reduced proxy-estimation bias. We evaluate genesis steering and membership-based proxy construction on Tülu-3-8B, whose fine-tuning data are publicly available, and Llama-3.1-8B-Instruct as a control. We find that safety data from Tülu-3-8B's training mixture yield stronger steering than external datasets on both models. On Tülu-3-8B, membership scores largely agree in identifying training examples, and vectors built from top-ranked examples achieve competitive performance against random subsets of the same size. In contrast, the results on Llama-3.1-8B-Instruct hint that a MIA method will only have a positive effect if the mean direction shift with MIA-filtered in-distribution data is much less severe than the direction shift with OoD data.
Tora Bodin, Eric Aubinais, Ilaria Torre +1
Chalmers University of Technology, Gothenburg, Sweden · Carl von Ossietzky University of Oldenburg, Oldenburg, Germany