@everme/qoder
v0.7.10
Published
Native EverMe memory hooks for Qoder CLI.
Readme
@everme/qoder
Native EverMe memory hooks for Qoder CLI.
What it does
Qoder CLI runs the same hook engine that QwenWork embeds through
@qoder-ai/qoder-agent-sdk. The engine follows the Claude Code hook
contract: stdin carries the hook input as JSON, stdout is parsed as hook
output, and exit code 2 blocks the operation. evercli plugin install qoder
registers three events:
| Event | Mode | What it does |
|---|---|---|
| SessionStart | sync | Injects the durable Profile block once per session. |
| UserPromptSubmit | sync | Injects recall for the prompt as additionalContext. |
| Stop | async | Captures the finished turn and uploads it. |
The install also does these steps:
- It stages this bundle at
<config-dir>/everme/. - It writes credentials to
<config-dir>/everme.envwith mode0600. - It adds the three hooks to
<config-dir>/settings.json. Other keys and the user's own hooks stay unchanged.
<config-dir> is ~/.qoder for the global edition and ~/.qoder-cn for the
China edition. The installer selects ~/.qoder-cn when QODERCLI_SITE=cn is
set, or when only ~/.qoder-cn exists.
Each hook command passes the config dir as an argument after the event name. This lets one staged bundle read the credentials of the edition that called it.
No MCP entry is written. The hooks already inject recall and the profile. The location where Qoder CLI reads user-scope MCP servers is not verified yet.
Start a new Qoder CLI session after install so that it loads the hooks.
Why Stop, and why async
SessionEndfires only when the CLI exits. If it were the capture boundary, a long interactive session would stay uncaptured until exit.Stopfires once per turn, so this package uses it.- A synchronous upload on every
Stopwould block each turn, soStopis registered withasync: true. The host does not wait for it and does not read its stdout. PostToolUseis not registered. It would start one process per tool call for data that the transcript already contains.
How a turn is read
Every hook payload carries transcript_path, which points to
<config-dir>/projects/<cwd-slug>/<session-uuid>.jsonl. Capture reads that
file. It does not rebuild a turn from event fields.
The transcript reader is a copy of the @everme/qwenwork reader, because the
two hosts write the same format. Read that package's README for the selection
rules, the native checkpoint, and the filters. Hosts never import each other.
Moving the reader into @everme/agent-sdk is a separate change.
Configuration
The hook reads its credentials from <config-dir>/everme.env, which evercli
writes. You can override the location in these ways:
EVERME_ENV_FILE_PATHsets the path of the credential file.EVERCLI_QODER_CONFIG_DIRsets the config dir when no argument names it.
Without credentials the hooks are silent: no output, no error, exit code 0. Memory must never block a turn, so every failure path exits with code 0 and writes one line to stderr.
Uninstall
evercli plugin uninstall qoderTo uninstall manually, do these steps:
- In
<config-dir>/settings.json, remove theeverme-named handlers fromhooks. Keep every other hook. Remove an event key only if it becomes empty. - Run
rm -rf <config-dir>/everme <config-dir>/everme.env.
Tests
npm test --workspace @everme/qoderLicense
Apache-2.0
