create-ai-project 1.20.4 → 1.20.6

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 (56) hide show
  1. package/.claude/agents-en/acceptance-test-generator.md +70 -25
  2. package/.claude/agents-en/code-verifier.md +4 -2
  3. package/.claude/agents-en/design-sync.md +145 -54
  4. package/.claude/agents-en/investigator.md +92 -39
  5. package/.claude/agents-en/quality-fixer-frontend.md +67 -12
  6. package/.claude/agents-en/quality-fixer.md +67 -12
  7. package/.claude/agents-en/solver.md +30 -27
  8. package/.claude/agents-en/technical-designer-frontend.md +18 -0
  9. package/.claude/agents-en/technical-designer.md +18 -0
  10. package/.claude/agents-en/verifier.md +100 -74
  11. package/.claude/agents-en/work-planner.md +40 -3
  12. package/.claude/agents-ja/acceptance-test-generator.md +70 -25
  13. package/.claude/agents-ja/code-verifier.md +4 -2
  14. package/.claude/agents-ja/design-sync.md +145 -54
  15. package/.claude/agents-ja/investigator.md +93 -40
  16. package/.claude/agents-ja/quality-fixer-frontend.md +71 -16
  17. package/.claude/agents-ja/quality-fixer.md +71 -16
  18. package/.claude/agents-ja/solver.md +32 -29
  19. package/.claude/agents-ja/technical-designer-frontend.md +18 -0
  20. package/.claude/agents-ja/technical-designer.md +18 -0
  21. package/.claude/agents-ja/verifier.md +100 -74
  22. package/.claude/agents-ja/work-planner.md +40 -3
  23. package/.claude/commands-en/add-integration-tests.md +7 -2
  24. package/.claude/commands-en/build.md +6 -2
  25. package/.claude/commands-en/diagnose.md +46 -34
  26. package/.claude/commands-en/front-build.md +6 -2
  27. package/.claude/commands-en/front-plan.md +8 -2
  28. package/.claude/commands-en/implement.md +8 -4
  29. package/.claude/commands-en/plan.md +4 -1
  30. package/.claude/commands-en/update-doc.md +3 -0
  31. package/.claude/commands-ja/add-integration-tests.md +7 -2
  32. package/.claude/commands-ja/build.md +6 -2
  33. package/.claude/commands-ja/diagnose.md +46 -34
  34. package/.claude/commands-ja/front-build.md +8 -4
  35. package/.claude/commands-ja/front-plan.md +8 -2
  36. package/.claude/commands-ja/implement.md +8 -4
  37. package/.claude/commands-ja/plan.md +4 -1
  38. package/.claude/commands-ja/update-doc.md +3 -0
  39. package/.claude/skills-en/documentation-criteria/SKILL.md +2 -1
  40. package/.claude/skills-en/documentation-criteria/references/design-template.md +10 -4
  41. package/.claude/skills-en/documentation-criteria/references/plan-template.md +13 -0
  42. package/.claude/skills-en/documentation-criteria/references/prd-template.md +4 -3
  43. package/.claude/skills-en/documentation-criteria/references/ui-spec-template.md +60 -6
  44. package/.claude/skills-en/integration-e2e-testing/SKILL.md +46 -5
  45. package/.claude/skills-en/subagents-orchestration-guide/SKILL.md +16 -8
  46. package/.claude/skills-ja/documentation-criteria/SKILL.md +2 -1
  47. package/.claude/skills-ja/documentation-criteria/references/design-template.md +10 -4
  48. package/.claude/skills-ja/documentation-criteria/references/plan-template.md +13 -0
  49. package/.claude/skills-ja/documentation-criteria/references/prd-template.md +4 -3
  50. package/.claude/skills-ja/documentation-criteria/references/ui-spec-template.md +61 -7
  51. package/.claude/skills-ja/integration-e2e-testing/SKILL.md +45 -5
  52. package/.claude/skills-ja/subagents-orchestration-guide/SKILL.md +16 -8
  53. package/CHANGELOG.md +44 -0
  54. package/README.ja.md +3 -3
  55. package/README.md +3 -3
  56. package/package.json +1 -1
@@ -43,12 +43,46 @@ Design Doc、UI Spec、PRD、ADR(提供されている場合)を読み込み
43
43
  - テストスケルトンが提供されていない場合、Design Docの受入条件に基づくテスト実装タスクを含める
44
44
  - 最終フェーズは常に品質保証
45
45
 
46
+ **E2Eギャップチェック(全戦略共通)**:
47
+ 利用可能なテストスケルトンを確認した後、E2Eスケルトンが不在かチェックする。マルチステップユーザージャーニーは以下の条件をすべて満たす場合に存在する: (1) 2つ以上の異なるインタラクション境界が順番に通過される、(2) ステップ間で状態が伝搬する、(3) ジャーニーに完了ポイントがある。**ユーザー向け**ジャーニーとは、人間のユーザーが直接ステップをトリガーし結果を観察するもの(UI、CLI、直接的なAPIインタラクション経由)であり、サービス内部パイプラインは含まない。
48
+
49
+ ```
50
+ IF E2Eテストスケルトンファイルが提供されていない
51
+ AND 上流からe2eAbsenceReasonが伝達されていない
52
+ AND Design DocまたはUI Specにユーザー向けマルチステップジャーニーが含まれる
53
+ THEN 作業計画書ヘッダーに追記:
54
+ ⚠ E2E Gap: この機能にはユーザー向けマルチステップジャーニーが含まれますが、
55
+ E2Eテストスケルトンが提供されていません。最終フェーズ前に
56
+ acceptance-test-generatorでE2Eテスト候補を評価することを検討してください。
57
+ 検出されたジャーニー: [ジャーニーの説明とAC参照のリスト]
58
+ ```
59
+
60
+ `e2eAbsenceReason`が提供されている場合(acceptance-test-generatorのGeneration Reportで生成される。例: `no_multi_step_journey`, `below_threshold_user_confirmed`)、E2E不在は意図的 — このギャップチェックをスキップする。
61
+
62
+ このチェックは戦略AまたはBのどちらが選択されていても適用される。統合テストスケルトンのみの提供はE2Eカバレッジを意味しない。サービス内部ジャーニー(非同期パイプライン、サービス間saga)はここではフラグしない — 通常のROIパスでE2Eが必要な場合はそちらで対応。
63
+
46
64
  **フェーズ構成**: Design Docの実装アプローチに基づいて選択。詳細はdocumentation-criteriaスキルのフェーズ分割基準を参照。plan-templateのOption A(垂直)またはOption B(水平)に従う。ハイブリッドの場合はOption Aをベースに、必要に応じて水平基盤フェーズを追加する。
47
65
 
48
- ### 5. 完了条件付きタスクの定義
66
+ ### 5. DD技術要件のタスクへのマッピング
67
+
68
+ 提供されたDesign Docをセクションごとにスキャンする。以下のカテゴリテーブルをチェックリストとして、該当する項目を抽出する:
69
+
70
+ | カテゴリ | 抽出対象 |
71
+ |---|---|
72
+ | impl-target | 作成・変更が必要なコンポーネント、関数、データ構造 |
73
+ | connection-switching | 統合ポイント、依存関係の配線、切替方式 |
74
+ | contract-change | インターフェース変更、データコントラクト変更、境界を越えるフィールドの伝搬 |
75
+ | verification | 検証手法、テスト境界、統合検証ポイント、統合ポイント一覧の検証方式列 |
76
+ | prerequisite | マイグレーション手順、セキュリティ対策、環境セットアップ |
77
+
78
+ 抽出した各項目をカバーするタスクにマッピングする。専用タスクでカバーしても、より包括的なタスクに内包してもよいが、マッピングは必ず明示すること。マッピング結果は計画テンプレートの設計-計画トレーサビリティ表に、上記左列のカテゴリ値を使用して記録する。
79
+
80
+ カバーするタスクがない項目はギャップステータスを`gap`とし、備考に理由を記載する。**トレーサビリティ表に`gap`が1件でも含まれる場合、計画書はドラフト状態とする。** ドラフトとして出力するが、ユーザーが各ギャップを確認するまで確定しない。理由なしのギャップ(備考が空)はエラーとして扱い、カバーするタスクを追加するか理由を記載してから進める。
81
+
82
+ ### 6. 完了条件付きタスクの定義
49
83
  各タスクについて、Design Docの受入条件から完了条件を導出。3要素の完了定義(実装完了、品質完了、統合完了)を適用。
50
84
 
51
- ### 6. 作業計画書の作成
85
+ ### 7. 作業計画書の作成
52
86
  documentation-criteriaスキルの計画テンプレートに従って作業計画書を記述。フェーズ構成図とタスク依存関係図(mermaid)を含める。
53
87
 
54
88
  ## Input Parameters
@@ -72,7 +106,7 @@ documentation-criteriaスキルの計画テンプレートに従って作業計
72
106
  2. **更新**: 各フェーズ完了時に進捗更新(チェックボックス)
73
107
  3. **削除**: 全タスク完了後、ユーザー承認を得て削除
74
108
  ## 出力方針
75
- ファイル出力は即座に実行(実行時点で承認済み)。
109
+ ファイル出力は即座に実行(実行時点で承認済み)。**例外**: トレーサビリティ表に`gap`が含まれる場合は、計画書をドラフトとして出力し、各ギャップについてユーザー確認を得てから確定する。
76
110
 
77
111
  ## タスク設計の重要原則
78
112
 
@@ -220,6 +254,9 @@ Design Docの技術的依存関係と実装アプローチに基づいてフェ
220
254
  ## 品質チェックリスト
221
255
 
222
256
  - [ ] Design Doc(複数時は各Doc)の整合性確認
257
+ - [ ] 設計-計画トレーサビリティ表の完成(DDの全技術要件がカテゴリ分類・マッピング済み)
258
+ - [ ] 理由なしの`gap`がないこと
259
+ - [ ] 理由ありの`gap`は計画承認前にユーザー確認を実施
223
260
  - [ ] Design Docから検証戦略を抽出し計画書ヘッダーに記載
224
261
  - [ ] フェーズ構成が実装アプローチと整合(垂直 → 価値単位フェーズ、水平 → レイヤーフェーズ)
225
262
  - [ ] 早期検証ポイントをPhase 1に配置(検証戦略で指定されている場合)
@@ -145,9 +145,14 @@ Invoke quality-fixer routed by task filename pattern:
145
145
  - `description`: "Final quality assurance"
146
146
  - `prompt`: "Final quality assurance for test files added in this workflow. Run all tests and verify coverage."
147
147
 
148
- **Expected output**: `approved` (true/false)
148
+ **Expected output**: `status` (approved/stub_detected/blocked)
149
+
150
+ Check quality-fixer response:
151
+ - `stub_detected` → Return to Step 4 with `incompleteImplementations[]` details, then re-execute Steps 4→5→6→7
152
+ - `blocked` → Escalate to user
153
+ - `approved` → Proceed to Step 8
149
154
 
150
155
  ### Step 8: Commit
151
156
 
152
- On `approved: true` from quality-fixer:
157
+ On `approved` from quality-fixer:
153
158
  - Commit test files with appropriate message using Bash
@@ -85,9 +85,13 @@ For EACH task, YOU MUST:
85
85
  - `approved` → Proceed to step 4
86
86
  - `readyForQualityCheck: true` → Proceed to step 4
87
87
  4. **INVOKE quality-fixer**: Execute all quality checks and fixes (cross-layer: see Layer-Aware Agent Routing)
88
- 5. **COMMIT on approval**: After `approved: true` from quality-fixer → Execute git commit
88
+ 5. **CHECK quality-fixer response**:
89
+ - `stub_detected` → Return to step 2 with `incompleteImplementations[]` details
90
+ - `blocked` → STOP and escalate to user
91
+ - `approved` → Proceed to step 6
92
+ 6. **COMMIT on approval**: Execute git commit
89
93
 
90
- **CRITICAL**: Monitor ALL structured responses WITHOUT EXCEPTION and ENSURE every quality gate is passed.
94
+ **CRITICAL**: Parse every sub-agent response for status fields. Execute the matching branch in the 4-step cycle. Proceed to next task only after quality-fixer returns `approved`.
91
95
 
92
96
  ## Sub-agent Invocation Constraints
93
97
 
@@ -2,7 +2,7 @@
2
2
  description: Investigate problem, verify findings, and derive solutions
3
3
  ---
4
4
 
5
- **Command Context**: Diagnosis flow to identify root cause and present solutions
5
+ **Command Context**: Diagnosis flow to identify failure points and present solutions
6
6
 
7
7
  Target problem: $ARGUMENTS
8
8
 
@@ -64,10 +64,10 @@ Confirm from rule-advisor output:
64
64
  ```
65
65
  Problem → investigator → verifier → solver ─┐
66
66
  ↑ │
67
- └── confidence < high ─────┘
67
+ └── coverage insufficient ─┘
68
68
  (max 2 iterations)
69
69
 
70
- confidence=high reached → Report
70
+ coverage sufficient → Report
71
71
  ```
72
72
 
73
73
  **Context Separation**: Pass only structured JSON output to each step. Each step starts fresh with the JSON data only.
@@ -94,19 +94,20 @@ Invoke investigator using Agent tool:
94
94
  Affected area: [What broke]
95
95
  Shared components: [Commonalities between cause and effect]
96
96
 
97
- **Expected output**: Evidence matrix, comparison analysis results, causal tracking results, list of unexplored areas, investigation limitations
97
+ **Expected output**: pathMap (execution paths per symptom), failurePoints (faults found at each node), impactAnalysis per failure point, unexplored areas, investigation limitations
98
98
 
99
99
  ### Step 2: Investigation Quality Check
100
100
 
101
101
  Review investigation output:
102
102
 
103
103
  **Quality Check** (verify JSON output contains the following):
104
- - [ ] `comparisonAnalysis` is present and `normalImplementation` is not null (comparison target found) OR explicitly recorded as "no working implementation found"
105
- - [ ] `causalChain` for each hypothesis reaches a stop condition (code change / design decision / external constraint)
106
- - [ ] `causeCategory` for each hypothesis is one of: typo / logic_error / missing_constraint / design_gap / external_factor
104
+ - [ ] `pathMap` exists with at least one symptom, and each symptom has at least one path with nodes listed
105
+ - [ ] Each failure point has: `location`, `upstreamDependency`, `symptomExplained`, `causalChain` (reaching a stop condition), `checkStatus`, `evidence` with a `source` citing a specific file or location
106
+ - [ ] Each failure point has `comparisonAnalysis` (normalImplementation found or explicitly null)
107
+ - [ ] `causeCategory` for each failure point is one of: typo / logic_error / missing_constraint / design_gap / external_factor
107
108
  - [ ] `investigationSources` covers at least 3 distinct source types (code, history, dependency, config, document, external)
108
109
  - [ ] Investigation covers `investigationFocus` items (when provided in Step 0.4)
109
- - [ ] Each hypothesis has at least 1 entry in `supportingEvidence` with a `source` field citing a specific file or location
110
+ - [ ] All nodes on mapped paths have been checked (no path was abandoned after finding the first fault)
110
111
 
111
112
  **If quality insufficient**: Re-run investigator specifying missing items explicitly:
112
113
  - `prompt`: |
@@ -135,48 +136,59 @@ Invoke verifier using Agent tool:
135
136
  - `description`: "Verify investigation results"
136
137
  - `prompt`: "Verify the following investigation results. Investigation results: [Investigation JSON output]"
137
138
 
138
- **Expected output**: Alternative hypotheses (at least 3), Devil's Advocate evaluation, final conclusion, confidence
139
+ **Expected output**: Coverage check (missing paths, unchecked nodes), Devil's Advocate evaluation per failure point, failure point evaluation with finalStatus, coverage assessment
139
140
 
140
- **Confidence Criteria**:
141
- - **high**: No uncertainty affecting solution selection or implementation
142
- - **medium**: Uncertainty exists but resolvable with additional investigation
143
- - **low**: Fundamental information gap exists
141
+ **Coverage Criteria**:
142
+ - **sufficient**: Main paths traced, all critical nodes checked, each failure point individually evaluated
143
+ - **partial**: Main paths traced, some nodes unchecked or some failure points at blocked/not_reached
144
+ - **insufficient**: Significant paths untraced, or critical nodes not investigated
144
145
 
145
- ### Step 4: Solution Derivation (solver)
146
+ ### Step 4: Coverage Gate
147
+
148
+ Check verifier's `coverageAssessment`:
149
+
150
+ - **sufficient** → Proceed to Step 5 (solver)
151
+ - **partial or insufficient** → Return to Step 1 with unchecked areas identified by verifier as investigation targets
152
+ - Maximum 2 additional investigation iterations
153
+ - After 2 iterations without reaching sufficient, present user with options:
154
+ - Continue additional investigation
155
+ - Proceed to solver at current coverage level (user accepts risk of incomplete diagnosis)
156
+
157
+ ### Step 5: Solution Derivation (solver)
158
+
159
+ **Prerequisite**: coverageAssessment=sufficient (or explicit user approval to proceed with partial/insufficient)
146
160
 
147
161
  Invoke solver using Agent tool:
148
162
  - `subagent_type`: "solver"
149
163
  - `description`: "Derive solutions"
150
- - `prompt`: "Derive solutions based on the following verified conclusion. Causes: [verifier's conclusion.causes]. Causes relationship: [causesRelationship: independent/dependent/exclusive]. Confidence: [high/medium/low]"
151
-
152
- **Expected output**: Multiple solutions (at least 3), tradeoff analysis, recommendation and implementation steps, residual risks
164
+ - `prompt`: |
165
+ Derive solutions based on the following verified failure points.
153
166
 
154
- **Completion condition**: confidence=high
167
+ Confirmed failure points: [verifier's conclusion.confirmedFailurePoints]
168
+ Refuted failure points: [verifier's conclusion.refutedFailurePoints]
169
+ Failure point relationships: [verifier's conclusion.failurePointRelationships]
170
+ Impact analysis: [investigator's impactAnalysis]
171
+ Coverage assessment: [sufficient/partial/insufficient]
155
172
 
156
- **When not reached**:
157
- 1. Return to Step 1 with uncertainties identified by solver as investigation targets
158
- 2. Maximum 2 additional investigation iterations
159
- 3. After 2 iterations without reaching high, present user with options:
160
- - Continue additional investigation
161
- - Execute solution at current confidence level
173
+ **Expected output**: Multiple solutions (at least 3), tradeoff analysis, recommendation and implementation steps, residual risks
162
174
 
163
- ### Step 5: Final Report Creation
175
+ ### Step 6: Final Report Creation
164
176
 
165
- **Prerequisite**: confidence=high achieved
177
+ **Prerequisite**: solver completed (Step 5)
166
178
 
167
179
  After diagnosis completion, report to user in the following format:
168
180
 
169
181
  ```
170
182
  ## Diagnosis Result Summary
171
183
 
172
- ### Identified Causes
173
- [Cause list from verification results]
174
- - Causes relationship: [independent/dependent/exclusive]
184
+ ### Identified Failure Points
185
+ [Confirmed failure points from verification results]
186
+ - Per failure point: location, symptom explained, finalStatus
175
187
 
176
188
  ### Verification Process
177
- - Investigation scope: [Scope confirmed in investigation]
189
+ - Path coverage: [Paths traced and nodes checked]
178
190
  - Additional investigation iterations: [0/1/2]
179
- - Alternative hypotheses count: [Number generated in verification]
191
+ - Coverage assessment: [sufficient/partial/insufficient]
180
192
 
181
193
  ### Recommended Solution
182
194
  [Solution derivation recommendation]
@@ -201,9 +213,9 @@ Rationale: [Selection rationale]
201
213
 
202
214
  ## Completion Criteria
203
215
 
204
- - [ ] Executed investigator and obtained evidence matrix, comparison analysis, and causal tracking
216
+ - [ ] Executed investigator and obtained pathMap, failurePoints, and impactAnalysis
205
217
  - [ ] Performed investigation quality check and re-ran if insufficient
206
- - [ ] Executed verifier and obtained confidence level
218
+ - [ ] Executed verifier and obtained coverage assessment
207
219
  - [ ] Executed solver
208
- - [ ] Achieved confidence=high (or obtained user approval after 2 additional iterations)
220
+ - [ ] Achieved coverageAssessment=sufficient (or obtained user approval after 2 additional iterations)
209
221
  - [ ] Presented final report to user
@@ -85,9 +85,13 @@ For EACH task, YOU MUST:
85
85
  - `approved` → Proceed to step 4
86
86
  - `readyForQualityCheck: true` → Proceed to step 4
87
87
  4. **INVOKE quality-fixer-frontend**: Execute all quality checks and fixes
88
- 5. **COMMIT on approval**: After `approved: true` from quality-fixer-frontend → Execute git commit
88
+ 5. **CHECK quality-fixer-frontend response**:
89
+ - `stub_detected` → Return to step 2 with `incompleteImplementations[]` details
90
+ - `blocked` → STOP and escalate to user
91
+ - `approved` → Proceed to step 6
92
+ 6. **COMMIT on approval**: Execute git commit
89
93
 
90
- **CRITICAL**: Parse every sub-agent response for status fields. Execute the matching branch in the 4-step cycle. Proceed to next task only after quality-fixer-frontend returns `approved: true`.
94
+ **CRITICAL**: Parse every sub-agent response for status fields. Execute the matching branch in the 4-step cycle. Proceed to next task only after quality-fixer-frontend returns `approved`.
91
95
 
92
96
  ## Sub-agent Invocation Constraints
93
97
 
@@ -43,13 +43,19 @@ Invoke acceptance-test-generator using Agent tool:
43
43
  - If UI Spec exists: `prompt: "Generate test skeletons from Design Doc at [path]. UI Spec at [ui-spec path]."`
44
44
  - If no UI Spec: `prompt: "Generate test skeletons from Design Doc at [path]."`
45
45
 
46
- Pass integration test file path and E2E test file path to work-planner according to subagents-orchestration-guide "acceptance-test-generator → work-planner" section.
46
+ Pass integration test file path, E2E test file path (or null), and e2eAbsenceReason to work-planner according to subagents-orchestration-guide "acceptance-test-generator → work-planner" section.
47
47
 
48
48
  ### Step 3: Work Plan Creation
49
49
  Invoke work-planner using Agent tool:
50
50
  - `subagent_type`: "work-planner"
51
51
  - `description`: "Work plan creation"
52
- - `prompt`: "Create work plan from Design Doc at [path]. Integration test file: [integration test path from step 2]. E2E test file: [E2E test path from step 2]. Integration tests are created simultaneously with each phase implementation, E2E tests are executed only in final phase."
52
+ - If test skeletons were generated in Step 2:
53
+ - When `generatedFiles.e2e` is not null:
54
+ `prompt`: "Create work plan from Design Doc at [path]. Integration test file: [integration test path]. E2E test file: [E2E test path]. Integration tests are created simultaneously with each phase implementation, E2E tests are executed only in final phase."
55
+ - When `generatedFiles.e2e` is null:
56
+ `prompt`: "Create work plan from Design Doc at [path]. Integration test file: [integration test path]. No E2E test skeletons were generated (reason: [e2eAbsenceReason]). Integration tests are created simultaneously with each phase implementation."
57
+ - If test skeletons were not generated:
58
+ `prompt`: "Create work plan from Design Doc at [path]."
53
59
 
54
60
  - Follow subagents-orchestration-guide Prompt Construction Rule for additional prompt parameters
55
61
  - Present work plan to user for review. If user requests changes, re-invoke work-planner with revised parameters
@@ -77,7 +77,10 @@ Following "Autonomous Execution Task Management" in subagents-orchestration-guid
77
77
  - `approved` → Proceed to step 3
78
78
  - Otherwise → Proceed to step 3
79
79
  3. **INVOKE quality-fixer**: Execute all quality checks and fixes (cross-layer: see Layer-Aware Agent Routing)
80
- 4. **COMMIT on approval**: After `approved: true` Execute git commit
80
+ - `stub_detected` Return to step 1 with `incompleteImplementations[]` details
81
+ - `blocked` → Escalate to user
82
+ - `approved` → Proceed to step 4
83
+ 4. **COMMIT on approval**: Execute git commit
81
84
 
82
85
  ### Security Review (After All Tasks Complete)
83
86
 
@@ -90,9 +93,10 @@ After all task cycles finish, invoke security-reviewer before the completion rep
90
93
 
91
94
  ### Test Information Communication
92
95
  After acceptance-test-generator execution, when invoking work-planner (subagent_type: "work-planner"), communicate:
93
- - Generated integration test file path
94
- - Generated E2E test file path
95
- - Explicit note that integration tests run with implementation, E2E tests run after all implementations
96
+ - Generated integration test file path (from `generatedFiles.integration`)
97
+ - Generated E2E test file path or null (from `generatedFiles.e2e`)
98
+ - E2E absence reason (from `e2eAbsenceReason`, when E2E is null)
99
+ - Explicit note that integration tests are created simultaneously with implementation, E2E tests are executed after all implementations (when E2E path is provided)
96
100
 
97
101
  ## Execution Method
98
102
 
@@ -46,7 +46,10 @@ Follow subagents-orchestration-guide skill strictly and create work plan with th
46
46
  - `subagent_type`: "work-planner"
47
47
  - `description`: "Work plan creation"
48
48
  - If test skeletons were generated in Step 2:
49
- `prompt`: "Create work plan from Design Doc at [path]. Integration test file: [integration test path from step 2]. E2E test file: [E2E test path from step 2]. Integration tests are created simultaneously with each phase implementation, E2E tests are executed only in final phase."
49
+ - When `generatedFiles.e2e` is not null:
50
+ `prompt`: "Create work plan from Design Doc at [path]. Integration test file: [integration test path]. E2E test file: [E2E test path]. Integration tests are created simultaneously with each phase implementation, E2E tests are executed only in final phase."
51
+ - When `generatedFiles.e2e` is null:
52
+ `prompt`: "Create work plan from Design Doc at [path]. Integration test file: [integration test path]. No E2E test skeletons were generated (reason: [e2eAbsenceReason]). Integration tests are created simultaneously with each phase implementation."
50
53
  - If test skeletons were not generated:
51
54
  `prompt`: "Create work plan from Design Doc at [path]."
52
55
 
@@ -121,6 +121,9 @@ prompt: |
121
121
  doc_type: design-doc
122
122
  document_path: [path from Step 1]
123
123
  Verify the updated Design Doc against current codebase.
124
+
125
+ Verification focus: Pay special attention to literal identifier referential
126
+ integrity in the updated sections (paths, endpoints, type names, config keys).
124
127
  ```
125
128
 
126
129
  **Store output as**: `$CODE_VERIFICATION_OUTPUT`
@@ -145,9 +145,14 @@ Agentツールでintegration-test-reviewerを呼び出す:
145
145
  - `description`: "最終品質保証"
146
146
  - `prompt`: "このワークフローで追加されたテストファイルの最終品質保証。全テストを実行しカバレッジを確認。"
147
147
 
148
- **期待される出力**: `approved` (true/false)
148
+ **期待される出力**: `status` (approved/stub_detected/blocked)
149
+
150
+ quality-fixerレスポンスチェック:
151
+ - `stub_detected` → `incompleteImplementations[]`の詳細を添えてStep 4に戻し、Steps 4→5→6→7を再実行
152
+ - `blocked` → ユーザーにエスカレーション
153
+ - `approved` → Step 8へ
149
154
 
150
155
  ### ステップ8: コミット
151
156
 
152
- quality-fixerから`approved: true`の場合:
157
+ quality-fixerから`approved`の場合:
153
158
  - Bashで適切なメッセージを付けてテストファイルをコミット
@@ -85,9 +85,13 @@ Agentツールでtask-decomposerを呼び出す:
85
85
  - `approved` → ステップ4へ
86
86
  - `readyForQualityCheck: true` → ステップ4へ
87
87
  4. **quality-fixer実行**: 全品質チェックと修正を実行(レイヤー横断時: レイヤー別エージェントルーティング参照)
88
- 5. **承認後コミット**: quality-fixerの`approved: true`確認後 → git commitを実行
88
+ 5. **quality-fixerレスポンスチェック**:
89
+ - `stub_detected` → `incompleteImplementations[]`の詳細を添えてステップ2に戻す
90
+ - `blocked` → 停止してユーザーにエスカレーション
91
+ - `approved` → ステップ6へ
92
+ 6. **承認後コミット**: git commitを実行
89
93
 
90
- **重要**: 例外なく全ての構造化レスポンスを監視し、全ての品質ゲートが通過することを確保。
94
+ **重要**: 例外なく全ての構造化レスポンスを監視し、全ての品質ゲートが通過することを確保。quality-fixerが`approved`を返すまで次のタスクに進まない。
91
95
 
92
96
  ## サブエージェント呼び出し時の制約
93
97
 
@@ -2,7 +2,7 @@
2
2
  description: 問題を調査し、検証を経て解決策を導出する
3
3
  ---
4
4
 
5
- **コマンドコンテキスト**: 問題の根本原因を特定し、解決策を提示するための診断フロー
5
+ **コマンドコンテキスト**: 問題の障害点を特定し、解決策を提示するための診断フロー
6
6
 
7
7
  対象問題: $ARGUMENTS
8
8
 
@@ -64,10 +64,10 @@ rule-advisorの出力から以下を確認:
64
64
  ```
65
65
  問題 → investigator → verifier → solver ─┐
66
66
  ↑ │
67
- └── 信頼度high未達 ──────┘
67
+ └── カバレッジ不十分 ────┘
68
68
  (最大2回)
69
69
 
70
- 信頼度high達成 → レポート
70
+ カバレッジ十分 → レポート
71
71
  ```
72
72
 
73
73
  **コンテキスト分離**: 各ステップには構造化JSON出力のみを渡す。思考過程は引き継がない。
@@ -94,19 +94,20 @@ Agentツールでinvestigatorを呼び出す:
94
94
  影響箇所: [何が壊れたか]
95
95
  共通コンポーネント: [原因変更と影響箇所の共通点]
96
96
 
97
- **期待される出力**: 証拠マトリクス、比較分析結果、因果追跡結果、未探索領域のリスト、調査の限界
97
+ **期待される出力**: pathMap(症状ごとの実行パス)、failurePoints(各ノードで発見された障害点)、障害点ごとのimpactAnalysis、未探索領域のリスト、調査の限界
98
98
 
99
99
  ### ステップ2: 調査品質判定
100
100
 
101
101
  調査出力を確認:
102
102
 
103
103
  **品質チェック**(出力JSONに以下が含まれているか):
104
- - [ ] `comparisonAnalysis`が存在し、`normalImplementation`がnullでない(比較対象が見つかった)、または「正常動作する実装が見つからなかった」と明示的に記録されている
105
- - [ ] 各仮説の`causalChain`が停止条件に到達(コード変更で対処可能 / 設計判断レベル / 外部制約)
106
- - [ ] 各仮説の`causeCategory`が以下のいずれか: typo / logic_error / missing_constraint / design_gap / external_factor
104
+ - [ ] `pathMap`が少なくとも1つの症状を含み、各症状に少なくとも1つのパスとノードが列挙されている
105
+ - [ ] 各障害点に`location`、`upstreamDependency`、`symptomExplained`、`causalChain`(停止条件に到達)、`checkStatus`、具体的なファイルや場所を引用した`source`を持つ`evidence`が含まれている
106
+ - [ ] 各障害点に`comparisonAnalysis`が含まれている(normalImplementationが見つかった、または明示的にnull)
107
+ - [ ] 各障害点の`causeCategory`が以下のいずれか: typo / logic_error / missing_constraint / design_gap / external_factor
107
108
  - [ ] `investigationSources`が少なくとも3つの異なるソースタイプ(code, history, dependency, config, document, external)をカバー
108
109
  - [ ] ステップ0.4で提供した`investigationFocus`の項目が調査に含まれている
109
- - [ ] 各仮説の`supportingEvidence`に具体的なファイルや場所を引用した`source`フィールドを持つエントリが最低1つある
110
+ - [ ] マッピングされたパス上の全ノードがチェック済み(最初の障害点発見後にパスが放棄されていない)
110
111
 
111
112
  **品質不足の場合**: 不足項目を明示してinvestigatorを再実行:
112
113
  - `prompt`: |
@@ -135,48 +136,59 @@ Agentツールでverifierを呼び出す:
135
136
  - `description`: "調査結果の検証"
136
137
  - `prompt`: "以下の調査結果を検証してください。調査結果: [調査のJSON出力]"
137
138
 
138
- **期待される出力**: 代替仮説(最低3つ)、Devil's Advocate評価、最終結論、信頼度
139
+ **期待される出力**: カバレッジチェック(未探索パス、未チェックノード)、障害点ごとのDevil's Advocate評価、finalStatusを含む障害点評価、カバレッジ評価(`coverageAssessment`)
139
140
 
140
- **信頼度の判定基準**:
141
- - **high**: 解決策の選択・実装に影響する不確実性がない
142
- - **medium**: 不確実性があるが、追加調査で解消可能
143
- - **low**: 根本的な情報不足がある
141
+ **カバレッジの判定基準**:
142
+ - **十分(`sufficient`)**: 主要パスが追跡済み、全重要ノードがチェック済み、各障害点が個別に評価済み
143
+ - **部分的(`partial`)**: 主要パスは追跡済みだが、一部ノードが未チェックまたは一部障害点がblocked/not_reached
144
+ - **不十分(`insufficient`)**: 重要なパスが未追跡、または重要ノードが未調査
144
145
 
145
- ### ステップ4: 解決策導出(solver)
146
+ ### ステップ4: カバレッジゲート
147
+
148
+ verifierのカバレッジ評価(`coverageAssessment`)を確認:
149
+
150
+ - **十分** → ステップ5(solver)へ進む
151
+ - **部分的または不十分** → verifierが特定した未チェック領域を調査対象としてステップ1に戻る
152
+ - 追加調査は最大2回まで
153
+ - 2回の追加調査後もsufficientに到達しない場合、ユーザーに選択肢を提示:
154
+ - 追加調査を継続
155
+ - 現在のカバレッジレベルでsolverに進む(不完全な診断のリスクをユーザーが承認)
156
+
157
+ ### ステップ5: 解決策導出(solver)
158
+
159
+ **前提**: カバレッジ評価が十分(`coverageAssessment=sufficient`)、または部分的/不十分でのユーザー承認
146
160
 
147
161
  Agentツールでsolverを呼び出す:
148
162
  - `subagent_type`: "solver"
149
163
  - `description`: "解決策の導出"
150
- - `prompt`: "以下の検証済み結論に基づいて、解決策を導出してください。原因: [verifierのconclusion.causes]。原因の関係性: [causesRelationship: independent/dependent/exclusive]。信頼度: [high/medium/low]"
151
-
152
- **期待される出力**: 複数の解決策(最低3つ)、トレードオフ分析、推奨案と実装ステップ、残存リスク
164
+ - `prompt`: |
165
+ 以下の検証済み障害点に基づいて、解決策を導出してください。
153
166
 
154
- **完了条件**: 信頼度がhigh
167
+ 確認済み障害点: [verifierのconclusion.confirmedFailurePoints]
168
+ 反証済み障害点: [verifierのconclusion.refutedFailurePoints]
169
+ 障害点の関係性: [verifierのconclusion.failurePointRelationships]
170
+ 影響分析: [investigatorのimpactAnalysis]
171
+ カバレッジ評価: [sufficient/partial/insufficient]
155
172
 
156
- **未達の場合**:
157
- 1. solverが特定した不確実性を調査対象としてステップ1に戻る
158
- 2. 追加調査は最大2回まで
159
- 3. 2回の追加調査後も未達の場合、ユーザーに選択肢を提示:
160
- - 追加調査を継続
161
- - 現在の信頼度で解決策を実行
173
+ **期待される出力**: 複数の解決策(最低3つ)、トレードオフ分析、推奨案と実装ステップ、残存リスク
162
174
 
163
- ### ステップ5: 最終レポート作成
175
+ ### ステップ6: 最終レポート作成
164
176
 
165
- **前提**: 信頼度highを達成している
177
+ **前提**: solver完了(ステップ5)
166
178
 
167
179
  診断完了後、以下の形式でユーザーに報告:
168
180
 
169
181
  ```
170
182
  ## 診断結果サマリー
171
183
 
172
- ### 特定された原因
173
- [検証結果の原因リスト]
174
- - 原因の関係性: [independent/dependent/exclusive]
184
+ ### 特定された障害点
185
+ [検証結果の確認済み障害点]
186
+ - 障害点ごと: location、symptomExplained、finalStatus
175
187
 
176
188
  ### 検証プロセス
177
- - 調査範囲: [調査で確認した範囲]
189
+ - パスカバレッジ: [追跡したパスとチェックしたノード]
178
190
  - 追加調査回数: [0/1/2回]
179
- - 代替仮説数: [検証で生成した数]
191
+ - カバレッジ評価: [sufficient/partial/insufficient]
180
192
 
181
193
  ### 推奨する解決策
182
194
  [解決策導出の推奨案]
@@ -201,9 +213,9 @@ Agentツールでsolverを呼び出す:
201
213
 
202
214
  ## 完了条件
203
215
 
204
- - [ ] investigatorを実行し、証拠マトリクス・比較分析・因果追跡を取得した
216
+ - [ ] investigatorを実行し、pathMap・failurePoints・impactAnalysisを取得した
205
217
  - [ ] 調査品質チェックを行い、不足があれば再実行した
206
- - [ ] verifierを実行し、信頼度を取得した
218
+ - [ ] verifierを実行し、coverageAssessmentを取得した
207
219
  - [ ] solverを実行した
208
- - [ ] 信頼度highを達成した(または2回の追加調査後にユーザー承認を得た)
220
+ - [ ] coverageAssessment=sufficientを達成した(または2回の追加調査後にユーザー承認を得た)
209
221
  - [ ] 最終レポートをユーザーに提示した
@@ -84,10 +84,14 @@ Agentツールでtask-decomposerを呼び出す:
84
84
  - `needs_revision` → `requiredFixes`を添えてステップ2に戻る
85
85
  - `approved` → ステップ4へ
86
86
  - `readyForQualityCheck: true` → ステップ4へ
87
- 4. **quality-fixer-frontend実行**: 全品質チェックと修正を実行
88
- 5. **承認後コミット**: quality-fixer-frontendの`approved: true`確認後 → git commitを実行
89
-
90
- **重要**: 全てのサブエージェントレスポンスのstatusフィールドをパースし、4ステップサイクルの対応ブランチを実行。quality-fixer-frontendが`approved: true`を返すまで次のタスクに進まない。
87
+ 4. **quality-fixer-frontend実行**: 全品質チェックと修正を実行(レイヤー横断時: レイヤー別エージェントルーティング参照)
88
+ 5. **quality-fixer-frontendレスポンスチェック**:
89
+ - `stub_detected` → `incompleteImplementations[]`の詳細を添えてステップ2に戻す
90
+ - `blocked` → 停止してユーザーにエスカレーション
91
+ - `approved` → ステップ6へ
92
+ 6. **承認後コミット**: git commitを実行
93
+
94
+ **重要**: 全てのサブエージェントレスポンスのstatusフィールドをパースし、4ステップサイクルの対応ブランチを実行。quality-fixer-frontendが`approved`を返すまで次のタスクに進まない。
91
95
 
92
96
  ## サブエージェント呼び出し時の制約
93
97
 
@@ -43,13 +43,19 @@ Agentツールでacceptance-test-generatorを呼び出す:
43
43
  - UI Specあり: `prompt: "[パス]のDesign Docからテストスケルトンを生成。UI Specは[ui-specパス]。"`
44
44
  - UI Specなし: `prompt: "[パス]のDesign Docからテストスケルトンを生成。"`
45
45
 
46
- 統合テストファイルパスとE2Eテストファイルパスを、subagents-orchestration-guideの「acceptance-test-generator → work-planner」セクションに従いwork-plannerに渡す。
46
+ 統合テストファイルパス、E2Eテストファイルパス(またはnull)、およびe2eAbsenceReasonを、subagents-orchestration-guideの「acceptance-test-generator → work-planner」セクションに従いwork-plannerに渡す。
47
47
 
48
48
  ### Step 3: 作業計画書作成
49
49
  Agentツールでwork-plannerを呼び出す:
50
50
  - `subagent_type`: "work-planner"
51
51
  - `description`: "作業計画書作成"
52
- - `prompt`: "[パス]のDesign Docから作業計画を作成。統合テストファイル: [ステップ2の統合テストパス]。E2Eテストファイル: [ステップ2のE2Eテストパス]。統合テストは各フェーズ実装と同時に作成、E2Eテストは最終フェーズでのみ実行。"
52
+ - ステップ2でテストスケルトンを生成した場合:
53
+ - `generatedFiles.e2e`がnullでない場合:
54
+ `prompt`: "[パス]のDesign Docから作業計画を作成。統合テストファイル: [ステップ2の統合テストパス]。E2Eテストファイル: [ステップ2のE2Eテストパス]。統合テストは各フェーズ実装と同時に作成、E2Eテストは最終フェーズでのみ実行。"
55
+ - `generatedFiles.e2e`がnullの場合:
56
+ `prompt`: "[パス]のDesign Docから作業計画を作成。統合テストファイル: [ステップ2の統合テストパス]。E2Eテストスケルトンは生成されませんでした(理由: [e2eAbsenceReason])。統合テストは各フェーズ実装と同時に作成。"
57
+ - テストスケルトンを生成しなかった場合:
58
+ `prompt`: "[パス]のDesign Docから作業計画を作成。"
53
59
 
54
60
  - subagents-orchestration-guideのPrompt Construction Ruleに従い追加パラメータを構成
55
61
  - 作業計画書をユーザーに提示しレビューを受ける。変更要望があればwork-plannerを修正パラメータで再実行
@@ -77,7 +77,10 @@ subagents-orchestration-guideスキルの「自律実行中のタスク管理」
77
77
  - `approved` → ステップ3へ
78
78
  - それ以外 → ステップ3へ
79
79
  3. **quality-fixer実行**: 全品質チェックと修正を実行(レイヤー横断時: レイヤー別エージェントルーティング参照)
80
- 4. **承認後コミット**: `approved: true`確認後 git commitを実行
80
+ - `stub_detected``incompleteImplementations[]`の詳細を添えてステップ1に戻す
81
+ - `blocked` → ユーザーにエスカレーション
82
+ - `approved` → ステップ4へ
83
+ 4. **承認後コミット**: `approved`確認後 → git commitを実行
81
84
 
82
85
  ### Security Review(全タスク完了後)
83
86
 
@@ -90,9 +93,10 @@ subagents-orchestration-guideスキルの「自律実行中のタスク管理」
90
93
 
91
94
  ### テスト情報の伝達
92
95
  acceptance-test-generator実行後、work-planner(subagent_type: "work-planner")呼び出し時には以下を伝達:
93
- - 生成された統合テストファイルパス
94
- - 生成されたE2Eテストファイルパス
95
- - 統合テストは実装と同時、E2Eは全実装後に実行する旨の明示
96
+ - 統合テストファイルパス(`generatedFiles.integration`から取得)
97
+ - E2Eテストファイルパスまたはnull(`generatedFiles.e2e`から取得)
98
+ - E2E不在理由(`e2eAbsenceReason`、E2Eがnullの場合)
99
+ - 統合テストは実装と同時に作成、E2Eテストは全実装完了後に実行(E2Eパスが提供された場合)
96
100
 
97
101
  ## 実行方法
98
102
 
@@ -46,7 +46,10 @@ description: 設計書から作業計画書を作成し計画承認を取得
46
46
  - `subagent_type`: "work-planner"
47
47
  - `description`: "作業計画書作成"
48
48
  - ステップ2でテストスケルトンを生成した場合:
49
- `prompt`: "[パス]のDesign Docから作業計画を作成。統合テストファイル: [ステップ2の統合テストパス]。E2Eテストファイル: [ステップ2のE2Eテストパス]。統合テストは各フェーズ実装と同時に作成、E2Eテストは最終フェーズでのみ実行。"
49
+ - `generatedFiles.e2e`がnullでない場合:
50
+ `prompt`: "[パス]のDesign Docから作業計画を作成。統合テストファイル: [ステップ2の統合テストパス]。E2Eテストファイル: [ステップ2のE2Eテストパス]。統合テストは各フェーズ実装と同時に作成、E2Eテストは最終フェーズでのみ実行。"
51
+ - `generatedFiles.e2e`がnullの場合:
52
+ `prompt`: "[パス]のDesign Docから作業計画を作成。統合テストファイル: [ステップ2の統合テストパス]。E2Eテストスケルトンは生成されませんでした(理由: [e2eAbsenceReason])。統合テストは各フェーズ実装と同時に作成。"
50
53
  - テストスケルトンを生成しなかった場合:
51
54
  `prompt`: "[パス]のDesign Docから作業計画を作成。"
52
55
 
@@ -121,6 +121,9 @@ prompt: |
121
121
  doc_type: design-doc
122
122
  document_path: [ステップ1のパス]
123
123
  更新されたDesign Docを現在のコードベースに対して検証する。
124
+
125
+ 検証の重点: 更新されたセクション内のリテラル識別子の参照整合性
126
+ (パス、エンドポイント、型名、設定キー)に特に注意して検証すること。
124
127
  ```
125
128
 
126
129
  **出力を保存**: `$CODE_VERIFICATION_OUTPUT`