npm @remem-ai/rememstdioMITupdated 7d ago
Stop re-explaining your project every new coding-agent session.
What can you do with remem?
remem: Local-first memory for Claude Code and OpenAI Codex
Stop re-explaining your project every new coding-agent session.
Language: English | įŽäŊ䏿
remem automatically captures, distills, searches, and injects engineering
memory across Claude Code and OpenAI Codex CLI sessions. Decisions,
bug-fix rationale, project patterns, and preferences stay available through
hooks, MCP, CLI, and a localhost REST API.

A new Claude Code session recalls the earlier root cause, commit, and open TODO with memory citations and no re-explaining.
What remem gives you
- Automatic session capture and background LLM distillation.
- Project-scoped recall across Claude Code and Codex using one local store.
- Searchable decisions, bug fixes, architecture notes, preferences, and raw session evidence.
- Source attribution, staleness labels, suppression, review queues, and injection audits.
- SQLite with SQLCipher encryption by default for fresh installs.
- MCP, CLI, and authenticated localhost REST access from one Rust runtime.
remem prioritizes memory quality. Automatic capture is the primary path;
manual save_memory calls supplement it when a decision needs to be recorded
immediately.
Install in five minutes
Homebrew
brew install majiayu000/tap/remem
"$(brew --prefix remem)/bin/remem" install --target codex
Use --target claude for Claude Code. --target all configures every known
host, including Cursor where its v1 renderer is supported.
Standalone installer
curl -fsSL https://raw.githubusercontent.com/majiayu000/remem/main/install.sh | env REMEM_NO_CONFIG=1 sh
~/.local/bin/remem install --target codex
npm or Cargo
npm install -g @remem-ai/remem
# or
cargo install remem-ai --bin remem
remem install --target codex
GitHub Releases: prebuilt binaries for macOS and Linux on x64/arm64, with
published checksums. Use one canonical remem executable on PATH;
remem doctor warns when hooks and terminals resolve different copies.
For channel-specific upgrades, platform boundaries, PATH drift, and manual install notes, read the installation and upgrade guide. The broader documentation guide links plugin and operational material.
Verify the installation
Restart the selected coding agent, then run:
remem doctor
remem status
remem search "last decision"
A healthy Claude Code or Codex installation injects relevant project memory at
SessionStart and queues durable session distillation at Stop. remem doctor
checks the schema, encryption key, database, hooks, MCP registration, worker,
and common install-path drift.
Repository contributors can verify duplicate SessionStart suppression with the isolated executable smoke fixture.
For a focused, read-only view of current-memory truth:
remem doctor truth --cwd .
Host support
| Capability | Claude Code | Codex CLI | Cursor v1 |
|---|---|---|---|
| MCP memory tools | Yes | Yes | Yes on macOS/Linux |
| SessionStart injection | Yes | Yes | Not supported |
| Automatic session memory | Yes | Yes, Stop-based and low-noise | Not enabled by the v1 installer |
| Tool-event capture | Installed hooks | No high-frequency Bash hook by default | Runtime command exists; no installed hook |
| Compiled command-rule enforcement | Optional warn/block on Bash | Not supported | Not supported |
| Windows | Supported | Supported | Not supported |
Cursor's v1 installer registers MCP only. The verified observe and
summarize runtime commands exist, but remem install --target cursor does
not install automatic capture hooks or SessionStart injection.
The repository also includes a Codex plugin wrapper. See plugins/remem/README.md for local plugin runtime and explicit hook activation instructions.
Why use remem alongside built-in memory
Built-in MEMORY.md, CLAUDE.md, and agent instruction files are ideal for a
small set of stable facts that should always be visible. remem covers the
engineering history that is too large, dynamic, or evidence-heavy to maintain
by hand.
| Need | Built-in files | remem |
|---|---|---|
| Stable project rules | Excellent | Supported |
| Automatic session capture | Manual upkeep | Hook-driven |
| Search older rationale | Limited by loaded text | Curated and raw search |
| Branch, time, and staleness handling | Manual | Built in |
| Provenance and injection audit | Git history | Database-backed audit |
| Review, suppression, and lifecycle governance | Manual edits | First-class commands |
Use both. Keep concise rules in native files and let remem retain the long tail of decisions, failures, evidence, and changing project state.
The broader ecosystem comparison lives in the dated memory-tool survey.
How it works
Claude Code / Codex hooks
|
v
append-only captured_events ledger
|
v
coalesced background extraction and session rollup
|
v
governed candidates -> curated memories + workstreams + raw archive
|
v
FTS, entity, temporal, vector, graph, and optional local rerank retrieval
|
v
budgeted, source-attributed SessionStart context
Hooks return quickly after durable capture or queueing. Background workers
perform extraction, candidate governance, compression, retrieval enrichment,
and lifecycle cleanup. MCP, CLI, REST, and SessionStart share the same local
store and governance model, but apply surface-specific eligibility policies.
Explicit search is an inspection and recovery surface, so it may return
labeled legacy_unverified memories; default SessionStart and CurrentTruth
exclude those rows and record the reason.
Generated memory is treated as untrusted until it passes source-support, secret, instruction-pattern, scope, and lifecycle checks. Unsafe content is dropped or routed to review with a diagnosable reason.
For module ownership and current data flow, read docs/ARCHITECTURE.md.
The experimental MCP context_bundle tool exposes the versioned, budgeted
compiler to explicit callers. The experimental remem context-plan command
prints a request-specific retrieval plan. These opt-in interfaces are tracked
by the Context Bundle and
retrieval-router contracts.
Everyday workflows
Recall and inspect
remem search "database encryption"
remem search "deployment decision" --branch main --explain
remem show <memory-id>
remem why <memory-id>
remem current <state-key>
Agents can use MCP search for compact results, then get_observations for
selected details. Use raw recall only when curated memory misses exact
transcript evidence:
remem raw search "exact phrase" --since 2026-06-01 --json
List complete host-bound sessions before reading an exact transcript:
remem raw sessions --latest 20 --json
remem raw messages --host codex-cli --source-root local \
--project "/path/to/project" --session-id SESSION_ID --json
remem ingest-sessions --root codex-cli:archive=/path/to/sessions --json
Copy host, source_root, project, and session_id unchanged from one
raw sessions summary into raw messages. Existing scripts must add the
required --host selector and replace --root LABEL=PATH with
--root HOST:LABEL=PATH; the same root format applies to raw reconcile.
The JSON envelope reports excluded_legacy_rows and
excluded_legacy_sessions when pre-identity transcript rows are retained in
the raw archive but cannot safely enter the host-bound session contract.
HOST is claude-code or codex-cli, and LABEL becomes the persisted
source_root. Cursor snapshot evidence requires a manually configured and
verified remem summarize --host cursor Stop integration; filesystem --root
ingestion and reconciliation reject cursor explicitly.
Review and govern
remem review list
remem review approve <candidate-id>
remem memory suppress memory:<id> --reason "no longer relevant"
remem govern --action stale --dry-run --json <id>
Mutating governance commands expose previews, explicit confirmations, or
review boundaries according to their risk. Run remem <command> --help for
the current contract instead of relying on a copied command inventory.
Configure memory AI and retrieval
remem config show
remem model current
remem model use balanced --dry-run
remem embedding status
remem embedding download --model multilingual-e5-small
remem embedding backfill --limit 1000
auto embedding mode stays local unless a remem-specific API key is selected.
The verified local model is optional; the labeled feature-hash fallback remains
available. The second-stage local reranker is also optional and disabled until
configured.
Use the current configuration routes, the
local embedding contract, and
remem config, remem embedding, or remem reranker help for details.
Share or edit memory outside the database
remem sync-memory --cwd .
remem export --markdown --output ./remem-memory
remem export --pack .remem-pack
Markdown mirrors are human-editable. Project memory packs are deterministic, git-committable exports with provenance-aware import and quarantine behavior. See the memory usage guide and project memory pack contract.
Evidence and benchmarks
The checked-in public suite separates memory-system capability evidence from coding-agent outcome evidence. Verify it locally with:
cargo run -- bench verify --root eval/public --json-out /tmp/remem-bench-verify.json
The current public report is deliberately labeled
directional_only_no_public_claim. The historical isolated coding baseline is
useful engineering evidence, but its preloaded-memory condition is not
comparable with the current SessionStart retrieval path.
Reproduction commands, artifact schemas, claim boundaries, and current gates live in:
README claims intentionally exclude unsealed local metrics that have no checked-in report.
Security and privacy
- Fresh installs create a SQLCipher-encrypted database and private key file.
- The data directory and key use restrictive per-user permissions.
- The REST API binds to
127.0.0.1and requires a bearer token. - Hook-captured event previews are redacted before durable storage.
- Memory candidates and injected content pass secret and poisoning defenses.
remem doctorreports encryption, plaintext residue, schema, and audit failures without printing memory payloads.
Read SECURITY.md for reporting and security policy. Operational contracts for SQLite tuning and memory-poisoning defense are kept outside the landing page.
REST API
remem api --port 5567
TOKEN=$(cat ~/.remem/.api-token)
curl -H "Authorization: Bearer $TOKEN" http://127.0.0.1:5567/api/v1/health
curl -H "Authorization: Bearer $TOKEN" http://127.0.0.1:5567/api/v1/capabilities
Clients should feature-detect through /api/v1/capabilities. The current
endpoint and compatibility contract is maintained in
docs/specs/SPEC-web-api.md.
Documentation
Use docs/README.md as the jump page for installation, configuration, memory lifecycle, retrieval, governance, API, plugin, operations, architecture, and benchmark material.
The most common destinations are:
- Architecture and data flow
- Memory usage guide
- Memory lifecycle
- Codex plugin
- REST API contract
- Current spec index
- Changelog
- Contributing
Uninstall
Preview and remove host hooks and MCP registration without deleting memory:
remem uninstall --dry-run
remem uninstall
The encrypted database remains in the configured REMEM_DATA_DIR. Back it up
before manually deleting that directory if data removal is intended. Ordinary
file deletion removes remem's local data but does not guarantee secure erasure
from filesystem snapshots, backups, or the underlying storage media.
License
MIT
Install
Add remem to your client. Pick the one you use.
claude mcp add remem -- npx -y @remem-ai/rememcodex mcp add remem -- npx -y @remem-ai/rememamp mcp add remem -- npx -y @remem-ai/remem{
"mcpServers": {
"remem": {
"command": "npx",
"args": [
"-y",
"@remem-ai/remem"
]
}
}
}Add to `claude_desktop_config.json`, then restart Claude Desktop.
{
"mcpServers": {
"remem": {
"command": "npx",
"args": [
"-y",
"@remem-ai/remem"
]
}
}
}Add to `~/.cursor/mcp.json`, or `.cursor/mcp.json` for a single project.
code --add-mcp '{"name":"remem","command":"npx","args":["-y","@remem-ai/remem"]}'Or add the block manually to `.vscode/mcp.json` under `servers`.
{
"mcpServers": {
"remem": {
"command": "npx",
"args": [
"-y",
"@remem-ai/remem"
]
}
}
}Add to `~/.codeium/windsurf/mcp_config.json`.
{
"mcpServers": {
"remem": {
"command": "npx",
"args": [
"-y",
"@remem-ai/remem"
]
}
}
}Add to `cline_mcp_settings.json` via the MCP Servers panel.
{
"mcpServers": {
"remem": {
"command": "npx",
"args": [
"-y",
"@remem-ai/remem"
]
}
}
}Add to `~/.gemini/settings.json`.
{
"mcpServers": {
"remem": {
"type": "local",
"command": "npx",
"args": [
"-y",
"@remem-ai/remem"
],
"tools": [
"*"
]
}
}
}Add to `~/.copilot/mcp-config.json`, or run `/mcp add` inside the CLI.
{
"context_servers": {
"remem": {
"command": {
"path": "npx",
"args": [
"-y",
"@remem-ai/remem"
]
}
}
}
}Add to your Zed `settings.json`.
npx -y @remem-ai/rememRun `goose configure`, choose **Add Extension â Command-line Extension**, and paste this command.
Score
39 / 100
Incomplete
- Documentation25/25
- Maintenance25/25
- Trust13/20
- Capability0/15
- Install experience12/15
- Documents what it does and how to connect
- Has a resolvable package or endpoint
- Exposes at least one tool, prompt or resource
- README has substantive content
- Includes a code example
- Documents its configuration
- Mentions credentials or security posture
- Last commit 0 days ago
- Has a release history
- Repository is not archived
- Licensed MIT
- Namespace verified in the official MCP registry
- Claimed by its owner
- Published under an organisation
- 0 tool(s) documented
- Provides prompt templates
- Provides resources
- 12 documented install method(s)
- Published to a package registry
- Offers a hosted endpoint â no local install
Version history
| Versions | Published |
|---|---|
| 0.6.59 | Aug 7, 2026 |
| 0.6.58 | Aug 7, 2026 |
| 0.6.57 | Aug 7, 2026 |
| 0.6.56 | Aug 7, 2026 |
| 0.6.55 | Aug 7, 2026 |
| 0.6.54 | Aug 7, 2026 |
| 0.6.51 | Aug 6, 2026 |
| 0.6.50 | Aug 6, 2026 |
| 0.6.49 | Aug 5, 2026 |
| 0.6.48 | Aug 5, 2026 |
| 0.6.47 | Aug 3, 2026 |
| 0.6.45 | Aug 2, 2026 |
| 0.6.44 | Aug 1, 2026 |
| 0.6.43 | Aug 1, 2026 |
| 0.6.42 | Jul 31, 2026 |
| 0.6.41 | Jul 31, 2026 |
| 0.6.40 | Jul 31, 2026 |
| 0.6.39 | Jul 31, 2026 |
| 0.6.38 | Jul 31, 2026 |
| 0.6.37 | Jul 31, 2026 |
| 0.6.36 | Jul 31, 2026 |
| 0.6.35 | Jul 30, 2026 |
| 0.6.34 | Jul 30, 2026 |
| 0.6.33 | Jul 30, 2026 |
| 0.6.32 | Jul 30, 2026 |
| 0.6.31 | Jul 30, 2026 |
| 0.6.30 | Jul 30, 2026 |
| 0.6.27 | Jul 26, 2026 |
| 0.6.26 | Jul 26, 2026 |
| 0.6.25 | Jul 25, 2026 |
| 0.6.24 | Jul 24, 2026 |
| 0.6.23 | Jul 24, 2026 |
| 0.6.22 | Jul 24, 2026 |
| 0.6.21 | Jul 24, 2026 |
| 0.6.19 | Jul 24, 2026 |
| 0.6.16 | Jul 24, 2026 |
| 0.6.15 | Jul 22, 2026 |
| 0.6.14 | Jul 20, 2026 |
| 0.6.13 | Jul 20, 2026 |
| 0.6.12 | Jul 20, 2026 |
| 0.6.11 | Jul 19, 2026 |
| 0.6.10 | Jul 19, 2026 |
| 0.6.5 | Jul 18, 2026 |
| 0.6.4 | Jul 17, 2026 |
| 0.6.3 | Jul 17, 2026 |
| 0.6.2 | Jul 17, 2026 |
| 0.6.1 | Jul 17, 2026 |
| 0.5.214 | Jul 16, 2026 |
| 0.5.213 | Jul 16, 2026 |
| 0.5.212 | Jul 16, 2026 |
| 0.5.211 | Jul 16, 2026 |
| 0.5.210 | Jul 16, 2026 |
| 0.5.209 | Jul 15, 2026 |
| 0.5.208 | Jul 15, 2026 |
| 0.5.207 | Jul 15, 2026 |
| 0.5.206 | Jul 15, 2026 |
| 0.5.205 | Jul 15, 2026 |
| 0.5.204 | Jul 15, 2026 |
| 0.5.203 | Jul 12, 2026 |
| 0.5.202 | Jul 12, 2026 |