功能对比
| Skill example | Best for | Typical files | Starter tools |
|---|---|---|---|
| code-review-skill | Review diffs for bugs, regressions, missing tests, and risk | .claude/skills/code-review-skill/SKILL.md | Read, Grep, Glob, Bash(git diff *) |
| test-writer-skill | Create or update focused tests after behavior changes | .claude/skills/test-writer-skill/SKILL.md | Read, Grep, Glob, Edit, Bash(npm test *) |
| migration-planner-skill | Plan framework, package, database, or API migrations | .claude/skills/migration-planner-skill/SKILL.md | Read, Grep, Glob |
| docs-updater-skill | Update docs, changelogs, onboarding notes, and release text | .claude/skills/docs-updater-skill/SKILL.md | Read, Grep, Glob, Edit |
| mcp-config-review-skill | Review MCP server configs, token boundaries, and install commands | .claude/skills/mcp-config-review-skill/SKILL.md | Read, Grep, Glob |
| seo-research-skill | Summarize search data, SERP notes, and page briefs | .claude/skills/seo-research-skill/SKILL.md | Read, WebSearch, Grep |
| frontend-polish-skill | Audit UI changes for responsive layout, states, and accessibility | .claude/skills/frontend-polish-skill/SKILL.md | Read, Grep, Glob, Bash(npm run build *) |
What Claude Code Skills Are
Claude Code skills are reusable instruction bundles that Claude can load when a task matches the skill. A skill usually starts with a SKILL.md file and can include supporting references, scripts, assets, or templates when the workflow is bigger than a single prompt.
- Use project-scoped skills for workflows that belong to one repository.
- Use personal skills for workflows you reuse across projects.
- Keep the skill description specific so Claude chooses it only when relevant.
- Prefer stable process guidance over temporary task notes.
Keyword Evidence And Priority
Latest logged-in Semrush Keyword Overview data makes claude code skills the primary page in this cluster. The page should anchor related hooks, commands, MCP, and SEO workflow content.
- claude code skills: US Volume 6.6K, KD 29%, CPC $10.87.
- Global Volume is 17.7K with informational intent.
- Keyword ideas count is 1.3K and competition is 0.05.
- Use Semrush MCP for Claude Code as a commercial-intent supporting page, not the main volume page.
Installation And Config Patterns
A small project skill can live directly in the repository. More complex skills can include references, scripts, or templates beside SKILL.md. After adding or editing skills, reload the Claude Code session so the new instructions are available.
.claude/
skills/
code-review-skill/
SKILL.md
mcp-config-review-skill/
SKILL.md
references/
mcp-security-checklist.md
templates/
review-output.md
# Personal skills commonly live under:
~/.claude/skills/<skill-name>/SKILL.md
# After edits, reload skills or restart Claude Code.Hooks Versus Commands Versus Skills
Choose the extension surface by timing and complexity. Hooks run automatically, commands are manually triggered, and skills are reusable knowledge/workflow bundles that can be selected for relevant tasks.
- Use hooks for deterministic lifecycle actions such as lint after edits or guardrails before tool use.
- Use slash or custom commands when a developer explicitly wants to trigger a short workflow.
- Use skills when the workflow needs richer instructions, supporting files, examples, or reuse across tasks.
- Use plugins when a team wants to package skills, commands, hooks, agents, and MCP servers together.
Skill Template Generator
Use the generator below to create a starter SKILL.md. Keep it short at first: name the trigger, define the workflow, list allowed context, and specify output and validation.
A good SKILL.md includes: - Clear name and description - When to use the skill - Inputs and context to inspect - Step-by-step workflow - Output format - Safety and validation notes
Security Notes
Skills can make powerful workflows easier to repeat, so review them like developer infrastructure. The skill should not include secrets, broad destructive commands, private tokens, or instructions to bypass approvals.
- Never commit API keys, passwords, tokens, or private customer data in SKILL.md.
- Keep Bash permissions narrow when the skill references shell commands.
- Document when a human must approve write actions, network calls, database access, or deployments.
- Review project skills when commands, package managers, CI checks, or MCP server access changes.
Team Rollout Checklist
Treat the first skill as a pilot. Use one repeated workflow, run it on a real task, collect review feedback, then decide whether to add supporting references or scripts.
[ ] Pick one repeated workflow. [ ] Create .claude/skills/<name>/SKILL.md. [ ] Add only stable instructions and safe examples. [ ] Reload Claude Code and test on one real task. [ ] Compare output quality and review comments. [ ] Add owner, review cadence, and validation command. [ ] Link the skill from CLAUDE.md or team docs.
Official And Community Sources
Start with official Claude Code docs, then use community repos and discussions to find workflow ideas. Do not copy a community skill into a team repo until you have reviewed permissions, commands, and data handling.
--- name: code-review-skill description: Review diffs for correctness, regressions, missing tests, and security risks. --- # code-review-skill Use this skill when the task matches: Review diffs for correctness, regressions, missing tests, and security risks. ## Workflow 1. Confirm the user request and the expected output. 2. Inspect only the files, docs, or sources needed for the workflow. 3. Explain the smallest useful plan before broad edits. 4. Apply focused changes or produce the requested brief. 5. Validate the result and summarize remaining risks. ## Allowed Context - Repo instructions such as CLAUDE.md or AGENTS.md. - Relevant source files, docs, tests, and command output. - External sources only when the task requires current facts. ## Suggested Tools Read, Grep, Glob, Bash(git diff *) ## Output Format - Findings or result first. - Files changed or sources consulted. - Validation performed. - Open questions or residual risks. ## Safety - Do not expose secrets, tokens, credentials, private customer data, or billing IDs. - Do not run destructive commands without explicit human approval. - Keep network, database, and deployment actions behind documented approval boundaries. ## Validation Run or request the most relevant test, lint, or typecheck command before handoff. ## Supporting Files - references/checklist.md: detailed review checklist. - templates/output.md: expected response format.
常见问题
What are Claude Code skills?
Claude Code skills are reusable instruction bundles, usually centered on a SKILL.md file, that help Claude run a repeatable workflow with the right context and output format.
Where do Claude Code skills live?
Project skills commonly live under .claude/skills/<name>/SKILL.md, while personal skills commonly live under ~/.claude/skills/<name>/SKILL.md.
When should I use a skill instead of a custom command?
Use a skill when the workflow needs richer instructions, supporting files, examples, or reuse across tasks. Use a custom command for a short human-triggered shortcut.
When should I use hooks instead of skills?
Use hooks for deterministic lifecycle automation such as linting after edits or blocking risky tool use. Use skills for reusable reasoning and workflow guidance.
Can skills include scripts or templates?
Yes. Complex skills can include supporting files such as references, scripts, templates, or assets, but those files should be reviewed and kept free of secrets.
What is the current Semrush data for claude code skills?
The latest logged-in Semrush Keyword Overview backend data provided for this page shows US Volume 6.6K, KD 29%, CPC $10.87, Global Volume 17.7K, informational intent, 1.3K keyword ideas, and competition 0.05.