Part I - The language-model interface

For each model request, application code supplies the input and handles the result. The model processes the request as a sequence of pieces and generates one piece at a time. Part I explains what the model computes, what the surrounding software supplies, and how they connect.

The visible interface uses text, while the model processes a sequence of smaller pieces. The request must fit instructions, evidence, and output requirements within the space available to the model. The application must check the returned content against the task’s requirements before using it or acting on it.

Chapter 1 explains what the model calculates and what the software must do. Chapter 2 shows how a task is expressed through instructions, examples, and a response format that can be checked. Chapter 3 explains how software selects the rules, conversation history, evidence, tool descriptions, and user input for a request, and what it records about that selection.

Three chapter panels show text becoming token IDs and generated output; prompt instructions, examples and response fields followed by format, evidence and task checks; and context selection within a budget with retained and omitted information recorded. A lower strip connects the application building a request, the model generating, and the application checking the result.
Figure 1: Part I follows text received by the application through the pieces processed by the model to a response checked by application code. Open full-size map (new tab).

Chapters in this part