create-ai-project 1.23.4 → 1.24.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.
- package/.claude/agents-en/acceptance-test-generator.md +8 -32
- package/.claude/agents-en/code-reviewer.md +24 -25
- package/.claude/agents-en/code-verifier.md +3 -32
- package/.claude/agents-en/codebase-analyzer.md +11 -79
- package/.claude/agents-en/document-reviewer.md +12 -58
- package/.claude/agents-en/integration-test-reviewer.md +6 -37
- package/.claude/agents-en/investigator.md +6 -59
- package/.claude/agents-en/quality-fixer-frontend.md +1 -5
- package/.claude/agents-en/quality-fixer.md +1 -5
- package/.claude/agents-en/requirement-analyzer.md +3 -14
- package/.claude/agents-en/rule-advisor.md +3 -16
- package/.claude/agents-en/scope-discoverer.md +5 -29
- package/.claude/agents-en/security-reviewer.md +2 -13
- package/.claude/agents-en/skill-creator.md +3 -6
- package/.claude/agents-en/skill-reviewer.md +7 -43
- package/.claude/agents-en/solver.md +9 -24
- package/.claude/agents-en/task-decomposer.md +39 -8
- package/.claude/agents-en/task-executor-frontend.md +29 -20
- package/.claude/agents-en/task-executor.md +29 -20
- package/.claude/agents-en/technical-designer-frontend.md +7 -12
- package/.claude/agents-en/technical-designer.md +4 -11
- package/.claude/agents-en/ui-analyzer.md +16 -115
- package/.claude/agents-en/ui-spec-designer.md +3 -3
- package/.claude/agents-en/verifier.md +9 -53
- package/.claude/agents-en/work-planner.md +27 -22
- package/.claude/agents-ja/acceptance-test-generator.md +10 -34
- package/.claude/agents-ja/code-reviewer.md +24 -25
- package/.claude/agents-ja/code-verifier.md +5 -34
- package/.claude/agents-ja/codebase-analyzer.md +11 -79
- package/.claude/agents-ja/document-reviewer.md +16 -62
- package/.claude/agents-ja/integration-test-reviewer.md +6 -37
- package/.claude/agents-ja/investigator.md +6 -59
- package/.claude/agents-ja/prd-creator.md +3 -3
- package/.claude/agents-ja/quality-fixer-frontend.md +2 -6
- package/.claude/agents-ja/quality-fixer.md +2 -6
- package/.claude/agents-ja/requirement-analyzer.md +3 -14
- package/.claude/agents-ja/rule-advisor.md +4 -17
- package/.claude/agents-ja/scope-discoverer.md +5 -29
- package/.claude/agents-ja/security-reviewer.md +3 -14
- package/.claude/agents-ja/skill-creator.md +3 -6
- package/.claude/agents-ja/skill-reviewer.md +7 -43
- package/.claude/agents-ja/solver.md +11 -26
- package/.claude/agents-ja/task-decomposer.md +40 -9
- package/.claude/agents-ja/task-executor-frontend.md +29 -20
- package/.claude/agents-ja/task-executor.md +29 -20
- package/.claude/agents-ja/technical-designer-frontend.md +8 -13
- package/.claude/agents-ja/technical-designer.md +5 -12
- package/.claude/agents-ja/ui-analyzer.md +17 -116
- package/.claude/agents-ja/ui-spec-designer.md +7 -7
- package/.claude/agents-ja/verifier.md +9 -53
- package/.claude/agents-ja/work-planner.md +51 -51
- package/.claude/commands-ja/build.md +1 -1
- package/.claude/commands-ja/design.md +1 -1
- package/.claude/commands-ja/diagnose.md +1 -1
- package/.claude/commands-ja/front-build.md +1 -1
- package/.claude/commands-ja/front-design.md +3 -3
- package/.claude/commands-ja/front-plan.md +2 -2
- package/.claude/commands-ja/implement.md +1 -1
- package/.claude/commands-ja/plan.md +2 -2
- package/.claude/commands-ja/prepare-implementation.md +4 -4
- package/.claude/commands-ja/reverse-engineer.md +1 -1
- package/.claude/commands-ja/review.md +1 -1
- package/.claude/commands-ja/task.md +2 -2
- package/.claude/commands-ja/update-doc.md +1 -1
- package/.claude/skills-en/documentation-criteria/references/design-template.md +5 -1
- package/.claude/skills-en/documentation-criteria/references/plan-template.md +17 -7
- package/.claude/skills-en/documentation-criteria/references/task-template.md +18 -0
- package/.claude/skills-en/documentation-criteria/references/ui-spec-template.md +1 -1
- package/.claude/skills-en/frontend-technical-spec/SKILL.md +4 -8
- package/.claude/skills-en/frontend-typescript-rules/SKILL.md +4 -2
- package/.claude/skills-en/frontend-typescript-testing/SKILL.md +5 -11
- package/.claude/skills-en/frontend-typescript-testing/references/e2e.md +1 -1
- package/.claude/skills-en/technical-spec/SKILL.md +4 -3
- package/.claude/skills-en/typescript-testing/SKILL.md +4 -4
- package/.claude/skills-ja/coding-standards/SKILL.md +4 -4
- package/.claude/skills-ja/coding-standards/references/security-checks.md +1 -1
- package/.claude/skills-ja/documentation-criteria/SKILL.md +1 -1
- package/.claude/skills-ja/documentation-criteria/references/design-template.md +10 -6
- package/.claude/skills-ja/documentation-criteria/references/plan-template.md +18 -8
- package/.claude/skills-ja/documentation-criteria/references/task-template.md +18 -0
- package/.claude/skills-ja/documentation-criteria/references/ui-spec-template.md +3 -3
- package/.claude/skills-ja/frontend-technical-spec/SKILL.md +4 -8
- package/.claude/skills-ja/frontend-typescript-rules/SKILL.md +5 -3
- package/.claude/skills-ja/frontend-typescript-testing/SKILL.md +5 -11
- package/.claude/skills-ja/frontend-typescript-testing/references/e2e.md +2 -2
- package/.claude/skills-ja/implementation-approach/SKILL.md +1 -1
- package/.claude/skills-ja/integration-e2e-testing/SKILL.md +1 -1
- package/.claude/skills-ja/integration-e2e-testing/references/e2e-environment-prerequisites.md +1 -1
- package/.claude/skills-ja/project-context/references/template.md +2 -2
- package/.claude/skills-ja/task-analyzer/references/skills-index.yaml +3 -3
- package/.claude/skills-ja/technical-spec/SKILL.md +4 -3
- package/.claude/skills-ja/typescript-testing/SKILL.md +4 -4
- package/CHANGELOG.md +19 -0
- package/package.json +1 -1
|
@@ -183,6 +183,17 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
183
183
|
2. **既存実装調査**:同ドメイン・責務で類似コンポーネント・hook を検索
|
|
184
184
|
3. **判定実行**:上記「必須判断基準」に従い継続・エスカレーション判定
|
|
185
185
|
|
|
186
|
+
#### 隣接ケース走査(タスクファイルの `Change Category` フィールドが `bug-fix` / `regression` / `state-change` / `boundary-change` のいずれかに設定されている場合は必須)
|
|
187
|
+
|
|
188
|
+
実装前確認の後、Binding Decision チェックの前に実行する。このステップはタスク分解が書き込んだフィールド値で発火する — フィールド値を読み、走査を適用するかの判断はそれを正本とする。
|
|
189
|
+
|
|
190
|
+
1. Investigation Targets(分解時に隣接ファイルが既に追加されている)から、変更と同一の経路・契約・永続状態・外部境界を共有するケースを特定する — 変更に関連するフォールバック描画、stale な状態、リトライ、外部呼び出しなど。
|
|
191
|
+
2. それぞれが、このタスクが修正するのと同一クラスの欠陥を抱えているか確認する。
|
|
192
|
+
3. 各残余をスコープに応じて処理する:
|
|
193
|
+
- **Target Files スコープ内** → 残余をこのタスクの失敗するテストと実装に取り込む。
|
|
194
|
+
- **修正を要すると確認できたスコープ外の兄弟ケース** → `out_of_scope_file` エスカレーション(Target Files 外のファイルに触れる際の標準経路)を発行し、ユーザーが Target Files を拡張するか follow-up タスクに切り出すかを判断できるようにする。これにより、確認済みの隣接欠陥は明示的な判断に回される。
|
|
195
|
+
- **修正を要するか確認できない関連残余** → タスクファイルの Investigation Notes に記録し、下流のレビューの隣接ケースチェックが実装に対して検証できるようにする。
|
|
196
|
+
|
|
186
197
|
#### Binding Decision チェック(タスクファイルに Binding Decisions セクションがある場合は必須)
|
|
187
198
|
|
|
188
199
|
このチェックは実装前確認の後、TDDサイクルの前に実行される。タスクファイルに1行以上を持つ Binding Decisions セクションがある場合のみ適用される。
|
|
@@ -195,6 +206,18 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
195
206
|
- `N`: 実装を中止し、`status: "escalation_needed"` と `escalation_type: "binding_decision_violation"`(`phase: "pre_implementation"`)で最終レスポンスを生成する(エスカレーションレスポンス表を参照)。`N` は計画段階での違反を表す
|
|
196
207
|
- `Unknown`: その行を Investigation Notes に保留として記録し、TDDサイクルに進む。終了ゲートが(このステップで保留された Unknown 行を含む)全行を最終実装に対して再評価し、その時点で `N` または `Unknown` が残る場合はエスカレーションする
|
|
197
208
|
|
|
209
|
+
#### Reference Contract チェック(タスクファイルに Reference Contracts セクションがある場合は必須)
|
|
210
|
+
|
|
211
|
+
実装前確認の後、Binding Decision チェックと並行して実行する。
|
|
212
|
+
|
|
213
|
+
1. Reference Contracts 表の各 Source が読み込み済みであることを確認する(Source は Investigation Targets に記載され、Step 2 で読み込まれている)
|
|
214
|
+
2. 計画したアプローチを Investigation Notes に記録する — 各行について、実装が Required Observable Value をどう再現するかを1文で述べる
|
|
215
|
+
3. 各行の Compliance Check を、計画したアプローチに対して評価する。各行の結果を `Y`、`N`、`Unknown` のいずれかとして、一行の根拠とともに Investigation Notes に記録する。`Unknown` は、計画したアプローチが述語の対象についてまだ判断を持たない場合のみ使う
|
|
216
|
+
4. 行ごとに、評価に応じて分岐する:
|
|
217
|
+
- `Y`: 続行する
|
|
218
|
+
- `N`: 実装を中止し、`status: "escalation_needed"` と `escalation_type: "design_compliance_violation"` で最終レスポンスを生成する。エスカレーションレスポンス表に従って埋める — `details.design_doc_expectation` = Reference Contract 行の Required Observable Value、`details.actual_situation` = 計画したアプローチ、`details.why_cannot_implement` / `details.attempted_approaches[]` / `claude_recommendation` は表に従う。`N` は計画段階での違反を表す
|
|
219
|
+
- `Unknown`: その行を Investigation Notes に保留として記録し、TDDサイクルに進む。終了ゲートが全保留行を最終実装に対して再評価する
|
|
220
|
+
|
|
198
221
|
#### 参照の代表性チェック(実装中に随時適用)
|
|
199
222
|
|
|
200
223
|
パターン・hook・ライブラリをコードから採用する際、coding-standards の「参照の代表性」を採用時点で適用する:
|
|
@@ -278,20 +301,8 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
278
301
|
"testsAdded": ["src/components/Button/Button.test.tsx"],
|
|
279
302
|
"requiresTestReview": false,
|
|
280
303
|
"newTestsPassed": true,
|
|
281
|
-
"progressUpdated": {
|
|
282
|
-
|
|
283
|
-
"workPlan": "該当箇所更新済み",
|
|
284
|
-
"designDoc": "進捗セクション更新済み or N/A"
|
|
285
|
-
},
|
|
286
|
-
"runnableCheck": {
|
|
287
|
-
"level": "L1: 単体テスト (React Testing Library) / L2: 統合テスト / L3: E2Eテスト",
|
|
288
|
-
"executed": true,
|
|
289
|
-
"command": "test -- Button.test.tsx",
|
|
290
|
-
"result": "passed / failed / skipped",
|
|
291
|
-
"substance": "substantive | non_substantive | null (非テスト系の検証)",
|
|
292
|
-
"substanceIssue": "substantive または非テスト系の場合は null。non_substantive の場合は原因と位置を記載",
|
|
293
|
-
"reason": "テスト実行理由・確認内容"
|
|
294
|
-
},
|
|
304
|
+
"progressUpdated": {"taskFile": "完了項目5/8", "workPlan": "該当箇所更新済み", "designDoc": "進捗セクション更新済み or N/A"},
|
|
305
|
+
"runnableCheck": {"level": "L1: 単体テスト (React Testing Library) / L2: 統合テスト / L3: E2Eテスト", "executed": true, "command": "test -- Button.test.tsx", "result": "passed / failed / skipped", "substance": "substantive | non_substantive | null (非テスト系の検証)", "substanceIssue": "substantive または非テスト系の場合は null。non_substantive の場合は原因と位置を記載", "reason": "テスト実行理由・確認内容"},
|
|
295
306
|
"readyForQualityCheck": true,
|
|
296
307
|
"nextActions": "品質チェック工程による全体品質検証"
|
|
297
308
|
}
|
|
@@ -334,11 +345,7 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
334
345
|
"reason": "Out of scope file",
|
|
335
346
|
"taskName": "[タスク名]",
|
|
336
347
|
"escalation_type": "out_of_scope_file",
|
|
337
|
-
"details": {
|
|
338
|
-
"file_path": "[変更を試みたパス]",
|
|
339
|
-
"allowed_list": ["[Target Files / タスクファイル / 作業計画書 / Provides の和集合]"],
|
|
340
|
-
"modification_reason": "[なぜ変更を試みたか]"
|
|
341
|
-
},
|
|
348
|
+
"details": {"file_path": "[変更を試みたパス]", "allowed_list": ["[Target Files / タスクファイル / 作業計画書 / Provides の和集合]"], "modification_reason": "[なぜ変更を試みたか]"},
|
|
342
349
|
"user_decision_required": true,
|
|
343
350
|
"suggested_options": ["Target Files に追加してリトライ", "別タスクに分割", "アプローチを再検討"]
|
|
344
351
|
}
|
|
@@ -352,7 +359,9 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
352
359
|
☐ Fix Mode: `requiredFixes` / `incompleteImplementations` の全項目が `changeSummary` に対応または個別エスカレーション済み
|
|
353
360
|
☐ 実装が Step 2 で記録した調査メモと整合している(調査対象が存在した場合)
|
|
354
361
|
☐ Binding Decisions の全 Compliance Check が最終実装に対して `Y` と評価され、その根拠が Investigation Notes に記録されている(タスクファイルに Binding Decisions セクションがある場合)。実装前チェックが通過していても、実装が計画したアプローチから逸脱している可能性があるため、ここで再評価する
|
|
362
|
+
☐ Reference Contracts の全 Compliance Check が最終実装に対して `Y` と評価され、その根拠が Investigation Notes に記録されている(タスクファイルに Reference Contracts セクションがある場合)。実装前チェックが通過していても、ここで再評価する
|
|
363
|
+
☐ テストが roundtrip を検証している — producer が出力する値を consumer が期待どおりの値へパースできる(タスクが作業計画書の Connection Map 由来の roundtrip チェックを伴う Boundary Context を持つ場合)
|
|
355
364
|
☐ テストエビデンスを引用している場合(タスクがテストを実行した場合)、`runnableCheck.substance` と `runnableCheck.substanceIssue` がフィールド仕様に従って設定されている
|
|
356
365
|
☐ 最終レスポンスが `status: "completed"` または `status: "escalation_needed"` の単一 JSON で、構造化レスポンス仕様のスキーマに一致する
|
|
357
366
|
|
|
358
|
-
**強制**: いずれかが未チェックの場合、構造化レスポンス仕様で定義される JSON 形式で `status: "escalation_needed"` を返却。未チェック項目が Binding Decisions の Compliance Check の場合は、`escalation_type: "binding_decision_violation"`(`phase: "exit_gate"
|
|
367
|
+
**強制**: いずれかが未チェックの場合、構造化レスポンス仕様で定義される JSON 形式で `status: "escalation_needed"` を返却。未チェック項目が Binding Decisions の Compliance Check の場合は、`escalation_type: "binding_decision_violation"`(`phase: "exit_gate"`)を使う。その他の未チェックのゲート項目には `escalation_type: "design_compliance_violation"` を使い、実装前マッピングと同じ粒度でエスカレーションレスポンス表に従って埋める: Reference Contracts の失敗では `details.design_doc_expectation` = Required Observable Value、`details.actual_situation` = 最終実装の振る舞い; roundtrip テストの欠落では `details.design_doc_expectation` = 要求される roundtrip(producer が出力する値を consumer が期待どおりの値へパースできること)、`details.actual_situation` = 欠落または失敗している roundtrip カバレッジ; いずれの場合も `details.why_cannot_implement` / `details.attempted_approaches[]` / `claude_recommendation` は表に従う。
|
|
@@ -183,6 +183,17 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
183
183
|
2. **既存実装調査**:同ドメイン・責務で類似機能を検索
|
|
184
184
|
3. **判定実行**:上記「必須判断基準」に従い継続・エスカレーション判定
|
|
185
185
|
|
|
186
|
+
#### 隣接ケース走査(タスクファイルの `Change Category` フィールドが `bug-fix` / `regression` / `state-change` / `boundary-change` のいずれかに設定されている場合は必須)
|
|
187
|
+
|
|
188
|
+
実装前確認の後、Binding Decision チェックの前に実行する。このステップはタスク分解が書き込んだフィールド値で発火する — フィールド値を読み、走査を適用するかの判断はそれを正本とする。
|
|
189
|
+
|
|
190
|
+
1. Investigation Targets(分解時に隣接ファイルが既に追加されている)から、変更と同一の経路・契約・永続状態・外部境界を共有するケースを特定する — 変更に関連するフォールバックの振る舞い、stale な状態、リトライ、外部呼び出しなど。
|
|
191
|
+
2. それぞれが、このタスクが修正するのと同一クラスの欠陥を抱えているか確認する。
|
|
192
|
+
3. 各残余をスコープに応じて処理する:
|
|
193
|
+
- **Target Files スコープ内** → 残余をこのタスクの失敗するテストと実装に取り込む。
|
|
194
|
+
- **修正を要すると確認できたスコープ外の兄弟ケース** → `out_of_scope_file` エスカレーション(Target Files 外のファイルに触れる際の標準経路)を発行し、ユーザーが Target Files を拡張するか follow-up タスクに切り出すかを判断できるようにする。これにより、確認済みの隣接欠陥は明示的な判断に回される。
|
|
195
|
+
- **修正を要するか確認できない関連残余** → タスクファイルの Investigation Notes に記録し、下流のレビューの隣接ケースチェックが実装に対して検証できるようにする。
|
|
196
|
+
|
|
186
197
|
#### Binding Decision チェック(タスクファイルに Binding Decisions セクションがある場合は必須)
|
|
187
198
|
|
|
188
199
|
このチェックは実装前確認の後、TDDサイクルの前に実行される。タスクファイルに1行以上を持つ Binding Decisions セクションがある場合のみ適用される。
|
|
@@ -195,6 +206,18 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
195
206
|
- `N`: 実装を中止し、`status: "escalation_needed"` と `escalation_type: "binding_decision_violation"`(`phase: "pre_implementation"`)で最終レスポンスを生成する(エスカレーションレスポンス表を参照)。`N` は計画段階での違反を表す
|
|
196
207
|
- `Unknown`: その行を Investigation Notes に保留として記録し、TDDサイクルに進む。終了ゲートが(このステップで保留された Unknown 行を含む)全行を最終実装に対して再評価し、その時点で `N` または `Unknown` が残る場合はエスカレーションする
|
|
197
208
|
|
|
209
|
+
#### Reference Contract チェック(タスクファイルに Reference Contracts セクションがある場合は必須)
|
|
210
|
+
|
|
211
|
+
実装前確認の後、Binding Decision チェックと並行して実行する。
|
|
212
|
+
|
|
213
|
+
1. Reference Contracts 表の各 Source が読み込み済みであることを確認する(Source は Investigation Targets に記載され、Step 2 で読み込まれている)
|
|
214
|
+
2. 計画したアプローチを Investigation Notes に記録する — 各行について、実装が Required Observable Value をどう再現するかを1文で述べる
|
|
215
|
+
3. 各行の Compliance Check を、計画したアプローチに対して評価する。各行の結果を `Y`、`N`、`Unknown` のいずれかとして、一行の根拠とともに Investigation Notes に記録する。`Unknown` は、計画したアプローチが述語の対象についてまだ判断を持たない場合のみ使う
|
|
216
|
+
4. 行ごとに、評価に応じて分岐する:
|
|
217
|
+
- `Y`: 続行する
|
|
218
|
+
- `N`: 実装を中止し、`status: "escalation_needed"` と `escalation_type: "design_compliance_violation"` で最終レスポンスを生成する。エスカレーションレスポンス表に従って埋める — `details.design_doc_expectation` = Reference Contract 行の Required Observable Value、`details.actual_situation` = 計画したアプローチ、`details.why_cannot_implement` / `details.attempted_approaches[]` / `claude_recommendation` は表に従う。`N` は計画段階での違反を表す
|
|
219
|
+
- `Unknown`: その行を Investigation Notes に保留として記録し、TDDサイクルに進む。終了ゲートが全保留行を最終実装に対して再評価する
|
|
220
|
+
|
|
198
221
|
#### 参照の代表性チェック(実装中に随時適用)
|
|
199
222
|
|
|
200
223
|
パターンや依存をコードから採用する際、coding-standardsの「参照の代表性」を採用時点で適用する:
|
|
@@ -281,20 +304,8 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
281
304
|
"testsAdded": ["作成したテストファイルパス"],
|
|
282
305
|
"requiresTestReview": true,
|
|
283
306
|
"newTestsPassed": true,
|
|
284
|
-
"progressUpdated": {
|
|
285
|
-
|
|
286
|
-
"workPlan": "該当箇所更新済み",
|
|
287
|
-
"designDoc": "進捗セクション更新済み or N/A"
|
|
288
|
-
},
|
|
289
|
-
"runnableCheck": {
|
|
290
|
-
"level": "L1: 単体テスト / L2: 統合テスト / L3: E2Eテスト",
|
|
291
|
-
"executed": true,
|
|
292
|
-
"command": "実行したテストコマンド",
|
|
293
|
-
"result": "passed / failed / skipped",
|
|
294
|
-
"substance": "substantive | non_substantive | null (非テスト系の検証)",
|
|
295
|
-
"substanceIssue": "substantive または非テスト系の場合は null。non_substantive の場合は原因と位置を記載",
|
|
296
|
-
"reason": "テスト実行理由・確認内容"
|
|
297
|
-
},
|
|
307
|
+
"progressUpdated": {"taskFile": "完了項目5/8", "workPlan": "該当箇所更新済み", "designDoc": "進捗セクション更新済み or N/A"},
|
|
308
|
+
"runnableCheck": {"level": "L1: 単体テスト / L2: 統合テスト / L3: E2Eテスト", "executed": true, "command": "実行したテストコマンド", "result": "passed / failed / skipped", "substance": "substantive | non_substantive | null (非テスト系の検証)", "substanceIssue": "substantive または非テスト系の場合は null。non_substantive の場合は原因と位置を記載", "reason": "テスト実行理由・確認内容"},
|
|
298
309
|
"readyForQualityCheck": true,
|
|
299
310
|
"nextActions": "品質チェック工程による全体品質検証"
|
|
300
311
|
}
|
|
@@ -337,11 +348,7 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
337
348
|
"reason": "Out of scope file",
|
|
338
349
|
"taskName": "[タスク名]",
|
|
339
350
|
"escalation_type": "out_of_scope_file",
|
|
340
|
-
"details": {
|
|
341
|
-
"file_path": "[変更を試みたパス]",
|
|
342
|
-
"allowed_list": ["[Target Files / タスクファイル / 作業計画書 / Provides の和集合]"],
|
|
343
|
-
"modification_reason": "[なぜ変更を試みたか]"
|
|
344
|
-
},
|
|
351
|
+
"details": {"file_path": "[変更を試みたパス]", "allowed_list": ["[Target Files / タスクファイル / 作業計画書 / Provides の和集合]"], "modification_reason": "[なぜ変更を試みたか]"},
|
|
345
352
|
"user_decision_required": true,
|
|
346
353
|
"suggested_options": ["Target Files に追加してリトライ", "別タスクに分割", "アプローチを再検討"]
|
|
347
354
|
}
|
|
@@ -355,7 +362,9 @@ task_file パスはオーケストレータが渡す入力。プロンプトで
|
|
|
355
362
|
☐ Fix Mode: `requiredFixes` / `incompleteImplementations` の全項目が `changeSummary` に対応または個別エスカレーション済み
|
|
356
363
|
☐ 実装が Step 2 で記録した調査メモと整合している(調査対象が存在した場合)
|
|
357
364
|
☐ Binding Decisions の全 Compliance Check が最終実装に対して `Y` と評価され、その根拠が Investigation Notes に記録されている(タスクファイルに Binding Decisions セクションがある場合)。実装前チェックが通過していても、実装が計画したアプローチから逸脱している可能性があるため、ここで再評価する
|
|
365
|
+
☐ Reference Contracts の全 Compliance Check が最終実装に対して `Y` と評価され、その根拠が Investigation Notes に記録されている(タスクファイルに Reference Contracts セクションがある場合)。実装前チェックが通過していても、ここで再評価する
|
|
366
|
+
☐ テストが roundtrip を検証している — producer が出力する値を consumer が期待どおりの値へパースできる(タスクが作業計画書の Connection Map 由来の roundtrip チェックを伴う Boundary Context を持つ場合)
|
|
358
367
|
☐ テストエビデンスを引用している場合(タスクがテストを実行した場合)、`runnableCheck.substance` と `runnableCheck.substanceIssue` がフィールド仕様に従って設定されている
|
|
359
368
|
☐ 最終レスポンスが `status: "completed"` または `status: "escalation_needed"` の単一 JSON で、構造化レスポンス仕様のスキーマに一致する
|
|
360
369
|
|
|
361
|
-
**強制**: いずれかが未チェックの場合、構造化レスポンス仕様で定義される JSON 形式で `status: "escalation_needed"` を返却。未チェック項目が Binding Decisions の Compliance Check の場合は、`escalation_type: "binding_decision_violation"`(`phase: "exit_gate"
|
|
370
|
+
**強制**: いずれかが未チェックの場合、構造化レスポンス仕様で定義される JSON 形式で `status: "escalation_needed"` を返却。未チェック項目が Binding Decisions の Compliance Check の場合は、`escalation_type: "binding_decision_violation"`(`phase: "exit_gate"`)を使う。その他の未チェックのゲート項目には `escalation_type: "design_compliance_violation"` を使い、実装前マッピングと同じ粒度でエスカレーションレスポンス表に従って埋める: Reference Contracts の失敗では `details.design_doc_expectation` = Required Observable Value、`details.actual_situation` = 最終実装の振る舞い; roundtrip テストの欠落では `details.design_doc_expectation` = 要求される roundtrip(producer が出力する値を consumer が期待どおりの値へパースできること)、`details.actual_situation` = 欠落または失敗している roundtrip カバレッジ; いずれの場合も `details.why_cannot_implement` / `details.attempted_approaches[]` / `claude_recommendation` は表に従う。
|
|
@@ -33,7 +33,6 @@ ADR/Design Docの作成閾値はdocumentation-criteriaスキルに準拠。判
|
|
|
33
33
|
以下のサブセクションは並列の必須事項ではなく、4段階の直列ゲートを構成する: **Gate 0** Inputs & Standards → **Gate 1** Existing-State Analysis → **Gate 2** Design Decisions → **Gate 3** Impact Documentation。各ゲートを完了してから次のゲートに進むこと。各サブセクションには見出しに `[Gate N — ...]` の注記(適用条件を含む)が付き、ゲート順に記載されている。文書順に実行すること。
|
|
34
34
|
|
|
35
35
|
### 合意事項チェックリスト [Gate 0 — Required]
|
|
36
|
-
Design Doc作成の最初に必ず実施:
|
|
37
36
|
|
|
38
37
|
1. **ユーザーとの合意事項を箇条書きで列挙**
|
|
39
38
|
- スコープ(どのコンポーネント・機能を変更するか)
|
|
@@ -47,7 +46,6 @@ Design Doc作成の最初に必ず実施:
|
|
|
47
46
|
- [ ] 未反映の合意事項がある場合は理由を記載
|
|
48
47
|
|
|
49
48
|
### 標準の特定 [Gate 0 — Required]
|
|
50
|
-
既存状態の調査前に必ず実施:
|
|
51
49
|
|
|
52
50
|
1. **プロジェクト標準の特定**
|
|
53
51
|
- プロジェクト設定、ルールファイル、UI Spec / UI分析入力、既存のフロントエンドコードパターンをスキャンする
|
|
@@ -69,7 +67,6 @@ Design Doc作成の最初に必ず実施:
|
|
|
69
67
|
- 逸脱には文書化された根拠が必要
|
|
70
68
|
|
|
71
69
|
### 既存コード調査 [Gate 1 — Required]
|
|
72
|
-
Design Doc作成前に必ず実施:
|
|
73
70
|
|
|
74
71
|
1. **実装ファイルパスの確認**
|
|
75
72
|
- まず `Glob: src/**/*.tsx` で全体構造を把握
|
|
@@ -156,14 +153,13 @@ Fact Disposition Table は **構造的な既存事実** を設計に結び付け
|
|
|
156
153
|
|
|
157
154
|
4. **収束**(選定)
|
|
158
155
|
- 上記の解決優先順位を適用し、すべての確定要件をカバーする中で最小の面を持つ代替案を選ぶ。
|
|
159
|
-
- 選定が最小でない場合、ステップ1
|
|
156
|
+
- 選定が最小でない場合、ステップ1から、より小さい代替案では満たせない現要件を明記する。
|
|
160
157
|
- 「再利用可能」「将来対応」「実装が楽」「ユーザーが欲しがるかも」は主観的コストノート列のみに記載する(タイブレーカー扱い)。
|
|
161
158
|
|
|
162
159
|
5. **不採用案の記録**
|
|
163
160
|
- 不採用となった各代替案について、何だったか・なぜ不採用かを1〜2行で記録する。将来の反復や別エージェントによる再提案を避けるため、Design Doc に残す。
|
|
164
161
|
|
|
165
162
|
### 実装アプローチ決定 [Gate 2 — Required]
|
|
166
|
-
Design Doc作成時に必ず実施。
|
|
167
163
|
|
|
168
164
|
1. **アプローチ選択**(implementation-approach スキルの Phase 1-4 を実行し、選択理由を記録):
|
|
169
165
|
|
|
@@ -186,7 +182,6 @@ Design Doc作成時に必ず実施。
|
|
|
186
182
|
**早期検証ポイント** を定義する: 本格展開前に最初に何を、どうやって検証するか。
|
|
187
183
|
|
|
188
184
|
### 共通ADRプロセス [Gate 2 — Required]
|
|
189
|
-
Design Doc作成前に実施:
|
|
190
185
|
1. 共通技術領域(コンポーネントパターン、状態管理、エラーハンドリング、アクセシビリティ等)を特定
|
|
191
186
|
2. `docs/ADR/ADR-COMMON-*` を検索、なければ作成
|
|
192
187
|
3. Design Docの「前提となるADR」に記載
|
|
@@ -199,6 +194,9 @@ Design Doc作成前に実施:
|
|
|
199
194
|
### 状態遷移 [Gate 2 — Required when applicable]
|
|
200
195
|
ステートフルコンポーネントの状態定義と遷移を記載(loading、error、success states)。
|
|
201
196
|
|
|
197
|
+
### Serialized Boundary Contract [Gate 2 — Required when a value crosses a serialized boundary]
|
|
198
|
+
コンポーネントが**URLクエリ、ルートパラメータ、フォームポスト、ブラウザ/セッション/ローカルストレージ、生成された設定/成果物の値、または他のコンポーネント・ツール・バックエンドがパースする任意のエンコードされた値**を通じて値を出力または消費する場合、Design Docの**Field Propagation Map**に記録する: producerが出力する正確な**Serialized Format**と、**Consumer Parse Rule**(相手側がどうデコード/検証するか)。producerとconsumerは表現を取り決める必要がある。シリアライズ境界を値が越えない場合はスキップ。
|
|
199
|
+
|
|
202
200
|
### 統合ポイント分析 [Gate 3 — Required]
|
|
203
201
|
既存コンポーネントとのすべての統合ポイントを「## 統合ポイントマップ」セクションに記載する:
|
|
204
202
|
|
|
@@ -272,7 +270,7 @@ UI Specが存在する場合(`docs/ui-spec/{feature-name}-ui-spec.md`):
|
|
|
272
270
|
|
|
273
271
|
分析でカバーされていない領域、または `limitations` でフラグされた領域についてのみ追加調査を実施。
|
|
274
272
|
|
|
275
|
-
- **UI Analysis**(任意、フロントエンドレシピ)。
|
|
273
|
+
- **UI Analysis**(任意、フロントエンドレシピ)。UI解析工程によるUI事実収集JSON:
|
|
276
274
|
|
|
277
275
|
| 入力フィールド | 反映先 |
|
|
278
276
|
|---|---|
|
|
@@ -293,13 +291,10 @@ UI Specが存在する場合(`docs/ui-spec/{feature-name}-ui-spec.md`):
|
|
|
293
291
|
- 各々のテンプレート(`template-en.md`)に従って作成
|
|
294
292
|
- ADRは既存番号を確認して max+1、初期ステータスは「Proposed」
|
|
295
293
|
|
|
296
|
-
##
|
|
297
|
-
|
|
298
|
-
含む: 決定事項、根拠、原則的な指針(例: 「ロジック再利用にカスタムフックを使用」 ✓、「Phase 1で実装」 ✗)
|
|
299
|
-
含まない: スケジュール、実装手順、具体的コード
|
|
294
|
+
## 出力ルール
|
|
300
295
|
|
|
301
|
-
|
|
302
|
-
|
|
296
|
+
- ファイル出力は即座に実行(実行時点で承認済み)。
|
|
297
|
+
- ADRは決定事項、根拠、原則的な指針を含む(例: 「ロジック再利用にカスタムフックを使用」 ✓、「Phase 1で実装」 ✗)。スケジュール、実装手順、具体的コードは含まない。
|
|
303
298
|
|
|
304
299
|
## 重要設計原則
|
|
305
300
|
|
|
@@ -32,7 +32,6 @@ ADR/Design Docの作成閾値はdocumentation-criteriaスキルに準拠。判
|
|
|
32
32
|
以下のサブセクションは並列の必須事項ではなく、4段階の直列ゲートを構成する: **Gate 0** Inputs & Standards → **Gate 1** Existing-State Analysis → **Gate 2** Design Decisions → **Gate 3** Impact Documentation。各ゲートを完了してから次のゲートに進むこと。各サブセクションには見出しに `[Gate N — ...]` の注記(適用条件を含む)が付き、ゲート順に記載されている。文書順に実行すること。
|
|
33
33
|
|
|
34
34
|
### 合意事項チェックリスト [Gate 0 — Required]
|
|
35
|
-
Design Doc作成の最初に必ず実施:
|
|
36
35
|
|
|
37
36
|
1. **ユーザーとの合意事項を箇条書きで列挙**
|
|
38
37
|
- スコープ(何を変更するか)
|
|
@@ -46,7 +45,6 @@ Design Doc作成の最初に必ず実施:
|
|
|
46
45
|
- [ ] 未反映の合意事項がある場合は理由を記載
|
|
47
46
|
|
|
48
47
|
### 標準の特定 [Gate 0 — Required]
|
|
49
|
-
調査開始前に必ず実施:
|
|
50
48
|
|
|
51
49
|
1. **プロジェクト基準の特定**
|
|
52
50
|
- プロジェクト設定、ルールファイル、既存コードパターンをスキャン
|
|
@@ -69,7 +67,6 @@ Design Doc作成の最初に必ず実施:
|
|
|
69
67
|
- 逸脱する場合は根拠を明記
|
|
70
68
|
|
|
71
69
|
### 既存コード調査 [Gate 1 — Required]
|
|
72
|
-
Design Doc作成前に必ず実施:
|
|
73
70
|
|
|
74
71
|
1. **実装ファイルパスの確認**
|
|
75
72
|
- まず `Glob: src/**/*.ts` で全体構造を把握
|
|
@@ -167,14 +164,13 @@ Fact Disposition Table は **構造的な既存事実** を設計に結び付け
|
|
|
167
164
|
|
|
168
165
|
4. **収束**(選定)
|
|
169
166
|
- 上記の解決優先順位を適用し、すべての確定要件をカバーする中で最小の面を持つ代替案を選ぶ。
|
|
170
|
-
- 選定が最小でない場合、ステップ1
|
|
167
|
+
- 選定が最小でない場合、ステップ1から、より小さい代替案では満たせない現要件を明記する。
|
|
171
168
|
- 「便利」「将来対応」「実装が楽」「ユーザーが欲しがるかも」は主観的コストノート列のみに記載する(タイブレーカー扱い)。
|
|
172
169
|
|
|
173
170
|
5. **不採用案の記録**
|
|
174
171
|
- 不採用となった各代替案について、何だったか・なぜ不採用かを1〜2行で記録する。将来の反復や別エージェントによる再提案を避けるため、Design Doc に残す。
|
|
175
172
|
|
|
176
173
|
### 実装アプローチ決定 [Gate 2 — Required]
|
|
177
|
-
Design Doc作成時に必ず実施。
|
|
178
174
|
|
|
179
175
|
1. **アプローチ選択**(implementation-approach スキルの Phase 1-4 を実行し、選択理由を記録):
|
|
180
176
|
|
|
@@ -198,7 +194,6 @@ Design Doc作成時に必ず実施。
|
|
|
198
194
|
**早期検証ポイント** を定義する: 本格展開前に最初に何を、どうやって検証するか。置換/変更の場合、デフォルトは少なくとも1つの代表的なケースでの出力比較。例外: 主要リスクが振る舞いの同等性以外にある場合(例: スキーマ互換性、統合コントラクト)は代替の検証対象を明記し、出力比較を後段に回す理由を記録する。
|
|
199
195
|
|
|
200
196
|
### 共通ADRプロセス [Gate 2 — Required]
|
|
201
|
-
Design Doc作成前に実施:
|
|
202
197
|
1. 共通技術領域(ログ、エラー処理、型定義、API設計等)を特定
|
|
203
198
|
2. `docs/ADR/ADR-COMMON-*` を検索、なければ作成
|
|
204
199
|
3. Design Doc の「前提となるADR」に記載
|
|
@@ -246,6 +241,7 @@ Design Doc作成時に必ず含める:
|
|
|
246
241
|
新規または変更されたフィールドがコンポーネント境界を越える場合:
|
|
247
242
|
|
|
248
243
|
各境界でのフィールドのステータス(preserved / transformed / dropped)を根拠付きで記録。
|
|
244
|
+
境界が**シリアライズ**されている場合 — 値がエンコードされ、クエリ文字列、CLI引数、環境変数、設定エントリ、メッセージ/キューのペイロード、ストレージキー、ファイルなどの媒体を介して再パースされる — さらに**Serialized Format**(producerが出力する正確な表現)と**Consumer Parse Rule**(consumerがどうデコード/検証するか)を記録し、producerとconsumerで表現を取り決める。インメモリのフィールド受け渡しでは両方を省略する。
|
|
249
245
|
フィールドが境界を越えない場合はスキップ。
|
|
250
246
|
|
|
251
247
|
### インターフェース変更影響分析 [Gate 3 — Required]
|
|
@@ -290,13 +286,10 @@ Design Doc作成時に必ず含める:
|
|
|
290
286
|
- 各々のテンプレート(`template-en.md`)に従って作成
|
|
291
287
|
- ADRは既存番号を確認して max+1、初期ステータスは「Proposed」
|
|
292
288
|
|
|
293
|
-
##
|
|
289
|
+
## 出力ルール
|
|
294
290
|
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
## 出力ポリシー
|
|
299
|
-
ファイル出力は即座に実行(実行時点で承認済み)。
|
|
291
|
+
- ファイル出力は即座に実行(実行時点で承認済み)。
|
|
292
|
+
- ADRは決定事項、根拠、原則的な指針を含む(例: 「依存性注入を使用」)。スケジュール、実装手順、具体的コードは含まない。
|
|
300
293
|
|
|
301
294
|
## 重要設計原則
|
|
302
295
|
|
|
@@ -154,7 +154,7 @@ skills: frontend-typescript-rules, frontend-technical-spec, project-context
|
|
|
154
154
|
入力要件を踏まえ、修正が必要になる可能性が最も高いファイルを列挙した`candidateWriteSet[]`を生成する。各ファイルについて:
|
|
155
155
|
- パス
|
|
156
156
|
- 修正される可能性が高い理由(`focusAreas[]`エントリ、または`componentStructure` / `cssLayout` / `i18n`内の具体的な事実へのリンク)
|
|
157
|
-
- 信頼度: `high
|
|
157
|
+
- 信頼度: `high`(要件で直接指定されている、または変更箇所が明確に唯一)/ `medium`(少数の候補の1つ)/ `low`(投機的、変更不要の可能性あり)
|
|
158
158
|
|
|
159
159
|
## 出力フォーマット
|
|
160
160
|
|
|
@@ -165,142 +165,43 @@ skills: frontend-typescript-rules, frontend-technical-spec, project-context
|
|
|
165
165
|
|
|
166
166
|
```json
|
|
167
167
|
{
|
|
168
|
-
"analysisScope": {
|
|
169
|
-
"filesAnalyzed": ["path/to/component.tsx"],
|
|
170
|
-
"stylesAnalyzed": ["path/to/styles.module.css"],
|
|
171
|
-
"uiConventions": {
|
|
172
|
-
"componentExtension": ".tsx",
|
|
173
|
-
"styleStrategy": "css-modules|vanilla-css|css-in-js|utility-classes",
|
|
174
|
-
"storybook": true,
|
|
175
|
-
"testRunner": "vitest|jest|other"
|
|
176
|
-
}
|
|
177
|
-
},
|
|
168
|
+
"analysisScope": {"filesAnalyzed": ["path/to/component.tsx"], "stylesAnalyzed": ["path/to/styles.module.css"], "uiConventions": {"componentExtension": ".tsx", "styleStrategy": "css-modules|vanilla-css|css-in-js|utility-classes", "storybook": true, "testRunner": "vitest|jest|other"}},
|
|
178
169
|
"externalResources": {
|
|
179
170
|
"status": "fetched|partial|not_recorded",
|
|
180
|
-
"designOrigin": {
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
},
|
|
185
|
-
"designSystem": {
|
|
186
|
-
"fetch_status": "fetched|mcp_unavailable|skipped|not_applicable",
|
|
187
|
-
"accessMethod": "...",
|
|
188
|
-
"fetched_summary": "components catalogued, tokens captured, anti-pattern identifiers"
|
|
189
|
-
},
|
|
190
|
-
"guidelines": {
|
|
191
|
-
"fetch_status": "fetched|skipped|not_applicable",
|
|
192
|
-
"accessMethod": "...",
|
|
193
|
-
"fetched_summary": "rule categories captured (CSS, accessibility, i18n, etc.)"
|
|
194
|
-
},
|
|
195
|
-
"visualVerification": {
|
|
196
|
-
"fetch_status": "available|mcp_unavailable|not_applicable",
|
|
197
|
-
"accessMethod": "...",
|
|
198
|
-
"notes": "how rendered output is verified during implementation"
|
|
199
|
-
}
|
|
171
|
+
"designOrigin": {"fetch_status": "fetched|mcp_unavailable|skipped|not_applicable", "accessMethod": "MCP name | URL | file path | existing-implementation-only", "fetched_summary": "brief description of fetched content (e.g., screen names, frame ids, token snapshot)"},
|
|
172
|
+
"designSystem": {"fetch_status": "fetched|mcp_unavailable|skipped|not_applicable", "accessMethod": "...", "fetched_summary": "components catalogued, tokens captured, anti-pattern identifiers"},
|
|
173
|
+
"guidelines": {"fetch_status": "fetched|skipped|not_applicable", "accessMethod": "...", "fetched_summary": "rule categories captured (CSS, accessibility, i18n, etc.)"},
|
|
174
|
+
"visualVerification": {"fetch_status": "available|mcp_unavailable|not_applicable", "accessMethod": "...", "notes": "how rendered output is verified during implementation"}
|
|
200
175
|
},
|
|
201
176
|
"componentStructure": [
|
|
202
|
-
{
|
|
203
|
-
"name": "ComponentName",
|
|
204
|
-
"filePath": "path/to/file:lineNumber",
|
|
205
|
-
"propsInterface": "name and brief shape",
|
|
206
|
-
"topLevelElement": "tag or component name",
|
|
207
|
-
"domOrder": ["child1", "child2", "child3"],
|
|
208
|
-
"conditionalBranches": [
|
|
209
|
-
{"predicate": "condition expression", "renderedSubtree": "brief description"}
|
|
210
|
-
],
|
|
211
|
-
"callSites": ["path/to/consumer:line"]
|
|
212
|
-
}
|
|
177
|
+
{"name": "ComponentName", "filePath": "path/to/file:lineNumber", "propsInterface": "name and brief shape", "topLevelElement": "tag or component name", "domOrder": ["child1", "child2", "child3"], "conditionalBranches": [{"predicate": "condition expression", "renderedSubtree": "brief description"}], "callSites": ["path/to/consumer:line"]}
|
|
213
178
|
],
|
|
214
179
|
"propsPatterns": [
|
|
215
|
-
{
|
|
216
|
-
"component": "ComponentName",
|
|
217
|
-
"callSite": "path/to/file:line",
|
|
218
|
-
"props": {"variant": "primary", "size": "md"},
|
|
219
|
-
"computedProps": ["onClick (useCallback)"],
|
|
220
|
-
"groupKey": "primary-md"
|
|
221
|
-
}
|
|
180
|
+
{"component": "ComponentName", "callSite": "path/to/file:line", "props": {"variant": "primary", "size": "md"}, "computedProps": ["onClick (useCallback)"], "groupKey": "primary-md"}
|
|
222
181
|
],
|
|
223
182
|
"cssLayout": [
|
|
224
|
-
{
|
|
225
|
-
"filePath": "path/to/styles.module.css",
|
|
226
|
-
"classNamingConvention": "camelCase|kebab-case|BEM",
|
|
227
|
-
"baseClass": "root",
|
|
228
|
-
"layouts": [
|
|
229
|
-
{
|
|
230
|
-
"selector": ".className",
|
|
231
|
-
"display": "flex|grid|block",
|
|
232
|
-
"direction": "row|column|grid-template",
|
|
233
|
-
"gap": "8px|none",
|
|
234
|
-
"wrap": "wrap|nowrap|absent",
|
|
235
|
-
"logicalProperties": true,
|
|
236
|
-
"stateSelectors": ["[data-state=active]", "[aria-selected=true]"]
|
|
237
|
-
}
|
|
238
|
-
],
|
|
239
|
-
"responsiveBreakpoints": ["768px", "1024px"]
|
|
240
|
-
}
|
|
183
|
+
{"filePath": "path/to/styles.module.css", "classNamingConvention": "camelCase|kebab-case|BEM", "baseClass": "root", "layouts": [{"selector": ".className", "display": "flex|grid|block", "direction": "row|column|grid-template", "gap": "8px|none", "wrap": "wrap|nowrap|absent", "logicalProperties": true, "stateSelectors": ["[data-state=active]", "[aria-selected=true]"]}], "responsiveBreakpoints": ["768px", "1024px"]}
|
|
241
184
|
],
|
|
242
185
|
"stateDisplay": [
|
|
243
|
-
{
|
|
244
|
-
"component": "ComponentName",
|
|
245
|
-
"states": [
|
|
246
|
-
{"name": "loading|empty|partial|error|ready|disabled", "trigger": "what causes this state", "renders": "brief description"}
|
|
247
|
-
],
|
|
248
|
-
"unsupportedStates": ["states the component does not currently express"]
|
|
249
|
-
}
|
|
186
|
+
{"component": "ComponentName", "states": [{"name": "loading|empty|partial|error|ready|disabled", "trigger": "what causes this state", "renders": "brief description"}], "unsupportedStates": ["states the component does not currently express"]}
|
|
250
187
|
],
|
|
251
188
|
"displayConditions": [
|
|
252
|
-
{
|
|
253
|
-
"component": "ComponentName",
|
|
254
|
-
"condition": "feature_flag|role|route|region|tenant|page_context",
|
|
255
|
-
"predicateLocation": "path/to/file:line",
|
|
256
|
-
"predicate": "expression",
|
|
257
|
-
"gatedSubtree": "brief description"
|
|
258
|
-
}
|
|
189
|
+
{"component": "ComponentName", "condition": "feature_flag|role|route|region|tenant|page_context", "predicateLocation": "path/to/file:line", "predicate": "expression", "gatedSubtree": "brief description"}
|
|
259
190
|
],
|
|
260
|
-
"i18n": {
|
|
261
|
-
"format": "csv|json|code-catalog|other",
|
|
262
|
-
"structuralConventions": {"csvColumns": 2, "trailingComma": false, "jsonNestingDepth": 1},
|
|
263
|
-
"keyNamingConvention": "pattern with examples",
|
|
264
|
-
"locales": ["ja-JP", "en-US"],
|
|
265
|
-
"localeGaps": ["keys present in one locale only"],
|
|
266
|
-
"generatedTypings": {"command": "generator command", "outputPath": "path/to/output"}
|
|
267
|
-
},
|
|
191
|
+
"i18n": {"format": "csv|json|code-catalog|other", "structuralConventions": {"csvColumns": 2, "trailingComma": false, "jsonNestingDepth": 1}, "keyNamingConvention": "pattern with examples", "locales": ["ja-JP", "en-US"], "localeGaps": ["keys present in one locale only"], "generatedTypings": {"command": "generator command", "outputPath": "path/to/output"}},
|
|
268
192
|
"accessibility": [
|
|
269
|
-
{
|
|
270
|
-
"component": "ComponentName",
|
|
271
|
-
"ariaAttributes": ["role=button", "aria-label fed by prop accessibleName"],
|
|
272
|
-
"keyboardHandling": "Enter and Space mapped to onClick",
|
|
273
|
-
"focusStyling": "focus-visible outline",
|
|
274
|
-
"testCoverage": "axe checks present|absent"
|
|
275
|
-
}
|
|
193
|
+
{"component": "ComponentName", "ariaAttributes": ["role=button", "aria-label fed by prop accessibleName"], "keyboardHandling": "Enter and Space mapped to onClick", "focusStyling": "focus-visible outline", "testCoverage": "axe checks present|absent"}
|
|
276
194
|
],
|
|
277
195
|
"generatedArtifacts": [
|
|
278
|
-
{
|
|
279
|
-
"kind": "css-module-typings|message-catalog-typings|route-typings|other",
|
|
280
|
-
"command": "generator command",
|
|
281
|
-
"trigger": "on *.module.css change|manual|other",
|
|
282
|
-
"consumers": ["typecheck", "test", "build", "runtime"]
|
|
283
|
-
}
|
|
196
|
+
{"kind": "css-module-typings|message-catalog-typings|route-typings|other", "command": "generator command", "trigger": "on *.module.css change|manual|other", "consumers": ["typecheck", "test", "build", "runtime"]}
|
|
284
197
|
],
|
|
285
198
|
"focusAreas": [
|
|
286
|
-
{
|
|
287
|
-
"fact_id": "src/components/Card/Card.tsx:Card",
|
|
288
|
-
"area": "Brief UI area name",
|
|
289
|
-
"evidence": "componentStructure[name=Card] | cssLayout[selector=.root] | propsPatterns[groupKey=...] | externalResources.designOrigin",
|
|
290
|
-
"factsToAddress": "Concrete UI facts the designer or implementer must respect",
|
|
291
|
-
"risk": "What inconsistency results if these facts are omitted"
|
|
292
|
-
}
|
|
199
|
+
{"fact_id": "src/components/Card/Card.tsx:Card", "area": "Brief UI area name", "evidence": "componentStructure[name=Card] | cssLayout[selector=.root] | propsPatterns[groupKey=...] | externalResources.designOrigin", "factsToAddress": "Concrete UI facts the designer or implementer must respect", "risk": "What inconsistency results if these facts are omitted"}
|
|
293
200
|
],
|
|
294
201
|
"candidateWriteSet": [
|
|
295
|
-
{
|
|
296
|
-
"path": "src/components/Card/Card.tsx",
|
|
297
|
-
"reasonRef": "focusAreas[fact_id=src/components/Card/Card.tsx:Card]",
|
|
298
|
-
"confidence": "high|medium|low"
|
|
299
|
-
}
|
|
202
|
+
{"path": "src/components/Card/Card.tsx", "reasonRef": "focusAreas[fact_id=src/components/Card/Card.tsx:Card]", "confidence": "high|medium|low"}
|
|
300
203
|
],
|
|
301
|
-
"limitations": [
|
|
302
|
-
"Areas the analysis could not reach with confidence"
|
|
303
|
-
]
|
|
204
|
+
"limitations": ["Areas the analysis could not reach with confidence"]
|
|
304
205
|
}
|
|
305
206
|
```
|
|
306
207
|
|
|
@@ -15,7 +15,7 @@ skills: documentation-criteria, frontend-typescript-rules, project-context
|
|
|
15
15
|
|
|
16
16
|
## 主な責務
|
|
17
17
|
|
|
18
|
-
1. PRD
|
|
18
|
+
1. PRDの受入条件(AC)を分析し、画面・状態・コンポーネントにマッピング
|
|
19
19
|
2. プロトタイプコードから画面構造・遷移・インタラクションパターンを抽出(提供時)
|
|
20
20
|
3. ui-spec-templateに従って包括的なUI Specを作成
|
|
21
21
|
4. 状態×表示マトリクスを含むコンポーネント分解を定義
|
|
@@ -25,17 +25,17 @@ skills: documentation-criteria, frontend-typescript-rules, project-context
|
|
|
25
25
|
## 必要情報
|
|
26
26
|
|
|
27
27
|
- **PRD**: PRDドキュメントパス。この機能のPRDが存在する場合に使用する。PRDが存在しない場合、呼び出し側はPRDの代わりに、ユーザー要件と確認済みの設計スコープをUI Specの土台として渡す。
|
|
28
|
-
- **codebase_analysis**:
|
|
28
|
+
- **codebase_analysis**: コードベース分析JSON(呼び出し側が渡す。特にPRDがない場合)。UI Specが尊重すべき既存コンポーネント・データ・制約を特定する。
|
|
29
29
|
- **プロトタイプコードパス**: プロトタイプコードへのパス(任意、`docs/ui-spec/assets/{feature-name}/`に配置)
|
|
30
30
|
- **既存フロントエンドコードベース**: 自動的に調査
|
|
31
|
-
- **ui_analysis**:
|
|
31
|
+
- **ui_analysis**: UI事実収集JSON(任意)。提供された場合、`componentStructure`・`propsPatterns`・`cssLayout`・`stateDisplay`・`externalResources`を、コンポーネント分解・状態×表示マトリクス・再利用可能コンポーネントの特定の主要な根拠として使う — エージェントが本来自前で行うコードベース調査を軽減する。
|
|
32
32
|
|
|
33
33
|
## UI Spec作成前の必須プロセス
|
|
34
34
|
|
|
35
35
|
### Step 1: PRD分析
|
|
36
36
|
|
|
37
37
|
1. **PRDの読み込みと理解**
|
|
38
|
-
- AC ID
|
|
38
|
+
- AC IDを含む全ACを抽出
|
|
39
39
|
- ユーザーストーリーと要件から暗示される画面/ビューを特定
|
|
40
40
|
- PRDのアクセシビリティ要件とUI品質指標を記録
|
|
41
41
|
|
|
@@ -85,7 +85,7 @@ skills: documentation-criteria, frontend-typescript-rules, project-context
|
|
|
85
85
|
- AC IDにリンクしたインタラクション定義(EARS形式)
|
|
86
86
|
- 既存コンポーネント再利用マップ
|
|
87
87
|
- デザイントークン(既存コードベースから)
|
|
88
|
-
-
|
|
88
|
+
- ビジュアルAC
|
|
89
89
|
- アクセシビリティ要件(キーボード、スクリーンリーダー、コントラスト)
|
|
90
90
|
3. **出力先**: `docs/ui-spec/{feature-name}-ui-spec.md`
|
|
91
91
|
|
|
@@ -105,13 +105,13 @@ skills: documentation-criteria, frontend-typescript-rules, project-context
|
|
|
105
105
|
- [ ] プロトタイプ提供時: プロトタイプが`docs/ui-spec/assets/`に配置されている
|
|
106
106
|
- [ ] 未確定事項の全TBDに担当者と期限がある
|
|
107
107
|
- [ ] UI Specの全要件がPRD要件と整合している
|
|
108
|
-
- [ ] **コンポーネント見出しの一意性**: 全コンポーネントが、UI Spec内でテキストとして一意なセクション見出しの下に記述されている。形式は`## Component: [ComponentName]`(画面の下にネストする場合は`### Component: [ComponentName]
|
|
108
|
+
- [ ] **コンポーネント見出しの一意性**: 全コンポーネントが、UI Spec内でテキストとして一意なセクション見出しの下に記述されている。形式は`## Component: [ComponentName]`(画面の下にネストする場合は`### Component: [ComponentName]`)。下流の工程はコンポーネントを見出しテキストの完全一致で参照するため、重複や言い換えがあると伝播チェーンが破綻する。
|
|
109
109
|
- **曖昧性回避ルール**: 2つのコンポーネントが同じベース名を持つ場合(例: 同じ`AlertCard`をバナーバリアントとインラインバリアントとして描画する)、各見出しを一意にするために括弧付きの修飾子を付加する: `Component: AlertCard (Banner variant)` と `Component: AlertCard (Inline variant)`。最終チェックで一意性を検証する: すべての`Component: `見出しを抽出し、重複がゼロであることを確認する
|
|
110
110
|
|
|
111
111
|
## 重要な設計原則
|
|
112
112
|
|
|
113
113
|
1. **プロトタイプは参考であり正式な仕様ではない**: UI Specが正式な仕様。プロトタイプコードは視覚的・動作的な参考資料としての添付。
|
|
114
|
-
2. **AC駆動設計**: すべてのインタラクションと状態はPRD
|
|
114
|
+
2. **AC駆動設計**: すべてのインタラクションと状態はPRDのACに遡れること。
|
|
115
115
|
3. **状態の網羅性**: すべてのコンポーネントはloading、empty、error状態の動作を定義すること(正常系だけでなく)。
|
|
116
116
|
4. **再利用優先**: 新規コンポーネントを提案する前に既存を確認。判定を記録する。
|
|
117
117
|
5. **テスト可能なインタラクション**: インタラクション定義はテストケースを導出できる具体性を持つこと(ただしテスト実装はUI Specのスコープ外)。
|