memory-persistence

memory-persistence is a skill for Claude Code from itallstartedwithaidea/agent-skills. It costs 28 tokens per session (2,215 once invoked), scanned A, original, MIT.

A skill that lets an AI agent save useful details from one conversation and recall them in later sessions.

In plain words
What is it for?
Use it to store and retrieve user preferences, project context, past decisions, and summaries across conversations.
Why use it?
It prevents the agent from repeatedly relearning preferences, project patterns, decisions, and corrected mistakes.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions CLAUDE.md; mentions Claude Code; mentions Codex.

Part of the ai-agent-engineering-skills plugin — 10 skills shipped together , and of all-skills

Good fit Use it to store and retrieve user preferences, project context, past decisions, and summaries across conversations.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/itallstartedwithaidea/agent-skills/memory-persistence
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.

Any agent
npx skills add itallstartedwithaidea/agent-skills --skill memory-persistence
Clone the repo
git clone --depth 1 https://github.com/itallstartedwithaidea/agent-skills

Made for: Claude Code.

Or install ai-agent-engineering-skills, the plugin that ships this one along with the rest of its 10 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for memory-persistence

README.md
[![agentmods](https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/memory-persistence/github.svg)](https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/memory-persistence)
Your own site
<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/memory-persistence"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/memory-persistence/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for memory-persistence

Your own site · 80×15
<a href="https://agentmods.dev/skills/itallstartedwithaidea/agent-skills/memory-persistence"><img src="https://agentmods.dev/badge/skills/itallstartedwithaidea/agent-skills/memory-persistence.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 28 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,215 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.1 $0.00028 $0.02215
Opus 5.5 $0.00011 $0.00886
Sonnet 5.5 $0.00006 $0.00443
Haiku 4.5 $0.00003 $0.00221

Measured 1mo ago against content hash acca509d0a66, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

memory-persistence 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 1mo 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/ai-agent-engineering/memory-persistence/SKILL.md · 214 lines

How it starts

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

Memory Persistence

Part of Agent Skills™ by googleadsagent.ai™

Description

Memory Persistence enables AI agents to maintain knowledge across sessions, transforming stateless inference calls into stateful, continuously improving systems. Without persistence, every new session starts from zero — the agent must re-learn user preferences, re-discover codebase patterns, and repeat mistakes it has already corrected. Memory Persistence solves this by implementing hooks that save critical context at session end and reload it at session start, creating the illusion of continuous memory.

This skill is built on the production memory system powering Buddy™ at googleadsagent.ai™, which uses Cloudflare KV as a persistent memory store. After each conversation, Buddy™ extracts entities (campaigns, metrics, user preferences, decisions made), summarizes the session, and stores the result keyed by user and session. On the next conversation, the most relevant memories are retrieved and injected into context, giving Buddy™ the ability to reference prior analyses, respect stated preferences, and build on previous decisions.

The memory system operates at three granularities: entity-level memory (individual facts like "user prefers conservative bidding"), session-level memory (summarized conversations), and pattern-level memory (recurring behaviors like "this account always overspends on branded terms"). Each granularity serves different retrieval patterns and has different storage and freshness requirements.

Use When

  • Users interact with the agent across multiple sessions and expect continuity
  • The agent makes decisions that should remain consistent over time (preferences, conventions)
  • Domain knowledge accumulates over sessions and should not be lost
  • You want to avoid repetitive re-explanation of codebase structure or project context
  • The agent needs to track evolving entities (accounts, campaigns, metrics) across time
  • Session summarization is needed for audit trails or compliance

Read the full file on GitHub · 214 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. 1mo ago First seen · 214 lines · 28 tokens per session scan A acca509d0a66

Subscribe to this mod's changes

memory-persistence is a skill published in the GitHub repository itallstartedwithaidea/agent-skills (44 stars, last pushed 6mo ago), licensed MIT. It adds 28 tokens to every session and 2,215 once invoked, about $0.0001 per session on Opus 5.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-30.

Related

Other skills, from other repositories

supermemory

Supermemory is a state-of-the-art memory and context infrastructure for AI agents. Use this skill when building applications that need persistent memory, user personalization, long-term context retention, or semantic search across knowledge bases. It provides Memory API for learned user context, User Profiles for…

supermemoryai/supermemory · 81 tokens

flaremo-memory

A shared memory ledger for coding agents. It defines how agents check project rules, record facts during work, and save a handoff report at the end.

realchendahuang/FlareMo · 138 tokens

titen-memory

Use the Titen MCP server to recall bounded evidence-grounded context, record verified durable signals, submit feedback, and coordinate checkpoints, leases, or handoffs. Use when work may benefit from prior project memory or when a verified outcome should be preserved for another agent; do not use it to capture raw…

RamaAditya49/titen · 77 tokens

context

Use whenever the user asks about their own work, projects, decisions, people, preferences or past sessions, and before ending any session that produced something worth keeping. The user's Context is their own notes, reached through the context MCP server; this skill says when to read it and how to write back.

Supa-Media/context · 64 tokens

how-we-define-chaos

How Context scores a workspace's chaos, and how to organize notes so it goes down. Use when the user asks you to tidy, organize, clean up or restructure their notes or folders, asks about their chaos score, or when a write or move answer reports the score got messier.

Supa-Media/context · 65 tokens

sync

Copy what you already know about the user into their Context, adding to what other AI apps wrote before. Run when the user asks to set up, fill in, import into, or sync their Context, or right after connecting a new AI app.

Supa-Media/context · 52 tokens