Esment logoEsmentBlog
← All posts
Local-first is a feature, not a constraint
The Esment Team2 min read

Local-first is a feature, not a constraint

Running memory on your own machine is not a limitation we accepted — it is the design that makes the product honest. Here is the architecture that makes it fast, private and portable.

There is a moment in every memory-product pitch where someone asks: "but why not just put it in the cloud?" It is a fair question. The cloud is easier to build, easier to sync, easier to sell. We chose local-first anyway, and the reasons are not philosophical — they are practical.

The privacy asymmetry

A memory store is the one dataset where the user's interests and the company's incentives are structurally misaligned. The user wants the assistant to know them; the company wants to know the user. Every cloud memory product has to be evaluated under that tension. A local store dissolves it: the data never leaves the machine, so there is nothing to misuse, nothing to subpoena, nothing to leak.

The architecture

The Esment engine is a single Rust binary that runs a SQLite-backed store with:

  • a temporal knowledge graph — entities, relations, and the memories that ground them;
  • a four-stage retrieval cascade — FTS/BM25, HNSW vectors, graph BFS, and MMR reranking;
  • a commit DAG — every mutation is a content-addressed, auditable commit;
  • an MCP server — any assistant that speaks the Model Context Protocol can connect over stdio or HTTP.

All of it runs on the user's machine, answering in milliseconds. The vector index is built locally; the LLM calls are the only thing that ever touches a network, and only when the user configures a provider.

The sync question

Local-first does not mean isolated. Esment syncs bidirectionally with the hosted cloud when the user asks for it: additive in both directions, conflict-safe, and with embeddings recomputed on each side. The cloud becomes a mirror of your memory, never the owner of it.

Why this wins

  • Speed. No round-trip to a server for every recall; the cascade runs on-device in tens of milliseconds.
  • Portability. The store is a file. Back it up, copy it, move it. It is yours in a way a database row can never be.
  • Honesty. "Your memory stays on your machine" is a claim you can verify with ls. The enterprise edition ships fully local: no OpenAI, no Ollama, no network — a memory engine that runs on an air-gapped machine.

Local-first is often described as a constraint we accepted. It is not. It is the feature that makes the whole product trustworthy enough to use.

Tags

local-firstarchitectureprivacy

Esment builds persistent, inspectable memory for AI assistants — local-first, deterministic, and yours. Learn more →