Visualizers

Learn by moving things

Interactive explainers for the ideas behind retrieval, embeddings, and agents. A formula tells you what is true; dragging a vector shows you why. Each one also appears inside the article it belongs to, and runs entirely in your browser, so drag, poke, and break it.

Portrait of Sachin Gupta rendered in binary

The draft-and-verify cycle

From: Draft, Then Verify →

One cycle of speculative decoding. A small draft model guesses the next tokens in one pass; the large target model verifies them together, accepts the correct prefix, and corrects the first miss. Step through it and watch one target pass commit several tokens.

Written so far
the best way to learn is to practice
step 1 / 5

So far, the model has written the text above. Now it needs the next tokens.

Draft better: the previous word fixes the crossbreed

From: Draft Better, Verify Smarter →

DSpark's first idea, interactive. Two replies fit after 'Thanks!': 'of course' and 'no problem'. Flip a blind parallel drafter (reaches for the same word and crossbreeds into 'of problem') against DSpark's sequential head, which lets position two see position one and adds a small bias so the words always agree, at the same speed.

Position one lands on:
Drafter:
“Thanks!”two good replies: “of course” / “no problem”
ofposition one+problemposition two, blind= “of problem”  ✗ crossbred
A blind parallel drafter predicts both words at once, each unaware of the other, so it reaches for the same second word every time. After “of” that gives “of problem”: every word fine alone, wrong together. Flip position one and watch it stay wrong.

Verify smarter: stop when the number drops

From: Draft Better, Verify Smarter →

DSpark's second idea, interactive. Each drafted word carries a confidence of surviving the check; multiply them into a running survival that only falls. Change the server load to move the 'worth a check' line and watch the cut move: heavier load raises the bar and stops sooner, so the target never spends its scarce capacity on words that were going to be rejected.

Server load:
the dashed line is “worth a check”; it rises with load
Drafted so far
The meeting is scheduled for ...
Draft wordRunning survival (each confidence multiplied in)
next
0.93verify
Monday
0.74verify
at
0.41verify
noon
0.14stop, drop rest
Verify
3 words
Drop unchecked
1
Worth line
0.25
Medium load: it checks a solid prefix and drops the least likely tail. The running number only falls, so once a row drops below the line, every word after it is worse too. That is why it is safe to stop there and drop the rest without checking, and it never changes the final text.
Visualizers — Sachin Gupta