Lesson 44
What an agent is
Build an LLM From Scratch, 53 lessons
Lesson 44: What an agent is
Build an LLM From Scratch, Lesson 44 of 53

Take away the marketing and an agent is a loop around a model. Step through a coding agent that fixes a failing test, break it, and see why the loop is where the memory and the stopping live.
The question for this lesson: what is an agent, with the marketing taken away, and how does it stop?
Last lesson ended with a model that is cheap enough to run, and it can answer. Everything it says comes from what it learned in training and from the text you hand it.
Now give it a job. A small program has tests, and some of them fail. You tell the model: “The tests fail. Find the bug and fix it.”
Tests are checks that compare what a program does with what it should do. A repo is the folder of code files for a job.
The rest of this lesson is in Premium
Premium includes every lesson, with its notes, practice and progress.