Claude Memory Compiler — Evolving Knowledge Base
Auto-capture Claude Code sessions into a structured knowledge base. Hooks extract decisions and lessons, compiler organizes into cross-referenced articles. No vector DB needed. 365+ stars.
Installation avec revue préalable
Cet actif nécessite une revue. Le prompt copié demande un dry-run, affiche les écritures, puis continue seulement après confirmation.
npx -y tokrepo@latest install 4388e2e8-33ce-11f1-9bc6-00163e2b0d79 --target codexDry-run d'abord, confirmez les écritures, puis lancez cette commande.
What it is
Claude Memory Compiler automatically captures decisions, patterns, and lessons from your Claude Code sessions and compiles them into a structured knowledge base. Hooks run after each session to extract noteworthy information, and a compiler step organizes everything into cross-referenced articles. The result is an evolving wiki that grows as you work, without requiring a vector database or external infrastructure.
This tool targets developers who use Claude Code daily and want to build institutional memory from their AI-assisted coding sessions. Teams that lose context between sessions or across team members benefit most.
How it saves time or tokens
Without persistent memory, developers re-explain context to Claude Code every session, wasting tokens on repetition. Claude Memory Compiler eliminates this by surfacing past decisions and patterns automatically. The structured output means you can reference previous solutions directly instead of re-deriving them, cutting both token consumption and debugging time.
How to use
- Clone the repository and install dependencies
- Configure hooks to run after Claude Code sessions
- Run the compiler to organize captured knowledge into cross-referenced articles
Example
git clone https://github.com/anthropics/claude-memory-compiler.git
cd claude-memory-compiler
npm install
# Configure hooks
npm run setup-hooks
# After working sessions, compile knowledge
npm run compile
# Browse your knowledge base
npm run serve
Related on TokRepo
- AI memory tools — Compare memory solutions for AI agents
- AI coding tools — Browse developer-focused AI tools
Common pitfalls
- The compiler works best with frequent, focused sessions rather than marathon coding sprints that mix unrelated topics
- Knowledge articles need occasional manual curation to merge duplicates and correct misclassifications
- Hook configuration must match your Claude Code setup; incorrect paths cause silent failures
Questions fréquentes
No. The system uses structured markdown articles with cross-references and full-text search. There is no dependency on a vector database, embedding model, or external search infrastructure.
Hooks run after Claude Code sessions to extract decisions, patterns, and lessons from the conversation. The compiler then organizes these extractions into structured articles with cross-references to related topics.
Yes. The knowledge base is stored as files that can be committed to a shared Git repository. Team members compile their sessions into the same base, building collective institutional memory.
Growth depends on session frequency and content. The compiler deduplicates and merges related topics, so the knowledge base grows in depth rather than unbounded breadth. Periodic curation keeps it manageable.
The hooks are designed for Claude Code sessions. Adapting them to other tools requires modifying the extraction logic to match that tool's session format and output structure.
Sources citées (3)
- Claude Memory Compiler GitHub— Hooks extract decisions and lessons from Claude Code sessions
- Anthropic Documentation— Structured knowledge base without vector database dependency
- Claude Code Overview— Cross-referenced article compilation from session data
En lien sur TokRepo
Source et remerciements
Created by Cole Medin. Licensed under open source.
claude-memory-compiler — ⭐ 365+
Thanks to Cole Medin for building a practical memory system for Claude Code power users.
Fil de discussion
Actifs similaires
pbi-cli — Power BI Skills for Claude Code
pbi-cli is a Python CLI that installs Claude Code skills for Power BI models and PBIR reports. Get started with pipx + `skills install`.
Multi-Platform Social Media Growth Skill for Developer Communities
Production-tested Claude Code skill for automating authentic developer engagement across 10+ platforms (Twitter, Bluesky, Dev.to, HN, Reddit, GitHub, Product Hunt, Hashnode, Medium, Quora). Includes rotation queue, per-platform cooldowns, action diversity rules, Chrome MCP toolchain with JS injection patterns, anti-ban safety, and continuous optimization framework. Battle-tested across 30+ cycles.
Ollama Model Library — Best AI Models for Local Use
Curated guide to the best models available on Ollama for coding, chat, and reasoning. Compare Llama, Mistral, Gemma, Phi, and Qwen models for local AI development.
Graphify — Repo Knowledge Graph + MCP
Graphify extracts docs/code into a knowledge graph and can install as an MCP/skill across Claude Code, Cursor, Codex, and Gemini CLI. Install via uv/pipx.