@mstar-harness/dsh 3.7.3 → 3.8.1

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.
Files changed (40) hide show
  1. package/README.i18n.yaml +2 -2
  2. package/README.md +127 -189
  3. package/README.zh.md +14 -12
  4. package/bundle/README.md +84 -165
  5. package/dist/client/index.d.ts +22 -7
  6. package/dist/client/panel/MstarPanelTitle.d.ts +13 -0
  7. package/dist/client/panel/PanelView.d.ts +75 -49
  8. package/dist/client/panel/TabNav.d.ts +17 -14
  9. package/dist/client/panel/definition.d.ts +23 -0
  10. package/dist/client/panel/engine-status-client.d.ts +187 -0
  11. package/dist/client/panel/graph/project-graph.d.ts +13 -55
  12. package/dist/client/panel/graph/schema.d.ts +1 -2
  13. package/dist/client/panel/guards.d.ts +52 -3
  14. package/dist/client/panel/locale.d.ts +1 -1
  15. package/dist/client/panel/mstar-glyph.d.ts +22 -0
  16. package/dist/client/panel/pages/AgentListPage.d.ts +71 -0
  17. package/dist/client/panel/pages/EventLogPage.d.ts +7 -4
  18. package/dist/client/panel/pages/IterationInfoSection.d.ts +16 -13
  19. package/dist/client/panel/pages/IterationTaskPage.d.ts +13 -14
  20. package/dist/client/panel/panel-meta.d.ts +2 -2
  21. package/dist/client/panel/panel-store.d.ts +28 -0
  22. package/dist/client/panel/sidebar.d.ts +12 -7
  23. package/dist/client/panel/state-section.d.ts +2 -2
  24. package/dist/client/panel/use-mstar-engine-status.d.ts +105 -32
  25. package/dist/client/panel/zones/Legend.d.ts +5 -3
  26. package/dist/client/panel/zones/TaskBoard.d.ts +13 -9
  27. package/dist/client.js +1017 -1236
  28. package/dist/engine-status-endpoint.d.ts +154 -0
  29. package/dist/engine-status-store.d.ts +190 -0
  30. package/dist/engine-status-wire.d.ts +29 -0
  31. package/dist/gates/_shared.d.ts +9 -0
  32. package/dist/gates/catalog.d.ts +8 -8
  33. package/dist/gates/system-prompt.d.ts +1 -1
  34. package/dist/index.d.ts +1 -1
  35. package/dist/index.js +528 -94
  36. package/dist/types.d.ts +40 -19
  37. package/harness-skills/mstar-artifacts/references/status-and-residuals.md +1 -1
  38. package/harness-skills/mstar-host/references/dsh.md +94 -219
  39. package/package.json +67 -63
  40. package/dist/client/panel/pages/AgentCanvasPage.d.ts +0 -345
package/dist/types.d.ts CHANGED
@@ -1,11 +1,16 @@
1
1
  /**
2
- * `mstar-engine-status` catalog source: a durable `catalog`-form
3
- * MessageSource the plugin appends to
4
- * every composed step at `agent/pre-step`, so the model-visible engine-status
5
- * row is reconstructable from the session log without re-parsing its prose
6
- * (model-visible ⟺ logged — dsh packages/AGENTS.md). Merge-extensible
7
- * `MessageSourceMap` augmentation mirroring the `@deepseek-ai/dsh-tool-skill`
8
- * precedent (declare module '@deepseek-ai/dsh-llm' + catalog-form source).
2
+ * `mstar-engine` catalog source + payload: the durable `catalog`-form
3
+ * MessageSource the plugin appends to every composed step at
4
+ * `agent/pre-step`, so the model-visible engine-status row is
5
+ * reconstructable from the session log without re-parsing its prose
6
+ * (model-visible ⟺ logged — dsh packages/AGENTS.md), plus the NON-persisted
7
+ * payload that row is rendered from.
8
+ *
9
+ * The source is the first-party `plugin` arm and nothing else: dsh freezes
10
+ * the source vocabulary per released session-format edge, so a custom `kind`
11
+ * or any extra `source` member makes a released edge refuse the whole session
12
+ * log. The structured facts live in
13
+ * {@link MstarEngineStatusPayload} instead.
9
14
  *
10
15
  * `mstar-iteration-gate` is the sibling catalog row: the boot-cached
11
16
  * `evaluatePhaseGate` verdict (tool result shape) appended after the
@@ -16,15 +21,36 @@
16
21
  */
17
22
  import type { EnforcementFlag } from '@mstar-harness/engine';
18
23
  /**
19
- * Durable provenance for the ONE unified engine-status catalog row. The
20
- * catalog is a `catalog`-form context, so it records the facts it published
21
- * beside the model-facing prose: a consumer presenting the row must not
22
- * re-parse the `<mstar_engine_status>` block, whose framing exists for the
23
- * model.
24
+ * The ONE unified engine-status catalog row's `source`: the first-party
25
+ * `plugin` arm with a CLOSED member set — exactly these three keys, never a
26
+ * fourth.
27
+ *
28
+ * `plugin` carries the plugin's identity and `form: 'catalog'` the row's
29
+ * first-party presentation; both are opaque, already-admitted vocabulary at
30
+ * every released session-format edge. Everything the row publishes about the
31
+ * workspace lives in {@link MstarEngineStatusPayload}, which never rides
32
+ * `source`.
33
+ *
34
+ * The `plugin` union is the PERSISTED-LOG vocabulary, not a write-time
35
+ * choice: the plugin emits `mstar-engine`, while rows emitted by shipped
36
+ * builds before 2026-09-11 persist `mstar-engine-status` in already-written
37
+ * session logs. Both are valid persisted rows; the panel's anchor reader
38
+ * accepts both (data compat for persisted session logs, not a code-compat
39
+ * layer).
24
40
  */
25
41
  export interface MstarEngineStatusSource {
26
- readonly kind: 'mstar-engine-status';
42
+ readonly kind: 'plugin';
43
+ readonly plugin: 'mstar-engine' | 'mstar-engine-status';
27
44
  readonly form: 'catalog';
45
+ }
46
+ /**
47
+ * The engine-status payload the model-facing row is rendered from — the
48
+ * facts the catalog publishes BESIDE the prose (a consumer presenting the row
49
+ * must not re-parse the `<mstar_engine_status>` block, whose framing exists
50
+ * for the model). Deliberately NOT persisted on the message `source`: no
51
+ * released historical session-format edge admits extra `source` members.
52
+ */
53
+ export interface MstarEngineStatusPayload {
28
54
  /**
29
55
  * The unified mstar version: the `@mstar-harness/dsh` plugin package
30
56
  * version (own manifest). The single-version invariant pins the bundled
@@ -187,7 +213,7 @@ export type WorkflowSelectionView = {
187
213
  * one-liner. All fields come from the same per-workspace cached build as
188
214
  * the rest of the row (one status.json / compass / knowledge-index read
189
215
  * per cache refresh — the TTL-bounded staleness tradeoff documented on
190
- * `buildCatalogSources`).
216
+ * `buildCatalogPayload`).
191
217
  */
192
218
  export interface MstarHarnessState {
193
219
  /**
@@ -332,8 +358,3 @@ export interface AgentFlowView {
332
358
  readonly events: readonly AgentFlowEventView[];
333
359
  readonly summary: readonly AgentFlowSummaryRow[];
334
360
  }
335
- declare module '@deepseek-ai/dsh-llm' {
336
- interface MessageSourceMap {
337
- 'mstar-engine-status': MstarEngineStatusSource;
338
- }
339
- }
@@ -157,7 +157,7 @@ Body conventions (`## Direction` + goal items as `- [ ]` / `- [x]` markdown task
157
157
 
158
158
  ## Fail-loud handoff contract
159
159
 
160
- Findings must pass engine validation **before** registration into the project register: `validateResidual(entry)` per entry, `validateProjectRegister(doc)` for the whole register, `validateWorkflowSnapshot(doc)` for the snapshot, `validateStatus` for the v2 root (`mstar status validate <path>` / engine import). Malformed entries — **non-object**, missing any of the nine required fields (`id`, `title`, `severity`, `source`, `scope`, `decision`, `owner`, `target`, `tracking` — mirroring engine `RESIDUAL_REQUIRED_FIELDS` in `packages/engine/src/status.ts`), or **severity** outside the enum — are **rejected** (`ok:false` + violation): fix and rewrite — never silent pass-through, downgrade-write, or “write then patch”.
160
+ Findings must pass engine validation **before** registration into the project register: `validateResidual(entry)` per entry, `validateProjectRegister(doc)` for the whole register, `validateWorkflowSnapshot(doc)` for the snapshot, `validateStatus` for the v2 root (`mstar status validate <path>` / engine import). Malformed entries — **non-object**, missing any of the nine required fields (`id`, `title`, `severity`, `source`, `scope`, `decision`, `owner`, `target`, `tracking` — mirroring engine `RESIDUAL_REQUIRED_FIELDS` in `packages/engine/src/status.ts`), or **`severity`** / **`decision`** outside their enums (`status.residual.invalid-severity` / `status.residual.invalid-decision`) — are **rejected** (`ok:false` + violation): fix and rewrite — never silent pass-through, downgrade-write, or “write then patch”. A *lifecycle* value such as `"resolved"` in `decision` leaves the **whole register unwritable** — `validateProjectRegister(doc)` then fails the document, so the engine refuses every subsequent write to that register, not just that entry.
161
161
 
162
162
  dsh-derived findings map their keys per the engine-residual validation verification spec §5; dsh keys never enter the schema.
163
163
 
@@ -34,217 +34,94 @@ or a custom profile).
34
34
  - Web client plugin (workflow panel): the same `mstar` bundle row carries a
35
35
  browser client half (`dsh.client` + `exports["./client"]`) discovered
36
36
  automatically by `ClientModuleHostService` — no separate profile layer or
37
- install step. It registers a **`conversation.view`** view-ring tab
38
- (`id: 'mstar-workflow'`, `order: 20`) labeled **"MStar 工作流" / "MStar
39
- Workflow"** rendering the latest `mstar-engine-status` catalog row as the
40
- **MStar Workflow layout** — a right sidebar (plans ≤5 in time-desc order +
41
- `+N more`, open residual findings ≤10 with severity chips + overflow hint,
42
- policy with **enforcement first** then push / worktree / control worktree,
43
- leases, knowledge, direction) over a bottom **fixed meta dock** (version +
44
- harness dir; small muted, hairline-separated, does NOT scroll with the
45
- sidebar digest — the former header row was removed), and an **HTML/CSS zone
46
- dashboard** (the react-flow cyclic graph was removed in plan
47
- `20260810-panel-canvas-zones`): the canvas fills the Tab (the page never
48
- scrolls; the zone container is the only scroll body) with an **iteration
49
- zone** (Step 1–5 stepper + `Step N/5` badge + active-highlight / inactive
50
- dimmed state; the steps carry a FOUR-STATE machine — `current` / `next` /
51
- `done` / `idle` (plan `20260812-panel-f5-iteration-zone-fix` Task 1): every
52
- step BEFORE the current one projects `done`「已完成」(completed — a finished
53
- Step 1 must not read as idle while Step 2 is current), `next` is the single
54
- forward target, `idle` is schema-only + the branch panel — iteration base /
55
- target / spec integration, rendered only while active; the expanded head is
56
- a LEFT-RIGHT SPLIT — branches (small left half, WIDTH-CAPPED — `flex: 0 1
57
- 260px` + `max-width: 280px`, never stretches with the container; the <860px
58
- column stack resets to content height) + steps (large right half, `flex: 1 1
59
- 0` absorbing the remaining width) via `data-iteration-head-split`, stacking
60
- on narrow widths, and NO branch panel
61
- when there is no active iteration; the current step follows the steering
62
- compass: `compassStatus: 'active'` (Phase 1 in flight) → Step 1
63
- (iteration-start) is CURRENT with verdict `unknown` — no PASS/FAIL badge,
64
- plan `20260811-panel-f4-iteration-zone`; **the iteration info section is
65
- SHARED by the tasks AND agents tabs** (plan
66
- `20260812-panel-f5-design-system` Task 8, user round-4 decision #4 — one
67
- `IterationInfoSection` component, both tabs render the same `view.iteration`
68
- block: summary + steps + branches), a **tasks zone** (5-column
69
- kanban: Todo / InProgress / InReview / Done / `blocked-unknown` — the
70
- Blocked state and the former `unknown` catch-all fold into ONE merged
71
- column titled「受阻/未知」/「Blocked / Unknown」, plan
72
- `20260813-panel-quick-fixes` Task 1 — with count badges; every column
73
- caps its rendered rows at `PLAN_CAP` and shows a clickable 「更多」/「收起」
74
- expand button (`data-kanban-more` anchor) unfolding the full column — the
75
- projection keeps ALL plan rows, the cap is a render concern never a
76
- discard), an **agent-execution zone** (the FOUR EXPECTED_ROLE_FLOW stage/phase
77
- columns — review-edit-chain → sdd-implement → qc-tri → qa-gate, the
78
- terminal stage; the former `sdd-task-review` stage is removed and its SDD
79
- L2 reviewer is now the PIPELINE role `code-reviewer` (v2.1.1, the former
80
- `generalPurpose` seat) — a strict FOUR-column layout with NO standalone
81
- unknown column (plan `20260812-panel-f5-design-system` Task 5, user
82
- 2026-08-12 round-2 decision — the former rightmost UNKNOWN column of plan
83
- `20260812-panel-f5-agent-layout` is superseded): the `general` bucket
84
- sinks into an **unknown SUB-PARTITION at the bottom of the `qa-gate`
85
- column** (a `data-sub-bucket="unknown"` caption row 「unknown / 未匹配角色」
86
- after the last qa-gate card, then the general cards; the standalone
87
- on-demand column was already removed in the agent-layout plan); `explore`
88
- is removed — no card, no column. The columns are laid out in **TWO
89
- side-by-side Phase groups** (plan `20260812-panel-f5-design-system` Task 8,
90
- user round-4 decision #2; side-by-side layout per plan
91
- `20260813-panel-agent-canvas-legend-layout` Task 2): the **Phase 1 group
92
- on the LEFT** (review-edit-chain — the sequential Review & Edit chain:
93
- product-manager → architect → writing-specialist) and the **Phase 2 group
94
- on the RIGHT** (sdd-implement → qc-tri → qa-gate — the iterative plan
95
- loop), top-aligned (all group label rows share the same `y = PAD_Y`), each
96
- with its group label row; the **Phase-2 label annotates the CURRENT PLAN**
97
- (projected `agents.activePlanId` = the first InProgress `state.plans[]`
98
- row, `data-canvas-group-plan`; `+N more` when several plans run in
99
- parallel, muted「无进行中 plan」when none). The `sdd-implement` column is split into SUB-BUCKETS by
100
- the PROJECTED `entity.bucket` (never a render guess): the **implementor**
101
- partition ABOVE — the flow roles in the stage's original order
102
- (fullstack-dev / fullstack-dev-2 / frontend-dev), then the on-demand
103
- roles (ops-engineer / prompt-engineer, carrying the **on-demand badge** —
104
- the standalone on-demand column is gone) — and the **sdd-reviewer**
105
- partition BELOW (code-reviewer, idle included), with the implementor /
106
- sdd-reviewer caption labels; `zone: 'on-demand'` entities live in the
107
- implementor partition, `zone: 'general'` entities render in the qa-gate
108
- column's bottom unknown sub-partition. The subagent ENTITY cards aggregate **by role** from actual
109
- dispatch evidence: the same role across sessions folds into one card ×N,
110
- and every off-roster dispatch (the former `generalPurpose` SDD reviewer,
111
- `scout`, anonymous `role === ''`) folds into the single `general` bucket
112
- entity — the card is ROLE-TITLED (the role id, e.g. `fullstack-dev`); the
113
- agent session id / task tag (`planId#taskId`) ride the RECORD line, never
114
- the title. Cards show the role chip / status point / ×N count; running
115
- entities carry the business glow-pulse
116
- highlight, un-evidenced stages render the dashed "待执行" pending
117
- placeholder with their expected role chips, un-evidenced KNOWN_AGENTS
118
- members render dashed idle cards (the full 14-role roster is never
119
- hidden), and the header shows the `N executing · M pending` summary.
120
- Cards carry the projected **emphasis tier** (plan
121
- `20260812-panel-f5-design-system` Task 4, design doc §3): `emphasis:
122
- 'current' | 'next' | 'off' | null` — the iteration's current-phase roles
123
- render at **100%** chrome intensity, later-phase expected roles at **75%**,
124
- already-passed / stage-less (on-demand, general) roles at **45%**, and
125
- `null` (no iteration / unresolved transition) applies NO override — always
126
- a chrome **alpha mix** (`--mstar-canvas-emphasis-*` tokens; never a
127
- whole-card `opacity`, so the status point + running glow stay opaque).
128
- Settled entities get a **standalone GREEN done frame + green ✓** (plan
129
- `20260812-panel-f5-design-system` Task 8, user round-4 decisions #1/#3:
130
- `data-agent-done="true"` — a full-strength success border + 1px ring on
131
- the rounded card body + the ✓ in the status point) **ONLY when
132
- `emphasis ≠ 'off'`** — an off-tier role (already-passed / stage-less
133
- on-demand + general) renders the muted dot instead and NEVER shows the
134
- completion marker (the completed state never appears on a stage-less
135
- role). The canvas filters to the CURRENT iteration only (plan
136
- `20260813-panel-quick-fixes` Task 2): dispatch evidence projects for the
137
- current iteration's plans — the steering compass `iterationId` when
138
- active, else the nearest iteration derived from the catalog
139
- `plans[].iterationRefs` (the most-recent plan's refs by 8-digit id date
140
- prefix + doneAt); provably cross-iteration events produce no entity/edge
141
- (the roster keeps its idle cards); plan-less / unknown-plan / standalone
142
- dispatches are never hidden. Status honesty (Task 2): `advisory` is NO
143
- LONGER terminal — a soft-enforcement dispatch falls through to its paired
144
- settle (green ✓ when a settle exists, `running` when none) while `denied`
145
- stays terminal; the advisory verdict still renders in the event log. The
146
- canvas legend sits BELOW the viewport (Task 3 — moved from above, user
147
- 2026-08-13 feedback).
148
- Edges (plan `20260812-panel-f5-design-system` Task 5, design doc §2):
149
- the `expected` stage skeleton arrows AND the ANIMATED **next** edge (the
150
- former `@keyframes agent-dash-flow` dash-flow arrow of plan
151
- `20260810-panel-agent-flow-zone`) are **REMOVED** — flow order is implied
152
- by the fixed column order + column labels, the current position by the
153
- running card glow + status point — leaving TWO semantic kinds: the
154
- evidence-driven **`actual` handoff** edges (same-plan ts-adjacent dispatch
155
- entity-key pairs, `general` endpoints filtered, ≤1 per entity pair) drawn
156
- as **bezier `C` curves** anchored to card **PORTS** — 4 fixed
157
- edge-midpoint ports (north / south / east / west; static-invisible,
158
- hover-revealed as small dots) with the arrow tip pulled back to a **10px
159
- standoff** off the port — the arrow follows the line's local tangent at
160
- the anchor (**H1**), and no line's stroke or arrow crosses any text
161
- (**H2**: standoff + side-gap routing, design doc §2.0/§2.5/§2.6;
162
- tightened in plan `20260813-panel-quick-fixes` Task 3 — same-column
163
- vertical flows whose center-x line would cross an in-between card body
164
- (e.g. fullstack-dev → frontend-dev skipping an idle fullstack-dev-2)
165
- reroute into the column's LEFT side gap, forward AND reverse, and reverse
166
- horizontal beziers keep direction-aware control points BETWEEN the
167
- endpoints so they never bulge into the adjacent column) — plus
168
- the **bidirectional supervise line** (plan `20260812-panel-f5-agent-layout`
169
- Task 1/2) — ONE static design-knowledge sub-bucket edge inside the
170
- `sdd-implement` column (implementor ↔ sdd-reviewer — the mstar-sdd
171
- mutual-supervision contract), now anchored at the **side-gap vertical
172
- anchor** (`x = card right edge + 18px`, vertical bezier flow, arrows along
173
- the vertical tangent — design doc §2.5/§2.7); dim dashed by default, lit
174
- business SOLID when the projected `evidenced` flag is true —
175
- evidence-driven lighting, never a fabricated activation); the 事件记录 tab
176
- (`EventLogPage`, spec panel-tabs §5, plan `20260811-panel-event-log`) is a
177
- NON-canvas log page with two partitions — **Agent 流转事件** (`view.events`
178
- ≤50 latest-first; off-pipeline unexpected dispatches fold in once via
179
- `expected: false` and carry a dispatch-only 「未匹配角色」 badge — settle
180
- rows are completion records and never flag as unexpected) and **违规记录**
181
- (`view.violations`, gate violations with severity/code/message); every row
182
- is an expandable native `<details>` (no-JS, keyboard-accessible) whose body
183
- shows the full catalog fields — missing fields render「—」, never a guessed
184
- value. Layout (plan `20260811-panel-f3-agent-general`): the two partitions
185
- render SIDE BY SIDE in a locked-height two-column grid
186
- (`repeat(2, minmax(0, 1fr))` — the page never scrolls as a whole; each
187
- partition pins its title and owns an internal `overflow-y` scroll on its
188
- row list; plan `20260813-panel-quick-fixes` Task 4 root-caused the
189
- whole-page scroll — the panel root opts into the host
190
- `data-conversation-composer-overlay` (the host's documented full-height
191
- opt-in), so the host `.viewArea` becomes a definite-height container and
192
- `height:100%` resolves: `.rowList`'s `overflow-y: auto` now scrolls
193
- INSIDE the partition and the host page no longer scrolls, with bottom
194
- clearance reserving the floating composer via the host-published
195
- `--dsh-composer-height`), falling back to two stacked 50/50 locked rows
196
- below 1200px —
197
- the `data-event-log-*` anchor family is unchanged. The canvas-corner **`AgentEventDock`** is REMOVED with the page
198
- (无双份日志 — its row layout + status chips migrated into `EventLogPage`);
199
- the fixed footer bar (zone legend + gate summary + violations) died with
200
- the WorkflowCanvas in plan `20260811-panel-tabs-shell` — the footer that
201
- remains is the freshness marker. Empty branches (spec §2 — plan
202
- `20260812-panel-f5-agent-layout` Task 3): waiting keeps the muted hint,
203
- and NO harness renders a **CENTERED inactive-state card** (folder icon +
204
- 「No Morning Star harness detected」 title + the hint copy — the detail
205
- panel stays inactive, no tabs / no sidebar, activating automatically once
206
- a harness is detected; the `data-mstar-empty="no-harness"` anchor stays on
207
- the title, `data-mstar-graph` on the main container). Below 1200px
208
- the zones stack vertically. Pure `projectGraph` projection (never throws,
209
- explicit degraded states — muted empty states, never orange warn boxes).
210
- The branches block left the sidebar in plan `20260810-panel-sidebar-info`
211
- (its anchor fields stay in the catalog source; the iteration zone renders
212
- them via plan `20260810-panel-canvas-zones`); refresh follows the session
213
- snapshot, no polling — while the main agent is ACTIVELY orchestrating, a
214
- ledger record (dispatch/settle) invalidates the workspace's TTL-cached
215
- catalog row so the next pre-step rebuilds and (digest text change)
216
- re-injects it, and the panel refreshes per step (seconds, not the 60 s TTL);
217
- while the main agent IDLES (waiting, no tool calls) the panel keeps the
218
- LAST snapshot — no live push channel (documented limit, plan
219
- `20260811-panel-f4-timeliness`). Bundle served at
220
- `/plugins/@mstar-harness/dsh/client.js` (closure-factory CJS with NO graph
221
- library inlined — react-flow removed; the build asserts the bundle contains
222
- no `xyflow`/`reactflow` markers, no `@deepseek-ai/*` value imports, and no
223
- `import.meta` / ESM statements — the loader runs plugin bundles as classic
224
- scripts). **Known limitations**: the stepper's Step 1 (iteration-start) IS
225
- the current step while the steering compass is `status: active` (Phase 1 in
226
- flight — catalog `compassStatus` field), carrying NO PASS/FAIL badge (Phase
227
- 1 has no gate verdict); Step 5 (merge-ready) can never be the CURRENT step —
228
- the engine phase gate only evaluates Phase 2→3→4 (merge-ready is never a gate
229
- transition); it renders `next` only while Step 4 (pr-delivery) is current,
230
- idle otherwise;
231
- the current step follows the TTL-refreshed `compassStatus` — up to one
232
- catalog interval (60 s) behind a mid-session `active`→`locked` flip (bounded,
233
- documented staleness, never a wrong verdict); the agent-entity
234
- status derivation pairs a PAIRED settle exactly by its dispatch identity
235
- (`agent`, `role`, `planId`, `taskId` — under QC-tri N=3 concurrency each
236
- settle lands on ITS dispatch), and an unpaired dispatch stays `running`
237
- (no paired settle — never guessed, never faked); the current-iteration
238
- filter with NO steering compass infers the iteration from plan ids
239
- (8-digit date prefix) + doneAt — deterministic, documented heuristic, and
240
- only provably cross-iteration events are dropped; no historical back-scan of
241
- resumed long logs; no custom
242
- top-level slot (the `conversation.view` tab is the only session-level panel
243
- seat without dsh-private layout changes); no-session → shell hero
244
- (strict-session view ring). Panel acceptance is dual-track: in-loop browser
245
- harness verification (agent-browser/CDP against the rebuilt bundle,
246
- iteration guides record the verified runs) plus user-restart final GUI
247
- acceptance.
37
+ install step. It registers a **right-Sidebar page tab type** (`id:
38
+ '@mstar-harness/dsh'`, `kind: 'mstar-workflow'`, one guide-page capsule at
39
+ `order: 20`) labeled **"启明星工作流" / "Morning
40
+ Star Workflow"** rendering the latest `mstar-engine` catalog **anchor** row
41
+ — the persisted source is the bare first-party `plugin` arm
42
+ (`{ kind: 'plugin', plugin: 'mstar-engine', form: 'catalog' }`, no
43
+ payload members; the anchor reader also accepts the legacy
44
+ `mstar-engine-status` identity from persisted logs), and the payload is fetched from the host's
45
+ `/api/mstar/engineStatus` endpoint (the gateway owns the route; the browser
46
+ half calls `connection.rpc.call('/api', 'mstar/engineStatus', { args: { sessionId, cwd } })`
47
+ and renders the session's stored snapshot, or an explicit unavailable
48
+ reason). **Morning Star Workflow layout**: a narrow-column shell bound to the
49
+ sidebar pane's definite height — exactly three zones: the **section nav**
50
+ (任务迭代 / 代理执行 / 事件记录; `data-mstar-tab-nav`), the panel-owned
51
+ **single scroll body** (`[data-mstar-scroll]` — the ONLY `overflow-y`
52
+ element in the panel; nothing scrolls horizontally; `data-mstar-graph`
53
+ rides it), and the pinned **meta dock** (version + harness dir; never
54
+ scrolls). The workspace-state digest (plans ≤5 time-desc + `+N more`,
55
+ open residual findings ≤10 with severity chips + overflow hint, policy
56
+ with **enforcement first** then push / worktree / control worktree,
57
+ leases, knowledge, direction) renders IN FLOW at the end of the scroll
58
+ body, closed by the freshness footer (`snapshot {time} · turn {turn}` —
59
+ the served snapshot's own timestamp + turn, never "live"). The three
60
+ sections stack in the scroll body: the tasks page (iteration head +
61
+ **vertical** 5-step stepper with the FOUR-STATE `current` / `next` /
62
+ `done` / `idle` machine + the branch panel + five stacked status groups
63
+ — the merged「受阻/未知」/「Blocked / Unknown」column kept, `PLAN_CAP`
64
+ render caps + the clickable 「更多」/「收起」 expand button
65
+ (`data-kanban-more`); the projection keeps ALL plan rows — then the
66
+ project rollup), the events page (two partitions — Agent 流转事件 /
67
+ 违规记录 — as flow rows, every row an expandable native `<details>`
68
+ carrying the full catalog fields, missing fields render 「—」 never a
69
+ guessed value), and the agents page — a **vertical grouped list** (the
70
+ react-flow canvas, its SVG edge layer, card ports and pointer pan are
71
+ REMOVED): two Phase groups in constant order (Phase 1 review-edit-chain
72
+ above; Phase 2 sdd-implement → qc-tri → qa-gate below, its label
73
+ annotating the CURRENT plan — `data-agent-group-plan` + `+N more`),
74
+ `sdd-implement` split into implementor / reviewer sub-partitions, the
75
+ `general` bucket sunk into an `unknown` sub-bucket, the full 14-role
76
+ roster as full-width flow rows (idle rows dashed muted — the roster is
77
+ never hidden) with role chip / status point / `×N` count / record line,
78
+ the `N executing · M pending` summary, and the three-entry legend in
79
+ flow below the list; rows carry the projected **emphasis tier**
80
+ (`--mstar-canvas-emphasis-*` chrome alpha mix — never a whole-row
81
+ `opacity`, so the status point + running glow stay opaque), settled
82
+ entities get the standalone GREEN done frame + ✓
83
+ (`data-agent-done="true"`) ONLY when `emphasis ≠ 'off'`; the agents page
84
+ contains zero `<svg>`, zero `data-agent-port` / `data-canvas-*` anchors
85
+ and no pan transform. The **iteration info section is shared by the
86
+ tasks AND agents pages** (one `IterationInfoSection`, both render the
87
+ same `view.iteration` block). Empty branches are explicit states —
88
+ `waiting` / `loading` / `unavailable` (with its reason) / no-harness
89
+ each carry their OWN anchor and copy and render no tabs, no digest and
90
+ no meta dock; no harness renders a CENTERED inactive-state card that
91
+ activates automatically once a harness is detected (inside the same
92
+ single scroll zone). Projection is the pure `projectGraph(source)`
93
+ function (schema constants vs catalog evidence strictly separated; never
94
+ throws; explicit degraded states — muted empty states, never orange warn
95
+ boxes). Refresh follows the session snapshot, no polling — while the
96
+ main agent is ACTIVELY orchestrating, a ledger record (dispatch/settle)
97
+ invalidates the workspace's TTL-cached catalog row so the next pre-step
98
+ rebuilds and (digest text change) re-injects it, and the panel refreshes
99
+ per step (seconds, not the 60 s TTL); while the main agent IDLES the
100
+ panel keeps the LAST snapshot — no live push channel. Bundle served at
101
+ `/plugins/@mstar-harness/dsh/client.js` (closure-factory CJS with NO
102
+ graph library inlined — react-flow removed; the build asserts the bundle
103
+ contains no `xyflow`/`reactflow` markers, no `@deepseek-ai/*` value
104
+ imports, and no `import.meta` / ESM statements — the loader runs plugin
105
+ bundles as classic scripts). Full realized layout detail:
106
+ `packages/dsh/README.md` (§ Web client plugin). **Known limitations**:
107
+ the stepper's Step 1 (iteration-start) IS the current step while the
108
+ steering compass is `status: active` (Phase 1 in flight — catalog
109
+ `compassStatus` field), carrying NO PASS/FAIL badge (Phase 1 has no gate
110
+ verdict); Step 5 (merge-ready) can never be the CURRENT step — the
111
+ engine phase gate only evaluates Phase 2→3→4; the current step follows
112
+ the TTL-refreshed `compassStatus` — up to one catalog interval (60 s)
113
+ behind a mid-session `active`→`locked` flip (bounded, documented
114
+ staleness, never a wrong verdict); the agent-entity status derivation
115
+ pairs a PAIRED settle exactly by its dispatch identity (`agent`, `role`,
116
+ `planId`, `taskId`), and an unpaired dispatch stays `running` (never
117
+ guessed, never faked); with NO steering compass the current-iteration
118
+ filter infers the iteration from plan ids (8-digit date prefix) +
119
+ doneAt — deterministic, documented heuristic, only provably
120
+ cross-iteration events are dropped, no historical back-scan of resumed
121
+ long logs; the sidebar chip title is captured at open time; a docked
122
+ body renders nothing while `tab.visible === false`. Panel acceptance is
123
+ dual-track: in-loop browser harness verification against the rebuilt
124
+ bundle plus user-restart final GUI acceptance.
248
125
 
249
126
  ## Skill loading
250
127
 
@@ -315,10 +192,8 @@ build (`catalogTtlMs`, default 60 s).
315
192
 
316
193
  The plugin records ACTUAL subagent dispatch and real-completion settle events —
317
194
  the evidence of what really happened, distinct from the client-side expected
318
- role flow. The workflow panel's agent-execution zone (the stage/entity
319
- projection — plan `20260810-panel-agent-flow-zone`) and the 事件记录 tab's
320
- `EventLogPage` log page (plan `20260811-panel-event-log`) are pure consumers
321
- of this evidence.
195
+ role flow. The workflow panel's 代理执行 (agents) page and the 事件记录
196
+ tab's `EventLogPage` log page are pure consumers of this evidence.
322
197
 
323
198
  - **Recording point (one core)**: `DshHostAdapter.dispatchGate` is the SINGLE
324
199
  record path behind both dispatch surfaces — the `tools/pre-execute` listener
@@ -346,8 +221,8 @@ of this evidence.
346
221
  summary. A MISSING file reads as the empty view ("no actual dispatches yet"
347
222
  — recording starts at plan merge); an unreadable file is absent evidence;
348
223
  malformed lines are skipped, never fatal.
349
- - **Settle = real completion pairing, never faked** (plan
350
- `20260811-panel-f4-timeliness`): `tools/post-execute` IS part of the
224
+ - **Settle = real completion pairing, never faked**: `tools/post-execute`
225
+ IS part of the
351
226
  verified dsh-tools registry surface (`runPostExecute` dispatches the
352
227
  waterfall for every tool call — verified against the upstream source and
353
228
  pinned by a real-call probe). The pairing listener matches dispatch TOOLS
@@ -377,8 +252,8 @@ of this evidence.
377
252
  top-5 + latest dispatch with HH:MM — the event detail lives in the
378
253
  structured source, never the model text). A ledger record (dispatch/settle)
379
254
  invalidates the affected workspace's TTL cache entry IMMEDIATELY
380
- (apply-scoped `harnessDir → cache key` reverse map + invalidation closure,
381
- plan `20260811-panel-f4-timeliness`) → the next pre-step rebuilds and (digest
255
+ (apply-scoped `harnessDir → cache key` reverse map + invalidation closure)
256
+ → the next pre-step rebuilds and (digest
382
257
  text change) re-injects the row — the 60 s TTL no longer bounds
383
258
  ledger-change latency; it still bounds non-ledger staleness.
384
259
  - **Maintainer view**: change the ledger shape (event schema, bounds, settle