一键导入
refresh-skills
Use when skills may be out of date with source code, after significant infra changes, or when skill descriptions need CSO compliance audit
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Use when skills may be out of date with source code, after significant infra changes, or when skill descriptions need CSO compliance audit
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | refresh-skills |
| description | Use when skills may be out of date with source code, after significant infra changes, or when skill descriptions need CSO compliance audit |
| complexity | medium |
| model-minimum | glm-5 |
| disable-model-invocation | false |
| allowed-tools | ["Read","Grep","Glob","Edit","Write","Bash(cd * && npx tsc --noEmit)","Bash(wc -l *)","Bash(git log *)"] |
| argument-hint | [skill name, 'all', or 'report'] |
Skills encode operational guidance, but the codebase evolves faster than skills get updated. This skill audits skills against the current source code, identifies drift, and applies fixes.
The argument determines scope:
| Argument | Behavior |
|---|---|
all | Audit every skill, update all that need it |
report | Audit every skill, report drift but don't edit |
<skill-name> | Audit and update one specific skill |
| (no argument) | Same as all |
Read every SKILL.md under .claude/skills/*/. For each, extract:
draft?For each skill's source references, read the actual current code. Check for:
Skill descriptions are injected into Claude's system prompt for skill selection. They must state ONLY triggering conditions — never summarize the skill's workflow or process.
Rule: Descriptions answer "When should I invoke this?" not "What does this skill do?"
Why: Testing (cross-project skill-pollination experiment, Finding 1) showed that descriptions summarizing workflow cause Claude to shortcut — following the description instead of reading the full skill body. A description saying "code review between tasks" caused Claude to do ONE review when the skill required TWO.
Checklist for each description:
Format:
# ❌ BAD: Summarizes workflow
description: "Process human feedback — investigate root cause, log learnings, and implement improvements"
# ✅ GOOD: Triggering condition only
description: "Use when the PI or a human provides feedback, corrections, or direction on agent work"
# ❌ BAD: Describes what the skill does
description: "Generate reports — operational dashboard, research digest, project status"
# ✅ GOOD: Triggering condition
description: "Use when a status report, digest, or dashboard is needed for human review"
Flag non-compliant descriptions in the drift report and rewrite them in Step 4.
chat.ts's regex patterns and buildChatPrompt()? Are any missing or removed?allowed-tools frontmatter match what the agent profile actually permits?agent.ts AGENT_PROFILES.chat.ts that no skill documents?buildChatPrompt() or the system prompt changed in ways skills should reflect?git log --since="2 weeks ago" -- <referenced files> — if source files changed recently but the skill hasn't, it's a drift candidate.status: draft that reference stable, shipped code — ready for promotion?Skills accumulate rules from incidents (postmortems, diagnoses, PI feedback) but lack a decay path — resolved failure modes leave permanent scar tissue. For each rule or instruction in the skill body:
Trace provenance. Look for references to decisions (decisions/NNNN), postmortems (postmortem-*.md), diagnoses (diagnosis-*.md), feedback (feedback-*.md), or inline comments explaining why the rule exists. If no provenance is found, flag as [untraced].
Check resolution status. If the rule was motivated by a specific failure mode:
[code-enforced], candidate for removal from skill (the code handles it).git log --since="90 days ago" for related postmortems/diagnoses. If no recurrence → flag as [dormant-90d].Classification. Assign each flagged rule to one of:
[untraced]); cannot determine if rule is still needed.Report provenance findings in the drift assessment (Step 3) under a Provenance: sub-section.
For each skill, produce a drift assessment:
### <skill-name>
Status: current | drifted | stale | draft
References: <list of source files this skill depends on>
Last skill edit: <date from git log>
Last source edit: <date from git log for referenced files>
Drift items:
- [ ] <specific item that needs updating — quote the stale text and the current truth>
Missing coverage:
- [ ] <feature or behavior in source that this skill should mention but doesn't>
If target is report, stop here.
For each drifted skill, apply fixes using Edit:
After each edit, verify the skill still reads coherently.
After all updates:
cd infra/scheduler && npx tsc --noEmit## Skill refresh summary
Date: YYYY-MM-DD
Skills audited: <N>
Skills updated: <N>
Skills current (no changes needed): <N>
Skills still draft: <N>
### Changes made
- <skill>: <1-line summary of what changed>
### Remaining issues
- <anything that needs human decision or is beyond this skill's scope>
Follow docs/sops/commit-workflow.md. Commit message: refresh-skills: update <N> skills — <brief summary of changes>
Use when a file or module is too large, responsibilities are tangled, or a cross-cutting redesign is needed
Use when literature notes exist and need citation verification, or before publishing any artifact that cites literature
Use at the end of a work session to embed learnings into conventions. Simplified for models with lower reasoning capacity.
Use at the end of a work session, or when accumulated findings need to be embedded into conventions, skills, or patterns
Use when the Slack bot needs to handle an operational action like launching an experiment, querying status, or processing approvals
Use when a plan, finding, or design needs adversarial review before committing to it