# kunickiaj/codemem [Health: Active]

**Category:** 🧠 Knowledge & Memory  
**Repository:** https://github.com/kunickiaj/codemem  
**GitHub Stars:** 84  
**npm Downloads (last month):** 5937  
**Views:** 3  
**Installs:** 0  
**Upvotes:** 0  
**Directory Page:** https://allmcps.com/mcp/kunickiaj-codemem

## Description
Persistent coding memory across sessions, machines and teammates, with memory search, optional sync, project sharing and automatic capture.

## Claude Desktop Quick Installation
Install path detected from listing signals. Uses `npx` (confidence: high):

```json
"mcpServers": {
  "codemem": {
    "command": "npx",
    "args": ["-y","codemem"]
  }
}
```

## Documentation

## What kunickiaj/codemem MCP server does

kunickiaj/codemem gives coding agents access to persistent project memory. It records decisions, discoveries, failed approaches, fixes, and repository-specific pitfalls so later sessions can recover useful context instead of starting from scratch. The broader codemem system supports OpenCode, Claude Code, Codex, and the Pi coding agent, with multiple agents sharing a project-scoped store.

Memory is local-first: data is kept in SQLite on the developer's machine. Selected project memories can also be synchronized between machines or shared with a teammate or Team. A local viewer at `http://localhost:38888` provides access to stored memories, sessions, and observer output.

## How it works

Captured coding activity is processed by an observer that turns session context into memories. The observer can use an OpenCode account, an API key, or a local Claude/Codex session selected in Settings. Retrieval uses both FTS5 BM25 lexical search and sqlite-vec semantic search, then merges and reranks the results.

For OpenCode, the plugin can inject relevant context into prompts automatically. It avoids repeating unchanged memories already present in the OpenCode context. Claude Code has plugin support, while Codex and Pi participate in the shared project store. Pi also has native memory tools and does not require MCP for its codemem integration. The MCP interface exposes `memory_session_search`.

## Setup and configuration

The documented quick start requires Node.js 24.15 or newer and npm or pnpm. Native database support covers macOS x64 and arm64, Linux x64 and arm64, and Windows x64; Linux requires glibc 2.34+ or musl. On Linux, set `ONNXRUNTIME_NODE_INSTALL=skip` before the first package installation to avoid downloading the unused GPU provider while retaining CPU inference.

For OpenCode, run `npx -y codemem setup --opencode-only`, then restart OpenCode. The setup configures one plugin entry that works with both supported OpenCode host generations. Verification can use `npx -y codemem memory stats` and `npx -y codemem diagnostics capture status`.

Advanced single-user deployments can expose an OAuth-protected Streamable HTTP MCP endpoint to configured remote clients. The local viewer should remain private.

## Tools and capabilities

- Search session memory through the `memory_session_search` MCP tool.
- Capture coding activity and build reusable memories through supported host integrations.
- Inject relevant memory into OpenCode prompts automatically.
- Share one project-scoped store across OpenCode, Claude Code, Codex, and Pi.
- Browse memories, sessions, and observer output in the local web viewer.
- Synchronize selected project memories across machines and share project knowledge with teammates or Teams.

## Limitations and notes

The OpenCode 2 integration is beta. Automatic capture and recall depend on the host integration and available ownership checks. Local storage does not guarantee local-only processing: captured context is sent to the configured observer model, and model calls may incur charges or consume plan usage.

The package does not support 32-bit targets, including Linux armv7. A global CLI installation is optional for setup, but is used for manual commands and semantic retrieval. Remote MCP access is intended for advanced single-user self-hosting and uses OAuth-protected Streamable HTTP rather than an unrestricted public endpoint.

_Full upstream README: https://allmcps.com/mcp/kunickiaj-codemem/readme_

