freecodego 0.1.6-alpha.2

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 (106) hide show
  1. package/LICENSE +23 -0
  2. package/README.i18n.yaml +6 -0
  3. package/README.md +85 -0
  4. package/README.zh.md +85 -0
  5. package/cordis.patch.yml +56 -0
  6. package/dist/agent-team.js +16296 -0
  7. package/dist/assets/engineering/skills/ask-matt/PHASE-BOUNDARIES.md +55 -0
  8. package/dist/assets/engineering/skills/ask-matt/SKILL.md +89 -0
  9. package/dist/assets/engineering/skills/ask-matt/agents/openai.yaml +5 -0
  10. package/dist/assets/engineering/skills/code-review/SKILL.md +87 -0
  11. package/dist/assets/engineering/skills/code-review/agents/openai.yaml +3 -0
  12. package/dist/assets/engineering/skills/codebase-design/DEEPENING.md +37 -0
  13. package/dist/assets/engineering/skills/codebase-design/DESIGN-IT-TWICE.md +44 -0
  14. package/dist/assets/engineering/skills/codebase-design/SKILL.md +114 -0
  15. package/dist/assets/engineering/skills/codebase-design/agents/openai.yaml +3 -0
  16. package/dist/assets/engineering/skills/domain-modeling/ADR-FORMAT.md +47 -0
  17. package/dist/assets/engineering/skills/domain-modeling/CONTEXT-FORMAT.md +60 -0
  18. package/dist/assets/engineering/skills/domain-modeling/SKILL.md +74 -0
  19. package/dist/assets/engineering/skills/domain-modeling/agents/openai.yaml +3 -0
  20. package/dist/assets/engineering/skills/engineering-code-review/SKILL.md +13 -0
  21. package/dist/assets/engineering/skills/engineering-context-control/SKILL.md +13 -0
  22. package/dist/assets/engineering/skills/engineering-release-readiness/SKILL.md +13 -0
  23. package/dist/assets/engineering/skills/engineering-security-review/SKILL.md +13 -0
  24. package/dist/assets/engineering/skills/engineering-silent-failure/SKILL.md +13 -0
  25. package/dist/assets/engineering/skills/engineering-spec-mining/SKILL.md +13 -0
  26. package/dist/assets/engineering/skills/engineering-tdd/SKILL.md +13 -0
  27. package/dist/assets/engineering/skills/grill-with-docs/SKILL.md +7 -0
  28. package/dist/assets/engineering/skills/grill-with-docs/agents/openai.yaml +5 -0
  29. package/dist/assets/engineering/skills/implement/SKILL.md +15 -0
  30. package/dist/assets/engineering/skills/implement/agents/openai.yaml +5 -0
  31. package/dist/assets/engineering/skills/improve-codebase-architecture/HTML-REPORT.md +123 -0
  32. package/dist/assets/engineering/skills/improve-codebase-architecture/SKILL.md +71 -0
  33. package/dist/assets/engineering/skills/improve-codebase-architecture/agents/openai.yaml +5 -0
  34. package/dist/assets/engineering/skills/prototype/LOGIC.md +67 -0
  35. package/dist/assets/engineering/skills/prototype/SKILL.md +26 -0
  36. package/dist/assets/engineering/skills/prototype/UI.md +112 -0
  37. package/dist/assets/engineering/skills/prototype/agents/openai.yaml +3 -0
  38. package/dist/assets/engineering/skills/resolving-merge-conflicts/SKILL.md +14 -0
  39. package/dist/assets/engineering/skills/resolving-merge-conflicts/agents/openai.yaml +3 -0
  40. package/dist/assets/engineering/skills/setup-matt-pocock-skills/SKILL.md +116 -0
  41. package/dist/assets/engineering/skills/setup-matt-pocock-skills/agents/openai.yaml +5 -0
  42. package/dist/assets/engineering/skills/setup-matt-pocock-skills/domain.md +51 -0
  43. package/dist/assets/engineering/skills/setup-matt-pocock-skills/issue-tracker-github.md +45 -0
  44. package/dist/assets/engineering/skills/setup-matt-pocock-skills/issue-tracker-gitlab.md +46 -0
  45. package/dist/assets/engineering/skills/setup-matt-pocock-skills/issue-tracker-local.md +30 -0
  46. package/dist/assets/engineering/skills/setup-matt-pocock-skills/triage-labels.md +15 -0
  47. package/dist/assets/engineering/skills/to-spec/SKILL.md +75 -0
  48. package/dist/assets/engineering/skills/to-spec/agents/openai.yaml +5 -0
  49. package/dist/assets/engineering/skills/to-tickets/SKILL.md +105 -0
  50. package/dist/assets/engineering/skills/to-tickets/agents/openai.yaml +5 -0
  51. package/dist/assets/engineering/skills/triage/AGENT-BRIEF.md +207 -0
  52. package/dist/assets/engineering/skills/triage/OUT-OF-SCOPE.md +105 -0
  53. package/dist/assets/engineering/skills/triage/SKILL.md +112 -0
  54. package/dist/assets/engineering/skills/triage/agents/openai.yaml +5 -0
  55. package/dist/assets/engineering/skills/wayfinder/SKILL.md +128 -0
  56. package/dist/assets/engineering/skills/wayfinder/agents/openai.yaml +5 -0
  57. package/dist/assets/engineering/skills/wizard/SKILL.md +44 -0
  58. package/dist/assets/engineering/skills/wizard/agents/openai.yaml +3 -0
  59. package/dist/assets/engineering/skills/wizard/template.sh +204 -0
  60. package/dist/assets/engineering/skills/writing-for-agents/SKILL-MECHANICS.md +22 -0
  61. package/dist/assets/engineering/skills/writing-for-agents/SKILL.md +81 -0
  62. package/dist/assets/engineering/skills/writing-for-agents/agents/openai.yaml +3 -0
  63. package/dist/assets/engineering/skills-starter/engineering-debug/SKILL.md +13 -0
  64. package/dist/assets/engineering/skills-starter/engineering-plan/SKILL.md +26 -0
  65. package/dist/assets/engineering/skills-starter/engineering-search-first/SKILL.md +13 -0
  66. package/dist/assets/engineering/skills-starter/engineering-verification/SKILL.md +67 -0
  67. package/dist/assets/engineering/skills-starter/grill-me/SKILL.md +7 -0
  68. package/dist/assets/engineering/skills-starter/grill-me/agents/openai.yaml +5 -0
  69. package/dist/assets/engineering/skills-starter/grilling/SKILL.md +28 -0
  70. package/dist/assets/engineering/skills-starter/grilling/agents/openai.yaml +3 -0
  71. package/dist/assets/engineering/skills-starter/handoff/SKILL.md +16 -0
  72. package/dist/assets/engineering/skills-starter/handoff/agents/openai.yaml +5 -0
  73. package/dist/assets/engineering/skills-starter/prompt-techniques/SKILL.md +84 -0
  74. package/dist/assets/engineering/skills-starter/to-questionnaire/SKILL.md +54 -0
  75. package/dist/assets/engineering/skills-starter/to-questionnaire/agents/openai.yaml +5 -0
  76. package/dist/assets/engineering/skills-starter/wait-what/SKILL.md +7 -0
  77. package/dist/assets/engineering/skills-starter/wait-what/agents/openai.yaml +5 -0
  78. package/dist/assets/engineering/skills-superpowers/brainstorming/SKILL.md +240 -0
  79. package/dist/assets/engineering/skills-superpowers/brainstorming/spec-document-reviewer-prompt.md +49 -0
  80. package/dist/assets/engineering/skills-superpowers/dispatching-parallel-agents/SKILL.md +167 -0
  81. package/dist/assets/engineering/skills-superpowers/executing-plans/SKILL.md +64 -0
  82. package/dist/assets/engineering/skills-superpowers/finishing-a-development-branch/SKILL.md +225 -0
  83. package/dist/assets/engineering/skills-superpowers/receiving-code-review/SKILL.md +205 -0
  84. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/SKILL.md +567 -0
  85. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/final-reviewer-prompt.md +181 -0
  86. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/implementer-prompt.md +154 -0
  87. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/re-review-prompt.md +115 -0
  88. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/scripts/review-package +46 -0
  89. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/scripts/sdd-workspace +40 -0
  90. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/scripts/task-brief +41 -0
  91. package/dist/assets/engineering/skills-superpowers/subagent-driven-development/task-reviewer-prompt.md +207 -0
  92. package/dist/assets/engineering/skills-superpowers/using-git-worktrees/SKILL.md +167 -0
  93. package/dist/assets/engineering/skills-superpowers/writing-plans/SKILL.md +171 -0
  94. package/dist/assets/engineering/skills-superpowers/writing-plans/plan-document-reviewer-prompt.md +49 -0
  95. package/dist/assets/presets/augmentcode/agent.cordis.yml +238 -0
  96. package/dist/assets/presets/augmentcode/preset.yml +4 -0
  97. package/dist/assets/presets/freecodego/agent.cordis.yml +220 -0
  98. package/dist/assets/presets/freecodego/preset.yml +4 -0
  99. package/dist/auto-review.js +429 -0
  100. package/dist/bootstrap.js +65223 -0
  101. package/dist/client.cjs +39382 -0
  102. package/dist/schedule.js +15846 -0
  103. package/dist/session-events.js +10 -0
  104. package/dist/tool-agent-team.js +16825 -0
  105. package/dist/workers/codex-worker.js +1127 -0
  106. package/package.json +113 -0
@@ -0,0 +1,54 @@
1
+ ---
2
+ name: to-questionnaire
3
+ description: Turn a decision you can't fully answer into a questionnaire for someone else to fill in.
4
+ disable-model-invocation: true
5
+ ---
6
+
7
+ Turn something the user can't answer alone into a **questionnaire**: a Markdown document they hand to one person to fill in async, or fill out together over a meeting. The recipient holds knowledge the user lacks; the questionnaire pulls it out of them.
8
+
9
+ **Grill the send, not the subject.** Interview the user only about the _send_, which they can always answer: who it goes to, and what they need back. The questions in the document then target the **gap** between what the recipient knows and what the user needs.
10
+
11
+
12
+ 1. **Who is it going to?** Ask, in one exchange, the recipient's role, expertise, and relationship to the user. This fixes the questionnaire's tone and how much context it must carry. Done when you know who the recipient is and what they know that the user doesn't.
13
+
14
+ 2. **What do you need back?** Ask, in one exchange, the specific decisions or facts the user can't resolve alone and needs from this person. Done when you have a concrete list of what the user must walk away able to do or decide.
15
+
16
+ 3. **Write the questionnaire.** Draft questions aimed at the gap from steps 1–2, following the Document structure below. Write it to `to-questionnaire-<slug>.md` in the current directory (slug from the topic) and report the path. Done when the file exists and every item the user named in step 2 is covered by a question.
17
+
18
+ ## Document structure
19
+
20
+ Frame the document as a **discovery questionnaire**: the user lacks context, the recipient holds it. Order questions most-important-first, since async means you may only get one pass, and group them under `##` headings by theme once there are more than a handful. Write it using the template below.
21
+
22
+ <questionnaire-template>
23
+
24
+ # <Questionnaire title>
25
+
26
+ **Purpose:** why this questionnaire exists and the decision riding on it.
27
+
28
+ **From:** <the user>, **To:** <the recipient>, **How your answers will be used:** <where they go>
29
+
30
+ ## Context
31
+
32
+ One paragraph orienting a recipient who wasn't in the user's head. Enough to answer well, not a page.
33
+
34
+ ## How to answer
35
+
36
+ Deadline and rough effort. Partial answers and "I don't know" are useful: flag anything you're unsure of rather than skipping it.
37
+
38
+ ## <Theme heading>
39
+
40
+ One `##` section per theme. Under each, its questions, most-important-first. Every question is one idea, never compound, with an answer stub directly beneath, and a one-line _why this matters_ only where the question could be misread or invite a throwaway answer.
41
+
42
+ <question-example>
43
+ ### What load is the system expected to handle at launch?
44
+
45
+ _Why this matters: it decides whether we provision for burst traffic now or defer it._
46
+
47
+ >
48
+ </question-example>
49
+
50
+ ## Anything else?
51
+
52
+ A closing catch-all: anything we didn't ask that we should know?
53
+
54
+ </questionnaire-template>
@@ -0,0 +1,5 @@
1
+ interface:
2
+ display_name: "To Questionnaire"
3
+ short_description: "Front-load questions into a doc for someone to answer"
4
+ policy:
5
+ allow_implicit_invocation: false
@@ -0,0 +1,7 @@
1
+ ---
2
+ name: wait-what
3
+ description: "Stop. That last message did not land: re-pitch it."
4
+ disable-model-invocation: true
5
+ ---
6
+
7
+ Wait, I don't understand where you've got to here. Re-pitch that: give me a little bit of context, talk in ASD-STE100 Simplified Technical English, and use the ubiquitous language from `CONTEXT.md` (follow `CONTEXT-MAP.md` to the right one if the repo has more than one).
@@ -0,0 +1,5 @@
1
+ interface:
2
+ display_name: "Wait What"
3
+ short_description: "Re-pitch that: simpler, with the context I'm missing"
4
+ policy:
5
+ allow_implicit_invocation: false
@@ -0,0 +1,240 @@
1
+ ---
2
+ name: brainstorming
3
+ description: "You MUST use this before any creative work - creating features, building components, adding functionality, or modifying behavior. Explores user intent, requirements and design before implementation."
4
+ ---
5
+
6
+ # Brainstorming Ideas Into Designs
7
+
8
+ Help turn ideas into fully formed designs and specs through natural collaborative dialogue.
9
+
10
+ Start by classifying how much process the request needs, then work
11
+ through your path: understand the context, refine the idea, present a
12
+ design, and get your human partner's approval.
13
+
14
+ <HARD-GATE>
15
+ Do NOT invoke any implementation skill, write any code, scaffold any
16
+ project, or take any implementation action until you have told your
17
+ human partner what you intend and they have approved it. This applies
18
+ to EVERY task on EVERY path below — the ceremony scales with the task;
19
+ the approval gate never does.
20
+ </HARD-GATE>
21
+
22
+ ## Three Paths
23
+
24
+ Before your first question, classify the request and say the
25
+ classification out loud — "this looks bounded, so I'll present a short
26
+ design here rather than write a spec" — so your human partner can
27
+ override it:
28
+
29
+ - **Spike** — a feasibility question ("can we...", "is it possible...",
30
+ "quick and dirty is fine") whose output is an answer, not code you
31
+ keep. Present the question and what you'll try in 2-3 sentences, get
32
+ a nod, then find out as cheaply as correctness allows. No design
33
+ doc, no spec file. Report findings as a recommendation; anything you
34
+ built stays labeled throwaway.
35
+ - **Bounded** — a well-scoped change to code that already exists in
36
+ this repo: a new flag, a small endpoint, a one-file fix.
37
+ Understanding the kind of app is not enough — bounded means the flow
38
+ you are changing is already here to read. If there is no existing
39
+ flow to change, the task is not bounded. Ask the clarifying
40
+ questions that matter, present a short design IN CHAT (a few
41
+ sentences to a few short paragraphs), and STOP. Implementation
42
+ starts only after your human partner says yes to that design — a
43
+ bounded task's approval is as hard a gate as an architectural
44
+ one. No spec file, no implementation plan document.
45
+ - **Architectural** — new projects, new subsystems, changes that
46
+ restructure how components fit together or alter interfaces others
47
+ depend on. Follow the full process: questions, approaches, sectioned
48
+ design, written spec, then the writing-plans skill.
49
+
50
+ When in doubt between two paths, take the heavier one. The ratchet is
51
+ one-way: hidden complexity discovered mid-task upgrades the path —
52
+ stop, say so, and step up. Nothing downgrades mid-task.
53
+
54
+ ## Anti-Pattern: "Too Simple To Need Approval"
55
+
56
+ Every path ends with your human partner approving your intent before
57
+ implementation. A todo list, a single-function utility, a config
58
+ change — the design may be two sentences in chat, but you MUST present
59
+ it and get approval. "Simple" tasks are where unexamined assumptions
60
+ cause the most wasted work. What scales with simplicity is the
61
+ artifact, never the approval.
62
+
63
+ ## Red Flags
64
+
65
+ | Thought | Reality |
66
+ |---------|---------|
67
+ | "This is too simple to need a design" | Simple means a short design, not no design. Two sentences in chat, then approval. |
68
+ | "I'll call it bounded and skip the spec" | Reaching for a label to skip work IS the doubt — take the heavier path. |
69
+ | "It's bounded and the design is obvious — I'll start while they read it" | The gate is the approval, not the design's length. Present, then stop until you hear yes. |
70
+ | "I understand this kind of app, so it's bounded" | Bounded measures the repo, not your familiarity. A new project has no existing flow — it is architectural. |
71
+ | "The spike works, so I'll keep the code" | A spike's output is an answer. Keeping the code is a new request — classify it. |
72
+ | "It grew, but I'm almost done — no need to re-classify" | Hidden complexity upgrades the path mid-task. Stop and say so. |
73
+ | "They approved the spike, so the follow-up change is approved too" | Each task gets its own classification and its own approval. |
74
+
75
+ ## Checklist
76
+
77
+ Classify first, announce the path, then create a task for each item on
78
+ your path and complete them in order.
79
+
80
+ **Spike:**
81
+ 1. **Explore project context** — enough to frame the probe
82
+ 2. **Present question + probe plan** — 2-3 sentences
83
+ 3. **Get approval** — a nod is enough
84
+ 4. **Investigate** — as cheaply as correctness allows
85
+ 5. **Report findings** — a recommendation; label anything built as throwaway
86
+
87
+ **Bounded:**
88
+ 1. **Explore project context** — check files, docs, recent commits
89
+ 2. **Ask clarifying questions** — one at a time, the ones that matter
90
+ 3. **Present short design in chat** — approach, files touched, testing
91
+ 4. **Get approval** — STOP and wait for an explicit yes; presenting the design and starting in the same breath is skipping the gate
92
+ 5. **Implement** — proceed with the normal development workflow (TDD applies); no plan document
93
+
94
+ **Architectural:**
95
+ 1. **Explore project context** — check files, docs, recent commits
96
+ 2. **Keep it text-only** — ask each question in the terminal, and describe genuinely visual options concretely instead of a mockup. See the Visual Companion section below for what this pack does and does not bundle.
97
+ 3. **Ask clarifying questions** — one at a time, understand purpose/constraints/success criteria
98
+ 4. **Propose 2-3 approaches** — with trade-offs and your recommendation
99
+ 5. **Present design** — in sections scaled to their complexity, get user approval after each section
100
+ 6. **Write design doc** — save to `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md` and commit
101
+ 7. **Spec self-review** — quick inline check for placeholders, contradictions, ambiguity, scope (see below)
102
+ 8. **User reviews written spec** — ask user to review the spec file before proceeding
103
+ 9. **Transition to implementation** — invoke writing-plans skill to create implementation plan
104
+
105
+ ## Process Flow
106
+
107
+ ```dot
108
+ digraph brainstorming {
109
+ "Classify: spike / bounded / architectural" [shape=diamond];
110
+ "Present question + probe (2-3 sentences)" [shape=box];
111
+ "Ask clarifying questions (bounded)" [shape=box];
112
+ "Present short design in chat" [shape=box];
113
+ "Human approves?" [shape=diamond];
114
+ "Investigate; report recommendation" [shape=doublecircle];
115
+ "Implement via normal workflow (no plan doc)" [shape=doublecircle];
116
+ "Explore project context" [shape=box];
117
+ "Ask clarifying questions" [shape=box];
118
+ "Propose 2-3 approaches" [shape=box];
119
+ "Present design sections" [shape=box];
120
+ "User approves design?" [shape=diamond];
121
+ "Write design doc" [shape=box];
122
+ "Spec self-review\n(fix inline)" [shape=box];
123
+ "User reviews spec?" [shape=diamond];
124
+ "Invoke writing-plans skill" [shape=doublecircle];
125
+ "Hidden complexity? Upgrade path" [shape=box];
126
+
127
+ "Classify: spike / bounded / architectural" -> "Present question + probe (2-3 sentences)" [label="spike"];
128
+ "Classify: spike / bounded / architectural" -> "Ask clarifying questions (bounded)" [label="bounded"];
129
+ "Classify: spike / bounded / architectural" -> "Explore project context" [label="architectural"];
130
+ "Present question + probe (2-3 sentences)" -> "Human approves?";
131
+ "Ask clarifying questions (bounded)" -> "Present short design in chat";
132
+ "Present short design in chat" -> "Human approves?";
133
+ "Human approves?" -> "Investigate; report recommendation" [label="spike: yes"];
134
+ "Human approves?" -> "Implement via normal workflow (no plan doc)" [label="bounded: yes"];
135
+ "Hidden complexity? Upgrade path" -> "Classify: spike / bounded / architectural";
136
+ "Explore project context" -> "Ask clarifying questions";
137
+ "Ask clarifying questions" -> "Propose 2-3 approaches";
138
+ "Propose 2-3 approaches" -> "Present design sections";
139
+ "Present design sections" -> "User approves design?";
140
+ "User approves design?" -> "Present design sections" [label="no, revise"];
141
+ "User approves design?" -> "Write design doc" [label="yes"];
142
+ "Write design doc" -> "Spec self-review\n(fix inline)";
143
+ "Spec self-review\n(fix inline)" -> "User reviews spec?";
144
+ "User reviews spec?" -> "Write design doc" [label="changes requested"];
145
+ "User reviews spec?" -> "Invoke writing-plans skill" [label="approved"];
146
+ }
147
+ ```
148
+
149
+ **Terminal states are path-bound.** Architectural: the ONLY skill you
150
+ invoke after brainstorming is writing-plans — never frontend-design,
151
+ mcp-builder, or any other implementation skill. Bounded: after
152
+ approval, implementation proceeds directly through the normal
153
+ development workflow; no plan document. Spike: the terminal state is a
154
+ reported recommendation.
155
+
156
+ ## The Process
157
+
158
+ The subsections below serve the bounded and architectural paths (a
159
+ spike stops at "present the probe, get a nod"). Sections from
160
+ **Exploring approaches** onward are architectural-path depth — for
161
+ bounded work, context plus a few questions plus a short in-chat design
162
+ is the whole process.
163
+
164
+ **Understanding the idea:**
165
+
166
+ - Check out the current project state first (files, docs, recent commits)
167
+ - Before asking detailed questions, assess scope: if the request describes multiple independent subsystems (e.g., "build a platform with chat, file storage, billing, and analytics"), flag this immediately. Don't spend questions refining details of a project that needs to be decomposed first.
168
+ - If the project is too large for a single spec, help the user decompose into sub-projects: what are the independent pieces, how do they relate, what order should they be built? Then brainstorm the first sub-project through the normal design flow. Each sub-project gets its own spec → plan → implementation cycle.
169
+ - For appropriately-scoped projects, ask questions one at a time to refine the idea
170
+ - Prefer multiple choice questions when possible, but open-ended is fine too
171
+ - Only one question per message - if a topic needs more exploration, break it into multiple questions
172
+ - Focus on understanding: purpose, constraints, success criteria
173
+
174
+ **Exploring approaches:**
175
+
176
+ - Propose 2-3 different approaches with trade-offs
177
+ - Present options conversationally with your recommendation and reasoning
178
+ - Lead with your recommended option and explain why
179
+ - YAGNI ruthlessly - remove unnecessary features from every approach and design
180
+
181
+ **Presenting the design:**
182
+
183
+ - Once you believe you understand what you're building, present the design
184
+ - Scale each section to its complexity: a few sentences if straightforward, up to 200-300 words if nuanced
185
+ - Ask after each section whether it looks right so far
186
+ - Cover: architecture, components, data flow, error handling, testing
187
+ - Be ready to go back and clarify if something doesn't make sense
188
+
189
+ **Design for isolation and clarity:**
190
+
191
+ - Break the system into smaller units that each have one clear purpose, communicate through well-defined interfaces, and can be understood and tested independently
192
+ - For each unit, you should be able to answer: what does it do, how do you use it, and what does it depend on?
193
+ - Can someone understand what a unit does without reading its internals? Can you change the internals without breaking consumers? If not, the boundaries need work.
194
+ - Smaller, well-bounded units are also easier for you to work with - you reason better about code you can hold in context at once, and your edits are more reliable when files are focused. When a file grows large, that's often a signal that it's doing too much.
195
+
196
+ **Working in existing codebases:**
197
+
198
+ - Explore the current structure before proposing changes. Follow existing patterns.
199
+ - Where existing code has problems that affect the work (e.g., a file that's grown too large, unclear boundaries, tangled responsibilities), include targeted improvements as part of the design - the way a good developer improves code they're working in.
200
+ - Don't propose unrelated refactoring. Stay focused on what serves the current goal.
201
+
202
+ ## After the Design (architectural path)
203
+
204
+ **Documentation:**
205
+
206
+ - Write the validated design (spec) to `docs/superpowers/specs/YYYY-MM-DD-<topic>-design.md`
207
+ - (User preferences for spec location override this default)
208
+ - Use elements-of-style:writing-clearly-and-concisely skill if available
209
+ - Commit the design document to git
210
+
211
+ **Spec Self-Review:**
212
+ After writing the spec document, look at it with fresh eyes:
213
+
214
+ 1. **Placeholder scan:** Any "TBD", "TODO", incomplete sections, or vague requirements? Fix them.
215
+ 2. **Internal consistency:** Do any sections contradict each other? Does the architecture match the feature descriptions?
216
+ 3. **Scope check:** Is this focused enough for a single implementation plan, or does it need decomposition?
217
+ 4. **Ambiguity check:** Could any requirement be interpreted two different ways? If so, pick one and make it explicit.
218
+
219
+ Fix any issues inline. No need to re-review — just fix and move on.
220
+
221
+ **User Review Gate:**
222
+ After the spec review loop passes, ask the user to review the written spec before proceeding:
223
+
224
+ > "Spec written and committed to `<path>`. Please review it and let me know if you want to make any changes before we start writing out the implementation plan."
225
+
226
+ Wait for the user's response. If they request changes, make them and re-run the spec review loop. Only proceed once the user approves.
227
+
228
+ **Implementation:**
229
+
230
+ - Invoke the writing-plans skill to create a detailed implementation plan
231
+ - Do NOT invoke any other skill. writing-plans is the next step.
232
+
233
+ ## Visual Companion
234
+
235
+ Upstream ships a browser-based companion (a local Node server plus a mockup page) for questions that are clearer shown than told. **FreeCodeGo does not vendor that server** — no local HTTP port, and nothing in this Skill reaches the network. Every question in this workflow is asked in the terminal.
236
+
237
+ What survives the adaptation is the classification discipline that made the companion useful, so apply it text-only:
238
+
239
+ - A question about a UI *topic* is not automatically a visual question. "What does personality mean in this context?" is conceptual; "which wizard layout works better?" is visual.
240
+ - When a question is genuinely visual, describe the options concretely in text (layout, dimensions, states, before/after) instead of gesturing at them. For a real mockup, use whatever rendering or prototype capability the harness already exposes; never start a server of your own.
@@ -0,0 +1,49 @@
1
+ # Spec Document Reviewer Prompt Template
2
+
3
+ Use this template when dispatching a spec document reviewer subagent.
4
+
5
+ **Purpose:** Verify the spec is complete, consistent, and ready for implementation planning.
6
+
7
+ **Dispatch after:** Spec document is written to docs/superpowers/specs/
8
+
9
+ ```
10
+ Subagent (general-purpose):
11
+ description: "Review spec document"
12
+ prompt: |
13
+ You are a spec document reviewer. Verify this spec is complete and ready for planning.
14
+
15
+ **Spec to review:** [SPEC_FILE_PATH]
16
+
17
+ ## What to Check
18
+
19
+ | Category | What to Look For |
20
+ |----------|------------------|
21
+ | Completeness | TODOs, placeholders, "TBD", incomplete sections |
22
+ | Consistency | Internal contradictions, conflicting requirements |
23
+ | Clarity | Requirements ambiguous enough to cause someone to build the wrong thing |
24
+ | Scope | Focused enough for a single plan — not covering multiple independent subsystems |
25
+ | YAGNI | Unrequested features, over-engineering |
26
+
27
+ ## Calibration
28
+
29
+ **Only flag issues that would cause real problems during implementation planning.**
30
+ A missing section, a contradiction, or a requirement so ambiguous it could be
31
+ interpreted two different ways — those are issues. Minor wording improvements,
32
+ stylistic preferences, and "sections less detailed than others" are not.
33
+
34
+ Approve unless there are serious gaps that would lead to a flawed plan.
35
+
36
+ ## Output Format
37
+
38
+ ## Spec Review
39
+
40
+ **Status:** Approved | Issues Found
41
+
42
+ **Issues (if any):**
43
+ - [Section X]: [specific issue] - [why it matters for planning]
44
+
45
+ **Recommendations (advisory, do not block approval):**
46
+ - [suggestions for improvement]
47
+ ```
48
+
49
+ **Reviewer returns:** Status, Issues (if any), Recommendations
@@ -0,0 +1,167 @@
1
+ ---
2
+ name: dispatching-parallel-agents
3
+ description: Use when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies
4
+ ---
5
+
6
+ # Dispatching Parallel Agents
7
+
8
+ ## Overview
9
+
10
+ You delegate tasks to specialized agents with isolated context. By precisely crafting their instructions and context, you ensure they stay focused and succeed at their task. They should never inherit your session's context or history — you construct exactly what they need. This also preserves your own context for coordination work.
11
+
12
+ When you have multiple unrelated failures (different test files, different subsystems, different bugs), investigating them sequentially wastes time. Each investigation is independent and can happen in parallel.
13
+
14
+ **Core principle:** Dispatch one agent per independent problem domain. Let them work concurrently.
15
+
16
+ ## When to Use
17
+
18
+ ```dot
19
+ digraph when_to_use {
20
+ "Multiple failures?" [shape=diamond];
21
+ "Are they independent?" [shape=diamond];
22
+ "Single agent investigates all" [shape=box];
23
+ "One agent per problem domain" [shape=box];
24
+ "Can they work in parallel?" [shape=diamond];
25
+ "Sequential agents" [shape=box];
26
+ "Parallel dispatch" [shape=box];
27
+
28
+ "Multiple failures?" -> "Are they independent?" [label="yes"];
29
+ "Are they independent?" -> "Single agent investigates all" [label="no - related"];
30
+ "Are they independent?" -> "Can they work in parallel?" [label="yes"];
31
+ "Can they work in parallel?" -> "Parallel dispatch" [label="yes"];
32
+ "Can they work in parallel?" -> "Sequential agents" [label="no - shared state"];
33
+ }
34
+ ```
35
+
36
+ **Use when:**
37
+ - 3+ test files failing with different root causes
38
+ - Multiple subsystems broken independently
39
+ - Each problem can be understood without context from others
40
+ - No shared state between investigations
41
+
42
+ **Don't use when:**
43
+ - Failures are related (fix one might fix others)
44
+ - Need to understand full system state
45
+ - Agents would interfere with each other
46
+
47
+ ## The Pattern
48
+
49
+ ### 1. Identify Independent Domains
50
+
51
+ Group failures by what's broken:
52
+ - File A tests: Tool approval flow
53
+ - File B tests: Batch completion behavior
54
+ - File C tests: Abort functionality
55
+
56
+ Each domain is independent - fixing tool approval doesn't affect abort tests.
57
+
58
+ ### 2. Create Focused Agent Tasks
59
+
60
+ Each agent gets:
61
+ - **Specific scope:** One test file or subsystem
62
+ - **Clear goal:** Make these tests pass
63
+ - **Constraints:** Don't change other code
64
+ - **Expected output:** Summary of what you found and fixed
65
+
66
+ ### 3. Dispatch in Parallel
67
+
68
+ Issue all three subagent dispatches in the same response — they run in parallel:
69
+
70
+ ```text
71
+ Subagent (general-purpose): "Fix agent-tool-abort.test.ts failures"
72
+ Subagent (general-purpose): "Fix batch-completion-behavior.test.ts failures"
73
+ Subagent (general-purpose): "Fix tool-approval-race-conditions.test.ts failures"
74
+ # All three run concurrently.
75
+ ```
76
+
77
+ Multiple dispatch calls in one response = parallel execution. One per response = sequential.
78
+
79
+ ### 4. Review and Integrate
80
+
81
+ When agents return:
82
+ - Read each summary
83
+ - Verify fixes don't conflict
84
+ - Run full test suite
85
+ - Integrate all changes
86
+
87
+ ## Agent Prompt Structure
88
+
89
+ Good agent prompts are:
90
+ 1. **Focused** - One clear problem domain
91
+ 2. **Self-contained** - All context needed to understand the problem
92
+ 3. **Specific about output** - What should the agent return?
93
+
94
+ ```markdown
95
+ Fix the 3 failing tests in src/agents/agent-tool-abort.test.ts:
96
+
97
+ 1. "should abort tool with partial output capture" - expects 'interrupted at' in message
98
+ 2. "should handle mixed completed and aborted tools" - fast tool aborted instead of completed
99
+ 3. "should properly track pendingToolCount" - expects 3 results but gets 0
100
+
101
+ These are timing/race condition issues. Your task:
102
+
103
+ 1. Read the test file and understand what each test verifies
104
+ 2. Identify root cause - timing issues or actual bugs?
105
+ 3. Fix by:
106
+ - Replacing arbitrary timeouts with event-based waiting
107
+ - Fixing bugs in abort implementation if found
108
+ - Adjusting test expectations if testing changed behavior
109
+
110
+ Do NOT just increase timeouts - find the real issue.
111
+
112
+ Return: Summary of what you found and what you fixed.
113
+ ```
114
+
115
+ ## Common Mistakes
116
+
117
+ **Too broad:** "Fix all the tests" - agent gets lost
118
+ **Specific:** "Fix agent-tool-abort.test.ts" - focused scope
119
+
120
+ **No context:** "Fix the race condition" - agent doesn't know where
121
+ **Context:** Paste the error messages and test names
122
+
123
+ **No constraints:** Agent might refactor everything
124
+ **Constraints:** "Do NOT change production code" or "Fix tests only"
125
+
126
+ **Vague output:** "Fix it" - you don't know what changed
127
+ **Specific:** "Return summary of root cause and changes"
128
+
129
+ ## When NOT to Use
130
+
131
+ **Related failures:** Fixing one might fix others - investigate together first
132
+ **Need full context:** Understanding requires seeing entire system
133
+ **Exploratory debugging:** You don't know what's broken yet
134
+ **Shared state:** Agents would interfere (editing same files, using same resources)
135
+
136
+ ## Real Example from Session
137
+
138
+ **Scenario:** 6 test failures across 3 files after major refactoring
139
+
140
+ **Failures:**
141
+ - agent-tool-abort.test.ts: 3 failures (timing issues)
142
+ - batch-completion-behavior.test.ts: 2 failures (tools not executing)
143
+ - tool-approval-race-conditions.test.ts: 1 failure (execution count = 0)
144
+
145
+ **Decision:** Independent domains - abort logic separate from batch completion separate from race conditions
146
+
147
+ **Dispatch:**
148
+ ```
149
+ Agent 1 → Fix agent-tool-abort.test.ts
150
+ Agent 2 → Fix batch-completion-behavior.test.ts
151
+ Agent 3 → Fix tool-approval-race-conditions.test.ts
152
+ ```
153
+
154
+ **Results:**
155
+ - Agent 1: Replaced timeouts with event-based waiting
156
+ - Agent 2: Fixed event structure bug (threadId in wrong place)
157
+ - Agent 3: Added wait for async tool execution to complete
158
+
159
+ **Integration:** All fixes independent, no conflicts, full suite green
160
+
161
+ ## Verification
162
+
163
+ After agents return:
164
+ 1. **Review each summary** - Understand what changed
165
+ 2. **Check for conflicts** - Did agents edit same code?
166
+ 3. **Run full suite** - Verify all fixes work together
167
+ 4. **Spot check** - Agents can make systematic errors
@@ -0,0 +1,64 @@
1
+ ---
2
+ name: executing-plans
3
+ description: Use when you have a written implementation plan to execute in a separate session with review checkpoints
4
+ ---
5
+
6
+ # Executing Plans
7
+
8
+ ## Overview
9
+
10
+ Load plan, review critically, execute all tasks, report when complete.
11
+
12
+ **Announce at start:** "I'm using the executing-plans skill to implement this plan."
13
+
14
+ **Note:** This workflow is much better with access to subagents. If the harness can dispatch them, use /subagent-driven-development instead of this skill.
15
+
16
+ ## The Process
17
+
18
+ ### Step 1: Load and Review Plan
19
+ 1. Ensure an isolated workspace: use /using-git-worktrees to create one or verify the existing one
20
+ 2. Read plan file
21
+ 3. Review critically - identify any questions or concerns about the plan
22
+ 4. If concerns: Raise them with your human partner before starting
23
+ 5. If no concerns: Create todos for the plan items and proceed
24
+
25
+ ### Step 2: Execute Tasks
26
+
27
+ For each task:
28
+ 1. Mark as in_progress
29
+ 2. Follow each step exactly (plan has bite-sized steps)
30
+ 3. Run verifications as specified
31
+ 4. Mark as completed
32
+
33
+ ### Step 3: Complete Development
34
+
35
+ After all tasks complete and verified:
36
+ - Announce: "I'm using the finishing-a-development-branch skill to complete this work."
37
+ - **REQUIRED SUB-SKILL:** Use /finishing-a-development-branch
38
+ - Follow that skill to verify tests, present options, execute choice
39
+
40
+ ## When to Stop and Ask for Help
41
+
42
+ **STOP executing immediately when:**
43
+ - Hit a blocker (missing dependency, test fails, instruction unclear)
44
+ - Plan has critical gaps preventing starting
45
+ - You don't understand an instruction
46
+ - Verification fails repeatedly
47
+
48
+ **Ask for clarification rather than guessing.**
49
+
50
+ ## When to Revisit Earlier Steps
51
+
52
+ **Return to Review (Step 1) when:**
53
+ - Partner updates the plan based on your feedback
54
+ - Fundamental approach needs rethinking
55
+
56
+ **Don't force through blockers** - stop and ask.
57
+
58
+ ## Remember
59
+ - Review plan critically first
60
+ - Follow plan steps exactly
61
+ - Don't skip verifications
62
+ - Reference skills when plan says to
63
+ - Stop when blocked, don't guess
64
+ - Never start implementation on main/master branch without explicit user consent