|
| 1 | +# Repo Skill Review |
| 2 | + |
| 3 | +## Purpose |
| 4 | + |
| 5 | +Use this reference when the task is to review a repository-managed skill collection such as `config/source/skills/` for quality, redundancy, trigger overlap, structure issues, or weak behavioral guidance. |
| 6 | + |
| 7 | +This review mode is based on: |
| 8 | + |
| 9 | +- Claude skill best practices: [Skill authoring best practices](https://platform.claude.com/docs/en/agents-and-tools/agent-skills/best-practices) |
| 10 | +- Datawhale skill write-up: [如何写出好的 Skill](https://github.com/datawhalechina/hello-agents/blob/main/Extra-Chapter/Extra08-%E5%A6%82%E4%BD%95%E5%86%99%E5%87%BA%E5%A5%BD%E7%9A%84Skill.md) |
| 11 | +- Trae guide: [如何写好一个 Skill:从创建到迭代的最佳实践](https://docs.trae.cn/ide/best-practice-for-how-to-write-a-good-skill) |
| 12 | + |
| 13 | +## When to use this reference |
| 14 | + |
| 15 | +Use it when the user asks to: |
| 16 | + |
| 17 | +- check the quality of `config/source/skills` |
| 18 | +- find redundant or overlapping skills |
| 19 | +- review whether skill descriptions are too broad or vague |
| 20 | +- inspect whether `SKILL.md` files are too heavy and should be split |
| 21 | +- evaluate whether repo-managed skills follow good authoring practice |
| 22 | + |
| 23 | +## Review Scope |
| 24 | + |
| 25 | +Treat the audit as four linked checks: |
| 26 | + |
| 27 | +1. Trigger quality |
| 28 | +2. Boundary clarity |
| 29 | +3. Structure and progressive disclosure |
| 30 | +4. Collection hygiene |
| 31 | + |
| 32 | +Do not stop at "this skill feels weak." The output should identify which dimension failed and what to rewrite. |
| 33 | + |
| 34 | +## Core Principles |
| 35 | + |
| 36 | +### 1. Description is the trigger surface |
| 37 | + |
| 38 | +`description` should explain both: |
| 39 | + |
| 40 | +- what the skill does |
| 41 | +- when it should be used |
| 42 | + |
| 43 | +For collection reviews, this means checking whether neighboring skills use distinguishable trigger language. |
| 44 | + |
| 45 | +Smells: |
| 46 | + |
| 47 | +- descriptions like "helps with X" |
| 48 | +- missing task or context cues |
| 49 | +- broad verbs shared across too many skills |
| 50 | +- synonyms stuffed into one skill without a clear boundary |
| 51 | + |
| 52 | +### 2. Write for the agent, not for humans |
| 53 | + |
| 54 | +Review `SKILL.md` for operational behavior, not team-facing prose. |
| 55 | + |
| 56 | +Smells: |
| 57 | + |
| 58 | +- background history |
| 59 | +- version history / changelog notes |
| 60 | +- README-style onboarding text |
| 61 | +- values or principles without actionable behavior |
| 62 | + |
| 63 | +Prefer instructions that change what the agent does after trigger. |
| 64 | + |
| 65 | +### 3. Keep only high-value context in the main file |
| 66 | + |
| 67 | +The main `SKILL.md` should stay concise and behavior-first. |
| 68 | + |
| 69 | +Check for: |
| 70 | + |
| 71 | +- repeated explanations the model likely already knows |
| 72 | +- long tutorials in the main file |
| 73 | +- deep detail that belongs in `references/` |
| 74 | +- repeated manual procedures that should become `scripts/` |
| 75 | + |
| 76 | +### 4. Progressive disclosure should be explicit |
| 77 | + |
| 78 | +`SKILL.md` should route the agent to the right reference file at the right time. |
| 79 | + |
| 80 | +Smells: |
| 81 | + |
| 82 | +- many reference files with no reading order |
| 83 | +- nested references that require reading references from references |
| 84 | +- no scenario-to-reference routing |
| 85 | +- heavy context loading by default |
| 86 | + |
| 87 | +### 5. Neighboring skills must stay distinct |
| 88 | + |
| 89 | +For repo-level audits, always compare the target skill against its nearest neighbors. |
| 90 | + |
| 91 | +Typical overlap patterns in `config/source/skills`: |
| 92 | + |
| 93 | +- platform vs domain skill overlap |
| 94 | +- auth entry skill vs platform-specific auth skill overlap |
| 95 | +- web vs mini program vs nodejs database skill overlap |
| 96 | +- "design/spec/review" skills that all claim broad planning or evaluation verbs |
| 97 | + |
| 98 | +If two skills share the same likely prompts, the review should explain whether to: |
| 99 | + |
| 100 | +- tighten one description |
| 101 | +- add non-applicable cases |
| 102 | +- move shared detail into a reference |
| 103 | +- merge the skills |
| 104 | +- split one skill by platform or mode |
| 105 | + |
| 106 | +## Repo Audit Workflow |
| 107 | + |
| 108 | +### Step 1: Build the inventory |
| 109 | + |
| 110 | +1. List all candidate skills under `config/source/skills/` |
| 111 | +2. Read the target `SKILL.md` files first |
| 112 | +3. Group nearby skills by domain, platform, or user intent |
| 113 | + |
| 114 | +Useful groupings: |
| 115 | + |
| 116 | +- auth |
| 117 | +- database |
| 118 | +- frontend / UI |
| 119 | +- deployment / runtime |
| 120 | +- planning / review |
| 121 | +- AI model usage |
| 122 | + |
| 123 | +### Step 2: Check frontmatter quality |
| 124 | + |
| 125 | +For each skill, ask: |
| 126 | + |
| 127 | +- Is the `name` short, stable, and specific? |
| 128 | +- Does the `description` describe both capability and trigger condition? |
| 129 | +- Would the description still be understandable without reading the body? |
| 130 | +- Is the wording in third-person / neutral instruction style rather than "I can help..."? |
| 131 | +- Does it overclaim scenarios already covered by a neighbor? |
| 132 | + |
| 133 | +### Step 3: Check body quality |
| 134 | + |
| 135 | +Ask: |
| 136 | + |
| 137 | +- Does the main file tell the agent what to do first? |
| 138 | +- Are non-applicable scenarios explicit? |
| 139 | +- Is the routing table present and useful? |
| 140 | +- Is behavior specific enough for fragile tasks? |
| 141 | +- Is the file acting like an execution guide rather than a general article? |
| 142 | + |
| 143 | +### Step 4: Check structure quality |
| 144 | + |
| 145 | +Ask: |
| 146 | + |
| 147 | +- Should some sections move into `references/`? |
| 148 | +- Are there scripts that would make fragile or repeated operations safer? |
| 149 | +- Are references one level deep from `SKILL.md`? |
| 150 | +- Do long reference files need a table of contents? |
| 151 | + |
| 152 | +### Step 5: Check overlap and redundancy |
| 153 | + |
| 154 | +Compare neighboring skills for: |
| 155 | + |
| 156 | +- same nouns + same verbs in `description` |
| 157 | +- duplicated workflow steps in `SKILL.md` |
| 158 | +- repeated examples that could live in one place |
| 159 | +- multiple skills routing to the same scenario without differentiation |
| 160 | + |
| 161 | +Mark each overlap as one of: |
| 162 | + |
| 163 | +- acceptable overlap |
| 164 | +- mild redundancy |
| 165 | +- trigger conflict |
| 166 | +- merge candidate |
| 167 | +- split candidate |
| 168 | + |
| 169 | +### Step 6: Design evaluation prompts |
| 170 | + |
| 171 | +For any skill that may be too broad or too narrow, create: |
| 172 | + |
| 173 | +- at least 3 should-trigger prompts |
| 174 | +- at least 3 should-not-trigger prompts |
| 175 | +- 1 closest-neighbor comparison |
| 176 | + |
| 177 | +Collection audits should include cross-skill prompts such as: |
| 178 | + |
| 179 | +- "Should this trigger `auth-tool` or `auth-web`?" |
| 180 | +- "Should this trigger `web-development` or `ui-design`?" |
| 181 | +- "Should this trigger `http-api` or `cloud-functions`?" |
| 182 | + |
| 183 | +## Findings Format |
| 184 | + |
| 185 | +When reporting the audit, prefer review-style findings ordered by severity. |
| 186 | + |
| 187 | +For each finding, include: |
| 188 | + |
| 189 | +- affected skill file(s) |
| 190 | +- issue type: trigger / boundary / structure / redundancy |
| 191 | +- why it matters |
| 192 | +- the smallest useful rewrite direction |
| 193 | + |
| 194 | +Example labels: |
| 195 | + |
| 196 | +- `[P1] Trigger wording overlaps with sibling skill` |
| 197 | +- `[P2] Main SKILL.md contains reference-grade detail` |
| 198 | +- `[P2] Missing non-applicable cases causes false positives` |
| 199 | +- `[P3] Duplicate examples should move to shared reference` |
| 200 | + |
| 201 | +## Rewrite Guidance |
| 202 | + |
| 203 | +Use these rewrite moves first: |
| 204 | + |
| 205 | +1. Tighten `description` |
| 206 | +2. Add "Do NOT use for" cases |
| 207 | +3. Make routing scenario-based |
| 208 | +4. Move detail from `SKILL.md` to `references/` |
| 209 | +5. Replace repeated manual instructions with `scripts/` |
| 210 | +6. Split by platform or mode only when boundary tightening is not enough |
| 211 | + |
| 212 | +## Collection Pass Criteria |
| 213 | + |
| 214 | +A repo skill collection is in good shape when: |
| 215 | + |
| 216 | +- each skill has a distinct job and nearest-neighbor boundary |
| 217 | +- descriptions are specific enough to drive correct triggering |
| 218 | +- `SKILL.md` files are concise and behavior-first |
| 219 | +- reference loading is explicit and shallow |
| 220 | +- repeated logic is minimized |
| 221 | +- audit findings can be explained with concrete file evidence |
0 commit comments