Y Combinator's Garry Tan Open-Sources GBrain to Fix AI Agent Memory
Y Combinator's Garry Tan open-sources GBrain, a Postgres-backed AI agent memory system with a self-wiring knowledge graph, 43 skills, and overnight 'dream cycles' that compound knowledge while you sleep.
Takeaways
- What it is: GBrain is YC CEO Garry Tan's open-source AI agent memory system — MIT-licensed, Postgres-backed, 22k stars.
- Core innovation: A self-wiring knowledge graph built with zero LLM calls, delivering +31.4 P@5 precision over vector-only RAG on BrainBench.
- Dream cycle: An 8-phase overnight maintenance loop that enriches, deduplicates, and consolidates memory while you sleep.
- Skills paradigm: Ships 43 curated markdown-based skills aligned with Anthropic's "Don't Build Agents, Build Skills" approach; skills are auto-improvable via
gbrain skillopt. - Controversy: Early code review found flagship features were markdown instructions, not executable code; the project has since grown substantially with 317+ commits.
- Setup: Free, installs in ~30 minutes via
bun install -g github:garrytan/gbrain; supports Claude Code, Codex, Cursor, Windsurf, and ChatGPT via MCP.
Most AI agents have a memory problem. Every new session starts from zero. They don't know who you met last Tuesday, what you decided in that meeting, or what's still open with a customer. Today's AI agents start from zero every time you have a conversation , they don't remember who you are, don't know what you're doing, and don't understand your context. Garry Tan, President and CEO of Y Combinator, built a fix for this , and now he's open-sourcing it.
GBrain is an open-source AI agent memory system that turns plain-text Markdown notes into a self-wiring knowledge graph an agent can read, write, and reason against. It was open-sourced by Tan on April 5, 2026, under the MIT license. The project amassed over 5,400 GitHub stars in its first 24 hours and reached more than 1.5 million people on X. It now sits at nearly 22,000 stars.
This is not a demo
Tan is the President and CEO of Y Combinator. He built GBrain to run his own AI agents , it's the production brain behind his OpenClaw and Hermes deployments: 146,646 pages, 24,585 people, 5,339 companies, and 66 cron jobs running autonomously. The released version generalizes that personal setup into something any operator can install in about 30 minutes.
The core insight is deceptively simple. The operating logic is a continuous cycle of read, respond, write: when the agent receives a message, it first detects the entities involved (people's names, companies, concepts), then looks up the relevant knowledge already in GBrain, responds with complete context, and finally writes the new information learned from the conversation back into the knowledge base. Each interaction compounds.
Search finds pages. GBrain reads them for you.
The biggest differentiator isn't the storage , it's the synthesis layer. Most personal-knowledge tools return a list of matching documents and leave you to read them yourself. GBrain goes further. Ask it "What do I need to know before my meeting with Alice tomorrow?" and instead of five pages to open, you get a synthesized briefing: what's open, what's stale, what you committed to, and an explicit note on what the brain doesn't know yet.
That last part , the gap analysis , is what makes it genuinely useful. GBrain adds two things nobody else ships together: a synthesis layer that gives you the actual answer, synthesized well-cited prose across people, companies, deals, and ideas , not "here are 10 chunks that mention your query." The second is the knowledge graph.