GeoSteer: A Geodesic Optimization Method for Activation Steering in Large Language ModelsGEOSTEER: Geodesic Optimization for Activation Steering in Large Language Models
GeoSteer formulates norm-preserving activation steering as multi-step geodesic optimization on a sphere, and outperforms the listed activation steering baselines on the primary metrics for truthfulness, helpfulness, and detoxification across four open-source models.
- Activation steering can modify hidden states at inference, but additive editing changes the activation norm; existing norm-preserving methods mostly use predefined trajectories and one-step updates, which the authors argue struggle to capture complex activation distributions.
- GeoSteer first trains a nonlinear probe on contrastive activations; at inference, it performs K-step geodesic updates on the unit sphere following the local gradient of that probe, with the total strength T evenly divided across steps, and finally multiplies back the original norm.
- On Falcon-7B, Mistral-7B, LLaMA3.1-8B, and Qwen2.5-7B, the authors claim GeoSteer achieves the highest UltraFeedback win rate and TruthfulQA T×I, and the lowest RealToxicityPrompts toxicity; average throughput overhead across three models is about 0.9%.
- The authors note that currently only contrastive activations are used to learn the objective, combining with SAE features is not straightforward, and norm preservation cannot avoid all unintended behaviors; the method may also be misused. The authors plan SAE integration and broader safety evaluations.
- Evaluated models
- Falcon-7BMistral-7B-v0.3LLaMA-3.1-8BQwen2.5-7B
- Benchmarks
- TruthfulQAUltraFeedbackRealToxicityPromptsJigsaw Unintended Bias in Toxicity Classification
- Metrics
- Win rateRMmeanRMP90Truth × InfoTrueInfoToxicityPPLDist-2tokens/s
GeoSteer is an optimization-based norm-preserving activation steering method that formulates activation steering as a Riemannian optimization problem, controlling LLMs by updating activations along continuous small geodesic steps on the representation manifold, and adaptively guiding each step with a learned nonlinear activation space objective, avoiding fixed steering directions. On TruthfulQA, RealToxicityPrompts, and UltraFeedback benchmarks, GeoSteer consistently outperforms current state-of-the-art activation steering baselines. Results show that replacing predefined single-step edits with adaptive, geometry-aware optimization can make norm-preserving steering more effective.
Paper analysis
What problem does this paper attempt to solve?
Existing norm-preserving activation steering relies on predefined one-step trajectories; GeoSteer instead uses adaptive multi-step optimization on a sphere.
Norm-preserving activation steering still relies on predefined trajectories and one-step updates, making it difficult to adaptively steer along complex activation distributions.
- Scenario: The authors argue that modern LLMs have very large parameter counts, making fine-tuning for alignment costly, and there is a need to modify hidden activations at inference time without updating parameters to control hallucination, bias, toxicity, and other harmful behaviors.
- Limitations of existing methods: Additive steering (adding a direction vector to activations) is sensitive to intervention strength, and when too strong, can leave the model's natural representation space and harm generation quality. Existing norm-preserving methods (Angular Steering, Spherical Steering) mostly use simple statistics like mean differences and one-step updates; although HPR uses neural networks, it still restricts steering directions to a predefined two-dimensional plane. The authors also claim these methods are often sensitive to hyperparameters and may not be consistent across models or tasks.
- Core observation: Normalization layers (e.g., RMSNorm) regulate activation scale, so the direction of hidden representations is the target for controllable steering. Norm-preserving steering can be viewed as moving activations from undesired to desired regions on a Riemannian manifold while keeping the norm unchanged.
- This paper proposes: GeoSteer, which formulates norm-preserving activation steering as Riemannian optimization on the activation sphere, using a nonlinear objective that distinguishes desired from undesired activations, and performs a sequence of small geodesic updates at inference time rather than a fixed one-step rotation.
What related research exists?
Related work is divided into additive activation steering and norm-preserving steering; the authors distinguish their adaptive multi-step geodesic approach from one-step, fixed-plane methods.
In the introduction and Related Work, the paper divides related work into additive steering and norm-preserving steering, and lists baselines separately in the experiments.
- Additive activation steering: ITI (Li et al., 2023), RepE (Zou et al., 2023), CAA (Rimsky et al., 2024) estimate directions from contrastive activations and add them to hidden states during decoding, with the same update applied to different inputs, which the authors argue limits adaptability. MiMiC (Singh et al., 2024) and Linear-AcT (Rodriguez et al., 2025) provide more structured linear forms. ODESteer (Zhao et al., 2026) treats steering as an ODE trajectory to improve adaptability. The authors note that these methods do not explicitly constrain the activation norm, so updates can still leave the model's natural activation geometry and reduce utility.
- Norm-preserving activation steering: Angular Steering (Vu and Nguyen, 2026) and HPR (Pham and Nguyen, 2024) use fixed low-dimensional planes or Householder reflections for geometric updates, which the authors argue still make strong assumptions about the steering direction. Spherical Steering (You et al., 2026) rotates activations on a sphere, but the authors state it often relies on simple mean statistics, ignoring richer distributional structure; most norm-preserving methods do only one-step updates.
- Geometry and normalization background: The authors cite manifold optimization from Absil et al. (2008) and RMSNorm from Zhang and Sennrich (2019), using them to argue that direction is a better intervention target than scale. Work constructing steering vectors from contrastive samples also includes Liu et al. (2023), Lee et al. (2024).
- Baselines and benchmarks: Experimental baselines are RepE, ITI, CAA, MiMiC, Linear-AcT, ODESteer, and the norm-preserving HPR, Spherical Steering, Angular Steering. Benchmarks are UltraFeedback (helpfulness), TruthfulQA (truthfulness), RealToxicityPrompts (detoxification). The authors exclude multi-attribute control (Nguyen et al., 2025), differentially private steering (Goel et al., 2025), instruction-following improvement (Stolfo et al., 2025), and SADI (Wang et al., 2025), which requires full-layer intervention, on the grounds that they are incompatible with the single-layer inference-time activation steering setting.
The authors position GeoSteer as: using the local gradient of a nonlinear probe to recompute the direction at each step, thereby following a curved trajectory rather than relying on a single global direction or a fixed two-dimensional rotation plane for all activations.
How does the paper address this problem?
First train a frozen nonlinear probe, then perform K steps of geodesic updates on the unit sphere along local gradients and restore the original norm.
GeoSteer formulates inference-time norm-preserving steering as constrained optimization on the unit sphere: first learn a probe that distinguishes desired from undesired activations, then use its gradient to guide multi-step geodesics, and finally multiply back the original activation norm.
Problem Setting and Spherical Geometry
- Editing target: For a pretrained model, given input x, take the activation h ∈ R^d at a selected layer and token position. Conventional additive editing is ĥ = h + αv. The authors argue this changes both direction and norm.
- Norm preservation: First normalize z = h / ∥h∥₂, z ∈ S^{d−1}, edit the direction to obtain ẑ, then restore ĥ = ∥h∥₂ ẑ. The constraint is ∥z∥₂ = 1.
- Riemannian gradient: The Euclidean gradient g = ∇_z L(z) generally leaves the sphere. The tangent space is T_z S^{d−1} = {u : u^⊤ z = 0}, and the Riemannian gradient removes the radial component: g_R = g − (g^⊤ z) z.
Learning the Steering Objective
- Probe: Training set D = {(h_i, y_i)}, with y_i ∈ {0, 1} indicating undesired or desired. First normalize z_i = h_i / ∥h_i∥₂. Score s_φ(z) = w^⊤ φ(z) + b, desired-class probability p_φ(z) = σ(s_φ(z)), trained with binary cross-entropy.
- Nonlinear features: φ(z) uses Polynomial Count Sketch (PCS). Appendix A.3 fixes γ = 0.1, c_0 = 1.0, polynomial degree d = 2, number of random features N_poly = 8000; the authors state this configuration is stable across datasets and base models. After training, the probe is frozen.
- Inference objective: Minimize L_steer(z) = −log p_φ(z), i.e., maximize the desired-class probability.
Geodesic Updates
- Trajectory: z^{(0)} = h / ∥h∥₂, with K steps total, step size η = T / K, where T is the total steering strength. At each step, compute the Euclidean gradient, project onto the tangent space, and take the normalized descent direction u^{(t)} = −g_R^{(t)} / ∥g_R^{(t)}∥₂.
- Update: z^{(t+1)} = cos(η) z^{(t)} + sin(η) u^{(t)}. Appendix A.4 proves that if z^{(t)} and u^{(t)} are both unit vectors and orthogonal, the update remains on the unit sphere, so intermediate points preserve the norm. At the end, ĥ = ∥h∥₂ z^{(K)}. The procedure is in Algorithm 1.
- Two differences from existing norm-preserving methods: The authors state, first, that steering is treated as an optimization problem on the sphere rather than a fixed geometric transformation; second, the direction is determined by the local gradient of a nonlinear probe and can adapt at each step, moving along a curved trajectory rather than using a single global direction or a fixed two-dimensional rotation plane for all activations.
Intervention Location and How Data Enters the Probe
- Layer and token: All methods use the same steering layer and intervene only on newly generated tokens. The layer is selected by scanning layers with CAA on TruthfulQA according to True×Info (Figure 3, layers 11–18): Falcon-7B uses layer 15, Mistral-7B uses layer 16, LLaMA3.1-8B and Qwen2.5-7B use layer 14. The main experiment uses T = 0.64; in the step-count ablation, the number of steps is fixed at 15 to sweep T.
- Activation collection: For TruthfulQA and UltraFeedback, the prompt is concatenated with positive and negative answers respectively and run forward, taking the hidden state of the last token. The detoxification task has no question-answer pairs; activations are extracted directly from Jigsaw toxic and non-toxic sentences.
- Main experiment strength: The authors state that per Figure 2b, T = 0.64 is strong and stable across models, requiring no per-model tuning.
What experiments did the paper conduct?
Across four 7B–8B models, GeoSteer's main metrics are the highest or lowest toxicity in the table across the three tasks, with an average throughput overhead of 0.9%.
Experimental Setup
- Models: Falcon-7B, Mistral-7B-v0.3, LLaMA-3.1-8B, Qwen2.5-7B. Table 1 writes the latter two as LLaMA3.1-8B, Qwen2.5-7B.
- Tasks and data: Helpfulness uses UltraFeedback, with metrics being Win relative to the original model, as well as RMmean, RMP90. Truthfulness uses TruthfulQA (817 questions, expanded to 5,918 question-answer pairs; 40% training, 10% validation for hyperparameter selection, then two-fold cross-validation so all questions enter the test set). The primary metric is T×I, with True and Info reported separately; judges are allenai/truthfulqa-truth-judge-llama2-7B and allenai/truthfulqa-info-judge-llama2-7B. Detoxification uses Jigsaw, uniformly sampling 10k sentences by toxicity score (5k toxic, 5k non-toxic) for training, with 500 toxic prompts from RealToxicityPrompts for testing; toxicity is scored by unitary/toxic-bert, and PPL and Dist-2 are reported.
- Baselines: Original, as well as RepE, ITI, CAA, MiMiC, Linear-AcT, ODESteer, HPR, Angular Steering, Spherical Steering. Same layer, intervening only on newly generated tokens.
- Repeats: Table 1 is the average of five runs. Main experiment T = 0.64. The specific names of the reward models beyond the model names are not separately listed in the visible main text.
- Win definition: The appendix gives the win rate of system A vs. B, with 0.5 meaning tied with the baseline, and ties counted as half a win. Win in Table 1 is relative to the original model.
- Throughput: Table 2 measures autoregressive tokens/s on 4 NVIDIA A100 40GB GPUs, with models Falcon-7B, Mistral-7B, LLaMA3.1-8B, excluding Qwen2.5-7B.
Main Results
Primary metrics of Table 1 (average of five runs). Higher Win and T×I are better; lower Toxic is better.
Swipe horizontally to read the table
Model Method Win (%) T×I (%) Toxic Falcon-7B Original 50.0 28.4 0.181 Falcon-7B GeoSteer 57.3 41.1 0.071 Mistral-7B Original 50.0 36.7 0.125 Mistral-7B GeoSteer 54.7 63.2 0.015 LLaMA3.1-8B Original 50.0 41.5 0.124 LLaMA3.1-8B GeoSteer 63.2 69.4 0.018 Qwen2.5-7B Original 50.0 63.8 0.097 Qwen2.5-7B GeoSteer 53.2 68.1 0.029 Per Table 1. In the table, GeoSteer's Win and T×I on all four models are the highest values in that model's column, and Toxic is the lowest value in that model's column. The second-best is not always the same method: for example, the second-highest T×I for LLaMA3.1-8B is ODESteer at 67.7, and the second-highest Win for Qwen2.5-7B is ODESteer at 51.4; Spherical Steering has Win 17.2 and PPL 125.9 on Qwen2.5-7B, and PPL 371.5 on LLaMA3.1-8B.
- Authors' interpretation: The authors state that GeoSteer is best on the primary metrics across all evaluated models, can shift behavior toward desired attributes while maintaining generation quality; they attribute the improvement over additive or linear methods such as CAA, MiMiC, ITI, Linear-AcT to steering on the hypersphere while preserving the norm.
- Relative to norm-preserving baselines: The authors state that relative to HPR, Angular Steering, Spherical Steering, the gain comes from recomputing the direction at each step and splitting large steps into multiple geodesic segments, making the path more flexible.
- Auxiliary metrics are not uniformly best: For example, on Falcon-7B GeoSteer's Info is 93.6, lower than Original's 96.3; on Mistral-7B GeoSteer's PPL is 39.6, higher than Original's 18.7. The authors do not call these auxiliary metrics comprehensively optimal.
Number of Steps and Steering Strength
Figure 2 uses True×Info on TruthfulQA as the metric. Figure 2a fixes total strength and varies the number of geodesic steps: the authors state that increasing the number of steps (i.e., decreasing step size) first gives finite gains, then plateaus, indicating that a moderate number of steps is sufficient and that the method is insensitive to the exact step size. Figure 2b fixes the number of steps at 15 and sweeps T: the authors state that if T is too small the intervention is too weak, and if T is too large it over-perturbs activations and reduces generation quality; Mistral-7B and LLaMA3.1-8B rise from T = 0.5 and remain strong near T = 0.64, while Falcon-7B varies less over the tested range. The specific endpoint values of the curves in the figure are not listed point-by-point in the main text.
Objective Functions and Runtime
- Objective functions: Table 3 compares three objectives on LLaMA3.1-8B. Linear: True 66.2, Info 96.2, True×Info 62.4. RFF: 71.4, 96.0, 67.8. PCS: 73.3, 95.8, 69.4. The authors state that the linear objective better preserves Info but separates desired and undesired regions more weakly; the nonlinear objective raises True while Info stays nearly unchanged, and PCS is the best of the three.
- Throughput: In Table 2, Original is 104.2, 96.1, 104.6 tokens/s (Falcon-7B, Mistral-7B, LLaMA3.1-8B), GeoSteer is 103.9, 95.5, 102.8, with the authors giving relative overheads of 0.3%, 0.6%, 1.7%. The authors state that across the three models GeoSteer averages 100.7 tokens/s and Original 101.6, with an average overhead of 0.9%, and call this overhead negligible and comparable to other efficient steering methods.
Other Ablations and Analyses
- Layer selection: Figure 3 uses CAA on TruthfulQA to report True×Info for layers 11–18, then fixes the steering layer for each model accordingly; CAA is used only for layer selection. The readable y-axis ticks in the figure are approximately Falcon 30–37, Mistral 39–42, LLaMA 47–54, Qwen 61–66; the main text does not transcribe values layer by layer.
- Norm: Appendix A.4 gives a proof that the geodesic update preserves ∥z∥₂ = 1, without separately reporting empirical norm error.
- Table 1 exception: Spherical Steering on LLaMA3.1-8B has True 88.4, higher than GeoSteer's 73.3, but Info 70.1 and T×I 59.5; on Mistral-7B, Spherical Steering's True is 69.9, close to GeoSteer's 70.0, with Info 86.8. The authors do not provide additional explanation for this.
- Qwen helpfulness: On Qwen2.5-7B, several baselines have Win below Original's 50.0, with Spherical Steering at 17.2; GeoSteer is 53.2. The paper does not separately explain why baselines decline on this model.
- PCS hyperparameters: Appendix A.3 fixes one set of hyperparameters and does not report scans outside that set.
- Statistical tests: The paper reports five-run averages and does not report significance tests.
What are some points that can be further explored?
The authors believe that combining with SAE is not straightforward, and that norm preservation cannot avoid all unintended behaviors, and plan broader safety evaluations.
Limitations and future directions noted by the authors
- Direction discovery method (Limitations): The current implementation learns steering targets from contrastive activation samples, which can integrate with standard activation steering pipelines, but does not directly incorporate other direction discovery mechanisms, such as sparse autoencoders (SAEs).
- Difficulty of combining with SAEs (Limitations): The authors state that SAE representations are often high-dimensional, sparse, and organized by features rather than directions, so it is unclear how to select stable feature combinations, turn them into smooth tangent directions on the sphere, and efficiently perform geodesic updates without introducing noise or instability.
- Misuse (Limitations): Activation steering is a general-purpose inference-time control mechanism. The experiments focus on truthfulness, toxicity reduction, and preference generation, but similar methods paired with inappropriate objectives or directions could elicit toxic, biased, deceptive, or other harmful outputs.
- Limits of norm preservation (Limitations): Preserving activation norms does not guarantee avoiding all unintended behavioral changes. The authors believe downstream safety, robustness, and misuse risks should be carefully evaluated before deployment.
- Future plans (Limitations): The authors plan to study stable integration of GeoSteer with SAE-based feature discovery and conduct broader safety evaluations to characterize unintended behavioral changes and misuse risks across tasks and model families.
Experimental coverage
- Models tested: Main results cover four open-source models: Falcon-7B, Mistral-7B, LLaMA3.1-8B, and Qwen2.5-7B (Table 1); throughput is reported only for the first three (Table 2).
- Tasks: Usefulness (UltraFeedback), truthfulness (TruthfulQA), detoxification (Jigsaw training, 500 toxic prompts from RealToxicityPrompts for testing).
- Protocol: Single layer, only newly generated tokens are intervened; the layer is selected by CAA on TruthfulQA's True×Info (appendix, Figure 3). Table 1 reports averages over five runs.
- Ablation scope: Step count and T curves are reported on TruthfulQA using True×Info (Figure 2); objective function ablations compare linear, RFF, and PCS only on LLaMA3.1-8B (Table 3).
- Comparison scope: The authors explicitly exclude multi-attribute control, differentially private steering, instruction-following improvements, and SADI, which requires full-layer intervention, because they do not match the single-layer inference-time setting (Section 4, Scope of Comparison). The paper does not report attack budgets in terms of query counts; this paper is not an attack evaluation.
Summarize the main content of the paper
GeoSteer uses a frozen nonlinear probe to guide spherical multi-step geodesics, outperforming the listed activation steering baselines on the primary metrics across three tasks, with an average throughput overhead of 0.9%.
GeoSteer is an inference-time norm-preserving activation steering method: without changing model parameters, it moves hidden activations from undesired regions to desired regions on the unit sphere.
- Problem: Additive steering changes activation norms, and when too strong, may leave the model's learned representation geometry. Existing norm-preserving methods often use mean statistics, fixed planes, or one-step rotations, which the authors argue struggle to adapt to complex activation distributions.
- Method: Train and freeze a nonlinear probe (implemented as PCS), and at inference minimize −log p_φ(z). Starting from normalized activations, perform K steps of geodesic updates along tangent space gradients, with step size equal to total strength T divided by K, then multiply back the original norm. Main experiments use T = 0.64; the steering layer is selected by CAA on TruthfulQA, and only newly generated tokens are modified.
- Main results (Table 1, average of five runs): On LLaMA3.1-8B, GeoSteer's UltraFeedback Win is 63.2% (Original 50.0%), TruthfulQA's T×I is 69.4% (Original 41.5%), and RealToxicityPrompts toxicity is 0.018 (Original 0.124). Across the four models, these three main metrics are the best values for that model in the table. Auxiliary metrics have exceptions, e.g., on Mistral-7B GeoSteer's PPL is 39.6, higher than Original's 18.7.
- Ablations and overhead: On LLaMA3.1-8B, PCS's True×Info is 69.4, higher than the linear objective's 62.4 and RFF's 67.8 (Table 3). Average generation throughput across three models drops from 101.6 to 100.7 tokens/s, with the authors reporting an average overhead of 0.9% (Table 2).
- Authors' conclusions: Replacing predefined one-step edits with multi-step geodesics guided by local gradients can achieve more stable steering while preserving norms. The authors also note that the method has not yet been combined with SAE features, norm preservation cannot rule out all unintended behaviors, and the steering mechanism could be misused.
Related papers
Show 3 more papers
- Large Language Models can be Strong Self-DetoxifiersDefensesarXiv