๐ ๐๐๐ฉ๐ ๐๐๐๐จ๐๐ ๐ ๐ ๐๐ ๐ข๐ฅ๐ฌ ๐ข๐ ๐๐ฉ๐๐ฅ๐ฌ๐ง๐๐๐ก๐ ๐ ๐๐ฅ๐ข๐ช๐ฆ๐
Claude reads my files and my screen. It did not know what I read in my browser yesterday.
I built BraveMCP to fix this. It is a local-first second brain. It gives Claude Desktop access to your history, bookmarks, and notes using the Model Context Protocol (MCP).
Everything stays on your machine. There is no cloud and no tracking.
The Architecture
MCP servers talk to Claude Desktop over a JSON-RPC stream. A browser extension lives in a sandbox. It cannot use that stream. It can only make HTTP requests.
I solved this with an HTTP bridge. An Express server runs on port 3747 inside the MCP server process. The extension sends data to the server. The MCP server reads that data from a shared database when Claude asks for it.
The Search System
I use two search methods to ensure accuracy:
- SQLite with FTS5 for fast keyword ranking.
- ChromaDB for semantic search.
If you search for "MCP security," semantic search finds "Claude agent hardening." If ChromaDB is down, the system still works using only keywords.
How it handles data
When you visit a page, BraveMCP creates a summary and an embedding. It uses Ollama for local processing. If Ollama is not running, it uses the Anthropic API.
I learned a hard lesson with fallbacks. In the first version, the tool gave generic answers if the AI was offline. Now, the system extracts real data from SQLite. It groups pages by domain and shows real snippets. The tool stays useful even without an LLM.
The most useful tool is find_forgotten_content. It uses hybrid search and ranks results by time and how often you visit a page. A page you visited three times last week ranks higher than a page you saw once today.
Lessons Learned
- One line of code broke everything. dotenv v17 prints a status line to stdout. This corrupted the JSON-RPC channel. I had to pin dotenv to version 16 to fix it.
- Dual-process issues are real. Claude Desktop and my dev client each start their own MCP server. Only one gets the extension data if you use in-memory storage. I fixed this by using SQLite as the single source of truth for both processes.
The Stack
- A Manifest V3 extension.
- An MCP server with 13 tools.
- SQLite and ChromaDB hybrid search.
- A Node.js test suite.
The project is open source under the MIT license.
Optional learning community: https://t.me/GyaanSetuAi