TL;DR
When you change a prompt from "Are there people?" to "How many people?", how does an AI model internally reorganize its "thoughts" without changing a single weight? By mapping the geometry of hidden states across different instructions, the authors discover that prompting largely acts like a surprisingly simple mathematical operation: a shift (translation) does most of the heavy lifting, while linear feature-mixing (an affine shear) locks the representation into the exact shape needed to steer behavior. Nonlinear warping barely adds anything at all.
What Problem Does This Paper Address?
Asking a model to "describe the object" versus "describe the artistic style" completely changes what features of an image or text matter, steering its output at inference time.
Two parallel lines of research have circled this phenomenon:
- Representational analyses show that prompts warp internal activation spaces, usually summarizing these changes with single scalar numbers (like probing accuracy or manifold capacity).
- Activation steering shows that we can manually hack model behavior by adding simple "steering vectors" or applying linear maps to hidden layers.
What’s been missing is the bridge between them: what exact mathematical transformation does natural prompting actually perform? Nobody had systematically decomposed prompt-induced changes into distinct geometric operations—like shifting, rotating, or stretching—or tested whether those exact natural maps causally drive the model's downstream answers.
Methods
The authors treat a model's layer-$\ell$ hidden state (at the final input-prompt token) for a set of stimuli as a geometric point cloud, or manifold. Given two prompts $A$ and $B$ applied to the exact same stimuli, they search for a stimulus-invariant (global) map that aligns Prompt $A$'s cloud onto Prompt $B$'s cloud.
Instead of testing one transformation, they introduce a nested geometric decomposition—a Russian nesting doll of five increasingly expressive transformation tiers:
- Translation: A pure shift of the cloud's center (mean-shift).
- Rigid + uniform scaling: Rotation, reflection, and uniform zoom (solved via classical orthogonal Procrustes analysis).
- Rigid + axis-wise scaling: Stretching or squishing individual rotated axes independently.
- Affine: Full linear feature mixing/shearing (solved via ridge regression).
- Nonlinear: An affine map plus a one-hidden-layer MLP fitted on the leftover residuals.
To prove these maps aren't just statistical flukes, they run a causal intervention: they feed a held-out stimulus into the model under Prompt $A$, intercept a single layer, swap the hidden state with its mathematically transformed version $\hat{f}(h^A)$, and let the model finish generating text to see if it behaves as though it read Prompt $B$. They also evaluate structural alignment using Representational Similarity Analysis (RSA)—which checks if pairwise distances between stimuli match the target task's structure—and silhouette scores (measuring cluster separation).
Datasets
The authors evaluate three LLMs (OPT-2.7B, Llama-3-8B-Instruct, Qwen3-8B) and three Vision-Language Models (BLIP-2, LLaVA-OneVision-7B, Qwen3-VL-8B) across six datasets:
- Text datasets (for LLMs): EmotionalStory, WritingStyle, and Number.
- Image datasets (for VLMs): EmoSet, StyleTransfer, and COCO.
Each dataset is structured around two distinct attributes (e.g., story topic $\times$ emotion, or object detection $\times$ count). This factorial setup lets the authors systematically test six prompt-pair groups—comparing open-ended queries, specific yes/no questions, and task-irrelevant factual questions ("What is the capital of France?") both within and across attributes.
Key Insights and Ideas
- Prompts actively sculpt task geometry: Prompting doesn't just route readouts; as depth increases, it reorganizes the representation space so stimuli cluster neatly according to the asked-about attribute.
- Translation dominates variance, but shearing builds structure: Pure shifts (translation) explain the lion's share of raw activation change, explaining why simple "steering vectors" work so well in practice. However, translation and rigid rotations preserve pairwise shapes—meaning they cannot reorganize which stimuli are grouped together. Affine transformations (cross-dimensional linear mixing) are the critical missing piece that actually reshapes the cloud into Prompt $B$'s task geometry and unlocks big jumps in behavioral accuracy.
- Different models use different "routing strategies": Instruction-tuned models like Llama-3 and Qwen3 rely heavily on low-dimensional shifts ("instruction codes") early on. Meanwhile, OPT-2.7B (the only base model without post-training) leans much harder on distributed rotations and affine mixing in early-to-middle layers.
- Linear maps travel well; nonlinearities overfit: When transferring a fitted prompt map to a completely different dataset, the linear/affine core generalizes remarkably well (once you re-center the dataset means). The extra capacity of the nonlinear MLP, however, clings to corpus-specific quirks and transfers poorly.
Key Results
- Monotonic growth: Prompt-induced representational change starts tiny in early layers ($10^{-4}$ to $10^{-2}$ normalized squared Frobenius distance) and grows nearly monotonically to $10^{-1}$–$10^0$ in final layers across all models and modalities.
- Consistent tier hierarchy: Across prompt groups, incremental explained variance follows a clear order: $\text{Translation} > \text{Affine} > \text{Rigid (uniform)} > \text{Rigid (axis)} \approx \text{Nonlinear}$.
- Cross-dataset generalization: Within a dataset, cumulative held-out $R^2$ reaches 0.98 at the affine and nonlinear tiers (averaged across Llama-3-8B and LLaVA-OneVision). Raw transfer to a new dataset drops affine $R^2$ to 0.62 and nonlinear to 0.56, but simply re-centering on the target dataset's mean restores the affine fit to 0.83—outperforming the nonlinear tier.
- Input layout robustness: Moving the prompt instruction from a standard header into an interior sentence boundary lowers deep-layer LLM $R^2$ slightly (from 0.89–0.95 down to 0.78–0.88 across tiers) while preserving the exact geometric hierarchy, failing only when Prompts $A$ and $B$ put instructions at mismatched token boundaries.
Limitations and Future Work
- Zero-shot only: The study focuses strictly on short, zero-shot instruction prompts. Few-shot in-context learning, soft prompts, and long-context conditioning may use very different geometric mechanisms.
- Single-point interventions: Causal patching was restricted to a single layer and a single readout token (the final prompt token). Exploring multi-layer or multi-token interventions—and testing more extreme distribution shifts—remains open territory for turning this diagnostic framework into practical, lightweight steering tools.
Summary updated