aigroup-workflow 2.0.2 → 2.1.0

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 (53) hide show
  1. package/.claude/commands/workflow-start.md +19 -15
  2. package/.codex/AGENTS.md +1 -1
  3. package/AGENTS.md +1 -1
  4. package/README.md +3 -5
  5. package/agents/seo-specialist.md +0 -3
  6. package/cli/commands/init.mjs +1 -1
  7. package/cli/utils/scaffold.mjs +1 -1
  8. package/docs/red-flags.md +1 -1
  9. package/docs/rules/README.md +3 -3
  10. package/docs/rules/web/design-quality.md +0 -1
  11. package/docs/templates/implementation-plan.md +1 -1
  12. package/docs/workflow-pipeline.md +41 -22
  13. package/manifests/install-modules.json +8 -3
  14. package/package.json +1 -1
  15. package/skills/SUPERPOWERS-LICENSE +21 -0
  16. package/skills/brainstorming/SKILL.md +164 -0
  17. package/skills/brainstorming/scripts/frame-template.html +214 -0
  18. package/skills/brainstorming/scripts/helper.js +88 -0
  19. package/skills/brainstorming/scripts/server.cjs +354 -0
  20. package/skills/brainstorming/scripts/start-server.sh +148 -0
  21. package/skills/brainstorming/scripts/stop-server.sh +56 -0
  22. package/skills/brainstorming/spec-document-reviewer-prompt.md +49 -0
  23. package/skills/brainstorming/visual-companion.md +287 -0
  24. package/skills/executing-plans/SKILL.md +70 -0
  25. package/skills/finishing-a-development-branch/SKILL.md +200 -112
  26. package/skills/receiving-code-review/SKILL.md +213 -0
  27. package/skills/requesting-code-review/SKILL.md +105 -0
  28. package/skills/requesting-code-review/code-reviewer.md +146 -0
  29. package/skills/systematic-debugging/CREATION-LOG.md +119 -0
  30. package/skills/systematic-debugging/SKILL.md +296 -208
  31. package/skills/systematic-debugging/condition-based-waiting-example.ts +158 -0
  32. package/skills/systematic-debugging/condition-based-waiting.md +115 -0
  33. package/skills/systematic-debugging/defense-in-depth.md +122 -0
  34. package/skills/systematic-debugging/find-polluter.sh +63 -0
  35. package/skills/systematic-debugging/root-cause-tracing.md +169 -0
  36. package/skills/systematic-debugging/test-academic.md +14 -0
  37. package/skills/systematic-debugging/test-pressure-1.md +58 -0
  38. package/skills/systematic-debugging/test-pressure-2.md +68 -0
  39. package/skills/systematic-debugging/test-pressure-3.md +69 -0
  40. package/skills/using-git-worktrees/SKILL.md +218 -0
  41. package/skills/verification-before-completion/SKILL.md +139 -120
  42. package/skills/writing-plans/SKILL.md +79 -94
  43. package/skills/writing-plans/plan-document-reviewer-prompt.md +49 -0
  44. package/skills/writing-skills/SKILL.md +655 -0
  45. package/skills/writing-skills/anthropic-best-practices.md +1150 -0
  46. package/skills/writing-skills/examples/CLAUDE_MD_TESTING.md +189 -0
  47. package/skills/writing-skills/graphviz-conventions.dot +172 -0
  48. package/skills/writing-skills/persuasion-principles.md +187 -0
  49. package/skills/writing-skills/render-graphs.js +168 -0
  50. package/skills/writing-skills/testing-skills-with-subagents.md +384 -0
  51. package/skills/subagent-driven-development/SKILL.md +0 -173
  52. package/skills/ui-ux-pro-max/scripts/__pycache__/core.cpython-39.pyc +0 -0
  53. 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
- **上下文**:此技能在需求工程 / 方案设计完成后调用,由 `planner` agent 或主会话使用。
14
+ **Announce at start:** "I'm using the writing-plans skill to create the implementation plan."
17
15
 
18
- **产物**:主会话把 planner 响应写入 `.orchestration/<session>/planner/handoff.md`。
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
- **每一步是一个动作(2-5 分钟):**
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
- ```markdown
49
- # [功能名] 实现计划
47
+ **Every plan MUST start with this header:**
50
48
 
51
- > **执行方式**:推荐使用 subagent-driven-development 技能按任务派遣子代理执行。
52
- > 步骤使用 checkbox (`- [ ]`) 语法追踪进度。
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
- **架构**:[2-3 句话描述方案]
54
+ **Goal:** [One sentence describing what this builds]
57
55
 
58
- **技术栈**:[关键技术/库]
56
+ **Architecture:** [2-3 sentences about approach]
59
57
 
60
- **设计文档**:`.orchestration/<session>/architect/handoff.md`
58
+ **Tech Stack:** [Key technologies/libraries]
61
59
 
62
60
  ---
63
61
  ```
64
62
 
65
- ## 任务结构
63
+ ## Task Structure
66
64
 
67
65
  ````markdown
68
- ### 任务 N[组件名]
66
+ ### Task N: [Component Name]
69
67
 
70
- **文件:**
71
- - 新建:`exact/path/to/file.py`
72
- - 修改:`exact/path/to/existing.py:123-145`
73
- - 测试:`tests/exact/path/to/test.py`
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
- - [ ] **步骤 1:编写失败测试**
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
- - [ ] **步骤 2:运行测试确认失败**
81
+ - [ ] **Step 2: Run test to verify it fails**
84
82
 
85
- 运行:`pytest tests/path/test.py::test_name -v`
86
- 预期:失败,提示 "function not defined"
83
+ Run: `pytest tests/path/test.py::test_name -v`
84
+ Expected: FAIL with "function not defined"
87
85
 
88
- - [ ] **步骤 3:编写最小实现**
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
- - [ ] **步骤 4:运行测试确认通过**
93
+ - [ ] **Step 4: Run test to verify it passes**
96
94
 
97
- 运行:`pytest tests/path/test.py::test_name -v`
98
- 预期:通过
95
+ Run: `pytest tests/path/test.py::test_name -v`
96
+ Expected: PASS
99
97
 
100
- - [ ] **步骤 5:提交**
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
- - "待定"、"TODO"、"之后实现"、"后续补充"
113
- - "添加适当的错误处理" / "添加验证" / "处理边界情况"
114
- - "为以上内容写测试"(没有实际测试代码)
115
- - "类似任务 N"(重复代码——执行者可能不按顺序读任务)
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
- 1. **设计覆盖度**:逐条过设计方案中的需求/功能点。每条都能指向一个实现任务吗?列出任何遗漏
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
- > "计划已保存到 `.orchestration/<session>/planner/handoff.md`。推荐执行方式:
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
- ## Red Flags 停下来
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
- - **requirement-engineering** 产出需求文档(本技能的输入)
164
- - **architecture-designer** 方案 / ADR(本技能的另一输入)
165
- - **subagent-driven-development** 执行本计划(本技能的输出)
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