aigroup-workflow 2.0.3 → 2.1.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.
- package/.claude/commands/workflow-start.md +19 -15
- package/.codex/AGENTS.md +1 -1
- package/AGENTS.md +1 -1
- package/README.md +3 -5
- package/agents/seo-specialist.md +0 -3
- package/cli/commands/init.mjs +1 -1
- package/cli/utils/scaffold.mjs +1 -1
- package/docs/red-flags.md +1 -1
- package/docs/rules/README.md +4 -3
- package/docs/rules/entropy.md +75 -0
- package/docs/rules/web/design-quality.md +0 -1
- package/docs/templates/implementation-plan.md +1 -1
- package/docs/workflow-pipeline.md +41 -22
- package/manifests/install-modules.json +8 -3
- package/package.json +1 -1
- package/skills/SUPERPOWERS-LICENSE +21 -0
- package/skills/brainstorming/SKILL.md +164 -0
- package/skills/brainstorming/scripts/frame-template.html +214 -0
- package/skills/brainstorming/scripts/helper.js +88 -0
- package/skills/brainstorming/scripts/server.cjs +354 -0
- package/skills/brainstorming/scripts/start-server.sh +148 -0
- package/skills/brainstorming/scripts/stop-server.sh +56 -0
- package/skills/brainstorming/spec-document-reviewer-prompt.md +49 -0
- package/skills/brainstorming/visual-companion.md +287 -0
- package/skills/executing-plans/SKILL.md +70 -0
- package/skills/finishing-a-development-branch/SKILL.md +200 -112
- package/skills/receiving-code-review/SKILL.md +213 -0
- package/skills/requesting-code-review/SKILL.md +105 -0
- package/skills/requesting-code-review/code-reviewer.md +146 -0
- package/skills/systematic-debugging/CREATION-LOG.md +119 -0
- package/skills/systematic-debugging/SKILL.md +296 -208
- package/skills/systematic-debugging/condition-based-waiting-example.ts +158 -0
- package/skills/systematic-debugging/condition-based-waiting.md +115 -0
- package/skills/systematic-debugging/defense-in-depth.md +122 -0
- package/skills/systematic-debugging/find-polluter.sh +63 -0
- package/skills/systematic-debugging/root-cause-tracing.md +169 -0
- package/skills/systematic-debugging/test-academic.md +14 -0
- package/skills/systematic-debugging/test-pressure-1.md +58 -0
- package/skills/systematic-debugging/test-pressure-2.md +68 -0
- package/skills/systematic-debugging/test-pressure-3.md +69 -0
- package/skills/using-git-worktrees/SKILL.md +218 -0
- package/skills/verification-before-completion/SKILL.md +139 -120
- package/skills/writing-plans/SKILL.md +79 -94
- package/skills/writing-plans/plan-document-reviewer-prompt.md +49 -0
- package/skills/writing-skills/SKILL.md +655 -0
- package/skills/writing-skills/anthropic-best-practices.md +1150 -0
- package/skills/writing-skills/examples/CLAUDE_MD_TESTING.md +189 -0
- package/skills/writing-skills/graphviz-conventions.dot +172 -0
- package/skills/writing-skills/persuasion-principles.md +187 -0
- package/skills/writing-skills/render-graphs.js +168 -0
- package/skills/writing-skills/testing-skills-with-subagents.md +384 -0
- package/skills/subagent-driven-development/SKILL.md +0 -173
- package/skills/ui-ux-pro-max/scripts/__pycache__/core.cpython-39.pyc +0 -0
- package/skills/ui-ux-pro-max/scripts/__pycache__/design_system.cpython-39.pyc +0 -0
|
@@ -1,78 +1,76 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: writing-plans
|
|
3
|
-
description:
|
|
3
|
+
description: Use when you have a spec or requirements for a multi-step task, before touching code
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
#
|
|
6
|
+
# Writing Plans
|
|
7
7
|
|
|
8
|
-
##
|
|
8
|
+
## Overview
|
|
9
9
|
|
|
10
|
-
|
|
11
|
-
记录他们需要知道的一切:每个任务要动哪些文件、完整代码、测试方法、可能需要查阅的文档、如何验证。
|
|
12
|
-
把整个计划拆成小口的任务。DRY、YAGNI、TDD、频繁提交。
|
|
10
|
+
Write comprehensive implementation plans assuming the engineer has zero context for our codebase and questionable taste. Document everything they need to know: which files to touch for each task, code, testing, docs they might need to check, how to test it. Give them the whole plan as bite-sized tasks. DRY. YAGNI. TDD. Frequent commits.
|
|
13
11
|
|
|
14
|
-
|
|
12
|
+
Assume they are a skilled developer, but know almost nothing about our toolset or problem domain. Assume they don't know good test design very well.
|
|
15
13
|
|
|
16
|
-
|
|
14
|
+
**Announce at start:** "I'm using the writing-plans skill to create the implementation plan."
|
|
17
15
|
|
|
18
|
-
|
|
16
|
+
**Context:** This should be run in a dedicated worktree (created by brainstorming skill).
|
|
19
17
|
|
|
20
|
-
|
|
18
|
+
**Save plans to:** `docs/superpowers/plans/YYYY-MM-DD-<feature-name>.md`
|
|
19
|
+
- (User preferences for plan location override this default)
|
|
21
20
|
|
|
22
|
-
|
|
23
|
-
如果没有拆分,建议分成独立的计划——每个子系统一个。每个计划应能独立产出可工作、可测试的软件。
|
|
21
|
+
## Scope Check
|
|
24
22
|
|
|
25
|
-
|
|
23
|
+
If the spec covers multiple independent subsystems, it should have been broken into sub-project specs during brainstorming. If it wasn't, suggest breaking this into separate plans — one per subsystem. Each plan should produce working, testable software on its own.
|
|
26
24
|
|
|
27
|
-
|
|
25
|
+
## File Structure
|
|
28
26
|
|
|
29
|
-
|
|
30
|
-
- 优先选择小而聚焦的文件,而非做太多事情的大文件
|
|
31
|
-
- 一起变更的文件应放在一起。按职责拆分,而非按技术层拆分
|
|
32
|
-
- 在现有代码库中遵循已有模式
|
|
27
|
+
Before defining tasks, map out which files will be created or modified and what each one is responsible for. This is where decomposition decisions get locked in.
|
|
33
28
|
|
|
34
|
-
|
|
29
|
+
- Design units with clear boundaries and well-defined interfaces. Each file should have one clear responsibility.
|
|
30
|
+
- You reason best about code you can hold in context at once, and your edits are more reliable when files are focused. Prefer smaller, focused files over large ones that do too much.
|
|
31
|
+
- Files that change together should live together. Split by responsibility, not by technical layer.
|
|
32
|
+
- In existing codebases, follow established patterns. If the codebase uses large files, don't unilaterally restructure - but if a file you're modifying has grown unwieldy, including a split in the plan is reasonable.
|
|
35
33
|
|
|
36
|
-
|
|
34
|
+
This structure informs the task decomposition. Each task should produce self-contained changes that make sense independently.
|
|
37
35
|
|
|
38
|
-
-
|
|
39
|
-
- "运行测试确认失败" — 一步
|
|
40
|
-
- "编写最小代码使测试通过" — 一步
|
|
41
|
-
- "运行测试确认通过" — 一步
|
|
42
|
-
- "提交" — 一步
|
|
36
|
+
## Bite-Sized Task Granularity
|
|
43
37
|
|
|
44
|
-
|
|
38
|
+
**Each step is one action (2-5 minutes):**
|
|
39
|
+
- "Write the failing test" - step
|
|
40
|
+
- "Run it to make sure it fails" - step
|
|
41
|
+
- "Implement the minimal code to make the test pass" - step
|
|
42
|
+
- "Run the tests and make sure they pass" - step
|
|
43
|
+
- "Commit" - step
|
|
45
44
|
|
|
46
|
-
|
|
45
|
+
## Plan Document Header
|
|
47
46
|
|
|
48
|
-
|
|
49
|
-
# [功能名] 实现计划
|
|
47
|
+
**Every plan MUST start with this header:**
|
|
50
48
|
|
|
51
|
-
|
|
52
|
-
|
|
49
|
+
```markdown
|
|
50
|
+
# [Feature Name] Implementation Plan
|
|
53
51
|
|
|
54
|
-
|
|
52
|
+
> **For agentic workers:** Dispatch subagents per the rules in `docs/rules/agents.md` (recommended), or use the `executing-plans` skill for inline batch execution. Steps use checkbox (`- [ ]`) syntax for tracking.
|
|
55
53
|
|
|
56
|
-
|
|
54
|
+
**Goal:** [One sentence describing what this builds]
|
|
57
55
|
|
|
58
|
-
|
|
56
|
+
**Architecture:** [2-3 sentences about approach]
|
|
59
57
|
|
|
60
|
-
|
|
58
|
+
**Tech Stack:** [Key technologies/libraries]
|
|
61
59
|
|
|
62
60
|
---
|
|
63
61
|
```
|
|
64
62
|
|
|
65
|
-
##
|
|
63
|
+
## Task Structure
|
|
66
64
|
|
|
67
65
|
````markdown
|
|
68
|
-
###
|
|
66
|
+
### Task N: [Component Name]
|
|
69
67
|
|
|
70
|
-
|
|
71
|
-
-
|
|
72
|
-
-
|
|
73
|
-
-
|
|
68
|
+
**Files:**
|
|
69
|
+
- Create: `exact/path/to/file.py`
|
|
70
|
+
- Modify: `exact/path/to/existing.py:123-145`
|
|
71
|
+
- Test: `tests/exact/path/to/test.py`
|
|
74
72
|
|
|
75
|
-
- [ ]
|
|
73
|
+
- [ ] **Step 1: Write the failing test**
|
|
76
74
|
|
|
77
75
|
```python
|
|
78
76
|
def test_specific_behavior():
|
|
@@ -80,87 +78,74 @@ def test_specific_behavior():
|
|
|
80
78
|
assert result == expected
|
|
81
79
|
```
|
|
82
80
|
|
|
83
|
-
- [ ]
|
|
81
|
+
- [ ] **Step 2: Run test to verify it fails**
|
|
84
82
|
|
|
85
|
-
|
|
86
|
-
|
|
83
|
+
Run: `pytest tests/path/test.py::test_name -v`
|
|
84
|
+
Expected: FAIL with "function not defined"
|
|
87
85
|
|
|
88
|
-
- [ ]
|
|
86
|
+
- [ ] **Step 3: Write minimal implementation**
|
|
89
87
|
|
|
90
88
|
```python
|
|
91
89
|
def function(input):
|
|
92
90
|
return expected
|
|
93
91
|
```
|
|
94
92
|
|
|
95
|
-
- [ ]
|
|
93
|
+
- [ ] **Step 4: Run test to verify it passes**
|
|
96
94
|
|
|
97
|
-
|
|
98
|
-
|
|
95
|
+
Run: `pytest tests/path/test.py::test_name -v`
|
|
96
|
+
Expected: PASS
|
|
99
97
|
|
|
100
|
-
- [ ]
|
|
98
|
+
- [ ] **Step 5: Commit**
|
|
101
99
|
|
|
102
100
|
```bash
|
|
103
101
|
git add tests/path/test.py src/path/file.py
|
|
104
|
-
git commit -m "feat:
|
|
102
|
+
git commit -m "feat: add specific feature"
|
|
105
103
|
```
|
|
106
104
|
````
|
|
107
105
|
|
|
108
|
-
##
|
|
106
|
+
## No Placeholders
|
|
109
107
|
|
|
110
|
-
|
|
108
|
+
Every step must contain the actual content an engineer needs. These are **plan failures** — never write them:
|
|
109
|
+
- "TBD", "TODO", "implement later", "fill in details"
|
|
110
|
+
- "Add appropriate error handling" / "add validation" / "handle edge cases"
|
|
111
|
+
- "Write tests for the above" (without actual test code)
|
|
112
|
+
- "Similar to Task N" (repeat the code — the engineer may be reading tasks out of order)
|
|
113
|
+
- Steps that describe what to do without showing how (code blocks required for code steps)
|
|
114
|
+
- References to types, functions, or methods not defined in any task
|
|
111
115
|
|
|
112
|
-
|
|
113
|
-
-
|
|
114
|
-
-
|
|
115
|
-
-
|
|
116
|
-
-
|
|
117
|
-
- 引用了任何任务中未定义的类型、函数或方法
|
|
116
|
+
## Remember
|
|
117
|
+
- Exact file paths always
|
|
118
|
+
- Complete code in every step — if a step changes code, show the code
|
|
119
|
+
- Exact commands with expected output
|
|
120
|
+
- DRY, YAGNI, TDD, frequent commits
|
|
118
121
|
|
|
119
|
-
##
|
|
122
|
+
## Self-Review
|
|
120
123
|
|
|
121
|
-
|
|
122
|
-
无占位符。无模糊步骤。无假设执行者会自行补全的内容。
|
|
123
|
-
每一步必须有:精确文件路径、完整代码、精确命令和预期输出。
|
|
124
|
-
```
|
|
124
|
+
After writing the complete plan, look at the spec with fresh eyes and check the plan against it. This is a checklist you run yourself — not a subagent dispatch.
|
|
125
125
|
|
|
126
|
-
|
|
126
|
+
**1. Spec coverage:** Skim each section/requirement in the spec. Can you point to a task that implements it? List any gaps.
|
|
127
127
|
|
|
128
|
-
|
|
128
|
+
**2. Placeholder scan:** Search your plan for red flags — any of the patterns from the "No Placeholders" section above. Fix them.
|
|
129
129
|
|
|
130
|
-
|
|
131
|
-
2. **占位符扫描**:搜索上面"禁止占位符"中的模式。修正它们
|
|
132
|
-
3. **类型一致性**:后续任务中使用的类型、方法签名、属性名是否与前面任务中的定义一致?
|
|
130
|
+
**3. Type consistency:** Do the types, method signatures, and property names you used in later tasks match what you defined in earlier tasks? A function called `clearLayers()` in Task 3 but `clearFullLayers()` in Task 7 is a bug.
|
|
133
131
|
|
|
134
|
-
|
|
132
|
+
If you find issues, fix them inline. No need to re-review — just fix and move on. If you find a spec requirement with no task, add the task.
|
|
135
133
|
|
|
136
|
-
##
|
|
134
|
+
## Execution Handoff
|
|
137
135
|
|
|
138
|
-
|
|
136
|
+
After saving the plan, offer execution choice:
|
|
139
137
|
|
|
140
|
-
|
|
141
|
-
>
|
|
142
|
-
> **子代理驱动(推荐)** — 主会话按任务派遣实现 agent(如 `tdd-guide`)执行,每任务独立上下文,`code-reviewer` 双阶段审查
|
|
143
|
-
>
|
|
144
|
-
> 确认后开始执行?"
|
|
138
|
+
**"Plan complete and saved to `docs/superpowers/plans/<filename>.md`. Two execution options:**
|
|
145
139
|
|
|
146
|
-
|
|
147
|
-
- 加载 `subagent-driven-development` 技能
|
|
148
|
-
- 每任务派遣新的实现 agent + `code-reviewer` 双阶段审查
|
|
140
|
+
**1. Subagent-Driven (recommended)** - I dispatch a fresh subagent per task, review between tasks, fast iteration
|
|
149
141
|
|
|
150
|
-
|
|
142
|
+
**2. Inline Execution** - Execute tasks in this session using executing-plans, batch execution with checkpoints
|
|
151
143
|
|
|
152
|
-
|
|
153
|
-
|------|------|
|
|
154
|
-
| 没有设计方案就开始写计划 | 停下来,先完成需求工程 / architect 设计 |
|
|
155
|
-
| 任务步骤没有代码块 | 不合格,补上完整代码 |
|
|
156
|
-
| 出现"待定""TODO"等占位符 | 不合格,现在就确定内容 |
|
|
157
|
-
| 计划没有引用设计文档 | 在计划头补上设计文档链接 |
|
|
158
|
-
| 单个任务超过 10 分钟 | 任务太大,继续拆分 |
|
|
159
|
-
| 步骤只描述不展示 | 不合格,补上代码和命令 |
|
|
144
|
+
**Which approach?"**
|
|
160
145
|
|
|
161
|
-
|
|
146
|
+
**If Subagent-Driven chosen:**
|
|
147
|
+
- Dispatch subagents per `docs/rules/agents.md` (fresh subagent per task + two-stage review by `code-reviewer`)
|
|
162
148
|
|
|
163
|
-
|
|
164
|
-
- **
|
|
165
|
-
-
|
|
166
|
-
- **verification-before-completion** — 每个任务完成时验证
|
|
149
|
+
**If Inline Execution chosen:**
|
|
150
|
+
- **REQUIRED SUB-SKILL:** Use superpowers:executing-plans
|
|
151
|
+
- Batch execution with checkpoints for review
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
# Plan Document Reviewer Prompt Template
|
|
2
|
+
|
|
3
|
+
Use this template when dispatching a plan document reviewer subagent.
|
|
4
|
+
|
|
5
|
+
**Purpose:** Verify the plan is complete, matches the spec, and has proper task decomposition.
|
|
6
|
+
|
|
7
|
+
**Dispatch after:** The complete plan is written.
|
|
8
|
+
|
|
9
|
+
```
|
|
10
|
+
Task tool (general-purpose):
|
|
11
|
+
description: "Review plan document"
|
|
12
|
+
prompt: |
|
|
13
|
+
You are a plan document reviewer. Verify this plan is complete and ready for implementation.
|
|
14
|
+
|
|
15
|
+
**Plan to review:** [PLAN_FILE_PATH]
|
|
16
|
+
**Spec for reference:** [SPEC_FILE_PATH]
|
|
17
|
+
|
|
18
|
+
## What to Check
|
|
19
|
+
|
|
20
|
+
| Category | What to Look For |
|
|
21
|
+
|----------|------------------|
|
|
22
|
+
| Completeness | TODOs, placeholders, incomplete tasks, missing steps |
|
|
23
|
+
| Spec Alignment | Plan covers spec requirements, no major scope creep |
|
|
24
|
+
| Task Decomposition | Tasks have clear boundaries, steps are actionable |
|
|
25
|
+
| Buildability | Could an engineer follow this plan without getting stuck? |
|
|
26
|
+
|
|
27
|
+
## Calibration
|
|
28
|
+
|
|
29
|
+
**Only flag issues that would cause real problems during implementation.**
|
|
30
|
+
An implementer building the wrong thing or getting stuck is an issue.
|
|
31
|
+
Minor wording, stylistic preferences, and "nice to have" suggestions are not.
|
|
32
|
+
|
|
33
|
+
Approve unless there are serious gaps — missing requirements from the spec,
|
|
34
|
+
contradictory steps, placeholder content, or tasks so vague they can't be acted on.
|
|
35
|
+
|
|
36
|
+
## Output Format
|
|
37
|
+
|
|
38
|
+
## Plan Review
|
|
39
|
+
|
|
40
|
+
**Status:** Approved | Issues Found
|
|
41
|
+
|
|
42
|
+
**Issues (if any):**
|
|
43
|
+
- [Task X, Step Y]: [specific issue] - [why it matters for implementation]
|
|
44
|
+
|
|
45
|
+
**Recommendations (advisory, do not block approval):**
|
|
46
|
+
- [suggestions for improvement]
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
**Reviewer returns:** Status, Issues (if any), Recommendations
|