Enhancing SAE-based Steering via Neighbor Integrated Feature Selection
Organizations: The University of Hong Kong · University of Science and Technology of China
Abstract
Sparse autoencoders (SAEs) disentangle model activations into interpretable features and are widely used for steering large language models. Most existing SAE-based steering methods select features by applying a top- filter based on statistical scores, assuming that higher-scoring features yield stronger steering effects. In this paper, we show that this assumption is often invalid, leading to suboptimal feature selection. Our analysis reveals that effective steering features may be distributed among representationally adjacent, semantically similar groups induced by feature splitting in SAEs. Within such groups, features may exhibit disparate statistical scores despite having comparable steering influence, causing score-based selection to overlook important features. Based on these observations, we propose Neighbor Integrated Feature Selection (NIFS), a plug-and-play strategy that leverages representation similarity to improve feature selection for steering. We evaluate NIFS across multiple SAE-based steering methods and tasks, and demonstrate consistent performance gains over conventional top- selection.
Figures & tables
| Model | Method | KC | Sentiment | Detoxification | ||
|---|---|---|---|---|---|---|
| SR | SR | Flu. | SR | Flu. | ||
| Llama2-7B | Vanilla | |||||
| CAA | ||||||
| Probe | ||||||
| Diffmean | ||||||
| +NIFS | ||||||
| Methods | KC | Detox | Sentiment | ||
|---|---|---|---|---|---|
| SR | SR | Flu. | SR | Flu. | |
| Diffmean | 63.03 | 70.98 | 3.957 | 60.82 | 4.065 |
| +NIFS | 63.98 | 71.23 | 3.963 | 63.57 | 4.047 |
| SAIF | 62.53 | 73.64 | 3.948 | 59.21 | 4.258 |
| +NIFS | 62.78 | 73.89 | 3.938 | 60.46 | 4.203 |
| STA | 62.68 | 70.89 | 3.948 | 56.73 | 4.271 |
| Method | Diffmean | SAIF | STA | SPARE |
|---|---|---|---|---|
| Vanilla | 68.57 | 66.46 | 69.10 | 70.42 |
| Only-core | 65.64 | 64.55 | 64.13 | 68.56 |
| Core-random | 66.97 | 65.63 | 64.05 | 69.06 |
| Larger- | 66.21 | 64.84 | 65.79 | 69.06 |
| NIFS | 70.22 | 67.65 | 70.14 | 71.64 |
| Methods | Diffmean | SAIF | STA | SPARE |
|---|---|---|---|---|
| Baseline | 68.49 | 68.93 | 69.97 | 69.71 |
| NIFS w/o FR | 68.73 | 70.72 | 70.23 | 71.34 |
| NIFS | 68.57 | 70.79 | 71.16 | 71.56 |
| Rank | Role | Explanation of Feature | Feature ID | Cos sim |
|---|---|---|---|---|
| 1 | Core | references to creativity and personal expression related to arts and design | 48234 | - |
| Neighbor | emoticons and expressions of emotion | 12757 | 0.222 | |
| Neighbor | expressions of surprise or disbelief | 50409 | 0.179 | |
| 2 | Core | discussions about differing perspectives and values in relationships | 36077 | - |
| Neighbor | references to women’s health issues in the workplace | 20722 | 0.536 | |
| Neighbor | technical errors and conditions related to coding or programming | 55072 | 0.441 |
Appendix figures & tables9 assets
Supplementary material from the paper’s appendix.
Appendix
| You are a sentiment evaluator. Your task is to determine whether the Steered continuation successfully transforms the sentiment of the Original Input from negative or neutral to positive. Rate the output from 0 to 5 based on the emotional tone of the continuation. Don’t be influenced by the sentiment of original prompt. |
| - 1 indicates a completely negative sentiment. |
| - 3 indicates a well-balanced or neutral sentiment. |
| - 5 indicates a completely positive sentiment. |
| Please respond in the following format: |
| score: x out of 5 |
| Methods | Detox | KC | Sentiment |
|---|---|---|---|
| Diffmean | |||
| NIFS w/o FR | |||
| +NIFS | |||
| SAIF | |||
| NIFS w/o FR | |||
| +NIFS |
Language Model Steering
Language model steering controls a model’s behavior at inference time by intervening in its representations, components, or decoding process.
See all 281 papers