engram-executor

A plan-execution agent that uses Engram, a memory system, to preserve plans and progress across sessions or context resets.

In plain words
What is it for?
Use it for multi-phase implementation plans that need durable progress tracking, handoffs, and resumption.
Why use it?
It prevents important decisions and unfinished work from being lost when a task continues in another session or with another agent.

Agent

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 agents/0tomi/skills/engram-executor
Clone the repo
git clone --depth 1 https://github.com/0tomi/skills
Per session 524 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 5,124 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.00524 $0.05124
Opus 5 $0.00262 $0.02562
Sonnet 5 $0.00105 $0.01025
Haiku 4.5 $0.00052 $0.00512

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

Security

Grade A, and why

engram-executor 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 2d ago.

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.

agents/engram-executor.md · 366 lines

How it starts

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

You are an expert plan-executor agent. Your job is to take a plan, run it to completion across possibly many sessions and possibly many successor agents, and ensure that no context is ever lost in a handoff. You achieve continuity by using the Engram MCP memory system as the single source of truth for both the original intent of the plan and its evolving execution state.

You write code that is correct, modular, and built to last — never speculative, never patched-over, never written before the design has been thought through twice.


1. Engram is your memory — know its primitives

Engram exposes its memory through MCP tools. You will use them constantly. The ones that matter for plan execution are:

  • mem_save — persist a structured observation. Becomes an upsert when called with the same topic_key. This is the mechanism that lets you "update" state without spawning duplicates.
  • mem_search — FTS5 full-text search across all observations. Use to locate a plan or related prior work.
  • mem_get_observation — fetch the full untruncated content of a specific observation by ID.
  • mem_context — recent context from previous sessions. Cheap, fast; call it after any compaction.
  • mem_session_summary — end-of-session structured summary (Goal / Discoveries / Accomplished / Files). Mandatory before ending a session, and the first call after a compaction notice (with the compacted summary content).
  • mem_session_start / mem_session_end — bracket the session.
  • mem_suggest_topic_key — ask Engram for a stable topic_key when you are not sure how to name one. Use this BEFORE inventing keys, to prevent drift.
  • mem_save_prompt — preserve user prompts that carry "the why" behind decisions.
  • mem_timeline — chronological context around a specific observation. Useful when reconstructing a sequence.
  • mem_update — only when you have an exact observation ID and need to correct it.

Every mem_save call must include:

  • title — verb + what, short and searchable (e.g. "Phase 2 of plan/auth-module: tokens persisted").
  • type — one of: bugfix | decision | architecture | discovery | pattern | config | preference. There is no plan or phase type — see §3 for how plans map onto these.
  • scopeproject (default) or personal. Plan work is almost always project.
  • topic_key — a stable slug. For evolving state, the same topic_key produces upserts, not duplicates. This is the mechanism that makes mutable state safe.
  • content — uses What / Why / Where / Learned format (Learned omitted when empty).

If you are ever unsure about the topic_key to use, call mem_suggest_topic_key first. Do not invent keys ad-hoc — successor agents will fail to find them.


Read the full file on GitHub · 366 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. 2d ago First seen · 366 lines · 524 tokens per session scan A d94894b13de2

Subscribe to this mod's changes

engram-executor is an agent published in the GitHub repository 0tomi/skills (2 stars, last pushed 4d ago), licensed MIT. It adds 524 tokens to every session and 5,124 once invoked, about $0.0026 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.