@hupan56/wlkj 2.3.4 → 2.4.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/package.json +1 -1
- package/templates/qoder/agents/design-agent.md +20 -0
- package/templates/qoder/agents/prd-planning.md +56 -0
- package/templates/qoder/agents/prd-quick.md +64 -0
- package/templates/qoder/agents/prd-reference.md +39 -0
- package/templates/qoder/agents/prd-research.md +33 -0
- package/templates/qoder/agents/qoder-coder.toml +46 -0
- package/templates/qoder/agents/qoder-spec-gen.toml +48 -0
- package/templates/qoder/agents/qoder-test-gen.toml +48 -0
- package/templates/qoder/agents/spec-generator.md +21 -0
- package/templates/qoder/commands/wl-prd.md +52 -10
- package/templates/qoder/skills/prd-generator/SKILL.md +77 -158
- package/templates/qoder/skills/wl-prd/SKILL.md +15 -3
- package/templates/root//345/256/214/346/225/264/345/221/275/344/273/244/344/270/216/346/223/215/344/275/234/346/214/207/345/215/227.md +630 -0
|
@@ -6,175 +6,94 @@ trigger: "user describes a requirement, asks for PRD, mockup, or invokes /wl-prd
|
|
|
6
6
|
|
|
7
7
|
# PRD Generator Skill
|
|
8
8
|
|
|
9
|
-
##
|
|
9
|
+
## 性能原则(最重要的规则)
|
|
10
10
|
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
-
|
|
11
|
+
1. **最少轮次**: Quick <=5 轮, Reference <=10 轮。不要 60 轮"深度思考"
|
|
12
|
+
2. **一次取全**: 用 context_pack 一次拿全上下文,不要逐个 search(5-6 次变 1 次)
|
|
13
|
+
3. **批量生成**: PRD + 原型一次 Write 写完,不分两轮
|
|
14
|
+
4. **不重复读**: 模板已有正确颜色(vben-style / Vant),不要单独读 style JSON
|
|
15
|
+
5. **并行调用**: 独立操作放一个消息里并行(如同时 Read 2 个文件)
|
|
16
|
+
6. **Quick 跳过**: EVA / 历史 PRD / 网络搜索 / style JSON
|
|
15
17
|
|
|
16
|
-
|
|
17
|
-
"还没初始化,建议先说'初始化'(/wl-init)注册开发者身份",但不要阻塞。
|
|
18
|
+
## 自取上下文(Quest / QoderWork 无 hook,必须自读)
|
|
18
19
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
**CRITICAL: You MUST ask this question BEFORE doing ANYTHING else.**
|
|
24
|
-
**NEVER auto-detect. NEVER assume. NEVER skip. ALWAYS ASK.**
|
|
20
|
+
- `.qoder/.developer` — 当前开发者名
|
|
21
|
+
- `.qoder/.current-task` — 当前活动任务
|
|
22
|
+
- `data/index/.index-meta.json` — 知识图谱新鲜度
|
|
25
23
|
|
|
26
|
-
|
|
24
|
+
## STEP 0: 必须先问平台
|
|
27
25
|
|
|
28
26
|
```
|
|
29
27
|
这个需求是针对哪个平台?
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
3. **两端都要**
|
|
34
|
-
|
|
28
|
+
1. Web 管理端 (fywl-ui) - Ant Design Vue + VxeGrid 风格
|
|
29
|
+
2. APP 移动端 (Carmg-H5) - Vant 风格
|
|
30
|
+
3. 两端都要
|
|
35
31
|
请选择 (1/2/3):
|
|
36
32
|
```
|
|
33
|
+
等用户回答。绝不自动判断。
|
|
37
34
|
|
|
38
|
-
|
|
35
|
+
| 回答 | 平台 | 项目 | 原型模板 |
|
|
36
|
+
|------|------|------|---------|
|
|
37
|
+
| 1 | Web | fywl-ui | prototype-web.html |
|
|
38
|
+
| 2 | APP | Carmg-H5 | prototype-app.html |
|
|
39
|
+
| 3 | Both | Both | 两个模板 |
|
|
39
40
|
|
|
40
|
-
|
|
41
|
+
## 取上下文 — 一次取全(不要逐个搜)
|
|
41
42
|
|
|
42
|
-
| User Answer | Platform | Project | Component Library | Template |
|
|
43
|
-
|-------------|----------|---------|-------------------|----------|
|
|
44
|
-
| 1 或 Web/PC/管理端 | Web | fywl-ui | Ant Design Vue + VxeGrid | prototype-web.html |
|
|
45
|
-
| 2 或 APP/H5/移动端 | APP | Carmg-H5 | Vant 3 + Element Plus | prototype-app.html |
|
|
46
|
-
| 3 或 都要/两端 | Both | Both | Generate 2 prototypes | Both templates |
|
|
47
|
-
|
|
48
|
-
### Search Command
|
|
49
|
-
|
|
50
|
-
After user selects platform, use:
|
|
51
43
|
```bash
|
|
52
|
-
/
|
|
53
|
-
/wl-search <keyword> --platform app # For APP
|
|
54
|
-
/wl-search <keyword> # For Both
|
|
44
|
+
python .qoder/scripts/context_pack.py <关键词> --platform <web|app>
|
|
55
45
|
```
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
```css
|
|
111
|
-
--primary: 212 100% 45%; /* 蓝色 */
|
|
112
|
-
--destructive: 359.33 100% 65.1%; /* 红色 */
|
|
113
|
-
--success: 144 57% 58%; /* 绿色 */
|
|
114
|
-
--background-deep: 216 20.11% 95.47%; /* 灰底 */
|
|
115
|
-
```
|
|
116
|
-
|
|
117
|
-
### APP 移动端 (Carmg-H5)
|
|
118
|
-
```
|
|
119
|
-
样式来源: data/code/Carmg-H5/src/
|
|
120
|
-
组件库: Vant 3 + Element Plus
|
|
121
|
-
适配: postcss-px-to-viewport (vw) + lib-flexible (rem)
|
|
122
|
-
关键文件: data/code/Carmg-H5/src/modules/xxx/index.vue
|
|
123
|
-
原型模板: .qoder/templates/prototype-app.html
|
|
124
|
-
```
|
|
125
|
-
|
|
126
|
-
**Design Tokens (APP):**
|
|
127
|
-
```css
|
|
128
|
-
--van-primary-color: #1989fa;
|
|
129
|
-
--van-success-color: #07c160;
|
|
130
|
-
--van-warning-color: #ff976a;
|
|
131
|
-
--van-danger-color: #ee0a24;
|
|
132
|
-
max-width: 375px; /* 移动端基准 */
|
|
133
|
-
```
|
|
134
|
-
|
|
135
|
-
---
|
|
136
|
-
|
|
137
|
-
## Prototype Generation Rules
|
|
138
|
-
|
|
139
|
-
### Required Features
|
|
140
|
-
- Style matches TARGET platform EXACTLY
|
|
141
|
-
- Changed/new elements highlighted with subtle border
|
|
142
|
-
- Interactive: clickable buttons, fillable forms
|
|
143
|
-
- Single HTML file, self-contained
|
|
144
|
-
- **Web**: Desktop layout, sidebar navigation
|
|
145
|
-
- **APP**: Mobile layout, bottom tab bar, 375px width
|
|
146
|
-
|
|
147
|
-
### Style Priority (when conflicts)
|
|
148
|
-
1. Real .vue files in project (HIGHEST)
|
|
149
|
-
2. data/style/ PDF specs
|
|
150
|
-
3. vben-style-reference.json (framework default)
|
|
151
|
-
4. If PDF vs Code conflict → **Code wins**
|
|
152
|
-
|
|
153
|
-
---
|
|
154
|
-
|
|
155
|
-
## PRD Templates (团队标准, MUST USE)
|
|
156
|
-
|
|
157
|
-
Distilled from data/docs/constitution/prdtemplate/*.docx (团队章程源文件):
|
|
158
|
-
|
|
159
|
-
| Mode | Template | Rule |
|
|
160
|
-
|------|----------|------|
|
|
161
|
-
| Reference / Brainstorm / Planning | .qoder/templates/prd-full-template.md | 所有章节必须保留(不适用写"无") |
|
|
162
|
-
| Quick | .qoder/templates/prd-quick-template.md | 改动要素涉及则填,章节标题保留 |
|
|
163
|
-
|
|
164
|
-
Read the template file, fill it with the findings. The 10-point quality
|
|
165
|
-
check below maps to the template's 自检 section. If the .docx 源文件更新了,
|
|
166
|
-
re-distill the .md templates (wl-init doctor 会提示).
|
|
167
|
-
|
|
168
|
-
---
|
|
169
|
-
|
|
170
|
-
## Quality Self-Check (10 Items)
|
|
171
|
-
1. Background answers "why"
|
|
172
|
-
2. Goals are quantifiable
|
|
173
|
-
3. User personas specific
|
|
174
|
-
4. Business rules exhaustive
|
|
175
|
-
5. Exceptions covered (2+ per feature)
|
|
176
|
-
6. AC testable (Given-When-Then)
|
|
177
|
-
7. Data events complete
|
|
178
|
-
8. No tech implementation in PRD
|
|
179
|
-
9. Priority tagged (P0/P1/P2)
|
|
180
|
-
10. Schedule grounded
|
|
46
|
+
返回 7 章节(代码+页面+字段+PRD+API+样式+Wiki)。**只读最相关 1-2 个 Vue 文件**。
|
|
47
|
+
|
|
48
|
+
## 五种模式
|
|
49
|
+
|
|
50
|
+
### Reference(默认 — 直接说需求)
|
|
51
|
+
1. 问平台
|
|
52
|
+
2. context_pack 一次取全
|
|
53
|
+
3. 读 1-2 个 Vue 文件
|
|
54
|
+
4. 一次性确认发现
|
|
55
|
+
5. **一次 Write** PRD + 原型
|
|
56
|
+
6. EVA 评估 + 确认发布
|
|
57
|
+
|
|
58
|
+
### Quick(快速 — "快速""加个字段""小改动")
|
|
59
|
+
1. 问平台
|
|
60
|
+
2. context_pack 一次取全
|
|
61
|
+
3. **一次 Write** Mini-PRD + 微型原型
|
|
62
|
+
4. 一句话确认 → push
|
|
63
|
+
> 跳过:EVA / 历史 PRD / 搜索 / style JSON
|
|
64
|
+
|
|
65
|
+
### Discuss(探讨 — "探讨""聊聊""分析")
|
|
66
|
+
1. 听需求
|
|
67
|
+
2. 问关键问题(痛点/谁用/现状/目标)
|
|
68
|
+
3. 给 2-3 个方向建议
|
|
69
|
+
> 不出文件。聊完说"出PRD"转 Reference
|
|
70
|
+
|
|
71
|
+
### Brainstorm(头脑风暴)
|
|
72
|
+
1. 问平台
|
|
73
|
+
2. SCAMPER + 多 agent 调研
|
|
74
|
+
3. 生成 PRD + 原型
|
|
75
|
+
|
|
76
|
+
### Planning(规划)
|
|
77
|
+
1. 问平台
|
|
78
|
+
2. 现状 + 理想态 + Gap + MVP
|
|
79
|
+
3. 生成 PRD + 原型
|
|
80
|
+
|
|
81
|
+
## 原型规则
|
|
82
|
+
|
|
83
|
+
- 从模板开始(`.qoder/templates/prototype-{web|app}.html`),模板已有正确颜色
|
|
84
|
+
- **不要单独读 vben-style-reference.json** — 模板里 CSS 变量已配好
|
|
85
|
+
- 只改 diff 部分,新功能高亮
|
|
86
|
+
- 单 HTML 文件,可交互
|
|
87
|
+
- Web: 桌面布局 + 侧边栏;APP: 375px + 底部 tab
|
|
88
|
+
|
|
89
|
+
## PRD 模板
|
|
90
|
+
|
|
91
|
+
| 模式 | 模板 |
|
|
92
|
+
|------|------|
|
|
93
|
+
| Reference/Brainstorm/Planning | `.qoder/templates/prd-full-template.md` |
|
|
94
|
+
| Quick | `.qoder/templates/prd-quick-template.md` |
|
|
95
|
+
|
|
96
|
+
## 质量自检(10 项,Quick 跳过)
|
|
97
|
+
1. 背景回答"为什么" 2. 目标可量化 3. 用户画像具体
|
|
98
|
+
4. 业务规则完整 5. 异常覆盖(2+) 6. 验收可测(Given-When-Then)
|
|
99
|
+
7. 数据事件完整 8. PRD 无技术实现 9. 优先级标注 10. 排期合理
|
|
@@ -38,10 +38,22 @@ trigger: "用户描述需求、要 PRD、要原型、要 mockup,或直接 /wl-
|
|
|
38
38
|
- `.qoder/.current-task` — 当前活动任务
|
|
39
39
|
- `data/index/.index-meta.json` — 知识图谱新鲜度(过期提示先 `/wl-init`,不阻塞)
|
|
40
40
|
|
|
41
|
-
##
|
|
41
|
+
## 五种模式(看用户怎么说自动选)
|
|
42
42
|
|
|
43
|
-
|
|
44
|
-
|
|
43
|
+
| 用户怎么说 | 模式 | 出PRD? | 出原型? |
|
|
44
|
+
|-----------|------|---------|---------|
|
|
45
|
+
| 直接说需求(默认) | Reference 参考 | ✅ | ✅ |
|
|
46
|
+
| "探讨""聊聊""分析一下""不知道怎么做" | **Discuss 探讨** | ❌ | ❌ |
|
|
47
|
+
| "头脑风暴""brainstorm" | Brainstorm 头脑风暴 | ✅ | ✅ |
|
|
48
|
+
| "规划""plan" | Planning 规划 | ✅ | ✅ |
|
|
49
|
+
| "快速""quick""加个字段" | Quick 快速 | ✅ | ✅ |
|
|
50
|
+
|
|
51
|
+
> **探讨模式**:纯讨论,理需求、拆问题、给方向建议。不出文件。
|
|
52
|
+
> 讨论完用户说"出PRD"→ 自动转参考模式。
|
|
53
|
+
|
|
54
|
+
## 完整流程(Reference/Brainstorm/Planning/Quick 模式)
|
|
55
|
+
|
|
56
|
+
按 `.qoder/commands/wl-prd.md` 执行。核心步骤:
|
|
45
57
|
|
|
46
58
|
1. **一次取全上下文**(fast path):
|
|
47
59
|
```bash
|