Claude Reflect — How It Works
Two-Stage Architecture
Stage 1: Automatic Capture (via Hooks) Claude Reflect installs hooks that monitor your Claude Code sessions in real-time. When you make a correction — phrases like "no, use X instead", "actually, do Y", "don't do that" — the system detects it using a combination of:
- Regex patterns — Fast, real-time detection of common correction phrases
- Semantic AI validation — Accurate interpretation across any language
Corrections are queued silently without interrupting your workflow.
Stage 2: Review & Sync (via Commands)
| Command | Purpose |
|---|---|
/reflect |
Review queued corrections, approve/reject, sync to CLAUDE.md |
/reflect-skills |
Analyze session history for repeating patterns |
/reflect --dedupe |
Consolidate duplicate or similar learnings |
/reflect --scan-history |
Recover corrections from past sessions |
Key Features
Permanent Memory
Approved corrections sync to CLAUDE.md at three levels:
- Global (
~/.claude/CLAUDE.md) — Applies to all projects - Project (
.claude/CLAUDE.md) — Project-specific preferences - Skills (
.claude/skills/) — Domain-specific knowledge
Multi-Language Support
The semantic AI detector understands corrections in any language — English, Chinese, Japanese, etc. No configuration needed.
Duplicate Detection
When a new correction is similar to an existing one, Claude Reflect offers to:
- Merge — Combine related learnings
- Replace — Update with newer preference
- Skip — Keep existing, discard new
Workflow Pattern Discovery
/reflect-skills uses AI reasoning to find semantic similarities across different phrasings in your session history. It suggests new reusable commands and skill files based on your actual usage patterns.
Example Workflow
You: Fix the login bug
Claude: [uses console.log for debugging]
You: No, always use the logger module, not console.log
→ Claude Reflect captures: "User prefers logger module over console.log"
→ You run /reflect, approve it
→ Added to CLAUDE.md: "Always use the logger module for debugging, never console.log"
→ Claude remembers this in all future sessionsRequirements
- Claude Code
- Python 3.6+
- macOS, Linux, or Windows
FAQ
Q: What is Claude Reflect? A: A Claude Code plugin that captures your corrections during development and syncs them to CLAUDE.md, making Claude remember your preferences across sessions and projects.
Q: Is Claude Reflect free? A: Yes, fully open-source under MIT license.
Q: Does it slow down Claude Code?
A: No. Corrections are captured asynchronously via lightweight hooks. The AI validation only runs when you invoke /reflect.