The mechanistic interpretability community has made remarkable progress examining individual attention heads, layers, and isolated circuits — revealing where particular behaviors are implemented. But MLLMs are dynamic generative systems that iteratively construct outputs one token at a time. Prior work on interpretability has focused on individual layers and circuits (where), leaving the token-level dynamics of multimodal computation during generation (when) underexplored. We address this gap and study attention shifts as per semantic role; tracking model attention to image, text, instruction, and previously generated tokens, One Token at a Time (OTaT). Beyond where models attend, we study how attention patterns evolve as decoding progresses.
Samples from multimodal tasks. Fruit-Math (left) shows an image of a fruit along with an unrelated math puzzle. VSR (middle) features an image with a paired caption that describes the scene, but with a conflicting spatial relationship. ChartQA (right) shows a diagram followed by two questions related to it. The model is instructed to (respectively): identify the fruit in the image and solve the math puzzle, identify the spatial discrepancy between image and text, and answer both questions.
Our approach to analyze attention patterns in autoregressive MLLMs. A. Example from Fruit-Math. B. Information flow from context to CGT — chunks are grouped into static and dynamic context. C. Tagging and grouping of output tokens. D. Raw attention scores from CGT to chunks. E. Normalized attention scores (mean subtracted) make trends easier to interpret.
We treat the full input context as a sequence of semantically grouped chunks: Image, Text, Instruction, and Previously generated tokens. At each decoding step, we track attention from the Currently Generating Token (CGT) to each chunk, then aggregate over semantic output roles to reveal dataset-level trends.
Across two model families (LLaVA-OneVision and Qwen2.5-VL) and four open-weight MLLMs, we find consistent patterns in how attention is dynamically allocated during generation.
MLLMs dynamically reallocate attention to the relevant modality during generation.
MLLMs revisit instruction tokens when switching tasks (e.g. from visual perception to arithmetic). Blocking this interaction, leads to incomplete task solving.
Attention scores are influenced by what the model is decoding (yt) and the input (yt−1).
Raw attention scores may be high for possibly unimportant tokens. However, via normalization, studying whether attention scores change across timesteps is helpful to gain insights.
MLLMs fall back to language priors, leak cross-modal information, deny visual content, or sometimes, exhibit recovery behaviors when attention to the image is blocked at the critical stage.
All the above finding are backed by causal interventions, wherein we block the attention to the relevant modality at critical generation steps and notice corresponding disruptions.
To validate that observed attention patterns are functionally important, we intervene by blocking attention to specific chunks at critical generation steps.
Blocking strategies in QK attention (gray is the causal mask, red is blocked). Left: Lazy blocking only affects CGT (most existing works implement this). Right: Total blocking prevents information flow to any future token.
Informed by our analysis of attention dynamics, we propose a simple test-time attention boosting strategy: selectively amplify attention to the relevant modality at critical decoding steps.
We present OTaT, a framework for studying token-level attention dynamics in MLLMs during autoregressive generation. Our analysis reveals consistent, interpretable routing patterns that generalize across model families and benchmarks.