Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
ropl-btc avatar

Persistent Memory

  • 753 installs
  • 1 repo stars
  • Updated July 29, 2026
  • ropl-btc/agent-skills

persistent-memory is an agent skill that maintains a single persistent memory layer with a local CLI so coding agents can reliably read and write durable preferences and facts across an entire workspace.

About

persistent-memory is a ropl-btc/agent-skills workflow that becomes the single memory system for a repository, covering task-start recall, explicit remember instructions, and retrieval of prior context. Agents run python3 .agents/skills/persistent-memory/scripts/memory.py or the pmem shortcut for commands including init, sync, cleanup-legacy, backfill, search, add, and recent plus stats. Developers adopt persistent-memory when agents otherwise lose preferences, decisions, and facts between sessions. The skill is marked ALWAYS USE for persistent memory handling in the workspace it is installed in, centralizing init and health checks instead of ad hoc note files.

  • Single authoritative memory system for the entire repository
  • 8 supported CLI commands including init, sync, search, add, recent, stats, prune and backfill-embeddings
  • Required workflow enforces sync → search before substantial tasks and add on explicit remember instructions
  • Handles task-start memory recall, durable preferences, and learned facts
  • One-time migration commands for cleanup-legacy and backfill-embeddings --batch 500

Persistent Memory by the numbers

  • 753 all-time installs (skills.sh)
  • Ranked #1,367 of 16,546 AI & Agent Building skills by installs in the Skillselion catalog
  • Security screen: MEDIUM risk (skills.sh audit)
  • Data as of Jul 29, 2026 (Skillselion catalog sync)
npx skills add https://github.com/ropl-btc/agent-skills --skill persistent-memory

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs753
repo stars1
Security audit3 / 3 scanners passed
Last updatedJuly 29, 2026
Repositoryropl-btc/agent-skills

How do agents persist memory across coding sessions?

Maintain a single persistent memory layer that agents can reliably read from and write to across an entire workspace.

Who is it for?

Teams running long-horizon coding agents in one repo who need a single CLI-backed memory store instead of scattered markdown notes.

Skip if: One-shot chat tasks with no cross-session context or teams already standardized on an external vector database without local agent integration.

When should I use this skill?

The user says remember, asks to recall prior context, starts a task needing memory, or requests init, sync, search, add, or recent memory operations.

What you get

Initialized memory database, synced memory store, and searchable recalled facts via pmem or memory.py commands.

  • Initialized memory database
  • Searchable stored facts and preferences

Files

SKILL.mdMarkdownGitHub ↗

Persistent Memory

Use this skill as the single memory system for this repository.

Commands

Use either command style:

  • python3 .agents/skills/persistent-memory/scripts/memory.py <command>
  • .agents/skills/persistent-memory/scripts/pmem <command>

Supported commands:

  • init
  • sync (database-only health check)
  • cleanup-legacy
  • backfill-embeddings --batch 500
  • prune --source "<label>" [--older-than <days>]
  • search "<query>" --limit 8
  • add "<memory text>" --tags "<comma,tags>" --source "assistant"
  • recent --limit 10
  • stats

Required Workflow

1. Initialize memory in a fresh workspace:

  • pmem init

2. At the start of substantial tasks:

  • pmem sync (database-only health check)
  • pmem search "<topic keywords>" --limit 8

3. When user explicitly says remember or when a durable preference/fact is learned:

  • pmem add "<memory text>" --tags "<tags>" --source "assistant"

4. Before finalizing memory-sensitive work, verify recall state:

  • pmem stats

One-Time Migration (If Upgrading From Older Setup)

1. Remove legacy imported rows:

  • pmem cleanup-legacy

2. Generate vectors for existing notes:

  • pmem backfill-embeddings

Storage Rules

  • Store durable preferences, long-lived facts, stable workflows, and repeated constraints.
  • Do not store noisy one-off transient details unless requested.
  • Keep entries concise and specific.
  • Prefer tags that improve retrieval quality (preferences, calendar, comms, product).

Retrieval Rules

  • Use targeted search queries instead of broad terms.
  • Keep default --limit low unless deeper recall is needed.
  • search automatically reinforces recalled entries by updating hits and last_seen_at.
  • hits are analytics-oriented and not used as a direct ranking boost.
  • Search uses hybrid retrieval: lexical + semantic.
  • Semantic search tries sqlite-vec first and auto-falls back to Python cosine if needed.

Bootstrapping and Recovery

  • If .memory/ is missing, run pmem init.
  • pmem sync is a lightweight database-only check (no markdown import/export).
  • If semantic mode degrades, run pmem stats to inspect semantic_backend and embedding_coverage.
  • For command examples and quick troubleshooting, read references/usage.md.

Related skills

FAQ

Which commands does persistent-memory provide?

persistent-memory provides pmem and python3 memory.py commands including init, sync, cleanup-legacy, backfill, search, add, recent, and stats for managing a single local agent memory database in the workspace.

When must agents use persistent-memory?

persistent-memory is marked ALWAYS USE when handling persistent memory in the workspace, including task-start recall, explicit remember instructions, storing durable preferences, and retrieving prior context.

Is Persistent Memory safe to install?

skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

AI & Agent Buildingagentsautomation

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.