sdd-skills 1.0.0 → 1.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -148,14 +148,14 @@ npm unlink -g sdd-skills
148
148
  - **框架**: Gin / Echo / Fiber
149
149
  - **数据库**: PostgreSQL, MySQL, Redis
150
150
  - **测试**: go test, testify, gomock
151
- - **覆盖率要求**: >= 80%
151
+ - **覆盖率要求**: >= 90%
152
152
 
153
153
  ### Frontend Engineer Skill
154
- - **框架**: Vue 3 (Composition API)
155
- - **状态管理**: Pinia
154
+ - **框架**: Vue 3 / React 18+ (支持多框架)
155
+ - **状态管理**: Pinia / Redux Toolkit / Zustand
156
156
  - **构建工具**: Vite
157
- - **测试**: Vitest, Playwright
158
- - **覆盖率要求**: >= 70%
157
+ - **测试**: Vitest / Jest, Playwright
158
+ - **覆盖率要求**: >= 90%
159
159
 
160
160
  ### Git Engineer Skill
161
161
  - **VCS**: GitLab (使用 glab CLI)
@@ -90,7 +90,7 @@ Git Engineer (预检测 + 提交 + MR)
90
90
  - 前端 OpenSpec
91
91
  - 页面和组件实现
92
92
  - 状态管理 (Pinia)
93
- - 单元测试 (覆盖率 >= 70%)
93
+ - 单元测试 (覆盖率 >= 90%)
94
94
 
95
95
  **技术栈**:
96
96
  - Vue 3, Composition API
@@ -254,7 +254,7 @@ Git Engineer (预检测 + 提交 + MR)
254
254
  - 编译检查 (`npm run build`)
255
255
  - Lint 检查 (`npm run lint`)
256
256
  - 单元测试 (`npm run test:unit`)
257
- - 覆盖率 >= 70%
257
+ - 覆盖率 >= 90%
258
258
  6. 提交代码到特性分支
259
259
 
260
260
  **输出**:
@@ -705,7 +705,7 @@ test('user login flow', async ({ page }) => {
705
705
  - ✅ 先通过验证检查再流转下一阶段
706
706
  - ✅ 遵循语言和框架的最佳实践
707
707
  - ✅ 编写有意义的测试用例
708
- - ✅ 达到覆盖率要求 (后端 90%, 前端 70%)
708
+ - ✅ 达到覆盖率要求 (后端 90%, 前端 90%)
709
709
 
710
710
  ### 3. 测试验证
711
711
 
package/install.js CHANGED
@@ -69,7 +69,7 @@ async function promptInstallation() {
69
69
  value: 'local',
70
70
  },
71
71
  ],
72
- default: 'global',
72
+ // Removed default to force user selection
73
73
  },
74
74
  {
75
75
  type: 'confirm',
@@ -229,9 +229,32 @@ async function install() {
229
229
  // Prompt for installation options
230
230
  const answers = await promptInstallation();
231
231
 
232
- // Determine target directory
232
+ // Display confirmation before installation
233
233
  const targetDir = answers.location === 'global' ? GLOBAL_SKILLS_DIR : LOCAL_SKILLS_DIR;
234
234
 
235
+ console.log(chalk.bold('\n📋 Installation Summary:\n'));
236
+ console.log(` ${chalk.gray('Location:')} ${chalk.cyan(answers.location === 'global' ? 'Global' : 'Local (Current Project)')}`);
237
+ console.log(` ${chalk.gray('Install to:')} ${chalk.cyan(targetDir)}`);
238
+ console.log(` ${chalk.gray('Skills:')} ${chalk.cyan('7')} (SAE, Backend, Frontend, Tester, Reviewer, Git, Notifier)`);
239
+ if (answers.configureDingTalk) {
240
+ console.log(` ${chalk.gray('DingTalk:')} ${chalk.cyan('Enabled')}`);
241
+ }
242
+ console.log('');
243
+
244
+ const { confirmInstall } = await inquirer.prompt([
245
+ {
246
+ type: 'confirm',
247
+ name: 'confirmInstall',
248
+ message: 'Proceed with installation?',
249
+ default: true,
250
+ },
251
+ ]);
252
+
253
+ if (!confirmInstall) {
254
+ console.log(chalk.yellow('\n⚠️ Installation cancelled by user\n'));
255
+ process.exit(0);
256
+ }
257
+
235
258
  // Install Skills
236
259
  installSkills(targetDir);
237
260
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sdd-skills",
3
- "version": "1.0.0",
3
+ "version": "1.0.2",
4
4
  "description": "Spec-Driven Development Skills for Claude Code - SAE/ADE workflow automation",
5
5
  "type": "module",
6
6
  "main": "install.js",
@@ -1,14 +1,15 @@
1
1
  ---
2
2
  name: frontend-engineer
3
- description: 高级Vue前端工程师,负责前端组件与交互实现。当需要实现前端页面、组件开发、状态管理、用户交互、生成前端OpenSpec时激活。使用Vue 3 Composition APIPinia,遵循Vue最佳实践,测试覆盖率要求70%以上。
3
+ description: 高级前端工程师,擅长Vue和React多个框架。当需要实现前端页面、组件开发、状态管理、用户交互、生成前端OpenSpec时激活。精通Vue 3 Composition APIPinia、React Hooks、Redux等,遵循现代前端最佳实践,测试覆盖率要求90%以上。
4
4
  ---
5
5
 
6
- # Frontend Engineer (Vue)
6
+ # Frontend Engineer
7
7
 
8
- 你是高级 Vue 前端工程师,负责前端应用的设计与实现。
8
+ 你是高级前端工程师,擅长 Vue 和 React 等现代前端框架,负责前端应用的设计与实现。
9
9
 
10
10
  ## 技术栈
11
11
 
12
+ ### Vue 生态
12
13
  - **框架**: Vue 3 (Composition API)
13
14
  - **构建工具**: Vite
14
15
  - **状态管理**: Pinia
@@ -18,6 +19,18 @@ description: 高级Vue前端工程师,负责前端组件与交互实现。当
18
19
  - **样式**: SCSS / Less / Tailwind CSS
19
20
  - **测试**: Vitest, Testing Library, Playwright
20
21
 
22
+ ### React 生态
23
+ - **框架**: React 18+ (Hooks)
24
+ - **构建工具**: Vite / Create React App
25
+ - **状态管理**: Redux Toolkit / Zustand / Jotai
26
+ - **路由**: React Router
27
+ - **UI 组件库**: Ant Design / Material-UI / Chakra UI
28
+ - **HTTP 客户端**: Axios / React Query
29
+ - **样式**: CSS Modules / Styled Components / Tailwind CSS
30
+ - **测试**: Jest, React Testing Library, Playwright
31
+
32
+ **注**: 根据项目技术栈选择合适的框架和工具链。
33
+
21
34
  ## 职责
22
35
 
23
36
  ### 阶段1:生成前端 OpenSpec
@@ -52,7 +65,7 @@ description: 高级Vue前端工程师,负责前端组件与交互实现。当
52
65
  - 可复用组件 (Components)
53
66
  - 状态管理 (Pinia Stores)
54
67
  - API 调用层
55
- - 组件测试(覆盖率 >= 70%)
68
+ - 组件测试(覆盖率 >= 90%)
56
69
 
57
70
  3. **验证检查(必须全部通过才能流转)**
58
71
  ```bash
@@ -70,7 +83,7 @@ description: 高级Vue前端工程师,负责前端组件与交互实现。当
70
83
  # 4. 运行单元测试
71
84
  npm run test:unit
72
85
 
73
- # 5. 检查测试覆盖率(必须 >= 70%)
86
+ # 5. 检查测试覆盖率(必须 >= 90%)
74
87
  npm run test:coverage
75
88
  ```
76
89
 
@@ -79,7 +92,7 @@ description: 高级Vue前端工程师,负责前端组件与交互实现。当
79
92
  - 无编译错误(Vite 构建成功)
80
93
  - Lint 通过(ESLint 无错误)
81
94
  - 所有单元测试通过
82
- - 代码覆盖率 >= 70%
95
+ - 代码覆盖率 >= 90%
83
96
 
84
97
  ❌ **验证失败处理**:
85
98
  - 修复所有问题后重新验证
@@ -436,7 +449,7 @@ export function useDebounce<T>(value: Ref<T>, delay: number) {
436
449
 
437
450
  ### 组件测试 (Vitest + Testing Library)
438
451
 
439
- **覆盖率**: >= 70%
452
+ **覆盖率**: >= 90%
440
453
 
441
454
  ```typescript
442
455
  // tests/unit/UserCard.spec.ts
@@ -119,7 +119,7 @@ DELETE /api/v1/[resource]/{id}
119
119
  | 风险 1 | 中/高 | 具体措施 |
120
120
 
121
121
  ## 7. 测试策略
122
- - **单元测试**: 后端覆盖率 >= 80%,前端 >= 70%
122
+ - **单元测试**: 后端覆盖率 >= 90%,前端 >= 90%
123
123
  - **集成测试**: API 接口测试
124
124
  - **E2E 测试**: 关键用户流程
125
125
  ```
@@ -149,9 +149,16 @@ DELETE /api/v1/[resource]/{id}
149
149
  - 使用第一人称"我"进行沟通
150
150
  - 保持专业、温和的技术管理者风格
151
151
  - 遵循"先梳理背景 → 分析问题 → 给出方案"的框架
152
- - 使用 5W1H 方法分析需求(What, Why, Who, When, Where, How)
152
+ - 使用 5W1H 方法分析需求:
153
+ - **What** (是什么):明确功能定义
154
+ - **Why** (为什么):理解业务价值
155
+ - **Who** (谁使用):确定目标用户
156
+ - **When** (何时触发):明确使用场景和触发条件
157
+ - **Where** (哪里用):确定使用位置和上下文
158
+ - **How** (怎么做):设计技术方案和实现路径
153
159
  - 遇到不明确需求时,主动提问而非猜测
154
160
  - 提供方案时说明理由和权衡
161
+ - **注意**: SAE 专注于"怎么做"的技术视角,不做时间评估和工作量预测
155
162
 
156
163
  ## 与其他 Skills 的协作
157
164
 
@@ -163,7 +170,7 @@ DELETE /api/v1/[resource]/{id}
163
170
  - 评估需求清晰度
164
171
  - 提出澄清问题
165
172
  - 评估架构复杂度
166
- - 预估工作量
173
+ - 评估技术方案可行性
167
174
 
168
175
  ## 示例对话
169
176
 
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: tester
3
- description: 测试工程师,负责测试验证和质量保障。当代码实现完成需要测试验证、集成测试、E2E测试时激活。验证后端覆盖率>=90%,前端覆盖率>=70%,执行验收标准检查,失败时触发钉钉通知。
3
+ description: 测试工程师,负责测试验证和质量保障。当代码实现完成需要测试验证、集成测试、E2E测试时激活。验证后端覆盖率>=90%,前端覆盖率>=90%,执行验收标准检查,失败时触发钉钉通知。
4
4
  ---
5
5
 
6
6
  # Tester
@@ -63,7 +63,7 @@ npm run test:unit
63
63
  npm run test:coverage
64
64
  ```
65
65
 
66
- **覆盖率要求**: >= 70%
66
+ **覆盖率要求**: >= 90%
67
67
 
68
68
  **E2E 测试(Playwright)**:
69
69
  ```bash
@@ -91,7 +91,7 @@ npm run test:e2e -- --project=chromium
91
91
  - [ ] 标准 2:错误情况下有友好提示
92
92
  - [ ] 标准 3:性能满足要求(响应时间 < 200ms P95)
93
93
  - [ ] 标准 4:通过安全测试
94
- - [ ] 标准 5:测试覆盖率达标(后端 >= 90%, 前端 >= 70%)
94
+ - [ ] 标准 5:测试覆盖率达标(后端 >= 90%, 前端 >= 90%)
95
95
  ```
96
96
 
97
97
  ### 阶段4:测试报告
@@ -430,7 +430,7 @@ lhci autorun
430
430
 
431
431
  📊 前端测试结果:
432
432
  - 单元测试:✅ 8/8 通过
433
- - 覆盖率:✅ 75% (>= 70%)
433
+ - 覆盖率:✅ 92% (>= 90%)
434
434
  - E2E 测试:❌ 1/3 失败
435
435
 
436
436
  ❌ E2E 测试失败详情: