Communitygithub.com

skill-stocktake

用于审核 Claude 技能和命令质量的审计工具。支持快速扫描(仅检查有变更的技能)和全量盘点两种模式,并通过顺序子代理批量评估。

skill-stocktake 是什么?

skill-stocktake 是一个针对 Claude 技能和命令的审计命令(斜杠命令 `/skill-stocktake`)。它使用质量标准检查清单和 AI 综合判断来评估技能质量,分为快速扫描和全量盘点两种模式。快速扫描模式(5-10 分钟)仅重新评估自上次运行以来内容发生变化的技能,适合日常维护;全量盘点模式(20-30 分钟)则对全部技能进行完整评审,包括盘点清单、质量评估、总结表和整合阶段。该工具支持全局技能目录(`~/.claude/skills/`)和项目级技能目录(`{cwd}/.claude/skills/`),并会检测项目目录来决定扫描范围。评估结果以 JSON 格式缓存到 `~/.claude/skills/skill-stocktake/results.json`,支持断点续评。核心功能是利用 AI 子代理对每个技能逐一进行质量检查,给出保留、改进、更新、淘汰或合并至某技能的 verdict,并附带详细理由。该工具不区分技能来源(ECC、自创、自动提取),对所有技能使用统一标准。

兼容平台✓Claude Code~Codex CLI~Cursor
npx skills add https://github.com/affaan-m/ECC/tree/main/skills/skill-stocktake

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

skill-stocktake 是做什么的?

斜杠命令(/skill-stocktake),使用质量检查清单和 AI 综合判断来审计所有 Claude 技能和命令。支持两种模式:快速扫描(仅检查近期变更的技能)和全量盘点(完整审查所有技能)。

范围

该命令针对 调用所在目录的相对路径 下的文件:

路径描述
~/.claude/skills/全局技能(所有项目)
{cwd}/.claude/skills/项目级技能(如果该目录存在)

在第一阶段开始时,命令会明确列出已找到并扫描的路径。

针对特定项目

要包含项目级技能,请从项目根目录运行:

cd ~/path/to/my-project
/skill-stocktake

如果项目没有 .claude/skills/ 目录,则仅评估全局技能和命令。

模式

模式触发条件耗时
快速扫描results.json 存在(默认)5–10 分钟
全量盘点results.json 不存在,或 /skill-stocktake full20–30 分钟

结果缓存: ~/.claude/skills/skill-stocktake/results.json

快速扫描流程

只重新评估自上次运行以来发生变化的技能(5–10 分钟)。

  1. 读取 ~/.claude/skills/skill-stocktake/results.json
  2. 运行:bash ~/.claude/skills/skill-stocktake/scripts/quick-diff.sh \ ~/.claude/skills/skill-stocktake/results.json (项目目录从 $PWD/.claude/skills 自动检测;仅在需要时显式传入)
  3. 如果输出为 []:报告“自上次运行以来无变更。”并停止
  4. 仅使用相同的第二阶段标准重新评估那些变更过的文件
  5. 保留之前结果中未变更的技能
  6. 仅输出差异
  7. 运行:bash ~/.claude/skills/skill-stocktake/scripts/save-results.sh \ ~/.claude/skills/skill-stocktake/results.json <<< "$EVAL_RESULTS"

全量盘点流程

第一阶段 — 盘点

运行:bash ~/.claude/skills/skill-stocktake/scripts/scan.sh

该脚本枚举技能文件,提取前置元数据,并收集 UTC 修改时间。 项目目录从 $PWD/.claude/skills 自动检测;仅在需要时显式传入。 从脚本输出中展示扫描摘要和盘点表:

扫描中:
  ✓ ~/.claude/skills/         (17 个文件)
  ✗ {cwd}/.claude/skills/    (未找到 — 仅全局技能)
技能7天使用30天使用描述

第二阶段 — 质量评估

使用完整的盘点和检查清单启动一个 Agent 工具子代理(通用型代理):

Agent(
  subagent_type="general-purpose",
  prompt="
请对照以下检查清单评估给出的技能盘点表。

[盘点表]

[检查清单]

为每个技能返回 JSON:
{ "verdict": "Keep"|"Improve"|"Update"|"Retire"|"Merge into [X]", "reason": "..." }
"
)

子代理读取每个技能,应用检查清单,并为每个技能返回 JSON:

{ "verdict": "保留"|"改进"|"更新"|"淘汰"|"合并至 [X]", "reason": "..." }

分块指导: 每次子代理调用处理约 20 个技能,以保持上下文可管理。每处理完一个块后,将中间结果保存到 results.json(status: "in_progress")。

所有技能评估完成后:设置 status: "completed",进入第三阶段。

断点续评检测: 如果在启动时发现 status: "in_progress",则从第一个未评估的技能继续。

每个技能都对照以下检查清单进行评估:

- [ ] 已检查与其他技能的内容重叠
- [ ] 已检查与 MEMORY.md / CLAUDE.md 的重叠
- [ ] 已检查技术引用的时效性(如果存在工具名称 / CLI 标志 / API,则使用 WebSearch)
- [ ] 已考虑使用频率

判定标准:

判定含义
保留有用且符合当前情况
改进值得保留,但需要特定的改进
更新引用的技术已过时(使用 WebSearch 验证)
淘汰质量低、过时或性价比不对称
合并至 [X]与另一个技能有大量重叠;指出合并目标

评估基于 AI 综合判断 —— 而非数字评分。指导维度:

  • 可操作性:提供代码示例、命令或步骤,使你能立即行动
  • 范围匹配:名称、触发条件和内容一致;不过宽或过窄
  • 独特性:价值不能被 MEMORY.md / CLAUDE.md / 其他技能替代
  • 时效性:技术引用在当前环境下能正常工作

理由质量要求 —— reason 字段必须内容完整且支持决策:

  • 不要仅写“未变更”——始终重申核心依据
  • 对于 淘汰:说明(1)发现了什么具体缺陷,(2)什么替代方案能满足相同需求
    • 错误:"已被取代"
    • 正确:"disable-model-invocation: true 已设置;已被 continuous-learning-v2 取代,该技能覆盖所有相同模式并增加了置信度评分。没有保留任何独特内容。"
  • 对于 合并:指出目标并描述要整合的内容
    • 错误:"与 X 重叠"
    • 正确:"42 行薄内容;chatlog-to-article 的步骤 4 已涵盖相同工作流。将'文章角度'技巧作为注释集成到该技能中。"
  • 对于 改进:描述所需的具体变更(哪个部分、什么操作、相关目标大小)
    • 错误:"太长"
    • 正确:"276 行;'Framework Comparison' 部分(第 80–140 行)与 ai-era-architecture-principles 重复;删除它以达到约 150 行。"
  • 对于 保留(快速扫描中仅 mtime 变更):重申原始判定的理由,不要写“未变更”
    • 错误:"未变更"
    • 正确:"mtime 已更新但内容未变。独特的 Python 引用,由 rules/python/ 显式导入;未发现重叠。"

第三阶段 — 总结表

技能7天使用判定理由

第四阶段 — 整合

  1. 淘汰 / 合并:在征得用户确认前,为每个文件提供详细的论证:
    • 发现了什么具体问题(重叠、过时、引用失效等)
    • 什么替代方案能覆盖相同功能(对于淘汰:哪个现有技能/规则;对于合并:目标文件以及要整合的内容)
    • 移除的影响(任何依赖的技能、MEMORY.md 引用或受影响的工作流)
  2. 改进:提供具体的改进建议并说明理由:
    • 要更改什么及原因(例如,“因为 X/Y 部分与 python-patterns 重复,将 430 行缩减至 200 行”)
    • 用户决定是否执行
  3. 更新:提供已更新内容,并附上已检查的来源
  4. 检查 MEMORY.md 行数;如果超过 100 行,建议压缩

结果文件结构

~/.claude/skills/skill-stocktake/results.json:

evaluated_at:必须设置为评估完成时的实际 UTC 时间。 通过 Bash 获取:date -u +%Y-%m-%dT%H:%M:%SZ。绝不使用仅日期的近似值,如 T00:00:00Z。

{
  "evaluated_at": "2026-02-21T10:00:00Z",
  "mode": "full",
  "batch_progress": {
    "total": 80,
    "evaluated": 80,
    "status": "completed"
  },
  "skills": {
    "skill-name": {
      "path": "~/.claude/skills/skill-name/SKILL.md",
      "verdict": "Keep",
      "reason": "Concrete, actionable, unique value for X workflow",
      "mtime": "2026-01-15T08:30:00Z"
    }
  }
}

备注

  • 评估是无偏见的:无论技能来源(ECC、自创、自动提取),均使用相同的检查清单
  • 存档/删除操作总是需要用户显式确认
  • 不根据技能来源进行判定分支

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

accessibility

Design, implement, and audit inclusive digital products using WCAG 2.2 Level AA. Use when building or auditing UI that must meet WCAG 2.2 Level AA, or when reviewing a change for keyboard, contrast, or screen-reader support.

affaan-m/content-engine

Create platform-native content systems for X, LinkedIn, TikTok, YouTube, newsletters, and repurposed multi-platform campaigns. Use when the user wants social posts, threads, scripts, content calendars, or one source asset adapted cleanly across platforms.

affaan-m/ECC

Multi-platform content distribution across X, LinkedIn, Threads, and Bluesky. Adapts content per platform using content-engine patterns. Never posts identical content cross-platform. Use when the user wants to distribute content across social platforms.

affaan-m/fal-ai-media

Unified media generation via fal.ai MCP — image, video, and audio. Covers text-to-image (Nano Banana), text/image-to-video (Seedance, Kling, Veo 3), text-to-speech (CSM-1B), and video-to-audio (ThinkSound). Use when the user wants to generate images, videos, or audio with AI.

affaan-m/manim-video

日本語翻訳:このファイルは manim-video 用の日本語翻訳が必要です

affaan-m/remotion-video-creation

Remotion のベストプラクティス - React で動画を作成する。3D、アニメーション、音声、字幕、チャート、トランジションなどをカバーするドメイン固有の29のルール。

affaan-m/video-editing

AI-assisted video editing workflows for cutting, structuring, and augmenting real footage. Covers the full pipeline from raw capture through FFmpeg, Remotion, ElevenLabs, fal.ai, and final polish in Descript or CapCut. Use when the user wants to edit video, cut footage, create vlogs, or build video content.

agent-architecture-audit

Full-stack diagnostic for agent and LLM applications. Audits the 12-layer agent stack for wrapper regression, memory pollution, tool discipline failures, hidden repair loops, and rendering corruption. Produces severity-ranked findings with code-first fixes. Essential for developers building agent applications, autonomous loops, or any LLM-powered feature. Use when an agent or LLM feature misbehaves and the failing layer is unknown, or before shipping an agent stack.

agent-eval

Head-to-head comparison of coding agents (Claude Code, Aider, Codex, etc.) on custom tasks with pass rate, cost, time, and consistency metrics. Use when choosing between coding agents, or when a change to an agent setup needs measured pass rate, cost, and time rather than an impression.

agent-harness-construction

Design and optimize AI agent action spaces, tool definitions, and observation formatting for higher completion rates. Use when defining or revising an agent

agentic-engineering

Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing. Use when planning or executing engineering work that agents will carry out end to end.

agentic-os

Build persistent multi-agent operating systems on Claude Code. Covers kernel architecture, specialist agents, slash commands, file-based memory, scheduled automation, and state management without external databases. Use when building a persistent multi-agent system on Claude Code with its own memory, commands, and scheduling.

agent-introspection-debugging

Structured self-debugging workflow for AI agent failures using capture, diagnosis, contained recovery, and introspection reports. Use when an agent run fails and you need a reproducible diagnosis instead of a retry.

agent-payment-x402

Add x402 payment execution to AI agents with per-task budgets, spending controls, and non-custodial wallets. Supports Base through agentwallet-sdk and X Layer through OKX Payments / OKX Agent Payments Protocol. Use when an agent must pay for something itself and needs per-task budgets, spending controls, and a non-custodial wallet.

agent-self-evaluation

Use after completing any non-trivial task. The agent self-rates its output on 5 axes — accuracy, completeness, clarity, actionability, conciseness — with concrete evidence per criterion. Produces a structured 1-5 scorecard with specific improvement suggestions.

agent-sort

Build an evidence-backed ECC install plan for a specific repo by sorting skills, commands, rules, hooks, and extras into DAILY vs LIBRARY buckets using parallel repo-aware review passes. Use when ECC should be trimmed to what a project actually needs instead of loading the full bundle.

ai-first-engineering

Engineering operating model for teams where AI agents generate a large share of implementation output. Use when setting team process, review gates, or ownership rules for a codebase largely written by agents.

ai-regression-testing

Regression testing strategies for AI-assisted development. Sandbox-mode API testing without database dependencies, automated bug-check workflows, and patterns to catch AI blind spots where the same model writes and reviews code. Use when adding regression coverage to AI-assisted code, or when the same model both wrote and reviewed a change.

android-clean-architecture

Clean Architecture patterns for Android and Kotlin Multiplatform projects — module structure, dependency rules, UseCases, Repositories, and data layer patterns. Use when structuring modules, layers, or data flow in an Android or KMP project.

angular-developer

Generates Angular code and provides architectural guidance. Trigger when creating projects, components, or services, or for best practices on reactivity (signals, linkedSignal, resource), forms, dependency injection, routing, SSR, accessibility (ARIA), animations, styling (component styles, Tailwind CSS), testing, or CLI tooling.

相关技能