skill-activate
v0.1.4
Published
Improve Claude Code skill activation reliability with one command.
Maintainers
Readme
skill-activate
Star the repo: https://github.com/realsahilsaini/skill-activate
Claude Code can miss relevant skills when responding to prompts.
skill-activate installs a forced-eval hook and rewrites skill descriptions so Claude evaluates and activates relevant skills before every response.
One-line install
npx skill-activate installRevert to original state anytime:
npx skill-activate uninstallFollow development and contribute: https://github.com/realsahilsaini/skill-activate
Reliability impact
- Before: skill activation can be inconsistent for relevant prompts.
- After install: prompts are forced through explicit skill evaluation and activation before implementation.
How it works
- Rewrites each skill
descriptioninto a directive format with clear triggers and a hard activation instruction. - Installs a
UserPromptSubmithook that injects a mandatory evaluation-and-activation sequence before every prompt. - Patches Claude settings safely and idempotently, then validates everything with a readable report.
Commands
| Command | What it does |
| --- | --- |
| npx skill-activate install | Full setup: rewrite descriptions, install hook, patch settings, validate |
| npx skill-activate scan | Detect and list installed SKILL.md files only |
| npx skill-activate uninstall | Remove hook wiring and restore all .bak files under skills |
| npx skill-activate status | Verify if hook is present and correctly wired |
How this works under the hood
skill-activate uses Claude Code's UserPromptSubmit lifecycle hook to prepend a mandatory instruction block on each user message. That block forces Claude to:
- Evaluate each available skill (
YESorNOwith reason) - Activate every
YESskill throughSkill()immediately - Only then continue with implementation
Reference: Anthropic Claude Code hooks docs: https://docs.anthropic.com/en/docs/claude-code/hooks
Output example
skill-activate setup report
───────────────────────────────────────
✓ Claude Code detected at ~/.claude
✓ Hook installed: ~/.claude/hooks/skill-forced-eval-hook.sh (executable)
✓ settings.json patched (UserPromptSubmit wired)
✓ 3 skills found and descriptions rewritten:
→ express-skill.md
→ mongoose-skill.md
→ jwt-auth-skill.md
✓ Backups saved as .bak files
Activation consistency improved with forced-eval hook.
───────────────────────────────────────
Restart Claude Code to apply changes.Development
npm install
npm test
node bin/cli.js installHow to contribute
- Fork the repo and create a feature branch.
- Run tests locally (
npm test) before opening a PR. - Add or update tests for behavior changes.
- Keep changes local-only (no external API dependencies).
- Open a PR with a clear before/after summary.
If this helped you, please star and watch the repo for updates:
- Star: https://github.com/realsahilsaini/skill-activate/stargazers
- Watch: https://github.com/realsahilsaini/skill-activate/watchers
- Issues: https://github.com/realsahilsaini/skill-activate/issues
Compatibility
- Node.js 18+
- macOS and Linux (native shell hook execution)
- Windows with WSL for shell hook execution
Troubleshooting
- Error:
Unknown skill: ...: This usually means the skill id was normalized (for example,algorithmic-artchanged toalgorithmic art). Re-runnpx skill-activate@latest installto apply the newest compatibility behavior. Version0.1.2+automatically creates compatibility aliases for hyphenated and underscored skill ids.
License
MIT
