用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
直接命令不会经过审查 Prompt;运行前请先检查来源。
npx skills add https://github.com/htlin222/dotfiles --skill add-skill命令会保持在同一行。复制前请横向滚动并检查完整内容。
想先保存到本地?可下载 SkillsMP 当前能够提供的文件。
正在显示 SKILL.md
| name | add-skill |
| description | Create new Claude Code skills with proper structure. Use when adding a skill or slash command. |
Create properly structured Claude Code skills from user requirements.
For rapid creation, user can provide all info at once:
/add-skill name=my-skill purpose="Does X" trigger="when user asks for Y"
Parse and generate without interactive prompts.
Always fetch official docs first to ensure compliance with current spec:
WebFetch: https://code.claude.com/docs/en/skills
Prompt: Extract skill file format, required fields, naming rules, and best practices
If WebFetch fails, fallback:
WebSearch: "Claude Code skills SKILL.md format site:code.claude.com"
Ask user (or parse from quick mode):
~/.claude/skills/{skill-name}/ (available in all projects).claude/skills/{skill-name}/ (only this repo, committed with code)processing-pdfs, testing-code){base-path}/skills/{skill-name}/
├── SKILL.md # Required: Main instructions (<500 lines)
├── scripts/ # Optional: Executable code
│ └── main.py
└── references/ # Optional: Detailed docs (one level deep)
└── examples.md
---
name: {skill-name}
description: {What it does in third person}. Use when {trigger conditions}.
---
# {Skill Title}
{Brief overview - assume Claude is smart, only add context it doesn't already have}
## Quick Start
{Minimal working example or first step}
## Instructions
{Step-by-step guidance with appropriate freedom level}
## Advanced Features
**Feature A**: See [references/feature-a.md](references/feature-a.md)
After drafting SKILL.md, count its lines. If approaching or exceeding 500 lines:
references/{topic}.md — one level deep onlyRun through the validation checklist before finalizing.
ls -la ~/.claude/skills/{skill-name}/
cat ~/.claude/skills/{skill-name}/SKILL.md
Test with: claude --debug to check for loading errors.
processing-pdfs, testing-code, writing-documentationpdf-processing, process-pdfs-, consecutive --, reserved words (anthropic, claude), XML tagshelper, utils, tools), overly generic (documents, data)Good:
description: Extracts text and tables from PDF files, fills forms, merges documents. Use when working with PDF files or when the user mentions PDFs, forms, or document extraction.
Bad: "Helps with documents", "Processes data", "Does stuff with files"
Challenge each piece of information:
| Freedom | Use When | Example |
|---|---|---|
| High (text instructions) | Multiple valid approaches | Code review guidelines |
| Medium (pseudocode/params) | Preferred pattern exists | Report generation template |
| Low (exact scripts) | Fragile operations, consistency critical | Database migrations |
Pick one term and use it throughout. Don't mix "API endpoint" / "URL" / "API route".
For complex multi-step operations, provide a copyable checklist.
Run validator → fix errors → repeat until passing.
Guide through decision points: Creating new? → "Creation workflow" / Editing existing? → "Editing workflow"
script.py" (execute) vs "See script.py" (reference)ServerName:tool_name<details> tag for old patterns基于 SOC 职业分类