mammoth-memory
Skill4 starsChanged yesterdayApache-2.0View on GitHub
Durable cross-session memory for this repo via AllSource Prime. Recall what was learned in past sessions and record salient new facts as you work — so the user never re-explains decisions, architecture, or task history twice. Use at the START of a session to orient (recall prior context before answering non-trivial questions), and DURING work to record decisions, gotchas, and outcomes worth remembering. Triggers on "what did we decide about X", "remember this", "why did we do Y", "recall", "have we discussed", "load context", or any question that depends on prior-session knowledge. Also use PROACTIVELY: recall before answering architecture/decision/history questions; record after a non-obvious decision is made. mammoth = the memory layer; caveman makes few token, mammoth never forget token.
In this repository25 other files it gives its agents.
- AGENTS.mdAGENTS.md
- CLAUDE.mdCLAUDE.md
- allsource-incident-statusSkill
- allsource-partnershipsSkill
- ritual-fullSkill
- ritualSkill
- semantic-isaSkill
- admin-healthSkill
- allsource-data-accessSkill
- allsource-debugSkill
- allsource-incident-statusSkill
- allsource-mcp-setupSkill
- allsource-onboardSkill
- chronos-data-flow-embeddedSkill
- chronos-data-flowSkill
- chronos-durabilitySkill
- chronos-embedded-durabilitySkill
- chronos-releaseSkill
- fly-statusSkill
- ritual-fullSkill
- ritualSkill
- semantic-isaSkill
- seo-aeo-auditSkill
- allsource-customerSkill
- allsource-prime-memorySkill
The file
We split this skill into the rules it gives an agent
5 rules. About 0 are common, 1 is distinctive, and 4 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈1
Distinctive · estimate
This author's own choices. Worth a look.
4
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 18
Availability gate: only act if prime_* tools are present.
- Very specific: line 27
Do this before answering any question that depends on prior-session knowledge — architecture choices, "why did we…", task history, …
- Very specific: line 31
Orient (cheap): Call prime_stats to see if memory has anything at all.
- Very specific: line 33
Hybrid recall: Call prime_context with the user's question as query (tier L2, the default — adds the compressed index + vectors + graph).
- Distinctive: line 37
Use it, cite it: If recall returns relevant facts, fold them into your answer and tell the user this came from memory ("from an earlier …
≈ “Common” is an estimate: at least 1 in 5 of the 364,980 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
mammoth-memory
Durable agent memory for this repo. Backed by the AllSource Prime MCP server
(prime_* tools) running local-only against .prime/ — durable WAL + Parquet,
no account, survives restarts. Generalized from the shipped pr-atom-reviewer
recall/record pattern into a general-purpose memory loop.
Hard rule — provenance: record your own analysis (decisions, rationale, gotchas, outcomes, summaries). NEVER write raw proprietary source code, secrets, API keys, or full file contents into Prime nodes/embeddings unless the user explicitly says it's OK. Metadata, file paths, and your conclusions are fine.
Availability gate: only act if prime_* tools are present. If they are not,
skip silently — do not announce "memory unavailable" unless the user asks. (The
project .mcp.json wires the server; tools surface after the user approves the
project MCP server on session start.)
When to RECALL (read memory)
Do this before answering any question that depends on prior-session knowledge — architecture choices, "why did we…", task history, who/what/when — and at the start of a fresh session for orientation.
- Orient (cheap). Call
prime_statsto see if memory has anything at all. Cold/empty store → skip recall, proceed normally, don't fabricate context. - Hybrid recall. Call
prime_contextwith the user's question asquery(tierL2, the default — adds the compressed index + vectors + graph). For a pure "what do I know about X" lookup,prime_recallwithtext= the query is enough. Ask fortop_k5. - Use it, cite it. If recall returns relevant facts, fold them into your answer and tell the user this came from memory ("from an earlier session: …") so the recall is visible — that visibility IS the product's magic moment.
- Cold start is fine. Empty results on the first sessions of a repo are expected. Never invent prior context to fill the gap.
Tool params come from each tool's input schema — prime_context requires
query; prime_recall takes text (server embeds in-process via fastembed) or
a precomputed vector, plus optional depth (0 = vector-only, 1+ = graph
expansion) and top_k. Don't guess names; the schemas are authoritative.
When to RECORD (write memory)
Record after something worth remembering happens. Best-effort: if a call fails, note it briefly and continue — recording never blocks the real work.
What counts as salient (default policy — owner may refine, chronis t-7cdc):
- A decision and its rationale ("chose X over Y because Z").
- A non-obvious gotcha / constraint discovered ("Core can't cross-compile to amd64 on Apple Silicon — QEMU fails on Erlang NIF").
- A durable fact about the project not derivable from code (ownership, conventions, external dependencies, deadlines).
- An outcome (what shipped, what was verified, what failed and why).
What is NOT salient (do not write — keeps the store signal-dense):
- Restating what's already in the codebase, git history, or CLAUDE.md.
- Transient state ("currently editing foo.rs"), chit-chat, or step narration.
- Anything covered by an existing node — update it instead of duplicating.
Recording steps:
- Find or create the subject node.
prime_search(bytype) orprime_neighborsto check if a node already exists. Create withprime_add_nodeonly if absent. Always include adomainproperty (e.g."domain": "mammoth","engineering","architecture") — domains power the compressed index's cross-references. Pick atypefrom the tool's set:decision,insight,concept,project,event,person,metric. - Embed it for semantic recall.
prime_embedwithtext= your written fact/decision (NOT source code), keyed by the node'sentity_id(the idprime_add_nodereturned). This is what makes it findable later. - Connect it.
prime_add_edgeto link the new node to related ones (depends_on,causes,impacts,requires). Cross-domain edges are the highest-value: they make the index's cross-reference section useful.
The loop (proactive default)
- Session start / new topic:
prime_stats→ if non-empty and the topic is non-trivial,prime_contextto pull relevant prior knowledge before answering. - After a decision or discovery: record it (node + embed + edges).
- On "remember this": record the user's note verbatim as an
insight/decisionnode + embed. - On "what did we decide / why / have we discussed": recall first, answer from memory, cite it.
--auto-inject is on in .mcp.json, so a compressed index is injected as the
prime://auto-context resource each conversation — you often already have a
high-level map before calling anything. Use prime_context/prime_recall to go
from that map to specifics.
Verification checklist
- Checked
prime_*tools exist before acting (silent skip if not). - Recalled (via
prime_context/prime_recall) before answering a prior-knowledge question; cited memory when used. - Recorded only salient, non-proprietary facts; updated rather than duplicated existing nodes.
- Every recorded node has a
domain; salient nodes are embedded so they're recallable. - No raw source code, secrets, or full file contents written to Prime.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

