The database under the chat: a local SQLite file a model asks for rows, not notes to re-read.
The database under the chat. A local, file-based database that you and an AI model fill together, where every table has real types and real checks, so what you worked out stays true. Free software, AGPL-3.0. Desktop only, no server, no account. getemerald.dev
.emd, a real SQLite database on your disk, stored as SQLite bytes or
as text and chosen per file. sqlite3 opens it, the schema is documented, and ordinary tools
read every table, including the ones you declared.CHECK for every rule you state, not a template. A value that
does not fit is refused when it is written, not found later.Three ways in, all available today:
The desktop app, for Windows and macOS, from the
latest release.
.emd documents get their own icon and open on a double-click. It is not code-signed: Windows
shows "Windows protected your PC" (click More info, then Run anyway; the installer is
per-user and asks for no administrator password), and macOS says Apple could not verify it (click
Done, then System Settings → Privacy & Security, Open Anyway). A Mac copy of 0.1.2
or earlier says "Emerald is damaged" instead and has no Open Anyway: run
xattr -cr /Applications/Emerald.app once in Terminal, or download the new one. Every release is built by this repository's
release workflow from a tag and attested, with a SHA256SUMS
file beside it: gh attestation verify <file> --repo kfireliyahu/emerald-emd asks GitHub whether
the file is one the workflow built. The installers' names carry no version (Emerald-Setup.exe,
Emerald-arm64.dmg, Emerald-x64.dmg), so releases/latest/download/<name> is always the newest.
Updates are off by default: turn them on in About and the app asks GitHub once a day whether
a newer version is out. On Windows it then downloads it in the background, checks it against the
checksum the release published, and says ready quietly at the top of the window; it installs
only when you press Install and restart, and opens again on the document you had open. On a
Mac it says so, and Download opens the release page (the Mac updater needs a signed app).
Updating yourself is automatic from 0.1.2 on; a copy older than that, download the new one
once by hand.
The MCP server, as the npm package emerald-mcp: one line in your assistant's MCP
configuration, for any document; leave off --engine-only for the ledger's tools too:
claude mcp add emerald -- npx -y emerald-mcp --engine-only
The Claude Code plugin, with the server, its views drawn in the conversation, the skill for
declaring a format with a person, and the hooks that bring a project's start_here and inbox
into a session (what it runs):
/plugin marketplace add kfireliyahu/emerald-emd
/plugin install emerald@emerald-emd
Build and run
git clone https://github.com/kfireliyahu/emerald-emd.git
cd emerald-emd
npm ci # npm install works too; this is the reproducible form
npm run dev # the app, in a browser tab
npm run test # the whole suite
npm run build # the app -> dist/, what the desktop shell serves
npm run desktop # build everything and open the desktop window
npm run build:plugin # the MCP server -> dist-plugin/server.mjs
npm run build:demo # Emerald's page and the tours -> dist-demo/
npm run dist:win # the Windows installer -> release/
npm run dist:mac # the macOS disk image -> release/ (needs a Mac)
npm ci prints audit advisories (in the MCP SDK and the router;
tracked). The first run of anything that opens the desktop window downloads Electron's binary
once; that is the one time the build needs the network.The MCP server from this checkout
.mcp.json points at dist-plugin/server.mjs with --engine-only, so a Claude Code session
started in this directory picks it up and asks you to approve it once. From anywhere else:
claude mcp add emerald -- node /absolute/path/to/dist-plugin/server.mjs --engine-only
Leave --engine-only off for the ledger's tools as well. The built folder is self-contained —
every package is bundled into it, and it is the npm package as it stands — so it runs from anywhere
Node does. docs/plugin.md has the tool surface, the hosts tried, and the rules.
Where things are
docs/: the specification, architecture, data model, the engine, a note
per area. docs/09-decision-log.md records why things are the way
they are, and docs/memory.emd holds where the build is, as rows.docs/demo.md: the page, the tours, and how another page embeds one.src/domain/ is the engine and imports nothing from React, SQLite or the DOM; src/data/ is
storage; src/ui/ the app; src/plugin/ the MCP server; electron/ the desktop shell;
src/data/packs/ the two packs.Issues and contributions
Emerald collects nothing. The policy, in full, is PRIVACY.md.
The code is AGPL-3.0-only (LICENSE); the notes and essays CC BY 4.0; format declarations, packs and synthetic fixtures CC0. LICENSING.md says which is which, what the name and mark are not, and how to get a commercial licence. The desktop app says the same in its About, with the third-party notices of everything it bundles a click away in Help.
Source-derived launch command. Check the maintainer’s required arguments and credentials before running:
npx -y emerald-mcpMerge this template into ~/Library/Application Support/Claude/claude_desktop_config.json. Keep existing servers. Add any arguments, credentials, and permissions required by the maintainer; this template has not been install-tested.
{
"mcpServers": {
"io-github-kfireliyahu-emerald": {
"command": "npx",
"args": [
"-y",
"emerald-mcp"
]
}
}
}Restart Claude Desktop completely for changes to take effect. Confirm the server appears connected in the client’s tool list, then try a read-only example from its documentation.
Claude Desktop setup referenceEmerald works with any MCP-compatible client. Copy the config snippet from the Configuration section above and add it to the file shown for your client, then restart the application.
~/Library/Application Support/Claude/claude_desktop_config.jsonRestart Claude Desktop completely for changes to take effect.~/.cursor/mcp.jsonRestart Cursor for changes to take effect..vscode/mcp.jsonReload VS Code window for changes to take effect.~/.codeium/windsurf/mcp_config.jsonRestart Windsurf for changes to take effect..mcp.jsonSave at the project root, then start Claude Code in that project and review the MCP server approval prompt. Keep real credentials out of shared files.