By jim80net
Memex skill/memory/rule router — semantic context injection via embedding similarity
Extract learnings from past session transcripts and create appropriately-typed skills. Processes unreviewed sessions to find user preferences, recurring patterns, and troublesome workflows.
Diagnose and fix memex installation, setup, or runtime problems. Run checks on the binary, config, hooks, cache, model, and scan paths.
Create a comprehensive continuation plan so a fresh session can pick up exactly where this one left off — with full operational detail, not summaries.
Show how to use memex: what it does, how to create skills/rules/memories, available commands, current status, and troubleshooting.
Instructions for creating and managing memories in memex format (injected in takeover mode)
Matches all tools
Hooks run on every tool call, not just specific ones
Own this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimOwn this plugin?
Verify ownership to unlock analytics, metadata editing, and a verified badge. GitHub access is read-only (username + org membership).
Sign in to claimBased on adoption, maintenance, documentation, and repository signals. Not a security audit or endorsement.
Semantic skill, memory, and rule router for Claude Code. Injects relevant knowledge into your session based on what you're actually working on, instead of loading everything at once.
Built on @jim80net/memex-core — the shared engine for embedding, indexing, and searching knowledge artifacts.
AI coding assistants are essentially paint-by-number systems. You start with a canvas (the model) and a system prompt (the outline of the picture). Then you add your own directives — CLAUDE.md, MEMORY.md, rules — which are like adding more lines to the coloring book before you begin.
This works well at first. But as you accumulate knowledge — git workflows, ticket tracking conventions, deployment procedures, coding standards, domain-specific patterns — the coloring page gets crowded. Every session starts with all of this context loaded, whether it's relevant or not. The LLM's attention is split across git rules when you're debugging CSS, and deployment procedures when you're writing tests. Performance degrades as the corpus grows.
The solution is gradual disclosure: start with universal principles only, then bring in additional directives at the point of consumption, when the conversation actually turns toward those specific tasks. When you need to trade a ticker, the relevant know-how appears. When you're deploying, the deployment checklist surfaces. When you're just writing code, nothing extra clutters the context.
This is what memex-claude does. As skills, memories, and rules are created, they are embedded for semantic retrieval. Each type has a disclosure pattern suited to its nature:
SKILL.md when Claude chooses to use it, which may in turn reference other documents and scripts.The result is a system that drives the conversation according to the task at hand. Performance stays consistent even as learnings amass, because the context window carries only what's needed right now.
To manage the growing corpus, two bundled skills handle the lifecycle: /sleep organizes and migrates memories into semantically-searchable skills, while /deep-sleep trawls past conversations to extract recurring patterns and preferences. Together, the system learns from how you work, builds a corpus of guidelines, and interjects them at the right moments — becoming more intuitive over time.
User prompt → embed (local ONNX) → cosine similarity against skill index → inject top matches
┌─────────────────────────────────────────────────────┐
│ @jim80net/memex-core │
│ SkillIndex ←→ Cache (~/.claude/cache/memex-cache…) │
│ embeddings (local ONNX via all-MiniLM-L6-v2) │
│ cosineSimilarity, mtime-based rebuild │
└──────────┬──────────────┬───────────────┬───────────┘
│ │ │
┌──────▼──────┐ ┌────▼─────┐ ┌──────▼──────┐
│ UserPrompt │ │ Stop │ │ PreToolUse │
│ Submit │ │ │ │ │
│ Match query │ │ Behavioral│ │ Match tool- │
│ → inject │ │ rules │ │ specific │
│ skills + │ │ │ │ guidance │
│ memories + │ │ │ │ │
│ rules │ │ │ │ │
└─────────────┘ └──────────┘ └─────────────┘
| Type | First match | Subsequent | Matched on |
|---|---|---|---|
rule | Full content | One-liner reminder | UserPromptSubmit |
memory | Full content | Full content | UserPromptSubmit |
skill | Description teaser | Full (via Read) | UserPromptSubmit |
workflow | Description teaser | Full (via Read) | UserPromptSubmit |
tool-guidance | Full content | Full content | PreToolUse |
session-learning | Full content | Full content | UserPromptSubmit |
stop-rule | Behavioral rules for Stop hook | — | Stop |
boost — An optional frontmatter field (boost: 0.05) that nudges an entry's similarity score, useful for skills near the match threshold.queryHits tracks which specific queries triggered matches, enabling data-driven query refinement during /sleep.bestQueryIndex, identifying which query in the entry's queries list was the strongest match.The router indexes knowledge from three locations, each at global and project scope:
npx claudepluginhub jim80net/memex-claude --plugin memex-claudePCRE2 regex-based permission gatekeeper for Claude Code tool calls
Skill memory layer for Claude Code — auto-capture, learn, and reuse skills from Acontext
Curate auto-memory, promote learnings to CLAUDE.md and rules, extract proven patterns into reusable skills.
Persistent memory across sessions. Learns preferences, conventions, and corrections automatically.
I (Claude) act as you - Build knowledge base from your notes.
PowerMem intelligent memory for Claude Code: add, search, update, and delete memories with Ebbinghaus decay and multi-agent support.
Universal memory runtime — cross-session cognitive memory for Claude Code. Remembers decisions, patterns, and context across coding sessions.