# FlowState **A shared project memory for your AI apps. Free, open source, and stored on your own machine.** FlowState is a local [MCP](https://modelcontextprotocol.io) server. It gives every AI app you use the same memory of your projects: todos, changes, decisions, problems and lessons learned. Your AI reads a short brief when it starts work on a project and writes down what happens as it goes. The next chat (or the next app) picks up where the last one stopped. Everything lives in one SQLite file on your computer. Your memory is not sent anywhere unless you turn on an optional feature that does so (an off-site backup to your own private GitHub repo, remote access through your own Cloudflare Tunnel, or the optional relay). FlowState itself makes one network call: once a day it asks GitHub whether a newer release is out. It sends nothing about you or your projects, and `flowstate update check off` turns it off (see "Upgrading"). If FlowState saves you some re-explaining, a [star on GitHub](https://github.com/dialectforge/FlowState) helps others find it. ## Many AIs, one memory, at the same time Claude, ChatGPT, Cursor and Grok can all use FlowState at once, on your computer, across your network, or from your phone (through the optional relay or your own tunnel). When one AI logs a decision or a change, the others see it the next time they check. Hard rules and handoff notes reach every AI, and every change records which AI made it, so you always know who did what. Work across projects is linked too, so a change to something shared shows up in every project that uses it. ### Several agents at once When two agents start on the same project at the same time, both can see the same "next" todo and quietly do the same work. So an agent claims a todo before it starts (`manage_todos(action="claim", todo_id=4)`, 15 minutes by default, up to 120) and releases it, or hands it off with a note, when it stops. Other agents see the claim in their brief (`#4 Fix login (claimed by cursor on mac-mini, expires in 9m)`), `next` skips it and lists it at the end, and a second claim is refused with the holder's name. Nothing is hidden or locked: a claim simply runs out if the agent goes away, and it is released when that app's session ends (quit, ended or idle; the same app reconnecting may take its claim back). Anyone (you included) can still update or finish a claimed todo; they just get a warning, and `manage_history(action="who")` shows it. A decision that reads like a current one (and doesn't say it replaces it) is still saved, but flagged as a *possible* conflict (`D31 vs D12` in the brief) for the agent and then you to settle in the review queue; FlowState matches words (and meaning, if the local model is installed), it doesn't judge. When two entries clearly disagree, FlowState also queues a disagreement card: claim A and claim B, who wrote each, and up to two short evidence snippets. You keep the older, the newer, or both, or dismiss the card. The one you don't keep is marked superseded, not deleted. An agent flags a pair with `log_work` (`conflicts_with`, `topic`, `evidence`) or `manage_links(action="flag_conflict")`. The review page shows the card (side by side on a wide screen), and the tool reply includes the same card as plain text plus the review link. Chat apps that support MCP Apps can show the card in the chat; its buttons are not yet cryptographically proven to be a person. Each window of an app gets its own session, and the brief opens with one line about what the others did meanwhile (`Since your last visit (Oct 19): Claude Desktop and Grok saved 3 decisions, 5 changes, 2 todos.`), and nothing when nothing changed.

Claude and Grok on an iPhone, side by side, both reading the same FlowState project brief and both knowing what was just shipped from the PC

Worked on my PC with Grok Build, then asked Claude and Grok on my iPhone. Both knew what I did last. (Click for the full-quality video.)

## Why I built it I built FlowState v1 in January 2026 as a gift to the vibe coder community, back when context was a serious bottleneck and every new AI chat started from scratch. This week I updated it, because the bottleneck moved. Now most of us work across several AI platforms at once, and keeping context between them is the new problem. FlowState stays free and local. *John Martin, DialectForge* --- ## Quick start: point your AI at this repo Paste this into an AI app that can run commands on your computer (Claude Code, Cursor, Windsurf, Codex CLI, Grok Build, ...): > Set up FlowState for me from https://github.com/dialectforge/FlowState by following its AGENTS.md. The AI reads [AGENTS.md](AGENTS.md), asks you which apps to connect and whether you want nightly backups and the FlowState skill, shows you a dry run, then runs `setup_flowstate.py`. When it's done, fully quit and reopen the apps it connected. Claude Desktop's chat can't run commands by itself. Set it up from one of the apps above ("...and connect it to Claude Desktop"), or run the script yourself (below). ### What `setup_flowstate.py` does It uses the Python standard library only, and it's safe to run again (it reports `unchanged` for anything already set up). In order, it: 1. checks for Python 3.11 or newer; 2. creates `.venv` in the repo folder and runs `pip install -e mcp-server` into it (skip with `--skip-install`); 3. creates the database if there isn't one, or keeps your existing one and adds only the new FlowState tables and columns (numbered migrations, with an integrity-checked backup first when the database already has data); 4. adds a `flowstate` entry to each chosen app's MCP config, after saving a copy of that file as `.flowstate-backup-