Enforce structural and organizational conventions across the entire skill library: folder naming, required files, category consistency, cross-reference depth, guide skill completeness, and index sync. Auto-trigger after skill-maker, skill-edit, or skill-index-sync completes. Trigger when: check skill library, library lint, validate library, audit library structure, skill 庫有沒有問題, 檢查 skill 庫結構, skill library 結構檢查. Do not trigger for auditing a single skill (use skill-audit) or modifying a skill (use skill-edit).
Scans the entire skill library for structural violations and auto-fixes safe issues; flags destructive actions for user confirmation.
Validate and repair the structural integrity of the skill library by enforcing naming conventions, required files, category consistency, cross-reference depth, guide skill completeness, and index sync.
Apply automatically after skill-maker, skill-edit, or skill-index-sync completes. Also trigger when:
Do NOT trigger for:
skill-auditskill-editskill-index-sync<library-root>/<category>/<name>/Scan all category folders — for every <category>/<name>/ folder, check all items in the Structural Rules table below; record each failure with folder path and evidence. Skills with format: github-imported in frontmatter are exempt from S5–S13 (body section checks) — still enforce S1–S4, S14, S15, S16
Check cross-reference depth — for every SKILL.md, find all markdown links; verify no link points to a file that itself links to another file (max one level deep from SKILL.md); flag any chain deeper than one level
Check guide skill completeness — verify each category has exactly one <category>-guide/SKILL.md; flag categories with zero guides or more than one guide
Check index sync — compare the actual skill inventory against all four index artifacts:
| Artifact | What to verify |
|---|---|
<category>/_index.md | Every skill in the category has a row; no rows for non-existent skills |
_index.md (root) | Every category is listed; skill counts match reality |
README.md | Every skill appears in the correct category table |
CLAUDE.md | Every category row's skill list matches the actual folder contents |
Compile the Audit Report — output all findings in the format below; group by check type; count total failures per type
Apply safe auto-fixes — without user confirmation, fix: missing rows in _index.md files, README.md, and CLAUDE.md; do not touch SKILL.md files or move/delete folders
Confirm destructive fixes — for any finding that requires moving a folder, deleting a file, or renaming a skill: list the exact action and wait for explicit user approval before executing
Re-run all checks (Steps 1–4) — repeat the fix → re-run loop until all checks pass; do not declare DONE while any failure remains
File path: none (report printed to user)
## Skill Library Lint Report
### 衝突問題
| Skill A | Skill B | 衝突類型 | 說明 |
|---------|---------|---------|------|
| new-skill | debug | 觸發詞重疊 | 兩者均響應 "find the bug" |
(無衝突時輸出:✓ 無衝突問題)
### 重複問題
| Skill | 重複對象 | 說明 | 建議 |
|-------|---------|------|------|
| new-skill | existing-skill | Purpose 描述相同操作 | 合併或縮小範圍 |
(無重複時輸出:✓ 無重複問題)
### 資安問題
| Path | 問題 | 嚴重度 | 修復方式 |
|------|------|-------|---------|
| dev/deploy-ops/SKILL.md | Step 3 執行 shell 指令但未要求使用者確認 | HIGH | 加入確認步驟 |
| meta/skill-maker/SKILL.md | allowed-tools 欄位不合法 | MEDIUM | 移至 Rules/Never |
(無問題時輸出:✓ 無資安問題)
### 其他問題
| Path | 問題 | 嚴重度 | 修復方式 | 是否自動修復 |
|------|------|-------|---------|------------|
| dev/CodeReview/ | 資料夾名稱含大寫 | HIGH | 重命名為 code-review/ | 需確認 |
| ops/deploy/ | 缺少 SKILL.md | HIGH | 建立或刪除空資料夾 | 需確認 |
| dev/_index.md | 缺少 deploy-check 項目 | LOW | 新增對應列 | ✓ 自動修復 |
| ops-guide | category ops 缺少 guide skill | HIGH | 建立 ops-guide/ | 需確認 |
(無問題時輸出:✓ 無其他問題)
### 總結
衝突:0 重複:0 資安:2 其他:4
自動修復:1(index 列) 待確認:3(資料夾操作)
### 判定
[ ] PASS — 庫結構完整
[x] FAIL — 自動修復後仍有 5 項待處理
_index.md, README.md, CLAUDE.md) — never auto-modify SKILL.md or move folders## Skill Library Lint Report
### 衝突問題
✓ 無衝突問題
### 重複問題
✓ 無重複問題
### 資安問題
✓ 無資安問題
### 其他問題
✓ 無其他問題
### 總結
衝突:0 重複:0 資安:0 其他:0
自動修復:0 待確認:0
### 判定
[x] PASS — 庫結構完整
I checked the skill library and everything looks fine.
The folder names seem correct and the index files are probably up to date.
Why this is bad: No checklist items run — any structural violation would go undetected. "Seems correct" and "probably up to date" are not verifiable verdicts. No evidence cited. No distinction between auto-fixed and user-confirmation-required issues. User cannot trust this report.