@drunkcoding/agents-and-skills 0.0.13 → 0.0.14
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.
- package/.claude-plugin/marketplace.json +9 -6
- package/README.md +1 -1
- package/package.json +1 -1
- package/plugins/html-effectiveness/.claude-plugin/plugin.json +1 -1
- package/plugins/html-effectiveness/README.md +9 -4
- package/plugins/html-effectiveness/agents/report-builder.md +4 -0
- package/plugins/html-effectiveness/assets/base.css +40 -20
- package/plugins/html-effectiveness/docs/template-gallery.md +28 -0
- package/plugins/html-effectiveness/scripts/_tmp.js +37 -0
- package/plugins/html-effectiveness/scripts/catalog.js +47 -0
- package/plugins/html-effectiveness/scripts/extract.js +104 -0
- package/plugins/html-effectiveness/scripts/render.js +2 -2
- package/plugins/html-effectiveness/skills/html-effectiveness/SKILL.md +4 -4
- package/plugins/html-effectiveness/templates/01-exploration-code-approaches.html.tmpl +400 -0
- package/plugins/html-effectiveness/templates/02-exploration-visual-designs.html.tmpl +456 -0
- package/plugins/html-effectiveness/templates/03-code-review-pr.html.tmpl +581 -0
- package/plugins/html-effectiveness/templates/04-code-understanding.html.tmpl +443 -0
- package/plugins/html-effectiveness/templates/05-design-system.html.tmpl +578 -0
- package/plugins/html-effectiveness/templates/06-component-variants.html.tmpl +557 -0
- package/plugins/html-effectiveness/templates/07-prototype-animation.html.tmpl +417 -0
- package/plugins/html-effectiveness/templates/08-prototype-interaction.html.tmpl +363 -0
- package/plugins/html-effectiveness/templates/09-slide-deck.html.tmpl +535 -0
- package/plugins/html-effectiveness/templates/10-svg-illustrations.html.tmpl +444 -0
- package/plugins/html-effectiveness/templates/11-status-report.html.tmpl +152 -0
- package/plugins/html-effectiveness/templates/12-incident-report.html.tmpl +547 -0
- package/plugins/html-effectiveness/templates/13-flowchart-diagram.html.tmpl +361 -0
- package/plugins/html-effectiveness/templates/14-research-feature-explainer.html.tmpl +348 -0
- package/plugins/html-effectiveness/templates/15-research-concept-explainer.html.tmpl +334 -0
- package/plugins/html-effectiveness/templates/16-implementation-plan.html.tmpl +657 -0
- package/plugins/html-effectiveness/templates/17-pr-writeup.html.tmpl +553 -0
- package/plugins/html-effectiveness/templates/18-editor-triage-board.html.tmpl +541 -0
- package/plugins/html-effectiveness/templates/19-editor-feature-flags.html.tmpl +627 -0
- package/plugins/html-effectiveness/templates/20-editor-prompt-tuner.html.tmpl +687 -0
- package/plugins/html-effectiveness/templates/manifest.json +436 -2
- package/plugins/html-effectiveness/tests/_tmp.test.js +58 -0
- package/plugins/html-effectiveness/tests/fixtures/01-exploration-code-approaches.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/02-exploration-visual-designs.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/03-code-review-pr.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/04-code-understanding.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/05-design-system.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/06-component-variants.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/07-prototype-animation.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/08-prototype-interaction.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/09-slide-deck.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/10-svg-illustrations.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/11-status-report.data.json +37 -0
- package/plugins/html-effectiveness/tests/fixtures/12-incident-report.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/13-flowchart-diagram.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/14-research-feature-explainer.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/15-research-concept-explainer.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/16-implementation-plan.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/17-pr-writeup.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/18-editor-triage-board.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/19-editor-feature-flags.data.json +3 -0
- package/plugins/html-effectiveness/tests/fixtures/20-editor-prompt-tuner.data.json +3 -0
- package/plugins/html-effectiveness/tests/manifest.test.js +61 -0
- package/plugins/plugin-validator/.claude-plugin/plugin.json +1 -1
- package/plugins/plugin-validator/skills/validate-agents/SKILL.md +2 -2
- package/plugins/plugin-validator/skills/validate-commands/SKILL.md +2 -2
- package/plugins/plugin-validator/skills/validate-hooks/SKILL.md +57 -18
- package/plugins/team-superpower/.claude-plugin/plugin.json +7 -39
- package/plugins/team-superpower/README.md +73 -19
- package/plugins/team-superpower/agents/backend-developer.md +33 -0
- package/plugins/team-superpower/agents/designer.md +5 -1
- package/plugins/team-superpower/agents/frontend-developer.md +33 -0
- package/plugins/team-superpower/agents/planner.md +31 -11
- package/plugins/team-superpower/agents/qa-engineer.md +30 -0
- package/plugins/team-superpower/agents/reviewer.md +37 -21
- package/plugins/team-superpower/agents/security-engineer.md +30 -0
- package/plugins/team-superpower/agents/software-architect.md +30 -0
- package/plugins/team-superpower/assets/ESCALATION.md +19 -5
- package/plugins/team-superpower/assets/SESSION_README.md +31 -11
- package/plugins/team-superpower/commands/team-feature-resume.md +40 -5
- package/plugins/team-superpower/commands/team-feature.md +148 -22
- package/plugins/team-superpower/hooks/hooks.json +0 -3
- package/plugins/tech-graph/.claude-plugin/plugin.json +1 -1
- package/plugins/tech-graph/agents/tech-graph.md +8 -0
- package/plugins/team-superpower/agents/implementer.md +0 -46
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { test } from 'node:test';
|
|
2
|
+
import assert from 'node:assert/strict';
|
|
3
|
+
import { existsSync, readFileSync } from 'node:fs';
|
|
4
|
+
import { dirname, join } from 'node:path';
|
|
5
|
+
import { fileURLToPath } from 'node:url';
|
|
6
|
+
|
|
7
|
+
const HERE = dirname(fileURLToPath(import.meta.url));
|
|
8
|
+
const PLUGIN_ROOT = dirname(HERE);
|
|
9
|
+
const MANIFEST = JSON.parse(readFileSync(join(PLUGIN_ROOT, 'templates/manifest.json'), 'utf8'));
|
|
10
|
+
const VALID_BUNDLES = new Set(['base', 'components', 'charts']);
|
|
11
|
+
|
|
12
|
+
const entries = Object.entries(MANIFEST).filter(([k]) => k !== '_meta');
|
|
13
|
+
|
|
14
|
+
test('manifest declares 20 vendored templates', () => {
|
|
15
|
+
assert.equal(entries.length, 20, `expected 20 entries, got ${entries.length}`);
|
|
16
|
+
});
|
|
17
|
+
|
|
18
|
+
test('_meta records upstream SHA and fetch date', () => {
|
|
19
|
+
const meta = MANIFEST._meta;
|
|
20
|
+
assert.ok(meta, '_meta missing');
|
|
21
|
+
assert.match(meta.upstream_sha, /^[0-9a-f]{40}$/, 'upstream_sha must be 40-char hex');
|
|
22
|
+
assert.match(meta.fetched_at, /^\d{4}-\d{2}-\d{2}$/, 'fetched_at must be YYYY-MM-DD');
|
|
23
|
+
assert.equal(meta.upstream_repo, 'ThariqS/html-effectiveness');
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
for (const [id, entry] of entries) {
|
|
27
|
+
test(`${id}: required fields present`, () => {
|
|
28
|
+
for (const f of ['title', 'use_cases', 'pattern', 'slots', 'asset_bundles']) {
|
|
29
|
+
assert.ok(f in entry, `${id} missing field "${f}"`);
|
|
30
|
+
}
|
|
31
|
+
assert.ok(Array.isArray(entry.use_cases), `${id} use_cases must be array`);
|
|
32
|
+
assert.ok(entry.use_cases.length > 0, `${id} use_cases must be non-empty`);
|
|
33
|
+
assert.equal(typeof entry.pattern, 'string', `${id} pattern must be string`);
|
|
34
|
+
assert.equal(typeof entry.slots, 'object', `${id} slots must be object`);
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
test(`${id}: asset_bundles valid`, () => {
|
|
38
|
+
assert.ok(Array.isArray(entry.asset_bundles), `${id} asset_bundles not array`);
|
|
39
|
+
for (const b of entry.asset_bundles) {
|
|
40
|
+
assert.ok(VALID_BUNDLES.has(b), `${id} asset_bundles contains invalid "${b}"`);
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
|
|
44
|
+
test(`${id}: template file exists`, () => {
|
|
45
|
+
const tmplRel = entry.tmpl || `templates/${id}.html.tmpl`;
|
|
46
|
+
const tmplAbs = join(PLUGIN_ROOT, tmplRel);
|
|
47
|
+
assert.ok(existsSync(tmplAbs), `${id} template file missing: ${tmplRel}`);
|
|
48
|
+
});
|
|
49
|
+
|
|
50
|
+
test(`${id}: fixture file exists`, () => {
|
|
51
|
+
const fix = join(PLUGIN_ROOT, `tests/fixtures/${id}.data.json`);
|
|
52
|
+
assert.ok(existsSync(fix), `${id} fixture missing: tests/fixtures/${id}.data.json`);
|
|
53
|
+
const data = JSON.parse(readFileSync(fix, 'utf8'));
|
|
54
|
+
for (const [slot, schemaRaw] of Object.entries(entry.slots)) {
|
|
55
|
+
const schema = typeof schemaRaw === 'string' ? { type: schemaRaw } : schemaRaw;
|
|
56
|
+
if (schema.required) {
|
|
57
|
+
assert.ok(slot in data, `${id} fixture missing required slot "${slot}"`);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
});
|
|
61
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "plugin-validator",
|
|
3
3
|
"displayName": "Plugin Validator",
|
|
4
|
-
"version": "0.0.
|
|
4
|
+
"version": "0.0.14",
|
|
5
5
|
"description": "Orchestrated validator for Claude Code plugins — validates skills, agents, commands, and hooks across every plugin under plugins/**.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Steven Hoang"
|
|
@@ -18,7 +18,7 @@ find plugins -path '*/agents/*.md'
|
|
|
18
18
|
find plugins -path '*/.claude-plugin/plugin.json'
|
|
19
19
|
```
|
|
20
20
|
|
|
21
|
-
For each `plugin.json`, parse
|
|
21
|
+
For each `plugin.json`, parse the optional `agents` field if present (see "`agents` field rule" below). Then validate every agent `.md` file as below.
|
|
22
22
|
|
|
23
23
|
## Spec Compliance Checks
|
|
24
24
|
|
|
@@ -30,7 +30,7 @@ For each `plugin.json`, parse and check whether the `agents` key is present (any
|
|
|
30
30
|
| `description` length | 1-1024 chars, non-empty |
|
|
31
31
|
| `tools` optional | Comma-separated string; each name appears in the valid-tool list below |
|
|
32
32
|
| `model` optional | One of `sonnet`, `opus`, `haiku`, `inherit` |
|
|
33
|
-
|
|
|
33
|
+
| `agents` field rule | Optional. Per https://code.claude.com/docs/en/plugins-reference#component-path-fields, value is `string` or `array`. Each entry must be a relative path starting with `./` (per "Path behavior rules"). If field is absent, agents are auto-discovered from `<plugin>/agents/*.md`. **Failure modes**: (a) value type other than string/array → `[FAIL]`. (b) entry does not start with `./` → `[FAIL]` (loader rejects with `agents: Invalid input` for bare filenames like `"reviewer.md"`). (c) entry points outside plugin root (contains `..`) → `[FAIL]`. (d) entry path does not exist on disk → `[FAIL]`. (e) field present and replaces the default `agents/` directory while files there exist that are not listed → `[WARN]` (loader silently drops them; v2.1.140+ shows `/doctor` warning). |
|
|
34
34
|
|
|
35
35
|
### Valid tool names (Claude Code ≥ 2.1.139)
|
|
36
36
|
|
|
@@ -18,7 +18,7 @@ find plugins -path '*/commands/*.md'
|
|
|
18
18
|
find plugins -path '*/.claude-plugin/plugin.json'
|
|
19
19
|
```
|
|
20
20
|
|
|
21
|
-
For each `plugin.json`, parse
|
|
21
|
+
For each `plugin.json`, parse the optional `commands` field if present (see "`commands` field rule" below). Then validate every command `.md` file as below.
|
|
22
22
|
|
|
23
23
|
## Spec Compliance Checks
|
|
24
24
|
|
|
@@ -31,7 +31,7 @@ For each `plugin.json`, parse and check whether the `commands` key is present (a
|
|
|
31
31
|
| `model` optional | One of `sonnet`, `opus`, `haiku`, `inherit` |
|
|
32
32
|
| Filename → command | Filename minus `.md` is lowercase alphanumeric + hyphens; produces `/<filename>` |
|
|
33
33
|
| Body non-empty | At least one non-blank line after frontmatter |
|
|
34
|
-
|
|
|
34
|
+
| `commands` field rule | Optional. Per https://code.claude.com/docs/en/plugins-reference#component-path-fields, value is `string` or `array`. Each entry must be a relative path starting with `./` (per "Path behavior rules"). If field is absent, commands are auto-discovered from `<plugin>/commands/*.md`. **Failure modes**: (a) value type other than string/array → `[FAIL]`. (b) entry does not start with `./` → `[FAIL]` (loader rejects with `commands: Invalid input` for bare filenames). (c) entry points outside plugin root (contains `..`) → `[FAIL]`. (d) entry path does not exist on disk → `[FAIL]`. (e) field present and replaces the default `commands/` directory while files there exist that are not listed → `[WARN]` (loader silently drops them; v2.1.140+ shows `/doctor` warning). |
|
|
35
35
|
|
|
36
36
|
### Valid tool names (Claude Code ≥ 2.1.139)
|
|
37
37
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: validate-hooks
|
|
3
|
-
description: Validates plugin hooks (plugin.json hooks field and any
|
|
3
|
+
description: Validates plugin hooks (plugin.json hooks field and any hooks/hooks.json) in plugins/** against the Claude Code plugin spec. Use via /validate-hooks command.
|
|
4
4
|
license: MIT
|
|
5
5
|
metadata:
|
|
6
6
|
author: Steven Hoang
|
|
@@ -9,37 +9,74 @@ metadata:
|
|
|
9
9
|
|
|
10
10
|
# Validate Hooks
|
|
11
11
|
|
|
12
|
-
Validate plugin hooks under `plugins/**` against the Claude Code plugin spec. Scope: `plugins/**` only — local-only `.claude/
|
|
12
|
+
Validate plugin hooks under `plugins/**` against the Claude Code plugin spec (https://code.claude.com/docs/en/hooks, https://code.claude.com/docs/en/plugins-reference#hooks). Scope: `plugins/**` only — local-only `.claude/hooks/` is out of scope.
|
|
13
13
|
|
|
14
14
|
## Discovery
|
|
15
15
|
|
|
16
16
|
```bash
|
|
17
|
-
find plugins -name 'hooks.json'
|
|
18
|
-
find plugins -name 'plugin.json' -path '*/.claude-plugin/*'
|
|
17
|
+
/usr/bin/find plugins -name 'hooks.json'
|
|
18
|
+
/usr/bin/find plugins -name 'plugin.json' -path '*/.claude-plugin/*'
|
|
19
19
|
```
|
|
20
20
|
|
|
21
|
-
|
|
21
|
+
For each `plugin.json`, classify the `hooks` field:
|
|
22
|
+
|
|
23
|
+
| Form | Action |
|
|
24
|
+
|------|--------|
|
|
25
|
+
| absent | Use auto-discovery: validate `<plugin_root>/hooks/hooks.json` if it exists. If neither field nor file exist, plugin has no hooks — skip. |
|
|
26
|
+
| string path | Resolve relative to plugin root, parse referenced JSON, validate. |
|
|
27
|
+
| array of paths | Resolve each, parse, validate each. |
|
|
28
|
+
| object (inline config) | Validate inline. |
|
|
29
|
+
|
|
30
|
+
All four forms are spec-legal. **Do not flag the `hooks` field for being a string, array, or object.**
|
|
31
|
+
|
|
32
|
+
If both inline `hooks` and `hooks/hooks.json` exist, emit `[WARN]` — duplication invites drift; pick one source of truth.
|
|
22
33
|
|
|
23
34
|
## Spec Compliance Checks
|
|
24
35
|
|
|
25
36
|
| Check | Rule |
|
|
26
37
|
|-------|------|
|
|
27
|
-
|
|
|
28
|
-
|
|
|
29
|
-
| Event value | Array of matcher groups |
|
|
30
|
-
| Matcher group shape | `{ matcher
|
|
31
|
-
| Hook entry
|
|
32
|
-
|
|
|
33
|
-
|
|
|
34
|
-
|
|
|
38
|
+
| Top-level container | The hooks config is an object with a single `hooks` key whose value is an object keyed by event name. |
|
|
39
|
+
| Event name in allowlist | One of the 28 events below. |
|
|
40
|
+
| Event value | Array of matcher groups. |
|
|
41
|
+
| Matcher group shape | `{ matcher?: string, hooks: [...] }` (matcher optional). |
|
|
42
|
+
| Hook entry `type` | One of: `command`, `http`, `mcp_tool`, `prompt`, `agent`. |
|
|
43
|
+
| Hook entry shape (command) | `{ type: "command", command: string, args?: array, timeout?: integer, statusMessage?: string, if?: string, once?: boolean }`. |
|
|
44
|
+
| Hook entry shape (http) | `{ type: "http", url: string, headers?: object, timeout?: integer, ... }`. |
|
|
45
|
+
| Hook entry shape (mcp_tool) | `{ type: "mcp_tool", server: string, tool: string, ... }`. |
|
|
46
|
+
| Hook entry shape (prompt) | `{ type: "prompt", prompt: string, model?: string, timeout?: integer, ... }`. |
|
|
47
|
+
| Hook entry shape (agent) | `{ type: "agent", agent: string, prompt?: string, timeout?: integer, ... }`. |
|
|
48
|
+
| Command path resolves | Resolves relative to plugin root, or uses `${CLAUDE_PROJECT_DIR}` / `${CLAUDE_PLUGIN_ROOT}`. |
|
|
49
|
+
| Executable bit | Referenced shell script has `+x`. |
|
|
50
|
+
| Regex compiles | Matcher value compiles as a Python `re` pattern (only checked when matcher contains characters outside `[A-Za-z0-9_|]`). |
|
|
51
|
+
|
|
52
|
+
### Allowed event names (28)
|
|
53
|
+
|
|
54
|
+
```
|
|
55
|
+
SessionStart, Setup, InstructionsLoaded, UserPromptSubmit, UserPromptExpansion,
|
|
56
|
+
PreToolUse, PermissionRequest, PermissionDenied, PostToolUse, PostToolUseFailure,
|
|
57
|
+
PostToolBatch, Notification, SubagentStart, SubagentStop,
|
|
58
|
+
TaskCreated, TaskCompleted, Stop, StopFailure, TeammateIdle,
|
|
59
|
+
ConfigChange, CwdChanged, FileChanged, WorktreeCreate, WorktreeRemove,
|
|
60
|
+
PreCompact, PostCompact, SessionEnd, Elicitation, ElicitationResult
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
### Events that do NOT support `matcher`
|
|
64
|
+
|
|
65
|
+
```
|
|
66
|
+
UserPromptSubmit, PostToolBatch, Stop, TeammateIdle,
|
|
67
|
+
TaskCreated, TaskCompleted, WorktreeCreate, WorktreeRemove, CwdChanged
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
If a matcher group under one of these events sets a `matcher` field, emit `[WARN]` — the field is silently ignored by the loader. Not a `[FAIL]`.
|
|
35
71
|
|
|
36
72
|
## Best-Practice Checks
|
|
37
73
|
|
|
38
74
|
| Check | Rule |
|
|
39
75
|
|-------|------|
|
|
40
|
-
| No absolute user paths | Body of command does not contain `/Users/<name>/...` or `/home/<name
|
|
41
|
-
| Timeout sane | `timeout` ≤ 60 unless inline comment justifies |
|
|
42
|
-
| Prompt
|
|
76
|
+
| No absolute user paths | Body of `command` does not contain `/Users/<name>/...` or `/home/<name>/...`. |
|
|
77
|
+
| Timeout sane | `timeout` ≤ 60 unless inline comment justifies. |
|
|
78
|
+
| Prompt/agent targets exist | `prompt`-type and `agent`-type hooks reference skills, commands, or agents that exist on disk. |
|
|
79
|
+
| `${CLAUDE_PLUGIN_ROOT}` quoting | Shell-form commands wrap `${CLAUDE_PLUGIN_ROOT}` in double quotes (path may contain spaces). |
|
|
43
80
|
|
|
44
81
|
## How to Run
|
|
45
82
|
|
|
@@ -52,13 +89,15 @@ Parse each `plugin.json`. If its `hooks` field is an inline object, validate inl
|
|
|
52
89
|
|
|
53
90
|
### plugins/<plugin>/<file>
|
|
54
91
|
- [PASS] <check description>
|
|
92
|
+
- [WARN] <check description>: <details>
|
|
55
93
|
- [FAIL] <check description>: <details>
|
|
56
94
|
```
|
|
57
95
|
|
|
58
|
-
4. Final tally: `Summary: <N> hooks files scanned. <P> pass, <F> fail.`
|
|
96
|
+
4. Final tally: `Summary: <N> hooks files scanned. <P> pass, <F> fail, <W> warn.`
|
|
59
97
|
|
|
60
98
|
## References
|
|
61
99
|
|
|
62
|
-
-
|
|
100
|
+
- Hook event lifecycle: https://code.claude.com/docs/en/hooks
|
|
101
|
+
- Plugin hook location + types: https://code.claude.com/docs/en/plugins-reference#hooks
|
|
63
102
|
- Resolution evidence: see `docs/superpowers/specs/2026-05-13-plugin-validation-skills-design.md` § Resolution 1
|
|
64
103
|
- Sibling skills: `validate-skills`, `validate-agents`, `validate-commands`
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "team-superpower",
|
|
3
3
|
"displayName": "Team Superpower",
|
|
4
|
-
"version": "0.0.
|
|
5
|
-
"description": "Coordination layer that runs the obra/superpowers skill chain across a Claude Code agent team — one /team-feature command takes an idea through
|
|
4
|
+
"version": "0.0.14",
|
|
5
|
+
"description": "Coordination layer that runs the obra/superpowers skill chain across a Claude Code agent team — one /team-feature command takes an idea through design, plan, pre-impl architecture+security gate, BE/FE implementation, QA gate, code review, and finish with at most 3 owner touchpoints.",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "Steven Hoang"
|
|
8
8
|
},
|
|
@@ -13,41 +13,9 @@
|
|
|
13
13
|
"orchestration",
|
|
14
14
|
"workflow",
|
|
15
15
|
"brainstorming",
|
|
16
|
-
"code-review"
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
"
|
|
20
|
-
|
|
21
|
-
"matcher": "*",
|
|
22
|
-
"hooks": [
|
|
23
|
-
{
|
|
24
|
-
"type": "command",
|
|
25
|
-
"command": "${CLAUDE_PLUGIN_ROOT}/hooks/teammate-idle.sh"
|
|
26
|
-
}
|
|
27
|
-
]
|
|
28
|
-
}
|
|
29
|
-
],
|
|
30
|
-
"TaskCreated": [
|
|
31
|
-
{
|
|
32
|
-
"matcher": "*",
|
|
33
|
-
"hooks": [
|
|
34
|
-
{
|
|
35
|
-
"type": "command",
|
|
36
|
-
"command": "${CLAUDE_PLUGIN_ROOT}/hooks/task-created.sh"
|
|
37
|
-
}
|
|
38
|
-
]
|
|
39
|
-
}
|
|
40
|
-
],
|
|
41
|
-
"TaskCompleted": [
|
|
42
|
-
{
|
|
43
|
-
"matcher": "*",
|
|
44
|
-
"hooks": [
|
|
45
|
-
{
|
|
46
|
-
"type": "command",
|
|
47
|
-
"command": "${CLAUDE_PLUGIN_ROOT}/hooks/task-completed.sh"
|
|
48
|
-
}
|
|
49
|
-
]
|
|
50
|
-
}
|
|
51
|
-
]
|
|
52
|
-
}
|
|
16
|
+
"code-review",
|
|
17
|
+
"architecture",
|
|
18
|
+
"security",
|
|
19
|
+
"qa"
|
|
20
|
+
]
|
|
53
21
|
}
|
|
@@ -1,34 +1,51 @@
|
|
|
1
1
|
# team-superpower
|
|
2
2
|
|
|
3
|
-
Coordination layer that runs the [obra/superpowers](https://github.com/obra/superpowers) skill chain across a Claude Code **agent team**. One `/team-feature` command takes an idea through
|
|
3
|
+
Coordination layer that runs the [obra/superpowers](https://github.com/obra/superpowers) skill chain across a Claude Code **agent team**. One `/team-feature` command takes an idea through design → plan → architecture + security gate → BE/FE implementation → QA gate → code review → finish, with at most **3 owner touchpoints**.
|
|
4
4
|
|
|
5
|
-
This plugin is *not* a fork of Superpowers. It consumes Superpowers skills as-installed and
|
|
5
|
+
This plugin is *not* a fork of Superpowers. It consumes Superpowers skills as-installed and adds the orchestration: who runs which skill, when, and how teammates talk without bothering the owner.
|
|
6
6
|
|
|
7
7
|
## What you get
|
|
8
8
|
|
|
9
9
|
- Three slash commands: `/team-feature`, `/team-feature-resume`, `/team-cleanup`.
|
|
10
|
-
-
|
|
11
|
-
- `designer` — runs `brainstorming
|
|
12
|
-
- `planner` — runs `using-git-worktrees
|
|
13
|
-
- `
|
|
14
|
-
- `
|
|
10
|
+
- **Eight agent roles**, each with a tightly-scoped system prompt mapping it to specific Superpowers skills or gate behaviour:
|
|
11
|
+
- `designer` — runs `brainstorming` (phase 1).
|
|
12
|
+
- `planner` — runs `using-git-worktrees` then `writing-plans` (phase 2). Routes implementation by `impl:be-` / `impl:fe-` prefix.
|
|
13
|
+
- `software-architect` — phase-3 pre-impl architecture gate. Reviews design + plan. Posts `ARCH_PASSED` / `ARCH_BLOCKED`.
|
|
14
|
+
- `security-engineer` — phase-3 pre-impl security gate, parallel with `software-architect`. Threat-models design + plan. Posts `SEC_PASSED` / `SEC_BLOCKED`.
|
|
15
|
+
- `backend-developer` — phase-4 implementer for `impl:be-` tasks (server, data, infra, CI). Runs `subagent-driven-development` + `test-driven-development` per task.
|
|
16
|
+
- `frontend-developer` — phase-4 implementer for `impl:fe-` tasks. Same skill chain.
|
|
17
|
+
- `qa-engineer` — phase-5 post-impl QA gate. Verifies acceptance criteria + regression coverage. Posts `QA_PASSED` / `QA_BLOCKED`.
|
|
18
|
+
- `reviewer` — phase-6 runs `requesting-code-review`; phase-7 runs `finishing-a-development-branch`.
|
|
15
19
|
- Three guardrail hooks (registered automatically via `hooks/hooks.json`):
|
|
16
20
|
- `TeammateIdle` — refuses idle while peer mail is unanswered.
|
|
17
|
-
- `TaskCreated` — enforces `impl
|
|
21
|
+
- `TaskCreated` — enforces `impl:` / `review:` / `meta:` / `block:` task title prefixes.
|
|
18
22
|
- `TaskCompleted` — gates `impl:` completions on `plan_approved_at` and validates escalation entries.
|
|
19
|
-
- `scripts/team-state.sh` —
|
|
23
|
+
- `scripts/team-state.sh` — inspection + cleanup helper. Called by the slash commands; also runnable directly.
|
|
20
24
|
- Robustness primitives baked into the workflow:
|
|
21
25
|
- **Preflight scan** in `/team-feature` and `/team-feature-resume` — detects orphaned team config, stale task lists, and in-flight runs before doing anything destructive.
|
|
26
|
+
- **Two gate phases** (pre-impl arch+security, post-impl QA) — block forward progress until findings resolve, so the reviewer at phase 6 sees clean code-quality issues only, not architectural or security regressions.
|
|
22
27
|
- **Heartbeat file** at `docs/superpowers/sessions/<slug>.heartbeat` — touched at every phase boundary; cleanup refuses to wipe state while the heartbeat is fresh.
|
|
23
28
|
- **Atomic checkpoint writes** (tmp + rename) — half-written checkpoints can't corrupt recovery.
|
|
24
29
|
- **Automatic cleanup after `FINISH_DONE`** — the lead verifies all phases complete, all commits in place, teammates idle, then runs the canonical "clean up the team" primitive followed by a verification scan. No manual `rm -rf` required.
|
|
25
30
|
- **`/team-cleanup [slug]`** for the case where a previous lead crashed and the canonical cleanup path is no longer available.
|
|
26
31
|
- Templates seeded into your project on first use: `docs/superpowers/ESCALATION.md` (escalation template + 2 worked examples) and `docs/superpowers/README.md` (onboarding + troubleshooting).
|
|
27
32
|
|
|
33
|
+
## Phase chain at a glance
|
|
34
|
+
|
|
35
|
+
| Phase | Role(s) | Output | Gate? |
|
|
36
|
+
|---|---|---|---|
|
|
37
|
+
| 1 Design | `designer` | Design doc → `docs/superpowers/specs/` | Owner approval |
|
|
38
|
+
| 2 Plan | `planner` | Worktree + plan with `impl:be-` / `impl:fe-` tasks → `docs/superpowers/plans/` | Owner approval |
|
|
39
|
+
| 3 Pre-impl review (parallel) | `software-architect` + `security-engineer` | ARCH + SEC reports → `docs/superpowers/reviews/` | Both must post PASSED |
|
|
40
|
+
| 4 Implementation (parallel) | `backend-developer` + `frontend-developer` | TDD commits on feature branch | All `impl:` tasks complete |
|
|
41
|
+
| 5 QA | `qa-engineer` | QA report → `docs/superpowers/reviews/` | `QA_PASSED` |
|
|
42
|
+
| 6 Code review | `reviewer` | Review report → `docs/superpowers/reviews/` | `REVIEW_PASSED` |
|
|
43
|
+
| 7 Finish | `reviewer` | Merge / PR / keep / discard | Owner decision |
|
|
44
|
+
|
|
28
45
|
## Requirements
|
|
29
46
|
|
|
30
47
|
- Claude Code `2.1.32` or later.
|
|
31
|
-
- `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` in your environment (the slash command
|
|
48
|
+
- `CLAUDE_CODE_EXPERIMENTAL_AGENT_TEAMS=1` in your environment (the slash command halts if absent).
|
|
32
49
|
- The Superpowers plugin installed: `/plugin install superpowers@claude-plugins-official`.
|
|
33
50
|
- `jq` on `$PATH` (the hooks degrade to log-only when missing, but you want them enforcing).
|
|
34
51
|
|
|
@@ -54,15 +71,30 @@ Then make sure the agent-teams env flag is set in `~/.claude/settings.json`:
|
|
|
54
71
|
/team-feature add a /healthcheck endpoint that returns 200 OK
|
|
55
72
|
```
|
|
56
73
|
|
|
57
|
-
You will be interrupted at most
|
|
74
|
+
You will be interrupted at most three times:
|
|
58
75
|
|
|
59
|
-
1.
|
|
60
|
-
2.
|
|
61
|
-
3.
|
|
62
|
-
4. Finish-branch decision (merge / PR / keep / discard).
|
|
76
|
+
1. Design sign-off (after phase 1).
|
|
77
|
+
2. Plan approval (after phase 2).
|
|
78
|
+
3. Finish-branch decision — merge / PR / keep / discard (in phase 7).
|
|
63
79
|
|
|
64
80
|
Anything else that reaches you uses the escalation template in `docs/superpowers/ESCALATION.md`. If a teammate pings you without using the template, that's a bug — file it.
|
|
65
81
|
|
|
82
|
+
## Task prefix routing
|
|
83
|
+
|
|
84
|
+
The planner assigns every `impl:` task one of two sub-prefixes; the lead routes by prefix:
|
|
85
|
+
|
|
86
|
+
| Prefix | Routed to | Scope |
|
|
87
|
+
|---|---|---|
|
|
88
|
+
| `impl:be-` | `backend-developer` | Server-side code, APIs, data, schemas, migrations, infra / CI scripts, Docker, IaC |
|
|
89
|
+
| `impl:fe-` | `frontend-developer` | UI components, pages, client-side state, styles, browser assets |
|
|
90
|
+
|
|
91
|
+
Defect-fix tasks filed mid-flight inherit the routing prefix:
|
|
92
|
+
|
|
93
|
+
| Prefix | Filed by | Routed to |
|
|
94
|
+
|---|---|---|
|
|
95
|
+
| `impl:qa-fix-be-` / `impl:qa-fix-fe-` | `qa-engineer` (phase 5) | matching BE / FE implementer |
|
|
96
|
+
| `impl:review-fix-be-` / `impl:review-fix-fe-` | `reviewer` (phase 6) | matching BE / FE implementer |
|
|
97
|
+
|
|
66
98
|
## Resume after `/resume` drops the team
|
|
67
99
|
|
|
68
100
|
```text
|
|
@@ -95,13 +127,30 @@ bash plugins/team-superpower/scripts/team-state.sh cleanup <slug> --force # app
|
|
|
95
127
|
|
|
96
128
|
`/team-feature` runs cleanup automatically the instant the reviewer reports `FINISH_DONE` (merge / PR / keep / discard). Before wiping anything, the lead verifies:
|
|
97
129
|
|
|
98
|
-
- every phase from
|
|
130
|
+
- every phase from design through finish is complete in the checkpoint
|
|
99
131
|
- the shared task list has zero in-progress tasks
|
|
100
|
-
- the expected commits exist on the worktree (design, plan, TDD pairs of test + code, review report, and any merge / PR-prep commit per the finish decision)
|
|
132
|
+
- the expected commits exist on the worktree (design, plan, ARCH+SEC reports, TDD pairs of test + code, QA report, code-review report, and any merge / PR-prep commit per the finish decision)
|
|
101
133
|
- all teammates are idle and shut down
|
|
102
134
|
|
|
103
135
|
Only then does it invoke the canonical "clean up the team" primitive, verify with a scan that `~/.claude/teams/superpower-<slug>/` is gone, and append a `## Closing` block to the checkpoint. If any step fails, the lead halts and instructs the owner to run `/team-cleanup <slug>` manually. **No `rm -rf` runs on a half-finished feature.**
|
|
104
136
|
|
|
137
|
+
### Worktree removal on merge
|
|
138
|
+
|
|
139
|
+
When (and only when) the finish decision is `merged` AND the platform-cleanup scan shows everything `absent`, the lead now runs a Step D.5 worktree removal between team cleanup and the final checkpoint commit. `git worktree remove <path>` is non-forced by default; the feature branch is left in place (only the worktree directory is removed). If `git worktree remove` fails (untracked files, locked worktree, in-progress git operation), the lead presents a 4-option menu:
|
|
140
|
+
|
|
141
|
+
| | Option | Behaviour |
|
|
142
|
+
|---|---|---|
|
|
143
|
+
| A | Show files + retry | Lists blocking files via `git status --short` + `git diff --stat`, then retries (cap 3). |
|
|
144
|
+
| B | Force remove | Discards uncommitted work in the worktree (requires typed `yes` confirmation). |
|
|
145
|
+
| C | Keep worktree | Leaves the directory on disk; owner removes manually. |
|
|
146
|
+
| D | Escalate | §7 escalation with verbatim stderr. |
|
|
147
|
+
|
|
148
|
+
Other finish decisions (`pr_opened`, `kept`, `discarded`) skip Step D.5 — the worktree stays so the owner can keep working in it or inspect artefacts. The Closing block records the outcome with a `worktree:` field.
|
|
149
|
+
|
|
150
|
+
### Merge-failure menu
|
|
151
|
+
|
|
152
|
+
If the reviewer's merge step in phase 7 fails (`conflict` / `non-ff` / `dirty-worktree` / `push-rejected`), it posts `FINISH_BLOCKED <reason>` instead of `FINISH_DONE`. The lead surfaces a 5-option menu — retry / switch to pr_opened / switch to kept / switch to discarded / escalate — counted as the same finish-branch touchpoint, not a new one. Retries cap at 3; after the 3rd `FINISH_BLOCKED`, option A drops. The cap persists across `/team-feature-resume` via the checkpoint.
|
|
153
|
+
|
|
105
154
|
## Layout
|
|
106
155
|
|
|
107
156
|
```
|
|
@@ -111,7 +160,11 @@ plugins/team-superpower/
|
|
|
111
160
|
├── agents/
|
|
112
161
|
│ ├── designer.md
|
|
113
162
|
│ ├── planner.md
|
|
114
|
-
│ ├──
|
|
163
|
+
│ ├── software-architect.md
|
|
164
|
+
│ ├── security-engineer.md
|
|
165
|
+
│ ├── backend-developer.md
|
|
166
|
+
│ ├── frontend-developer.md
|
|
167
|
+
│ ├── qa-engineer.md
|
|
115
168
|
│ └── reviewer.md
|
|
116
169
|
├── commands/
|
|
117
170
|
│ ├── team-feature.md
|
|
@@ -136,6 +189,7 @@ See the project's `docs/superpowers/README.md` after first run for the operating
|
|
|
136
189
|
- The **lead** is a conductor. It never runs a Superpowers skill itself.
|
|
137
190
|
- Teammates run **canonical, unmodified** Superpowers skills. They are forbidden from paraphrasing or replacing them.
|
|
138
191
|
- TDD is enforced by `subagent-driven-development` + `test-driven-development` per implementer task. The `TaskCompleted` hook is a backstop, not the primary control.
|
|
192
|
+
- **Two gate phases** keep the reviewer's job small. Architecture and security issues are caught at phase 3 (pre-impl) so implementers don't waste cycles on plans that fail review. QA defects are caught at phase 5 (post-impl) so the reviewer at phase 6 only deals with code-quality findings.
|
|
139
193
|
- All cross-team chatter that needs an owner decision goes through the §7 escalation template. The hook spot-checks the template fields and refuses malformed escalations.
|
|
140
194
|
- Every phase boundary writes a checkpoint to `docs/superpowers/sessions/<slug>.md`. That's the only thing that survives a `/resume` failure — the slash command `/team-feature-resume` reads it back.
|
|
141
195
|
|
|
@@ -143,7 +197,7 @@ See the project's `docs/superpowers/README.md` after first run for the operating
|
|
|
143
197
|
|
|
144
198
|
- Token-usage metrics per teammate per phase.
|
|
145
199
|
- Per-role permission allowlists.
|
|
146
|
-
-
|
|
200
|
+
- Standalone devops, technical-writer, or minimal-change-engineer roles — infra/CI folds into `backend-developer`; documentation lands in PR descriptions and inline; minimal-change patterns are scoped per task by the planner.
|
|
147
201
|
|
|
148
202
|
## License
|
|
149
203
|
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: backend-developer
|
|
3
|
+
description: Specialised phase-4 implementer for server-side, infrastructure, and CI tasks. Claims `impl:be-` prefixed tasks from the shared task list. Scoped to routes, services, repositories, schemas, migrations, config, build/deploy pipelines.
|
|
4
|
+
tools: Read, Write, Edit, Bash, Glob, Grep
|
|
5
|
+
model: sonnet
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Backend Developer — Phase 4 (Implementation)
|
|
9
|
+
|
|
10
|
+
You are a **backend-developer** teammate. You are a specialised implementer covering server-side AND infrastructure/CI work. Your only job: claim `impl:be-` prefixed tasks from the shared task list and complete each through the canonical Superpowers chain.
|
|
11
|
+
|
|
12
|
+
## Hard rules
|
|
13
|
+
|
|
14
|
+
1. Run the unmodified Superpowers `subagent-driven-development` skill for every task. Read `~/.claude/plugins/cache/claude-plugins-official/superpowers/5.1.0/skills/subagent-driven-development/SKILL.md` before claiming your first task.
|
|
15
|
+
2. Every code change MUST follow the canonical `test-driven-development` skill: RED → GREEN → REFACTOR. If you wrote production code before a failing test existed, delete it and restart. Non-negotiable.
|
|
16
|
+
3. You are scoped to: routes, services, repositories, schemas, migrations, server config, build scripts, CI / deploy pipeline files, Dockerfiles, IaC. Do NOT touch frontend files (`components/`, `pages/`, browser `assets/`). If a task bleeds into frontend scope, halt and escalate.
|
|
17
|
+
4. You **may not** modify the plan or the design. If the plan is wrong, escalate via the §7 template — `software-architect` + `security-engineer` already gated the plan at phase 3; raise it to the lead, not silently work around.
|
|
18
|
+
5. You handle `impl:qa-fix-` and `impl:review-fix-` tasks that touch backend files (filed by `qa-engineer` and `reviewer` respectively).
|
|
19
|
+
6. Mark a task complete only after the two-stage review inside `subagent-driven-development` passes.
|
|
20
|
+
|
|
21
|
+
## Responsibilities
|
|
22
|
+
|
|
23
|
+
Claim the lowest-numbered eligible `impl:be-` task, mark it in-progress, run subagent-driven-development, mark complete. Repeat until no eligible tasks remain, then idle.
|
|
24
|
+
|
|
25
|
+
## Output
|
|
26
|
+
|
|
27
|
+
Committed code on the feature branch per task. No separate report needed.
|
|
28
|
+
Post `BE_DONE <task-id>` to the lead's mailbox after each task completes.
|
|
29
|
+
|
|
30
|
+
## Escalation
|
|
31
|
+
|
|
32
|
+
Use the §7 template in `docs/superpowers/ESCALATION.md` for any blocker.
|
|
33
|
+
Common blockers: task scope bleeds into frontend files; plan contradicts design doc on an API contract; a migration would destroy data in an unexpected way; CI change would block other PRs already in flight.
|
|
@@ -11,13 +11,17 @@ You are the **designer** teammate on a team-superpower agent team. The lead spaw
|
|
|
11
11
|
|
|
12
12
|
## Hard rules
|
|
13
13
|
|
|
14
|
-
1. Run the unmodified Superpowers `brainstorming` skill at `~/.claude/plugins/superpowers/skills/brainstorming/SKILL.md`. Follow it verbatim. Do not invent steps, skip the visual-companion offer, or collapse the clarifying-question loop. Read the SKILL.md before you do anything else.
|
|
14
|
+
1. Run the unmodified Superpowers `brainstorming` skill at `~/.claude/plugins/cache/claude-plugins-official/superpowers/5.1.0/skills/brainstorming/SKILL.md`. Follow it verbatim. Do not invent steps, skip the visual-companion offer, or collapse the clarifying-question loop. Read the SKILL.md before you do anything else.
|
|
15
15
|
2. **Never** write code, plans, worktree commands, or anything outside `docs/superpowers/specs/`.
|
|
16
16
|
3. Save the design doc to `docs/superpowers/specs/YYYY-MM-DD-<slug>-design.md` and commit it. The brainstorming skill already prescribes this; do not deviate from its filename pattern. The `<slug>` is given to you by the lead in your spawn prompt.
|
|
17
17
|
4. Before sending a clarifying question to the owner, **post it to the lead via mailbox first**. The lead may answer from project context or escalate. Never DM the owner directly.
|
|
18
18
|
5. Every escalation you do raise MUST use the template in `docs/superpowers/ESCALATION.md`. No exceptions, even for one-line questions.
|
|
19
19
|
6. When the owner signs off on the design, post `DESIGN_APPROVED <path>` to the lead's mailbox where `<path>` is the absolute path of the design doc. Then idle.
|
|
20
20
|
|
|
21
|
+
## Output
|
|
22
|
+
|
|
23
|
+
A committed design document at `docs/superpowers/specs/YYYY-MM-DD-<slug>-design.md`, owner-approved per the brainstorming skill's sign-off step. Signals completion by posting `DESIGN_APPROVED <path>` to the lead's mailbox.
|
|
24
|
+
|
|
21
25
|
## What you must NOT do
|
|
22
26
|
|
|
23
27
|
- Decide implementation strategy. The plan is the planner's job.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: frontend-developer
|
|
3
|
+
description: Specialised phase-4 implementer for UI and component tasks. Claims `impl:fe-` prefixed tasks from the shared task list. Scoped to UI components, pages, and client-side state files.
|
|
4
|
+
tools: Read, Write, Edit, Bash, Glob, Grep
|
|
5
|
+
model: sonnet
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
# Frontend Developer — Phase 4 (Implementation)
|
|
9
|
+
|
|
10
|
+
You are a **frontend-developer** teammate. You are a specialised implementer. Your only job: claim `impl:fe-` prefixed tasks from the shared task list and complete each one through the canonical Superpowers chain.
|
|
11
|
+
|
|
12
|
+
## Hard rules
|
|
13
|
+
|
|
14
|
+
1. Run the unmodified Superpowers `subagent-driven-development` skill for every task. Read `~/.claude/plugins/cache/claude-plugins-official/superpowers/5.1.0/skills/subagent-driven-development/SKILL.md` before claiming your first task.
|
|
15
|
+
2. Every code change MUST follow the canonical `test-driven-development` skill: RED → GREEN → REFACTOR. If you wrote production code before a failing test existed, delete it and restart. Non-negotiable.
|
|
16
|
+
3. You are scoped to frontend files only: components, pages, client-side state, styles, and browser assets. Do not touch backend files (routes, services, repositories, schemas, migrations, CI pipelines). If a task bleeds into backend scope, halt and escalate.
|
|
17
|
+
4. You **may not** modify the plan or the design. If the plan is wrong, escalate via the §7 template — `software-architect` + `security-engineer` already gated the plan at phase 3; raise it to the lead, not silently work around.
|
|
18
|
+
5. You handle `impl:qa-fix-` and `impl:review-fix-` tasks that touch frontend files (filed by `qa-engineer` and `reviewer` respectively).
|
|
19
|
+
6. Mark a task complete only after the two-stage review inside `subagent-driven-development` passes.
|
|
20
|
+
|
|
21
|
+
## Responsibilities
|
|
22
|
+
|
|
23
|
+
Claim the lowest-numbered eligible `impl:fe-` task, mark it in-progress, run subagent-driven-development, mark complete. Repeat until no eligible tasks remain, then idle.
|
|
24
|
+
|
|
25
|
+
## Output
|
|
26
|
+
|
|
27
|
+
Committed code on the feature branch per task. No separate report needed.
|
|
28
|
+
Post `FE_DONE <task-id>` to the lead's mailbox after each task completes.
|
|
29
|
+
|
|
30
|
+
## Escalation
|
|
31
|
+
|
|
32
|
+
Use the §7 template in `docs/superpowers/ESCALATION.md` for any blocker.
|
|
33
|
+
Common blockers: task scope bleeds into backend files; plan specifies a component API that does not match what the backend-developer implemented; a UI behaviour is underspecified in the design doc.
|
|
@@ -1,38 +1,57 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: planner
|
|
3
|
-
description: Runs Superpowers `using-git-worktrees` then `writing-plans`. Owns phase 2
|
|
3
|
+
description: Runs Superpowers `using-git-worktrees` then `writing-plans`. Owns phase 2 of the team-superpower workflow. Halts on broken test baseline. Cannot write feature code or modify the design. Routes implementation work to `backend-developer` and `frontend-developer` via task prefixes.
|
|
4
4
|
tools: Read, Write, Bash, Glob, Grep
|
|
5
5
|
model: sonnet
|
|
6
6
|
---
|
|
7
7
|
|
|
8
|
-
# Planner — Phase 2 (Worktree
|
|
8
|
+
# Planner — Phase 2 (Worktree + Plan)
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
## Output
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
A committed worktree (signalled by `WORKTREE_READY <path> <branch>`) and a committed plan at `docs/superpowers/plans/YYYY-MM-DD-<slug>-plan.md` (signalled by `PLAN_READY <path>`). Every `impl:` task carries an `impl:be-` / `impl:fe-` sub-prefix, file-scope, and dependency metadata. On plan-revision loops (after `ARCH_BLOCKED` / `SEC_BLOCKED`), re-posts `PLAN_READY` once findings are addressed.
|
|
13
13
|
|
|
14
|
-
|
|
14
|
+
You are the **planner** teammate. You run two Superpowers skills sequentially: first `using-git-worktrees`, then `writing-plans`. Both must be the unmodified canonical versions from `~/.claude/plugins/cache/claude-plugins-official/superpowers/5.1.0/skills/`.
|
|
15
|
+
|
|
16
|
+
## Phase 2.a — `using-git-worktrees`
|
|
17
|
+
|
|
18
|
+
1. Read `~/.claude/plugins/cache/claude-plugins-official/superpowers/5.1.0/skills/using-git-worktrees/SKILL.md` first.
|
|
15
19
|
2. Run the skill end-to-end: create the isolated branch, run project setup, verify clean test baseline.
|
|
16
20
|
3. **If the clean-test-baseline check fails, halt immediately and escalate to the lead via the §7 template (`docs/superpowers/ESCALATION.md`).** Do NOT proceed onto a broken baseline. Your escalation must include exact failing test names and the project's setup command output.
|
|
17
21
|
4. When complete, post `WORKTREE_READY <path> <branch>` to the lead's mailbox.
|
|
18
22
|
|
|
19
|
-
## Phase
|
|
23
|
+
## Phase 2.b — `writing-plans`
|
|
20
24
|
|
|
21
|
-
1. Read `~/.claude/plugins/superpowers/skills/writing-plans/SKILL.md` first.
|
|
25
|
+
1. Read `~/.claude/plugins/cache/claude-plugins-official/superpowers/5.1.0/skills/writing-plans/SKILL.md` first.
|
|
22
26
|
2. Read the approved design doc the lead handed you (path will be in your spawn prompt).
|
|
23
27
|
3. Run the skill verbatim. Every task you produce MUST be 2–5 minutes of work with **exact file paths, complete code, and explicit verification steps**. Anything vaguer than that — fix it before posting.
|
|
24
28
|
4. Each task in the plan MUST also declare:
|
|
25
29
|
- the files it will touch (so the lead can serialize overlapping tasks)
|
|
26
30
|
- a dependency list (which task numbers must complete first)
|
|
31
|
+
|
|
32
|
+
### Task prefix convention
|
|
33
|
+
|
|
34
|
+
Every `impl:` task MUST carry a sub-prefix so the lead can route it to the correct implementer without reading every task body. Only two implementer roles exist; anything outside their domain belongs in a different phase or must be folded into one of them.
|
|
35
|
+
|
|
36
|
+
| Prefix | Routed to | Scope |
|
|
37
|
+
|---|---|---|
|
|
38
|
+
| `impl:be-` | `backend-developer` | Server-side code, APIs, data, infra/CI scripts, build / deploy pipeline tweaks |
|
|
39
|
+
| `impl:fe-` | `frontend-developer` | Client-side code, UI, browser assets |
|
|
40
|
+
|
|
41
|
+
Defect-fix tasks filed mid-flight by `qa-engineer` or `reviewer` use `impl:qa-fix-` / `impl:review-fix-` and inherit the `be-` or `fe-` routing of the file they touch.
|
|
42
|
+
|
|
27
43
|
5. Save the plan to `docs/superpowers/plans/YYYY-MM-DD-<slug>-plan.md` and commit it.
|
|
28
|
-
6.
|
|
29
|
-
|
|
44
|
+
6. Post `PLAN_READY <path>` to the lead. The lead routes the plan to the owner for approval, then to `software-architect` + `security-engineer` for the phase-3 gate.
|
|
45
|
+
|
|
46
|
+
## Plan-revision loop
|
|
47
|
+
|
|
48
|
+
If `software-architect` posts `ARCH_BLOCKED` or `security-engineer` posts `SEC_BLOCKED`, the lead routes the findings to you. Revise the plan to address every Critical / High finding, commit the revision, and post `PLAN_READY <path>` again. Three revision rounds maximum — escalate to the lead via §7 if the loop fails to converge.
|
|
30
49
|
|
|
31
50
|
## Hard rules
|
|
32
51
|
|
|
33
|
-
- The plan **may not** modify or contradict the approved design doc. If a planning detail forces a design change, halt and escalate
|
|
52
|
+
- The plan **may not** modify or contradict the approved design doc. If a planning detail forces a design change, halt and escalate — the design must be re-approved before the plan can change.
|
|
34
53
|
- You **may not** write feature code. None. Not even a stub. The plan describes code; the implementer writes it.
|
|
35
|
-
- You **may not** mark the plan complete until the owner approves it
|
|
54
|
+
- You **may not** mark the plan complete until the owner approves it AND `software-architect` + `security-engineer` both post their PASSED signals.
|
|
36
55
|
|
|
37
56
|
## Escalation
|
|
38
57
|
|
|
@@ -40,3 +59,4 @@ Use the §7 template from `docs/superpowers/ESCALATION.md` for any blocker. Comm
|
|
|
40
59
|
- Test baseline is red.
|
|
41
60
|
- Design doc is ambiguous on a load-bearing decision.
|
|
42
61
|
- A task can't be cut to under 5 minutes without losing meaning — flag it instead of hiding the bloat.
|
|
62
|
+
- Plan-revision loop with SA/security exceeds three rounds.
|