The Two Clocks board puts one request on a ruler, with a long first wait and then a steady tick per word. This lesson builds the thing that keeps that tick short. Stage one of the serving series that Build Your Own Inference Engine maps.
Before you start. A GPT writes a reply one character at a time, and each character needs one pass through the model, the forward pass. In Sampling and What Scale Buys you ran that pass over the last 32 characters for every new character. Attention, from Attention by Hand, makes two vectors from each character, a key and a value, so that later characters can look back at it. Later in this track, Prefix Caching (the same start, computed once) and The Two Clocks (TTFT, TPOT, and why goodput is the number) explain the serving side of this without code, so read them after if the numbers here leave a question. Here you write it.
Lesson 70 of 83 in AI
The rest of this lesson is part of a plan.
A plan opens every lesson, board, video, lab and paper on chalk. Yearly is $39/year.