Skip to main content
MCP server CX Codex

Nacre — Claude Code MCP server: what it does, how to install

Nacre is an MCP server for Claude Code with a self-hosted knowledge index and granular access control. Agents see only documents the requesting user may read.

Apache-2.0 ★ 2 updated 2026-10-10

Install into Claude Code · Platform CLI All methods and platforms ↓
claude mcp add nacre -e NACRE_SERVICE_KEY=<NACRE_SERVICE_KEY> -- npx -y @nacre.work/mcp
Open on GitHub

What Nacre does

Nacre is a permission-aware context layer. Organizations hold workspaces, workspaces hold layers, layers hold documents. Rights (read, write, admin) cascade top-down; write does not grant read automatically. Access filters run during HNSW traversal: top_k yields k permitted results, not k minus whatever got stripped afterward.

Hybrid retrieval combines dense vectors, BM25, and optional cross-encoder reranking. The parser extracts text from PDF, Office, OpenDocument, EPUB and RTF. Embeddings go through any OpenAI-compatible endpoint bound to a layer. Switching a layer to a different model triggers reindexing with recall validation: if the new model loses relevance on your reference query set, the migration halts instead of going live.

Runs via docker compose --profile minimal up -d. The CLI client npx @nacre.work/cli authenticates, provisions a layer, ingests a directory, and searches. On Apple Silicon read docs/apple-silicon.md before starting: images are arm64, but the embedder runs on the host.

What it helps with

  • Give an agent access to a company index without exposing documents the user lacks clearance for
  • Ensure search returns exactly k permitted results rather than filtering after ranking
  • Match literal identifiers (error codes, invoice numbers, variable names) where dense vectors fail
  • Migrate a layer to a different embedding model and stop the switch if recall drops
  • Parse PDF, DOCX, PPTX, EPUB or RTF and index the extracted text

Example prompts for the agent

  • Search our index for mentions of SQLSTATE 23505
  • Show authentication architecture docs the current user can read
  • Ingest files from docs/ into the engineering-kb layer

How to install Nacre

Platform CLI

claude mcp add nacre -e NACRE_SERVICE_KEY=<NACRE_SERVICE_KEY> -- npx -y @nacre.work/mcp

Replace <…> with your own values

Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more

Questions about Nacre

How to install Nacre in Claude Code?

Run claude mcp add nacre -e NACRE_SERVICE_KEY=<NACRE_SERVICE_KEY> -- npx -y @nacre.work/mcp, substituting your service account key.

What does Nacre do?

Nacre is a self-hosted knowledge index with layer-level and document-level access control. An agent querying the index sees only results the requesting user has clearance for. Filtering is embedded in HNSW graph traversal.

Why validate recall when changing the embedding model?

Before switching a layer to a new embedding model, Nacre scores your reference query set against it. If recall drops, the migration stops and the old model stays live. This prevents search quality degradation.

Similar MCP servers

All MCP servers for Agent setup: memory, context, orchestration →

Project sponsors

Companies that keep this analytics open