Free lesson · Module: Agents in Production

Memory & Context

Context is the agent’s working memory

Everything the model knows right now sits in its context window: the system prompt, the history, the tool results. Think of a desk covered in papers. The desk is small. Once it’s cluttered, the important page gets lost even before space runs out. So much of agent work is deciding what goes on the desk and what comes off.

Start with memory in files

The simplest memory for an agent is plain files: notes.md, plan.md. The agent writes its conclusions there and reads them at the start of the next session. It’s a notebook you can open and check: you see exactly what the agent “remembers.” No extra infrastructure needed. Most agents can live on this for a long time.

More on Way of the Agent

Still in this lesson: 3 more cards, a quiz of 5 questions, XP and stars - in the course.

Continue the lesson on the Path