-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Description
Summary
I use both Claude Code and OpenAI Codex CLI heavily - Claude Code for complex
agentic work, Codex for its generous context limits and strong reasoning on
large tasks. Having shared persistent memory between the two would make them
genuinely complementary rather than siloed.
Current State
claude-mem already supports claude-code and cursor platforms. Codex CLI
supports MCP servers natively (via config.toml), so Codex can already READ
from claude-mem today by connecting to the mcp-server.cjs MCP server.
The gap is WRITING. Codex CLI does not yet have a PostToolUse or SessionStart
hooks system equivalent to Claude Code's. It only has a notify config that
fires on agent-turn-complete. This means automatic per-tool observation
capture isn't possible yet.
What I'm Requesting
-
A
codexplatform for therawhook — similar to howcursoris a
supported platform. The worker already acceptshook raw observationbut
needs to know the expected JSON input format Codex should send (message
history format, tool call format, etc.) so that observations actually get
saved rather than filtered out. -
A
notify-compatible endpoint — since Codex'snotifyfires on
agent-turn-completewith a JSON payload (thread-id, last-assistant-message,
input-messages, cwd), the worker could accept this payload and generate a
session summary observation from it. This would give Codex at minimum
end-of-turn memory capture today, without waiting for full hooks support. -
Documentation — a section in the README showing how to configure Codex
CLI's config.toml to point at the MCP server and use the notify hook.
Why This Matters
Claude Code excels at long agentic sessions, hooks-driven automation, and
complex multi-step work. Codex CLI excels at large context tasks, has a more
generous plan, and reasons well about big codebases. Used together they cover
each other's gaps. Shared memory via claude-mem would make the combination
dramatically more powerful — work done in a Codex session would be available
in Claude Code and vice versa.
Technical Details
- Worker is already running as a local HTTP server (default port 37777)
hook raw observationalready returns exitCode 0 when called- The worker's AI filters out low-value content, so the format of the JSON
payload passed on stdin matters for whether observations are actually saved - Codex's
notifypayload includes: type, thread-id, turn-id, cwd,
input-messages, last-assistant-message