An assistant that remembers, and forgets on request

Customers hate repeating themselves. Memory fixes that, and creates a new duty: remembering only what is useful, and forgetting when asked.

The brief

A shop's support assistant answers the same customers every week. The team wants it to remember order history and preferences between conversations, and legal wants proof that a customer's memories can be removed on request.

What you will build

  • Short-term memory: one conversation kept across turns and trimmed when long
  • Long-term memory: facts about a customer extracted and recalled in later conversations
  • A 'forget me' path that deletes a customer's memories
  • Tests that prove recall works and that deletion is complete

Requirements

RequirementDone when
ContinuityA second message in the same conversation uses the first without the user repeating it
RecallA new conversation for the same customer uses a fact from an earlier one
IsolationCustomer A's memories never appear in customer B's answers
UpdatesA changed fact, such as a new address, replaces the old one
ForgettingAfter a delete request, no memory for that customer is returned, and a test proves it

What to learn it from

Milestones

  1. Keep one conversation across turns
  2. Add long-term memory scoped by customer id
  3. Test recall in a new conversation
  4. Test isolation between two customers
  5. Add and test the delete path
  6. Decide what must never be stored and enforce it
The failure worth testing
Store a memory for one customer and ask as another. A memory system that leaks across users is worse than one that forgets everything.

Stretch goals

  • Show the customer what is remembered about them
  • Expire memories after a set time
  • Measure how many tokens memory adds to each request

Before you call it done

Worth remembering
  • Recall, isolation and deletion each have a passing test
  • Nothing sensitive is stored, by design, not by luck
  • Memory cost per request is known
Back toAll frameworks

Every expert started right here.