Feature request: Built-in procedural memory / session learning

Resolved 💬 3 comments Opened Mar 30, 2026 by Ship-gate Closed Apr 3, 2026

Summary

Claude Code already stores session transcripts as JSONL, but never learns from them. Session 100 makes the same wrong-file-first mistakes as session 1. There's a community package — claude-conscious — that demonstrates this is solvable today with the existing transcript format and hook system.

What it does

A 4-stage offline pipeline: parse transcripts into decision graphs, extract anti-patterns and convergence patterns, synthesize confidence-scored strategies, and inject a CLAUDE_STRATEGIES.md (~4K tokens) that Claude Code reads on session start. It hooks into the existing Stop hook to auto-refresh after each session.

The result: the agent gets a pre-mortem before every session predicting what it's likely to get wrong (scope creep, wrong file first, overengineering), a cognitive fingerprint of its reasoning tendencies, and per-project file heatmaps of what it usually needs to touch.

Why this should be native

  • The transcript data already exists (~/.claude/projects/)
  • The hook system already exists
  • The gap between "has memory" and "has skill" is exactly what's missing
  • 2 dependencies, ~1700 lines of compiled JS — lightweight enough to integrate
  • The community package works today across 150+ sessions with measurable pattern extraction

Proposal

Consider building procedural memory as a first-class feature — even a minimal version (anti-pattern extraction + file heatmaps) would meaningfully improve agent performance over time.

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗