@mstar-harness/opencode 1.3.1 → 1.3.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/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,13 @@ All notable changes to the `@mstar-harness/opencode` package are documented in t
|
|
|
4
4
|
|
|
5
5
|
The monorepo root [CHANGELOG.md](../../CHANGELOG.md) summarizes cross-surface releases.
|
|
6
6
|
|
|
7
|
+
## 1.3.2
|
|
8
|
+
|
|
9
|
+
- Bundled commands: `/iteration-start` Cursor Plan path — feedback-driven plan updates; deferred grill after feedback-close; single CreatePlan URI (in-place edits only).
|
|
10
|
+
- Bundled skills: `mstar-iteration` §1.2 Plan UX feedback-driven + recommended branch policy; `mstar-host` Cursor Phase 1 bridge/rule.
|
|
11
|
+
|
|
12
|
+
See root [CHANGELOG.md](../../CHANGELOG.md) **1.3.2**.
|
|
13
|
+
|
|
7
14
|
## 1.3.1
|
|
8
15
|
|
|
9
16
|
- Bundled skills/commands: iteration package layout — `{ITERATION_DIR}/<id>/delivery-compass.md` + sibling `guides/` / `specs/`; one-row root iteration index; legacy flat compass read-compat.
|
|
@@ -28,7 +28,7 @@ Detailed workflow → **`mstar-iteration` § Phase 1**(含 §1.6 Review & Edit
|
|
|
28
28
|
|
|
29
29
|
| 宿主上下文 | 走哪条 |
|
|
30
30
|
|------------|--------|
|
|
31
|
-
| **Cursor Plan mode**(CreatePlan / Plan 会话活跃) | §0 Boot → §P
|
|
31
|
+
| **Cursor Plan mode**(CreatePlan / Plan 会话活跃) | §0 Boot → §P — **先**空白 CreatePlan,再 **feedback-driven** 自主改同一份 plan;grill-me **仅**在用户明确结束反馈后、仍有阻塞疑问时;**Build 前不执行** Review 链 / commit / integration 分支 |
|
|
32
32
|
| **其它**(Agent、OpenCode、非 Plan) | §0 Boot → §1–§6(Research → Explore → grill-me → Write → Review → branch) |
|
|
33
33
|
|
|
34
34
|
## 0. Boot
|
|
@@ -43,19 +43,28 @@ Detailed workflow → **`mstar-iteration` § Phase 1**(含 §1.6 Review & Edit
|
|
|
43
43
|
|
|
44
44
|
**若 Cursor Plan mode 活跃 → 进入 §P;否则继续 §1。**
|
|
45
45
|
|
|
46
|
-
## P. Cursor Plan mode(Phase 1 scaffold →
|
|
46
|
+
## P. Cursor Plan mode(Phase 1 scaffold → feedback loop → deferred grill → Build)
|
|
47
47
|
|
|
48
48
|
**Detect**:会话处于 Cursor Plan mode(系统要求 CreatePlan / SwitchMode,或 Plan 工具可用且当前为 Plan 会话)。
|
|
49
49
|
|
|
50
|
-
**语义**:Plan 模式期间 **只维护 CreatePlan + SSOT
|
|
50
|
+
**语义**:Plan 模式期间 **只维护 CreatePlan + SSOT 草稿**;用户侧是 **纯反馈**(提方向 / 提意见),**不是**答问卷。Agent **探索 + 推荐并直接改 plan**。**不**派发 Review 链;**不** commit;**不**建 integration 分支。点 **Build** 后才执行下方 Build todos(对齐 `mstar-host/references/cursor-plan-mode-bridge.md` · Phase 1 in Plan mode)。
|
|
51
|
+
|
|
52
|
+
### P.0 Single CreatePlan URI(HARD — 防双 plan)
|
|
53
|
+
|
|
54
|
+
| 规则 | 说明 |
|
|
55
|
+
|------|------|
|
|
56
|
+
| **CreatePlan 只调用一次** | §P.2 空白脚手架是本会话 **唯一** 一次 CreatePlan |
|
|
57
|
+
| **记录路径** | 记下工具返回的 plan 文件路径(常在 `~/.cursor/plans/*.plan.md`);后续所有修订都写 **这一份** |
|
|
58
|
+
| **更新方式** | Feedback / deferred grill 后用 **Read + Write/StrReplace 原地改** 该文件;**禁止**再调 CreatePlan 开第二份 |
|
|
59
|
+
| **发现重复** | 若已误开第二份:把有效内容 **合并进第一份**,删除重复文件,并确保用户 View Plan 指向第一份 |
|
|
51
60
|
|
|
52
61
|
### P.1 Research(只读)
|
|
53
62
|
|
|
54
63
|
执行与 §1 相同的调研(structured + unstructured + `STRATEGY.md`)。**不要**在本步写 compass/plans 终稿。
|
|
55
64
|
|
|
56
|
-
### P.2 Early CreatePlan(空白脚手架 —
|
|
65
|
+
### P.2 Early CreatePlan(空白脚手架 — 本会话唯一一次)
|
|
57
66
|
|
|
58
|
-
Research 后 **立刻** CreatePlan
|
|
67
|
+
Research 后 **立刻** CreatePlan **一次**(**禁止**等方向锁定完成再 CreatePlan;**禁止**之后再 CreatePlan)。
|
|
59
68
|
|
|
60
69
|
**CreatePlan 最小结构**(session mirror;dual-write 草稿见 P.3):
|
|
61
70
|
|
|
@@ -86,39 +95,62 @@ TBD
|
|
|
86
95
|
|---------|------|--------|-------|
|
|
87
96
|
| TBD | | Todo | |
|
|
88
97
|
|
|
89
|
-
##
|
|
90
|
-
|
|
98
|
+
## Feedback log
|
|
99
|
+
(吸收用户反馈 / agent 推荐决议后追加)
|
|
100
|
+
|
|
101
|
+
## Deferred grill log
|
|
102
|
+
(仅 P.3.5 若发起 grill 时追加;可空)
|
|
91
103
|
```
|
|
92
104
|
|
|
93
|
-
**Build 才勾的 todos**(顺序;**不要**把 grill
|
|
105
|
+
**Build 才勾的 todos**(顺序;**不要**把 feedback / grill 写成 Build todo):
|
|
94
106
|
|
|
95
107
|
1. `harness-init` — 若 `{HARNESS_DIR}` / `status.json` 缺失则初始化
|
|
96
|
-
2. `finalize-compass-plans` — 将 CreatePlan 正文落成 compass + `{PLAN_DIR}/` plans + `status.json` 登记 + `{ITERATION_DIR}
|
|
108
|
+
2. `finalize-compass-plans` — 将 **同一份** CreatePlan 正文落成 compass + `{PLAN_DIR}/` plans + `status.json` 登记 + `{ITERATION_DIR}` 索引
|
|
97
109
|
3. `review-edit-product-manager` — §5.1 invoke
|
|
98
110
|
4. `review-edit-architect` — §5.2 invoke
|
|
99
111
|
5. `review-edit-writing-specialist` — §5.3 invoke
|
|
100
112
|
6. `pm-lock` — §5.4 compass `status: locked` + Prepare gates
|
|
101
113
|
7. `integration-branch` — §6
|
|
102
114
|
|
|
103
|
-
### P.3
|
|
115
|
+
### P.3 Feedback loop(主路径 — 直到用户明确结束反馈)
|
|
116
|
+
|
|
117
|
+
**用户模式**:提方向、提意见、纠正推荐 — **纯反馈**。**不要**把用户当成问卷答题人;**禁止**例行一问一答卡更新。
|
|
118
|
+
|
|
119
|
+
**Agent 每轮**(可多轮,直到用户喊停):
|
|
120
|
+
|
|
121
|
+
1. 探索代码 / harness / roadmap(能靠读回答的先读)
|
|
122
|
+
2. 形成推荐(Direction / Scope / Acceptance / Non-Goals / Branch policy / Plans)
|
|
123
|
+
3. **立刻**原地更新 **§P.2 那一份** CreatePlan(含 `## Feedback log`)+ 推荐 dual-write SSOT 草稿
|
|
124
|
+
4. 吸收用户新反馈 → 再探索/再改 **同一份** plan
|
|
125
|
+
|
|
126
|
+
**Branch policy**:在 plan 中写入 **推荐值 + 简短 rationale**(不得静默默认 `main`/`master`);用户可用反馈改掉。**不要**在本阶段为 branch 开 grill。
|
|
127
|
+
|
|
128
|
+
**禁止**:
|
|
129
|
+
|
|
130
|
+
- 再调 CreatePlan / 写到另一份 plan 文件
|
|
131
|
+
- 把「等用户回答问题」当作更新 plan 的门禁
|
|
132
|
+
- 在用户结束反馈前加载 / 运行 `grill-me`
|
|
133
|
+
- 固定死反馈轮数;Plan 模式内派发 §5 / commit / §6
|
|
134
|
+
|
|
135
|
+
### P.3.5 Feedback-close → deferred grill(可选)
|
|
104
136
|
|
|
105
|
-
|
|
137
|
+
**触发**:用户明确表示反馈结束(例如:反馈结束、总结、分析反馈、可以了、准备 Build)。
|
|
106
138
|
|
|
107
|
-
|
|
139
|
+
然后 Agent 自检 CreatePlan:Direction / Scope / Acceptance / Non-Goals / Branch policy / Plans 是否仍有 **阻塞缺口**。
|
|
108
140
|
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
141
|
+
| 结果 | 动作 |
|
|
142
|
+
|------|------|
|
|
143
|
+
| **无阻塞缺口** | **不**开 grill-me;宣布可 Build;确认同一份 CreatePlan + 草稿 SSOT 已反映锁定内容 |
|
|
144
|
+
| **仍有阻塞缺口** | Read `skills/grill-me/SKILL.md`(**仅本命令**);对 **剩余缺口** 做最小 grill(一段一问);每段收敛后仍 **原地改同一份** CreatePlan,并追加 `## Deferred grill log` |
|
|
113
145
|
|
|
114
|
-
|
|
146
|
+
**Direction lock mode** 仍为 interactive 语义,但 Plan 会话的 **主路径是 feedback-driven**;grill 是 close 后门禁,不是主循环。
|
|
115
147
|
|
|
116
148
|
### P.4 Build(执行 Phase 1 可执行门禁)
|
|
117
149
|
|
|
118
150
|
用户点击 **Build**(或 Plan → Agent)后:
|
|
119
151
|
|
|
120
|
-
1. 按 Build todos 顺序执行:`harness-init` → `finalize-compass-plans
|
|
121
|
-
2. **禁止**把 Build
|
|
152
|
+
1. 按 Build todos 顺序执行:`harness-init` → `finalize-compass-plans`(以 **View Plan 打开的那一份** CreatePlan 为准)→ §5 Review 链(5.1→5.2→5.3)→ `pm-lock` → §6
|
|
153
|
+
2. **禁止**把 Build 当成重新跑 feedback / grill
|
|
122
154
|
3. pre-commit checklist(见 §5)全 `[x]` 后再 commit / push integration 分支
|
|
123
155
|
|
|
124
156
|
**非 Plan 路径从这里继续 ↓**
|
|
@@ -156,11 +188,11 @@ Explore candidate directions targeting **product completeness**:
|
|
|
156
188
|
|
|
157
189
|
## 3. Lock Direction — bundled `grill-me`
|
|
158
190
|
|
|
159
|
-
> **非 Plan 路径**。Cursor Plan mode 用 §P.3
|
|
191
|
+
> **非 Plan 路径**。Cursor Plan mode 用 §P.3 feedback loop + §P.3.5 deferred grill(主路径不是 grill)。
|
|
160
192
|
|
|
161
193
|
**Direction lock mode: `interactive`**(`mstar-iteration` §1.2 默认;本命令不使用 `autonomous`)。
|
|
162
194
|
|
|
163
|
-
This command bundles a **non-`mstar-*`** skill at `skills/grill-me/SKILL.md`. **Only this command step**(及 §P.3)references it — **do not** load it from `mstar-harness-core` or other `mstar-*` skills.
|
|
195
|
+
This command bundles a **non-`mstar-*`** skill at `skills/grill-me/SKILL.md`. **Only this command step**(及 §P.3.5 deferred grill)references it — **do not** load it from `mstar-harness-core` or other `mstar-*` skills.
|
|
164
196
|
|
|
165
197
|
**Before this step:** Read `skills/grill-me/SKILL.md`.
|
|
166
198
|
|
|
@@ -176,7 +208,7 @@ Run **grill-me** to stress-test candidate directions with the user:
|
|
|
176
208
|
|
|
177
209
|
## 4. Write Compass & Plans
|
|
178
210
|
|
|
179
|
-
> **非 Plan 路径**。Plan mode 在 §P.2–P.3
|
|
211
|
+
> **非 Plan 路径**。Plan mode 在 §P.2–P.3.5 维护 **同一份** CreatePlan 草稿,Build 时由 `finalize-compass-plans` 落盘终稿。
|
|
180
212
|
|
|
181
213
|
Produce harness artifacts per **`mstar-iteration` § 1.3**(template: `mstar-iteration/references/iteration-compass-template.md`):
|
|
182
214
|
|
|
@@ -224,7 +256,7 @@ Only after 5.4 → proceed to §6.
|
|
|
224
256
|
|
|
225
257
|
PM must print this block before §6; all `[ ]` must be `[x]`:
|
|
226
258
|
|
|
227
|
-
- [ ]
|
|
259
|
+
- [ ] direction lock decisions recorded in compass(Plan 路径:Feedback log + 可选 Deferred grill log;非 Plan:grill-me)
|
|
228
260
|
- [ ] Draft compass + plans + `status.json` registered
|
|
229
261
|
- [ ] product-manager invoke completed — compass / plans / specs / **`<iteration-id>/` package**(按需);**未**向 `{KNOWLEDGE_DIR}/` 新增
|
|
230
262
|
- [ ] architect invoke completed — compass / **specs** edited;**未**向 `{KNOWLEDGE_DIR}/` 新增
|
|
@@ -189,16 +189,21 @@ When starting a **new iteration** under Cursor Plan mode (host command may orche
|
|
|
189
189
|
|
|
190
190
|
| Phase | Behavior | Forbidden |
|
|
191
191
|
|-------|----------|-----------|
|
|
192
|
-
| Early CreatePlan | After read-only research, **
|
|
193
|
-
|
|
|
192
|
+
| Early CreatePlan | After read-only research, **CreatePlan once** with blank Phase 1 scaffold + Build-bound todos; **record the returned plan file path** | Wait until direction lock finishes; call CreatePlan again later |
|
|
193
|
+
| Feedback loop | User gives **direction / opinions only** (no questionnaire). Agent explores, recommends, and **edits that same plan file in place** (+ SSOT drafts). Absorb feedback → update again | Routine one-question-at-a-time interview; gate plan updates on user answers; write a second `*.plan.md`; open interview helpers before feedback-close |
|
|
194
|
+
| Feedback-close | When user signals feedback done (e.g. 反馈结束 / 总结 / 准备 Build): if blocking gaps remain → **minimal** deferred interview on gaps only, still editing the **same** plan file; else ready for Build | Start the interview helper as the main Plan-session loop |
|
|
194
195
|
| Pre-Build | Maintain documents only | Execute Review chain, commit, or create `spec_integration_branch` |
|
|
195
|
-
| Build |
|
|
196
|
+
| Build | Finalize SSOT from the **same** CreatePlan body → sequential Review & Edit → PM lock → integration branch | Replay feedback/interview; finalize from a different plan URI than View Plan |
|
|
197
|
+
|
|
198
|
+
**Single CreatePlan URI (HARD)**: one CreatePlan per Phase 1 Plan session. Updates use file edit tools on that path. If a duplicate plan file was created by mistake: merge into the original, delete the duplicate, keep View Plan on the original.
|
|
196
199
|
|
|
197
200
|
**Plan mode ≠ executing todos.** Build = Phase 1 executable gate (Review chain, lock, branch).
|
|
198
201
|
|
|
202
|
+
**Branch policy in Plan session**: write **recommended** `iteration_base_branch` / `target_branch` (+ short rationale) into the plan — do **not** silently default to `main`/`master`. User may correct via feedback; ask only after feedback-close if still TBD/conflicting.
|
|
203
|
+
|
|
199
204
|
**Bootstrap relationship**: ordinary per-plan work still uses `harness-init` / `spec-register` / `mirror-plan`. Phase 1 CreatePlan uses Phase 1 todos (`harness-init` → `finalize-compass-plans` → review-edit seats → `pm-lock` → `integration-branch`). Business `plans[]` rows should exist as drafts before Build when direction has converged.
|
|
200
205
|
|
|
201
|
-
**Helpers**: third-party interview helpers are **not** named here; host **command** layer
|
|
206
|
+
**Helpers**: third-party interview helpers are **not** named here; host **command** layer may use them only after feedback-close when gaps remain.
|
|
202
207
|
|
|
203
208
|
## Anti-patterns
|
|
204
209
|
|
|
@@ -211,7 +216,8 @@ When starting a **new iteration** under Cursor Plan mode (host command may orche
|
|
|
211
216
|
| Skip `spec-register` | Add `plans[]` row before implement |
|
|
212
217
|
| Build starts coding in the parent session | Resume PM context; dispatch implement work or block on missing Assignment |
|
|
213
218
|
| Follow-up only in chat / no roadmap section | Add `Roadmap / deferred scope` to CreatePlan and SSOT plan before implement |
|
|
214
|
-
| Phase 1 Plan mode:
|
|
219
|
+
| Phase 1 Plan mode: second CreatePlan / stale open plan | Edit the original plan file only; merge+delete duplicates |
|
|
220
|
+
| Phase 1 Plan mode: interview loop before feedback-close | Feedback-driven autonomous plan updates; deferred interview only after close signal if gaps remain |
|
|
215
221
|
| Phase 1 Plan mode: Review / commit / branch before Build | Keep Pre-Build document-only; execute those todos after Build |
|
|
216
222
|
|
|
217
223
|
## Related skills
|
|
@@ -29,7 +29,7 @@ Before **SwitchMode → Agent**: mirror plan exists; `status.json` lists `plan_i
|
|
|
29
29
|
|
|
30
30
|
After **Build**: treat the run as plan resume, not `/pm` replay. Reload `mstar-harness-core` + this Cursor reference, resume Morning Star plans as `project-manager` orchestration, and dispatch implementation through Task unless the user explicitly overrides the harness.
|
|
31
31
|
|
|
32
|
-
**`mstar-iteration` Phase 1 in Plan mode**: CreatePlan blank scaffold **
|
|
32
|
+
**`mstar-iteration` Phase 1 in Plan mode**: CreatePlan **once** (blank scaffold); then **feedback-driven** in-place updates on that same plan file; deferred interview only after user signals feedback-close **and** gaps remain; **do not** run Review & Edit / commit / integration branch until **Build**. Detail → **`cursor-plan-mode-bridge.md`** § `mstar-iteration` Phase 1 in Plan mode.
|
|
33
33
|
|
|
34
34
|
Enforcement: `rules/mstar-cursor-plan-mode.mdc` when plugin active.
|
|
35
35
|
|
|
@@ -92,11 +92,18 @@ compass/plans 初稿落盘前,必须锁定**单一**迭代方向、成功标
|
|
|
92
92
|
| **`interactive`** | **默认**(未显式声明 mode 时一律用此) | 与用户/产品**逐问**收敛方向与 branch policy;不得静默默认 `main`/`master` |
|
|
93
93
|
| **`autonomous`** | **仅**当 caller / Assignment **显式**声明 `Direction lock mode: autonomous`(或等价书面 opt-in) | 代码优先调研 → 排序候选 → **锁定推荐方向并落盘 rationale**;不因「是否同意该方向」例行问用户。细则 → **`references/autonomous-direction-lock.md`** |
|
|
94
94
|
|
|
95
|
-
**宿主 Plan UX(interactive)**:若宿主提供 Plan 会话(先写 session plan、后点 Build 才执行 todos
|
|
95
|
+
**宿主 Plan UX(interactive)**:若宿主提供 Plan 会话(先写 session plan、后点 Build 才执行 todos):
|
|
96
|
+
|
|
97
|
+
- 允许 **先 scaffold 空白 Phase 1 文档/todos**,再以 **用户反馈驱动** 收敛:Agent 探索并写入推荐,**原地更新同一份** session plan;用户提方向/意见,**不以**例行问卷为主路径。
|
|
98
|
+
- Branch policy:在 plan 中写推荐值 + rationale(不得静默 `main`/`master`);用户可用反馈改正;仅在用户明确结束反馈后仍缺字段时再追问。
|
|
99
|
+
- 访谈式收敛 **仅**在反馈结束后仍有阻塞缺口时可选发起。
|
|
100
|
+
- **禁止**为更新内容再开第二份 session plan。
|
|
101
|
+
|
|
102
|
+
**非** Plan 会话仍按「收敛后再写 compass/plans 初稿」的默认顺序。此条 **不**改变 autonomous 路径,也 **不**要求非 Plan 宿主先写空文件。
|
|
96
103
|
|
|
97
104
|
**禁止**:在未显式 opt-in 时自行切换到 `autonomous`(例如仅因读了本 skill 或存在 roadmap next)。
|
|
98
105
|
|
|
99
|
-
**Branch policy gate(interactive — 默认路径)**:若用户、现有 roadmap、或项目约定未明确 `iteration_base_branch` / `target_branch`,PM
|
|
106
|
+
**Branch policy gate(interactive — 默认路径)**:若用户、现有 roadmap、或项目约定未明确 `iteration_base_branch` / `target_branch`,PM 必须检查当前分支并向用户确认(**Plan 会话**走上方「推荐写入 plan + 反馈改正」;非 Plan 仍须确认)。**不得**因为存在 `main` / `master` 就默认从默认分支开 iteration 或向默认分支提 PR。
|
|
100
107
|
|
|
101
108
|
**Autonomous branch resolve**:仅 `autonomous` 模式;解析顺序与 STOP 规则见 **`references/autonomous-direction-lock.md`**(勿把该顺序套用到 interactive 以跳过向用户确认)。
|
|
102
109
|
|