write-memory

A worker that writes a note to a vault after another skill has decided what should be remembered.

In plain words
What is it for?
Use it to create fact, feedback, question-and-answer, or runbook notes from a provided handoff.
Why use it?
It keeps the writing step separate from the decision about whether something is worth saving, and verifies where the note was written.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/toejough/engram/write-memory
Any agent
npx skills add toejough/engram --skill write-memory
Clone the repo
git clone --depth 1 https://github.com/toejough/engram

Made for: Claude Code, Codex.

Per session 62 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,258 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00062 $0.01258
Opus 5 $0.00031 $0.00629
Sonnet 5 $0.00012 $0.00252
Haiku 4.5 $0.00006 $0.00126

Measured yesterday against content hash eba8f55f040e, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

write-memory scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agent-instructions/skills/write-memory/SKILL.md · 115 lines

How it starts

The opening of the file, as written. The whole thing — 115 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Write Memory — execute a handed-off vault write

You were invoked by a parent skill that already made the judgment (what to write and why). Your job is the write itself: compose, execute, verify, report. Do not re-litigate the parent's judgment; do not decide WHETHER to write.

The handoff contract

The parent provides:

  • kindfact, feedback, qa, or runbook
  • content fields — by kind, per the blocks below
  • source — human-readable provenance string
  • optional chunk-sources<source#anchor> chunk IDs (provenance)
  • optional tags — categorical <family> or <family>/<value> strings (kebab-case; fact/feedback/runbook only), e.g. work-kind/rename, tier/cheap, outcome/pass
  • optional supersedes<basename>|<type>|<claim> (types: updates|narrows|refutes), when the parent determined this write corrects a surfaced note
  • optional position / target — Luhmann placement (top (default), continuation, or sibling) plus the target note ID (required when position is not top), when the parent made a disposition decision. Omitted → --position top (today's default), fact/feedback/runbook only.

If a required field is missing, ask for it from the in-session parent context — do not invent content on the parent's behalf.

Compose

kind=feedback:

engram learn feedback --slug <kebab-slug> --position <top|continuation|sibling> [--target <id>] \
  --source "<source>" \
  --situation "<retrieval-shaped phrase: when does this apply>" \
  --behavior "<what was done>" --impact "<why it was wrong/costly>" --action "<what to do instead>" \
  [--tag <family>/<value> ...]

kind=fact:

engram learn fact --slug <kebab-slug> --position <top|continuation|sibling> [--target <id>] \
  --source "<source>" \
  --situation "<retrieval-shaped phrase: when does this apply>" \
  --subject "<the thing>" --predicate "<requires / must use / is>" --object "<the standard or value>" \
  [--tag <family>/<value> ...]

Read the full file on GitHub · 115 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. yesterday First seen · 115 lines · 62 tokens per session scan A eba8f55f040e

Subscribe to this mod's changes

write-memory is a skill published in the GitHub repository toejough/engram (8 stars, last pushed yesterday), licensed Apache-2.0. It adds 62 tokens to every session and 1,258 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.