How a prompt travels through 28 layers

What happens inside an LLM between your prompt and its answer?

How LLMs work · about 5 minutes

Between your prompt and its answer, an LLM runs your text through a stack of layers. Each layer adds to a working state. The answer comes from that state after the last layer.

Sketch: Xiaohei rides a lift up a tall building; floors on the way show different guesses, and the top floor shows the final answer