← sources

Agent memory - simple solution

source: reddit (reddit:ClaudeCode)published 2026-10-21 15:52ingested 2026-10-22 02:42

retained text

I found a surprisingly simple way to give your AI agent a memory, and it doesn’t cost anything.

The problem is pretty familiar. You have a great session with Calude, you fix a tricky bug, and then you start a new session and have to explain the whole project all over again: how it’s structured, where the files live, what you’ve already tried. That’s because every new session starts with a blank memory.

There are plenty of solutions out there, but most of them mean sending your data to someone else’s server or paying for a plan. I came across a much simpler idea that actually works.

Here’s the setup. Create a local Obsidian vault on your hard drive, for example `c:\path\agents-wiki`. Then add two instructions to your [`agents.md`](http://agents.md) file:

1. Before asking the user any question, check the `agents-wiki` first to see if the answer is already there.
2. During or after a task, if you find something that would be useful for future sessions, write it to the `agents-wiki`.

That’s it. The agent gets a shared notebook that persists between sessions, it lives on your own machine, and Obsidian makes it easy to read and edit the notes yourself when you want to.

document fetched 2026-10-22 00:43 · canonical https://reddit.com/r/ClaudeCode/comments/1xbqwdp/agent_memory_simple_solution