Activation Steering
General Definition
Activation Steering is a technique where vectors derived from analyzing activations on controlled examples are added to or subtracted from the hidden states (hidden states) of the model at specific layers. This allows guiding generation in a desired direction — for example, increasing usefulness, reducing toxicity, or changing the style of responses.
Unlike fine-tuning, this method does not alter the model's weights and does not require a gradient pass. Steering vectors are calculated in advance and applied during inference.
Mechanics
- Activations are collected on a set of paired examples (e.g., 'honest' and 'dishonest' responses) on a selected layer.
- The difference in mean activations is calculated — this is the steering vector.
- During generation, the vector is added to the activations with a specified scaling coefficient.
| Parameter | Description |
|---|---|
| Layer | The layer on which the vector is applied |
| Coefficient | Multiplier of the strength of influence |
| Direction | Sign of the vector (enhancement or weakening of the property) |
Applications
- Reducing hallucinations and bias.
- Controlling the tone and style of responses.
- Investigating internal mechanisms of the model.
- Quick adaptation of behavior without retraining.