hivemind
Claude Code has two kinds of memory. There is a global instructions file, CLAUDE.md, that you write yourself and every session reads. And there is what Claude learns on its own while you work, which it saves for that project only. The second kind grows fastest, and it never leaves the project where it was learned. A correction I gave in one project (how I like my commit messages, to ask before running anything that deletes) meant nothing in the next one, unless I stopped and copied it into the global file by hand.
hivemind gives all of those projects one second brain. A single folder collects everything Claude has learned about you and your work, it updates itself after every session, and a new session in any project looks there before it asks you.

The kit makes no network calls and reads no credentials. The brain is a plain folder. If you put it inside a folder you already sync, it is backed up the way the rest of that folder is, and only then.
Is it for you?
- You use Claude Code in more than one folder or repo.
- You keep correcting the same things in different projects.
- You want to see, and fix, what Claude believes about you.
- You would like that memory backed up, not sitting in one hidden folder on one laptop.
Two pieces make it work
A hook writes the brain. Claude Code can run your own commands when something happens, like a session ending. These are called hooks. The kit adds one: when any session ends, a small script copies every project's memory into the brain. Claude does not decide whether to do it and you do not have to remember; it runs every time.
An instruction reads it. A short block in your global CLAUDE.md, the file every session reads first, tells Claude where the brain is and when to use it: when it is missing context (who you are, how your machine is set up, a project this folder does not know), check the brain before asking or guessing. New facts that apply everywhere are written to the brain's shared folder.
That split is deliberate. Saving has to be reliable, so it is a hook. Remembering to look is a judgment call, so it is an instruction, and because the instruction lives in the global file, it works in every project, including one created a minute ago.
How it works, in three stages
- You work as usual. In each project, Claude saves what it learns, the way it always has.
- The session ends. The hook mirrors every project's memory into the brain.
- The next session starts, anywhere. It reads the global file, finds the pointer to the brain, and looks there when it needs to. A brand new repo already knows how you work.
It keeps up with every change
A memory you cannot trust is worse than none, so the brain is a true mirror, not a pile of copies. A new note arrives, an edited note is updated, and a note you deleted disappears from the brain too, so an old fact never lingers to mislead the next session.

Every run leaves a small receipt with the time and the projects it synced, so you can see at a glance that it is working.
What lives in the brain
Brain\
BRAIN.md the index: what lives where
global\ what applies everywhere: you, your machine, your rules
projects\ a mirror of each project's own memory
last-backup.txt the receipt of the last runglobal\ is the part you will care about. Seed it with the five or six things you are tired of repeating. projects\ belongs to the hook; change a memory at its source and the mirror follows.
Everything is plain markdown, so you can open the brain and read what Claude believes about you, fix what is wrong and delete what is stale. Inside an Obsidian vault it renders as notes with links between them.
Two weeks of real use
I wanted to know whether sessions actually use the brain, not just whether it grows. So I went through every Claude Code transcript on my machine from the first two weeks.

Fifteen sessions went to the brain to look something up; three more were me maintaining it. The moments that sold me:
- A brand new folder. The first task in a project created that morning read my shared facts before doing anything, so it knew my setup without being told.
- A lost conversation. I could not find the chat where an earlier build was planned. One request, "get me everything about it", and the session rebuilt the context from the brain.
- Picking work back up. A new piece of work on an existing app started with the session reading that app's notes in the brain, before it planned anything.
Good to know
- Windows only, as shipped. The script is about forty lines, so a macOS or Linux version is a small job.
- Recall is an instruction, not magic. Claude Code still loads only the current project's learned memory by itself. The brain works because the global file tells every session to look there, and in my sessions it does.
- Keep it private. The brain holds whatever Claude was asked to remember. Put it somewhere you would put your own notes, not a shared folder.
- It does not replace CLAUDE.md. Your global file still holds the rules you write by hand. The brain holds what Claude learns, so you stop copying it over.
Get it
Setup takes about ten minutes: one script, one hook and one block in your global CLAUDE.md. The README on GitHub walks through every step, with troubleshooting and how to remove it. Or clone it, open Claude Code and ask it to set up hivemind from the README; it will ask you where the brain should live.