@xulthekl/team-flow 0.59.0 → 0.61.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/always/phase-guard.md +1 -1
- package/.claude-plugin/marketplace.json +1 -1
- package/.claude-plugin/plugin.json +2 -2
- package/.codex-plugin/plugin.json +1 -1
- package/.cursor-plugin/marketplace.json +1 -1
- package/.cursor-plugin/plugin.json +2 -2
- package/.github/plugin/marketplace.json +2 -2
- package/AGENTS.md +6 -6
- package/CHANGELOG.md +57 -0
- package/GEMINI.md +1 -1
- package/INSTALL.md +1 -1
- package/README.md +3 -3
- package/agents/change-split-auditor.md +1 -0
- package/docs/README_en.md +1 -1
- package/docs/decision-points.md +4 -0
- package/docs/plans/2026-09-21-001-three-optimization-eval.md +127 -0
- package/docs/{usage-guide.md → team-flow /344/275/277/347/224/250/350/257/264/346/230/216/357/274/210/347/240/224/345/217/221/345/233/242/351/230/237/347/211/210/357/274/211.md" } +234 -104
- package/gemini-extension.json +2 -2
- package/hooks/session-start +2 -2
- package/llms.txt +1 -1
- package/package.json +1 -1
- package/plugin.json +2 -2
- package/scripts/check-version-consistency.mjs +2 -2
- package/scripts/lib/cmd-version.mjs +4 -0
- package/skills/bug-investigator/SKILL.md +8 -0
- package/skills/ce-plan/references/change-splitting.md +12 -0
- package/skills/jarvis/SKILL.md +117 -0
- package/skills/{decision-surrogate → jarvis}/references/decision-points.md +2 -2
- package/skills/{decision-surrogate → jarvis}/references/onboarding.md +27 -11
- package/skills/{decision-surrogate → jarvis}/references/protocols.md +21 -11
- package/skills/workflow-orchestrator/SKILL.md +12 -0
- package/skills/workflow-orchestrator/references/s1-path-router.md +7 -1
- package/skills/workflow-orchestrator/references/s4-split-validate.md +1 -0
- package/skills/workflow-start/SKILL.md +13 -0
- package/skills/decision-surrogate/SKILL.md +0 -87
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
{
|
|
10
10
|
"name": "team-flow",
|
|
11
11
|
"description": "8-state spec workflow + compound global compounding + architecture-design (4A/DDD) + local HTML prototype + product-level orchestration + bootstrap + e2e + session handoff + workflow feedback + independent business analysis. 28 skills + 17 agents with embedded TDD, SDD, code review, debugging, delta spec sync, and design-system-driven prototyping.",
|
|
12
|
-
"version": "0.
|
|
12
|
+
"version": "0.61.0",
|
|
13
13
|
"source": "./",
|
|
14
14
|
"author": {
|
|
15
15
|
"name": "LT",
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "team-flow",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "Unified workflow plugin: team-flow (spec-driven dev: TDD/SDD/code-review/debugging) + compound-engineering core subset (brainstorm/plan/compound/strategy/ideate/proof, global compounding) + architecture-design (4A+DDD incremental design & global compounding) + prototype (local HTML prototype, zero external deps) + e2e (Playwright E2E, AC-driven) + workflow-orchestrator (product-level workflow orchestration) + workflow-bootstrap (existing project onboarding) + session-handoff (context transfer) + workflow-feedback (issue tracking) + business-analysis (independent requirement/scenario artifact) + design-system (design tokens + component contract + AI primer + showcase) + test-strategy (test strategy design) + project-initialize (new service onboarding). 28 skills + 17 agents, one install.",
|
|
3
|
+
"version": "0.61.0",
|
|
4
|
+
"description": "Unified workflow plugin: team-flow (spec-driven dev: TDD/SDD/code-review/debugging) + compound-engineering core subset (brainstorm/plan/compound/strategy/ideate/proof, global compounding) + architecture-design (4A+DDD incremental design & global compounding) + prototype (local HTML prototype, zero external deps) + e2e (Playwright E2E, AC-driven) + workflow-orchestrator (product-level workflow orchestration) + workflow-bootstrap (existing project onboarding) + session-handoff (context transfer) + workflow-feedback (issue tracking) + business-analysis (independent requirement/scenario artifact) + design-system (design tokens + component contract + AI primer + showcase) + test-strategy (test strategy design) + project-initialize (new service onboarding) + jarvis (team-flow decision agent, opt-in). 28 skills + 17 agents, one install.",
|
|
5
5
|
"source": "./",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "LT",
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "team-flow",
|
|
3
3
|
"displayName": "team-flow",
|
|
4
|
-
"description": "Unified workflow plugin: team-flow (spec-driven dev: TDD/SDD/code-review/debugging) + compound-engineering core subset (brainstorm/plan/compound/strategy/ideate/proof, global compounding) + architecture-design (4A+DDD incremental design & global compounding) + prototype (local HTML prototype, zero external deps) + e2e (Playwright E2E, AC-driven) + workflow-orchestrator (product-level workflow orchestration) + workflow-bootstrap (existing project onboarding) + session-handoff (context transfer) + workflow-feedback (issue tracking) + business-analysis (independent requirement/scenario artifact). 28 skills + 17 agents, one install.",
|
|
5
|
-
"version": "0.
|
|
4
|
+
"description": "Unified workflow plugin: team-flow (spec-driven dev: TDD/SDD/code-review/debugging) + compound-engineering core subset (brainstorm/plan/compound/strategy/ideate/proof, global compounding) + architecture-design (4A+DDD incremental design & global compounding) + prototype (local HTML prototype, zero external deps) + e2e (Playwright E2E, AC-driven) + workflow-orchestrator (product-level workflow orchestration) + workflow-bootstrap (existing project onboarding) + session-handoff (context transfer) + workflow-feedback (issue tracking) + business-analysis (independent requirement/scenario artifact) + jarvis (team-flow decision agent, opt-in). 28 skills + 17 agents, one install.",
|
|
5
|
+
"version": "0.61.0",
|
|
6
6
|
"author": {
|
|
7
7
|
"name": "LT",
|
|
8
8
|
"url": "https://github.com/LT"
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
},
|
|
7
7
|
"metadata": {
|
|
8
8
|
"description": "Unified workflow plugins and skills for AI coding agents (team-flow: team-flow + compound + architecture-design + prototype).",
|
|
9
|
-
"version": "0.
|
|
9
|
+
"version": "0.61.0"
|
|
10
10
|
},
|
|
11
11
|
"plugins": [
|
|
12
12
|
{
|
|
13
13
|
"name": "team-flow",
|
|
14
14
|
"description": "Unified workflow with planning artifacts, execution contracts, TDD, review gates, systematic debugging, delta spec sync, architecture-design, independent business analysis, and local HTML prototyping.",
|
|
15
|
-
"version": "0.
|
|
15
|
+
"version": "0.61.0",
|
|
16
16
|
"source": ".",
|
|
17
17
|
"author": {
|
|
18
18
|
"name": "LT",
|
package/AGENTS.md
CHANGED
|
@@ -100,10 +100,10 @@ spec 驱动开发过程。8 态变更机:`exploring → specifying → bridgin
|
|
|
100
100
|
- glaf4 体系走 glaf4-dev 的 PROJECT_INITIALIZE 模式;非 glaf4 走内置引导(B1.5 骨架生成)
|
|
101
101
|
- 由 ARCH 后 Pre-check 服务初始化检测触发(缺失时引导接入)
|
|
102
102
|
|
|
103
|
-
### 13.
|
|
104
|
-
-
|
|
105
|
-
- 依赖**个人资产**:`~/.claude/lt-preferences/` 决策偏好库 +
|
|
106
|
-
- **不进任何默认流程**,需要的成员独立启用;设计文档见工作区 `docs/plan/
|
|
103
|
+
### 13. jarvis(1 skill,team-flow 决策代理,v0.59.0 新增 / v0.60.0 改名,**可选启用**)
|
|
104
|
+
- 在授权范围内代做 team-flow 决策点裁决:布置任务并逐点预授权 → 经 Orca 派 worker 跑工作流 → 裁决可代答的点、其余 HOLD 等用户 → 交付决策过程汇总。**核心场景是夜间/离席值守,但不再限于此**——在场时亦可分流决策点,减少打断
|
|
105
|
+
- 依赖**个人资产**:`~/.claude/lt-preferences/` 决策偏好库 + Jarvis home(各成员自建)
|
|
106
|
+
- **不进任何默认流程**,需要的成员独立启用;设计文档见工作区 `docs/plan/jarvis-design.md`
|
|
107
107
|
|
|
108
108
|
## 全局产物结构(Discoverability —— 设计/开发前先检索)
|
|
109
109
|
|
|
@@ -220,7 +220,7 @@ STRATEGY.md CONCEPTS.md 产品策略(BA) / 领域词汇
|
|
|
220
220
|
| workflow-feedback | 工作流反馈 | 工作流问题结构化记录(v0.16.0) |
|
|
221
221
|
| business-analysis | 独立业务分析 | 将任意输入整理为 requirement/vN/business-analysis.md(独立外挂,v0.44.0) |
|
|
222
222
|
| project-initialize | 项目初始化引导 | 工作空间代码服务为空时:架构选择(glaf4/前端分离/单体微服务/拆分)→ 服务命名确认 → 创建服务子目录 → 委托初始化(glaf4 走 glaf4-dev,非 glaf4 走内置引导)(v0.45.0) |
|
|
223
|
-
|
|
|
223
|
+
| jarvis | team-flow 决策代理(**可选启用**) | 在授权范围内代做 team-flow 决策点裁决(**夜间/离席值守**为核心场景,在场时亦可分流、只把 HOLD 项交回);经 Orca 派 worker,依赖个人偏好库与 Jarvis home(v0.59.0 新增 / v0.60.0 改名) |
|
|
224
224
|
|
|
225
225
|
### 触发域分层(v0.12.0 新增)
|
|
226
226
|
|
|
@@ -231,7 +231,7 @@ STRATEGY.md CONCEPTS.md 产品策略(BA) / 领域词汇
|
|
|
231
231
|
| 接入层 | workflow-bootstrap | "初始化/接入/分析代码库" | 一次性,触发词独特,无冲突 |
|
|
232
232
|
| 产品级(唯一入口) | **workflow-orchestrator** | 新的产品级需求("新需求/从头开始/我有个想法/做一个XX") | 拥有所有"产品级新需求"触发词,内部路由到 ce-brainstorm/ce-plan |
|
|
233
233
|
| 变更级(唯一入口) | workflow-start | change 上下文内的操作(.team-flow.yaml) | 有强上下文约束,与产品级天然隔离 |
|
|
234
|
-
| 步骤级 - 独立工具 | ce-ideate, ce-strategy, ce-compound, ce-proof, architecture-design, prototype, e2e, session-handoff, workflow-feedback, **business-analysis**, **
|
|
234
|
+
| 步骤级 - 独立工具 | ce-ideate, ce-strategy, ce-compound, ce-proof, architecture-design, prototype, e2e, session-handoff, workflow-feedback, **business-analysis**, **jarvis** | 各自独特触发词 | 无冲突,可独立触发;business-analysis 不进入核心工作流;**jarvis 为可选启用**(个人决策代理,不进任何默认流程) |
|
|
235
235
|
| 步骤级 - 受限独立 | ce-brainstorm, ce-plan | 可独立触发,但产品级新需求应走 orchestrator | description 中标注路由指导 |
|
|
236
236
|
| 步骤级 - 仅路由 | need-explorer, spec-writer, contract-builder, build-executor, code-reviewer, spec-merger, release-archivist, bug-investigator | 仅由 workflow-start 路由 | 不独立触发 |
|
|
237
237
|
| 内部方法论(预加载)| test-strategy, clean-code | 无触发词——仅经 agent `skills:` 字段预加载,或由派发模板内联 | 不独立触发;判据真相源,执行处为派发模板(`user-invocable: false`)|
|
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,63 @@ All notable changes to `team-flow` will be documented in this file.
|
|
|
4
4
|
|
|
5
5
|
The format loosely follows Keep a Changelog.
|
|
6
6
|
|
|
7
|
+
## [0.61.0] - 2026-09-21
|
|
8
|
+
|
|
9
|
+
### Added(三优化点:决策话术人类化 / Hotfix 命中源 change / 拆分粗粒度优先)
|
|
10
|
+
|
|
11
|
+
1. **决策话术人类化规范**(v0.61.0 新增):在 `workflow-orchestrator` 与 `workflow-start` 两入口 skill 新增「决策话术规范(人类化原则)」节(4 条规则 + 反例),并在 `docs/decision-points.md` 顶部加锚点。面向用户的决策提问用白话、给可理解选项,避免暴露内部路径名/技术术语(反例:S1 直接问"path 路由名" → 改为"你这步想做什么" + 白话选项)。
|
|
12
|
+
2. **Hotfix 增强:命中源 change**(v0.61.0 新增,纯文档承载):bug 修复时优先匹配源 change(`git blame` 定位)→ 命中则复用源 change 的 design/specs/tests 上下文做轻量修复,并在 `change-brief.md` frontmatter 写入 `source_change_ref`;非命中走原 Hotfix 快通道。绝不静默 reopen 源 change,失准须降级并请用户确认。**实现形态**:复用 `bug-investigator` 报告段 + `change-brief` `source_change_ref` + learnings 承载,**不动 `state-loader` SETTABLE_FIELDS**(规避门禁变更)。
|
|
13
|
+
3. **change 拆分粗粒度优先**(v0.61.0 新增):`ce-plan/references/change-splitting.md` 顶部加「拆分默认姿态(粗粒度优先)」节——宁粗勿细,仅当「越过所有权边界 / 需独立并行验证 / 团队领取需要」任一成立才拆细;`change-split-auditor` D3「Too small」段加主动建议合并(change 数 > Standard 5 时给合并候选)。拆太细仅建议不硬拦(D3 维持 advisory)。
|
|
14
|
+
|
|
15
|
+
### Changed(设计增强方案)
|
|
16
|
+
|
|
17
|
+
- 设计增强方案升 `docs/architecture-api-db-design-enhancement-v0.26.md`(承袭 v0.25,目标插件 v0.61.0):§202 话术规范、§203 bugfix 增强 Hotfix 纯文档承载、§204 粗粒度优先、§205 P1.5 可跳过判定、§206 制品链校验清单、§207 决策落实状态表。
|
|
18
|
+
|
|
19
|
+
## [0.60.0] - 2026-09-12
|
|
20
|
+
|
|
21
|
+
### Changed(`decision-surrogate` → `jarvis`:更名 + 重定位 + 首次通道实测修订)
|
|
22
|
+
|
|
23
|
+
**更名**:第 28 个 skill `decision-surrogate` → **`jarvis`**(目录 / frontmatter `name` / 全部文档引用同步;设计文档更名为 `docs/plan/jarvis-design.md`)。
|
|
24
|
+
|
|
25
|
+
**重定位**:从「夜间决策替身」扩为 **「team-flow 专用决策代理」**——夜间/离席值守仍为核心场景,但**不再限时段**(在场时亦可分流决策点、只把 HOLD 项交回);通用跨项目的「大副」角色由 firstmate 承担,两者不重叠。
|
|
26
|
+
|
|
27
|
+
### Added(首次通道实测:六条通路,详见设计文档附录 E)
|
|
28
|
+
|
|
29
|
+
| 通路 | 结果 | 关键证据 |
|
|
30
|
+
|------|------|---------|
|
|
31
|
+
| `ask` → `reply`(worker 问、代理答) | ✅ 可用 | 14 秒闭环;worker 写回文件与代答原文**逐字一致** |
|
|
32
|
+
| `send --to dispatch` 唤醒 settled worker | ❌ **不可用** | 消息 `read=0` 永久滞留邮箱 |
|
|
33
|
+
| 重新派发(退化路径) | ✅ 可用 | 新 task 完成原 worker 目标 |
|
|
34
|
+
| Claude Code `SendMessage` 唤醒 idle 会话 | ✅ **可用** | 唤起 idle worker 并完成写入 |
|
|
35
|
+
| Orca 派发 + SendMessage 对话 | ✅ 可用 | worker 主动联系代理会话成功 |
|
|
36
|
+
| 多轮持续对话 | ✅ 可用 | 3 轮问答全部无超时 |
|
|
37
|
+
|
|
38
|
+
### Changed(方案 v4.1 → v4.2)
|
|
39
|
+
|
|
40
|
+
1. **§7.1 双通道互补** —— `orca ask/reply`(worker 发起、**阻塞语义**)+ Claude Code `SendMessage`(代理发起、**异步唤醒**),含**反向寻址**机制(worker 会话名随机 → 由 worker 启动后主动联系代理,代理凭消息头 `from=` 回复)
|
|
41
|
+
2. **§7.2 晨间恢复改 SendMessage** —— 原 `send --to dispatch` 路径**已证伪**
|
|
42
|
+
3. **§7.5 ⑧ 结案**(不可用)+ 新增 ⑩–⑬ 四项待验
|
|
43
|
+
4. **新增 §7.6 环境前置检查**(shell 启动期提示 / 目录信任 / 不休眠 / runtime / orchestration)
|
|
44
|
+
5. **§11 补三行异常**
|
|
45
|
+
|
|
46
|
+
**`agent_prompt_stalled` 真因修正(重要)**:实测证明主因是 **shell 启动期的交互提示**——oh-my-zsh 更新提示吃掉 Orca 注入的 `claude` 命令首字母(实际执行 `laude`),故障发生在 worker 启动**之前**,与 TUI 模态无关,且报错完全不指向真因。
|
|
47
|
+
|
|
48
|
+
### Fixed(skill 侧 4 处缺陷,均由实测暴露)
|
|
49
|
+
|
|
50
|
+
1. **`orca ask` 简写不存在** → 更正为 `orca orchestration ask`
|
|
51
|
+
2. **ask 命令模板缺鉴权参数** → 补 `--from` / `--dispatch-capability`(裸命令返回 `dispatch_capability_invalid`)
|
|
52
|
+
3. **HOLD 早上恢复路径已证伪** → 改 SendMessage
|
|
53
|
+
4. **重试命令缺前置步骤** → 补 `orca orchestration task-update --status ready`(派发失败会连坐 task,否则报 `task_not_startable`)
|
|
54
|
+
|
|
55
|
+
### Changed(环境前置,实测踩坑)
|
|
56
|
+
|
|
57
|
+
- `~/.zshrc`:`DISABLE_UPDATE_PROMPT="true"` 取消注释——**消除 oh-my-zsh 更新提示对 worker 派发的干扰**(实测 5 次连续派发失败的根因)
|
|
58
|
+
- 目标目录须预置 `~/.claude.json` 的 `hasTrustDialogAccepted: true`——新目录首次派发否则必失败
|
|
59
|
+
|
|
60
|
+
### Changed(文档同步)
|
|
61
|
+
|
|
62
|
+
`README.md` / `AGENTS.md` / 工作区 `CLAUDE.md`:skill 名、设计文档路径、定位描述全部同步。
|
|
63
|
+
|
|
7
64
|
## [0.59.0] - 2026-09-12
|
|
8
65
|
|
|
9
66
|
### Added(decision-surrogate 决策替身 —— 第 28 个 skill,可选启用)
|
package/GEMINI.md
CHANGED
|
@@ -8,7 +8,7 @@ The workflow is self-contained and does not require OpenSpec or Superpowers at r
|
|
|
8
8
|
|
|
9
9
|
|
|
10
10
|
<!-- team-flow-phase-guard-start -->
|
|
11
|
-
# team-flow v0.
|
|
11
|
+
# team-flow v0.61.0 | 阶段: {{state}} | 工作流: {{workflow}}
|
|
12
12
|
当前阶段允许的操作由 workflow-start 路由规则定义。
|
|
13
13
|
禁止跨越 DP gate 进入下一阶段。变更范围以 execution-contract.md 的 Intent Lock 为准。
|
|
14
14
|
<!-- team-flow-phase-guard-end -->
|
package/INSTALL.md
CHANGED
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# team-flow
|
|
2
2
|
|
|
3
|
-
> 当前版本:`v0.
|
|
3
|
+
> 当前版本:`v0.61.0`
|
|
4
4
|
|
|
5
5
|
> 统一插件:**team-flow**(spec 驱动开发)+ **compound-engineering 核心子集**(全局复利)+ **architecture-design**(4A+DDD 增量设计)+ **prototype**(本地 HTML 原型)+ **e2e**(AC 驱动 E2E)+ **workflow-orchestrator**(产品级编排)+ **workflow-bootstrap**(既有项目接入)。一次安装,十三套能力协同(详见下文「十三套能力」)。
|
|
6
6
|
|
|
@@ -84,7 +84,7 @@ STRATEGY.md CONCEPTS.md 策略 / 领域词汇
|
|
|
84
84
|
- **设计系统**(1):design-system(独立创建/迭代项目级设计系统,用户主导交互,v0.19.0)
|
|
85
85
|
- **业务分析**(1):business-analysis(将任意输入整理为 requirement/vN/business-analysis.md,多轮单问澄清,独立外挂,v0.44.0)
|
|
86
86
|
- **项目初始化**(1):project-initialize(工作空间代码服务为空时的初始化引导:架构选择 → 服务命名 → 创建子目录 → 委托骨架,v0.45.0)
|
|
87
|
-
-
|
|
87
|
+
- **Jarvis**(1):jarvis(team-flow 专用决策代理:在授权范围内代做决策点裁决——**夜间/离席值守**为核心场景,在场时亦可分流、只把 HOLD 项交回;经 Orca 派 worker,依赖个人偏好库与 Jarvis home,**可选启用**,v0.59.0 新增 / v0.60.0 改名)
|
|
88
88
|
|
|
89
89
|
### 配套 agents(17 个,v0.47.0 增至 17)
|
|
90
90
|
|
|
@@ -98,7 +98,7 @@ Skills 命名保留其来源前缀,作为功能分组的自然标识:
|
|
|
98
98
|
|------|------|------|--------|
|
|
99
99
|
| `ce-` | compound-engineering | 产品级思维工具(头脑风暴、计划、策略、复利、创意、验证) | ce-brainstorm, ce-plan, ce-strategy, ce-compound, ce-ideate, ce-proof |
|
|
100
100
|
| 无前缀 | team-flow | 变更级开发流程工具(状态机、规格、构建、审查、归档、内部方法论) | workflow-start, need-explorer, spec-writer, contract-builder, build-executor, code-reviewer, spec-merger, release-archivist, bug-investigator, test-strategy, clean-code |
|
|
101
|
-
| 无前缀 | team-flow 新增 |
|
|
101
|
+
| 无前缀 | team-flow 新增 | 编排/接入/设计/原型/测试/交接/反馈/初始化/分析/决策代理 | workflow-orchestrator, workflow-bootstrap, architecture-design, prototype, e2e, session-handoff, workflow-feedback, design-system, project-initialize, business-analysis, jarvis |
|
|
102
102
|
|
|
103
103
|
> `ce-` 前缀来自 compound-engineering 项目,team-flow 整合时保留了这一命名以维持功能分组的可辨识性。这不是命名不一致,而是有意的来源标注。
|
|
104
104
|
|
|
@@ -58,6 +58,7 @@ Use Bash for mechanical extraction (`grep` for depends_on patterns) and manual g
|
|
|
58
58
|
1. For each change, assess scope from its description, task count, and affected modules
|
|
59
59
|
2. **Too large** signals: >5 modules affected, >15 tasks estimated, spans multiple bounded contexts → Important (recommend split)
|
|
60
60
|
3. **Too small** signals: single-file change, <2 tasks, trivial config tweak → Important (recommend merge)
|
|
61
|
+
- **主动建议合并(v0.61.0 粗粒度优先,设计依据 v0.26 §204)**:当本 PRD 的 change 总数超过中等上限(Standard > 5)时,审计员除标记单体"太小"外,**必须主动给出合并候选**——列出可合并的 change 对及其共同所有权单元,供 ce-plan 回退收敛。目的:落实"宁粗勿细"默认姿态,避免每个细 change 都走完整 8 态 + 4+1 产物 + 架构增量 + 复利回写(ceremony 开销 > 价值)。
|
|
61
62
|
4. Report the distribution: list changes by estimated size, flag outliers (>2x median or <0.5x median)
|
|
62
63
|
|
|
63
64
|
This dimension is advisory — flag but do not FAIL on granularity alone.
|
package/docs/README_en.md
CHANGED
|
@@ -126,7 +126,7 @@ npm install -g team-flow
|
|
|
126
126
|
|
|
127
127
|
### Version
|
|
128
128
|
|
|
129
|
-
- Current: `v0.
|
|
129
|
+
- Current: `v0.61.0`
|
|
130
130
|
- v0.9.1 highlights: DP-4 execution-mode recommendations, a portable runtime across 17 platforms, and a raw-package smoke with no plugin-root variable.
|
|
131
131
|
- Self-contained — no OpenSpec or Superpowers runtime required
|
|
132
132
|
- Upstream: [Fission-AI/OpenSpec](https://github.com/Fission-AI/OpenSpec), [obra/superpowers](https://github.com/obra/superpowers)
|
package/docs/decision-points.md
CHANGED
|
@@ -2,6 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
本文档集中定义了 team-flow 工作流中所有需要用户明确确认的决策点。每个决策点(Decision Point)都是工作流中的关键门禁,确保用户在自动化流程中始终保持最终决策权。工作流中的 skill 在到达决策点时必须暂停执行、向用户呈现所需信息,并等待明确指令后方可继续。
|
|
4
4
|
|
|
5
|
+
## 话术规范(人类化原则,v0.61.0 新增)
|
|
6
|
+
|
|
7
|
+
所有 DP 的提问文案必须遵守「用大白话讲结果、不讲机制」:选项 label ≤ 12 字、零术语,描述"选了会怎样";技术术语下沉 description 且首现括注白话等价;决策点 = 帮你拍板的岔路口,不让你做机制选型。详细规则与正反例见 `workflow-orchestrator` / `workflow-start` SKILL.md 的「决策话术规范」节(设计依据:设计增强方案 v0.26 §202)。
|
|
8
|
+
|
|
5
9
|
## DP-0: 设计前确认(User Confirmation Gate)
|
|
6
10
|
|
|
7
11
|
- **编号**:DP-0
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
# 三个工作流优化点 · 设计评估笔记
|
|
2
|
+
|
|
3
|
+
> 日期:2026-09-21
|
|
4
|
+
> 遵循流程:`CONTRIBUTING.md`「Large Changes」——重大工作流变更先写 design note,再同步改 skills / templates / examples。
|
|
5
|
+
> 本文档为**评估稿(第一步)**:评估现状、缺口、影响面、可行性与建议方案。实施待评估通过后再落地。
|
|
6
|
+
|
|
7
|
+
## 0. 评估结论速览
|
|
8
|
+
|
|
9
|
+
| # | 优化点 | 现状 | 缺口 | 可行性 | 实施强度 |
|
|
10
|
+
|---|--------|------|------|--------|----------|
|
|
11
|
+
| 1 | 决策话术人类化(避免太技术) | DP 门禁集中定义于 `docs/decision-points.md`,但提问文案由各 skill 的 AskUserQuestion 自定,无"白话"硬规则 | 选项 label/description 含术语(执行模式 SDD/Inline、聚合/限界上下文/CQRS),非技术用户看不懂 | 高(纯文案/规则层,不动状态机) | 改 `decision-points.md` + 各含 DP 的 skill 文案 |
|
|
12
|
+
| 2 | bugfix 匹配源头 change 快速修复 | 执行期 bug 走 `workflow-start → bug-investigator`(debugging 侧路径);S1 有 Hotfix 入口。但**无"bug 回溯到引入它的源 change"机制** | 发现 bug 时无法复用源 change 的 scope/AC/design/tests 上下文,每次从零确认 | 中(新增 `source_change` 字段 + 匹配检索 + 轻量修复路由,复用 hotfix/tweak 通道) | 改 S1 + workflow-start + bug-investigator + change-brief 模板 + state schema |
|
|
13
|
+
| 3 | change 拆分原则明确定义,不建议拆太细 | `change-split-auditor` D5(所有权自包含,v0.9 根因判据)已防"切碎"FAIL;D3 粒度"太小"仅 Important(advisory);`ce-plan/references/change-splitting.md` 有完整判据 | 缺**显式默认姿态**:"宁粗勿细,只有越过所有权边界才拆"。文档是判据(什么算坏),不是原则(默认怎么拆) | 高(文档/判据层微调) | 改 `change-splitting.md` + `change-split-auditor` D3 权重 |
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
## 1. 优化点①:决策话术人类化
|
|
18
|
+
|
|
19
|
+
### 1.1 现状
|
|
20
|
+
- 所有需要用户拍板的节点集中在 `docs/decision-points.md`(DP-0 ~ DP-7),由各 skill 通过平台阻塞问题工具(AskUserQuestion)发起。
|
|
21
|
+
- 现有话术规范只管**流程**(need-explorer「一次一问」「给 2-3 个选项带取舍」「先复述确认」),**不管话术的"技术浓度"**。
|
|
22
|
+
- 术语直灌选项,非技术 PM / 业务方看不懂,例如:
|
|
23
|
+
- DP-4「执行模式选择」:`propose waves` / `SDD` / `Inline` / `Batch Inline`(机制词进 label)。
|
|
24
|
+
- DP-A「架构产品确认」:`聚合` / `限界上下文` / `CQRS` / `读模型`(架构术语无白话等价)。
|
|
25
|
+
- S1 路径路由:`续版需求` / `重新计划` / `单 change 快速通道`(行话,未解释"选了会怎样")。
|
|
26
|
+
|
|
27
|
+
### 1.2 缺口(需新增的硬规则)
|
|
28
|
+
1. **可见文案用"人话"**:用"结果/价值"描述而非"机制";术语首次出现必须括注白话等价(如 `聚合(一组相关的业务数据,比如一张订单及其明细)`)。
|
|
29
|
+
2. **选项口吻**:以"你选哪个"的口吻;label ≤ 12 字;description 讲"选它会怎样",不写"这是什么"。
|
|
30
|
+
3. **术语下沉**:SDD / Inline / 契约 / 聚合等技术细节沉到 description 或折叠区,**不进 label**。
|
|
31
|
+
4. **定位**:决策点是"帮你拍板的岔路口",不是考试——避免让用户做他没能力判断的技术选型。
|
|
32
|
+
|
|
33
|
+
### 1.3 影响面(需 audit 的 DP 文案)
|
|
34
|
+
- `need-explorer`(DP-1)、`workflow-start`(DP-0 / G4 同步 / DP-4 / DP-6 / DP-7)、`contract-builder`(DP-3)、`architecture-design`(DP-A)、`ce-plan` / `ce-brainstorm`(模式选择)、`workflow-orchestrator`(S1 路由、S4 G5 同步)、`prototype`(决策点中继)。
|
|
35
|
+
- 落点:`docs/decision-points.md` 新增「话术规范」一节 + 上述 skill 的提问 prompt 文案。
|
|
36
|
+
|
|
37
|
+
### 1.4 方案与风险
|
|
38
|
+
- 方案:新增一处统一话术规范(原则 + 正反例),并 audit 现有所有 DP 文案,改写为白话版;术语保留在 description 内以保证精度。
|
|
39
|
+
- 风险:过度口语化可能损失精度 → 用"label 白话 + description 含术语"分层化解。可行性高,不动状态机。
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
## 2. 优化点②:bugfix 匹配源头 change 快速修复
|
|
44
|
+
|
|
45
|
+
### 2.1 现状
|
|
46
|
+
- 执行期 bug:`workflow-start`「Route to bug-investigator」→ `executing → debugging` 侧路径 → 回 `build-executor`。`bug-investigator` 是纯科学根因调查,**不认 change 来源**。
|
|
47
|
+
- 产品级:`workflow-orchestrator` S1「紧急修复(Hotfix)」入口 → 直接建 change(`type:hotfix`,注入 bug 描述替代 PRD)→ `workflow-start`,closing 强制补录复利。
|
|
48
|
+
- **关键缺口**:无论执行期还是线上发现的 bug,都**没有"把缺陷回溯到引入它的源 change"的机制**。无法复用源 change 的 `change-brief` / `design.md` / `specs/` / `tests` / `learnings.md` 上下文,每次都从零确认修复 scope。
|
|
49
|
+
|
|
50
|
+
### 2.2 方案建议(新增"bugfix 快速修复"模式)
|
|
51
|
+
1. **触发**:用户报 bug / 线上问题 / 已 closing change 暴露缺陷(独立于 Hotfix)。
|
|
52
|
+
2. **匹配源 change**:
|
|
53
|
+
- `git blame` + 受影响文件/符号 → 定位引入 commit → 经 `change_dag` / `change-brief` / `learnings.md` 反查 `change_dir`;
|
|
54
|
+
- 或按受影响 capability 在全局 `specs/` 检索归属 change。
|
|
55
|
+
3. **快速修复路由**:
|
|
56
|
+
- **命中源 change** → 复用其 `change-brief` / `design.md` / `specs` 作"已知设计约束"上下文,走轻量修复(tweak / hotfix 形态,但带 `source_change` 引用字段),省去重复 scope 确认。
|
|
57
|
+
- **非命中**(独立缺陷 / 新文件)→ 走现有 Hotfix。
|
|
58
|
+
4. **字段与产物**:
|
|
59
|
+
- `workflow-start` 状态文件新增 `source_change` 字段;新增 `reopen` / `quick-fix` 路由(reopen 仅限用户确认,绝不静默)。
|
|
60
|
+
- `bug-investigator` 报告新增「源 change 关联」段(命中则填 change_dir + 复用约束)。
|
|
61
|
+
|
|
62
|
+
### 2.3 影响面
|
|
63
|
+
- `workflow-orchestrator` S1(增强/新增 Hotfix 判据,叠加"是否命中源 change"分支)。
|
|
64
|
+
- `workflow-start`(新增 `source_change` 字段 + reopen/quick-fix 路由 + Guardrails)。
|
|
65
|
+
- `bug-investigator`(报告模板加溯源段)。
|
|
66
|
+
- `changes/<name>/change-brief.md` 模板(加 `source_change_ref` frontmatter)。
|
|
67
|
+
- `src/schema/change.ts` 状态 schema + `docs/artifact-contract.md`。
|
|
68
|
+
|
|
69
|
+
### 2.4 可行性与风险
|
|
70
|
+
- 可行性:中。核心是"源 change 关联"检索,可基于既有 `git blame` + change 元数据(已有 `change_dag` / `change-brief`)。复用 hotfix/tweak 快速通道,不新造状态。
|
|
71
|
+
- 风险:`git blame` 关联可能失准(重构 / 多 change 共改一行)→ **必须让用户确认匹配结果**,不做静默自动 reopen;匹配失败时优雅降级到 Hotfix。
|
|
72
|
+
|
|
73
|
+
---
|
|
74
|
+
|
|
75
|
+
## 3. 优化点③:change 拆分原则明确定义,不建议拆太细
|
|
76
|
+
|
|
77
|
+
### 3.1 现状
|
|
78
|
+
- `change-split-auditor` D5(v0.9 根因判据·所有权自包含):≥2 change 瓜分同一聚合/上下文/读模型/契约 → **FAIL(切碎)**;细到无设计单元 → **FAIL**;跨无关节所有权单元 → **FAIL**。
|
|
79
|
+
- D3 粒度均衡:`太大 → Important(建议拆)`;`太小 → Important(建议合)`,**advisory,不单独 FAIL**。
|
|
80
|
+
- `ce-plan/references/change-splitting.md`:完整所有权判据 + Good/Anti-Patterns + Depth Guidance(Standard 2-5 个 change)。
|
|
81
|
+
|
|
82
|
+
### 3.2 缺口
|
|
83
|
+
- 现有内容是**判据(什么算坏)**,不是**原则(默认怎么拆)**。用户/ce-plan 在"可拆可不拆"时缺一条**显式默认姿态**:"宁粗勿细——只有越过所有权边界、或需要独立并行验证、或需要团队分别领取时,才向下拆细"。
|
|
84
|
+
- D3「太小」仅 Important 不阻断,倾向多拆时 auditor 不拦;需把"拆太细"的代价上升为**默认原则**。
|
|
85
|
+
|
|
86
|
+
### 3.3 方案建议
|
|
87
|
+
1. `change-splitting.md` 顶部显式声明**默认拆分姿态**(粗粒度优先三条件:越过所有权边界 / 可独立并行验证 / 团队领取需要——三者任一成立才拆细)。
|
|
88
|
+
2. `change-split-auditor` D3 提升"太小"信号权重:当单 PRD 的 change 数超过中等规模上限(如 Standard > 5)时,auditor 主动建议合并并给出合并候选;在 Depth Guidance 写"粗粒度优先"。
|
|
89
|
+
3. 明确"拆太细"的代价:每个 change 走完整 8 态 + 4+1 产物 + 架构增量 + 复利回写,ceremonies 开销 > 价值(现有 anti-pattern 已提,上升为默认原则)。
|
|
90
|
+
|
|
91
|
+
### 3.4 可行性与风险
|
|
92
|
+
- 可行性:高(文档/判据层微调,不动状态机)。风险低。
|
|
93
|
+
|
|
94
|
+
---
|
|
95
|
+
|
|
96
|
+
## 4. 按 plugin 流程的后续实施路径
|
|
97
|
+
|
|
98
|
+
> 本笔记评估通过后,依 `CONTRIBUTING.md` 同步改 skills / templates / examples:
|
|
99
|
+
|
|
100
|
+
1. **设计笔记**:本文(已完成评估)。
|
|
101
|
+
2. **话术规范**:`docs/decision-points.md` 新增「话术规范」节 + audit 改写各 DP 文案(优化点①)。
|
|
102
|
+
3. **bugfix 模式**:S1 + workflow-start + bug-investigator + change-brief 模板 + state schema(优化点②)。
|
|
103
|
+
4. **拆分原则**:`change-splitting.md` + `change-split-auditor` D3(优化点③)。
|
|
104
|
+
5. **tests**:`npm test` 过 frontmatter-lint;补「决策话术白话」自检 / change-split 粗粒度优先用例(如需要)。
|
|
105
|
+
6. **CHANGELOG.md**:记录三处用户可见变更。
|
|
106
|
+
7. **examples**:必要时更新 `docs/examples/` 中 bugfix / 粗粒度拆分样例。
|
|
107
|
+
|
|
108
|
+
## 5. 开放问题(待大哥拍板)
|
|
109
|
+
|
|
110
|
+
## 6. 决策记录(大哥拍板,2026-09-21)
|
|
111
|
+
|
|
112
|
+
| # | 开放问题 | 决策 | 落地影响 |
|
|
113
|
+
|---|---------|------|---------|
|
|
114
|
+
| ② | 新增独立 bugfix 入口 vs 增强现有 Hotfix | **增强现有 Hotfix**(改动小) | S1 Hotfix 入口内叠加"是否命中源 change"分支;不新增独立入口 |
|
|
115
|
+
| ① | 全 DP 改双行 vs 仅关键 DP | **最小改动:在两个入口 skill 内各加一小段「话术规范」定义**(workflow-orchestrator + workflow-start) | 不逐个改 subagent skill;入口 skill 设标准,subagent 提问沿用同一口径(need-explorer/ce-plan 等后续可引用,非本次强制) |
|
|
116
|
+
| ③ | D3「太小」升 Critical vs 加强建议 | **只建议、不硬拦**(2026-09-21 拍板) | 保持 advisory;声明"粗粒度优先"原则 + 审计员主动建议合并,不升 Critical |
|
|
117
|
+
|
|
118
|
+
### 6.1 据此锁定的实施方案(待 ③ 拍板后一并实施)
|
|
119
|
+
|
|
120
|
+
- **优化点①(最小改动)**:在 `workflow-orchestrator/SKILL.md` 与 `workflow-start/SKILL.md` 各新增一节「决策话术规范」(label 白话 + description 含术语;术语首现括注白话等价;选项口吻"你选哪个";决策点=帮拍板的岔路口)。同步在 `docs/decision-points.md` 顶部加"话术规范"引用锚点。
|
|
121
|
+
- **优化点②(增强 Hotfix)**:
|
|
122
|
+
- `workflow-orchestrator` S1 Hotfix 入口:用户报 bug 时,先尝试 `git blame` + change 元数据反查源 change;命中则在建 change 时携带 `source_change` 引用,非命中走原 Hotfix。
|
|
123
|
+
- `workflow-start` Hotfix 路由:新增 `source_change` 字段消费 + "复用源 change 上下文做轻量修复"说明 + Guardrail(匹配结果必须用户确认,失准降级 Hotfix,绝不静默 reopen)。
|
|
124
|
+
- `bug-investigator` 报告模板:新增「源 change 关联」段。
|
|
125
|
+
- `changes/<name>/change-brief.md` 模板:`source_change_ref` frontmatter(可选)。
|
|
126
|
+
- `src/schema/change.ts` 状态 schema:新增 `source_change` 字段(additive)+ `docs/artifact-contract.md` 记录。
|
|
127
|
+
- **优化点③(待 ③ 拍板)**:`change-splitting.md` 顶部声明"粗粒度优先"原则;`change-split-auditor` D3 主动建议合并(不升 Critical)。
|