A personal knowledge base that Claude can read and write from any device. Your notes are plain Markdown in a private GitHub repo. An MCP server on your own Cloudflare account gives Claude on the web, desktop, and phone access to them, and a sync job keeps a copy on your Mac for Obsidian and Claude Code.
- A notes repo with rules built in. Folders for work, life, people, and an inbox,
each with a template, and a
CONVENTIONS.mdthat tells Claude where things go. - One set of instructions for every assistant. You write your preferences once, in a note. Claude reads them through the server, and the Mac copies them into Claude Code, Codex, OpenCode, and Antigravity.
- Guides Claude loads when a kind of work comes up. You write your own. The starter has two: one that explains how a guide is laid out, and one for moving memories over from Claude's memory.
- Search by meaning and keyword, with work and personal notes kept apart.
- Full history. Every change is a commit, and Claude can undo one.
- Protection against planted instructions. A change to your instructions made through Claude waits for your approval on the Mac, and a change to the notes rules waits in a pull request. Both get an automatic check for prompt injection.
| Folder | What it is |
|---|---|
server/ |
The MCP server, a Cloudflare Worker, and the Claude plugin |
scripts/ |
The Mac sync job and the hooks for Claude Code and Antigravity |
kb-starter/ |
What your notes repo starts from |
extras/ |
Optional additions, off until you ask for one |
setup.sh |
Sets up a Mac |
Your notes live in their own private repo, cloned into kb/ here and ignored by this
one.
You need a Mac, a GitHub account, and a Cloudflare account. The steps suit Claude Code well: open this folder in it and ask it to set things up.
-
Make your own copy of this repo on GitHub (Use this template, or fork it), and clone it.
-
Let git sign in to GitHub. GitHub doesn't accept your account password for git, so the GitHub CLI signs in through the browser once and hands git a token:
brew install gh gh auth login --web --git-protocol https gh auth setup-git -
Run
./setup.sh. It asks for your name, what to call your knowledge base, and the name of your notes repo. Then it creates that repo as a private one fromkb-starter/, clones it intokb/, and installs the sync job. -
Deploy the server and add the connector in Claude.
server/README.mdhas the steps. -
Fill in
about/me.mdandabout/preferences.md, by hand or with Claude.
Needs Claude Code 2.1.277 or later, the first version that reads AGENTS.md.
- Daily memory sync. Claude's own memory learns from your chats, apart from your notes. A
scheduled task can copy what it learned into your notes every day, and can also correct
lines in Claude's memory that your notes have made out of date. It saves without asking
each time, so it's off by default. To turn it on, tell Claude Code "Set up the daily
memory sync", and it explains the choices first. It needs a paid Claude plan.
extras/memory-sync.mdhas the steps. - Antigravity. Add
antigravity.googletoALLOWED_REDIRECT_HOSTSinserver/wrangler.jsonc, deploy, and runscripts/antigravity-setup.sh.
setup.sh saves your answers in personal-os.config, which git ignores:
| Setting | What it is |
|---|---|
OWNER_NAME |
Your name, as Claude uses it |
KB_NAME |
What Claude calls your knowledge base, like SamOS |
KB_REPO |
Your private notes repo, like sam/samos-notes |
AUTO_UPDATE |
yes makes the sync job pull this repo from GitHub too |
OWNER_NAME and KB_NAME must match the same settings in server/wrangler.jsonc.
Leave AUTO_UPDATE off unless this repo's origin is your own copy. The sync job runs
these scripts every 2 minutes, so with it on, whatever is pushed to origin runs on
your Mac.
| It says | What to do |
|---|---|
| A note was changed both on this Mac and through Claude | Nothing is lost. Ask Claude Code to sync kb |
| Sync is paused: an unfinished merge or undo | Ask Claude Code to finish it in kb |
| The notes haven't synced with GitHub for some minutes | Ask Claude Code to check the sync |
| A sync ran for 30 minutes and was stopped | Nothing, the next one starts by itself |
| A file in the knowledge base is over 50 MB | Make it smaller or move it out |
| Your AI instructions were changed through Claude | It's on hold. Open Claude Code, which offers to review it |
| A change to the notes rules is waiting in a pull request | Open Claude Code, which offers to review it |
| The Personal OS folder has been behind GitHub for an hour | Ask Claude Code to check its uncommitted changes |
Being offline sends nothing. The sync picks up again by itself, and its log is at
~/Library/Logs/personal-os-sync.log.
UPDATING.md: bringing an older copy up to date.AGENTS.md: the rules for working in this folder.scripts/AGENTS.md: how the sync job and the hooks work.server/README.md: the server, its tools, and deploying it.
MIT. See LICENSE.