garrytan/gbrain

AI Engineering

A memory layer for existing AI agents that stores sourced, correctable facts shared across tools.

31,203
4,663
TypeScript
MIT
6 months old

GBrain is worth a look if you already run an agent and keep re-explaining the same context to it; it is not a drop-in for everyone, since the most complete path assumes Bun and some comfort with MCP configuration.

The problem

Before a meeting, you want your agent to answer "what do I need to know about Alice?" rather than hand back five file names to open yourself. Today that context is scattered across notes, past meetings and prior chats, and each agent you use remembers a different fragment. GBrain changes the retrieval step: you ask a question, the agent pulls explicit facts with their sources and composes an answer. The result is a shared memory that survives switching between agents rather than being rebuilt in each one.

What's different

The design centers on explicit facts with sources, plus corrections and withdrawal, instead of an opaque vector blob. That makes the memory auditable: when a fact is wrong you can point at it and retract it. Keyless keyword retrieval works out of the box, with semantic search, synthesis and background enrichment as opt-in additions, so a first run needs no API spend. Skills live beside the knowledge in the content root, and agents join an authorized catalog where only approved editors publish.

The trade-off is that GBrain is opinionated about infrastructure. The full "always on" experience assumes a server-hosted agent with 24/7 cron jobs and an "overnight dream cycle" that enriches the brain while you sleep; the README itself flags this as the highest-cost path, both a deployed server with 8GB+ RAM and API usage that scales with how hard the agent runs. The lighter paths avoid that, but then you are choosing among several setups with different behavior. Also note the packaging warning: the npm gbrain package is unrelated, so only the documented install route is correct.

Who should try it

Good fit: you already use an agent daily (Claude Code, Codex, OpenClaw, Hermes) and want one memory you control across them, or a small team that wants shared brain skills with editing restricted to approved people. Starting with the coding-agent setup is the least intrusive option because it keeps your agent's identity and stores memory inside its environment, with no new private repo required.

Poor fit: you want a hosted turnkey product with nothing to install (there is a hosted option, but that is a different commitment), or you have no agent workflow yet and are just curious about memory. Also a poor fit if you cannot or will not install Bun, since the CLI and setup path depend on it.

Requirements and limitations

Bun 1.4.0 or newer is required for the CLI. The default local start uses PGLite with --no-embedding, which means no server or Docker and no keyless-to-paid surprise, but semantic retrieval is off until you add embeddings. The setup command writes an MCP entry and read-context hooks and smoke-tests them; verify what it resolved before accepting, and use --dry-run if you want a preview.

Ongoing upkeep matters: schema migrations can leave a brain behind (the README links issue #218 and a fix path), and upgrading existing worker installs requires following the authorization and queue guide before restarting services. gbrain doctor is the first stop for health problems, with db-repair and engine status --probe for specific failures. The heavier server path adds real hosting and token costs; the README is explicit that this exceeds a chat subscription.

HotRepo's take

The only dated observation is one daily-board appearance on 2026-10-25 with 31,180 stars at +38 that day; HotRepo began tracking on 2026-10-24, and that single sample is insufficient to judge whether interest is rising or fading. The project is roughly 202 days old, so age alone tells you little about long-term maintenance. Before adopting, check the migration and authorization-upgrade notes against your current install, since those are the documented places where upgrades break.

Project source and documentation

Hacker News

GBrain – The memex, built for people who think for a living
▲ 9 · 2 comments · April 10, 2026
Garry's Opinionated Agent Brain
▲ 3 · 0 comments · June 1, 2026

Written by AI from the project's README, updated October 25, 2026. The project's own docs are the source of truth.