Skip to content
Development
Skill

/memem-mine

Opt in to memem's event-triggered mining. New sessions are mined automatically via the Stop hook.

From plugin
memem
326 skills4 hooks
Install
$ npx -y skills add TT-Wang/memem --skill memem-mine --agent claude-code

How it fires

How this skill gets triggered: by you, by Claude, or both.

  • Fires itselfAuto-invocation. Claude auto-loads it when your prompt matches the work.Auto-invocation is when the right skill fires by itself at the right moment, driven by a FLOW.md router and a hook, instead of you invoking it by name. It is the difference between a skill being installed and a skill actually getting used.Read the full definition →
  • You can call itInvoke it directly when you want it.
  • Slash command/memem-mine

Context preview

The summary Claude sees to decide when to auto-load this skill.

Opt in to memem's event-triggered mining. New sessions are mined automatically via the Stop hook.

SKILL.md

memem-mine.SKILL.md
name: memem-mine
description: Opt in to memem's event-triggered mining. New sessions are mined automatically via the Stop hook.
allowed-tools: [Bash]

Opt in to memem mining. In v2.1.0+ mining is event-triggered: it fires on every Claude Code Stop event when the opt-in marker exists. There is no daemon to start.

1. Create the opt-in marker:

mkdir -p ~/.memem && touch ~/.memem/.miner-opted-in

2. Tell the user:

  • Mining is now active — every Stop event spawns a detached `mine_delta` subprocess that extracts memories from new turns since the last invocation
  • Hook overhead is ~50ms; the Haiku call runs in background
  • Run `/memem-status` to check Stop-hook registration, opt-in marker, and last mine run
  • Safety net: SessionStart fires a stale-session sweep for any JSONLs > 10 min old not yet in `~/.memem/.mined_sessions` (catches sessions where Stop never fired)
  • To opt out: `rm ~/.memem/.miner-opted-in` (no daemon to stop — the hook just no-ops)

For backfilling pre-existing sessions, use `/memem-mine-history`.

Ships withmemem

Persistent, self-evolving memory for Claude Code. Stop re-explaining your project every session. <!-- The Glama badge URL below intentionally uses the legacy cortex-plugin slug.

Get the whole plugin
Stats
32
Stars
1
Forks
Active
Maintenance
Python
Language
MIT
License
13d ago
Last commit
5mo ago
Created

Repo: TT-Wang/memem

Other skills on memem.