claude-memory-mcp: Instructions file for Codex

AGENTS.md

claude-memory-mcp AGENTS.md is an instructions file for Codex, OpenCode from WhenMoon-afk/claude-memory-mcp. It costs 2,035 tokens per session, scanned A, original, MIT.

Repository rules for Mooncite, a local Linux tool that searches and verifies evidence from earlier conversations. It uses a private, rebuildable database index while leaving the original conversation files read-only.

In plain words
What is it for?
Use them when changing indexing, lexical search, evidence inspection, status output, or source-file handling, especially where privacy and read-only behavior matter.
Why use it?
They define the privacy and accuracy limits of the tool: retrieval is bounded and evidence must be checked against the current source files. This prevents claims that it interprets, updates, uploads, or owns the conversation history.

Instructions file for CodexOpenCode

Written for Codex and OpenCode: the file is AGENTS.md. Also seen: mentions Claude Code; mentions Codex.

This is WhenMoon-afk/claude-memory-mcp's own configuration. It tells Codex and OpenCode how to work on claude-memory-mcp itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything claude-memory-mcp configures →

Reuse

Borrowing it

Nothing to install: this file belongs to WhenMoon-afk/claude-memory-mcp. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/WhenMoon-afk/claude-memory-mcp/main/AGENTS.md
Clone the repo
git clone --depth 1 https://github.com/WhenMoon-afk/claude-memory-mcp

Made for: Codex, OpenCode.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for claude-memory-mcp AGENTS.md

README.md
[![agentmods](https://agentmods.dev/badge/instructions/whenmoon-afk/claude-memory-mcp/agents-md/github.svg)](https://agentmods.dev/instructions/whenmoon-afk/claude-memory-mcp/agents-md)
Your own site
<a href="https://agentmods.dev/instructions/whenmoon-afk/claude-memory-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/whenmoon-afk/claude-memory-mcp/agents-md/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for claude-memory-mcp AGENTS.md

Your own site · 80×15
<a href="https://agentmods.dev/instructions/whenmoon-afk/claude-memory-mcp/agents-md"><img src="https://agentmods.dev/badge/instructions/whenmoon-afk/claude-memory-mcp/agents-md.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 2,035 This file is loaded in full into every session.
When invoked 2,035 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.02035 $0.02035
Opus 5.5 $0.00814 $0.00814
Sonnet 5.5 $0.00407 $0.00407
Haiku 4.5 $0.00203 $0.00203

Measured 26d ago against content hash 304a77cde034, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

claude-memory-mcp AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 26d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 89 lines

How it starts

The opening of the file, as written. The whole thing — 89 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Mooncite repository contract

These instructions apply to the whole repository. Preserve the invariants below unless the owner explicitly changes the product contract.

Product boundary

Mooncite is a Linux/procfs-only, local, citation-backed retrieval tool for prior conversation history. Packaged local embeddings require Linux x64 and are skipped on other architectures. It helps an agent find and verify bounded evidence; it does not decide what evidence means, whether it is current, or what the user should do.

  • Source history is user-owned and read-only. Never rewrite, repair, normalize in place, move, delete, or claim ownership of it.
  • The SQLite evidence index is owner-private, transactional, derived, disposable, and rebuildable from authorized sources.
  • Recall is lexical-first. An unquoted query of at least two terms may add local embedding matches after no strong lexical hit, and only when local embeddings are available. Quoted phrases and shorter queries stay lexical. Inspection must re-read and verify the current physical source bytes before returning a bounded window. Status must not expose transcript text or full physical paths.
  • Mooncite has no history network transport, telemetry, upload, SSH/remote-copy path, account login, export automation, credential/cookie access, or opaque application-cache scraping. Text returned through MCP enters the receiving model's privacy boundary; do not imply otherwise.
  • Evidence retrieval is not an authority, policy, recommendation, truth-scoring, or durable-agent-memory layer.

Fixed architecture

Treat these counts and seams as closed contracts:

  • Exactly five source origins: Pi, OMP, Claude Code, Codex, and ChatGPT.
  • Exactly three MCP tools: mooncite_recall, mooncite_inspect, and mooncite_status.
  • Exactly four client integrations: Pi, OMP, Codex, and Claude Code. They connect to one local stdio MCP server. ChatGPT is a source origin, not a client integration.
  • MoonciteEngine owns ingestion, source adapters, coherent reads, citation identity, SQLite/FTS, refresh/rebuild, inspection, last-good behavior, and the bounded canonical-anchor resolver.
  • The Pi extension is a thin native-to-MCP adapter. .mcp.json, Codex, and Claude Code registrations point to the same packaged server. Do not duplicate retrieval behavior in an integration.
  • Pi and OMP use their standard roots. Only the narrow supported Claude Code, Codex, and local ChatGPT-export roots may be automatically discovered. Owner configuration adds optional roots. A configured origin/root pair suppresses only the automatic registration with that exact pair. Automatic sibling roots remain active. Authorization grants local reads only.
  • Symlinks are excluded from source admission. Authorized roots and opened files remain physically contained and identity-checked through Linux file descriptors.
  • Incremental publication is transactional. Pi same-inode size growth may be admitted as append_trusted after a coherent suffix read. OMP same-inode size growth may use the same bounded path after physically verifying the last indexed evidence record; a failed boundary check replaces that source projection. These paths do not reread the already indexed prefix. Detectable Pi shrinkage, same-size rewrites, or identity changes retain the last-good generation. Other detected OMP changes and every detected change from supported mutable Claude Code, Codex, and ChatGPT producers replace that source projection transactionally. Never publish knowingly partial coverage over a usable generation.

Read the full file on GitHub · 89 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 26d ago Changed · -2 lines · -299 tokens per session 304a77cde034
  2. 1mo ago Changed · +3 tokens per session 4a7e523556d8
  3. 1mo ago First seen · 91 lines · 2,331 tokens per session scan A c4be82eef75d

Subscribe to this mod's changes

claude-memory-mcp AGENTS.md is an instructions file published in the GitHub repository WhenMoon-afk/claude-memory-mcp (69 stars, last pushed 27d ago), licensed MIT. It adds 2,035 tokens to every session, about $0.0081 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other instructions, from other repositories

vscode buildNext.instructions.md

Working notes and architecture documentation for the new esbuild-based build system in build/next. Use when making changes to the new build pipeline (transpile/bundle commands, NLS plugin, source-map handling, resource copying, or self-hosting watch tasks).

microsoft/vscode · 9,649 tokens

next.js AGENTS.md

AGENTS.md instructions for vercel/next.js, covering next.js development guide, codebase structure, monorepo overview, core package: packages/next and other important packages.

vercel/next.js · 7,549 tokens

vscode oss-third-party-notices.instructions.md

Instructions for microsoft/vscode, covering vs code oss third-party-notices pipeline, architecture, pipeline flow in ci, cache eligibility and rollout and applying the notice (cutover).

microsoft/vscode · 5,262 tokens

langchain AGENTS.md

AGENTS.md instructions for langchain-ai/langchain, covering global development guidelines for the langchain monorepo, corridor security analysis, project architecture and context, monorepo structure and development tools & commands.

langchain-ai/langchain · 4,680 tokens

vscode copilot-instructions.md

Copilot instructions for microsoft/vscode, covering vs code copilot instructions, project overview, root folders, core architecture (src/ folder) and built-in extensions (extensions/ folder).

microsoft/vscode · 2,731 tokens

deno copilot-instructions.md

Copilot instructions for denoland/deno, covering deno development guide for github copilot, network access, high level overview, key directories and key files to understand first.

denoland/deno · 3,077 tokens