dsh-charter 0.2.0 → 0.2.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.
- package/CHANGELOG.md +30 -1
- package/CHANGELOG.zh.md +27 -1
- package/CONTRIBUTING.md +12 -2
- package/CONTRIBUTING.zh.md +9 -2
- package/README.md +32 -18
- package/README.zh.md +28 -16
- package/docs/README.md +4 -3
- package/docs/README.zh.md +4 -3
- package/docs/assets/charter-pane.zh.png +0 -0
- package/docs/design/charter-design-v1.md +7 -3
- package/docs/design/charter-design-v1.zh.md +14 -1
- package/docs/design/charter-workspace-v2.zh.md +4 -3
- package/docs/design/version-roadmap.md +10 -9
- package/docs/design/version-roadmap.zh.md +8 -14
- package/docs/release-notes/0.2.0.md +7 -7
- package/docs/release-notes/0.2.1.md +56 -0
- package/docs/release-notes/README.md +2 -2
- package/docs/releasing.md +15 -8
- package/docs/releasing.zh.md +13 -8
- package/docs/user-guide.md +12 -7
- package/docs/user-guide.zh.md +9 -5
- package/docs/verification.md +33 -27
- package/docs/verification.zh.md +25 -23
- package/lib/client/locales.d.ts +35 -13
- package/lib/client/store.d.ts +5 -0
- package/lib/client.js +612 -179
- package/lib/host/domain.d.ts +50 -0
- package/lib/host/service.d.ts +18 -1
- package/lib/host/types.d.ts +35 -1
- package/lib/index.js +1 -1
- package/lib/remote/service.d.ts +8 -1
- package/lib/remote/wire.d.ts +124 -0
- package/lib/remote.js +133 -2
- package/lib/{service-C3A59BG5.js → service-CNjnvioR.js} +181 -3
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -5,7 +5,36 @@ 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.2.
|
|
8
|
+
## 0.2.1 — 2026-11-06 (release candidate)
|
|
9
|
+
|
|
10
|
+
Post-`0.2.0` UI, diagnostics, and recovery-cache patch. No record-schema bump; existing `0.2.0` records remain
|
|
11
|
+
readable.
|
|
12
|
+
|
|
13
|
+
### Added
|
|
14
|
+
|
|
15
|
+
- Editable message proposals: selecting a user message preloads its full text into an editable body; edited
|
|
16
|
+
proposals use manual provenance and the Host rejects non-human actors.
|
|
17
|
+
- Bounded recovery cache in the owner-only `dsh_charter_archives_v1` domain with `listArchives`/`readArchive`
|
|
18
|
+
Remote entries: at most five snapshots per Session and 25 per profile, oldest-first eviction.
|
|
19
|
+
- Diagnostics separates fact validity checks from evidence integrity; proposal batches render the query-plane
|
|
20
|
+
`sourceIntegrity` without an extra Host round trip.
|
|
21
|
+
|
|
22
|
+
### Changed
|
|
23
|
+
|
|
24
|
+
- Message-proposal, diagnostics, and recovery forms use one label/description hierarchy; the Pane header follows
|
|
25
|
+
the lighter `dsh-context` page-title scale and spacing.
|
|
26
|
+
- Recovery lists cached snapshots directly; download export is independent from restore. Local JSON import stays
|
|
27
|
+
available as an advanced path.
|
|
28
|
+
- README capability list and Pane screenshot describe the current 0.2.1 UI.
|
|
29
|
+
|
|
30
|
+
### Fixed
|
|
31
|
+
|
|
32
|
+
- Message proposal state resets when the Session changes; diagnostics state and feedback reset as well.
|
|
33
|
+
- Same-revision query views retain proposal batch integrity after an Apply.
|
|
34
|
+
- Cache snapshots survive Host restarts; no Session-disposal purge, and profile-wide LRU bounds orphan entries.
|
|
35
|
+
- Restore wording distinguishes cached recovery from imported files.
|
|
36
|
+
|
|
37
|
+
## 0.2.0 — 2026-11-05
|
|
9
38
|
|
|
10
39
|
Workspace and dependency-plan upgrade. Versioning from this release onward uses plain increments
|
|
11
40
|
(`0.2.0`, `0.2.1`, ...) and never an `rc` suffix.
|
package/CHANGELOG.zh.md
CHANGED
|
@@ -4,7 +4,33 @@
|
|
|
4
4
|
|
|
5
5
|
记录 `dsh-charter` 的重要变更。DSH 插件 ABI 仍在演进,项目保持 pre-1.0 版本线。
|
|
6
6
|
|
|
7
|
-
## 0.2.
|
|
7
|
+
## 0.2.1 — 2026-11-06(发布候选)
|
|
8
|
+
|
|
9
|
+
`0.2.0` 之后的 UI、诊断和恢复缓存补丁。不改变 record schema;已有 `0.2.0` 记录保持可读。
|
|
10
|
+
|
|
11
|
+
### 新增
|
|
12
|
+
|
|
13
|
+
- 可编辑消息提案:选择用户消息后把完整正文带入可编辑框;编辑后的提案使用 manual provenance,Host 拒绝
|
|
14
|
+
非人类 actor。
|
|
15
|
+
- owner-only `dsh_charter_archives_v1` 恢复缓存与 `listArchives`/`readArchive` Remote 入口:每 Session
|
|
16
|
+
最多 5 份、整个 profile 最多 25 份,最旧优先淘汰。
|
|
17
|
+
- 诊断区拆分事实有效性验证和证据完整性;proposal batch 直接渲染查询面的 `sourceIntegrity`,不再额外请求
|
|
18
|
+
Host。
|
|
19
|
+
|
|
20
|
+
### 变更
|
|
21
|
+
|
|
22
|
+
- 消息提案、诊断和恢复表单共用同一套标签/说明层级;Pane 页头采用更轻量的 `dsh-context` 标题比例和间距。
|
|
23
|
+
- 恢复区直接列出缓存快照;下载导出与恢复解耦。本地 JSON 导入保留为高级路径。
|
|
24
|
+
- README 能力列表和 Pane 截图更新为当前 0.2.1 界面。
|
|
25
|
+
|
|
26
|
+
### 修复
|
|
27
|
+
|
|
28
|
+
- Session 切换时重置消息提案状态,同时重置诊断状态和反馈。
|
|
29
|
+
- Apply 后同 revision 的查询视图仍保留 proposal batch 的 integrity。
|
|
30
|
+
- 缓存快照在 Host 重启后保留;不再随 Session dispose 清空,并用 profile 级 LRU 限制孤儿条目。
|
|
31
|
+
- 恢复文案区分缓存恢复和文件导入。
|
|
32
|
+
|
|
33
|
+
## 0.2.0 — 2026-11-05
|
|
8
34
|
|
|
9
35
|
工作区与依赖计划升级。从该版本起使用普通递增版本号(`0.2.0`、`0.2.1`……),不再使用 `rc` 后缀。
|
|
10
36
|
|
package/CONTRIBUTING.md
CHANGED
|
@@ -41,8 +41,18 @@ npm run check
|
|
|
41
41
|
## Branch workflow (solo maintainer)
|
|
42
42
|
|
|
43
43
|
The remote keeps only `main`. Do development on local non-`main` branches; do not push those branches.
|
|
44
|
-
|
|
45
|
-
|
|
44
|
+
|
|
45
|
+
Fixed path for every change:
|
|
46
|
+
|
|
47
|
+
1. Create a local non-`main` branch from local `main`.
|
|
48
|
+
2. Implement and run the local gates there.
|
|
49
|
+
3. Build an acceptance tarball/profile and perform **local human acceptance** against the exact build.
|
|
50
|
+
4. Only after acceptance: merge the branch into local `main` linearly.
|
|
51
|
+
5. Push `main` only. Protected actions on `main` are force-pushes, deletion, and non-linear merges, not a
|
|
52
|
+
PR review requirement.
|
|
53
|
+
|
|
54
|
+
No release, tag, or remote branch is created before local acceptance. Record the acceptance result in the
|
|
55
|
+
release verification notes.
|
|
46
56
|
|
|
47
57
|
External contributors may still open PRs from forks. The maintainer reviews and merges them locally under
|
|
48
58
|
the same main-only policy.
|
package/CONTRIBUTING.zh.md
CHANGED
|
@@ -42,8 +42,15 @@ npm run check
|
|
|
42
42
|
|
|
43
43
|
## 分支流程(单维护者)
|
|
44
44
|
|
|
45
|
-
远程仓库只保留 `main
|
|
46
|
-
|
|
45
|
+
远程仓库只保留 `main`。每个改动的固定路径:
|
|
46
|
+
|
|
47
|
+
1. 从本地 `main` 创建本地非 `main` 分支;
|
|
48
|
+
2. 在分支上实现并跑完本地门禁;
|
|
49
|
+
3. 构建验收 tarball/profile,对精确构建做**本地人工验收**;
|
|
50
|
+
4. 只有验收确认后,才线性合入本地 `main`;
|
|
51
|
+
5. 只推送 `main`。`main` 的保护是不允许 force-push、删除和非线性合并,而不是 PR review 要求。
|
|
52
|
+
|
|
53
|
+
本地验收前不创建 release/tag,也不推送远端分支;验收结果写入发布验证记录。
|
|
47
54
|
|
|
48
55
|
外部贡献者仍可从 fork 提交 PR;维护者按同样的 main-only 策略在本地审查和合并。
|
|
49
56
|
|
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
[](https://github.com/centella-cream/dsh-charter)
|
|
5
5
|
[](docs/design/compatibility.md)
|
|
6
6
|
[](package.json)
|
|
7
|
-
[](#status)
|
|
8
8
|
|
|
9
9
|
English | [中文](README.zh.md)
|
|
10
10
|
|
|
@@ -14,9 +14,9 @@ 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
|
-

|
|
17
|
+

|
|
18
18
|
|
|
19
|
-
> The current **0.2** Pane in a local Web profile. UI strings follow the active DSH language; this image uses
|
|
19
|
+
> The current **0.2.1** Pane in a local Web profile. UI strings follow the active DSH language; this image uses
|
|
20
20
|
> demo values so no private Session content is published.
|
|
21
21
|
|
|
22
22
|
## Contents
|
|
@@ -39,12 +39,23 @@ deliverables, evidence, and dependency relationships survive compaction and rema
|
|
|
39
39
|
|
|
40
40
|
## Status
|
|
41
41
|
|
|
42
|
-
- **Published release:** `0.
|
|
43
|
-
- **Release candidate:** `0.2.
|
|
44
|
-
not
|
|
42
|
+
- **Published release:** `0.2.0` — npm `latest` and `next`, GitHub Release `v0.2.0`.
|
|
43
|
+
- **Release candidate:** `0.2.1` — post-`0.2.0` UI, diagnostics, and recovery-cache patch; local acceptance and
|
|
44
|
+
promotion are still pending, so do not install it from npm yet.
|
|
45
|
+
- **Previous release:** `0.1.0-rc.6`.
|
|
45
46
|
- **Primary DSH baseline:** `0.2.2-rc.1`; nine declared DSH versions are source-matrix verified.
|
|
46
47
|
- Versioning from `0.2.0` onward uses plain increments (`0.2.0`, `0.2.1`, …), never an `rc` suffix.
|
|
47
48
|
|
|
49
|
+
### 0.2.1 highlights
|
|
50
|
+
|
|
51
|
+
- Message proposals now prefill an **editable body** from the selected user message; the old character-range
|
|
52
|
+
inputs are gone.
|
|
53
|
+
- Diagnostics separates fact validation from evidence integrity, and both forms explain the target and check
|
|
54
|
+
being run.
|
|
55
|
+
- Recovery restores from a Host-maintained cache (five per Session, 25 per profile) without requiring a
|
|
56
|
+
downloaded file; export stays a separate operation for analysis and backup.
|
|
57
|
+
- The Pane header and form typography follow the lighter `dsh-context` hierarchy.
|
|
58
|
+
|
|
48
59
|
## Why
|
|
49
60
|
|
|
50
61
|
Compaction replaces older history with a summary. A summary can keep the general task while quietly dropping
|
|
@@ -66,8 +77,8 @@ permission boundary.
|
|
|
66
77
|
and a Host-canonical preview digest.
|
|
67
78
|
- **Safe onboarding.** An existing compacted Session gets a review-only draft from its latest usable compaction
|
|
68
79
|
summary; nothing becomes effective until you review and apply it.
|
|
69
|
-
- **Recoverable records.** Export/restore is owner-only,
|
|
70
|
-
fences only that Session until a Host restart.
|
|
80
|
+
- **Recoverable records.** Export/restore is owner-only, the Host keeps at most five recent recovery snapshots per
|
|
81
|
+
Session (25 across the profile), healthy records refuse overwrite, and an uncertain write fences only that Session until a Host restart.
|
|
71
82
|
- **Fail closed per Session.** A structurally invalid record is preserved for diagnosis and never overwritten.
|
|
72
83
|
|
|
73
84
|
A charter is a declaration, not an enforcement policy. Use Host permissions, sandbox policy, hooks, or
|
|
@@ -109,12 +120,13 @@ Dependencies are a user-authored **execution constraint**, not an enforced sandb
|
|
|
109
120
|
- Record schema v2 with in-memory v1 migration, proposal batches, typed provenance, and objective proposals.
|
|
110
121
|
- `summary`/`watchSummary` plus paged item/proposal/change queries. The Pane uses summary + queries and keeps
|
|
111
122
|
the full-watch stream only as a compatibility fallback.
|
|
112
|
-
- Pending-only `charter_propose` tool and user-triggered message proposals with
|
|
123
|
+
- Pending-only `charter_propose` tool and user-triggered message proposals with an editable body and kind.
|
|
113
124
|
- Evidence Integrity and Fact Validity, including owner-only registered validators:
|
|
114
125
|
`workspace.path-exists`, `workspace.file-digest`, and `workspace.file-contains`.
|
|
115
126
|
- Source-integrity projection checks for message, compaction-summary, and agent-tool batches; fork projections
|
|
116
127
|
are explicitly reported as `unsupported`.
|
|
117
|
-
- Fork with item/validity/evidence/dependency remapping; Recovery Center export/initialize
|
|
128
|
+
- Fork with item/validity/evidence/dependency remapping; Recovery Center export/initialize and owner-only restore
|
|
129
|
+
from a bounded five-snapshot cache.
|
|
118
130
|
- English/Chinese UI, light/dark themes, keyboard focus states, and container-query responsiveness.
|
|
119
131
|
|
|
120
132
|
## How it works
|
|
@@ -124,6 +136,8 @@ flowchart LR
|
|
|
124
136
|
U[User edits the Charter tab] --> A[charter.edit]
|
|
125
137
|
A --> B[Atomic single-record update]
|
|
126
138
|
B --> D[(dsh_charter_v1 storage domain)]
|
|
139
|
+
D -. bounded snapshots .-> Q[(dsh_charter_archives_v1 / max 5)]
|
|
140
|
+
Q --> X[Owner-only restore cache]
|
|
127
141
|
D --> R[Deterministic renderer]
|
|
128
142
|
R --> C[user-role runtime context]
|
|
129
143
|
D --> T[charter_read]
|
|
@@ -141,18 +155,18 @@ storage.
|
|
|
141
155
|
|
|
142
156
|
## Install
|
|
143
157
|
|
|
144
|
-
The latest public release is `0.
|
|
145
|
-
|
|
158
|
+
The latest public release is `0.2.0`. The `0.2.1` candidate is not on npm yet. Install the published exact
|
|
159
|
+
version for a reproducible profile:
|
|
146
160
|
|
|
147
161
|
```bash
|
|
148
|
-
|
|
149
|
-
dsh plugin --profile web add ./dsh-charter-0.2.0.tgz
|
|
162
|
+
dsh plugin --profile web add dsh-charter@0.2.0
|
|
150
163
|
```
|
|
151
164
|
|
|
152
|
-
|
|
165
|
+
For air-gapped machines or exact-artifact verification, install the published tarball:
|
|
153
166
|
|
|
154
167
|
```bash
|
|
155
|
-
|
|
168
|
+
npm pack dsh-charter@0.2.0
|
|
169
|
+
dsh plugin --profile web add ./dsh-charter-0.2.0.tgz
|
|
156
170
|
```
|
|
157
171
|
|
|
158
172
|
For Desktop, use **Desktop → Plugins → Install/Update**, or import the same local tarball if your Desktop build
|
|
@@ -268,8 +282,8 @@ npm run verify:compaction # manual real-model compaction check
|
|
|
268
282
|
node scripts/verify/compat-matrix.mjs --versions all --allow-new-release
|
|
269
283
|
```
|
|
270
284
|
|
|
271
|
-
Current source evidence: **36 files /
|
|
272
|
-
**
|
|
285
|
+
Current source evidence: **36 files / 441 tests**, and the nine-version DSH matrix passes **9/9** at
|
|
286
|
+
**441/441**. See the [verification record](docs/verification.md) for exact commands and the distinction between
|
|
273
287
|
source, local-matrix, exact-artifact, and manual evidence.
|
|
274
288
|
|
|
275
289
|
CI runs `npm run check` and `npm run smoke:package` on Node `22.19.0` and `24`; the release candidate and promotion workflows are separate gates. A green candidate is not a publication.
|
package/README.zh.md
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
[](https://github.com/centella-cream/dsh-charter)
|
|
5
5
|
[](docs/design/compatibility.zh.md)
|
|
6
6
|
[](package.json)
|
|
7
|
-
[](#状态)
|
|
8
8
|
|
|
9
9
|
[English](README.md) | 中文
|
|
10
10
|
|
|
@@ -13,9 +13,9 @@
|
|
|
13
13
|
`dsh-charter` 是 [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness) 的持久化、用户所有的
|
|
14
14
|
会话契约插件。目标、硬约束、交付物、证据和依赖关系在上下文压缩后仍然保留,并且始终可查看、可编辑。
|
|
15
15
|
|
|
16
|
-

|
|
16
|
+

|
|
17
17
|
|
|
18
|
-
> 这是本地 Web profile 中当前 **0.2** Pane 的界面。UI 文案跟随 DSH 当前语言;截图使用演示数据,不发布
|
|
18
|
+
> 这是本地 Web profile 中当前 **0.2.1** Pane 的界面。UI 文案跟随 DSH 当前语言;截图使用演示数据,不发布
|
|
19
19
|
> 任何私人 Session 内容。
|
|
20
20
|
|
|
21
21
|
## 目录
|
|
@@ -38,12 +38,21 @@
|
|
|
38
38
|
|
|
39
39
|
## 状态
|
|
40
40
|
|
|
41
|
-
- **已发布版本:**`0.
|
|
42
|
-
- **发布候选:**`0.2.
|
|
43
|
-
|
|
41
|
+
- **已发布版本:**`0.2.0` — npm `latest` 和 `next`,GitHub Release `v0.2.0`。
|
|
42
|
+
- **发布候选:**`0.2.1` — `0.2.0` 之后的 UI、诊断和恢复缓存补丁;本地验收与 promotion 尚未完成,暂不要从
|
|
43
|
+
npm 安装。
|
|
44
|
+
- **上一版本:**`0.1.0-rc.6`。
|
|
44
45
|
- **主要 DSH 基线:**`0.2.2-rc.1`;九个声明版本通过源码矩阵验证。
|
|
45
46
|
- 从 `0.2.0` 起版本号使用普通递增(`0.2.0`、`0.2.1`…),不再使用 `rc` 后缀。
|
|
46
47
|
|
|
48
|
+
### 0.2.1 重点变化
|
|
49
|
+
|
|
50
|
+
- 消息提案会从所选用户消息预填**可编辑正文**;原来的字符范围输入已移除。
|
|
51
|
+
- 诊断区把事实有效性验证和证据完整性拆开,两处都说明验证对象和检查内容。
|
|
52
|
+
- 恢复改为从 Host 维护的缓存选择快照(每 Session 5 份、整个 profile 25 份),不再要求先下载文件;
|
|
53
|
+
导出仍是独立的分析与备份操作。
|
|
54
|
+
- Pane 页头和表单排版对齐更轻量的 `dsh-context` 层级。
|
|
55
|
+
|
|
47
56
|
## 为什么需要
|
|
48
57
|
|
|
49
58
|
压缩会把较早的上下文替换成摘要。摘要可能保留总体任务,却丢掉长期约束,比如“不要改 migrations/”、
|
|
@@ -60,8 +69,8 @@
|
|
|
60
69
|
- **原子 Apply。**一个 Change Set 要么完整提交,要么不提交;带 revision 冲突、幂等重试和 Host canonical
|
|
61
70
|
preview digest。
|
|
62
71
|
- **安全接入。**已有压缩历史的 Session 可以生成只读草案;用户确认前不会生效。
|
|
63
|
-
- **可恢复。**export/restore 仅 owner
|
|
64
|
-
Host 重启恢复。
|
|
72
|
+
- **可恢复。**export/restore 仅 owner 可用;Host 每个 Session 最多保留 5 份恢复快照(整个 profile 最多 25 份);健康记录拒绝覆盖;
|
|
73
|
+
写入结果不确定时只隔离该 Session,等待 Host 重启恢复。
|
|
65
74
|
- **逐 Session fail closed。**结构损坏的记录会保留用于诊断,不会被覆盖。
|
|
66
75
|
|
|
67
76
|
契约是声明,不是强制执行策略。需要机器强制的限制请使用 Host permissions、sandbox policy、hooks 或
|
|
@@ -97,12 +106,13 @@ deliverable 的**前置约束**,而这些关系会进入存储契约、校验
|
|
|
97
106
|
- record schema v2、内存 v1 迁移、proposal batch、类型化 provenance 和 objective proposal。
|
|
98
107
|
- `summary`/`watchSummary` 及分页 item/proposal/change query;Pane 使用 summary + query,完整 watch 仅作为
|
|
99
108
|
兼容回退。
|
|
100
|
-
- pending-only `charter_propose`;用户触发的 message proposal
|
|
109
|
+
- pending-only `charter_propose`;用户触发的 message proposal(选择器、可编辑正文、kind)。
|
|
101
110
|
- Evidence Integrity 与 Fact Validity,以及 owner-only 注册式验证器:
|
|
102
111
|
`workspace.path-exists`、`workspace.file-digest`、`workspace.file-contains`。
|
|
103
112
|
- message/compaction-summary/agent-tool batch 的 source integrity 投影复算;fork source integrity 明确返回
|
|
104
113
|
`unsupported`。
|
|
105
|
-
- fork 的 item/validity/evidence/依赖重映射;Recovery Center 支持 export/initialize
|
|
114
|
+
- fork 的 item/validity/evidence/依赖重映射;Recovery Center 支持 export/initialize,以及从最多 5 份的
|
|
115
|
+
owner-only 快照缓存恢复。
|
|
106
116
|
- 中英文 UI、明暗主题、键盘 focus 状态和容器查询响应式布局。
|
|
107
117
|
|
|
108
118
|
## 工作原理
|
|
@@ -112,6 +122,8 @@ flowchart LR
|
|
|
112
122
|
U[用户在 Charter 页编辑] --> A[charter.edit]
|
|
113
123
|
A --> B[原子单记录更新]
|
|
114
124
|
B --> D[(dsh_charter_v1 storage domain)]
|
|
125
|
+
D -. 有界快照 .-> Q[(dsh_charter_archives_v1 / 最多 5 份)]
|
|
126
|
+
Q --> X[owner-only 恢复缓存]
|
|
115
127
|
D --> R[确定性 renderer]
|
|
116
128
|
R --> C[user-role runtime context]
|
|
117
129
|
D --> T[charter_read]
|
|
@@ -128,17 +140,17 @@ compaction summary 返回只读草案,不写 storage。
|
|
|
128
140
|
|
|
129
141
|
## 安装
|
|
130
142
|
|
|
131
|
-
当前公开版本是 `0.
|
|
143
|
+
当前公开版本是 `0.2.0`;`0.2.1` 候选尚未发布到 npm。可复现 profile 请先安装已发布的精确版本:
|
|
132
144
|
|
|
133
145
|
```bash
|
|
134
|
-
|
|
135
|
-
dsh plugin --profile web add ./dsh-charter-0.2.0.tgz
|
|
146
|
+
dsh plugin --profile web add dsh-charter@0.2.0
|
|
136
147
|
```
|
|
137
148
|
|
|
138
|
-
|
|
149
|
+
离线机器或需要精确验证 artifact 时,安装已发布 tarball:
|
|
139
150
|
|
|
140
151
|
```bash
|
|
141
|
-
|
|
152
|
+
npm pack dsh-charter@0.2.0
|
|
153
|
+
dsh plugin --profile web add ./dsh-charter-0.2.0.tgz
|
|
142
154
|
```
|
|
143
155
|
|
|
144
156
|
Desktop 请使用 **Desktop → Plugins → Install/Update**;若 Desktop 构建支持本地插件导入,也可导入同一
|
|
@@ -251,7 +263,7 @@ npm run verify:compaction # 手动真实模型 compaction 检查
|
|
|
251
263
|
node scripts/verify/compat-matrix.mjs --versions all --allow-new-release
|
|
252
264
|
```
|
|
253
265
|
|
|
254
|
-
当前源码证据:**36 个测试文件 /
|
|
266
|
+
当前源码证据:**36 个测试文件 / 441 个测试**,九版本 DSH 矩阵 **9/9**、每版 **441/441** 通过。精确命令
|
|
255
267
|
和 source/local-matrix/exact-artifact/manual 证据的区别见[验证记录](docs/verification.zh.md)。
|
|
256
268
|
|
|
257
269
|
CI 在 Node `22.19.0` 和 `24` 上运行 `npm run check` 与 `npm run smoke:package`;release candidate 和 promotion 是独立门禁。green candidate 不等于已发布。
|
package/docs/README.md
CHANGED
|
@@ -20,8 +20,8 @@ A status block has this shape:
|
|
|
20
20
|
|
|
21
21
|
```text
|
|
22
22
|
> **Status:** Active
|
|
23
|
-
> **Version scope:** 0.2.
|
|
24
|
-
> **Baseline:** 2026-11-
|
|
23
|
+
> **Version scope:** 0.2.1
|
|
24
|
+
> **Baseline:** 2026-11-06
|
|
25
25
|
> **Authority:** docs/design/version-roadmap.zh.md
|
|
26
26
|
> **Supersedes / Superseded by:** none / <path or none>
|
|
27
27
|
```
|
|
@@ -60,7 +60,8 @@ same commit. Do not delete a historical decision just because it is inactive; mo
|
|
|
60
60
|
| [user-guide.md](user-guide.md) | Active | current line | Installation and usage guide. |
|
|
61
61
|
| [release-notes/0.1.0-rc.5.md](release-notes/0.1.0-rc.5.md) | Historical | 0.1.0-rc.5 | Published npm release note. |
|
|
62
62
|
| [release-notes/0.1.0-rc.6.md](release-notes/0.1.0-rc.6.md) | Historical | 0.1.0-rc.6 | Published/accepted release note. |
|
|
63
|
-
| [release-notes/0.2.0.md](release-notes/0.2.0.md) |
|
|
63
|
+
| [release-notes/0.2.0.md](release-notes/0.2.0.md) | Historical | 0.2.0 | Published npm release and GitHub Release. |
|
|
64
|
+
| [release-notes/0.2.1.md](release-notes/0.2.1.md) | Release candidate | 0.2.1 | Local acceptance and promotion pending. |
|
|
64
65
|
|
|
65
66
|
## Maintenance rules
|
|
66
67
|
|
package/docs/README.zh.md
CHANGED
|
@@ -19,8 +19,8 @@
|
|
|
19
19
|
|
|
20
20
|
```text
|
|
21
21
|
> **Status:** Active
|
|
22
|
-
> **Version scope:** 0.2.
|
|
23
|
-
> **Baseline:** 2026-11-
|
|
22
|
+
> **Version scope:** 0.2.1
|
|
23
|
+
> **Baseline:** 2026-11-06
|
|
24
24
|
> **Authority:** docs/design/version-roadmap.zh.md
|
|
25
25
|
> **Supersedes / Superseded by:** none / <路径或 none>
|
|
26
26
|
```
|
|
@@ -58,7 +58,8 @@
|
|
|
58
58
|
| [user-guide.md](user-guide.md) | Active | 当前版本线 | 安装与使用指南。 |
|
|
59
59
|
| [release-notes/0.1.0-rc.5.md](release-notes/0.1.0-rc.5.md) | Historical | 0.1.0-rc.5 | 已发布 npm 版本的发布说明。 |
|
|
60
60
|
| [release-notes/0.1.0-rc.6.md](release-notes/0.1.0-rc.6.md) | Historical | 0.1.0-rc.6 | 已发布并验收的发布说明。 |
|
|
61
|
-
| [release-notes/0.2.0.md](release-notes/0.2.0.md) |
|
|
61
|
+
| [release-notes/0.2.0.md](release-notes/0.2.0.md) | Historical | 0.2.0 | 已发布 npm 版本和 GitHub Release。 |
|
|
62
|
+
| [release-notes/0.2.1.md](release-notes/0.2.1.md) | Release candidate | 0.2.1 | 本地验收与 promotion 待完成。 |
|
|
62
63
|
|
|
63
64
|
## 维护规则
|
|
64
65
|
|
|
Binary file
|
|
@@ -232,7 +232,10 @@ automatically verify; a failed verification does not automatically archive.
|
|
|
232
232
|
|
|
233
233
|
1. `CharterService.init()` registers Session and Agent lifecycle listeners before opening the domain.
|
|
234
234
|
2. `openDomain()` opens `dsh_charter_v1` with a `sessions` table (`layout: per-record`), validates all records,
|
|
235
|
-
and marks semantically inconsistent records unavailable.
|
|
235
|
+
and marks semantically inconsistent records unavailable. It also opens the optional
|
|
236
|
+
`dsh_charter_archives_v1` domain with an `archives` table for the latest five owner-only recovery snapshots
|
|
237
|
+
per Session and at most 25 across the profile (oldest evicted first);
|
|
238
|
+
failure to open the cache degrades export/restore without bricking the primary record.
|
|
236
239
|
3. On `session/created`, the service initializes the Session in the background.
|
|
237
240
|
4. On `agent/created` (serial and awaitable), the listener awaits initialization before the first prompt can be
|
|
238
241
|
assembled.
|
|
@@ -240,8 +243,9 @@ automatically verify; a failed verification does not automatically archive.
|
|
|
240
243
|
it never leaves two initialization promises waiting on each other.
|
|
241
244
|
6. If a child Session appears before its parent record is durable, the child waits for `domain/changed` and
|
|
242
245
|
retries.
|
|
243
|
-
7. `session/disposed` aborts in-flight initialization and removes UI listeners.
|
|
244
|
-
|
|
246
|
+
7. `session/disposed` aborts in-flight initialization and removes UI listeners. It does not delete the record
|
|
247
|
+
or its recovery cache; the durable record is the authority, and the cache is a bounded derivative with
|
|
248
|
+
profile-wide eviction (never a second authority).
|
|
245
249
|
8. On plugin unload, new edits are blocked, in-flight writes are awaited, listeners and domain are released.
|
|
246
250
|
|
|
247
251
|
Session disposal closes every open watch subscription (listeners receive `null` and the stream generator exits),
|
|
@@ -287,6 +287,19 @@ table: sessions
|
|
|
287
287
|
key: SessionId
|
|
288
288
|
```
|
|
289
289
|
|
|
290
|
+
恢复缓存使用独立 domain:
|
|
291
|
+
|
|
292
|
+
```text
|
|
293
|
+
name: dsh_charter_archives_v1
|
|
294
|
+
version: 1
|
|
295
|
+
layout: per-record
|
|
296
|
+
table: archives
|
|
297
|
+
key: sessionId--revision
|
|
298
|
+
policy: 每 Session 最多 5 份;整个 profile 最多 25 份,最旧优先淘汰
|
|
299
|
+
```
|
|
300
|
+
|
|
301
|
+
缓存是 owner-only 的派生物,不是第二正本;host 打开失败时降级为无缓存,不影响主 record。
|
|
302
|
+
|
|
290
303
|
记录形状:
|
|
291
304
|
|
|
292
305
|
```ts
|
|
@@ -752,7 +765,7 @@ Session dispose:
|
|
|
752
765
|
|
|
753
766
|
- 停止该 Session 的初始化任务和流;
|
|
754
767
|
- 清除 runtime 引用;
|
|
755
|
-
-
|
|
768
|
+
- 不删除持久记录,也不按 dispose 清空恢复缓存;缓存统一受 profile 级 LRU 上限约束。
|
|
756
769
|
|
|
757
770
|
插件卸载:
|
|
758
771
|
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
- Pane active/history/pending/inactive/batch 列表窗口化;store 走 summary + 分页 query,旧 Host 保留 full-watch fallback。
|
|
21
21
|
- queryItems/queryProposals/queryChanges 的 facets、validity filter、filter digest、revision-bound cursor 和响应
|
|
22
22
|
字节上限;`objectiveProposals` 独立 cursor 和字节上限。
|
|
23
|
-
- message proposal
|
|
23
|
+
- message proposal 的选择器、可编辑正文、kind 和 projection digest;编辑后的正文使用 manual provenance;Change Set canonical preview digest/
|
|
24
24
|
`PREVIEW_MISMATCH`;proposedRequires 支持 batch-candidate 和同 Change Set 接受顺序;fork 重置 validity 并重映射
|
|
25
25
|
proposedRequires/evidence;bootstrap active item dedupe;来源派生的 origin。
|
|
26
26
|
- Evidence Integrity/Fact Validity:registered validator、owner-only、文件大小/总字节/总时长/并发边界、
|
|
@@ -35,7 +35,7 @@
|
|
|
35
35
|
- fork source integrity 为 `unsupported`:child record 不保存父来源投影;fork typed refs 已保留但完整复算需要父记录。
|
|
36
36
|
fork 将 validity 结论重置为 `unassessed`,保留 evidence/source 引用;不会把父 Session 的有效性结论带入 child。
|
|
37
37
|
- `charter_propose` 的 requires 仍只解析当前 active deliverable IDs;agent batch-candidate 引用暂不支持。
|
|
38
|
-
- message proposal
|
|
38
|
+
- message proposal 只接受真实 user message;选中正文会预填到可编辑框,保存前可自由修改。
|
|
39
39
|
- Pane 仍一次取回全部分页(渲染已窗口化),网络层分页/窗口化仍是优化项。
|
|
40
40
|
- queryProposals 的 review 过滤是 batch 级命中,响应保留该 batch 的全部 candidate;这是当前契约,不是 candidate 级过滤。
|
|
41
41
|
- 真实 Gateway 授权/配额、Desktop ABI/Plugins UI、可访问性/触屏/200% 文本、真实模型 compaction、512 条性能人工
|
|
@@ -59,6 +59,7 @@
|
|
|
59
59
|
4. 关系采用少量明确类型,不建设任意节点都能连线的通用图。
|
|
60
60
|
5. 历史、时间、来源和诊断元数据不进入常驻 prompt。
|
|
61
61
|
6. 模型只能读取当前契约和提出 proposal,不能接受提案、改变依赖、归档条目或切换当前重点。
|
|
62
|
+
7. 恢复使用 Host 维护的归档快照:每 Session 最近 5 份、profile 全局最多 25 份,最旧优先清理;下载导出只用于外部校验、分析或备份,恢复不依赖下载。
|
|
62
63
|
|
|
63
64
|
本文建议首个依赖模型只覆盖 deliverable 的 `requires`。该新增范围需要先修订版本路线,再形成实现承诺。
|
|
64
65
|
约束适用范围 `appliesTo` 和用户控制的 Focus 作为后续实验项,只有受控 A/B 显示收益后才进入稳定契约。
|
|
@@ -1082,7 +1083,7 @@ predicate-based 批量写入。Host 计算的 canonical summary digest 与客户
|
|
|
1082
1083
|
| `applyChangeSet` | owner / user | 复用 op 级授权;purge 和等价不可逆清除仍为 owner-only |
|
|
1083
1084
|
| `runValidators` | owner-only | 先检查 principal、Session resource、validator capability 和 workspace 权限,再读取文件或 storage |
|
|
1084
1085
|
| `charter_propose` | 当前 live Session 的 agent tool call | 使用 pending-only 专用 handler,不复用 owner/user edit 权限 |
|
|
1085
|
-
| export / initialize / restore | owner-only | 保持现有维护授权和 healthy-target
|
|
1086
|
+
| export / initialize / restore / listArchives / readArchive | owner-only | 保持现有维护授权和 healthy-target 拒绝规则;归档缓存读取与导出同级 |
|
|
1086
1087
|
|
|
1087
1088
|
`runValidators` 是一个 RPC 内的两阶段协议:先在已授权 workspace 上 evaluation,生成 validator version、input digest 和
|
|
1088
1089
|
结构化结果;再在 mutation queue 内重读 base revision 和 input binding,以一个 durable Change Set 提交整批结果。Evaluation
|
|
@@ -6,7 +6,7 @@ English | [中文](version-roadmap.zh.md)
|
|
|
6
6
|
>
|
|
7
7
|
> **Status:** Active — version and scope authority.
|
|
8
8
|
> **Version scope:** 0.1 history and current 0.2 development line.
|
|
9
|
-
> **Baseline:** 2026-
|
|
9
|
+
> **Baseline:** 2026-11-06; current line `0.2.1` is a post-`0.2.0` release candidate (plain increments, no `rc`).
|
|
10
10
|
> **Authority:** Chinese [version-roadmap.zh.md](version-roadmap.zh.md) is normative for scope.
|
|
11
11
|
> **Supersedes / Superseded by:** none / none
|
|
12
12
|
|
|
@@ -23,6 +23,7 @@ The release path is:
|
|
|
23
23
|
→ 0.1.0 stable
|
|
24
24
|
→ 0.1.1 only if stable needs a compatible patch
|
|
25
25
|
→ 0.2.0 development → 0.2.0
|
|
26
|
+
→ 0.2.1 post-0.2.0 UI/diagnostics/recovery-cache patch
|
|
26
27
|
```
|
|
27
28
|
|
|
28
29
|
**`0.1.0-rc.6`** is published and formally accepted; its GitHub Release uses recovery tag `v0.1.0-rc.6-republished`. **`0.1.0-rc.5`** is the previous accepted release and its canonical GitHub tag/release is pending restoration. `0.1.1-rc.1` remains a post-stable patch spelling, not another rc.6.
|
|
@@ -35,14 +36,14 @@ rc.5 fixed the correctness defect inside the promised 0.1 workflow: previously e
|
|
|
35
36
|
|
|
36
37
|
## 2. Current Release State
|
|
37
38
|
|
|
38
|
-
-
|
|
39
|
-
|
|
40
|
-
-
|
|
41
|
-
|
|
42
|
-
- `
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
39
|
+
- `0.2.0` is published on npm (`latest`/`next`) and as GitHub Release `v0.2.0`; its tag, assets, and npm bytes
|
|
40
|
+
are immutable.
|
|
41
|
+
- `0.2.1` is the current release candidate on the local development line. It is not tagged, released, or
|
|
42
|
+
published; local acceptance and promotion remain pending.
|
|
43
|
+
- `0.2.1` is a compatible post-`0.2.0` patch: editable message proposals, clearer diagnostics/typography, and an
|
|
44
|
+
owner-only bounded recovery cache. It does not change `recordSchemaVersion` 2 or the model tool surface; the
|
|
45
|
+
`dsh_charter_archives_v1` domain is a bounded derivative cache, not a second authority.
|
|
46
|
+
- `0.1.0-rc.6` remains the previous public release. Historical rc tags and releases are immutable.
|
|
46
47
|
|
|
47
48
|
## 3. Why rc.5
|
|
48
49
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
> **状态:** Active — 版本与范围权威。
|
|
6
6
|
> **版本范围:** 0.1 历史与当前 0.2 开发线。
|
|
7
|
-
> **基准:** 2026-
|
|
7
|
+
> **基准:** 2026-11-06;当前线 `0.2.1` 是 `0.2.0` 之后的发布候选(普通递增,不使用 `rc` 后缀)。
|
|
8
8
|
> **权威:** 中文版本为 scope 的 normative。
|
|
9
9
|
> **替代/被替代:** 无 / 无
|
|
10
10
|
|
|
@@ -21,6 +21,7 @@
|
|
|
21
21
|
→ 0.1.0 stable
|
|
22
22
|
→ 0.1.1(仅在 stable 后确有兼容补丁时)
|
|
23
23
|
→ 0.2.0 开发线 → 0.2.0
|
|
24
|
+
→ 0.2.1:0.2.0 之后的 UI、诊断与恢复缓存补丁
|
|
24
25
|
```
|
|
25
26
|
|
|
26
27
|
**`0.1.0-rc.5`** 已发布到 npm,是最新发布版本;其规范 GitHub tag/release 待恢复。**`0.1.0-rc.6`** 在验收前
|
|
@@ -34,19 +35,12 @@ rc.5 修复了与产品承诺冲突的审阅正确性问题:此前历史草案
|
|
|
34
35
|
|
|
35
36
|
## 2. 当前发布状态
|
|
36
37
|
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
- rc.
|
|
43
|
-
|
|
44
|
-
### 2.2 rc.5 候选
|
|
45
|
-
|
|
46
|
-
- rc.5 已实现、candidate 全绿并发布到 npm;规范 GitHub tag/release 待恢复,发布后检查仍需完成。
|
|
47
|
-
发布后检查仍待完成。
|
|
48
|
-
- rc.6 已通过验收并发布;GitHub Release 使用 recovery tag `v0.1.0-rc.6-republished`。
|
|
49
|
-
- `main` 已包含剩余 promotion 路径使用的 token 发布 workflow。已发布的 rc.4 历史永不改写。
|
|
38
|
+
- `0.2.0` 已发布到 npm(`latest`/`next`)和 GitHub Release `v0.2.0`;tag、资产和 npm 字节不可变。
|
|
39
|
+
- `0.2.1` 是当前本地开发线上的发布候选;尚未打 tag、发布 GitHub Release 或发布 npm,本地验收与 promotion
|
|
40
|
+
仍待完成。
|
|
41
|
+
- `0.2.1` 是 `0.2.0` 之后的兼容补丁:可编辑消息提案、更清晰的诊断/排版、owner-only 有界恢复缓存。不改变
|
|
42
|
+
`recordSchemaVersion` 2 或模型工具面;`dsh_charter_archives_v1` 是有界派生物缓存,不是第二正本。
|
|
43
|
+
- `0.1.0-rc.6` 仍是上一个公开版本。历史 rc tag/release 不可变。
|
|
50
44
|
|
|
51
45
|
## 3. 为什么是 rc.5
|
|
52
46
|
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
# dsh-charter 0.2.0
|
|
2
2
|
|
|
3
|
-
> **Status:**
|
|
3
|
+
> **Status:** Released 2026-11-05 — npm and GitHub Release published.
|
|
4
4
|
> **Version scope:** `0.2.0`
|
|
5
5
|
> **Baseline:** 2026-11-05
|
|
6
6
|
> **Authority:** [version roadmap](../design/version-roadmap.md); [verification](../verification.md) for evidence.
|
|
7
|
-
> **Supersedes / Superseded by:** none /
|
|
7
|
+
> **Supersedes / Superseded by:** none / none.
|
|
8
8
|
|
|
9
|
-
`0.2.0` is the workspace, constraint-relationship, evidence, and release-process upgrade. It is
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
`0.2.0` is the workspace, constraint-relationship, evidence, and release-process upgrade. It is published as
|
|
10
|
+
npm `dsh-charter@0.2.0` (`latest` and `next`) and GitHub Release `v0.2.0`. Functional boundaries are listed in
|
|
11
|
+
the workspace design.
|
|
12
12
|
|
|
13
13
|
## Status
|
|
14
14
|
|
|
@@ -18,8 +18,8 @@ protected candidate/promotion workflow. Functional boundaries are listed in the
|
|
|
18
18
|
`rc` suffix.
|
|
19
19
|
- Source acceptance: strict TypeScript, build/smoke, 36 files / 434 tests, and the nine-version DSH
|
|
20
20
|
compatibility matrix pass on the current tree.
|
|
21
|
-
-
|
|
22
|
-
|
|
21
|
+
- Post-release diagnostics (real Desktop/browser checks, real-model compaction, performance) remain recorded in
|
|
22
|
+
[verification](../verification.md); they do not change the immutable published bytes.
|
|
23
23
|
|
|
24
24
|
## Added
|
|
25
25
|
|