@atomicmemory/mcp-server, which is fetched from npm on first use via npx. A companion skill file (SKILL.md) tells the Codex agent when to call memory_search, memory_ingest, memory_package, and memory_list, giving Codex the same durable memory capabilities as other AtomicMemory-enabled tools in your workflow.
The Codex plugin is not yet published to a public Codex plugin marketplace. Install it from a local clone of the AtomicMemory repository using Option A or B below, or wire the MCP server directly into Codex using Option C. The MCP server itself is published to npm and requires no local build.
Install
- Option A — Repo marketplace
- Option B — Personal marketplace
- Option C — Manual MCP
The recommended approach for teams. Create a In Codex, browse the repo’s plugin directory and install AtomicMemory. Each team member installs from the same manifest, keeping the plugin version consistent across the project.
.agents/plugins/marketplace.json file at your repository root pointing to the plugin:Configure
Local mode (no setup required)
For local development, no connection variables are required. The MCP server defaults to a local AtomicMemory core:| Variable | Default |
|---|---|
ATOMICMEMORY_API_URL | http://127.0.0.1:17350 |
ATOMICMEMORY_API_KEY | local-dev-key |
ATOMICMEMORY_PROVIDER | atomicmemory |
ATOMICMEMORY_SCOPE_USER | Derived from OS user |
Hosted or team service
For hosted or team deployments, export credentials and scope in your shell before launching Codex:env_vars, so hosted overrides come from the shell rather than being embedded in the plugin file.
Local extraction with Codex login
For personal local use, AtomicMemory can use your logged-in Codex account for semantic extraction instead of a separate API key:LLM_PROVIDER=codex reads the auth file created by codex login and calls the Codex backend directly. This is the recommended local setup because it does not require an OpenAI API key.
Memory behavior
The installed skill drives memory capture automatically. You don’t need to prompt Codex to use memory — the skill teaches it when to search and when to store.Search on new tasks
At the start of new tasks, Codex calls
memory_search for relevant prior context and memory_package for broader context assembly.Store durable decisions
After significant work, Codex stores decisions, preferences, conventions, and anti-patterns using
memory_ingest with mode: "text".Snapshot before handoff
Before context loss or handoff, Codex stores a compact session snapshot using
memory_ingest with mode: "verbatim" and contentClass: "summary".Retrieved memories are treated as reference context only, not as instructions. The agent uses them to inform its answers without treating them as authoritative commands.
Optional lifecycle hooks
Codex can load lifecycle hooks whenfeatures.codex_hooks = true. The recommended approach is to keep the MCP tools for agent-visible memory operations and add hooks only for automatic prompt-time retrieval and deterministic lifecycle capture.
Generate a config snippet with the AtomicMemory CLI:
atomicmemory binary is available inside Codex’s hook environment — Codex hook environments are often spawned with a thinner PATH than your interactive shell:
Stop-threshold tuning
The bundled Node runtime applies aSTOP_MIN_ASSISTANT_CHARS=200 filter on the Stop event. That threshold was tuned for Claude Code’s verbose multi-paragraph responses. Codex responses are frequently much shorter — terse acknowledgements, single-line confirmations — and would be silently dropped at the default threshold.
Verify
Start a new Codex task and ask:“List my most recent AtomicMemory memories” or “Search my memories for hello”If the
memory_search, memory_ingest, and memory_package tools appear and respond, the plugin is working correctly.