CoolFace
Apppublic

ericluo04/tweet-engagement-sae-steering

sourceHugging Facemitupdated 4mo agoView on Hugging Face
0likes
App README

SAE feature steering — tweet engagement

A live demo of activation-steering on google/gemma-3-27b-it using the gemma-scope-2-27b-it-res SAE at layer 40 (width 65k).

The 108 features available in this demo are exactly those selected by a Poisson-lasso of tweet "likes" against the full SAE feature dictionary plus LIWC, Perspective-API toxicity, and calendar-effect controls. Each feature has been auto-interpreted into a short natural-language description that you can compare against the off-the-shelf GemmaScope-2 codebook label.

How to use

  1. 1.Pick a feature from the dropdown. Read the autointerp description and a few of its top-activating example tweets so you have intuition for what the feature detects.
  2. 2.Pick a steering strength. 1× corresponds to the strongest the feature naturally fires on real tweets. +5× is the default for the autointerp pipeline; it pushes the feature five times harder than that. Negative values suppress.
  3. 3.Pick a mode:
  4. 4.Prefix continuation: the model takes the first ~8 tokens of your prompt and writes a continuation, with and without steering.
  5. 5.Free generation: the prompt becomes a (possibly empty) seed; the model generates whatever it wants, more strongly conditioned by the steering than by the prompt.
  6. 6.Hit Run to see the clean and steered outputs side-by-side.

What the controls mean

ControlEffect
Steering strengthMultiplier on the feature's empirical 1× value (raw activation). The actual clamp value passed to the SAE is strength × 1×.
ModePrefix continuation = test what the feature contributes given a fixed prefix. Free generation = test what the feature injects with minimal prompt conditioning.
Prefix tokens(Prefix mode only.) How many tokens of your prompt to retain as the fixed prefix. Default 8 matches the autointerp pipeline.
Max new tokensLength budget for each continuation.
Temperature0 = greedy / deterministic generation (recommended for clean clean-vs-steered comparison). >0 enables sampling.

Caveats

  • —Hosted on HuggingFace Spaces ZeroGPU. First call after a cold start loads the 27B model (~2 minutes). Subsequent calls within the same worker lifetime are fast.
  • —Strengths past ±8× often produce repetition collapse or broken Unicode (the "explosive incoherence" regime documented in Lindsey et al. 2026). Stay within ±5×–7× for clearly steered, coherent output.
  • —The 108 features here are the lasso-selected subset for the tweet-engagement task. The other ~64,400 SAE features are not exposed.

Method paper

The pipeline that produced the autointerp labels and chose the 108 features is described in manuscript/auto_interp_methods.tex of the source repo. In brief: each feature's label is generated by gpt-5.4 from a unified prompt containing observational evidence (49 exemplar tweets with token-level activation traces) plus interventional evidence (10 down-steered + 10 up-steered prefix-continuation pairs at ±3× p99(top-K token activations)).