AttentionViz: A Global View of Transformer Attention
Transformer models are revolutionizing machine learning, but their inner
workings remain mysterious. In this work, we present a new visualization
technique designed to help researchers understand the self-attention mechanism
in transformers that allows these models to learn rich, contextual
relationships between elements of a sequence. The main idea behind our method
is to visualize a joint embedding of the query and key vectors used by
transformer models to compute attention. Unlike previous attention
visualization techniques, our approach enables the analysis of global patterns
across multiple input sequences. We create an interactive visualization tool,
AttentionViz, based on these joint query-key embeddings, and use it to study
attention mechanisms in both language and vision transformers. We demonstrate
the utility of our approach in improving model understanding and offering new
insights about query-key interactions through several application scenarios and
expert feedback.
64584c5f32ac1687a28c792d
Catherine Yeh
claimed_verified
2023-05-09T08:52:16.921Z
6312606695407887cb78af89
/avatars/55d2ec0736ae91dc0c07c99bc418528f.svg
Catherine Yeh
user
catherinesyeh
64584c5f32ac1687a28c792e
Yida Chen
claimed_verified
2023-05-08T09:28:58.957Z
6312618c5e2531edb9ee9fb0
https://cdn-avatars.huggingface.co/v1/production/uploads/6312618c5e2531edb9ee9fb0/CxFdN-z8pTn8qCLcJ16bT.png
Yida Chen
user
YidaChen
64584c5f32ac1687a28c792f
Aoyu Wu
64584c5f32ac1687a28c7930
Cynthia Chen
64584c5f32ac1687a28c7931
Fernanda Viégas
64584c5f32ac1687a28c7932
Martin Wattenberg
AttentionViz: A Global View of Transformer Attention
Transformer models are revolutionizing machine learning, but their inner
workings remain mysterious. In this work, we present a new visualization
technique designed to help researchers understand the self-attention mechanism
in transformers that allows these models to learn rich, contextual
relationships between elements of a sequence. The main idea behind our method
is to visualize a joint embedding of the query and key vectors used by
transformer models to compute attention. Unlike previous attention
visualization techniques, our approach enables the analysis of global patterns
across multiple input sequences. We create an interactive visualization tool,
AttentionViz, based on these joint query-key embeddings, and use it to study
attention mechanisms in both language and vision transformers. We demonstrate
the utility of our approach in improving model understanding and offering new
insights about query-key interactions through several application scenarios and
expert feedback.
AttentionViz provides an interactive visualization technique for analyzing global attention patterns in transformer models, enhancing model understanding and providing insights into query-key interactions.
transformer models self-attention mechanism joint embedding query vectors key vectors interactive visualization tool AttentionViz