Agent memory
For engineers
Working memory in context, long-term stores, file-based notes, what to remember, and memories that go stale or get poisoned
110 questions across four stages: Understand, Apply, Solve and Judge.
Try 5 questions
Practice items, not counted towards your mastery. No account needed.
Check yourself · 1 of 5
A coding agent has run 40 tool calls in one session. What is its short-term memory?
Check yourself · 2 of 5
A shopping agent should remember each customer's shoe size and preferred currency. Which store fits best?
Check yourself · 3 of 5
Why does a notes file help an agent that works over several sessions?
Check yourself · 4 of 5
Which item should a memory policy forbid an assistant from saving by default?
Check yourself · 5 of 5
A memory says "Production database is db1". The team moved to db2 last month. What kind of failure is this?
Topics
- Short-term memory in the context window4 min read · Conversation history, tool results and scratchpads as working memory, and why they fill up and degrade
- Long-term memory stores and retrieval5 min read · Vector stores, key-value profiles and graphs that persist across sessions, and how the agent searches them
- File-based memory and agent notes5 min read · Progress files, notes the agent writes for itself and memory tools backed by a directory
- Deciding what an agent should remember4 min read · Write policies, user visibility and control, consent, expiry and deletion of remembered facts
- Stale, wrong and poisoned memories5 min read · Outdated facts, false memories the agent wrote itself, cross-user leaks and injected instructions saved as memory
Start here
- MemGPT: Towards LLMs as Operating Systems (opens in a new tab)PaperFree
The paper that frames context as fast memory and external stores as slow memory the model pages in and out.
- Memory tool (Claude API docs) (opens in a new tab)DocsFree
How a directory-backed memory tool works: view, create and edit commands, and security notes on path handling.
- Memory overview (LangChain docs) (opens in a new tab)DocsFree
Short-term versus long-term memory, and semantic, episodic and procedural memory types, with write timing.
Scenarios
Helps to know first
110 questions · last verified 2026-12