takt 0.39.0 → 0.40.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 (109) hide show
  1. package/README.md +2 -2
  2. package/builtins/en/facets/instructions/arbitrate.md +6 -6
  3. package/builtins/en/facets/instructions/{loop-monitor-ai-fix.md → loop-monitor-ai-antipattern-fix.md} +2 -2
  4. package/builtins/en/facets/instructions/review-arch.md +1 -1
  5. package/builtins/en/facets/instructions/review-cqrs-es.md +1 -1
  6. package/builtins/en/facets/instructions/review-terraform.md +1 -1
  7. package/builtins/en/facets/policies/review.md +19 -0
  8. package/builtins/en/workflows/auto-improvement-loop.yaml +9 -3
  9. package/builtins/en/workflows/backend-cqrs-mini.yaml +9 -9
  10. package/builtins/en/workflows/backend-cqrs.yaml +43 -21
  11. package/builtins/en/workflows/backend-mini.yaml +9 -9
  12. package/builtins/en/workflows/backend.yaml +43 -21
  13. package/builtins/en/workflows/default-draft.yaml +128 -0
  14. package/builtins/en/workflows/default-high.yaml +26 -295
  15. package/builtins/en/workflows/default-mini.yaml +17 -203
  16. package/builtins/en/workflows/default-peer-review.yaml +130 -0
  17. package/builtins/en/workflows/default.yaml +21 -208
  18. package/builtins/en/workflows/draft.yaml +166 -0
  19. package/builtins/en/workflows/dual-cqrs-mini.yaml +9 -9
  20. package/builtins/en/workflows/dual-cqrs.yaml +44 -22
  21. package/builtins/en/workflows/dual-mini.yaml +9 -9
  22. package/builtins/en/workflows/dual.yaml +43 -21
  23. package/builtins/en/workflows/frontend-mini.yaml +9 -9
  24. package/builtins/en/workflows/frontend.yaml +43 -21
  25. package/builtins/en/workflows/peer-review.yaml +208 -0
  26. package/builtins/en/workflows/review-fix-takt-default.yaml +23 -23
  27. package/builtins/en/workflows/review-takt-default.yaml +5 -5
  28. package/builtins/en/workflows/takt-default-refresh-all.yaml +42 -20
  29. package/builtins/en/workflows/takt-default-refresh-fast.yaml +42 -20
  30. package/builtins/en/workflows/takt-default.yaml +26 -308
  31. package/builtins/en/workflows/terraform.yaml +11 -11
  32. package/builtins/ja/INSTRUCTION_STYLE_GUIDE.md +2 -2
  33. package/builtins/ja/facets/instructions/arbitrate.md +6 -6
  34. package/builtins/ja/facets/instructions/{loop-monitor-ai-fix.md → loop-monitor-ai-antipattern-fix.md} +2 -2
  35. package/builtins/ja/facets/instructions/review-arch.md +1 -1
  36. package/builtins/ja/facets/instructions/review-cqrs-es.md +1 -1
  37. package/builtins/ja/facets/instructions/review-terraform.md +1 -1
  38. package/builtins/ja/facets/policies/review.md +19 -0
  39. package/builtins/ja/workflows/auto-improvement-loop.yaml +9 -3
  40. package/builtins/ja/workflows/backend-cqrs-mini.yaml +9 -9
  41. package/builtins/ja/workflows/backend-cqrs.yaml +43 -21
  42. package/builtins/ja/workflows/backend-mini.yaml +9 -9
  43. package/builtins/ja/workflows/backend.yaml +43 -21
  44. package/builtins/ja/workflows/default-draft.yaml +128 -0
  45. package/builtins/ja/workflows/default-high.yaml +26 -295
  46. package/builtins/ja/workflows/default-mini.yaml +17 -203
  47. package/builtins/ja/workflows/default-peer-review.yaml +130 -0
  48. package/builtins/ja/workflows/default.yaml +21 -208
  49. package/builtins/ja/workflows/draft.yaml +166 -0
  50. package/builtins/ja/workflows/dual-cqrs-mini.yaml +9 -9
  51. package/builtins/ja/workflows/dual-cqrs.yaml +44 -22
  52. package/builtins/ja/workflows/dual-mini.yaml +9 -9
  53. package/builtins/ja/workflows/dual.yaml +43 -21
  54. package/builtins/ja/workflows/frontend-mini.yaml +9 -9
  55. package/builtins/ja/workflows/frontend.yaml +43 -21
  56. package/builtins/ja/workflows/peer-review.yaml +208 -0
  57. package/builtins/ja/workflows/review-fix-takt-default.yaml +23 -23
  58. package/builtins/ja/workflows/review-takt-default.yaml +5 -5
  59. package/builtins/ja/workflows/takt-default-refresh-all.yaml +42 -20
  60. package/builtins/ja/workflows/takt-default-refresh-fast.yaml +42 -20
  61. package/builtins/ja/workflows/takt-default.yaml +18 -300
  62. package/builtins/ja/workflows/terraform.yaml +11 -11
  63. package/builtins/schemas/followup-task.json +7 -1
  64. package/builtins/schemas/pr-followup-task.json +2 -1
  65. package/builtins/skill/references/engine.md +4 -4
  66. package/dist/features/interactive/passthroughMode.js +1 -1
  67. package/dist/features/interactive/passthroughMode.js.map +1 -1
  68. package/dist/features/interactive/quietMode.js +1 -1
  69. package/dist/features/interactive/quietMode.js.map +1 -1
  70. package/dist/features/tasks/list/index.d.ts.map +1 -1
  71. package/dist/features/tasks/list/index.js +8 -4
  72. package/dist/features/tasks/list/index.js.map +1 -1
  73. package/dist/features/tasks/list/requeueHelpers.d.ts +3 -1
  74. package/dist/features/tasks/list/requeueHelpers.d.ts.map +1 -1
  75. package/dist/features/tasks/list/requeueHelpers.js +78 -37
  76. package/dist/features/tasks/list/requeueHelpers.js.map +1 -1
  77. package/dist/features/tasks/list/taskInstructionActions.d.ts.map +1 -1
  78. package/dist/features/tasks/list/taskInstructionActions.js +20 -18
  79. package/dist/features/tasks/list/taskInstructionActions.js.map +1 -1
  80. package/dist/features/tasks/list/taskRetryActions.d.ts +1 -0
  81. package/dist/features/tasks/list/taskRetryActions.d.ts.map +1 -1
  82. package/dist/features/tasks/list/taskRetryActions.js +121 -58
  83. package/dist/features/tasks/list/taskRetryActions.js.map +1 -1
  84. package/dist/infra/codex/client.d.ts.map +1 -1
  85. package/dist/infra/codex/client.js +3 -1
  86. package/dist/infra/codex/client.js.map +1 -1
  87. package/dist/infra/task/runner.d.ts +2 -2
  88. package/dist/infra/task/runner.d.ts.map +1 -1
  89. package/dist/infra/task/runner.js +4 -4
  90. package/dist/infra/task/runner.js.map +1 -1
  91. package/dist/infra/task/taskRecordMutations.d.ts +1 -1
  92. package/dist/infra/task/taskRecordMutations.d.ts.map +1 -1
  93. package/dist/infra/task/taskRecordMutations.js +9 -7
  94. package/dist/infra/task/taskRecordMutations.js.map +1 -1
  95. package/dist/infra/task/taskRetryService.d.ts +2 -2
  96. package/dist/infra/task/taskRetryService.d.ts.map +1 -1
  97. package/dist/infra/task/taskRetryService.js +9 -10
  98. package/dist/infra/task/taskRetryService.js.map +1 -1
  99. package/dist/shared/i18n/labels_en.yaml +2 -0
  100. package/dist/shared/i18n/labels_ja.yaml +2 -0
  101. package/package.json +1 -1
  102. package/builtins/en/facets/instructions/review-ai.md +0 -11
  103. package/builtins/ja/facets/instructions/review-ai.md +0 -11
  104. /package/builtins/en/facets/instructions/{ai-fix.md → ai-antipattern-fix.md} +0 -0
  105. /package/builtins/en/facets/instructions/{ai-review.md → ai-antipattern-review.md} +0 -0
  106. /package/builtins/en/facets/output-contracts/{ai-review.md → ai-antipattern-review.md} +0 -0
  107. /package/builtins/ja/facets/instructions/{ai-fix.md → ai-antipattern-fix.md} +0 -0
  108. /package/builtins/ja/facets/instructions/{ai-review.md → ai-antipattern-review.md} +0 -0
  109. /package/builtins/ja/facets/output-contracts/{ai-review.md → ai-antipattern-review.md} +0 -0
package/README.md CHANGED
@@ -86,7 +86,7 @@ takt run
86
86
  ### Manage results
87
87
 
88
88
  ```bash
89
- # List task branches — merge, retry, force-fail, or delete
89
+ # List task branches — merge, retry, requeue, force-fail, or delete
90
90
  takt list
91
91
  ```
92
92
 
@@ -150,7 +150,7 @@ See the [Builtin Catalog](./docs/builtin-catalog.md) for all workflows and perso
150
150
  |---------|-------------|
151
151
  | `takt` | Talk to AI, refine requirements, execute or queue tasks |
152
152
  | `takt run` | Execute all pending tasks |
153
- | `takt list` | Manage task branches (merge, retry, force-fail, instruct, delete) |
153
+ | `takt list` | Manage task branches (merge, retry, requeue, force-fail, instruct, delete) |
154
154
  | `takt #N` | Execute GitHub Issue as task |
155
155
  | `takt eject` | Copy builtin workflows/facets for customization |
156
156
  | `takt workflow init` | Create a new workflow scaffold |
@@ -1,14 +1,14 @@
1
- The ai_review (reviewer) and ai_fix (coder) disagree.
1
+ The ai-antipattern-review-1st (reviewer) and ai-antipattern-fix (coder) disagree.
2
2
 
3
- - ai_review flagged issues and issued a REJECT
4
- - ai_fix reviewed and determined "no fix needed"
3
+ - ai-antipattern-review-1st flagged issues and issued a REJECT
4
+ - ai-antipattern-fix reviewed and determined "no fix needed"
5
5
 
6
6
  Review both outputs and arbitrate which judgment is valid.
7
7
 
8
8
  **Reports to reference:**
9
- - AI review results: {report:ai-review.md}
9
+ - AI review results: {report:ai-antipattern-review.md}
10
10
 
11
11
  **Judgment criteria:**
12
- - Whether ai_review's findings are specific and point to real issues in the code
13
- - Whether ai_fix's rebuttal has evidence (file verification results, test results)
12
+ - Whether ai-antipattern-review-1st's findings are specific and point to real issues in the code
13
+ - Whether ai-antipattern-fix's rebuttal has evidence (file verification results, test results)
14
14
  - Whether the findings are non-blocking (record only) level or actually require fixes
@@ -1,10 +1,10 @@
1
- The ai_reviewai_fix loop has repeated {cycle_count} times.
1
+ The ai-antipattern-review-1stai-antipattern-fix loop has repeated {cycle_count} times.
2
2
 
3
3
  Review the reports from each cycle and determine whether this loop
4
4
  is healthy (making progress) or unproductive (repeating the same issues).
5
5
 
6
6
  **Reports to reference:**
7
- - AI Review results: {report:ai-review.md}
7
+ - AI Review results: {report:ai-antipattern-review.md}
8
8
 
9
9
  **Judgment criteria:**
10
10
  - Are the same finding_ids persisting across multiple cycles?
@@ -1,5 +1,5 @@
1
1
  Focus on reviewing **architecture and design**.
2
- Do not review AI-specific issues (already covered by the ai_review step).
2
+ Do not review AI-specific issues (already covered by the ai-antipattern-review-1st step).
3
3
 
4
4
  **Review criteria:**
5
5
  - Structural and design validity
@@ -1,5 +1,5 @@
1
1
  Review the changes from the perspective of CQRS (Command Query Responsibility Segregation) and Event Sourcing.
2
- AI-specific issue review is not needed (already covered by the ai_review step).
2
+ AI-specific issue review is not needed (already covered by the ai-antipattern-review-1st step).
3
3
 
4
4
  **Review criteria:**
5
5
  - Aggregate design validity
@@ -1,5 +1,5 @@
1
1
  Focus on reviewing **Terraform convention compliance**.
2
- Do not review AI-specific issues (already covered by the ai_review step).
2
+ Do not review AI-specific issues (already covered by the ai-antipattern-review-1st step).
3
3
 
4
4
  **Review criteria:**
5
5
  - Variable declaration compliance (type, description, sensitive)
@@ -150,6 +150,25 @@ Test file length and duplication are warning-level maintainability concerns by d
150
150
  - inability to detect regressions
151
151
  - "Too long" or "duplicated" alone is not sufficient for `REJECT`
152
152
 
153
+ ## Handling Changelog and History Files
154
+
155
+ Files or sections that record point-in-time facts (e.g., `CHANGELOG.md`, `RELEASE_NOTES.md`, `MIGRATION.md`) are history, not specifications of the current code. Judge them by their correctness as history.
156
+
157
+ | Target | Judgment |
158
+ |--------|----------|
159
+ | Past entry's config keys, API names, or behaviors do not match current code | REJECT prohibited |
160
+ | Records that were correct at the time of the relevant release | Modification requests prohibited |
161
+ | Factual errors in newly added entries (relative to the target release) | REJECT allowed |
162
+ | Markdown formatting issues, duplication, broken links, obvious typos | REJECT or Warning allowed |
163
+
164
+ ### Judgment Criteria
165
+
166
+ - History records "what changed at that point in time," not "how the system currently works"
167
+ - Even if names or behaviors have been changed in current code, that is not grounds to rewrite past entries
168
+ - To request modification of a past entry, demonstrate that it was incorrect even at the relevant release point
169
+ - Identify history files/sections by file name (`CHANGELOG.md`, etc.) or conventional headings (`### Changed`, `### Added`, dated release headings)
170
+ - Do not REJECT a history file or section based solely on disagreement with current schema or current config keys
171
+
153
172
  ## Boy Scout Rule
154
173
 
155
174
  Leave it better than you found it.
@@ -87,7 +87,9 @@ steps:
87
87
 
88
88
  Do not implement anything. Output only the next task instruction in task_markdown.
89
89
  Output the next action in action.
90
- If needed, output the issue creation plan in issue.
90
+ Always output task_markdown and issue.
91
+ For wait_before_next_scan, set task_markdown to an empty string and issue to { create: false, labels: [] }.
92
+ For an existing issue task, set issue.create to false unless a new GitHub Issue is explicitly needed.
91
93
 
92
94
  Allowed action values:
93
95
  - enqueue_new_task
@@ -148,7 +150,9 @@ steps:
148
150
 
149
151
  Do not implement anything. Output only the next task instruction in task_markdown.
150
152
  Output the next action in action.
151
- If needed, output the issue creation plan in issue.
153
+ Always output task_markdown and issue.
154
+ For wait_before_next_scan, set task_markdown to an empty string and issue to { create: false, labels: [] }.
155
+ For a fresh improvement task, set issue.create to true so the task is backed by a GitHub Issue.
152
156
 
153
157
  Allowed action values:
154
158
  - enqueue_new_task
@@ -199,7 +203,9 @@ steps:
199
203
  - head_branch: {context:route_context.selected_pr.head_branch}
200
204
 
201
205
  Output the next action in action.
202
- If a follow-up implementation task is needed, output it in task_markdown.
206
+ Always output task_markdown.
207
+ For prepare_merge or reject_pr, set task_markdown to an empty string.
208
+ For enqueue_from_pr, output the follow-up implementation task in task_markdown.
203
209
 
204
210
  Allowed action values:
205
211
  - enqueue_from_pr
@@ -92,7 +92,7 @@ steps:
92
92
  format: coder-decisions
93
93
  - name: reviewers
94
94
  parallel:
95
- - name: ai_review
95
+ - name: ai-antipattern-review-2nd
96
96
  edit: false
97
97
  persona: ai-antipattern-reviewer
98
98
  policy:
@@ -106,14 +106,14 @@ steps:
106
106
  - Grep
107
107
  - WebSearch
108
108
  - WebFetch
109
- instruction: review-ai
109
+ instruction: ai-antipattern-review
110
110
  rules:
111
111
  - condition: No AI-specific issues
112
112
  - condition: AI-specific issues found
113
113
  output_contracts:
114
114
  report:
115
- - name: ai-review.md
116
- format: ai-review
115
+ - name: ai-antipattern-review.md
116
+ format: ai-antipattern-review
117
117
  - name: supervise
118
118
  edit: false
119
119
  persona: supervisor
@@ -149,12 +149,12 @@ steps:
149
149
  - condition: all("AI-specific issues found", "Requirements unmet, tests failing")
150
150
  next: fix_both
151
151
  - condition: any("AI-specific issues found")
152
- next: ai_fix
152
+ next: ai-antipattern-fix
153
153
  - condition: any("Requirements unmet, tests failing")
154
154
  next: supervise_fix
155
155
  - name: fix_both
156
156
  parallel:
157
- - name: ai_fix_parallel
157
+ - name: ai-antipattern-fix-parallel
158
158
  edit: true
159
159
  persona: coder
160
160
  policy:
@@ -180,7 +180,7 @@ steps:
180
180
  - condition: AI Reviewer's issues fixed
181
181
  - condition: No fix needed (verified target files/spec)
182
182
  - condition: Cannot proceed, insufficient info
183
- instruction: ai-fix
183
+ instruction: ai-antipattern-fix
184
184
  - name: supervise_fix_parallel
185
185
  edit: true
186
186
  persona: coder
@@ -212,7 +212,7 @@ steps:
212
212
  next: reviewers
213
213
  - condition: any("No fix needed (verified target files/spec)", "Cannot proceed, insufficient info")
214
214
  next: implement
215
- - name: ai_fix
215
+ - name: ai-antipattern-fix
216
216
  edit: true
217
217
  persona: coder
218
218
  policy:
@@ -243,7 +243,7 @@ steps:
243
243
  next: implement
244
244
  - condition: Cannot proceed, insufficient info
245
245
  next: implement
246
- instruction: ai-fix
246
+ instruction: ai-antipattern-fix
247
247
  - name: supervise_fix
248
248
  edit: true
249
249
  persona: coder
@@ -10,15 +10,15 @@ max_steps: 60
10
10
  initial_step: plan
11
11
  loop_monitors:
12
12
  - cycle:
13
- - ai_review
14
- - ai_fix
13
+ - ai-antipattern-review-1st
14
+ - ai-antipattern-fix
15
15
  threshold: 3
16
16
  judge:
17
17
  persona: supervisor
18
- instruction: loop-monitor-ai-fix
18
+ instruction: loop-monitor-ai-antipattern-fix
19
19
  rules:
20
20
  - condition: Healthy (making progress)
21
- next: ai_review
21
+ next: ai-antipattern-review-1st
22
22
  - condition: Unproductive (no improvement)
23
23
  next: reviewers_1
24
24
  - cycle:
@@ -126,11 +126,11 @@ steps:
126
126
  instruction: implement
127
127
  rules:
128
128
  - condition: Implementation is complete
129
- next: ai_review
129
+ next: ai-antipattern-review-1st
130
130
  - condition: No implementation (report only)
131
- next: ai_review
131
+ next: ai-antipattern-review-1st
132
132
  - condition: Cannot proceed with implementation
133
- next: ai_review
133
+ next: ai-antipattern-review-1st
134
134
  - condition: User input required
135
135
  next: implement
136
136
  requires_user_input: true
@@ -141,7 +141,7 @@ steps:
141
141
  format: coder-scope
142
142
  - name: coder-decisions.md
143
143
  format: coder-decisions
144
- - name: ai_review
144
+ - name: ai-antipattern-review-1st
145
145
  edit: false
146
146
  persona: ai-antipattern-reviewer
147
147
  policy:
@@ -155,17 +155,17 @@ steps:
155
155
  - Grep
156
156
  - WebSearch
157
157
  - WebFetch
158
- instruction: ai-review
158
+ instruction: ai-antipattern-review
159
159
  rules:
160
160
  - condition: No AI-specific issues found
161
161
  next: reviewers_1
162
162
  - condition: AI-specific issues detected
163
- next: ai_fix
163
+ next: ai-antipattern-fix
164
164
  output_contracts:
165
165
  report:
166
- - name: ai-review.md
167
- format: ai-review
168
- - name: ai_fix
166
+ - name: ai-antipattern-review.md
167
+ format: ai-antipattern-review
168
+ - name: ai-antipattern-fix
169
169
  edit: true
170
170
  persona: coder
171
171
  policy:
@@ -188,16 +188,16 @@ steps:
188
188
  - Bash
189
189
  - WebSearch
190
190
  - WebFetch
191
- instruction: ai-fix
191
+ instruction: ai-antipattern-fix
192
192
  pass_previous_response: false
193
193
  rules:
194
194
  - condition: AI Reviewer's issues have been fixed
195
- next: ai_review
195
+ next: ai-antipattern-review-1st
196
196
  - condition: No fix needed (verified target files/spec)
197
- next: ai_no_fix
197
+ next: ai-antipattern-no-fix
198
198
  - condition: Unable to proceed with fixes
199
- next: ai_no_fix
200
- - name: ai_no_fix
199
+ next: ai-antipattern-no-fix
200
+ - name: ai-antipattern-no-fix
201
201
  edit: false
202
202
  persona: architecture-reviewer
203
203
  policy: review
@@ -208,9 +208,9 @@ steps:
208
208
  - Glob
209
209
  - Grep
210
210
  rules:
211
- - condition: ai_review's findings are valid (fix required)
212
- next: ai_fix
213
- - condition: ai_fix's judgment is valid (no fix needed)
211
+ - condition: ai-antipattern-review-1st's findings are valid (fix required)
212
+ next: ai-antipattern-fix
213
+ - condition: ai-antipattern-fix's judgment is valid (no fix needed)
214
214
  next: reviewers_1
215
215
  instruction: arbitrate
216
216
  - name: reviewers_1
@@ -263,6 +263,28 @@ steps:
263
263
  report:
264
264
  - name: testing-review.md
265
265
  format: testing-review
266
+ - name: ai-antipattern-review-2nd
267
+ edit: false
268
+ persona: ai-antipattern-reviewer
269
+ policy:
270
+ - review
271
+ - ai-antipattern
272
+ provider_options:
273
+ claude:
274
+ allowed_tools:
275
+ - Read
276
+ - Glob
277
+ - Grep
278
+ - WebSearch
279
+ - WebFetch
280
+ instruction: ai-antipattern-review
281
+ rules:
282
+ - condition: approved
283
+ - condition: needs_fix
284
+ output_contracts:
285
+ report:
286
+ - name: ai-antipattern-review.md
287
+ format: ai-antipattern-review
266
288
  rules:
267
289
  - condition: all("approved")
268
290
  next: reviewers_2
@@ -90,7 +90,7 @@ steps:
90
90
  format: coder-decisions
91
91
  - name: reviewers
92
92
  parallel:
93
- - name: ai_review
93
+ - name: ai-antipattern-review-2nd
94
94
  edit: false
95
95
  persona: ai-antipattern-reviewer
96
96
  policy:
@@ -104,14 +104,14 @@ steps:
104
104
  - Grep
105
105
  - WebSearch
106
106
  - WebFetch
107
- instruction: review-ai
107
+ instruction: ai-antipattern-review
108
108
  rules:
109
109
  - condition: No AI-specific issues
110
110
  - condition: AI-specific issues found
111
111
  output_contracts:
112
112
  report:
113
- - name: ai-review.md
114
- format: ai-review
113
+ - name: ai-antipattern-review.md
114
+ format: ai-antipattern-review
115
115
  - name: supervise
116
116
  edit: false
117
117
  persona: supervisor
@@ -146,12 +146,12 @@ steps:
146
146
  - condition: all("AI-specific issues found", "Requirements unmet, tests failing")
147
147
  next: fix_both
148
148
  - condition: any("AI-specific issues found")
149
- next: ai_fix
149
+ next: ai-antipattern-fix
150
150
  - condition: any("Requirements unmet, tests failing")
151
151
  next: supervise_fix
152
152
  - name: fix_both
153
153
  parallel:
154
- - name: ai_fix_parallel
154
+ - name: ai-antipattern-fix-parallel
155
155
  edit: true
156
156
  persona: coder
157
157
  policy:
@@ -176,7 +176,7 @@ steps:
176
176
  - condition: AI Reviewer's issues fixed
177
177
  - condition: No fix needed (verified target files/spec)
178
178
  - condition: Cannot proceed, insufficient info
179
- instruction: ai-fix
179
+ instruction: ai-antipattern-fix
180
180
  - name: supervise_fix_parallel
181
181
  edit: true
182
182
  persona: coder
@@ -207,7 +207,7 @@ steps:
207
207
  next: reviewers
208
208
  - condition: any("No fix needed (verified target files/spec)", "Cannot proceed, insufficient info")
209
209
  next: implement
210
- - name: ai_fix
210
+ - name: ai-antipattern-fix
211
211
  edit: true
212
212
  persona: coder
213
213
  policy:
@@ -237,7 +237,7 @@ steps:
237
237
  next: implement
238
238
  - condition: Cannot proceed, insufficient info
239
239
  next: implement
240
- instruction: ai-fix
240
+ instruction: ai-antipattern-fix
241
241
  - name: supervise_fix
242
242
  edit: true
243
243
  persona: coder
@@ -10,15 +10,15 @@ max_steps: 60
10
10
  initial_step: plan
11
11
  loop_monitors:
12
12
  - cycle:
13
- - ai_review
14
- - ai_fix
13
+ - ai-antipattern-review-1st
14
+ - ai-antipattern-fix
15
15
  threshold: 3
16
16
  judge:
17
17
  persona: supervisor
18
- instruction: loop-monitor-ai-fix
18
+ instruction: loop-monitor-ai-antipattern-fix
19
19
  rules:
20
20
  - condition: Healthy (making progress)
21
- next: ai_review
21
+ next: ai-antipattern-review-1st
22
22
  - condition: Unproductive (no improvement)
23
23
  next: reviewers_1
24
24
  - cycle:
@@ -123,11 +123,11 @@ steps:
123
123
  instruction: implement
124
124
  rules:
125
125
  - condition: Implementation is complete
126
- next: ai_review
126
+ next: ai-antipattern-review-1st
127
127
  - condition: No implementation (report only)
128
- next: ai_review
128
+ next: ai-antipattern-review-1st
129
129
  - condition: Cannot proceed with implementation
130
- next: ai_review
130
+ next: ai-antipattern-review-1st
131
131
  - condition: User input required
132
132
  next: implement
133
133
  requires_user_input: true
@@ -138,7 +138,7 @@ steps:
138
138
  format: coder-scope
139
139
  - name: coder-decisions.md
140
140
  format: coder-decisions
141
- - name: ai_review
141
+ - name: ai-antipattern-review-1st
142
142
  edit: false
143
143
  persona: ai-antipattern-reviewer
144
144
  policy:
@@ -152,17 +152,17 @@ steps:
152
152
  - Grep
153
153
  - WebSearch
154
154
  - WebFetch
155
- instruction: ai-review
155
+ instruction: ai-antipattern-review
156
156
  rules:
157
157
  - condition: No AI-specific issues found
158
158
  next: reviewers_1
159
159
  - condition: AI-specific issues detected
160
- next: ai_fix
160
+ next: ai-antipattern-fix
161
161
  output_contracts:
162
162
  report:
163
- - name: ai-review.md
164
- format: ai-review
165
- - name: ai_fix
163
+ - name: ai-antipattern-review.md
164
+ format: ai-antipattern-review
165
+ - name: ai-antipattern-fix
166
166
  edit: true
167
167
  persona: coder
168
168
  policy:
@@ -184,16 +184,16 @@ steps:
184
184
  - Bash
185
185
  - WebSearch
186
186
  - WebFetch
187
- instruction: ai-fix
187
+ instruction: ai-antipattern-fix
188
188
  pass_previous_response: false
189
189
  rules:
190
190
  - condition: AI Reviewer's issues have been fixed
191
- next: ai_review
191
+ next: ai-antipattern-review-1st
192
192
  - condition: No fix needed (verified target files/spec)
193
- next: ai_no_fix
193
+ next: ai-antipattern-no-fix
194
194
  - condition: Unable to proceed with fixes
195
- next: ai_no_fix
196
- - name: ai_no_fix
195
+ next: ai-antipattern-no-fix
196
+ - name: ai-antipattern-no-fix
197
197
  edit: false
198
198
  persona: architecture-reviewer
199
199
  policy: review
@@ -204,9 +204,9 @@ steps:
204
204
  - Glob
205
205
  - Grep
206
206
  rules:
207
- - condition: ai_review's findings are valid (fix required)
208
- next: ai_fix
209
- - condition: ai_fix's judgment is valid (no fix needed)
207
+ - condition: ai-antipattern-review-1st's findings are valid (fix required)
208
+ next: ai-antipattern-fix
209
+ - condition: ai-antipattern-fix's judgment is valid (no fix needed)
210
210
  next: reviewers_1
211
211
  instruction: arbitrate
212
212
  - name: reviewers_1
@@ -259,6 +259,28 @@ steps:
259
259
  report:
260
260
  - name: testing-review.md
261
261
  format: testing-review
262
+ - name: ai-antipattern-review-2nd
263
+ edit: false
264
+ persona: ai-antipattern-reviewer
265
+ policy:
266
+ - review
267
+ - ai-antipattern
268
+ provider_options:
269
+ claude:
270
+ allowed_tools:
271
+ - Read
272
+ - Glob
273
+ - Grep
274
+ - WebSearch
275
+ - WebFetch
276
+ instruction: ai-antipattern-review
277
+ rules:
278
+ - condition: approved
279
+ - condition: needs_fix
280
+ output_contracts:
281
+ report:
282
+ - name: ai-antipattern-review.md
283
+ format: ai-antipattern-review
262
284
  rules:
263
285
  - condition: all("approved")
264
286
  next: reviewers_2
@@ -0,0 +1,128 @@
1
+ name: default-draft
2
+ description: default series Phase 1. Implement -> AI-antipattern self-review ⇄ fix loop.
3
+ subworkflow:
4
+ callable: true
5
+ visibility: internal
6
+ returns:
7
+ - need_replan
8
+ params:
9
+ impl_instruction:
10
+ type: facet_ref
11
+ facet_kind: instruction
12
+ default: implement
13
+ workflow_config:
14
+ provider_options:
15
+ codex:
16
+ network_access: true
17
+ opencode:
18
+ network_access: true
19
+ max_steps: 30
20
+ initial_step: implement
21
+ loop_monitors:
22
+ - cycle:
23
+ - ai-antipattern-review-1st
24
+ - ai-antipattern-fix
25
+ threshold: 3
26
+ judge:
27
+ persona: supervisor
28
+ instruction: loop-monitor-ai-antipattern-fix
29
+ rules:
30
+ - condition: Healthy (making progress)
31
+ next: ai-antipattern-review-1st
32
+ - condition: Unproductive (no improvement)
33
+ next: COMPLETE
34
+ steps:
35
+ - name: implement
36
+ edit: true
37
+ persona: coder
38
+ policy:
39
+ - coding
40
+ - testing
41
+ session: refresh
42
+ knowledge:
43
+ - architecture
44
+ provider_options:
45
+ claude:
46
+ allowed_tools:
47
+ - Read
48
+ - Glob
49
+ - Grep
50
+ - Edit
51
+ - Write
52
+ - Bash
53
+ - WebSearch
54
+ - WebFetch
55
+ required_permission_mode: edit
56
+ instruction:
57
+ $param: impl_instruction
58
+ rules:
59
+ - condition: Implementation complete
60
+ next: ai-antipattern-review-1st
61
+ - condition: No implementation (report only)
62
+ next: ai-antipattern-review-1st
63
+ - condition: Cannot proceed, insufficient info
64
+ return: need_replan
65
+ - condition: User input required
66
+ next: implement
67
+ requires_user_input: true
68
+ interactive_only: true
69
+ output_contracts:
70
+ report:
71
+ - name: coder-scope.md
72
+ format: coder-scope
73
+ - name: coder-decisions.md
74
+ format: coder-decisions
75
+ - name: ai-antipattern-review-1st
76
+ edit: false
77
+ persona: ai-antipattern-reviewer
78
+ policy:
79
+ - review
80
+ - ai-antipattern
81
+ provider_options:
82
+ claude:
83
+ allowed_tools:
84
+ - Read
85
+ - Glob
86
+ - Grep
87
+ - WebSearch
88
+ - WebFetch
89
+ instruction: ai-antipattern-review
90
+ rules:
91
+ - condition: No AI-specific issues
92
+ next: COMPLETE
93
+ - condition: AI-specific issues found
94
+ next: ai-antipattern-fix
95
+ output_contracts:
96
+ report:
97
+ - name: ai-antipattern-review.md
98
+ format: ai-antipattern-review
99
+ - name: ai-antipattern-fix
100
+ edit: true
101
+ persona: coder
102
+ policy:
103
+ - coding
104
+ - testing
105
+ session: refresh
106
+ knowledge:
107
+ - architecture
108
+ provider_options:
109
+ claude:
110
+ allowed_tools:
111
+ - Read
112
+ - Glob
113
+ - Grep
114
+ - Edit
115
+ - Write
116
+ - Bash
117
+ - WebSearch
118
+ - WebFetch
119
+ required_permission_mode: edit
120
+ instruction: ai-antipattern-fix
121
+ pass_previous_response: false
122
+ rules:
123
+ - condition: AI issues fixed
124
+ next: ai-antipattern-review-1st
125
+ - condition: No fix needed (verified target files/spec)
126
+ next: COMPLETE
127
+ - condition: Cannot proceed with fixes
128
+ next: COMPLETE