by ReflexioAI
A Claude Code plugin that makes Claude Code self-improve — learning from your corrections, not just remembering them (also support codex now)
# Add to your Claude Code skills
git clone https://github.com/ReflexioAI/claude-smartMost memory tools just record. Claude remembers what happened, but doesn't change what it does next.
claude-smart focuses on learning instead.
Four things this changes:
💡 Stop repeating the same mistakes: Produces actionable skills Claude can follow next time; memory only records what happened.
Example: a deploy fails after Claude bumps
prismafrom 5.x to 6.0; you tell it to roll back because 6.0 breaks nested writes in your order flow. Memory: “deploy broke after prisma bump; user rolled back” Learning: “treat major-version bumps of ORMs/DB drivers as breaking — verify with integration tests, not just unit tests”
🚀 Start from the optimized path: Records and optimizes the steps that worked so Claude can reuse them, instead of re-exploring each session.
Example: Claude spends several iterations trying to start the local dev environment before discovering that this repo requires
pnpm dev:allinstead of the usualnpm run dev. Memory: “user mentioned thatnpm run devdid not work” Learning: “for this repo, always usepnpm dev:allto start the full local stack —npm run devonly starts the frontend and causes missing service errors”
Instead of re-exploring, Claude Code starts from the proven path—reducing planning steps, latency, and token usage.
🌐 Project-specific and shared skills: Session memory disappears with the conversation. Project-specific skills preserve repo-local rules, while shared skills roll up patterns that should transfer across projects. Preferences stay scoped to the current project so per-repo preferences don't leak across projects.
No comments yet. Be the first to share your thoughts!
🪶 Better context without prompt bloat: Distilled, deduplicated skills stay in dozens of tokens—not thousands—even as the project grows.
npx claude-smart install # or: uvx claude-smart install
Then restart Claude Code.
Requires Node.js (for npx) or uv (for uvx) to already exist.
Alternatively, install via Claude Code's plugin marketplace:
claude plugin marketplace add ReflexioAI/claude-smart
claude plugin install claude-smart@reflexioai
To uninstall:
npx claude-smart uninstall # or: uvx claude-smart uninstall
Or, if installed via the plugin marketplace:
claude plugin uninstall claude-smart@reflexioai
npx claude-smart install --host codex
Then fully quit and reopen Codex so hooks reload.
Requires the codex CLI on PATH and Node.js (for npx).
To uninstall:
npx claude-smart uninstall --host codex
Restart Codex after uninstalling. Learned data under ~/.reflexio/ and ~/.claude-smart/ is preserved and shared with Claude Code, so you can switch between hosts without losing skills or preferences.
Developing the plugin itself? See DEVELOPER.md for what the installer does, manual toggles via /plugins, and clone-based development.
Not supported: Claude Code Cowork, claude.ai/code web, or remote Codex environments without local plugin hooks — they run outside your local machine, so the local backend/dashboard and
~/.reflexio/aren't reachable.
| Platform | Status | Notes | | --- | --- | --- | | Apple Silicon macOS 14+ | Supported | Runtime bootstrap installs private Node/npm, uv, Python 3.12 deps, and dashboard deps. | | Windows x64 | Supported | Runtime bootstrap uses PowerShell for uv/Node archive extraction and patches Codex hooks to the Node wrapper. | | Linux | Supported when host hooks are local | Existing Linux behavior is preserved; install coverage depends on available Python wheels. | | Intel Mac, macOS 13 or older, Windows ARM | Not supported | Current local embedding/ML dependencies do not publish a complete native wheel set for these targets. |
Network access is required during first install for npm, PyPI/uv, Node.js, and
the first local embedding model download. The ONNX model cache lives at
~/.cache/chroma/onnx_models/all-MiniLM-L6-v2/.
e.g. correct the same
npm test --rungotcha twice → consolidated into one rule. New evidence shows it applies tovitesttoo → scope broadened. Switch policy topnpm test→ old rule archived, new one supersedes it.
~/.reflexio/ and ~/.claude-smart/)./claude-smart:learn in Claude Code, or bash ~/.reflexio/plugin-root/scripts/cli.sh learn in Codex, flags the last turn as a correction so the extractor weights it heavily.A web UI for browsing session histories, inspecting preferences, and editing project-specific and shared skills. The dashboard auto-starts alongside the backend, so you can open http://localhost:3001 directly. Or run /claude-smart:dashboard in Claude Code to open it in your browser. In Codex, run bash ~/.reflexio/plugin-root/scripts/dashboard-open.sh.
claude-smart builds three artifacts as you work and injects the relevant ones into Claude Code or Codex:
--run to npm test — watch mode hangs CI."Skills clean themselves up: correct the same thing twice and they merge; change your mind and the old one is archived.
Under the hood: hooks watch your turns, tool calls, and assistant replies, auto-flagging corrections (or anything you flag with /claude-smart:learn). At session end (or on /claude-smart:learn), reflexio — the self-improving engine that powers claude-smart — extracts preferences and project-specific skills, then rolls durable patterns into shared skills. On each new user prompt, claude-smart searches for matching context and injects only the relevant hits. Run /claude-smart:show or the equivalent CLI command to audit the current learned state. Everything runs on your machine.
Citations. At the end of a reply, the assistant may append a short marker:
✨ 2 claude-smart learnings applied [cs:s1-252,p1-5aed]
That signals a preference (p…) or skill (s…) materially shaped the reply.
Open the session's detail page in the dashboard to see the exact cited item.
See ARCHITECTURE.md for hooks, data flow, and reflexio details.