Memory tool
A Claude API tool the model uses to view and edit files under /memories. Your harness carries out each command.
The Claude API defines a memory tool,
{"type": "memory_20250818", "name": "memory"}. Think of the model as someone dictating notes, with your harness as the assistant who files them. The model knows how to use it: it sends commands likeview,create,str_replace,insert,deleteandrenameon paths under/memories. Your harness runs them, against files, a database or anything else. So the memory lives where you choose, and the model can check it at the start of a task and save what it learned at the end.
Try it now
The list makes the model plan, survives compaction, and lets you spot a bad plan early.
Learn it properly
Memory, plans and long tasks · To-do lists, progress notes, memory files and checkpoints. About 40 minutes.
Other terms from the same lesson
- CLAUDE.md: A project instructions file a coding agent loads at the start of every session: build commands, conventions and things to avoid.
- memory poisoning: An injected instruction saved into an agent's memory, where it comes back in later sessions.
Never trained an AI?
Teach a small one to write, right in your browser. It takes about 20 seconds and needs no account.