BertViz
An interactive tool that shows which words an AI language model pays attention to.
- Your data
- Stays on your device
- Coding needed
- Developers only
- Cost
- Free
- Runs on
- Web browser
- Computer
- An ordinary computer is fine
An interactive tool that shows which words an AI language model pays attention to.
Language models use a mechanism called attention to decide which words matter to each other. BertViz draws this as interactive pictures so you can see what is happening inside the model.
It offers several views: one layer at a time, a bird's-eye view of the whole model, and a close look at individual parts of the calculation. It works with most models from the Hugging Face library.
It runs inside Jupyter or Google Colab notebooks, and there is a ready-made Colab tutorial with all the views loaded.
Students, teachers and researchers who want to understand or explain how transformer models work.
Developers only. You run it from Python code in a notebook, though the Colab tutorial needs very little setup. New to this? Start here.
Using Claude Code, Cursor or another AI coding assistant? Paste the prompt and it will walk you through the setup.New to this?