← Case Studies

// case study · one-pager

brain

A self-hosted, agent-readable personal memory layer for AI agents. v0 in two days. Three years of reasoning backfilled. A schema built so the artifact and the proof of the artifact are the same object.

role:
Designer · builder · sole author
stack:
Supabase Postgres + pgvector, MCP, Next.js, Vercel
  • v0 shipped in 2 days
  • 3 years of data backfilled
  • ~$0.40 extraction cost

What it is. A self-hosted, agent-readable personal memory system: Postgres + pgvector behind an MCP server, owned end to end, queryable by any AI tool from any device. It is built so the schema itself reads as the portfolio piece.

The problem. Every new AI session started as a stranger. Past reasoning was not queryable, so the same decisions got re-litigated and the cost compounded with every conversation. The alternatives all failed in specific ways. Notion and Obsidian were siloed and not machine-readable. Hosted memory products (Mem, Reflect, ChatGPT memory) were shallow, vendor-locked, and exposed no schema you could hand an interviewer. Built-in AI memory did not survive a switch between tools or devices. And the cross-source patterns that matter most stayed invisible: a ChatGPT chat about upgrading a laptop looked like indecision until you read it next to six YouTube searches on the same topic in the prior two weeks, at which point it was clearly a decision being confirmed, not opened.

The approach. Four data layers, joined at query time rather than by foreign keys: Capture (what did I just notice), Attention (what did I consume, when), Identity (who am I as an operator), and Thinking (how do I reason, and how has that reasoning evolved). The Thinking layer (decision records plus a typed reasoning-edge graph with six relation types) is the differentiator no off-the-shelf product offered. A two-tier privacy model (private / work_safe / public, defaulting to private) is enforced three independent ways and fails closed, so a work device reads a curated slice and never the rest. The foundation is a vendored open-source framework (OB1), with provenance documented down to the upstream commit; everything that makes the system Brian's, the Identity and Thinking layers, the privacy tiers, and the cross-layer correlation, is original work on top.

Results.

  • v0 designed, deployed, and backfilled in two days (2026-04-27 to 2026-04-28), corroborated by 25 commits across those dates.
  • Backfilled three years of real history: 474 ChatGPT conversations, 71 Claude conversations, roughly 70K attention signals, 130+ reasoning records, and roughly 118 lessons. Total extraction cost about $0.40.
  • Live MCP endpoint (brain.bfurg.com/mcp, a Vercel proxy in front of a Supabase Edge Function) reachable from Claude Code, Claude Desktop, claude.ai web, ChatGPT, Cursor, and Telegram, with OAuth 2.1 and Dynamic Client Registration for the claude.ai connector.
  • Public dashboard (dashboard.bfurg.com) that reads straight from the live database, so the demo is the system.
  • 16 tier-aware MCP tools across an 8-table typed schema.

What it demonstrates. Systems and architecture judgment (a flat, composable, FK-free schema; deferring the reasoning graph until the corpus made it earn its keep). Privacy engineering (a real threat model answered with three fail-closed enforcement layers, including a view that closes a non-obvious leak through relationship edges). Product thinking (failure modes named before features; sharp positioning against Obsidian and the hosted-memory incumbents). And shipping speed with substance: two days to a deployed, OAuth-reachable, multi-client endpoint backfilled with three years of real data, for under a dollar.