create-memory

Create memory.md with a standard header and entries section when missing.

1|Updated Feb 3, 2026
One-click install
npx skills add https://github.com/adamrdrew/claude-code-patterns --skill create-memory-adamrdrew
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: create-memory
Source: https://github.com/adamrdrew/claude-code-patterns/tree/main/skill-discovery/.claude/skills/create-memory
Command: npx skills add https://github.com/adamrdrew/claude-code-patterns --skill create-memory-adamrdrew

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Memory persistence is often missing or uninitialized, causing loss of context across sessions. This skill creates memory.md if it doesn't exist and guarantees that existing memory is not overwritten.

Core Features & Use Cases

  • Idempotent initialization: creates memory.md only when missing and never overwrites existing content.
  • Structured memory: provides a standard Memory header and an entries section for future key-value pairs.
  • Simple adoption: enables agents to store and retrieve small context data across runs.

Quick Start

Run the skill in your project directory to create memory.md if it does not exist.

Frequently Asked Questions about create-memory

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I initialize persistent memory for an AI agent across sessions?

To initialize persistent memory across agent sessions, you need a file that survives between runs. This skill creates a memory.md file with a standard header and entries section, establishing a structured store when one is missing.

What is the best way to create a memory file without overwriting existing data?

The best way to create a memory file without losing data is through idempotent initialization. This skill safely creates memory.md only when it is missing and guarantees that existing memory content is never overwritten.

How does a Markdown memory file structure work for storing agent context?

A Markdown memory file structure works by providing a standard Memory header and an entries section. This format enables straightforward read and write operations for small context data and key-value pairs across future runs.

Can I use an idempotent memory initialization script in any project workspace?

Yes, you can use idempotent memory initialization in any project workspace. The process applies across any directory where memory must persist across agent sessions, requiring no specific dependencies or components to function.

Why does my AI agent lose context data between different runs?

Your AI agent loses context data between runs because memory persistence is often missing or uninitialized. Creating a persistent memory.md file ensures small context data is stored and retrieved successfully across future sessions.

When do I need to initialize a persistent memory store for automation workflows?

You need to initialize a persistent memory store when your automation workflows must retain context across sessions. This skill creates a structured Markdown file to capture key-value entries if no memory file currently exists in the workspace.