memory-capture

A skill for saving decisions, lessons, recurring practices, and other project information as persistent memories that survive between sessions.

In plain words
What is it for?
It is for recording architecture decisions, technical learnings, project context, API details, security notes, testing guidance, and technical debt.
Why use it?
It prevents important context from being lost when a conversation ends or the active context is shortened.

Skill for Claude CodeCodex

Part of the subcog plugin — 4 skills, 9 commands, 5 hooks shipped together

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/zircote/subcog/memory-capture
Any agent
npx skills add zircote/subcog --skill memory-capture
Clone the repo
git clone --depth 1 https://github.com/zircote/subcog

Made for: Claude Code, Codex.

Or install subcog, the plugin that ships this one along with the rest of its 4 skills, 9 commands, 5 hooks.

Per session 0 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 798 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.00000 $0.00798
Opus 5 $0.00000 $0.00399
Sonnet 5 $0.00000 $0.00160
Haiku 4.5 $0.00000 $0.00080

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

Security

Grade A, and why

memory-capture 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 3d 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.

skills/memory-capture/SKILL.md · 99 lines

How it starts

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

Memory Capture Skill

Capture decisions, learnings, patterns, and context as persistent memories that survive across sessions.

Trigger Phrases

  • "remember this", "capture this", "save this decision"
  • "document that", "log this pattern", "note this learning"
  • "TIL", "gotcha", "we decided", "going with"
  • "this is important", "don't forget"

Quick Reference

Namespace Use When Signal Words
decisions Making architectural or design choices "decided", "chose", "going with"
patterns Establishing recurring practices "always", "never", "when X do Y"
learnings Discovering something new "TIL", "gotcha", "discovered"
context Recording background information "because", "constraint", "requirement"
tech-debt Noting future work "TODO", "FIXME", "temporary"
apis Documenting API contracts "endpoint", "API", "schema"
config Recording configuration details "config", "environment", "setting"
security Security-related information "auth", "vulnerability", "permission"
performance Performance insights "optimization", "benchmark", "latency"
testing Testing strategies "edge case", "fixture", "coverage"

Execution Strategy

Capture Quality Guidelines:

  • Include context and rationale, not just the decision
  • Add relevant tags for discoverability
  • Reference related files or components
  • Keep content concise but complete

Interactive Capture Workflow

  1. Detect capture signals in user's message
  2. Identify the namespace from context and signal words
  3. Extract the core insight - what should be remembered?
  4. Enhance with context - why is this important?
  5. Suggest tags based on content and current work
  6. Confirm with user using AskUserQuestion if uncertain
  7. Execute capture via MCP tool or CLI
  8. Verify success and report the memory ID

Read the full file on GitHub · 99 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. 3d ago First seen · 99 lines · 0 tokens per session scan A 55dd3753fca7

Subscribe to this mod's changes

memory-capture is a skill published in the GitHub repository zircote/subcog (28 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 798 tokens. 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-30.

Related

Other skills, from other repositories

codebase-exploration

Explore and understand codebases using SocratiCode semantic search, dependency graphs, and context artifacts. Use when exploring code, understanding architecture, finding functions/types, analysing dependencies, searching database schemas or API specs, or when socraticode/codebasesearch tools are available. Activates…

giancarloerra/SocratiCode · 88 tokens

codebase-management

Set up, index, and manage SocratiCode codebase indexing. Use when the user wants to index a project, check infrastructure health, start/stop file watching, configure context artifacts, troubleshoot indexing issues, manage the code graph, or any SocratiCode administrative task. Activates when the user mentions…

giancarloerra/SocratiCode · 86 tokens

cocosearch-review-pr

Use when reviewing a GitHub PR or GitLab MR by URL. Fetches diff and metadata via API, then uses CocoSearch for blast radius analysis, dependency impact, pattern consistency, and test coverage assessment. Read-only by default; optionally pushes findings back as inline PR/MR comments after your confirmation.

VioletCranberry/coco-search · 68 tokens

cocosearch-add-language

Use when adding support for a new programming language or config format to CocoSearch. Guides through all paths (handler, symbol extraction, context expansion) with registration checklists. For grammar handlers, use cocosearch-add-grammar.

VioletCranberry/coco-search · 53 tokens

cocosearch-add-extractor

Use when adding a dependency extractor for a language or grammar. Guides through pre-checks, extractor implementation, optional module resolver, tests, and registration. Enables deps tree, deps impact, and dependency-enriched search for the target language.

VioletCranberry/coco-search · 57 tokens

cocosearch-add-grammar

Use when adding a grammar handler for domain-specific file formats that share a base language extension (e.g., GitHub Actions within YAML). Guides through YamlGrammarBase inheritance, content validation, separator spec, metadata extraction, tests, and registration.

VioletCranberry/coco-search · 57 tokens