ZrifBSofiane

MemAi — Development skill for Claude Code

Development community

Paged memory for coding agents: a ~200-token project card + symbol manifest, demand-paged detail and Merkle deltas, shared by Claude Code, Codex, OpenCode, ZCode and DSH through one MCP server or one.

How to install MemAi

This entry records only its repository, not the path inside it, so there is no exact command to give. Open ZrifBSofiane/MemAi and copy the folder into ~/.claude/skills/, or the file into ~/.claude/agents/.

What MemAi does

Paged memory for coding agents: a ~200-token project card + symbol manifest, demand-paged detail and Merkle deltas, shared by Claude Code, Codex, OpenCode, ZCode and DSH through one MCP server or one CLI.

Alternatives in Development

  • Harnessrouter — HarnessRouter Community Edition: the self-hosted, Apache-2.0 edition of the unified interface for agent harnes 618 ★
  • Edgee — Official Edgee CLI to interract with Edgee's Agent Gateway 127 ★
  • Qartez MCP — Semantic code intelligence MCP server for Claude Code - project maps, symbol search, impact analysis, and more 70 ★

README

MemAi

**Paged memory for coding agents.** MemAi distils your repository locally into a ~200-token project card plus a symbol manifest, then lets each session and subagent *demand-page* only the detail it needs, and resume after edits from a Merkle delta instead of re-reading files or consuming a model-written handoff. One stdio MCP server and one dependency-free CLI serve Claude Code, Codex, OpenCode, ZCode and DeepSeek Harness.

[![CI](https://github.com/ZrifBSofiane/MemAi/actions/workflows/ci.yml/badge.svg)](https://github.com/ZrifBSofiane/MemAi/actions/workflows/ci.yml)

**v0.1.0 preview.** The measured numbers below are real runs on one machine (Windows 11, Node 24.14); the compatibility matrix labels what was verified on an installed agent versus documented from vendor docs. npm package: `memai-cli` · CLI binary: `memai` · MCP binary: `memai-mcp` · store: `.memai/` · root env: `MEMAI_ROOT`.

The problem, in one measurement

On one completed two-agent coding task (170 model steps, 32.8M tokens billed):

  • 98.3% of billed tokens were re-sent context, not new input;
  • 91.4% of prompt tokens were tool results — file reads, shell output, inspection dumps — each riding in the window for ~39 further steps;
  • 14.9% of tool-output bytes were byte-identical repeats.

Re-reading files is not the expensive part. *Re-sending* everything that was ever read is. See [`docs/evidence.md`](docs/evidence.md) for the method and the counterfactual replay: keeping only the last 8 tool results inline would have cut prompt tokens **7.8×** and cost **−56%** on that task.

What MemAi does

Idea In practice
One small card memai card → stack, entrypoints, build/test commands, layout, conventions, paging rules. ~200 tokens, byte-stable, content-addressed.
One manifest memai map → one line per file with LOC + top symbols, budget-capped. The agent knows what exists without reading it.
Demand paging `memai