AI engineering

Stage 1 · Lesson 3 of 8

The context window as a budget

How LLMs work: tokens and context

is the most tokens a model can handle in one request. Everything counts towards it: the (your standing instructions), the conversation so far, any documents you add, the that describe what the model can call, and the reply it writes.

Anything outside the window does not exist for the model. Windows now reach hundreds of thousands of tokens, but bigger is not free. You pay for every token on every call.

Replies get slower as the input grows. And models use information in the middle of a long context less reliably than information at the start or end. So treat the window as a budget, where every document you add must earn its place. That idea drives and later in the track.

A question to check yourself, an AI practice session and 1 cheat sheet entry come with the full roadmap. Unlock

Resources for this stage

Start with· follow one of these

Keep handy

Also worth your time

Mark this stage as not done?