Give your AI a memory that outlives the chat
Short answer
AI coding tools forget everything when a session ends. Keep a folder of Markdown notes, tell the AI in its instruction file (CLAUDE.md, AGENTS.md or GEMINI.md) to read your project notes before it works and to write down what it did after. Neuralth shows that folder as a living graph and versions every change with Git, so the memory is yours, readable and shared by every model.
Why AI tools forget
Claude Code, Codex, Gemini CLI and GitHub Copilot start every session with an empty context. They do not remember the decision you made last week, the convention you explained yesterday or the task you left half done. Built-in memory features help a little, but they are tied to one vendor, hidden from you and gone when you switch tools.
A plain folder of notes fixes this. The AI reads it at the start, writes to it at the end, and the next session, with any model, picks up where the last one stopped.
How it works
- Your notes are the memory. Project goals, decisions, conventions and open tasks live in Markdown files.
- The AI reads before it works. A short rule in the tool's instruction file points it at the right notes.
- The AI writes after it works. It logs what it changed and records new decisions, linked with
[[wikilinks]]. - You see and control everything. New notes appear in the Neuralth graph, and every edit is a Git change you can review or undo.
Step 1: Create a vault
Install Neuralth and choose a folder for your notes, for example ~/notes. If you already have an Obsidian vault, open that folder: it works as is. Connect a private GitHub repository if you want every change versioned and synced between computers.
A simple structure that works well for AI memory:
notes/
├── Projects/
│ ├── Website.md ← hub: goals, stack, decisions
│ └── Website - Open tasks.md
├── Journal/
│ └── 2026-12-04.md ← what the AI (and you) did today
├── Decisions/
│ └── Use Astro for the site.md
└── Home.mdStep 2: Write the memory rules
Write the rules once. Keep them short and concrete; the AI follows short rules better than long essays.
# Memory
My notes live in ~/notes (a Neuralth vault, synced with Git).
## Before you start
- Read ~/notes/Projects/<project>.md (goals, decisions, conventions)
- Read ~/notes/Projects/<project> - Open tasks.md
## When you finish
- Add a short log to ~/notes/Journal/<YYYY-MM-DD>.md:
what you changed, why, and what is left
- Link it to the project with [[<project>]]
- Record new decisions in the project note, not only in the log
## Never
- Never write passwords, API keys or tokens into notesStep 3: Point each AI tool at your vault
Every tool reads its own instruction file at the start of a session. Paste your rules there, or a single line that says "Read and follow ~/notes/AI rules.md". A global file applies to every project; a project file applies to one repository.
| Tool | Instruction file | Global version |
|---|---|---|
| Claude Code | CLAUDE.md in the project | ~/.claude/CLAUDE.md |
| OpenAI Codex | AGENTS.md in the project | ~/.codex/AGENTS.md |
| Gemini CLI | GEMINI.md in the project | ~/.gemini/GEMINI.md |
| GitHub Copilot | .github/copilot-instructions.md or AGENTS.md | Settings in your editor |
| Cursor | AGENTS.md or .cursor/rules | User rules in settings |
If the tool runs in a sandbox that only sees the current project, allow it to read your vault folder or add the vault as a second working directory.
Step 4: Watch the brain grow
After a few sessions, open the Graph view in Neuralth. Journal entries link to project hubs, decisions link to the notes that caused them, and you can see at a glance what your AI knows. Because the vault is a Git repository, the Source Control panel shows exactly which notes the AI created or changed. Review them, commit, and push.
Tips that make AI memory work
- One hub note per project. Goals, stack, decisions and links to everything else. The AI reads this first.
- Write decisions with the reason. "Use Astro, because the site is mostly static" stops the next session from undoing it.
- Keep an open tasks list. The AI ticks items off and adds new ones, so nothing is lost between sessions.
- Log by date. One journal note per day is easy for both you and the AI to find.
- No secrets in the vault. Passwords, API keys and tokens belong in a password manager, not in notes.