swe-workflow-skills 0.4.0 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (73) hide show
  1. package/README.md +22 -3
  2. package/VERSION +1 -1
  3. package/bin/cli.mjs +18 -2
  4. package/disable.mjs +207 -0
  5. package/install.mjs +13 -5
  6. package/package.json +2 -1
  7. package/scripts/resolve.mjs +77 -2
  8. package/skills/accessibility-design/SKILL.md +0 -1
  9. package/skills/ai-evaluation/SKILL.md +0 -1
  10. package/skills/api-design/SKILL.md +0 -1
  11. package/skills/architecture-design/SKILL.md +0 -1
  12. package/skills/architecture-documentation/SKILL.md +0 -1
  13. package/skills/brainstorming/SKILL.md +0 -1
  14. package/skills/browser-verification/SKILL.md +0 -1
  15. package/skills/bug-investigating/SKILL.md +0 -1
  16. package/skills/build-vs-buy/SKILL.md +0 -1
  17. package/skills/cicd-pipeline/SKILL.md +0 -1
  18. package/skills/code-archaeology/SKILL.md +0 -1
  19. package/skills/code-reviewing/SKILL.md +0 -1
  20. package/skills/compliance-privacy/SKILL.md +0 -1
  21. package/skills/configuration-strategy/SKILL.md +0 -1
  22. package/skills/containerization/SKILL.md +0 -1
  23. package/skills/data-modeling/SKILL.md +0 -1
  24. package/skills/data-pipeline-design/SKILL.md +0 -1
  25. package/skills/data-quality/SKILL.md +0 -1
  26. package/skills/dependency-impact-analysis/SKILL.md +0 -1
  27. package/skills/dependency-management/SKILL.md +0 -1
  28. package/skills/deployment-checklist/SKILL.md +0 -1
  29. package/skills/deployment-repo/SKILL.md +0 -1
  30. package/skills/dx-audit/SKILL.md +0 -1
  31. package/skills/effort-estimation/SKILL.md +0 -1
  32. package/skills/exploratory-data-analysis/SKILL.md +0 -1
  33. package/skills/feature-planning/SKILL.md +0 -1
  34. package/skills/finops-cost-optimization/SKILL.md +0 -1
  35. package/skills/frontend-architecture/SKILL.md +0 -1
  36. package/skills/git-workflow/SKILL.md +0 -1
  37. package/skills/gitops-delivery/SKILL.md +0 -1
  38. package/skills/incident-response/SKILL.md +0 -1
  39. package/skills/infrastructure-as-code/SKILL.md +0 -1
  40. package/skills/llm-app-engineering/SKILL.md +0 -1
  41. package/skills/metrics-and-okrs/SKILL.md +0 -1
  42. package/skills/ml-experiment-tracking/SKILL.md +0 -1
  43. package/skills/ml-model-deployment/SKILL.md +0 -1
  44. package/skills/ml-pipeline-design/SKILL.md +0 -1
  45. package/skills/mobile-architecture/SKILL.md +0 -1
  46. package/skills/mobile-release/SKILL.md +0 -1
  47. package/skills/notebook-to-production/SKILL.md +0 -1
  48. package/skills/observability-design/SKILL.md +0 -1
  49. package/skills/performance-optimization/SKILL.md +0 -1
  50. package/skills/plan-execution/SKILL.md +0 -1
  51. package/skills/prd-writing/SKILL.md +0 -1
  52. package/skills/project-documentation/SKILL.md +0 -1
  53. package/skills/project-proposal/SKILL.md +0 -1
  54. package/skills/project-review/SKILL.md +0 -1
  55. package/skills/refactoring/SKILL.md +0 -1
  56. package/skills/release-management/SKILL.md +0 -1
  57. package/skills/resilience-engineering/SKILL.md +0 -1
  58. package/skills/retrospective/SKILL.md +0 -1
  59. package/skills/rollback-strategy/SKILL.md +0 -1
  60. package/skills/security-audit/SKILL.md +0 -1
  61. package/skills/skill-router/SKILL.md +0 -1
  62. package/skills/statistical-analysis/SKILL.md +0 -1
  63. package/skills/strategic-review/SKILL.md +0 -1
  64. package/skills/subagent-orchestration/SKILL.md +0 -1
  65. package/skills/tdd-workflow/SKILL.md +0 -1
  66. package/skills/technical-debt-review/SKILL.md +0 -1
  67. package/skills/test-data-strategy/SKILL.md +0 -1
  68. package/skills/test-suite-design/SKILL.md +0 -1
  69. package/skills/threat-modeling/SKILL.md +0 -1
  70. package/skills/ui-ux-design/SKILL.md +0 -1
  71. package/skills/verification-before-completion/SKILL.md +0 -1
  72. package/skills/writing-skills/SKILL.md +4 -3
  73. package/uninstall.mjs +1 -0
package/README.md CHANGED
@@ -1,5 +1,6 @@
1
1
  # SWE Workflow Skills for Claude Code
2
2
 
3
+ [![npm](https://img.shields.io/npm/v/swe-workflow-skills)](https://www.npmjs.com/package/swe-workflow-skills)
3
4
  [![roles-check](https://github.com/SWEStash/swe-workflow-skills/actions/workflows/roles-check.yml/badge.svg)](https://github.com/SWEStash/swe-workflow-skills/actions/workflows/roles-check.yml)
4
5
  ![skills](https://img.shields.io/badge/skills-65-blue)
5
6
  [![license: MIT](https://img.shields.io/badge/license-MIT-yellow.svg)](LICENSE)
@@ -59,12 +60,28 @@ web, claude.ai chat, and Cowork):
59
60
  /plugin install swe-workflow-pm@swe-workflow
60
61
  ```
61
62
 
62
- **Want the whole library with the orchestrator** (CLI) — no clone needed:
63
+ **Want the whole library with the orchestrator** (CLI) — no clone needed. This is a
64
+ **two-step** setup:
63
65
 
64
66
  ```bash
65
- npx swe-workflow-skills install --global # all 65 skills + router + /role + the SessionStart hook
67
+ # 1. Install all 65 skills + router + /role + the hook script, and apply the baseline
68
+ npx swe-workflow-skills install --global
66
69
  ```
67
70
 
71
+ ```jsonc
72
+ // 2. Wire the hook: merge the snippet the installer prints into your settings.json
73
+ // (the installer never edits settings.json for you — it just prints the block).
74
+ // Then start a new session; /doctor should show the hook registered.
75
+ { "hooks": { "SessionStart": [ /* ...the printed block... */ ] } }
76
+ ```
77
+
78
+ > ⚠️ **Don't skip step 2.** Step 1 alone installs the skills and prevents cropping, but
79
+ > the hook is what nudges Claude to consult `skill-router` first — **without it, skills
80
+ > won't auto-route** (the whole point of the library) and the baseline isn't re-asserted
81
+ > after `/compact`. If you deliberately want no hook, pass `--no-hook`; auto-routing stays
82
+ > off until a hook is wired. The **per-role plugin** path above needs no hook — it's
83
+ > self-contained.
84
+
68
85
  Or from a clone: `node install.mjs --global`.
69
86
 
70
87
  > **Prerequisite:** Node.js ≥ 18 (already present wherever Claude Code runs).
@@ -97,7 +114,9 @@ for every method × surface, and **[ROLES.md](docs/ROLES.md)** for the activatio
97
114
  On any non-trivial task, Claude consults **`skill-router`** first; it reads the full
98
115
  catalog and invokes the matching skill(s) by name, re-routing as the work changes phase.
99
116
  The default SessionStart hook nudges Claude to do this automatically; you can also route
100
- explicitly ("use the security-audit skill") or switch the promoted set with `/role`.
117
+ explicitly ("use the security-audit skill") or switch the promoted set with `/role`. Don't
118
+ want a particular skill routed at all? `npx swe-workflow-skills disable <skill>` opts it out
119
+ durably — see [disable a skill from routing](docs/ROLES.md#advanced-disable-a-skill-from-routing).
101
120
 
102
121
  **A routed chain, by phase** — e.g. *"add OAuth login"*:
103
122
 
package/VERSION CHANGED
@@ -1 +1 @@
1
- 0.4.0
1
+ 0.5.1
package/bin/cli.mjs CHANGED
@@ -5,6 +5,9 @@
5
5
  //
6
6
  // npx swe-workflow-skills install [--global|--dir DIR|--role R|--no-hook|...]
7
7
  // npx swe-workflow-skills uninstall [--global|--dir DIR|--dry-run|--yes]
8
+ // npx swe-workflow-skills disable <skill> [--off] [--global | --dir DIR]
9
+ // npx swe-workflow-skills enable <skill> [--global | --dir DIR]
10
+ // npx swe-workflow-skills list-disabled [--global | --dir DIR]
8
11
 
9
12
  import { spawnSync } from "node:child_process";
10
13
  import { dirname, join } from "node:path";
@@ -17,21 +20,34 @@ const [sub, ...rest] = process.argv.slice(2);
17
20
  const HELP = `swe-workflow-skills <command> [options]
18
21
 
19
22
  Commands:
20
- install Install skills into a Claude config dir (passes flags to install.mjs)
21
- uninstall Remove the library (passes flags to uninstall.mjs)
23
+ install Install skills into a Claude config dir (passes flags to install.mjs)
24
+ uninstall Remove the library (passes flags to uninstall.mjs)
25
+ disable <skill> Opt a skill out of routing/auto-trigger (advanced; --off to fully hide)
26
+ enable <skill> Re-enable a previously disabled skill
27
+ list-disabled List skills currently disabled
22
28
 
23
29
  Examples:
24
30
  npx swe-workflow-skills install --global
25
31
  npx swe-workflow-skills install --role pm
26
32
  npx swe-workflow-skills uninstall --global --dry-run
33
+ npx swe-workflow-skills disable data-modeling --global
34
+ npx swe-workflow-skills enable data-modeling --global
27
35
 
28
36
  Run a command with --help to see its full option list.`;
29
37
 
38
+ // disable/enable/list-disabled all run through disable.mjs; map the CLI verb to
39
+ // the action positional it expects (list-disabled -> list).
40
+ const DISABLE_ACTIONS = { disable: "disable", enable: "enable", "list-disabled": "list" };
41
+
30
42
  if (sub === "install" || sub === "uninstall") {
31
43
  const script = join(ROOT, sub === "install" ? "install.mjs" : "uninstall.mjs");
32
44
  // stdio inherited so install output and uninstall's confirm prompt pass through.
33
45
  const res = spawnSync(process.execPath, [script, ...rest], { stdio: "inherit" });
34
46
  process.exit(res.status ?? 1);
47
+ } else if (sub in DISABLE_ACTIONS) {
48
+ const script = join(ROOT, "disable.mjs");
49
+ const res = spawnSync(process.execPath, [script, DISABLE_ACTIONS[sub], ...rest], { stdio: "inherit" });
50
+ process.exit(res.status ?? 1);
35
51
  } else if (sub === "-v" || sub === "--version" || sub === "version") {
36
52
  process.stdout.write(readFileSync(join(ROOT, "VERSION"), "utf-8"));
37
53
  process.exit(0);
package/disable.mjs ADDED
@@ -0,0 +1,207 @@
1
+ #!/usr/bin/env node
2
+ // Disable / enable a single skill from routing and auto-trigger, durably.
3
+ //
4
+ // The library installs a name-only baseline: skills don't auto-trigger, they're
5
+ // invoked by the skill-router. Disabling goes one step further — it hides a skill
6
+ // from the router too, for users who don't want the whole corpus routed. This is
7
+ // an ADVANCED opt-out of the routed SWE-methodology; most people don't need it.
8
+ //
9
+ // Why a command (not a manual settings edit): the SessionStart hook re-writes
10
+ // every installed skill's skillOverrides entry each session, so a hand edit is
11
+ // reverted. This records the choice in a `.disabled-skills` marker beside the
12
+ // skills, which the hook folds into the baseline every time — so it persists.
13
+ //
14
+ // Runs on Linux, macOS, and Windows using only Node.
15
+ //
16
+ // node disable.mjs disable <skill> # -> user-invocable-only (default)
17
+ // node disable.mjs disable <skill> --off # -> off (fully hidden)
18
+ // node disable.mjs enable <skill> # re-enable (back to the baseline)
19
+ // node disable.mjs list # show disabled skills
20
+ // node disable.mjs disable <skill> --global # target the user config dir
21
+
22
+ import { existsSync, statSync, readFileSync } from "node:fs";
23
+ import { dirname, join, resolve } from "node:path";
24
+ import { fileURLToPath } from "node:url";
25
+ import { homedir } from "node:os";
26
+ import {
27
+ loadRoles,
28
+ applyBaseline,
29
+ installedSkills,
30
+ readDisabled,
31
+ writeDisabled,
32
+ DEFAULT_DISABLE_STATE,
33
+ } from "./scripts/resolve.mjs";
34
+
35
+ // Exit cleanly when stdout is closed early (e.g. piped to `head`/`grep`) instead
36
+ // of throwing an EPIPE stack trace.
37
+ process.stdout.on("error", (e) => {
38
+ if (e && e.code === "EPIPE") process.exit(0);
39
+ throw e;
40
+ });
41
+
42
+ const REPO_ROOT = dirname(fileURLToPath(import.meta.url));
43
+
44
+ const USAGE = `Usage: disable.mjs <disable|enable|list> [skill] [options]
45
+
46
+ Disable or re-enable a skill from routing/auto-trigger (advanced opt-out).
47
+
48
+ Actions:
49
+ disable <skill> Hide <skill> from the router. Default state: user-invocable-only
50
+ (you can still run it manually as /<skill>). Add --off to hide
51
+ it entirely (not even user-invocable).
52
+ enable <skill> Re-enable <skill> (return it to the name-only baseline).
53
+ list List currently disabled skills.
54
+
55
+ Options:
56
+ --off With 'disable': set state to "off" instead of user-invocable-only
57
+ -g, --global Target the user config dir: $CLAUDE_CONFIG_DIR if set, else
58
+ ~/.claude/ (default without this flag: ./.claude/)
59
+ -d, --dir DIR Target a custom Claude config directory DIR
60
+ -h, --help Show this help`;
61
+
62
+ function isDir(p) {
63
+ return existsSync(p) && statSync(p).isDirectory();
64
+ }
65
+ function fatal(msg) {
66
+ process.stderr.write(`Error: ${msg}\n`);
67
+ process.exit(1);
68
+ }
69
+ function log(msg) {
70
+ process.stdout.write(msg + "\n");
71
+ }
72
+ function expandTilde(p) {
73
+ if (p === "~" || p.startsWith("~/") || p.startsWith("~\\")) return homedir() + p.slice(1);
74
+ return p;
75
+ }
76
+
77
+ // ---- arg parsing -----------------------------------------------------------
78
+
79
+ let global = false;
80
+ let off = false;
81
+ let configDir = "";
82
+ const positional = [];
83
+
84
+ const argv = process.argv.slice(2);
85
+ for (let i = 0; i < argv.length; i++) {
86
+ const a = argv[i];
87
+ if (a === "-g" || a === "--global") global = true;
88
+ else if (a === "--off") off = true;
89
+ else if (a === "-d" || a === "--dir") {
90
+ configDir = argv[++i];
91
+ if (configDir === undefined) fatal("--dir requires a path");
92
+ } else if (a.startsWith("--dir=")) configDir = a.slice("--dir=".length);
93
+ else if (a === "-h" || a === "--help") {
94
+ log(USAGE);
95
+ process.exit(0);
96
+ } else if (a.startsWith("-")) {
97
+ process.stderr.write(`Unknown option: ${a}\n${USAGE}\n`);
98
+ process.exit(1);
99
+ } else positional.push(a);
100
+ }
101
+
102
+ const action = positional[0];
103
+ const skill = positional[1];
104
+ if (!action || !["disable", "enable", "list"].includes(action)) {
105
+ process.stderr.write(`${USAGE}\n`);
106
+ process.exit(1);
107
+ }
108
+ if ((action === "disable" || action === "enable") && !skill) {
109
+ fatal(`'${action}' requires a <skill> name`);
110
+ }
111
+ // Reject path-like / malformed names before any filesystem use.
112
+ if (skill && !/^[a-z0-9][a-z0-9-]*$/.test(skill)) {
113
+ fatal(`invalid skill name '${skill}' (expected lowercase letters, digits, hyphens)`);
114
+ }
115
+
116
+ let claudeDir;
117
+ if (configDir) {
118
+ if (global) fatal("--dir and --global are mutually exclusive");
119
+ claudeDir = resolve(expandTilde(configDir));
120
+ } else if (global) {
121
+ claudeDir = process.env.CLAUDE_CONFIG_DIR || join(homedir(), ".claude");
122
+ } else {
123
+ claudeDir = join(process.cwd(), ".claude");
124
+ }
125
+ const dest = join(claudeDir, "skills");
126
+ const settingsLocal = join(claudeDir, "settings.local.json");
127
+
128
+ if (!isDir(dest)) fatal(`no skills found at ${dest} (is the library installed there? try --global or --dir)`);
129
+
130
+ // Roles data: prefer the installed marker beside the skills, else the repo copy.
131
+ function loadRolesData() {
132
+ for (const p of [join(dest, ".roles.json"), join(REPO_ROOT, "roles.json")]) {
133
+ if (existsSync(p)) return loadRoles(p);
134
+ }
135
+ return null;
136
+ }
137
+
138
+ // Active role, so re-applying the baseline preserves the user's promoted set.
139
+ function activeRole(data) {
140
+ const f = join(dest, ".active-role");
141
+ if (!existsSync(f)) return null;
142
+ try {
143
+ const r = readFileSync(f, "utf-8").replace(/\s+/g, "");
144
+ return r && data && data.roles && r in data.roles ? r : null;
145
+ } catch {
146
+ return null;
147
+ }
148
+ }
149
+
150
+ // Re-assert the baseline now so the change hot-reloads in the current session
151
+ // (like /role), instead of waiting for the next session boundary.
152
+ function reapply() {
153
+ const data = loadRolesData();
154
+ if (!data) return; // no roles data (partial/plugin install): marker still written
155
+ try {
156
+ applyBaseline(data, settingsLocal, dest, activeRole(data));
157
+ } catch (e) {
158
+ process.stderr.write(`Warning: wrote the marker but could not re-apply the baseline (${e.message}).\n`);
159
+ process.stderr.write("It will take effect at the next session start.\n");
160
+ }
161
+ }
162
+
163
+ // ---- actions ---------------------------------------------------------------
164
+
165
+ const disabled = readDisabled(dest);
166
+
167
+ if (action === "list") {
168
+ if (disabled.size === 0) {
169
+ log("No skills are disabled.");
170
+ } else {
171
+ log("Disabled skills:");
172
+ for (const name of [...disabled.keys()].sort()) log(` ${name} (${disabled.get(name)})`);
173
+ }
174
+ process.exit(0);
175
+ }
176
+
177
+ const data = loadRolesData();
178
+ const installed = new Set(installedSkills(dest));
179
+
180
+ if (action === "disable") {
181
+ if (!installed.has(skill)) fatal(`unknown skill '${skill}' — not installed at ${dest}`);
182
+ const state = off ? "off" : DEFAULT_DISABLE_STATE;
183
+ disabled.set(skill, state);
184
+ writeDisabled(dest, disabled);
185
+ reapply();
186
+ log(`Disabled '${skill}' -> ${state}.`);
187
+ if (state === DEFAULT_DISABLE_STATE) {
188
+ log(`The router will no longer invoke it; you can still run it manually as /${skill}.`);
189
+ } else {
190
+ log("It is now fully hidden (not routable and not user-invocable).");
191
+ }
192
+ if (data && Array.isArray(data.pinned) && data.pinned.includes(skill)) {
193
+ log(`Note: '${skill}' is a pinned safety skill — disabling it opts out of that guardrail.`);
194
+ }
195
+ log("This persists across sessions (the hook re-asserts it). Re-enable with:");
196
+ log(` node disable.mjs enable ${skill}${global ? " --global" : ""}`);
197
+ } else {
198
+ // enable
199
+ if (!disabled.has(skill)) {
200
+ log(`'${skill}' is not disabled — nothing to do.`);
201
+ process.exit(0);
202
+ }
203
+ disabled.delete(skill);
204
+ writeDisabled(dest, disabled);
205
+ reapply();
206
+ log(`Enabled '${skill}' — back to the name-only baseline (routable again).`);
207
+ }
package/install.mjs CHANGED
@@ -369,14 +369,22 @@ if (hook) {
369
369
  hookPath = join(hookDestDir, "session-start.mjs");
370
370
  log(`Installed hook script -> ${hookPath}`);
371
371
  log("");
372
- log("The name-only baseline is already applied. To have it re-asserted every");
373
- log("session (and the router nudge injected), merge this into");
374
- log(`${join(claudeDir, "settings.json")} (the installer does NOT edit settings for you):`);
372
+ log("========================================================================");
373
+ log("REQUIRED NEXT STEP — wire the router hook");
374
+ log("========================================================================");
375
+ log("Skills are installed and the name-only baseline is applied, so nothing");
376
+ log("will crop. But WITHOUT this step Claude won't be nudged to consult");
377
+ log("skill-router first, so skills won't auto-route — you lose the whole point");
378
+ log("of the library. The hook also re-asserts the baseline after /compact.");
379
+ log("");
380
+ log(`Merge this into ${join(claudeDir, "settings.json")}`);
381
+ log("(for your safety the installer does NOT edit settings.json for you):");
375
382
  log("");
376
383
  log(hookSnippet(hookPath));
377
384
  log("");
378
- log("Start a new session and run /doctor to confirm the hook is registered.");
379
- log("(Prefer no hook? Re-run with --no-hook; the baseline still applies.)");
385
+ log("Then start a new session and run /doctor to confirm the hook is registered.");
386
+ log("(Deliberately not using the hook? Re-run with --no-hook; the baseline still");
387
+ log(" applies, but auto-routing stays off until you wire a hook.)");
380
388
  }
381
389
  }
382
390
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "swe-workflow-skills",
3
- "version": "0.4.0",
3
+ "version": "0.5.1",
4
4
  "description": "A curated library of Claude Code Agent Skills covering the full software lifecycle, with orchestrator-routed activation that scales past the skill-listing budget.",
5
5
  "type": "module",
6
6
  "bin": {
@@ -10,6 +10,7 @@
10
10
  "bin/cli.mjs",
11
11
  "install.mjs",
12
12
  "uninstall.mjs",
13
+ "disable.mjs",
13
14
  "scripts/resolve.mjs",
14
15
  "hooks/session-start.mjs",
15
16
  "commands/role.md",
@@ -28,7 +28,7 @@
28
28
  //
29
29
  // roles.json is read from $ROLES_JSON if set, else ../roles.json relative to this file.
30
30
 
31
- import { readFileSync, writeFileSync, mkdirSync, existsSync, statSync, readdirSync } from "node:fs";
31
+ import { readFileSync, writeFileSync, mkdirSync, existsSync, statSync, readdirSync, rmSync } from "node:fs";
32
32
  import { dirname, join, resolve as resolvePath } from "node:path";
33
33
  import { fileURLToPath } from "node:url";
34
34
 
@@ -88,6 +88,73 @@ export function installedSkills(skillsDir) {
88
88
  .sort();
89
89
  }
90
90
 
91
+ // ---- disabled-skills marker ------------------------------------------------
92
+ //
93
+ // Lets a user opt a skill OUT of routing/auto-trigger and have it *survive* the
94
+ // SessionStart hook. A plain settings.local.json edit can't: applyBaseline owns
95
+ // every installed skill's entry and rewrites it each session. Instead the choice
96
+ // lives in a `.disabled-skills` marker beside the skills (like `.active-role`),
97
+ // which applyBaseline folds in on every write — so the hook re-asserts the
98
+ // disable rather than reverting it.
99
+ //
100
+ // Format: one skill per line, optional state after whitespace; `#` comments and
101
+ // blank lines ignored. Valid states are the two that hide a skill from the model:
102
+ // data-modeling -> user-invocable-only (default; human /name still works)
103
+ // data-modeling off -> off (fully hidden)
104
+
105
+ export const DISABLE_STATES = new Set(["user-invocable-only", "off"]);
106
+ export const DEFAULT_DISABLE_STATE = "user-invocable-only";
107
+
108
+ export function disabledMarkerPath(skillsDir) {
109
+ return join(skillsDir, ".disabled-skills");
110
+ }
111
+
112
+ // Parse the marker into Map<skill, state>. Best-effort: a missing or unreadable
113
+ // file yields an empty map (never throws — the hook must not fail on it).
114
+ export function readDisabled(skillsDir) {
115
+ const path = disabledMarkerPath(skillsDir);
116
+ const map = new Map();
117
+ if (!(existsSync(path) && statSync(path).isFile())) return map;
118
+ let text = "";
119
+ try {
120
+ text = readFileSync(path, "utf-8");
121
+ } catch {
122
+ return map;
123
+ }
124
+ for (const raw of text.split("\n")) {
125
+ const line = raw.trim();
126
+ if (!line || line.startsWith("#")) continue;
127
+ const [name, state] = line.split(/\s+/);
128
+ if (!name) continue;
129
+ map.set(name, DISABLE_STATES.has(state) ? state : DEFAULT_DISABLE_STATE);
130
+ }
131
+ return map;
132
+ }
133
+
134
+ // Same, but restricted to skills actually installed here (stale names dropped).
135
+ export function loadDisabled(skillsDir) {
136
+ const installed = new Set(installedSkills(skillsDir));
137
+ const map = new Map();
138
+ for (const [name, state] of readDisabled(skillsDir)) {
139
+ if (installed.has(name)) map.set(name, state);
140
+ }
141
+ return map;
142
+ }
143
+
144
+ // Persist Map<skill, state>, sorted. Removes the marker entirely when empty so an
145
+ // enabled-everything state leaves no file behind (mirrors pruneSettings dropping
146
+ // an empty skillOverrides).
147
+ export function writeDisabled(skillsDir, map) {
148
+ const path = disabledMarkerPath(skillsDir);
149
+ const names = [...map.keys()].sort();
150
+ if (names.length === 0) {
151
+ if (existsSync(path)) rmSync(path);
152
+ return;
153
+ }
154
+ const lines = names.map((n) => (map.get(n) === DEFAULT_DISABLE_STATE ? n : `${n} ${map.get(n)}`));
155
+ writeFileSync(path, lines.join("\n") + "\n");
156
+ }
157
+
91
158
  // ---- settings I/O ----------------------------------------------------------
92
159
 
93
160
  // Recursively sort object keys so output is deterministic (mirrors Python's
@@ -143,11 +210,19 @@ export function applyBaseline(data, settingsPath, skillsDir, role) {
143
210
  const merged = {};
144
211
  for (const [k, v] of Object.entries(existing)) if (!installedSet.has(k)) merged[k] = v;
145
212
  Object.assign(merged, desired);
213
+
214
+ // User-disabled skills override the baseline: an explicit opt-out wins over
215
+ // name-only AND over a pinned/role-promoted "on" (a pinned skill the user
216
+ // disabled becomes user-invocable-only, not on). Read from the marker each
217
+ // call so the hook re-asserts the disable instead of reverting it.
218
+ const disabled = loadDisabled(skillsDir);
219
+ for (const [s, state] of disabled) merged[s] = state;
220
+
146
221
  settings.skillOverrides = merged;
147
222
 
148
223
  writeSettings(settingsPath, settings);
149
224
  const nameOnly = Object.keys(desired).length;
150
- return { nameOnly, on: installed.length - nameOnly, role };
225
+ return { nameOnly, on: installed.length - nameOnly, role, disabled: disabled.size };
151
226
  }
152
227
 
153
228
  // Remove the given skills from a settings file's skillOverrides. Returns removed count.
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: accessibility-design
3
3
  description: "Design and implement accessible web/mobile apps to WCAG 2.1/2.2 — semantic HTML, ARIA patterns, keyboard navigation, focus management, color contrast, screen readers, accessible forms. Triggers: accessibility, a11y, WCAG, screen reader, keyboard navigation, ARIA, focus management, color contrast, alt text, semantic HTML, tab order, focus trap, skip link, announce. Build it in, don't bolt it on."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: ai-evaluation
3
3
  description: "Define how to evaluate ML models and GenAI/LLM apps — golden datasets, offline metrics, RAG evaluation (faithfulness, relevance, context precision/recall) with ragas/deepeval/promptfoo, LLM-as-judge design and calibration, eval regression gates in CI, online A/B and human feedback. Logging/comparing runs → ml-experiment-tracking; building the app → llm-app-engineering; general experiment statistics → statistical-analysis."
4
4
  when_to_use: "Triggers: evaluate the model, eval my chatbot, RAG evals, ragas, LLM as judge, golden dataset, eval suite, is the new prompt better, hallucination rate, benchmark our AI app."
5
- model: sonnet
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
7
6
  ---
8
7
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: api-design
3
3
  description: "Design RESTful and GraphQL APIs — endpoint naming, request/response contracts, error handling, pagination, versioning, auth patterns, OpenAPI specs. Triggers: design the API, API contract, REST API, GraphQL schema, error response format, pagination, API versioning, OpenAPI, swagger, endpoints. Use architecture-design for REST-vs-GraphQL or monolith-vs-microservices decisions."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: architecture-design
3
3
  description: "Guide architectural and structural decisions using Architecture Decision Records (ADRs) — new services, pattern choices, database selection, component boundaries, state management, costly-to-reverse decisions. Triggers: how should I architect, which pattern, design decision, should I use X or Y, system design, ADR, component design, architectural trade-off. Owns internal-structure decisions — build vs buy/adopt a vendor or OSS capability → build-vs-buy."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: architecture-documentation
3
3
  description: "Design and maintain architecture documentation with multi-level diagrams (C4) and docs-as-code. Triggers: architecture diagram, document the architecture, C4 diagram, system context, container diagram, component diagram, architecture docs, docs-as-code, PlantUML, Structurizr, D2, Mermaid architecture, infrastructure diagram, runtime flow. Use architecture-design for ADRs."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: brainstorming
3
3
  description: "Facilitate divergent ideation before committing to a spec — Socratic questioning, widening the option space, challenging assumptions and inherited constraints, then converging on candidates. Triggers: brainstorm, let's explore ideas, what are our options, help me think through, generate ideas, what could we build, not sure what I want, explore approaches, ideate. Once ideas converge, hand off to prd-writing (WHAT/WHY) or feature-planning (breakdown) — this skill opens options; those close them."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: browser-verification
3
3
  description: "Verify a web app change by driving the real UI in a browser — reproduce the user flow end to end, watch console errors and network failures, exercise loading/error/empty states, capture screenshots as evidence. Use before claiming a UI change works. Triggers: check it in the browser, verify the UI, click through the flow, console errors, test it like a user, smoke test the frontend. Designing persistent test suites → test-suite-design; the generic done-gate → verification-before-completion (this is its browser-specific practice)."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: bug-investigating
3
3
  description: "Systematic debugging and root cause analysis using structured methodology — reproduce, isolate, hypothesize, verify. Triggers: this doesn't work, I'm getting an error, something is broken, bug, debug this, why is this happening, unexpected behavior, regression, root cause, stack trace, error message."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: build-vs-buy
3
3
  description: "Decide whether to build in-house, buy a vendor/SaaS product, or adopt OSS — core-vs-commodity framing, multi-year total cost of ownership, integration and maintenance burden, vendor viability, lock-in and exit costs. Triggers: build vs buy, build or buy, vendor evaluation, SaaS vs in-house, should we adopt this open source, TCO, total cost of ownership, lock-in, exit cost, make or buy, off the shelf. Internal-structure decisions (patterns, service boundaries, ADRs for your own code) → architecture-design."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, WebFetch, WebSearch
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: cicd-pipeline
3
3
  description: "Design CI/CD pipelines for automated build, test, deploy — GitHub Actions, GitLab CI, quality gates. Triggers: CI/CD, pipeline, GitHub Actions, GitLab CI, workflow, automated deployment, build pipeline, continuous integration, continuous deployment, automate tests on PR, deploy automatically, quality gate."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: code-archaeology
3
3
  description: "Understand unfamiliar or legacy code before changing it — map entry points, mine git history (blame, churn, log -S), trace data flow, recover the why behind odd code, pin current behavior with characterization tests, find seams for safe change. Triggers: understand this codebase, legacy code, inherited this project, what does this code do, why is it written this way, nobody knows how this works, onboard to this repo, is it safe to change this. Prioritizing debt → technical-debt-review; improving code you already understand → refactoring."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: code-reviewing
3
3
  description: "Structured code reviews enforcing DRY, KISS, YAGNI, SRP, best practices, and project conventions."
4
4
  when_to_use: "Triggers: review this code, code review, check my code, what do you think of this implementation, review this PR, is this code good, feedback on my code, review staged changes before commit."
5
- model: sonnet
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit
7
6
  ---
8
7
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: compliance-privacy
3
3
  description: "Engineer for regulatory and privacy obligations — GDPR/CCPA privacy-by-design, PII data mapping and minimization, retention and deletion (right to erasure), data subject requests, consent, SOC 2 controls (access, change management, audit logging). Triggers: GDPR, CCPA, SOC 2, HIPAA, compliance, privacy review, PII, personal data, data retention, right to be forgotten, DSR, audit requirements, are we compliant. Vulnerabilities in code → security-audit; attack analysis of a design → threat-modeling."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, WebFetch, WebSearch
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: configuration-strategy
3
3
  description: "Design environment configuration, secrets management, and feature-flag hierarchy for a service or feature. Triggers: config strategy, environment variables, .env, secrets management, feature flag, config hierarchy, config precedence, twelve-factor config, environment-specific settings."
4
- model: haiku
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: containerization
3
3
  description: "Write production-grade Dockerfiles, docker-compose, and Kubernetes manifests following security and reliability best practices. Triggers: Dockerfile, docker-compose, containerize, Docker image, Kubernetes, k8s manifest, container, pod, deployment yaml, multi-stage build, docker build, image size, container security."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: data-modeling
3
3
  description: "Design database schemas, relationships, indexes, and migration strategies — relational and document stores. Triggers: data model, schema design, ER diagram, database schema, table design, foreign key, index strategy, normalization, denormalization, migration plan, document model, partition key."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: data-pipeline-design
3
3
  description: "Design batch and streaming data pipelines — ELT into a warehouse/lakehouse, dbt and analytics engineering (staging/intermediate/marts layers), orchestration with Airflow or Dagster, idempotent loads, incremental models, backfills, CDC ingestion. Triggers: data pipeline, ELT, ETL, dbt models, data warehouse, Snowflake, BigQuery, ingest into the warehouse, Airflow DAG, Dagster, Kafka streaming, backfill, incremental load, nightly job duplicates rows. ML training/feature pipelines → ml-pipeline-design; validating the data → data-quality."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: data-quality
3
3
  description: "Keep warehouse and pipeline data trustworthy — dbt tests, expectations (Great Expectations/Soda), data contracts with upstream producers, source freshness, schema-drift and volume anomaly detection, lineage and blast radius, severity and alerting. Triggers: data quality, bad data in dashboards, data validation, dbt tests, data contract, schema drift, stale data, freshness check, duplicate rows, nulls in the warehouse, data lineage, data SLA, upstream schema change broke us. Generating test/synthetic data → test-data-strategy; schema design → data-modeling."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: dependency-impact-analysis
3
3
  description: "Map the blast radius of a change before implementing — find dependents, classify breaking vs additive, identify coordination needs, produce a propagation plan. Triggers: what will break if I change this, blast radius, impact analysis, breaking change, who depends on this, downstream impact, safe to rename, shared schema change, dependency graph."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: dependency-management
3
3
  description: "Evaluate, audit, and upgrade project dependencies — assess libraries before adoption, audit CVEs, plan major upgrades, resolve conflicts. Triggers: should I use this library, npm audit, upgrade dependencies, dependency vulnerability, outdated packages, evaluate this package, is this library maintained, dependency conflict, lock file, breaking changes in upgrade."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, WebFetch, WebSearch
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: deployment-checklist
3
3
  description: "Pre-deploy verification and release safety checks — config, migrations, monitoring, rollback readiness, comms. Triggers: deployment checklist, ready to deploy, pre-deploy, release checklist, go-live, ship checklist, deploy safety, is this safe to ship, release readiness."
4
- model: haiku
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: deployment-repo
3
3
  description: "Design a deployment (GitOps) repo that orchestrates multiple services in a polyrepo — version pinning, environment promotion, compatibility matrices, system config. Triggers: deployment repo, GitOps repo, polyrepo, multi-repo, version pinning, compatibility matrix, environment promotion, multi-service deployment, orchestration repo, which versions work together."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: dx-audit
3
3
  description: "Audit and improve developer experience — inner-loop feedback (build/test/reload times), CI wait and queue times, flaky tests, local environment setup, onboarding time-to-first-PR, tooling friction, docs discoverability; produce a prioritized remediation plan. Triggers: developer experience, DX audit, devex, builds are slow, CI takes forever, flaky tests, onboarding takes weeks, tooling friction, developer productivity, engineers are frustrated. Code health/debt hotspots → technical-debt-review; designing one pipeline → cicd-pipeline."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: effort-estimation
3
3
  description: "Estimate engineering effort with agile techniques — story points, t-shirt sizing, three-point estimation, capacity planning."
4
4
  when_to_use: "Triggers: estimate this, how long will this take, story points, t-shirt sizing, effort estimation, capacity planning, sprint planning, budget estimate, forecast, velocity, when will this be done."
5
- model: haiku
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit
7
6
  ---
8
7
 
@@ -2,7 +2,6 @@
2
2
  name: exploratory-data-analysis
3
3
  description: "Explore and profile an unfamiliar dataset before modeling or analysis — structural profiling, missingness structure, distributions and outliers, feature–target relationships, leakage awareness, and explicit hypothesis generation. Pipeline-level data trust (broken dashboards, tests, contracts, freshness) → data-quality; formal inference on the hypotheses → statistical-analysis."
4
4
  when_to_use: "Triggers: explore this dataset, EDA, profile the data, what's in this data, first look at the data, understand this CSV, distributions, outliers, missing values, correlation, data leakage."
5
- model: sonnet
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
7
6
  ---
8
7
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: feature-planning
3
3
  description: "Break features into well-scoped tasks with acceptance criteria, risk assessment, and dependency mapping. Triggers: plan this, break this down, scope this feature, create tasks for, sprint planning, how should I implement this feature, user stories, acceptance criteria, dependency mapping, feature breakdown. Creates the plan — executing an already-approved plan checkpoint by checkpoint → plan-execution."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: finops-cost-optimization
3
3
  description: "Understand and reduce cloud spend — cost visibility and allocation (tagging, ownership), unit economics, rightsizing, autoscaling, commitment discounts (reserved instances, savings plans), storage/egress traps, architecture cost review, budgets and anomaly alerts. Triggers: cloud costs, AWS bill, cut costs, cost optimization, FinOps, why is our bill so high, rightsizing, reserved instances, savings plan, egress fees, cost per customer. Whether to build or buy a capability → build-vs-buy; making code faster → performance-optimization."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash, WebFetch, WebSearch
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: frontend-architecture
3
3
  description: "Design frontend architecture — React component hierarchy, state management, design tokens, data fetching, routing, error boundaries, code organization. Triggers: component architecture, state management, design system, design tokens, component library, React structure, folder structure, Zustand vs Redux, React Query, code splitting, error boundary, compound component."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: git-workflow
3
3
  description: "Write commit messages, PR descriptions, and manage branching strategy following conventional commits."
4
4
  when_to_use: "Triggers: write a commit message, commit this, PR description, pull request, branching strategy, git workflow, squash commits, rebase, conventional commits, how should I commit this, review staged changes."
5
- model: haiku
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit
7
6
  ---
8
7
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: gitops-delivery
3
3
  description: "Design GitOps continuous delivery with ArgoCD or Flux — declarative reconciliation, cross-repo CI/CD triggers, drift detection, progressive delivery. Triggers: ArgoCD, Flux, FluxCD, GitOps, git-based deployment, declarative delivery, auto-sync, drift detection, cross-repo trigger, reconciliation loop, pull-based deployment, canary GitOps."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: incident-response
3
3
  description: "Structured production incident workflow — triage, mitigation, investigation, recovery, comms. Triggers: production is down, site is down, incident, outage, users seeing errors, on-call, alert fired, p0, p1, sev1, sev2, broken in prod, rollback, emergency deploy. For active incidents under time pressure."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: infrastructure-as-code
3
3
  description: "Write and review IaC with Terraform, CloudFormation, Pulumi, or CDK — modularity, security, state management. Triggers: Terraform, CloudFormation, Pulumi, infrastructure as code, IaC, provision, cloud resources, terraform module, state management, terraform plan, CDK, drift, remote state."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: llm-app-engineering
3
3
  description: "Design and build LLM-powered applications — prompt and context engineering, RAG architecture (chunking, hybrid retrieval, reranking, grounded prompts), agent design (tool surfaces, planning, sub-agents), and memory. Triggers: build a chatbot, LLM app, AI assistant, prompt engineering, system prompt, RAG design, chunking, embeddings, vector database, semantic search, AI agent, tool calling, agent memory, context window, hallucinations. Measuring quality → ai-evaluation; model serving/inference infra → ml-model-deployment."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: metrics-and-okrs
3
3
  description: "Define OKRs, KPIs, success metrics, and engineering health metrics (DORA). Triggers: OKR, KPI, metrics, success metrics, key results, objectives, measure success, DORA metrics, engineering metrics, velocity, cycle time, deployment frequency, how do we measure, what should we track."
4
- model: haiku
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: ml-experiment-tracking
3
3
  description: "Design reproducible ML experiments — tracking, versioning, run comparison with MLflow, W&B, or DVC. Triggers: experiment tracking, MLflow, wandb, weights and biases, DVC, track experiments, compare models, hyperparameter, reproducibility, model registry, which model is better, experiment results, log metrics. Defining WHAT to measure (metrics, golden datasets, judges) → ai-evaluation; this skill records and compares the runs."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: ml-model-deployment
3
3
  description: "Deploy ML models to production — serving infrastructure, monitoring, drift detection, safe rollouts. Triggers: deploy model, serve model, model API, model monitoring, data drift, concept drift, model degradation, A/B test model, canary model, inference endpoint, prediction API, retrain trigger."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: ml-pipeline-design
3
3
  description: "Design reproducible ML training and data pipelines — ingestion, validation, feature engineering, training, evaluation, continuous training orchestration. Analytics/BI ELT and dbt warehouse pipelines → data-pipeline-design; refactoring general analysis/reporting notebooks (no model training) to production code → notebook-to-production."
4
4
  when_to_use: "Triggers: training pipeline, ML data pipeline, feature engineering, ETL for ML, continuous training, data validation, feature store, preprocessing, notebook to training pipeline, orchestrate training, Kubeflow, pipeline DAG, point-in-time features."
5
- model: opus
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
7
6
  ---
8
7
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: mobile-architecture
3
3
  description: "Design mobile app architecture — native (Swift/Kotlin) vs cross-platform (React Native/Flutter) selection, navigation and deep linking, state management, offline-first design and data sync, local persistence, push notifications, platform constraints (background work, battery, permissions). Triggers: mobile app architecture, iOS app, Android app, React Native or Flutter, offline first, data sync, mobile state management, deep linking, push notifications, app structure. Web SPA component architecture → frontend-architecture."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: mobile-release
3
3
  description: "Ship mobile apps through the app stores — signing and provisioning, store review and rejection handling, phased/staged rollouts with halt criteria, crash monitoring, versioning and build numbers, beta channels (TestFlight, Play tracks), forced updates, and the no-instant-rollback reality of mobile. Triggers: app store release, publish to App Store, Play Store, TestFlight, staged rollout, app review rejected, code signing, provisioning profile, mobile release, hotfix a mobile bug. General semver/registry/library publishing → release-management."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash, WebFetch, WebSearch
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: notebook-to-production
3
3
  description: "Refactor analysis notebooks into production-grade code — triage what deserves productionizing, extract modules with tests, parameterize hardcoded values, pin environments for reproducibility, and schedule unattended runs with alerting. Owns general analysis/reporting notebooks; notebooks that feed model TRAINING (feature engineering + training DAGs, scheduled retraining) → ml-pipeline-design."
4
4
  when_to_use: "Triggers: productionize this notebook, notebook to script, notebook to module, refactor my notebook, parameterize notebook, papermill, schedule this analysis, reproducible analysis, notebook is a mess."
5
- model: opus
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
7
6
  ---
8
7
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: observability-design
3
3
  description: "Design production observability — SLIs, SLOs, SLAs, error budgets, OpenTelemetry traces/metrics/logs, structured logging, alerting, dashboards. Triggers: SLO, SLI, SLA, error budget, observability, monitoring, OpenTelemetry, OTel, tracing, distributed tracing, structured logging, alerting, dashboard, metrics, correlation ID, alert fatigue."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: performance-optimization
3
3
  description: "Identify and resolve performance bottlenecks via static analysis — N+1 queries, algorithmic complexity, query optimization, caching, memory leaks, bundle size, connection management. Triggers: this is slow, optimize, performance, N+1, query optimization, caching, bundle size, memory leak, latency, response time, scale, bottleneck."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: plan-execution
3
3
  description: "Execute an already-approved plan with discipline — batch tasks into verifiable checkpoints, verify each with fresh evidence before marking it done, log drift, and stop to re-plan when reality diverges from the plan's assumptions. Triggers: execute the plan, implement the approved plan, work through this plan, continue/resume the plan, next phase, checkpoint. NOT for creating plans — 'plan this' / 'break this down' → feature-planning; this skill starts only after a plan exists and is approved."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: prd-writing
3
3
  description: "Write lightweight agile PRDs and technical RFCs that align stakeholders before implementation. Triggers: PRD, product requirements, RFC, request for comments, technical design doc, design document, tech spec, write requirements, what are we building, spec this out. Produces the WHAT and WHY — feature-planning handles HOW."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: project-documentation
3
3
  description: "Write and maintain project docs — README, contributing guides, API docs, changelogs, inline docs."
4
4
  when_to_use: "Triggers: write a README, document this project, create documentation, contributing guide, changelog, API docs, how do I document, this needs docs, onboarding docs, JSDoc, docstrings."
5
- model: haiku
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit
7
6
  ---
8
7
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: project-proposal
3
3
  description: "Write lightweight project proposals for budget approval and go/no-go decisions — problem, business case, scope, rough estimates, risks, success criteria. Triggers: project proposal, project brief, business case, budget estimate, should we build this, go/no-go, risk assessment, cost-benefit, ROI, justify this project, stakeholder approval."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: project-review
3
3
  description: "Review a built project's execution health before a milestone — scope alignment, roadmap / execution-plan adherence, implementation maturity (what's production-ready vs stub/deferred), and the evidence it actually works (tests, coverage, validation results, changelog). Use strategic-review for vision/positioning/market; technical-debt-review for a pure code-health audit."
4
4
  when_to_use: "Triggers: project review, execution review, are we on track, implementation vs roadmap, scope drift, readiness review, what's actually built, validation results review, pre-launch review."
5
- model: opus
6
5
  context: fork
7
6
  agent: general-purpose
8
7
  allowed-tools: Read, Grep, Glob, WebFetch, Write, Edit
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: refactoring
3
3
  description: "Systematic code improvement via design principles, smell detection, and safe transformation patterns. Triggers: refactor this, clean this up, simplify this code, reduce complexity, extract this, this code is messy, tech debt, improve this code, code smell, rename, extract function, dead code."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: release-management
3
3
  description: "Cut and publish software releases right-sized to the project — semver decisions, changelogs, tagging, automated version bumps (release-please, changesets, semantic-release), publishing gates, npm/PyPI/container registry publishing, pre-release channels, monorepo versioning. Triggers: cut a release, release this, publish to npm, publish to PyPI, publish this package, version bump, what version should this be, semver, changelog, tag a release, release notes, GitHub release, prerelease, release automation, release PR. Deploy-time safety → deployment-checklist; commit/PR hygiene → git-workflow."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: resilience-engineering
3
3
  description: "Design systems that survive failure — failure-mode analysis, resilience patterns (timeouts, retries with backoff, circuit breakers, bulkheads, load shedding, graceful degradation), chaos experiments, disaster recovery with RTO/RPO, backup restore testing, game days. Triggers: chaos engineering, disaster recovery, DR plan, what if the database goes down, single point of failure, failover, circuit breaker, RTO, RPO, game day, high availability. An incident happening NOW → incident-response; undoing a bad deploy → rollback-strategy."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: retrospective
3
3
  description: "Facilitate sprint retros, project post-mortems, and incident post-mortems with actionable, owned improvements. Triggers: retrospective, retro, post-mortem, postmortem, lessons learned, what went wrong, what went well, incident review, blameless, action items, sprint review, after action review."
4
- model: haiku
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: rollback-strategy
3
3
  description: "Design safe rollback plans before deploying — identify irreversible changes, classify rollback complexity, create tested undo procedures. Triggers: rollback plan, rollback strategy, how do I undo this, can we revert, what if the deploy fails, safe to deploy, feature flag rollout, blue-green, database migration rollback, irreversible change."
4
- model: haiku
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: security-audit
3
3
  description: "Comprehensive security analysis — OWASP Top 10, auth/authz flows, injection vulnerabilities, data exposure, secrets detection, dependency CVEs, hardening recommendations. Reviews EXISTING code/config — design-time analysis of a system not yet built → threat-modeling."
4
4
  when_to_use: "Triggers: security audit, vulnerability, is this secure, security review, pentest prep, OWASP, harden this, check for vulnerabilities, injection, XSS, CSRF, auth security."
5
- model: opus
6
5
  context: fork
7
6
  agent: general-purpose
8
7
  allowed-tools: Read, Grep, Glob, Write, Edit, WebFetch, WebSearch
@@ -2,7 +2,6 @@
2
2
  name: skill-router
3
3
  description: "Orchestrator and entry point for the swe-workflow skills library — consult FIRST when starting any non-trivial software task; most skills load name-only and only activate when invoked here. Routes intent to the right skill(s) and invokes them by name; shows the Golden Path chains."
4
4
  when_to_use: "Triggers: starting a feature, planning, an architecture or design decision, implementing, debugging, reviewing, refactoring, testing, security, deployment, an incident, shipping, or unsure which skill fits."
5
- model: haiku
6
5
  allowed-tools: Read, Grep, Glob, Skill
7
6
  ---
8
7
 
@@ -2,7 +2,6 @@
2
2
  name: statistical-analysis
3
3
  description: "Design and analyze experiments and statistical tests — test selection with stated assumptions, sample size and power, effect sizes and confidence intervals over bare p-values, and pitfall discipline (multiple comparisons, p-hacking, peeking/optional stopping). Owns experiment statistics generally; live A/B evaluation of AI/LLM apps (quality metrics, judges, feedback) → ai-evaluation."
4
4
  when_to_use: "Triggers: hypothesis test, t-test, chi-square, p-value, statistical significance, confidence interval, sample size, power analysis, design an experiment, A/B test, multiple comparisons, is this difference real."
5
- model: opus
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
7
6
  ---
8
7
 
@@ -2,7 +2,6 @@
2
2
  name: strategic-review
3
3
  description: "Review a project's strategic position before going public, launching, or raising — vision, mission, value proposition, scope positioning, the defensible wedge, and a live competitive / market comparative analysis. Use project-review for execution/roadmap/implementation health; delegates deep market scans to deep-research."
4
4
  when_to_use: "Triggers: strategic review, positioning, go public, go-to-market, market analysis, competitive landscape, value proposition, is there a moat, who are our competitors, platform absorption risk, market positioning, comparable products."
5
- model: opus
6
5
  context: fork
7
6
  agent: general-purpose
8
7
  allowed-tools: Read, Grep, Glob, WebFetch, WebSearch, Write, Edit
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: subagent-orchestration
3
3
  description: "Decompose big or parallelizable work across subagents — when to fan out vs stay solo, scoping self-contained sub-tasks, prompting agents that don't share your context, isolating parallel edits (git worktrees), skeptically verifying and synthesizing results you didn't produce. Triggers: use subagents, parallelize this, fan out, orchestrate agents, multi-agent, spawn agents, worktree, delegate to agents, split this across agents, agent team. Sequencing checkpoints of an approved plan → plan-execution (orchestration parallelizes within its batches)."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: tdd-workflow
3
3
  description: "Guide test-driven development with red-green-refactor. Triggers: use tdd, test first, write the tests, red green refactor, test-driven, what should I test, write tests before code, failing test, implement using TDD. For NEW code via test-first — use test-suite-design for adding tests to existing code."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: technical-debt-review
3
3
  description: "Strategic codebase health assessment — identify hotspots, categorize debt, produce remediation roadmap."
4
4
  when_to_use: "Triggers: technical debt, tech debt, debt review, codebase health, hotspots, debt assessment, remediation plan, what should we fix first, debt roadmap, code rot, legacy code audit."
5
- model: opus
6
5
  context: fork
7
6
  agent: general-purpose
8
7
  allowed-tools: Read, Grep, Glob, Write, Edit
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: test-data-strategy
3
3
  description: "Design and generate test data — factories, synthetic data, property-based testing, boundary analysis, contract testing, load scenarios, GDPR-safe data. Triggers: test data, synthetic data, fake data, factory, seed data, fixtures, property-based testing, fuzz testing, boundary values, contract testing, Pact, load test data, anonymize, GDPR test data."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: test-suite-design
3
3
  description: "Design comprehensive test suites for existing code — strategy across unit/integration/e2e, fixtures, factories, helpers. Triggers: add tests, write tests for, increase coverage, test this module, testing strategy, test plan, what tests do I need, test infrastructure, test helpers, this has no tests. Not for TDD — use tdd-workflow."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: threat-modeling
3
3
  description: "Design-time security analysis of a system or feature before it's built — trust boundaries, attack surface, STRIDE per element, abuse cases, prioritized mitigations that become security requirements. Triggers: threat model, STRIDE, trust boundary, attack surface, what could go wrong security-wise, security design review, abuse case, secure this design, security requirements. Reviewing EXISTING code/config for vulnerabilities → security-audit; use this skill while the design is still on the whiteboard."
4
- model: opus
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: ui-ux-design
3
3
  description: "Design user experiences from an engineer's perspective — user flows, wireframes, interaction patterns, responsive strategy, navigation, loading/error/empty states. Triggers: design the UI, user flow, wireframe, how should this screen look, loading state, error state, empty state, responsive design, navigation, page layout, form design, mockup."
4
- model: sonnet
5
4
  allowed-tools: Read, Grep, Glob, Write, Edit
6
5
  ---
7
6
 
@@ -1,7 +1,6 @@
1
1
  ---
2
2
  name: verification-before-completion
3
3
  description: "Evidence gate before claiming work is done, passing, fixed, or deployed. Use before saying 'done', 'it works', or 'tests pass', or before committing, pushing, or opening a PR. Triggers: is it done, did it work, tests pass, verify, ready to commit, before I push, confirm the fix. Run the proving command fresh and read its output first."
4
- model: haiku
5
4
  allowed-tools: Read, Grep, Glob, Bash
6
5
  ---
7
6
 
@@ -2,7 +2,6 @@
2
2
  name: writing-skills
3
3
  description: "Use when authoring, editing, or reviewing a skill in this library — a new SKILL.md, one that under-triggers, or hardening an existing one. Covers description and listing-budget rules, frontmatter, progressive disclosure, the 3-eval rule, and pressure-testing against rationalizations."
4
4
  when_to_use: "Triggers: write a skill, new skill, edit a skill, skill isn't triggering."
5
- model: sonnet
6
5
  allowed-tools: Read, Grep, Glob, Write, Edit, Bash
7
6
  ---
8
7
 
@@ -69,8 +68,10 @@ description over the body, so get it right.
69
68
 
70
69
  ## Structure and budget (brief — see AUTHORING.md for detail)
71
70
 
72
- - Frontmatter: `name`, `description`, `when_to_use`, `model` (haiku/sonnet/opus
73
- by reasoning need), `allowed-tools`. Newer fields where they fit:
71
+ - Frontmatter: `name`, `description`, `when_to_use`, `allowed-tools` — do NOT
72
+ set `model` (inline pins are ignored at runtime; on forked skills they
73
+ override the user's model choice and quota bucket — see AUTHORING.md
74
+ "Frontmatter Fields"). Newer fields where they fit:
74
75
  `context: fork` + `agent` (heavy report-producing skills — must write the full
75
76
  report to a file and put anything needing user input in an "Open questions"
76
77
  section, since a fork returns only a summary and can't ask the user),
package/uninstall.mjs CHANGED
@@ -127,6 +127,7 @@ for (const f of [
127
127
  join(dest, ".roles.json"),
128
128
  join(dest, ".catalog.json"),
129
129
  join(dest, ".active-role"),
130
+ join(dest, ".disabled-skills"),
130
131
  join(dest, ".swe-workflow-manifest.json"),
131
132
  join(claudeDir, "hooks", "resolve.mjs"),
132
133
  join(claudeDir, "hooks", "session-start.mjs"),