aiia.li
EN DE

ai

What happens to your question after you press send in an AI chat bot

Your question leaves your device immediately, gets cut into chunks, and turns into columns of numbers. From there the model never sees language again, and it never holds the finished sentence either. An animated walk through the whole path, from keystroke to answer.

Somewhere between pressing send and the first word appearing, your question stops being language and becomes arithmetic. That conversion is the whole trick, and it is the part almost nobody sees.

It leaves immediately

Your device does very little. It draws the letters, packages them, and waits. The question then travels to a datacenter, where it lines up with everyone else's questions arriving in the same second.

The model you are talking to is not yours. It is one program, running on shared hardware, used by all of us at once. There is no copy of it sitting on your phone, and nothing on your phone is doing any thinking.

The sentence gets cut up

Inside, your sentence is separated into chunks. Not quite words, not quite syllables: pieces of text that the system has decided are worth treating as units. Common words usually stay whole. Longer or unusual ones get split.

"Why is the sky blue" comes apart into a handful of these pieces, in order.

Then the interesting part

Each chunk grows a column of numbers beneath it.

This is where people who are not mathematicians tend to check out, which is a shame, because it is the one step that actually explains the behaviour of the whole thing. The numbers are coordinates. Each chunk is placed at a position in a space with a very large number of directions, and things that get used in similar ways end up near each other. Nothing in there says "sky" or "colour". There is only the position, and how close it sits to other positions.

From this point on, the model has no access to your sentence. It has the numbers. That is the entire input.

Weighing everything against everything

Before it guesses anything, the model compares each chunk against every other chunk and decides which ones matter for the one it is about to produce. In "Why is the sky blue", the connection between "sky" and "blue" carries weight, and "is" carries much less.

Then it scores its candidates for the next chunk. Every candidate it knows, all at once, and one of them comes out ahead.

It never holds the finished sentence

This is the part I found genuinely odd while building the animation out. The winning chunk is appended to your question, and the whole calculation runs again from the beginning. New weights, new comparisons, new scores. One full round per chunk.

The model does not write a sentence and then hand it over. It produces one piece, forgets that it was ever a decision, and asks the same question again with slightly more text in front of it.

Which is why the answer types itself out on your screen. That is not a loading animation or a stylistic choice. It is the process, arriving at the speed it happens.

Why I built it

I wanted a version I could show someone in under two minutes without a whiteboard. The steps are not hard, but they are invisible, and the words we use for them (tokens, vectors, attention) sound like they need a degree.

They do not. They need a picture.

The animation follows one question from keystroke to answer, in one continuous move: your device, the datacenter, the model inside it. No formulas. Mostly I built it because explaining it out loud kept taking me longer than it should.

Tags: aillmchatbotsexplaineranimationtokensvectorsdeveloper-life