Deep audit for installed ClawHub skills — usage analysis, permission review, conflict detection
安全
skill-usefulness-audit
试用审查已安装的 agent skill,给出实际使用、重叠与可清理候选,不自动删除。
它能做什么
按六层顺序审计已安装的 skill:使用证据、元数据与功能重叠、用户提供的 skill-on/off 结果、运行时与体积负担、静态健康与风险提示、可选的离线社区指标。随包脚本会把每个 skill 归类为 api、tool 或 general,并按评分细则计算 10 分制分数。输出包含一段可直接复制到对话的简短报告,以及可选的详细 Markdown 证据文件;删除、合并、隔离一律作为人工复核建议返回,不会自动执行。如有使用记录、历史消融结果、社区指标等文件,请通过 --usage-file、--history-file、--ablation-file、--community-file 一并传入;缺少时审计以仅结构模式运行,置信度相应降低。
什么时候用它
- 在切换模型上下文前找出长期未调用的 skill
- 判断两个功能相似的 skill 是否真的重叠到可以合并或下线
- 为通用型 skill 生成消融计划与成本估算
- 输出 Markdown 审计报告附在维护工单里
技能文档
Skill Usefulness Audit
Manual Trigger Only
Use this skill only after a direct request to audit installed agent skills, their usage, overlap, cleanup options, or a structure-only inventory. Do not invoke it during normal tasks or use it for ordinary repository/source-code review, general security audit, or employee/human skill assessment.
Safety
Never delete, merge, quarantine, isolate, or disable skills automatically.
Treat delete, merge-delete, and quarantine-review as manual-review recommendations.
Do not delete skills based only on a structure-only report.
This tool does not automatically replay historical conversations; it generates ablation plans and reads ablation result files that the user provides.
Audit Scope
Audit these layers in order:
- Usage evidence, including recency and source quality.
- Installed metadata, instructions, and functional overlap.
- User-provided skill-on versus skill-off results for general skills.
- Runtime and bundle burden, including over-triggering, context cost, weak progressive disclosure, redundant resources, script failures, and private-looking files.
- Static health and risk hints.
- Optional offline community or registry metrics.
Treat API and tool skills as protected capability skills during ablation. Examples: Excel, DOCX, PDF, browser automation, deployment, OCR, external API wrappers, MCP/API gateway helpers.
Workflow
- Collect user-provided roots before host-local defaults.
- Load only the usage, history, ablation, and community evidence that is available.
- Inspect each
SKILL.mdand its script/reference/asset metrics. - Let the bundled script classify each skill as
api,tool, orgeneraland calculate its score. Read{baseDir}/references/scoring-rubric.mdonly when checking or explaining a score, verdict, or action. - Print the short usefulness report and, when requested, write Markdown evidence or an ablation plan.
Ablation Rules
Read {baseDir}/references/ablation-protocol.md only when running replays, preparing normalized ablation records, or reviewing mixed or delete-boundary results. The script can generate an ablation plan without loading the protocol.
Replay only selected general candidates with identical prompts/artifacts and pairwise judging.
Do not fake no-tool ablation for api or tool skills; use the rubric's protected-capability branch.
Run the Audit
Run the audit after collecting available evidence:
REPORT_LANGUAGE=en # use zh-CN when the current user invocation is Chinese
python "{baseDir}/scripts/skill_usefulness_audit.py" audit \
--skills-root ./skills \
--report-language "$REPORT_LANGUAGE" \
--markdown-out ./skill-audit-report.md
OpenClaw expands {baseDir} to the installed skill directory. Use it for bundled scripts and references.
Add evidence only when available:
--usage-file: JSON, JSONL, CSV, or TSV with per-skill usage.--history-file: raw transcripts used only when direct usage is weak or missing; mentions remainhistory_mentions/suspected_invocations, notcalls.--ablation-file: normalized JSON or JSONL skill-on/skill-off results.--community-file: offline JSON, JSONL, CSV, or TSV registry metrics.--ablation-plan-out: a cost estimate and focused replay plan; its case counts can be overridden with the four--ablation-*-casesoptions documented by--help.--json-out: machine-readable evidence only when requested or needed by another tool.
Pass --report-language zh-CN for a Chinese invocation and --report-language en for an English invocation. auto reads SKILL_AUDIT_REPORT_LANGUAGE or the process locale, then falls back to English.
Run without extra files only when you need a structure-only audit. Usage, community, and ablation evidence become lower-confidence in that mode. History and usage files may contain sensitive conversations, local paths, project names, and customer data. Missing env means not configured in the current audit process, not proof that the skill is broken in every host.
Output Contract
Use one run for both output layers; do not ask the user to choose a quick or full mode.
Standard output is a short natural-language report. Its opening paragraph states the audited skill count and the total characters plus approximate tokens of loaded entry descriptions. Lead with actual usage, not static risk or bundle health, and keep scores, internal codes, risk flags, and tables out of this layer.
When --markdown-out is provided, write the detailed evidence—with scores, action codes, missing evidence, burden, and risk notes—in the same run.
Match the user's language: clean Chinese for zh-CN and clean English for en, except for skill names and unavoidable paths or commands.
Copy the short report to chat verbatim, apart from making its evidence path clickable. Do not paste raw JSON or the full Markdown evidence unless the user asks. Read {baseDir}/references/report-narration-prompt.md only when another agent or host must deliver an already-generated report.
JSON includes report_mode, per-skill score_breakdown, quality_penalty, quality_penalty_uncapped, quality_evidence, community_breakdown, action_advice, and risk_review. It includes ablation_plan only when --ablation-plan-out is used. JSON emits both risk_* and static_risk_* with identical values, and total_score as an alias of local_score; treat risk_* and local_score as canonical.
Keep deletion advice conservative for system or host-core skills, and prefer narrowing or merging when overlapping skills still serve distinct host integrations.
Resources
{baseDir}/scripts/skill_usefulness_audit.py: compatibility wrapper for the modular audit package.{baseDir}/scripts/skill_usefulness_audit_lib/: collect metadata, score skills, scan static risk hints, and render Markdown reports plus optional JSON artifacts.{baseDir}/references/report-narration-prompt.md: concise prompt for turning the report into a user-facing conversational summary.{baseDir}/references/scoring-rubric.md: 10-point scoring rules, confidence logic, community prior, and action thresholds.{baseDir}/references/ablation-protocol.md: normalized replay method for historical conversations.
常见问题
- 审计会自动删除或下线 skill 吗?
- 不会。删除、合并、隔离一律只作为人工复核建议返回,从不自动执行。
- 它会回放我过去的对话吗?
- 不会自动回放。它只读取你提供的消融结果文件,或由随包脚本生成消融计划。
- 为什么 api 和 tool 类 skill 要单独处理?
- 它们属于受保护能力类,例如 Excel、DOCX、PDF、浏览器自动化、部署、OCR、外部 API 封装、MCP/API 网关助手等,评分细则里有专门的处理分支。
相关技能
Generic skill-quality auditor for any agent skill (Claude, OpenClaw, Cursor, etc.). Runs a 7-dimension static analysis (D1 process closure & idempotency, D2 tool/command conventions, D3 portability & defense, D4 skill usability, D5 security & op risk, D6 code & doc quality, D7 dependency & footprint) with explicit ERR / WARN severity, 120-point scoring (pass line 90 + zero ERR), and an opt-in `--fix` workflow that always backs up first. Two depths: L1 static (~2 min) and L2 dryRun (~5 min, read-only hub + reachability checks). Strict red lines — read-only by default, never executes the audited skill's writes. Use when the user asks to "audit a skill", "check skill quality", "is this skill ready to ship", "lint my skill", or runs this tool by name. Triggers also: "审计这个 Skill"、"检查 Skill 质量"、"Skill 能上线吗"、 "skill-deep-audit"、"审一下 xxx skill"。
Automated security audit for AI agent skills. Use BEFORE installing any skill from ClawHub, GitHub, or other sources. Scans SKILL.md + all files for 30+ red...
Audit an upstream agent skill, SKILL.md, skill repository, or lifecycle workflow before adapting it for ClawHub, Codex, Claude Code, or a public Skool skill...
Audit a named ClawHub skill or skill URL before installation by combining OpenClaw verification with bounded static analysis. Use when the user explicitly asks whether a skill is safe or requests a pre-install review; report evidence and uncertainty instead of treating a score as proof.
[DEPRECATED — renamed to skill-deep-audit. Install that one instead: `clawhub install skill-deep-audit`.] Generic skill-quality auditor for any agent skill....