Index

Free, with Google

Keep going, free.

A free account opens lessons 2 and 3 of every track, 33 more lessons, and keeps your progress and review cards on every device.

Start free with Google

A chalk plan

Open everything on chalk.

Every lesson, board, video, lab and paper, and the full review decks. Yearly is $39/year.

See plansStart free instead

Module 05 · AI · The loop and its harness · about 25 min to read

Play it as a journeyTutor comes with a plan

Memory (four places a fact can live, and only one of them is the model)

Memory
Memory · Open board

Building with LLMs, the seventh board of the run. The lesson before this one (The Harness (everything around the loop that the model never touches)) drew the ordinary code that sits around the model and puts together, turn by turn, the text it reads. This board opens the one drawer of that code everybody assumes is the model’s own: remembering. It draws four places a fact about a customer can live, the habit that writes a finished conversation down as a few dated notes, the habit that reads six of those notes back next time, and a table where skipping one column, the date, cost nine points of accuracy.

Before you start. The assistant in this lesson works an online shop’s returns desk, where it can look up an order and start a return. Around the model sits ordinary code somebody wrote, the harness: it builds the text the model reads, and it runs whatever the model asks for, like that order lookup. For each answer the harness hands over one block of text, the last few things said plus anything it just looked up, and that block is the window (What the Model Sees (one string, every turn, from the top)). The model reads the window and writes a reply. Between that answer and the next it keeps nothing at all.

Lesson 49 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.

See plansAlready a member? Sign in

Or start free: a free account opens lessons 2 and 3 of every track.

In this lesson

  • “Same as last time”
  • April 2023, Stanford: a town of twenty-five people who forgot breakfast
  • October 2023, Berkeley: memory as an operating system
  • The write path: a clerk who works after closing
  • The struck-out line
  • Which six of fifty
  • Where should each fact live?
  • What does the clerk charge after closing?
  • Which six, priced
  • The fading rule, in code

Terms it explains: harness, window, store, extraction, memory poisoning, scoping, recency, tokens, weights, semantic, episodic, schema, newest wins, old kept, 2.9, 29, 240 tokens, 88%.

Review AI