Dev tools

Isham Faizal ships an in-browser LLM attention visualiser that hits 158 points on Hacker News

September 9, 2026 at 7:30 AM PT

A generated signal-field graphic that stands in for a screenshot of the tool

Why it mattersA working developer who has never opened an attention matrix can now hover a token and see which past tokens the model actually leans on, which changes what you expect an LLM to reliably reproduce.

Isham Faizal published a Show HN on 2026-09-08 for an interactive in-browser tool that visualises which past tokens a language model draws from when it generates each next token. The Show HN reached 158 points on Hacker News, and the underlying post on ishamf.dev is dated 2026-09-07.

What it draws

Tap or hover any generated token in the demo. Every previous token dims or brightens by how much the model leaned on it when producing that next token. The signal is the attention weight scaled by the value vector's magnitude, aggregated across attention heads, summed across layers, and normalised so the largest previous token sits at opacity 1. Faizal states plainly in his own footnote that "affected might not be fully accurate", because the reduction throws information away, and gives the exact reduction.

The default "Office Move Summary" demo shows what the reduction is good for. Hover a copied address or a copied date in the generated text, and the same tokens light up in the source data above. A "Debugging an Average Function" demo shows a 600 million parameter model reproducing an entire JavaScript function except for the intended edit, and it lets you check which source tokens carried that copy through.

How it runs

The app is a plain React front end using Transformers.js to run the model in the browser, and the browser demos are baked from a small set of pre-computed prompts so a visitor does not wait for hundreds of megabytes to download before anything renders. Faizal notes in the post that Transformers.js compiles model computation to WebAssembly from .onnx files, which have a fixed set of outputs, so accessing the internal attention tensors needed for the visualisation meant writing a custom generation loop around the model.

What it changes about a mental model

An LLM predicts the next token from a probability distribution, so an intuition that says a long verbatim copy is fragile is a reasonable one to hold. This visualisation makes it plain how the copy actually works: attention concentrates on the exact tokens in the source, the model reads them back, and the error probability on that path is much lower than a raw sampling intuition would suggest. Faizal writes that this "addresses one thing that I've previously found unintuitive about LLMs".

For a working developer that is a useful five minutes: it settles whether you should expect an LLM to reproduce a proper name or an SKU or a snippet of code exactly, and it does it with the model live on screen. The reduction throws away one dimension of information, so pattern reading here sits a step above reading attention in a research paper, and Faizal is direct about which patterns survive the reduction. The tool is one page on his personal site and is free to open in the browser.

Source

Isham Faizal, LLM Attention Visualization on ishamf.dev, and the Show HN thread.

Source: ishamf.dev

This item was written by an AI system from the linked source. Reveneau is responsible for what it publishes.

More from AI News

Microsoft Edge automates extension review checks after AI-assisted submissions overwhelmed its pipeline

The Microsoft Edge team said on 2026-09-08 that AI-assisted coding has raised extension submissions past its review capacity, so it has automated the repeatable validation checks and cut Featured badge refreshes to every 15 days.

Source: PressDev tools

Astral signs and notarizes uv 0.12.12 binaries on macOS and Windows

Astral released uv 0.12.12 on 2026-09-09 with code-signed macOS and Windows binaries, notarized on macOS with an Apple Developer ID and timestamped on Windows with Authenticode.

Source: GitHubDev tools

Browser Use ships Pi, a TypeScript web agent that writes JavaScript into a persistent V8 REPL and drives Chrome through raw CDP

Browser Use published Pi on 2026-09-05, a TypeScript web agent that writes JavaScript into a persistent V8 REPL and drives Chrome through raw CDP, and the repository is at 126 stars four days later.

Source: GitHubDev tools