takt 0.2.3 → 0.3.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/README.md +186 -162
- package/dist/agents/runner.d.ts +2 -4
- package/dist/agents/runner.d.ts.map +1 -1
- package/dist/agents/runner.js +6 -35
- package/dist/agents/runner.js.map +1 -1
- package/dist/claude/client.d.ts +31 -6
- package/dist/claude/client.d.ts.map +1 -1
- package/dist/claude/client.js +78 -30
- package/dist/claude/client.js.map +1 -1
- package/dist/claude/executor.d.ts.map +1 -1
- package/dist/claude/executor.js +17 -8
- package/dist/claude/executor.js.map +1 -1
- package/dist/claude/index.d.ts +1 -1
- package/dist/claude/index.d.ts.map +1 -1
- package/dist/claude/index.js +1 -1
- package/dist/claude/index.js.map +1 -1
- package/dist/cli.d.ts +5 -5
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +160 -119
- package/dist/cli.js.map +1 -1
- package/dist/codex/client.d.ts +0 -1
- package/dist/codex/client.d.ts.map +1 -1
- package/dist/codex/client.js +3 -6
- package/dist/codex/client.js.map +1 -1
- package/dist/commands/addTask.d.ts +15 -8
- package/dist/commands/addTask.d.ts.map +1 -1
- package/dist/commands/addTask.js +63 -26
- package/dist/commands/addTask.js.map +1 -1
- package/dist/commands/eject.d.ts +13 -0
- package/dist/commands/eject.d.ts.map +1 -0
- package/dist/commands/eject.js +105 -0
- package/dist/commands/eject.js.map +1 -0
- package/dist/commands/index.d.ts +2 -2
- package/dist/commands/index.d.ts.map +1 -1
- package/dist/commands/index.js +2 -2
- package/dist/commands/index.js.map +1 -1
- package/dist/commands/interactive.d.ts +28 -0
- package/dist/commands/interactive.d.ts.map +1 -0
- package/dist/commands/interactive.js +186 -0
- package/dist/commands/interactive.js.map +1 -0
- package/dist/commands/taskExecution.js +2 -2
- package/dist/commands/taskExecution.js.map +1 -1
- package/dist/commands/workflowExecution.d.ts.map +1 -1
- package/dist/commands/workflowExecution.js +85 -18
- package/dist/commands/workflowExecution.js.map +1 -1
- package/dist/config/agentLoader.d.ts +3 -1
- package/dist/config/agentLoader.d.ts.map +1 -1
- package/dist/config/agentLoader.js +17 -24
- package/dist/config/agentLoader.js.map +1 -1
- package/dist/config/globalConfig.d.ts +2 -0
- package/dist/config/globalConfig.d.ts.map +1 -1
- package/dist/config/globalConfig.js +14 -0
- package/dist/config/globalConfig.js.map +1 -1
- package/dist/config/initialization.d.ts +7 -5
- package/dist/config/initialization.d.ts.map +1 -1
- package/dist/config/initialization.js +23 -21
- package/dist/config/initialization.js.map +1 -1
- package/dist/config/paths.d.ts +5 -0
- package/dist/config/paths.d.ts.map +1 -1
- package/dist/config/paths.js +9 -0
- package/dist/config/paths.js.map +1 -1
- package/dist/config/workflowLoader.d.ts +6 -4
- package/dist/config/workflowLoader.d.ts.map +1 -1
- package/dist/config/workflowLoader.js +190 -35
- package/dist/config/workflowLoader.js.map +1 -1
- package/dist/github/issue.d.ts +72 -0
- package/dist/github/issue.d.ts.map +1 -0
- package/dist/github/issue.js +143 -0
- package/dist/github/issue.js.map +1 -0
- package/dist/models/index.d.ts +1 -1
- package/dist/models/index.d.ts.map +1 -1
- package/dist/models/index.js.map +1 -1
- package/dist/models/schemas.d.ts +164 -90
- package/dist/models/schemas.d.ts.map +1 -1
- package/dist/models/schemas.js +77 -51
- package/dist/models/schemas.js.map +1 -1
- package/dist/models/types.d.ts +51 -20
- package/dist/models/types.d.ts.map +1 -1
- package/dist/prompt/index.d.ts +0 -7
- package/dist/prompt/index.d.ts.map +1 -1
- package/dist/prompt/index.js +0 -11
- package/dist/prompt/index.js.map +1 -1
- package/dist/providers/claude.js +2 -2
- package/dist/providers/claude.js.map +1 -1
- package/dist/providers/codex.d.ts.map +1 -1
- package/dist/providers/codex.js +0 -2
- package/dist/providers/codex.js.map +1 -1
- package/dist/providers/index.d.ts +2 -1
- package/dist/providers/index.d.ts.map +1 -1
- package/dist/providers/index.js.map +1 -1
- package/dist/resources/index.d.ts +3 -22
- package/dist/resources/index.d.ts.map +1 -1
- package/dist/resources/index.js +3 -73
- package/dist/resources/index.js.map +1 -1
- package/dist/task/display.js +1 -1
- package/dist/task/display.js.map +1 -1
- package/dist/utils/session.d.ts +74 -10
- package/dist/utils/session.d.ts.map +1 -1
- package/dist/utils/session.js +101 -51
- package/dist/utils/session.js.map +1 -1
- package/dist/workflow/engine.d.ts +34 -1
- package/dist/workflow/engine.d.ts.map +1 -1
- package/dist/workflow/engine.js +228 -36
- package/dist/workflow/engine.js.map +1 -1
- package/dist/workflow/index.d.ts +1 -1
- package/dist/workflow/index.d.ts.map +1 -1
- package/dist/workflow/index.js +1 -1
- package/dist/workflow/index.js.map +1 -1
- package/dist/workflow/instruction-builder.d.ts +87 -18
- package/dist/workflow/instruction-builder.d.ts.map +1 -1
- package/dist/workflow/instruction-builder.js +404 -57
- package/dist/workflow/instruction-builder.js.map +1 -1
- package/dist/workflow/parallel-logger.d.ts +76 -0
- package/dist/workflow/parallel-logger.d.ts.map +1 -0
- package/dist/workflow/parallel-logger.js +173 -0
- package/dist/workflow/parallel-logger.js.map +1 -0
- package/dist/workflow/phase-runner.d.ts +40 -0
- package/dist/workflow/phase-runner.d.ts.map +1 -0
- package/dist/workflow/phase-runner.js +69 -0
- package/dist/workflow/phase-runner.js.map +1 -0
- package/dist/workflow/rule-evaluator.d.ts +64 -0
- package/dist/workflow/rule-evaluator.d.ts.map +1 -0
- package/dist/workflow/rule-evaluator.js +178 -0
- package/dist/workflow/rule-evaluator.js.map +1 -0
- package/dist/workflow/rule-utils.d.ts +13 -0
- package/dist/workflow/rule-utils.d.ts.map +1 -0
- package/dist/workflow/rule-utils.js +17 -0
- package/dist/workflow/rule-utils.js.map +1 -0
- package/dist/workflow/transitions.d.ts +5 -13
- package/dist/workflow/transitions.d.ts.map +1 -1
- package/dist/workflow/transitions.js +8 -78
- package/dist/workflow/transitions.js.map +1 -1
- package/dist/workflow/types.d.ts +2 -1
- package/dist/workflow/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/resources/global/en/agents/default/ai-antipattern-reviewer.md +84 -15
- package/resources/global/en/agents/default/{architect.md → architecture-reviewer.md} +144 -44
- package/resources/global/en/agents/default/coder.md +4 -4
- package/resources/global/en/agents/default/planner.md +16 -9
- package/resources/global/en/agents/default/{security.md → security-reviewer.md} +23 -5
- package/resources/global/en/agents/default/supervisor.md +22 -2
- package/resources/global/en/agents/expert/frontend-reviewer.md +0 -17
- package/resources/global/en/agents/expert/qa-reviewer.md +0 -16
- package/resources/global/en/agents/expert/security-reviewer.md +0 -16
- package/resources/global/en/agents/expert/supervisor.md +2 -0
- package/resources/global/en/agents/expert-cqrs/cqrs-es-reviewer.md +0 -17
- package/resources/global/en/agents/templates/coder.md +128 -0
- package/resources/global/en/agents/templates/planner.md +44 -0
- package/resources/global/en/agents/templates/reviewer.md +57 -0
- package/resources/global/en/agents/templates/supervisor.md +64 -0
- package/resources/global/en/workflows/default.yaml +232 -772
- package/resources/global/en/workflows/expert-cqrs.yaml +319 -698
- package/resources/global/en/workflows/expert.yaml +348 -723
- package/resources/global/en/workflows/magi.yaml +45 -52
- package/resources/global/en/workflows/research.yaml +18 -99
- package/resources/global/en/workflows/simple.yaml +152 -421
- package/resources/global/ja/agents/default/ai-antipattern-reviewer.md +84 -15
- package/resources/global/ja/agents/default/{architect.md → architecture-reviewer.md} +148 -48
- package/resources/global/ja/agents/default/coder.md +4 -4
- package/resources/global/ja/agents/default/planner.md +16 -9
- package/resources/global/ja/agents/default/{security.md → security-reviewer.md} +23 -5
- package/resources/global/ja/agents/default/supervisor.md +22 -2
- package/resources/global/ja/agents/expert/frontend-reviewer.md +0 -18
- package/resources/global/ja/agents/expert/qa-reviewer.md +0 -16
- package/resources/global/ja/agents/expert/security-reviewer.md +0 -16
- package/resources/global/ja/agents/expert/supervisor.md +2 -0
- package/resources/global/ja/agents/expert-cqrs/cqrs-es-reviewer.md +0 -18
- package/resources/global/ja/agents/templates/coder.md +128 -0
- package/resources/global/ja/agents/templates/planner.md +44 -0
- package/resources/global/ja/agents/templates/reviewer.md +57 -0
- package/resources/global/ja/agents/templates/supervisor.md +64 -0
- package/resources/global/ja/workflows/default.yaml +227 -773
- package/resources/global/ja/workflows/expert-cqrs.yaml +309 -833
- package/resources/global/ja/workflows/expert.yaml +325 -712
- package/resources/global/ja/workflows/magi.yaml +45 -52
- package/resources/global/ja/workflows/research.yaml +18 -99
- package/resources/global/ja/workflows/simple.yaml +145 -415
- package/dist/commands/help.d.ts +0 -8
- package/dist/commands/help.d.ts.map +0 -1
- package/dist/commands/help.js +0 -48
- package/dist/commands/help.js.map +0 -1
- package/dist/commands/refreshBuiltin.d.ts +0 -11
- package/dist/commands/refreshBuiltin.d.ts.map +0 -1
- package/dist/commands/refreshBuiltin.js +0 -37
- package/dist/commands/refreshBuiltin.js.map +0 -1
|
@@ -1,19 +1,23 @@
|
|
|
1
1
|
# Simple TAKT Workflow
|
|
2
|
-
# Plan ->
|
|
3
|
-
# (Simplified version of default - removed improve, fix, ai_fix, security_review, security_fix)
|
|
2
|
+
# Plan -> Implement -> AI Review -> Architect Review -> Supervisor Approval
|
|
4
3
|
#
|
|
5
|
-
# Template Variables:
|
|
6
|
-
# {iteration}
|
|
7
|
-
# {max_iterations}
|
|
8
|
-
# {step_iteration}
|
|
9
|
-
# {task}
|
|
10
|
-
# {previous_response}
|
|
11
|
-
# {
|
|
12
|
-
# {
|
|
13
|
-
#
|
|
4
|
+
# Template Variables (auto-injected by engine):
|
|
5
|
+
# {iteration} - Workflow-wide turn count
|
|
6
|
+
# {max_iterations} - Maximum iterations allowed
|
|
7
|
+
# {step_iteration} - Per-step iteration count
|
|
8
|
+
# {task} - Original user request
|
|
9
|
+
# {previous_response} - Output from the previous step
|
|
10
|
+
# {user_inputs} - Accumulated user inputs during workflow
|
|
11
|
+
# {report_dir} - Report directory name
|
|
12
|
+
#
|
|
13
|
+
# Auto-injected sections (do NOT include in instruction_template):
|
|
14
|
+
# ## Workflow Context - iteration, step_iteration, report info
|
|
15
|
+
# ## User Request - {task}
|
|
16
|
+
# ## Previous Response - {previous_response}
|
|
17
|
+
# ## Additional User Inputs - {user_inputs}
|
|
14
18
|
|
|
15
19
|
name: simple
|
|
16
|
-
description: Simplified development workflow (plan -> implement ->
|
|
20
|
+
description: Simplified development workflow (plan -> implement -> ai_review -> review -> supervise)
|
|
17
21
|
|
|
18
22
|
max_iterations: 20
|
|
19
23
|
|
|
@@ -21,7 +25,31 @@ initial_step: plan
|
|
|
21
25
|
|
|
22
26
|
steps:
|
|
23
27
|
- name: plan
|
|
24
|
-
|
|
28
|
+
edit: false
|
|
29
|
+
agent: ../agents/default/planner.md
|
|
30
|
+
report:
|
|
31
|
+
name: 00-plan.md
|
|
32
|
+
format: |
|
|
33
|
+
```markdown
|
|
34
|
+
# Task Plan
|
|
35
|
+
|
|
36
|
+
## Original Request
|
|
37
|
+
{User's request as-is}
|
|
38
|
+
|
|
39
|
+
## Analysis Results
|
|
40
|
+
|
|
41
|
+
### Objective
|
|
42
|
+
{What needs to be achieved}
|
|
43
|
+
|
|
44
|
+
### Scope
|
|
45
|
+
{Impact scope}
|
|
46
|
+
|
|
47
|
+
### Implementation Approach
|
|
48
|
+
{How to proceed}
|
|
49
|
+
|
|
50
|
+
## Clarifications Needed (if any)
|
|
51
|
+
- {Unclear points or items requiring confirmation}
|
|
52
|
+
```
|
|
25
53
|
allowed_tools:
|
|
26
54
|
- Read
|
|
27
55
|
- Glob
|
|
@@ -30,67 +58,20 @@ steps:
|
|
|
30
58
|
- Bash
|
|
31
59
|
- WebSearch
|
|
32
60
|
- WebFetch
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
## Output Format
|
|
43
|
-
|
|
44
|
-
| Situation | Tag |
|
|
45
|
-
|-----------|-----|
|
|
46
|
-
| Analysis complete | `[PLANNER:DONE]` |
|
|
47
|
-
| Question answered | `[PLANNER:ANSWER]` |
|
|
48
|
-
| Insufficient info | `[PLANNER:BLOCKED]` |
|
|
49
|
-
|
|
50
|
-
### Output Examples
|
|
51
|
-
|
|
52
|
-
**DONE case:**
|
|
53
|
-
```
|
|
54
|
-
[PLANNER:DONE]
|
|
55
|
-
```
|
|
56
|
-
|
|
57
|
-
**ANSWER case:**
|
|
58
|
-
```
|
|
59
|
-
{Answer to the question}
|
|
60
|
-
|
|
61
|
-
[PLANNER:ANSWER]
|
|
62
|
-
```
|
|
63
|
-
|
|
64
|
-
**BLOCKED case:**
|
|
65
|
-
```
|
|
66
|
-
[PLANNER:BLOCKED]
|
|
67
|
-
|
|
68
|
-
Clarifications needed:
|
|
69
|
-
- {Question 1}
|
|
70
|
-
- {Question 2}
|
|
71
|
-
```
|
|
61
|
+
rules:
|
|
62
|
+
- condition: Requirements are clear and implementable
|
|
63
|
+
next: implement
|
|
64
|
+
- condition: User is asking a question
|
|
65
|
+
next: COMPLETE
|
|
66
|
+
- condition: Requirements unclear, insufficient info
|
|
67
|
+
next: ABORT
|
|
68
|
+
pass_previous_response: true
|
|
72
69
|
instruction_template: |
|
|
73
|
-
## Workflow Context
|
|
74
|
-
- Iteration: {iteration}/{max_iterations} (workflow-wide)
|
|
75
|
-
- Step Iteration: {step_iteration} (times this step has run)
|
|
76
|
-
- Step: plan (Task Analysis)
|
|
77
|
-
- Report Directory: .takt/reports/{report_dir}/
|
|
78
|
-
- Report File: .takt/reports/{report_dir}/00-plan.md
|
|
79
|
-
|
|
80
|
-
## User Request
|
|
81
|
-
{task}
|
|
82
|
-
|
|
83
70
|
## Previous Response (when returned from implement)
|
|
84
71
|
{previous_response}
|
|
85
72
|
|
|
86
|
-
## Instructions
|
|
87
73
|
Analyze the task and create an implementation plan.
|
|
88
74
|
|
|
89
|
-
**Judgment criteria:**
|
|
90
|
-
- If the user input is an implementation task → create a plan and output `[PLANNER:DONE]`
|
|
91
|
-
- If the user input is a question → research, answer, and output `[PLANNER:ANSWER]`
|
|
92
|
-
- If there is insufficient information → output `[PLANNER:BLOCKED]`
|
|
93
|
-
|
|
94
75
|
**Note:** If returned from implement step (Previous Response exists),
|
|
95
76
|
review and revise the plan based on that feedback (replan).
|
|
96
77
|
|
|
@@ -99,42 +80,12 @@ steps:
|
|
|
99
80
|
2. Identify impact scope
|
|
100
81
|
3. Decide implementation approach
|
|
101
82
|
|
|
102
|
-
**Report output:** Output to the `Report File` specified above.
|
|
103
|
-
- If file does not exist: Create new file
|
|
104
|
-
- If file exists: Append with `## Iteration {step_iteration}` section
|
|
105
|
-
|
|
106
|
-
**Report format:**
|
|
107
|
-
```markdown
|
|
108
|
-
# Task Plan
|
|
109
|
-
|
|
110
|
-
## Original Request
|
|
111
|
-
{User's request as-is}
|
|
112
|
-
|
|
113
|
-
## Analysis Results
|
|
114
|
-
|
|
115
|
-
### Objective
|
|
116
|
-
{What needs to be achieved}
|
|
117
|
-
|
|
118
|
-
### Scope
|
|
119
|
-
{Impact scope}
|
|
120
|
-
|
|
121
|
-
### Implementation Approach
|
|
122
|
-
{How to proceed}
|
|
123
|
-
|
|
124
|
-
## Clarifications Needed (if any)
|
|
125
|
-
- {Unclear points or items requiring confirmation}
|
|
126
|
-
```
|
|
127
|
-
pass_previous_response: true
|
|
128
|
-
transitions:
|
|
129
|
-
- condition: done
|
|
130
|
-
next_step: implement
|
|
131
|
-
- condition: answer
|
|
132
|
-
next_step: COMPLETE
|
|
133
|
-
- condition: blocked
|
|
134
|
-
next_step: ABORT
|
|
135
|
-
|
|
136
83
|
- name: implement
|
|
137
|
-
|
|
84
|
+
edit: true
|
|
85
|
+
agent: ../agents/default/coder.md
|
|
86
|
+
report:
|
|
87
|
+
- Scope: 01-coder-scope.md
|
|
88
|
+
- Decisions: 02-coder-decisions.md
|
|
138
89
|
allowed_tools:
|
|
139
90
|
- Read
|
|
140
91
|
- Glob
|
|
@@ -145,58 +96,15 @@ steps:
|
|
|
145
96
|
- WebSearch
|
|
146
97
|
- WebFetch
|
|
147
98
|
permission_mode: acceptEdits
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
| Implementation complete | `[CODER:DONE]` |
|
|
154
|
-
| Cannot decide/insufficient info | `[CODER:BLOCKED]` |
|
|
155
|
-
|
|
156
|
-
**Important**: When in doubt, `[BLOCKED]`. Don't decide on your own.
|
|
157
|
-
|
|
158
|
-
### Output Examples
|
|
159
|
-
|
|
160
|
-
**DONE case:**
|
|
161
|
-
```
|
|
162
|
-
Implementation complete.
|
|
163
|
-
- Created: `src/auth/service.ts`, `tests/auth.test.ts`
|
|
164
|
-
- Modified: `src/routes.ts`
|
|
165
|
-
|
|
166
|
-
[CODER:DONE]
|
|
167
|
-
```
|
|
168
|
-
|
|
169
|
-
**BLOCKED case:**
|
|
170
|
-
```
|
|
171
|
-
[CODER:BLOCKED]
|
|
172
|
-
|
|
173
|
-
Reason: DB schema is undefined, cannot implement
|
|
174
|
-
Required info: users table structure
|
|
175
|
-
```
|
|
99
|
+
rules:
|
|
100
|
+
- condition: Implementation complete
|
|
101
|
+
next: ai_review
|
|
102
|
+
- condition: Cannot proceed, insufficient info
|
|
103
|
+
next: plan
|
|
176
104
|
instruction_template: |
|
|
177
|
-
## Workflow Context
|
|
178
|
-
- Iteration: {iteration}/{max_iterations} (workflow-wide)
|
|
179
|
-
- Step Iteration: {step_iteration} (times this step has run)
|
|
180
|
-
- Step: implement
|
|
181
|
-
- Report Directory: .takt/reports/{report_dir}/
|
|
182
|
-
- Report Files:
|
|
183
|
-
- Scope: .takt/reports/{report_dir}/01-coder-scope.md
|
|
184
|
-
- Decisions: .takt/reports/{report_dir}/02-coder-decisions.md
|
|
185
|
-
|
|
186
|
-
## User Request
|
|
187
|
-
{task}
|
|
188
|
-
|
|
189
|
-
## Additional User Inputs
|
|
190
|
-
{user_inputs}
|
|
191
|
-
|
|
192
|
-
## Instructions
|
|
193
105
|
Follow the plan from the plan step and implement.
|
|
194
106
|
Refer to the plan report (00-plan.md) and proceed with implementation.
|
|
195
107
|
|
|
196
|
-
**Report output:** Output to the `Report Files` specified above.
|
|
197
|
-
- If file does not exist: Create new file
|
|
198
|
-
- If file exists: Append with `## Iteration {step_iteration}` section
|
|
199
|
-
|
|
200
108
|
**Scope report format (create at implementation start):**
|
|
201
109
|
```markdown
|
|
202
110
|
# Change Scope Declaration
|
|
@@ -226,14 +134,38 @@ steps:
|
|
|
226
134
|
- **Options Considered**: {List of options}
|
|
227
135
|
- **Reason**: {Why this option was chosen}
|
|
228
136
|
```
|
|
229
|
-
transitions:
|
|
230
|
-
- condition: done
|
|
231
|
-
next_step: review
|
|
232
|
-
- condition: blocked
|
|
233
|
-
next_step: plan
|
|
234
137
|
|
|
235
|
-
- name:
|
|
236
|
-
|
|
138
|
+
- name: ai_review
|
|
139
|
+
edit: false
|
|
140
|
+
agent: ../agents/default/ai-antipattern-reviewer.md
|
|
141
|
+
report:
|
|
142
|
+
name: 03-ai-review.md
|
|
143
|
+
format: |
|
|
144
|
+
```markdown
|
|
145
|
+
# AI-Generated Code Review
|
|
146
|
+
|
|
147
|
+
## Result: APPROVE / REJECT
|
|
148
|
+
|
|
149
|
+
## Summary
|
|
150
|
+
{One sentence summarizing result}
|
|
151
|
+
|
|
152
|
+
## Verified Items
|
|
153
|
+
| Aspect | Result | Notes |
|
|
154
|
+
|--------|--------|-------|
|
|
155
|
+
| Assumption validity | ✅ | - |
|
|
156
|
+
| API/Library existence | ✅ | - |
|
|
157
|
+
| Context fit | ✅ | - |
|
|
158
|
+
| Scope | ✅ | - |
|
|
159
|
+
|
|
160
|
+
## Issues (if REJECT)
|
|
161
|
+
| # | Category | Location | Issue |
|
|
162
|
+
|---|----------|----------|-------|
|
|
163
|
+
| 1 | Hallucinated API | `src/file.ts:23` | Non-existent method |
|
|
164
|
+
```
|
|
165
|
+
|
|
166
|
+
**Cognitive load reduction rules:**
|
|
167
|
+
- No issues -> Summary 1 line + check table only (10 lines or less)
|
|
168
|
+
- Issues found -> + Issues in table format (25 lines or less)
|
|
237
169
|
allowed_tools:
|
|
238
170
|
- Read
|
|
239
171
|
- Glob
|
|
@@ -241,110 +173,50 @@ steps:
|
|
|
241
173
|
- Write
|
|
242
174
|
- WebSearch
|
|
243
175
|
- WebFetch
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
| Structural issues | REJECT |
|
|
250
|
-
| Design principle violations | REJECT |
|
|
251
|
-
| Security issues | REJECT |
|
|
252
|
-
| Insufficient tests | REJECT |
|
|
253
|
-
| No issues | APPROVE |
|
|
254
|
-
|
|
255
|
-
**Note:** In simple workflow, IMPROVE is not used.
|
|
256
|
-
If there are minor suggestions, use APPROVE + comments.
|
|
257
|
-
|
|
258
|
-
## Output Format
|
|
259
|
-
|
|
260
|
-
| Situation | Tag |
|
|
261
|
-
|-----------|-----|
|
|
262
|
-
| No issues | `[ARCHITECT:APPROVE]` |
|
|
263
|
-
| Structural changes required | `[ARCHITECT:REJECT]` |
|
|
264
|
-
|
|
265
|
-
### Output Examples
|
|
266
|
-
|
|
267
|
-
**APPROVE case:**
|
|
268
|
-
```
|
|
269
|
-
[ARCHITECT:APPROVE]
|
|
270
|
-
|
|
271
|
-
Positive points:
|
|
272
|
-
- Appropriate module organization
|
|
273
|
-
- Single responsibility maintained
|
|
274
|
-
```
|
|
275
|
-
|
|
276
|
-
**REJECT case:**
|
|
277
|
-
```
|
|
278
|
-
[ARCHITECT:REJECT]
|
|
279
|
-
|
|
280
|
-
Issues:
|
|
281
|
-
1. File size exceeded
|
|
282
|
-
- Location: `src/services/user.ts` (523 lines)
|
|
283
|
-
- Fix: Split into 3 files
|
|
284
|
-
```
|
|
176
|
+
rules:
|
|
177
|
+
- condition: No AI-specific issues
|
|
178
|
+
next: review
|
|
179
|
+
- condition: AI-specific issues found
|
|
180
|
+
next: plan
|
|
285
181
|
instruction_template: |
|
|
286
|
-
|
|
287
|
-
-
|
|
288
|
-
-
|
|
289
|
-
-
|
|
290
|
-
-
|
|
291
|
-
- Report File: .takt/reports/{report_dir}/03-architect-review.md
|
|
292
|
-
|
|
293
|
-
## Original User Request (Initial request from workflow start)
|
|
294
|
-
{task}
|
|
295
|
-
|
|
296
|
-
## Git Diff
|
|
297
|
-
```diff
|
|
298
|
-
{git_diff}
|
|
299
|
-
```
|
|
300
|
-
|
|
301
|
-
## Instructions
|
|
302
|
-
Focus on **architecture and design** review. Do NOT review AI-specific issues (that's the next step).
|
|
303
|
-
|
|
304
|
-
Review the changes and provide feedback.
|
|
305
|
-
|
|
306
|
-
**Note:** In simple workflow, IMPROVE judgment is not used.
|
|
307
|
-
If there are minor suggestions, use APPROVE + comments.
|
|
308
|
-
|
|
309
|
-
**Report output:** Output to the `Report File` specified above.
|
|
310
|
-
- If file does not exist: Create new file
|
|
311
|
-
- If file exists: Append with `## Iteration {step_iteration}` section
|
|
312
|
-
|
|
313
|
-
**Report format:**
|
|
314
|
-
```markdown
|
|
315
|
-
# Architecture Review
|
|
316
|
-
|
|
317
|
-
## Result: APPROVE / REJECT
|
|
318
|
-
|
|
319
|
-
## Summary
|
|
320
|
-
{1-2 sentences summarizing result}
|
|
321
|
-
|
|
322
|
-
## Reviewed Perspectives
|
|
323
|
-
- [x] Structure & Design
|
|
324
|
-
- [x] Code Quality
|
|
325
|
-
- [x] Change Scope
|
|
326
|
-
|
|
327
|
-
## Issues (if REJECT)
|
|
328
|
-
| # | Location | Issue | Fix |
|
|
329
|
-
|---|----------|-------|-----|
|
|
330
|
-
| 1 | `src/file.ts:42` | Issue description | Fix method |
|
|
331
|
-
|
|
332
|
-
## Improvement Suggestions (optional, non-blocking)
|
|
333
|
-
- {Future improvement suggestions}
|
|
334
|
-
```
|
|
335
|
-
|
|
336
|
-
**Cognitive load reduction rules:**
|
|
337
|
-
- APPROVE + no issues → Summary only (5 lines or less)
|
|
338
|
-
- APPROVE + minor suggestions → Summary + suggestions (15 lines or less)
|
|
339
|
-
- REJECT → Issues in table format (30 lines or less)
|
|
340
|
-
transitions:
|
|
341
|
-
- condition: approved
|
|
342
|
-
next_step: ai_review
|
|
343
|
-
- condition: rejected
|
|
344
|
-
next_step: plan
|
|
182
|
+
Review the code for AI-specific issues:
|
|
183
|
+
- Assumption validation
|
|
184
|
+
- Plausible but wrong patterns
|
|
185
|
+
- Context fit with existing codebase
|
|
186
|
+
- Scope creep detection
|
|
345
187
|
|
|
346
|
-
- name:
|
|
347
|
-
|
|
188
|
+
- name: review
|
|
189
|
+
edit: false
|
|
190
|
+
agent: ../agents/default/architecture-reviewer.md
|
|
191
|
+
report:
|
|
192
|
+
name: 04-architect-review.md
|
|
193
|
+
format: |
|
|
194
|
+
```markdown
|
|
195
|
+
# Architecture Review
|
|
196
|
+
|
|
197
|
+
## Result: APPROVE / REJECT
|
|
198
|
+
|
|
199
|
+
## Summary
|
|
200
|
+
{1-2 sentences summarizing result}
|
|
201
|
+
|
|
202
|
+
## Reviewed Perspectives
|
|
203
|
+
- [x] Structure & Design
|
|
204
|
+
- [x] Code Quality
|
|
205
|
+
- [x] Change Scope
|
|
206
|
+
|
|
207
|
+
## Issues (if REJECT)
|
|
208
|
+
| # | Location | Issue | Fix |
|
|
209
|
+
|---|----------|-------|-----|
|
|
210
|
+
| 1 | `src/file.ts:42` | Issue description | Fix method |
|
|
211
|
+
|
|
212
|
+
## Improvement Suggestions (optional, non-blocking)
|
|
213
|
+
- {Future improvement suggestions}
|
|
214
|
+
```
|
|
215
|
+
|
|
216
|
+
**Cognitive load reduction rules:**
|
|
217
|
+
- APPROVE + no issues -> Summary only (5 lines or less)
|
|
218
|
+
- APPROVE + minor suggestions -> Summary + suggestions (15 lines or less)
|
|
219
|
+
- REJECT -> Issues in table format (30 lines or less)
|
|
348
220
|
allowed_tools:
|
|
349
221
|
- Read
|
|
350
222
|
- Glob
|
|
@@ -352,104 +224,25 @@ steps:
|
|
|
352
224
|
- Write
|
|
353
225
|
- WebSearch
|
|
354
226
|
- WebFetch
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
| Incorrect assumptions (affecting behavior) | REJECT |
|
|
361
|
-
| Plausible-but-wrong code | REJECT |
|
|
362
|
-
| Significant context mismatch with codebase | REJECT |
|
|
363
|
-
| Scope creep | APPROVE (with warning noted) |
|
|
364
|
-
| Minor style deviations only | APPROVE |
|
|
365
|
-
| Code fits context and works | APPROVE |
|
|
366
|
-
|
|
367
|
-
**Note:** Scope creep is noted as a warning but doesn't warrant REJECT alone.
|
|
368
|
-
|
|
369
|
-
## Output Format
|
|
370
|
-
|
|
371
|
-
| Situation | Tag |
|
|
372
|
-
|-----------|-----|
|
|
373
|
-
| No AI-specific issues | `[AI_REVIEW:APPROVE]` |
|
|
374
|
-
| Issues found | `[AI_REVIEW:REJECT]` |
|
|
375
|
-
|
|
376
|
-
### Output Examples
|
|
377
|
-
|
|
378
|
-
**APPROVE case:**
|
|
379
|
-
```
|
|
380
|
-
[AI_REVIEW:APPROVE]
|
|
381
|
-
|
|
382
|
-
Verification result: No issues
|
|
383
|
-
```
|
|
384
|
-
|
|
385
|
-
**REJECT case:**
|
|
386
|
-
```
|
|
387
|
-
[AI_REVIEW:REJECT]
|
|
388
|
-
|
|
389
|
-
Issues:
|
|
390
|
-
1. Non-existent API used: `fetch.json()` → `response.json()`
|
|
391
|
-
```
|
|
227
|
+
rules:
|
|
228
|
+
- condition: No issues found
|
|
229
|
+
next: supervise
|
|
230
|
+
- condition: Structural fix required
|
|
231
|
+
next: plan
|
|
392
232
|
instruction_template: |
|
|
393
|
-
|
|
394
|
-
- Iteration: {iteration}/{max_iterations} (workflow-wide)
|
|
395
|
-
- Step Iteration: {step_iteration} (times this step has run)
|
|
396
|
-
- Step: ai_review (AI-Generated Code Review)
|
|
397
|
-
- Report Directory: .takt/reports/{report_dir}/
|
|
398
|
-
- Report File: .takt/reports/{report_dir}/04-ai-review.md
|
|
399
|
-
|
|
400
|
-
## Original User Request (Initial request from workflow start)
|
|
401
|
-
{task}
|
|
402
|
-
|
|
403
|
-
## Git Diff
|
|
404
|
-
```diff
|
|
405
|
-
{git_diff}
|
|
406
|
-
```
|
|
233
|
+
Focus on **architecture and design** review. Do NOT review AI-specific issues (that's already done).
|
|
407
234
|
|
|
408
|
-
|
|
409
|
-
Review the code for AI-specific issues:
|
|
410
|
-
- Assumption validation
|
|
411
|
-
- Plausible but wrong patterns
|
|
412
|
-
- Context fit with existing codebase
|
|
413
|
-
- Scope creep detection
|
|
414
|
-
|
|
415
|
-
**Report output:** Output to the `Report File` specified above.
|
|
416
|
-
- If file does not exist: Create new file
|
|
417
|
-
- If file exists: Append with `## Iteration {step_iteration}` section
|
|
418
|
-
|
|
419
|
-
**Report format:**
|
|
420
|
-
```markdown
|
|
421
|
-
# AI-Generated Code Review
|
|
422
|
-
|
|
423
|
-
## Result: APPROVE / REJECT
|
|
424
|
-
|
|
425
|
-
## Summary
|
|
426
|
-
{One sentence summarizing result}
|
|
427
|
-
|
|
428
|
-
## Verified Items
|
|
429
|
-
| Aspect | Result | Notes |
|
|
430
|
-
|--------|--------|-------|
|
|
431
|
-
| Assumption validity | ✅ | - |
|
|
432
|
-
| API/Library existence | ✅ | - |
|
|
433
|
-
| Context fit | ✅ | - |
|
|
434
|
-
| Scope | ✅ | - |
|
|
435
|
-
|
|
436
|
-
## Issues (if REJECT)
|
|
437
|
-
| # | Category | Location | Issue |
|
|
438
|
-
|---|----------|----------|-------|
|
|
439
|
-
| 1 | Hallucinated API | `src/file.ts:23` | Non-existent method |
|
|
440
|
-
```
|
|
235
|
+
Review the changes and provide feedback.
|
|
441
236
|
|
|
442
|
-
**
|
|
443
|
-
|
|
444
|
-
- Issues found → + Issues in table format (25 lines or less)
|
|
445
|
-
transitions:
|
|
446
|
-
- condition: approved
|
|
447
|
-
next_step: supervise
|
|
448
|
-
- condition: rejected
|
|
449
|
-
next_step: plan
|
|
237
|
+
**Note:** In simple workflow, IMPROVE judgment is not used.
|
|
238
|
+
If there are minor suggestions, use APPROVE + comments.
|
|
450
239
|
|
|
451
240
|
- name: supervise
|
|
452
|
-
|
|
241
|
+
edit: false
|
|
242
|
+
agent: ../agents/default/supervisor.md
|
|
243
|
+
report:
|
|
244
|
+
- Validation: 05-supervisor-validation.md
|
|
245
|
+
- Summary: summary.md
|
|
453
246
|
allowed_tools:
|
|
454
247
|
- Read
|
|
455
248
|
- Glob
|
|
@@ -458,65 +251,12 @@ steps:
|
|
|
458
251
|
- Bash
|
|
459
252
|
- WebSearch
|
|
460
253
|
- WebFetch
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
| Requirements not met | REJECT |
|
|
467
|
-
| Tests failing | REJECT |
|
|
468
|
-
| Build fails | REJECT |
|
|
469
|
-
| Workarounds remaining | REJECT |
|
|
470
|
-
| All OK | APPROVE |
|
|
471
|
-
|
|
472
|
-
**Principle**: When in doubt, REJECT. Don't give ambiguous approval.
|
|
473
|
-
|
|
474
|
-
## Output Format
|
|
475
|
-
|
|
476
|
-
| Situation | Tag |
|
|
477
|
-
|-----------|-----|
|
|
478
|
-
| Final approval | `[SUPERVISOR:APPROVE]` |
|
|
479
|
-
| Return for fixes | `[SUPERVISOR:REJECT]` |
|
|
480
|
-
|
|
481
|
-
### Output Examples
|
|
482
|
-
|
|
483
|
-
**APPROVE case:**
|
|
484
|
-
```
|
|
485
|
-
[SUPERVISOR:APPROVE]
|
|
486
|
-
|
|
487
|
-
Verification results:
|
|
488
|
-
- Tests: ✅ All passed
|
|
489
|
-
- Build: ✅ Succeeded
|
|
490
|
-
- Requirements met: ✅
|
|
491
|
-
```
|
|
492
|
-
|
|
493
|
-
**REJECT case:**
|
|
494
|
-
```
|
|
495
|
-
[SUPERVISOR:REJECT]
|
|
496
|
-
|
|
497
|
-
Issues:
|
|
498
|
-
1. Tests failing: `npm test` - 2 failures
|
|
499
|
-
2. Requirements not met: Login feature not implemented
|
|
500
|
-
```
|
|
254
|
+
rules:
|
|
255
|
+
- condition: All checks passed
|
|
256
|
+
next: COMPLETE
|
|
257
|
+
- condition: Requirements unmet, tests failing
|
|
258
|
+
next: plan
|
|
501
259
|
instruction_template: |
|
|
502
|
-
## Workflow Context
|
|
503
|
-
- Iteration: {iteration}/{max_iterations} (workflow-wide)
|
|
504
|
-
- Step Iteration: {step_iteration} (times this step has run)
|
|
505
|
-
- Step: supervise (final verification)
|
|
506
|
-
- Report Directory: .takt/reports/{report_dir}/
|
|
507
|
-
- Report Files:
|
|
508
|
-
- Validation: .takt/reports/{report_dir}/05-supervisor-validation.md
|
|
509
|
-
- Summary: .takt/reports/{report_dir}/summary.md
|
|
510
|
-
|
|
511
|
-
## Original User Request
|
|
512
|
-
{task}
|
|
513
|
-
|
|
514
|
-
## Git Diff
|
|
515
|
-
```diff
|
|
516
|
-
{git_diff}
|
|
517
|
-
```
|
|
518
|
-
|
|
519
|
-
## Instructions
|
|
520
260
|
Run tests, verify the build, and perform final approval.
|
|
521
261
|
|
|
522
262
|
**Workflow Overall Review:**
|
|
@@ -527,10 +267,6 @@ steps:
|
|
|
527
267
|
**Review Reports:** Read all reports in Report Directory and
|
|
528
268
|
check for any unaddressed improvement suggestions.
|
|
529
269
|
|
|
530
|
-
**Report output:** Output to the `Report Files` specified above.
|
|
531
|
-
- If file does not exist: Create new file
|
|
532
|
-
- If file exists: Append with `## Iteration {step_iteration}` section
|
|
533
|
-
|
|
534
270
|
**Validation report format:**
|
|
535
271
|
```markdown
|
|
536
272
|
# Final Validation Results
|
|
@@ -573,8 +309,8 @@ steps:
|
|
|
573
309
|
## Review Results
|
|
574
310
|
| Review | Result |
|
|
575
311
|
|--------|--------|
|
|
576
|
-
| Architect | ✅ APPROVE |
|
|
577
312
|
| AI Review | ✅ APPROVE |
|
|
313
|
+
| Architect | ✅ APPROVE |
|
|
578
314
|
| Supervisor | ✅ APPROVE |
|
|
579
315
|
|
|
580
316
|
## Verification Commands
|
|
@@ -583,8 +319,3 @@ steps:
|
|
|
583
319
|
npm run build
|
|
584
320
|
```
|
|
585
321
|
```
|
|
586
|
-
transitions:
|
|
587
|
-
- condition: approved
|
|
588
|
-
next_step: COMPLETE
|
|
589
|
-
- condition: rejected
|
|
590
|
-
next_step: plan
|