Skip to content
Skill

memory

by zoubingwu

AI Summary

Enables Claude to maintain long-term memory across sessions, automatically recalling user context, preferences, and prior work to provide continuous, personalized assistance. Essential for developers who need stateful AI interactions across multiple conversations.

Install

Copy this and paste it into Claude Code, Cursor, or any AI assistant:

I want to install the "memory" skill in my project.

Please run this command in my terminal:
# Install skill into the correct directory (2 files)
mkdir -p .claude/skills/memory && curl --retry 3 --retry-delay 2 --retry-all-errors -o .claude/skills/memory/SKILL.md "https://raw.githubusercontent.com/zoubingwu/memory-skill/master/memory/SKILL.md" && mkdir -p .claude/skills/memory/scripts && curl --retry 3 --retry-delay 2 --retry-all-errors -o .claude/skills/memory/scripts/memory.sh "https://raw.githubusercontent.com/zoubingwu/memory-skill/master/memory/scripts/memory.sh"

Then restart Claude Code (or reload the window in Cursor) so the skill is picked up.

Description

Long-term memory across sessions. Always use memory_search at the start of any user request (unless the user explicitly says not to), especially for questions about the user (profile/personal info/preferences), prior constraints or decisions, and resuming ongoing work; use memory_write only when the user explicitly asks to store memory.

Overview

• Provide two functions: memory_write and memory_search. • Store memory in a single append-only JSONL file (one JSON object per line). • Search a recent tail window first; only expand the window if needed.

Requirements

• Depend on standard unix tools: bash, touch, tail, rg (ripgrep), jq. • Provide fallbacks: if rg missing, use grep; if jq missing, fail with a clear error. • Make sure commands are safe with arbitrary user text (proper quoting). • Ensure the skill returns structured JSON to the agent, not raw text logs. • Require bash and jq; use rg or grep, tail, date, printf, and touch. • Allow tools: Bash(date:) Bash(jq:) Bash(printf:) Bash(touch:) Bash(tail:) Bash(rg:) Bash(grep:*)

Recall context

Run memory_search at the start of every task unless the user explicitly says not to.

Persist knowledge

Run memory_write only when the user explicitly asks to store memory, and only for stable, reusable information.

Discussion

0/2000
Loading comments...

Health Signals

MaintenanceCommitted 3mo ago
Stale
AdoptionUnder 100 stars
22 ★ · Niche
DocsREADME + description
Well-documented

GitHub Signals

Stars22
Forks1
Issues0
Updated3mo ago
View on GitHub
No License

My Fox Den

Community Rating

Sign in to rate this booster

Works With

Claude Code