coco-research/m0-recall
Read the recent M0 operational thread for a project, newest first, to pick up work started in this or another tool. Answers 'where were we' and 'what is next' before asking the user to repeat context. Local SQLite, no embeddings, no network. Triggers on: 'm0 recall', 'where were we', 'what did we do last time', 'catch me up', 'resume context', 'read the thread', 'what is next'.
npx skills add https://github.com/coco-research/coco --skill m0-recall
The read path for M0. Returns the most recent entries for a project, newest
first, with the next_step and last_verified that were recorded when they were
still true.
Retrieval is by project, kind and recency — there is no semantic search. That is
the whole query model, and it is why this returns in milliseconds.
M0="${M0_BASE_URL:-http://127.0.0.1:8787}"
M0S="$HOME/.claude/skills/m0/scripts"
# The recent thread for a project
curl -s "$M0/api/brain/thread?project=acme-web&limit=10" | python3 -m json.tool
# Just the handoffs
curl -s "$M0/api/brain/thread?project=acme-web&kind=compact_checkpoint&limit=3"
# Without a server (same store)
python3 "$M0S/m0_server.py" read --project acme-web --limit 10
If the MCP tools are wired (/m0 mcp), call m0_recall directly — it returns the
same data already formatted for reading.
| Parameter | Default | Notes |
|-----------|---------|-------|
| project | all projects | Omit only when you genuinely want every project. |
| limit | 20 | Capped at 500. |
| kind | all kinds | step_done, compact_checkpoint, session_end, lane_dispatched, lane_result, ambient_signal. An unknown value is rejected. |
$M0_PROJECT, elsethe repository or directory name.
limit=10 with no kind filter shows what hasbeen happening. If the thread is long, kind=compact_checkpoint gives the
handoffs, which is usually the fastest way to orient.
next_step. Oldernext_step values have usually been superseded — do not act on a stale one.
verified, and what the recorded next step is. Then say what you intend to do.
source_tool and branch on the entries you rely on. An entry writtenby another tool on another branch may not describe the tree you are looking at.
last_verified records what someone saidthey checked, at some earlier point. If it matters now, re-run it.
{
"project": "acme-web",
"count": 2,
"pending_sidecars": 0,
"degraded": null,
"entries": [ { "ts": "…", "kind": "step_done", "text": "…", "next_step": "…" } ]
}
| Signal | What it means |
|--------|---------------|
| count: 0 | Nothing recorded for that project. Check the project key before concluding the thread is empty — a typo reads as "no memory". |
| "pending": true on an entry | It is still in the sidecar spool, not yet in the store. Real, and readable, but not durable until the next drain. |
| pending_sidecars > 0 | Some writes are spooled. Run python3 "$M0S/m0_server.py" drain. |
| degraded set | The store could not be read — another process holds the lock — so the entries shown may be only the spooled ones. Say so; do not present a partial thread as complete. |
session in one editor can read what another wrote.
re-reading the whole history.
result, and whether it was verified.
kind, nothing else.compact_checkpoint entries are thecompression, and only because someone wrote them.
unless a hook was installed (/m0 hooks).
For semantic retrieval over a knowledge graph, the cognee bundle is the right
tool — see the comparison in systems/m0/README.md.
Take coco-research/m0-recall from the repository into ~/.claude/skills for personal
use, or into .claude/skills inside a project.
The agent identifies a skill by the name field in its header. Two skills with the
same name cannot sit side by side — one of them will be ignored.