This skill should be used when the user asks to "set up claude-mem", "pair claude-mem", "connect cmem", "add my cmem key", "set up cloud sync in Cowork", or pro
复制下面这句话,粘贴给 Claude Code、Codex、Cursor 等 AI 编程工具,它会读取安装说明并在你确认后完成安装。
请阅读 https://ai.atlankj.com/install/asset/gh-mem-setup-52066d0f34c0 ,按照其中的说明把「mem-setup」安装到你(当前 AI 工具)中。执行前先告诉我将运行的命令和写入的位置,等我确认。
查看 AI 将读取的安装说明正在读取 GitHub 原文…
内容来自 GitHub 原始文件,由原作者维护。在 GitHub 查看
Configure this plugin with the user's own cmem.ai credentials so hooks can capture and inject memory. Anyone can pair — credentials are per-user configuration, never hardcoded in plugin logic.
From cmem.ai → Connect, the user has three values:
cm_) — used as the bearer API keyIf the user pastes the whole Connect blurb, extract the three values from it. If any are missing, ask for the sync token at minimum — the other two are optional.
Locate the installed plugin root (this skill's own plugin). Update its
config.json: set apiKey to the sync token, userId, and syncHubUrl.
Leave other settings unless the user asks (inject toggles). Project naming
is automatic (cmem_work_*) and is not configurable.
Cowork containers are ephemeral: edits to the installed copy last only for
this session. To make pairing permanent, repackage — zip the plugin
directory as <plugin-name>.plugin and send it to the user to re-install
(the cowork-plugin skill's packaging flow). Tell the user this is why.
If this machine also has a local claude-mem install (a ~/.claude-mem/
directory exists), optionally write the same values to
~/.claude-mem/settings.json with mode 0600 (CLAUDE_MEM_CLOUD_SYNC_TOKEN,
CLAUDE_MEM_CLOUD_SYNC_USER_ID, CLAUDE_MEM_CLOUD_SYNC_HUB_URL keys — the
same keys the local claude-mem cloud-sync pairing writes) — the hook script
and the local worker both read it.
Verify without exposing the secret:
node "${CLAUDE_PLUGIN_ROOT}/scripts/cmem-hook.mjs" status
Report the masked output. A MISSING key means the write didn't land;
a 404 on /api/hooks/context is expected until the Pro endpoints deploy
(search/injection still work via /api/mcp).
Env vars override everything and need no file edits: CMEM_API_KEY,
CMEM_USER_ID, CMEM_SYNC_HUB_URL, CMEM_API_BASE.