> Illustrative sample produced with the Cheek Build a Second Brain skill. Mastercard is not affiliated with and has not endorsed this material. The folder contents, counts, and search examples are plausible sample values, not a real executive's files.

# Second Brain Guide

This folder is now a second brain: your files, made permanently queryable, entirely on this machine. This guide records what was indexed, how the pieces fit, and how to use it. Keep it in the folder; it is part of the brain.

## What was indexed

The folder held 214 files across four areas when the brain was built. Coverage, stated honestly:

| Content | Files | Status |
|---|---|---|
| Board materials (decks exported to PDF, pre-reads in docx) | 38 | Extracted. All PDFs carried a text layer. |
| Strategy memos and drafts (docx, md) | 52 | Extracted. |
| Meeting notes (md, txt, some with wikilinks between them) | 96 | Extracted. Links between notes became graph edges. |
| Payments research (PDFs, html clippings, two csv datasets) | 24 | 21 extracted. 3 skipped, listed below. |
| Photos of whiteboards (jpg) | 4 | Indexed by name only. Images carry no extractable text. |

Skipped, with reasons: `research/tokenization-panel-scan.pdf` and `research/interchange-hearing-scan.pdf` are scanned images with no text layer, and `research/network-economics.key` is a Keynote binary. All three sit in the graph by name so they are not forgotten, but their contents are not searchable. Re-export them as text-bearing PDF or docx and the watcher will pick them up.

Totals after the build: 211 files with searchable text, 4,182 chunks, 4,182 vectors in the database, 289 nodes and 1,247 edges in the graph, of which 312 are similarity edges.

## The architecture in five sentences

Every readable file is reduced to plain text and split into chunks of about 1,200 characters, because a paragraph is about one thing and a 40 page deck is about many. Each chunk is embedded into a vector by a small model that runs on this machine, so meaning can be compared without any API key and without any file leaving the folder. The vectors live in an embedded Postgres database with pgvector inside `brain/db/`, with a read replica at `brain/db/search-index.json` that the search server reads. The knowledge graph at `brain/graph/graph.json` connects files three ways: folder structure, explicit links between notes, and semantic similarity between files that never mention each other. A local MCP server exposes the whole thing to any Claude session as three tools: semantic_search, read_note, and recent_changes.

## How to query it from any Claude session

The MCP server is registered under the name `second-brain`. If it ever needs re-registering, the command shape is:

    claude mcp add second-brain -- node /path/to/your-folder/brain/mcp/server.mjs

Then, in any Claude session, just ask in plain language. Claude will call `semantic_search` with your question, get back the best matching files with snippets and scores, and can pull any full document with `read_note`. Matching is by meaning, not keywords: a search for "customer pushback on pricing" finds the note that says "issuers balked at the new assessment fee structure."

To see what has moved lately, ask "what changed in my second brain this week." That calls `recent_changes`, which reads the pipeline's run log.

## The watcher

The watcher process (`brain/pipeline/watch.mjs`) observes the folder, waits three seconds after the last change, then re-runs the incremental pipeline: extract, embed, graph. Drop a file in and it becomes searchable in under a minute; delete one and it is forgotten, vectors and all. It is installed as a background job through launchd, so it survives restarts. Only changed files cost anything: an unchanged folder refreshes in about two seconds.

## Rebuilding from scratch

If the brain ever needs a clean rebuild: delete `brain/db/` and `brain/graph/graph.json`, then run `node brain/pipeline/refresh.mjs` from the folder. The model cache re-downloads once if you also deleted `brain/db/models`. Nothing outside `brain/` is ever touched.

## Four ways to use this brain, grounded in what is in it

1. **The board commitment ledger.** Before you draft the next quarterly deck, ask: "what did I commit to the board on agentic checkout in the last two quarters." The brain reads the decks and pre-reads you already wrote and answers with sources.
2. **The pre-meeting sweep.** Before a leadership meeting on interchange strategy, ask what you said the last three times the topic appeared in your meeting notes. Consistency is a superpower nobody prepares for.
3. **The research cross-pollinator.** The graph already draws similarity edges between your tokenization research and two strategy memos that never cite it. Ask "what connects my saved research to the value-added services memo" and follow the edges.
4. **The relationship memory.** Your meeting notes carry names. Before you see a regulator, issuer, or board member again, ask the brain for every context you share with that person.

IMPORTANT: download this file and upload it to your Claude project, or keep it in this working folder if you are in Claude Code, so future sessions can find it and query the brain with full context.
