dsh-charter 0.3.1 → 0.3.3

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 (57) hide show
  1. package/CHANGELOG.md +45 -0
  2. package/CHANGELOG.zh.md +40 -0
  3. package/README.md +55 -23
  4. package/README.zh.md +45 -19
  5. package/docs/README.md +4 -2
  6. package/docs/README.zh.md +5 -3
  7. package/docs/assets/charter-graph-0.3.3.png +0 -0
  8. package/docs/assets/charter-graph-0.3.3.zh.png +0 -0
  9. package/docs/assets/charter-graph-root-text-200-0.3.2.png +0 -0
  10. package/docs/assets/charter-pane-0.3.3.png +0 -0
  11. package/docs/assets/charter-pane-0.3.3.zh.png +0 -0
  12. package/docs/assets/charter-state-applied-0.3.2.png +0 -0
  13. package/docs/assets/charter-state-conflict-0.3.2.png +0 -0
  14. package/docs/assets/charter-state-empty-0.3.2.png +0 -0
  15. package/docs/assets/charter-state-forced-colors-0.3.2.png +0 -0
  16. package/docs/assets/charter-state-reduced-motion-0.3.2.png +0 -0
  17. package/docs/assets/charter-state-staged-0.3.2.png +0 -0
  18. package/docs/design/charter-dependency-graph-v1.zh.md +5 -4
  19. package/docs/design/charter-draft-calibration-v1.zh.md +617 -0
  20. package/docs/design/charter-draft-extraction-v1.zh.md +346 -0
  21. package/docs/design/charter-gui-v1.zh.md +31 -18
  22. package/docs/design/compatibility.md +11 -5
  23. package/docs/design/compatibility.zh.md +10 -5
  24. package/docs/design/version-roadmap.md +12 -15
  25. package/docs/design/version-roadmap.zh.md +14 -11
  26. package/docs/release-notes/0.3.1.md +7 -4
  27. package/docs/release-notes/0.3.2.md +35 -0
  28. package/docs/release-notes/0.3.3.md +32 -0
  29. package/docs/release-notes/README.md +1 -1
  30. package/docs/releasing.md +6 -4
  31. package/docs/releasing.zh.md +6 -4
  32. package/docs/user-guide.md +16 -2
  33. package/docs/user-guide.zh.md +15 -2
  34. package/docs/verification.md +73 -48
  35. package/docs/verification.zh.md +69 -44
  36. package/lib/client/DependencyGraph.d.ts +2 -0
  37. package/lib/client/bootstrap-plan.d.ts +9 -1
  38. package/lib/client/draft-store.d.ts +12 -1
  39. package/lib/client/locales.d.ts +12 -0
  40. package/lib/client/pane-scope.d.ts +2 -0
  41. package/lib/client/store.d.ts +12 -1
  42. package/lib/client.js +567 -240
  43. package/lib/core/bootstrap.d.ts +14 -0
  44. package/lib/core/schemas.d.ts +3 -0
  45. package/lib/core/structured-bootstrap.d.ts +49 -0
  46. package/lib/core.js +2 -2
  47. package/lib/{fork-KSL6sovw.js → fork-h8Gx4AJd.js} +178 -166
  48. package/lib/host/draft-translation.d.ts +47 -0
  49. package/lib/host/service.d.ts +19 -1
  50. package/lib/host/types.d.ts +43 -0
  51. package/lib/index.js +3 -3
  52. package/lib/remote/service.d.ts +6 -1
  53. package/lib/remote/wire.d.ts +91 -2
  54. package/lib/remote.js +116 -4
  55. package/lib/{service-BSrE7Kbu.js → service-CPha5Ipx.js} +734 -42
  56. package/lib/version.d.ts +1 -1
  57. package/package.json +19 -18
package/CHANGELOG.md CHANGED
@@ -5,6 +5,51 @@ English | [中文](CHANGELOG.zh.md)
5
5
  All notable changes to `dsh-charter` are recorded here. The project follows a pre-1.0 version line while the
6
6
  DSH plugin ABI is still moving.
7
7
 
8
+ ## 0.3.3 — 2026-11-24 (released)
9
+
10
+ Structured draft extraction and automatic zh/en language following. No record-schema, prompt-projection, or model-tool change.
11
+
12
+ ### Added
13
+
14
+ - `charter/bootstrapDraft`: structured candidates with stable refs, language tags, duplicate folding, and oversized/truncated markers.
15
+ - Sentence-boundary-only semantic splitting; no silent hard-split fragments.
16
+ - Exact and conservative prefix duplicate folding with representative, fold count, and member refs.
17
+ - Automatic zh/en normalization: when the draft language differs from the DSH UI locale, the Host performs one bounded strict-JSON translation call through the session model; missing/invalid models fall back to the source draft with a visible notice.
18
+ - Compatibility: DSH `0.2.2-rc.4` and `0.2.2-rc.5` added to `engines`/peer/`dshReleases`; thirteen-version local matrix covers the latest `0.2.2-rc.5` baseline.
19
+ - Additive `objective.initialize.clientRef` and structured `applyBootstrap` validation; legacy `charter/bootstrap` and `applyBootstrap` behavior stays byte-compatible.
20
+
21
+ ### Verification
22
+
23
+ - Source gates and new structured/translation tests are expected on the final tree; run the full `npm run check` before release.
24
+ - This candidate is not published; `0.3.2` remains the latest published release.
25
+
26
+ ## 0.3.2 — 2026-11-16
27
+
28
+ Accessibility/evidence convergence patch for the 0.3.x line. No record-schema, Remote-wire, or prompt change.
29
+
30
+ ### Added
31
+
32
+ - Root-text graph scaling: when the root font size exceeds 16px, the whole graph canvas scales as a unit
33
+ (capped at 200%) and the viewport becomes scrollable, avoiding new node-text clipping.
34
+ - A source metric for the graph's 44px path hit target and a pure `graphTextScale` test.
35
+ - Final-build evidence for empty/staged/applied/conflict-confirmation, forced-colors, reduced-motion, and
36
+ breakpoint/root-font measurements.
37
+
38
+ ### Changed
39
+
40
+ - Reconciled the 0.3.0 GUI design header and Appendix D against the published 0.3.0/0.3.1 releases; carried
41
+ unfinished manual gates explicitly into 0.3.2.
42
+ - Marked the dependency-graph design Active with real AT and root-text gaps as public known gaps.
43
+ - Refreshed verification's current-status section for 0.3.1/0.3.2 and cleaned roadmap/docs-index pending wording.
44
+
45
+ ### Verification
46
+
47
+ - `npm run check`: 42 files / **500 tests** PASS; token coverage over 11 declared DSH versions PASS;
48
+ `verify:ui-metrics -- --gate=final` PASS.
49
+ - Eleven-version source matrix PASS on the 0.3.2 tree.
50
+ - Manual gates still open: real VoiceOver/NVDA, native Desktop window matrix, and final human sign-off on the
51
+ frozen mockup side-by-side review.
52
+
8
53
  ## 0.3.1 — 2026-11-13
9
54
 
10
55
  GUI convergence patch for the dependency graph, standing-envelope observability, and local traffic forensics.
package/CHANGELOG.zh.md CHANGED
@@ -4,6 +4,46 @@
4
4
 
5
5
  记录 `dsh-charter` 的重要变更。DSH 插件 ABI 仍在演进,项目保持 pre-1.0 版本线。
6
6
 
7
+ ## 0.3.3 — 2026-11-24(已发布)
8
+
9
+ 结构化契约草案抽取与自动中英文语言跟随;不改变 record schema、prompt 投影或模型工具面。
10
+
11
+ ### 新增
12
+
13
+ - `charter/bootstrapDraft`:带稳定 ref、语言标注、重复折叠和 oversized/截断标记的结构化候选。
14
+ - 只按句边界做语义保全切分,不再静默硬切碎片。
15
+ - 全等/保守前缀重复折叠为代表条目,并保留折叠计数与成员 ref。
16
+ - 自动中英文归一:草案语言与 DSH 界面语言不一致时,Host 通过当前会话模型做一次有界、严格 JSON 的翻译调用;模型缺失或响应不合格时保留原文草案并显示降级提示。
17
+ - `objective.initialize.clientRef` additive 字段与结构化 `applyBootstrap` 校验;legacy `charter/bootstrap` / `applyBootstrap` 行为保持字节兼容。
18
+
19
+ ### 验证
20
+
21
+ - 最终树需通过 `npm run check`、结构化/翻译测试、兼容矩阵和 UI 指标门禁。
22
+ - 本候选未发布;`0.3.2` 仍是最新已发布版本。
23
+
24
+ ## 0.3.2 — 2026-11-16
25
+
26
+ 0.3.x 的无障碍/证据收敛补丁。不改变 record schema、Remote wire 或 prompt。
27
+
28
+ ### 新增
29
+
30
+ - 根字号图形缩放:根字号大于 16px 时,整个画布等比缩放(最多 200%),viewport 可滚动,避免节点文本新增裁切。
31
+ - 图形 44px 命中路径的源码度量,以及 `graphTextScale` 纯函数测试。
32
+ - 最终构建的空/暂存/已应用/冲突确认、forced-colors、reduced-motion 和断点/根字号测量证据。
33
+
34
+ ### 变更
35
+
36
+ - 将 0.3.0 GUI 设计状态头和附录 D 与 0.3.0/0.3.1 已发布事实对账;未完成的人工门禁显式转入 0.3.2。
37
+ - 依赖图文档转为 Active,并把真实 AT 与根字号缺口标为公开已知缺口。
38
+ - verification 当前状态节刷新到 0.3.1/0.3.2,清理 roadmap/docs index 的 pending 措辞。
39
+
40
+ ### 验证
41
+
42
+ - `npm run check`:42 文件 / **500 测试** PASS;11 个声明 DSH 版本 token 覆盖 PASS;
43
+ `verify:ui-metrics -- --gate=final` PASS。
44
+ - 0.3.2 树的十一版本源码矩阵 PASS。
45
+ - 仍待人工:真实 VoiceOver/NVDA、Desktop 原生窗口矩阵、冻结稿并排人工签收。
46
+
7
47
  ## 0.3.1 — 2026-11-13
8
48
 
9
49
  依赖图、standing envelope 可观测性与本地流量取证的 GUI 收敛补丁。不改变 record schema、Remote wire 或
package/README.md CHANGED
@@ -2,9 +2,9 @@
2
2
 
3
3
  [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
4
4
  [![GitHub](https://img.shields.io/badge/GitHub-centella--cream%2Fdsh--charter-181717?logo=github)](https://github.com/centella-cream/dsh-charter)
5
- [![DSH](https://img.shields.io/badge/DSH-11%20verified%20versions-4b6bfb)](docs/design/compatibility.md)
5
+ [![DSH](https://img.shields.io/badge/DSH-13%20verified%20versions-4b6bfb)](docs/design/compatibility.md)
6
6
  [![Node](https://img.shields.io/badge/node-%5E22.19%20%7C%7C%20%3E%3D24-339933)](package.json)
7
- [![Status: 0.3.1](https://img.shields.io/badge/status-0.3.1-brightgreen)](#status)
7
+ [![Status: 0.3.3](https://img.shields.io/badge/status-0.3.3-brightgreen)](#status)
8
8
 
9
9
  English | [中文](README.zh.md)
10
10
 
@@ -14,12 +14,12 @@ English | [中文](README.zh.md)
14
14
  [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness). Goals, hard constraints,
15
15
  deliverables, evidence, and dependency relationships survive compaction and remain visible and editable.
16
16
 
17
- ![Charter Pane in the document-feel layout](docs/assets/charter-pane-0.3.1.png)
17
+ ![Charter Pane in the document-feel layout](docs/assets/charter-pane-0.3.3.png)
18
18
 
19
19
  > The Pane in a local Web profile: underline area tabs, a 720px document column, aligned document
20
20
  > rows, and a compact execution-path disclosure. Screenshot uses synthetic demo values only.
21
21
 
22
- ![Dependency graph in the Pane](docs/assets/charter-graph-0.3.1.png)
22
+ ![Dependency graph in the Pane](docs/assets/charter-graph-0.3.3.png)
23
23
 
24
24
  > The execution-path dependency graph: lane headings, the three-column execution grid, and the state/type
25
25
  > legend. Edge arrows and hit targets appear when dependencies exist. The semantic list remains authoritative.
@@ -45,15 +45,12 @@ deliverables, evidence, and dependency relationships survive compaction and rema
45
45
 
46
46
  ## Status
47
47
 
48
- - **Current development candidate:** `0.3.1` — the GUI convergence release. It keeps the frozen document-feel Pane and closes
49
- the dependency-graph audit and standing-envelope observability gaps. It ships the document-feel Pane across
50
- Workspace, Review Center, and Diagnostics; the dependency graph; the bounded DSH compatibility declaration;
51
- and the Host tool fix that exposes deliverable ids to `charter_propose.requires`. **Not published yet;** latest published release is `0.3.0`.
52
- - **Previous release:** `0.2.2` — dependency-graph workspace view, compact dependency list, and explicit
53
- dependency-conflict confirmation.
54
- - **Earlier release:** `0.2.1`; **primary DSH baseline:** `0.2.2-rc.3`; eleven declared DSH versions are
55
- source-matrix verified.
56
- - Versioning from `0.2.0` onward uses plain increments (`0.2.0`, `0.2.1`, `0.2.2`, `0.3.0`, `0.3.1`), never an `rc`
48
+ - **Current release:** `0.3.3` — structured draft extraction with automatic zh/en language normalization,
49
+ duplicate folding, stable candidate refs, deferred non-blocking translation, and adaptive batch handling for
50
+ custom model latency. Published to npm `latest`/`next` and GitHub Release `v0.3.3`.
51
+ - **Previous release:** `0.3.2` — accessibility/evidence convergence; `0.3.1` and `0.3.0` are earlier baselines.
52
+ **Primary DSH baseline:** `0.2.2-rc.5`; thirteen declared DSH versions are source-matrix verified.
53
+ - Versioning from `0.2.0` onward uses plain increments (`0.2.0`, `0.2.1`, `0.2.2`, `0.3.0`, `0.3.1`, `0.3.2`, `0.3.3`), never an `rc`
57
54
  suffix.
58
55
 
59
56
  ## Core capabilities
@@ -82,10 +79,35 @@ deliverables, evidence, and dependency relationships survive compaction and rema
82
79
  - **Traffic forensics:** the local `traffic-check` reports `charter_propose` rejection categories and active
83
80
  charter-surface hashes; `traffic-diff` compares before/after baselines. No runtime telemetry or upload is added.
84
81
 
82
+ ### Accessibility and evidence convergence
83
+
84
+ - **Root-text graph scaling:** when the root text size is larger than 16px, the graph canvas scales as a unit
85
+ (up to 200%) so node text, edges, lanes, and hit targets stay aligned; the viewport becomes scrollable rather
86
+ than clipping the graph.
87
+ - **Final-build evidence:** empty, staged, applied, and conflict-confirmation states, forced-colors and
88
+ reduced-motion captures, plus breakpoint/scaling measurements were recorded for the 0.3.2 release.
89
+ - **Known manual gates:** real VoiceOver/NVDA and native Desktop-window evidence are not claimed by automated
90
+ AX-tree or renderer screenshots.
91
+
92
+ ### Structured draft extraction and language following
93
+
94
+ - **Semantic extraction:** candidates are split only at sentence boundaries; an oversized sentence is kept
95
+ whole and marked instead of being cut into fragments, and explicit truncation records the original byte count.
96
+ - **Duplicate folding:** exact and conservative prefix duplicates are folded into one representative with a
97
+ fold count and member refs, so repeated constraints do not flood the review.
98
+ - **Language following:** when the reviewed draft language differs from the DSH UI language (`zh`/`en`), the
99
+ Host renders the source-language draft first, then performs bounded, strict-JSON translation calls through the
100
+ configured session model in the background and replaces the draft only while it is still pristine. If no model is
101
+ available or the response is invalid, the source-language draft remains usable with a visible fallback notice.
102
+ The automatic call sends the compaction draft/current-charter text to that configured model; the plugin stores no
103
+ API key and adds no telemetry or upload path. Set `languageFollow: false` in the profile config to disable the
104
+ automatic model call; deterministic extraction/folding still runs and the source-language draft remains usable.
105
+ `languageFollowTimeoutMs` bounds each background batch (default 60s); failed batches split/retry and successful candidates are kept. Custom-API users can set `languageFollowProvider`/`languageFollowModel` to pin normalization to a dedicated model.
106
+
85
107
  ### Compatibility and runtime
86
108
 
87
- - DSH `0.2.2-rc.3` declarations plus a bounded `engines.dsh` 0.2-line range; exact `dshReleases`/peer list
88
- remains the eleven-version matrix-verified support set.
109
+ - DSH `0.2.2-rc.5` declarations plus a bounded `engines.dsh` 0.2-line range; exact `dshReleases`/peer list
110
+ remains the thirteen-version matrix-verified support set.
89
111
  - `charter_read standing` now exposes stable deliverable ids so the model can propose real `requires`
90
112
  references; `D<n>` labels are documented as display-only, and invalid references fail explicitly.
91
113
  - Desktop and Web plugin bundles hot-reload through the Host profile recomposition/client HMR path; CSS is
@@ -191,17 +213,17 @@ storage.
191
213
 
192
214
  ## Install
193
215
 
194
- The latest published release is `0.3.0`:
216
+ The current release is `0.3.3`:
195
217
 
196
218
  ```bash
197
- dsh plugin --profile web add dsh-charter@0.3.0
219
+ dsh plugin --profile web add dsh-charter@0.3.3
198
220
  ```
199
221
 
200
- The `0.3.1` development candidate is not published. Build/accept it from the working tree:
222
+ For air-gapped machines or exact-artifact verification:
201
223
 
202
224
  ```bash
203
- npm pack
204
- dsh plugin --profile web add ./dsh-charter-0.3.1.tgz
225
+ npm pack dsh-charter@0.3.3
226
+ dsh plugin --profile web add ./dsh-charter-0.3.3.tgz
205
227
  ```
206
228
 
207
229
  For Desktop, use **Desktop → Plugins → Install/Update**, or import the same local tarball if your Desktop build
@@ -210,8 +232,9 @@ that profile.
210
232
 
211
233
  ### Requirements
212
234
 
213
- - DSH: only the versions listed in the [compatibility matrix](docs/design/compatibility.md) are supported.
214
- `0.2.1+` is required for per-Peer Remote resource authorization.
235
+ - DSH: only the versions listed in the [compatibility matrix](docs/design/compatibility.md) are supported;
236
+ the current primary baseline is `0.2.2-rc.5` (thirteen-version local matrix). `0.2.1+` is required for per-Peer
237
+ Remote resource authorization.
215
238
  - Node.js **`^22.19.0 || >=24.0.0`**.
216
239
  - A Web or Desktop profile.
217
240
 
@@ -262,6 +285,11 @@ Defaults live in `cordis.patch.yml`. Override them in the profile patch:
262
285
  maxObjectiveBytes: 4096
263
286
  maxItemBytes: 1024
264
287
  contextOrder: 130
288
+ languageFollow: true
289
+ languageFollowTimeoutMs: 60000
290
+ # Optional dedicated translation route; omit to use the session model.
291
+ languageFollowProvider: your-provider
292
+ languageFollowModel: your-fast-model
265
293
  ```
266
294
 
267
295
  | Field | Default | Meaning |
@@ -279,6 +307,10 @@ Defaults live in `cordis.patch.yml`. Override them in the profile patch:
279
307
  | `maintenanceLimit` | 16 | recent initialize/restore receipts |
280
308
  | `maxRecoveryBytes` | 4194304 | full recovery-archive budget |
281
309
  | `contextOrder` | 130 | runtime-context order |
310
+ | `languageFollow` | true | normalize a review draft to the active `zh`/`en` DSH language through the session model; set `false` to disable the automatic call |
311
+ | `languageFollowTimeoutMs` | 60000 | upper bound for one background translation call; per-batch failures split and keep source text |
312
+ | `languageFollowProvider` | unset | optional provider route for language normalization; requires `languageFollowModel` |
313
+ | `languageFollowModel` | unset | optional model for language normalization; omit both to use the current session model |
282
314
 
283
315
  The only model-visible capacity is `maxPromptBytes`; `maxItems` and `maxPendingItems` bound storage.
284
316
 
@@ -289,7 +321,7 @@ The only model-visible capacity is `maxPromptBytes`; `maxItems` and `maxPendingI
289
321
  | `0.1.7-rc.2` | Supported (minimum) |
290
322
  | `0.2.0-rc.1` / `0.2.0-rc.2` | Supported |
291
323
  | `0.2.1-rc.1` / `0.2.1-rc.2` / `0.2.1-rc.3` / `0.2.1-rc.4` / `0.2.1-rc.5` | Supported |
292
- | `0.2.2-rc.1` / `0.2.2-rc.2` / `0.2.2-rc.3` | Supported (primary baseline: `0.2.2-rc.3`) |
324
+ | `0.2.2-rc.1` / `0.2.2-rc.2` / `0.2.2-rc.3` / `0.2.2-rc.4` / `0.2.2-rc.5` | Supported (primary baseline: `0.2.2-rc.5`) |
293
325
  | `0.3.x` | Not declared until verified |
294
326
 
295
327
  `engines.dsh` uses a bounded 0.2-line range (`0.1.7-rc.2 || >=0.2.0-rc.1 <0.3.0-0`), evaluated with
package/README.zh.md CHANGED
@@ -2,9 +2,9 @@
2
2
 
3
3
  [![License: MIT](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE)
4
4
  [![GitHub](https://img.shields.io/badge/GitHub-centella--cream%2Fdsh--charter-181717?logo=github)](https://github.com/centella-cream/dsh-charter)
5
- [![DSH](https://img.shields.io/badge/DSH-11%20verified%20versions-4b6bfb)](docs/design/compatibility.zh.md)
5
+ [![DSH](https://img.shields.io/badge/DSH-13%20verified%20versions-4b6bfb)](docs/design/compatibility.zh.md)
6
6
  [![Node](https://img.shields.io/badge/node-%5E22.19%20%7C%7C%20%3E%3D24-339933)](package.json)
7
- [![Status: 0.3.1](https://img.shields.io/badge/status-0.3.1-brightgreen)](#状态)
7
+ [![Status: 0.3.3](https://img.shields.io/badge/status-0.3.3-brightgreen)](#状态)
8
8
 
9
9
  [English](README.md) | 中文
10
10
 
@@ -13,12 +13,12 @@
13
13
  `dsh-charter` 是 [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) 的持久化、用户所有的
14
14
  会话契约插件。目标、硬约束、交付物、证据和依赖关系在上下文压缩后仍然保留,并且始终可查看、可编辑。
15
15
 
16
- ![文档感布局中的会话契约页](docs/assets/charter-pane-0.3.1.zh.png)
16
+ ![文档感布局中的会话契约页](docs/assets/charter-pane-0.3.3.zh.png)
17
17
 
18
18
  > 本地 Web profile 中的 Pane:顶部下划线 tabs、720px 文档列、对齐的文档行和可折叠执行路径。
19
19
  > 截图仅使用合成演示数据。
20
20
 
21
- ![Pane 中的依赖关系图](docs/assets/charter-graph-0.3.1.zh.png)
21
+ ![Pane 中的依赖关系图](docs/assets/charter-graph-0.3.3.zh.png)
22
22
 
23
23
  > 执行路径依赖图:泳道标题、三列执行网格和状态/类型 legend;存在依赖时显示方向箭头与沿边命中区。语义列表始终是权威操作面。
24
24
 
@@ -43,12 +43,10 @@
43
43
 
44
44
  ## 状态
45
45
 
46
- - **当前开发候选:**`0.3.1` — GUI 收敛版本。保留冻结的文档感 Pane,并关闭依赖图审计和 standing envelope 可观测性缺口。
47
- 包含文档感 Pane、依赖关系图、有界 DSH 兼容声明,以及让 `charter_propose.requires` 可用交付物 id 的
48
- Host 工具修复。**尚未发布**;最新已发布版本为 `0.3.0`。
49
- - **上一版本:**`0.2.2` — 依赖关系图形视图、紧凑依赖列表和依赖冲突二次确认。
50
- - **更早版本:**`0.2.1`;**主要 DSH 基线:**`0.2.2-rc.3`;十一个声明版本通过源码矩阵验证。
51
- - 从 `0.2.0` 起版本号使用普通递增(`0.2.0`、`0.2.1`、`0.2.2`、`0.3.0`、`0.3.1`),不再使用 `rc` 后缀。
46
+ - **当前发布:**`0.3.3` — 结构化契约草案抽取、自动中英文语言归一、相似重复折叠、稳定候选 ref、非阻塞后台翻译,以及针对自定义模型延迟的自适应分批。已发布到 npm `latest`/`next` 和 GitHub Release `v0.3.3`。
47
+ - **上一版本:**`0.3.2` — 无障碍/证据收敛;`0.3.1`、`0.3.0` 是更早基线。
48
+ **主要 DSH 基线:**`0.2.2-rc.5`;十三个声明版本通过源码矩阵验证。
49
+ - 从 `0.2.0` 起版本号使用普通递增(`0.2.0`、`0.2.1`、`0.2.2`、`0.3.0`、`0.3.1`、`0.3.2`、`0.3.3`),不再使用 `rc` 后缀。
52
50
 
53
51
  ## 核心能力
54
52
 
@@ -75,9 +73,28 @@
75
73
  - **流量取证:** 本地 `traffic-check` 增加 `charter_propose` 拒绝分类和 active charter surface hash;
76
74
  `traffic-diff` 对比前后基线。不新增运行时埋点、不上报。
77
75
 
76
+ ### 无障碍与证据收敛
77
+
78
+ - **根字号图形缩放:** 根字号大于 16px 时,画布作为整体等比缩放(最多 200%),节点文本、边、泳道和命中区
79
+ 保持对齐;viewport 改为可滚动,而不是裁切图形。
80
+ - **最终构建证据:** 空/暂存/已应用/冲突确认状态、forced-colors 与 reduced-motion 截图,以及断点/缩放
81
+ 测量记录于 0.3.2 发布。
82
+ - **仍待人工门禁:** 真实 VoiceOver/NVDA 与 Desktop 原生窗口证据;自动化 AX-tree 或 renderer 截图不计为
83
+ 已通过。
84
+
85
+ ### 结构化草案抽取与语言跟随
86
+
87
+ - **语义保全:**只按句边界切分;超长句整段保留并标记,不再硬切成碎片;显式截断记录原始字节数。
88
+ - **相似重复折叠:**全等/保守前缀重复折叠为代表条目,并保留折叠计数与成员 ref。
89
+ - **语言跟随:**草案语言与 DSH 界面语言(`zh`/`en`)不一致时,Host 不等待模型:先立即返回源语言草案,再在后台通过当前会话模型做有界、严格 JSON 的分批翻译,并在草案仍未被操作时替换。模型不可用或响应不合格时
90
+ 保留原文草案并显示降级提示,不阻断审阅。自动调用会把压缩草案/当前契约
91
+ 文本发送到该会话配置的模型;插件不保存 API key,也不新增遥测或上传。可在 profile 设置
92
+ `languageFollow: false` 关闭自动调用;结构化抽取/折叠仍生效,源语言草案仍可用。
93
+ `languageFollowTimeoutMs` 限制每批后台翻译等待(默认 60 秒);失败批会拆分重试并保留成功候选。自定义 API 用户可设置 `languageFollowProvider`/`languageFollowModel` 固定专用翻译模型。
94
+
78
95
  ### 兼容性与运行时
79
96
 
80
- - DSH `0.2.2-rc.3` 声明与有界 `engines.dsh` 0.2 线范围;精确 `dshReleases`/peer 列表仍是十一版本矩阵已验证支持集。
97
+ - DSH `0.2.2-rc.5` 声明与有界 `engines.dsh` 0.2 线范围;精确 `dshReleases`/peer 列表仍是十三版本矩阵已验证支持集。
81
98
  - `charter_read standing` 现在返回交付物稳定 id,模型可以提出真实 `requires` 引用;`D<n>` 明确只是展示标签,
82
99
  非法引用显式失败。
83
100
  - Desktop/Web 插件通过 Host profile 重组 + client HMR 热更新;CSS 按归属 style tag upsert,重载后替换旧样式,
@@ -169,17 +186,17 @@ compaction summary 返回只读草案,不写 storage。
169
186
 
170
187
  ## 安装
171
188
 
172
- 最新已发布版本是 `0.3.0`:
189
+ 当前发布版本是 `0.3.3`:
173
190
 
174
191
  ```bash
175
- dsh plugin --profile web add dsh-charter@0.3.0
192
+ dsh plugin --profile web add dsh-charter@0.3.3
176
193
  ```
177
194
 
178
- `0.3.1` 开发候选尚未发布;从工作区构建并验收:
195
+ 离线机器或需要精确验证 artifact 时:
179
196
 
180
197
  ```bash
181
- npm pack
182
- dsh plugin --profile web add ./dsh-charter-0.3.1.tgz
198
+ npm pack dsh-charter@0.3.3
199
+ dsh plugin --profile web add ./dsh-charter-0.3.3.tgz
183
200
  ```
184
201
 
185
202
  Desktop 请使用 **Desktop → Plugins → Install/Update**;若 Desktop 构建支持本地插件导入,也可导入同一
@@ -187,8 +204,8 @@ tarball。`dsh plugin --profile desktop` 会被拥有该 profile 的 Electron
187
204
 
188
205
  ### 要求
189
206
 
190
- - DSH:仅支持[兼容矩阵](docs/design/compatibility.zh.md)中列出的版本;`0.2.1+` 才具备 per-Peer Remote
191
- resource authorization。
207
+ - DSH:仅支持[兼容矩阵](docs/design/compatibility.zh.md)中列出的版本;当前主基线是 `0.2.2-rc.5`
208
+ (十三版本本地矩阵);`0.2.1+` 才具备 per-Peer Remote resource authorization。
192
209
  - Node.js **`^22.19.0 || >=24.0.0`**。
193
210
  - Web 或 Desktop profile。
194
211
 
@@ -237,6 +254,11 @@ active-count 失败。
237
254
  maxObjectiveBytes: 4096
238
255
  maxItemBytes: 1024
239
256
  contextOrder: 130
257
+ languageFollow: true
258
+ languageFollowTimeoutMs: 60000
259
+ # 可选:专用翻译路由;省略则使用当前会话模型
260
+ languageFollowProvider: your-provider
261
+ languageFollowModel: your-fast-model
240
262
  ```
241
263
 
242
264
  | 字段 | 默认值 | 含义 |
@@ -254,6 +276,10 @@ active-count 失败。
254
276
  | `maintenanceLimit` | 16 | 最近 initialize/restore receipt |
255
277
  | `maxRecoveryBytes` | 4194304 | 完整 recovery archive 预算 |
256
278
  | `contextOrder` | 130 | runtime-context 顺序 |
279
+ | `languageFollow` | true | 按当前 `zh`/`en` DSH 界面语言通过模型归一草案;设为 `false` 关闭自动调用 |
280
+ | `languageFollowTimeoutMs` | 60000 | 单批后台翻译等待上限;失败批会拆分并保留源文 |
281
+ | `languageFollowProvider` | 未设置 | 可选专用翻译 provider;需同时设置 model |
282
+ | `languageFollowModel` | 未设置 | 可选专用翻译模型;两者都不设时使用当前会话模型 |
257
283
 
258
284
  模型可见容量只有 `maxPromptBytes`;`maxItems` 和 `maxPendingItems` 约束存储。
259
285
 
@@ -264,7 +290,7 @@ active-count 失败。
264
290
  | `0.1.7-rc.2` | 支持(最低版本) |
265
291
  | `0.2.0-rc.1` / `0.2.0-rc.2` | 支持 |
266
292
  | `0.2.1-rc.1` / `0.2.1-rc.2` / `0.2.1-rc.3` / `0.2.1-rc.4` / `0.2.1-rc.5` | 支持 |
267
- | `0.2.2-rc.1` / `0.2.2-rc.2` / `0.2.2-rc.3` | 支持(主基线:`0.2.2-rc.3`) |
293
+ | `0.2.2-rc.1` / `0.2.2-rc.2` / `0.2.2-rc.3` / `0.2.2-rc.4` / `0.2.2-rc.5` | 支持(主基线:`0.2.2-rc.5`) |
268
294
  | `0.3.x` | 验证前不声明 |
269
295
 
270
296
  `engines.dsh` 使用有界的 0.2 线范围(`0.1.7-rc.2 || >=0.2.0-rc.1 <0.3.0-0`),DSH gate 会按 prerelease
package/docs/README.md CHANGED
@@ -51,8 +51,10 @@ same commit. Do not delete a historical decision just because it is inactive; mo
51
51
  | --- | --- | --- | --- |
52
52
  | [design/charter-design-v1.md](design/charter-design-v1.md) | Active | 0.1 core; invariants apply to 0.2 | Core Charter invariants and v1 product baseline. |
53
53
  | [design/charter-workspace-v2.zh.md](design/charter-workspace-v2.zh.md) | Active | 0.2.0 / 0.3.0 | Workspace, proposal timeline, dependencies; topic-scoped. |
54
- | [design/charter-dependency-graph-v1.zh.md](design/charter-dependency-graph-v1.zh.md) | Active | 0.2.2 / 0.3.1 | Client-side dependency graph view. Source implementation lands on the 0.2.2 line; real browser/AT and W0-1/2/3 gate evidence remains pending. |
55
- | [design/charter-gui-v1.zh.md](design/charter-gui-v1.zh.md) | Active | 0.3.0 / 0.3.1 | All-section GUI refactor: design system, IA/routing, Change Set contract, Pane/store split, evidence gates. Frozen visual language (document-feel): [design/mockups/](design/mockups/README.md). |
54
+ | [design/charter-dependency-graph-v1.zh.md](design/charter-dependency-graph-v1.zh.md) | Active | 0.2.2 / 0.3.1 / 0.3.2 | Client-side dependency graph view. Source implementation lands on the 0.2.2 line; real browser evidence is recorded; real AT and W0-1/2/3 remain 0.3.2 gates. |
55
+ | [design/charter-gui-v1.zh.md](design/charter-gui-v1.zh.md) | Active | 0.3.0 / 0.3.1 / 0.3.2 | All-section GUI refactor: design system, IA/routing, Change Set contract, Pane/store split, evidence gates. Frozen visual language (document-feel): [design/mockups/](design/mockups/README.md). |
56
+ | [design/charter-draft-extraction-v1.zh.md](design/charter-draft-extraction-v1.zh.md) | Implemented — pending release acceptance | 0.3.3 | Draft-extraction quality and automatic zh/en language following: semantics-preserving splits, near-duplicate folding, structured candidates with stable refs, bounded background batch translation with per-batch retry/partial fallback and optional dedicated model. Implemented locally; release acceptance pending. |
57
+ | [design/charter-draft-calibration-v1.zh.md](design/charter-draft-calibration-v1.zh.md) | Proposed | 0.4.0 candidate | Future advanced draft calibration: semantic aggregation, original-vs-calibrated diff review, quality A/B; host-managed `ctx.llm` opt-in, zero record-schema change; depends on the implemented 0.3.3 extraction layer. |
56
58
  | [design/version-roadmap.md](design/version-roadmap.md) | Active | whole line | Scope/version authority; Chinese is normative. |
57
59
  | [design/compatibility.md](design/compatibility.md) | Active | declared DSH versions | Compatibility claims and matrix. |
58
60
  | [history/2026-10-19-charter-design-v1-review.md](history/2026-10-19-charter-design-v1-review.md) | Historical | 0.1 | Frozen v1 design review. |
package/docs/README.zh.md CHANGED
@@ -48,9 +48,11 @@
48
48
  | 文档 | 状态 | 版本范围 | 说明 |
49
49
  | --- | --- | --- | --- |
50
50
  | [design/charter-design-v1.md](design/charter-design-v1.md) | Active | 0.1 核心;不变量适用于 0.2 | Charter 核心不变量与 v1 产品基线。 |
51
- | [design/charter-workspace-v2.zh.md](design/charter-workspace-v2.zh.md) | Active | 0.2.0 / 0.3.0 / 0.3.1 | 工作区、提案时间线、依赖;专题范围。 |
52
- | [design/charter-dependency-graph-v1.zh.md](design/charter-dependency-graph-v1.zh.md) | Active | 0.2.2 / 0.3.1 | 客户端依赖关系图形视图;源码已在 0.2.2 落地,真实浏览器/AT 与 W0-1/2/3 门禁证据仍待完成。 |
53
- | [design/charter-gui-v1.zh.md](design/charter-gui-v1.zh.md) | Active | 0.3.0 / 0.3.1 | 全栏目 GUI 全面重构:设计系统、IA/路由、Change Set 合同、Pane/store 拆分、证据门禁;视觉语言已冻结(文档感):[design/mockups/](design/mockups/README.md)。 |
51
+ | [design/charter-workspace-v2.zh.md](design/charter-workspace-v2.zh.md) | Active | 0.2.0 / 0.3.0 / 0.3.1 / 0.3.2 | 工作区、提案时间线、依赖;专题范围。 |
52
+ | [design/charter-dependency-graph-v1.zh.md](design/charter-dependency-graph-v1.zh.md) | Active | 0.2.2 / 0.3.1 / 0.3.2 | 客户端依赖关系图形视图;源码已在 0.2.2 落地,真实浏览器证据已记录;真实 AT 与 W0-1/2/3 仍属 0.3.2 门禁。 |
53
+ | [design/charter-gui-v1.zh.md](design/charter-gui-v1.zh.md) | Active | 0.3.0 / 0.3.1 / 0.3.2 | 全栏目 GUI 全面重构:设计系统、IA/路由、Change Set 合同、Pane/store 拆分、证据门禁;视觉语言已冻结(文档感):[design/mockups/](design/mockups/README.md)。 |
54
+ | [design/charter-draft-extraction-v1.zh.md](design/charter-draft-extraction-v1.zh.md) | Implemented — pending release acceptance | 0.3.3 | 契约草案抽取质量与自动中英文语言跟随:语义保全切分、近重复折叠、结构化候选与稳定 ref、宿主模型后台分批翻译、每批重试/partial 回退与可选专用模型;已本地实现,待发布验收。 |
55
+ | [design/charter-draft-calibration-v1.zh.md](design/charter-draft-calibration-v1.zh.md) | Proposed | 0.4.0 候选 | 后续高级草案校准:语义聚合、原文 diff 审阅、质量 A/B;宿主托管 `ctx.llm` opt-in,零 record schema 变更;依赖已实现的 0.3.3 抽取层。 |
54
56
  | [design/version-roadmap.md](design/version-roadmap.md) | Active | 全版本线 | 范围与版本权威;中文为 normative。 |
55
57
  | [design/compatibility.md](design/compatibility.md) | Active | 已声明 DSH 版本 | 兼容声明与矩阵。 |
56
58
  | [history/2026-10-19-charter-design-v1-review.md](history/2026-10-19-charter-design-v1-review.md) | Historical | 0.1 | 冻结的 v1 设计评审。 |
@@ -1,9 +1,9 @@
1
1
  # `dsh-charter` 依赖关系图形化视图设计(提案)
2
2
 
3
- > **状态:** `Implemented — pending release acceptance`——0.3.1 已完成方向箭头、泳道标题、沿边 44px 命中路径和历史线型;
4
- > 真实浏览器自动化已记录,真实 AT/VoiceOver 人工门禁仍待完成。进入发布前仍以[版本路线](version-roadmap.zh.md)为准
3
+ > **状态:** `Active`——0.2.2/0.3.1 已实现并发布;方向箭头、泳道标题、沿边 44px 命中路径和历史线型已发布。
4
+ > **公开已知缺口:** 真实 AT/VoiceOver、200% 根字号文本缩放、W0-1/2 实测仍属 0.3.2 跟踪项。
5
5
  > ([charter-workspace-v2.zh.md](charter-workspace-v2.zh.md) §1.1)。
6
- > **版本范围:** `0.2.2` / `0.3.1`(纯客户端)。源码实现已完成;发布前仍需完成真实 AT 人工门禁(§3.10)。
6
+ > **版本范围:** `0.2.2` / `0.3.1` 已发布;`0.3.2` 负责真实 AT、根字号缩放和实测收敛。
7
7
  > **形态:** **A —— 图形增强,语义列表常驻且为权威操作面**(已确认,§0.2)。
8
8
  > **基准:** 2026-11-09,基于已发布 `0.2.1` 之后的开发树。
9
9
  > **权威边界:** 版本范围由[版本路线](version-roadmap.zh.md)决定;不变量由 [v1 核心设计](charter-design-v1.zh.md)
@@ -15,7 +15,8 @@
15
15
  >
16
16
  > **0.3.1 几何决策:** 实现已采用固定 px 几何(184px 节点、`PX_PER_EM=18.4`、`PX_PER_EM_Y=22`)。
17
17
  > 本文 D19 与 §3.7 的 em 契约保留为历史分析;当前权威几何规格是 [charter-gui-v1.zh.md](charter-gui-v1.zh.md) §5.7。
18
- > 200% **根字号文本缩放**尚未由 W0-2 覆盖;W0-2 现有证据是字号 10/14/22 + 200% page scale。
18
+ > **0.3.2 根字号处理:** 根字号 >16px 时整个画布按比例缩放(上限 200%),viewport 横向滚动;16/24/32px
19
+ > 实测无新增文本裁切。W0-2 的 page-scale 证据仍不等同于根字号证据。
19
20
 
20
21
  ## 0. 目标与形态取舍
21
22