← Back to Plugins
Tools

Memcontext Plugins

CyberBoyAyush By CyberBoyAyush 👁 18 views ▲ 0 votes

MemContext long-term memory plugins for Claude Code, Codex, Cursor, Gemini CLI, OpenCode, OpenClaw, Hermes, Amp and more, plus a one-command installer

GitHub

Install

npm install
pnpm

Configuration Example

{
  "enabled": true,
  "injectOnStart": true,
  "recallOnPrompt": true,
  "capture": true,
  "startTokens": 900,
  "promptTokens": 450,
  "project": ""
}

README

<p align="center">
  <a href="https://memcontext.in">
    <img src="https://raw.githubusercontent.com/CyberBoyAyush/memcontext-plugins/main/assets/icon.png" width="96" alt="MemContext logo" />
  </a>
</p>

<h1 align="center">MemContext Plugins</h1>

<p align="center">
  <b>One memory for every AI coding agent.</b><br/>
  Claude Code, Codex, Cursor, Gemini CLI, OpenCode, OpenClaw, Hermes, Amp and 20+ more remember your preferences,
  your project's decisions and where you left off — across apps and sessions.
</p>

<p align="center">
  <a href="https://www.npmjs.com/package/memcontext-plugin"><img src="https://img.shields.io/npm/v/memcontext-plugin?color=e8613c&label=memcontext-plugin" alt="npm version" /></a>
  <a href="https://www.npmjs.com/package/opencode-memcontext"><img src="https://img.shields.io/npm/v/opencode-memcontext?color=e8613c&label=opencode-memcontext" alt="opencode-memcontext" /></a>
  <a href="https://www.npmjs.com/package/openclaw-memcontext"><img src="https://img.shields.io/npm/v/openclaw-memcontext?color=e8613c&label=openclaw-memcontext" alt="openclaw-memcontext" /></a>
  <a href="https://github.com/CyberBoyAyush/memcontext-plugins/blob/main/LICENSE"><img src="https://img.shields.io/badge/license-MIT-0b0b0b" alt="MIT license" /></a>
</p>

<p align="center">
  <a href="https://memcontext.in">Website</a> ·
  <a href="https://docs.memcontext.in">Docs</a> ·
  <a href="https://app.memcontext.in">Dashboard</a> ·
  <a href="https://github.com/CyberBoyAyush/memcontext-plugins">GitHub</a>
</p>

---

## Quick start

You need [Node.js](https://nodejs.org) 18 or newer and a free [MemContext account](https://app.memcontext.in).

```bash
npx memcontext-plugin install
```

That's it. The installer:

1. finds every AI app on your machine,
2. lets you pick which ones to set up (all are selected — use ↑/↓ and space to change, enter to install),
3. installs the right MemContext plugin into each one you picked,
4. signs you in once in the browser — every plugin shares that sign-in.

Restart your AI apps and start a new chat. Check everything with:

```bash
npx memcontext-plugin status
```

## What you get

| | |
|---|---|
| 🧠 **Starts with context** | Every new session opens with your preferences, this project's decisions and the latest "In progress" note — even if you left off in a different app. |
| 🔎 **Recalls as you type** | Each prompt pulls in only the memories relevant to it. Never repeats what was already shown, and never slows you down (hard 4-second budget). |
| ✍️ **Remembers automatically** | Finished turns are sent to MemContext, which extracts lasting facts in the background. Secrets are redacted. |
| 🔁 **Hands off unfinished work** | When a chat is compacted or you write an `In progress:` note, the next session picks it up — in any app. |
| 🧰 **Skills + MCP tools** | `memcontext` (search, save, update), `memcontext-handoff` and `memcontext-index` (learn a repo), plus the MemContext MCP tools for explicit saves and searches. |
| 🔒 **You stay in control** | Turn capture off globally or per repo, keep things out with `<private>…</private>`, and your opt-outs always win. |

> **Why a plugin and not just MCP?** With MCP alone, the model has to *decide* to search memory — and it often doesn't. The plugins put the right memory in context before the first token, through each app's own lifecycle hooks. In our tests, Claude Code answered 6/6 memory questions with the plugin vs 4/6 with MCP only; Codex 6/6 vs 2/6.

## Supported apps

| App | What you get | How it's installed |
|---|---|---|
| **Claude Code** | Session + per-prompt memory, capture, compaction handoff, skills, MCP | Plugin marketplace |
| **Codex CLI / ChatGPT desktop** | Session + per-prompt memory, capture, skills, MCP | Plugin + user hooks |
| **Cursor** | Session memory, prompt recall, capture, rules, skills, MCP | Plugin |
| **Gemini CLI** | Session + per-prompt memory, capture, skills, MCP | Extension |
| **Antigravity** | Session + per-prompt memory, capture, rules, skills, MCP | Plugin |
| **OpenCode** · **Kilo Code** | Per-turn memory, capture, compaction handoff, skills, MCP | npm [`opencode-memcontext`](https://www.npmjs.com/package/opencode-memcontext) |
| **OpenClaw** | Per-prompt memory, capture, memory tools, `/remember` `/recall` | npm [`openclaw-memcontext`](https://www.npmjs.com/package/openclaw-memcontext) |
| **Hermes Agent** | Per-turn memory, capture, skills, MCP | Python plugin |
| **Amp** | Per-turn memory, capture, skills, MCP | Plugin |
| **Grok Build** | Capture, skills, MCP | Plugin marketplace |
| **Factory Droid** · **Devin** · **Augment** · **GitHub Copilot CLI** | Hooks, skills and MCP (to each app's limits) | Plugin |
| **Qwen Code** · **Kiro** | Skills + MCP | Extension / Power |
| **VS Code** · **Zed** · **Warp** · **Cline** · **Windsurf** · **Goose** | MemContext MCP tools | MCP config |
| **Claude.ai** · **ChatGPT** · **Gemini** (web) | MemContext connector | Instructions printed by `install --all` |

Run `npx memcontext-plugin list` to see which of these are on your machine and what is installed.

## Installer commands

```bash
npx memcontext-plugin install                        # detect apps, pick which ones, install, sign in
npx memcontext-plugin install --only claude-code,cursor
npx memcontext-plugin install --dry-run              # show every step, change nothing
npx memcontext-plugin update                         # refresh every installed plugin
npx memcontext-plugin login                          # browser sign-in (shared by all plugins)
npx memcontext-plugin login --api-key mc_...         # or an API key (CI, servers)
npx memcontext-plugin status                         # connection + current project
npx memcontext-plugin list                           # supported apps, detected and installed
npx memcontext-plugin uninstall --all                # remove from every app
npx memcontext-plugin logout
```

Options: `--only <ids>`, `--all`, `--dry-run`, `--source local|github|github:<owner/repo>|<path>`, `--tag <npm tag>`, `--no-login`, `-y`.

The installer edits app configs safely: it keeps your comments and existing options, backs files up once, and never writes a config the app couldn't read.

## Install inside a single app (no npm)

| App | Command |
|---|---|
| **Claude Code** | `/plugin marketplace add CyberBoyAyush/memcontext-plugins` then `/plugin install memcontext@memcontext` |
| **Codex** | `codex plugin marketplace add CyberBoyAyush/memcontext-plugins` then `codex plugin add memcontext@memcontext` |
| **Cursor** | Settings → Plugins → From GitHub repository → `CyberBoyAyush/memcontext-plugins` |
| **Gemini CLI** | `gemini extensions install https://github.com/CyberBoyAyush/memcontext-plugins --ref gemini` |
| **Grok Build** | `grok plugin marketplace add CyberBoyAyush/memcontext-plugins` |
| **Factory Droid** | `droid plugin marketplace add CyberBoyAyush/memcontext-plugins` |
| **Copilot CLI** | `copilot plugin install CyberBoyAyush/memcontext-plugins:plugins/copilot` |
| **OpenCode / Kilo** | add `"opencode-memcontext@latest"` to your config — see [opencode-memcontext](https://www.npmjs.com/package/opencode-memcontext) |
| **OpenClaw** | `openclaw plugins install openclaw-memcontext` then `openclaw memcontext setup` |

Then sign in once with `npx memcontext-plugin login` (or set `MEMCONTEXT_API_KEY`). Codex's automatic memory hooks come from `npx memcontext-plugin install`.

## Privacy and control

- **Your opt-outs always win.** Set `"capture": false` (or `"enabled": false`) and no repo config or plugin option can turn it back on. A conversation that ever ran with capture off is never uploaded.
- **One conversation, one account.** Each conversation stays with the MemContext account that started it; switching accounts never mixes memories.
- **Private text stays local.** `<private>…</private>` spans are removed before upload, and MemContext redacts secrets.
- **Group chats stay private.** OpenClaw and Hermes don't use or save your memory in group, channel or other people's chats unless you opt in.

## Configuration

Global: `~/.memcontext/settings.json` · Per repo: `<repo>/.memcontext/config.json`

```json
{
  "enabled": true,
  "injectOnStart": true,
  "recallOnPrompt": true,
  "capture": true,
  "startTokens": 900,
  "promptTokens": 450,
  "project": ""
}
```

Environment variables: `MEMCONTEXT_API_KEY`, `MEMCONTEXT_DISABLE=1`, `MEMCONTEXT_RECALL=0`, `MEMCONTEXT_CAPTURE=0`, `MEMCONTEXT_PROJECT=name`, `MEMCONTEXT_API_URL`, `MEMCONTEXT_MCP_URL`.

**Project** = the repository name from your git remote, so every app working in the same repo shares the same project memory.

## Updates

| Channel | How updates arrive |
|---|---|
| `npx memcontext-plugin update` | Refreshes every installed app from the latest release |
| Claude Code · Grok · Factory | `/plugin marketplace update memcontext` (or turn on auto-update) |
| Codex | `codex plugin marketplace upgrade memcontext` |
| Gemini CLI | auto-updates from GitHub |
| OpenCode · Kilo · OpenClaw | npm `@latest`, picked up on restart |

## How it works

```
 your AI app (session start, prompt, reply, compaction …)
        │  hook event
        ▼
 MemContext plugin ──► GET  /api/memories/context   memory for this session / prompt
                  ├──► POST /api/memories/ingest    the conversation, sent once per change
                  └──► PUT  /api/memories/handoff   "In progress" note for the next session
        │
        ▼  memory added to the model's context in the format each app expects
```

Every hook fails open: if MemContext is slow or offline, your agent keeps working normally.

## Development

```bash
pnpm install
pnpm build        # bundles the shared runtime into every plugin, syncs skills, builds the CLI
pnpm test         # vitest against a mock MemContext API
pnpm run ci       # typecheck + tests + build + manifest validation + generated-file check
```

Repository layout: `packages/core` (shared runtime), `packages/cli` (the

... (truncated)
tools

Comments

Sign in to leave a comment

Loading comments...