# clude

Adds structured long-term memory with differential decay and semantic recall to AI coding agents. Useful for retaining project context across multiple sessions.

- MCP server · `type=mcp` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, Gemini CLI · ★ 22
- Author: sebbsssss
- License: MIT · policy=link-only · description only; the file stays with the author
- Source: https://github.com/sebbsssss/clude
- Updated: 2026-10-04
- HTML: https://affpapa.org/en/nevibecode/mcp/clude

## What it does

Clude supplies agents with cognitive memory instead of plain storage logs. Records belong to explicit categories — episodic, semantic, procedural, or self-model. Each category decays at an independent daily rate between 1% and 7%, while repeated retrievals strengthen the internal graph edges.

Agents connect through 8 MCP tools. These include single and batch writes up to 50 memories via `batch_store_memories`, hybrid search with `recall_memories`, and non-obvious association queries through `find_clinamen`. The engine can run offline using SQLite and local embeddings, or through the hosted platform with a `CORTEX_API_KEY`.

Direct connectors for frameworks like LangGraph or CrewAI do not exist yet. You must write custom wrappers around storage and recall methods to hook it into external orchestrators.

## Requirements
- Needs: Node.js (commands run via npx)
- Environment variables: `CORTEX_API_KEY`, `CORTEX_HOST_URL`, `CLUDE_WALLET`, `CLUDE_AGENT_NAME` — keys and tokens: ask the human for the values, never commit them or put them in shared files.

## Install

### Claude Code (native platform)

**Platform CLI**
```bash
claude mcp add --env CORTEX_API_KEY=<CORTEX_API_KEY> --env CORTEX_HOST_URL=<CORTEX_HOST_URL> --env CLUDE_WALLET=<CLUDE_WALLET> --env CLUDE_AGENT_NAME=<CLUDE_AGENT_NAME> --transport stdio clude -- npx -y @clude/sdk
```
Replace <…> with your own values

### Codex

**Platform CLI**
```bash
codex mcp add clude --env CORTEX_API_KEY=<CORTEX_API_KEY> --env CORTEX_HOST_URL=<CORTEX_HOST_URL> --env CLUDE_WALLET=<CLUDE_WALLET> --env CLUDE_AGENT_NAME=<CLUDE_AGENT_NAME> -- npx -y @clude/sdk
```
Replace <…> with your own values

### Cursor

**Config file**
File `.cursor/mcp.json`:
```json
{
    "mcpServers": {
        "clude": {
            "command": "npx",
            "args": [
                "-y",
                "@clude/sdk"
            ],
            "env": {
                "CORTEX_API_KEY": "<CORTEX_API_KEY>",
                "CORTEX_HOST_URL": "<CORTEX_HOST_URL>",
                "CLUDE_WALLET": "<CLUDE_WALLET>",
                "CLUDE_AGENT_NAME": "<CLUDE_AGENT_NAME>"
            }
        }
    }
}
```
Replace <…> with your own values

### GitHub Copilot

**Config file**
File `.vscode/mcp.json`:
```json
{
    "servers": {
        "clude": {
            "type": "stdio",
            "command": "npx",
            "args": [
                "-y",
                "@clude/sdk"
            ],
            "env": {
                "CORTEX_API_KEY": "<CORTEX_API_KEY>",
                "CORTEX_HOST_URL": "<CORTEX_HOST_URL>",
                "CLUDE_WALLET": "<CLUDE_WALLET>",
                "CLUDE_AGENT_NAME": "<CLUDE_AGENT_NAME>"
            }
        }
    }
}
```
Replace <…> with your own values

### Gemini CLI

**Platform CLI**
```bash
gemini mcp add -e CORTEX_API_KEY=<CORTEX_API_KEY> -e CORTEX_HOST_URL=<CORTEX_HOST_URL> -e CLUDE_WALLET=<CLUDE_WALLET> -e CLUDE_AGENT_NAME=<CLUDE_AGENT_NAME> clude npx -y @clude/sdk
```
Replace <…> with your own values

## When to use it
- retain architectural decisions and user context across separate CLI sessions
- retrieve relevant memories using combined vector, tag, and keyword matching
- deprecate outdated episodic details automatically via time-based decay rates
- export gathered context into JSON or Markdown files to share across models

## Example prompts
- Store our decision to use Prisma migrations in procedural memory
- Recall past context regarding API rate limiting and token thresholds
- Check get_memory_stats to see the current distribution of memory types

## Similar
- [REA](https://affpapa.org/en/nevibecode/mcp/rea.md) — MCP server · ★ 386989
- [GitHub](https://affpapa.org/en/nevibecode/mcp/github.md) — MCP server · ★ 33918
- [Netdata](https://affpapa.org/en/nevibecode/mcp/netdata.md) — MCP server · ★ 81115
- [browser-use](https://affpapa.org/en/nevibecode/mcp/browser-use.md) — MCP server · ★ 119160
- [Codebase Memory](https://affpapa.org/en/nevibecode/mcp/codebase-memory.md) — MCP server · ★ 47392
- [mcp-server](https://affpapa.org/en/nevibecode/mcp/mcp-server.md) — MCP server · ★ 43872

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
