PlugWiki

forget Skill (agentmemory) for Claude Code: Delete Memories

Deletes saved memories from agentmemory after you confirm the list it shows, for anyone who needs to scrub a note or private data.

Installs
14.2K
on skills.sh
Stars
30.1K
on GitHub
Files
2
besides SKILL.md
Updated
Oct 2026
last repo commit

forget is the delete command of the agentmemory plugin. You type /forget with a search term, and Claude searches saved memories, shows you the matches with secret values redacted, and asks for a clear yes. Only then does it delete them by memory ID.

The skill calls deletion "destructive and irreversible". It covers saved memories only. It does not erase observations or whole sessions, and lessons are deleted with a separate tool. It bundles no scripts and needs the agentmemory server and its MCP tools.

Good for

  • Anyone who saved something by mistake, such as a key or a wrong fact
  • Developers cleaning private data out of project memory
  • Users of the remember skill who want an undo

Install forget

Claude Code

  1. 1

    Copy this prompt.

    Install the forget skill in Claude Code. Run this command:
    
    npx -y @agentmemory/agentmemory@latest
    
    Then check that it loaded and tell me how to use it.
  2. 2

    Paste it into Claude Code. It shows the change and asks before running it.

Requires Node.js 20 or newer.

This skill only works when the memory server is running and the agentmemory MCP tools are connected. The plugin route is the one the README recommends for Claude Code. The skills-only route installs all 17 skills but does not connect the MCP tools by itself. Pick one route, not both.

From the project README. Source.

What's in the skill

When it loads

Delete selected durable memories from agentmemory after showing them and getting explicit confirmation. Use when the user says "forget this", "delete memory", "remove that note", or wants to scrub specific data for privacy.

Sections in SKILL.md

  1. Quick start
  2. Why
  3. Workflow
  4. Anti-patterns
  5. Checklist
  6. See also
  7. Troubleshooting

Key facts

Author
rohitg00
Installs on skills.sh
14,155 as of 2026-11-02
Last repo commit
2026-10-29

What it includes

  • Slash command that starts a guarded delete

    Takes a session ID, file path or search term as the argument and starts by searching, not deleting.

    Try: “/forget the old api key in config”

    Delete · /forget [what to forget]

  • Finds candidate memories, limit 20, memory layer

    Searches saved memories only. The skill says these are relevance matches, not a full inventory.

    Network · memory_smart_search

  • Shows IDs, titles and scope, then waits for a clear yes

    Secret values are redacted in the list. Silence or a vague "sure, whatever" does not count as confirmation.

    Confirm first

  • Deletes the confirmed memories by ID

    Takes memoryIds as a comma-separated string and an optional reason. It works on memory IDs, never a bare session ID.

    Delete · memory_governance_delete

  • Deletes a lesson by its lessonId

    Lessons are separate. The memory delete tool does not touch them.

    Delete · memory_lesson_delete

  • Reports deleted, notFound and failed counts

    States the real number deleted and lists unresolved IDs separately. It rechecks IDs before retrying a failed request.

    Read · Check the result

  • Does not erase observations or whole sessions

    The skill explains this before proceeding and never calls a memory deletion a complete session wipe.

    Stated limit

From the official docs

Permissions

Medium risk

What it can do

  • Read your data
  • Create and change things
  • Delete things
  • Read-only mode

Watch out for

  • The plugin records your sessions through hooks

    The README lists captured data: user prompts (privacy-filtered), tool name, input and output, errors, and the assistant reply of each turn. Review what is stored in the viewer, and use the forget skill to remove entries. github.com

  • Installing starts a local server and runs npm code

    The setup command pulls the latest package with npx and starts a background server. On macOS and Linux it also needs curl, sh and tar for automatic runtime setup. github.com

  • It permanently deletes saved memories

    The skill calls deletion irreversible and relies on you confirming the list. Read the IDs and titles before you answer yes. github.com

  • Saved memories flow back into later sessions

    plugin.json says the plugin injects context into future sessions. In the hook scripts, SessionStart and PreToolUse inject context only when AGENTMEMORY_INJECT_CONTEXT=true, as the README also says. The PreCompact script asks the server for context before each compaction with a default budget of 1500 and prints it as hook output; AGENTMEMORY_PRE_COMPACT_BUDGET=0 turns that off. Our advice: avoid saving text you do not trust, because the assistant reads it back. github.com

Security advisories

No published security advisories as of Nov 2, 2026.

Technical details
Turning on read-onlyNo read-only switch is documented for these skills.
Talks toThe server and viewer bind to loopback (127.0.0.1) by default. Compression or embeddings with a provider you configure use that provider. Local semantic search downloads an embedding model on first use if you set EMBEDDING_PROVIDER=local
Sign-in and keysA local server creates a random secret at ~/.agentmemory/secret with mode 0600 and the bundled clients read it. A remote server needs AGENTMEMORY_SECRET in your environment.
Data retentionMemories are stored on your machine in the agentmemory data folder until you delete them. The README says API keys, bearer tokens and <private> tags are stripped before storage.
Scopes
  • The Claude Code plugin registers 12 hooks that run node scripts on events such as every prompt, every tool call and the end of each turn

  • The plugin ships a .mcp.json that starts a node bridge to the local memory server

  • Setup runs npx -y @agentmemory/agentmemory@latest, writes config to ~/.agentmemory and starts a server on localhost:3111

  • If the MCP tools are missing, the skill's TROUBLESHOOTING.md tells the assistant to call the REST API on the daemon directly with a bearer secret, read from AGENTMEMORY_SECRET or, for loopback URLs, from ~/.agentmemory/.env and ~/.agentmemory/secret

Questions

What does the forget skill do?

It finds saved memories that match your text, shows them, and deletes the ones you confirm. It is the undo for the remember skill.

How do I install forget?

Use the install box at the top of this page. Start the agentmemory server first, then add the plugin. The skill calls tools the server provides, so the folder alone does nothing.

Can I get a deleted memory back?

The skill says deletion is irreversible. It shows exactly what will be deleted and asks for an explicit yes first.

Does it erase a whole session?

No. It deletes selected saved memories by ID. Observation or whole-session erasure is not supported by this operation, and lessons need a separate tool.

Will it delete without asking?

The skill says it must not. It lists the matches, waits for an explicit yes, and only then calls the delete tool. That rule is an instruction to the assistant, so check the list yourself before you confirm.

Is forget safe?

It can permanently delete memories, so read the list before you say yes. The setup around it is also larger than the skill: the plugin adds hooks that record sessions and runs a local server. See the safety section on this page.

Information

updated Nov 2, 2026

Folder
plugin/skills/forget

rohitg00/agentmemoryskills.sh

Sources

Docs, issue trackers and discussions this page is built from.

Show all 10
  1. rohitg00/agentmemory README · github.com
  2. skills CLI commands · github.com
  3. forget SKILL.md · github.com
  4. plugin hooks.json · github.com
  5. plugin .mcp.json · github.com
  6. plugin.json · github.com
  7. Shared TROUBLESHOOTING.md · github.com
  8. pre-compact.mjs · github.com
  9. TROUBLESHOOTING.md · github.com
  10. session-start.mjs · github.com

Updated Nov 2, 2026.