@shgroup/dsh-serenity-hooks 1.31.9 → 1.31.12
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/README.md +10 -6
- package/dsh.plugin.json +3 -3
- package/lib/host/contract.d.ts +1 -1
- package/lib/index.js +2 -2
- package/package.json +51 -19
package/README.md
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
> **一句话**:装上这个插件,你在电脑上给 AI 划一块自己的工作区(就是一个普通目录),
|
|
4
4
|
> AI 在里面干活时就有了**记忆、纪律、工具和边界**——中途换模型、重启电脑、第二天再来,都能接着干。
|
|
5
5
|
>
|
|
6
|
-
> 适用 [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness)(下称 DSH)0.1.5-rc.
|
|
6
|
+
> 适用 [DeepSeek Harness](https://github.com/deepseek-ai/deepseek-harness)(下称 DSH)0.1.5-rc.2 及以上。
|
|
7
7
|
> 想了解背后的想法(为什么叫"认知容器"),看 [docs/cognitive-container-theory.md](https://github.com/tellmewhattodo/dsh-serenity-plugin/blob/master/docs/cognitive-container-theory.md);本文只讲**能干什么、怎么用**。
|
|
8
8
|
|
|
9
9
|
**几个词先说明白**(后面都用这几个词,不再解释):
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
|
|
33
33
|
## 2. 快速开始(2 分钟)
|
|
34
34
|
|
|
35
|
-
前置:Node ≥ 20(或 bun)、DSH 0.1.5-rc.
|
|
35
|
+
前置:Node ≥ 20(或 bun)、DSH 0.1.5-rc.2 及以上。
|
|
36
36
|
|
|
37
37
|
```bash
|
|
38
38
|
# 1. 装插件(自动加入 DSH 的 web profile)
|
|
@@ -317,12 +317,16 @@ AI 一次能"记住"的内容有上限。满了不用你手动开新会话:
|
|
|
317
317
|
|
|
318
318
|
```bash
|
|
319
319
|
pnpm typecheck # 类型检查(node + 浏览器端两套)
|
|
320
|
-
pnpm test # 全量测试(当前 80 个文件 /
|
|
320
|
+
pnpm test # 全量测试(当前 80 个文件 / 1180 个用例)
|
|
321
321
|
pnpm build # 打包(lib/index.js + client.js)
|
|
322
322
|
```
|
|
323
323
|
|
|
324
|
-
- **开发用小工具**:`scripts/dsh-develop.ts`——typecheck / test / build / status / commit / push / version / bump / deploy / restart-web / publish / pack-check / github-push 一条龙。
|
|
325
|
-
`
|
|
324
|
+
- **开发用小工具**:`scripts/dsh-develop.ts`——typecheck / test / build / status / commit / push / version / bump / deploy / **lockfile** / **host-upgrade** / restart-web / publish / pack-check / github-push 一条龙。
|
|
325
|
+
`lockfile` = 重生成锁文件 + 用 `--frozen-lockfile` 自检(CI 的 `Install (hooks)` 同款判定);
|
|
326
|
+
`pack-check` 会在发布前核对打包产物是否完整(曾经踩过"发到 npm 少了文件"的坑);`scripts/dsh-crash-investigate.ts` 用来查崩溃(只读)。
|
|
327
|
+
⚠️ **改完 `package.json` 依赖后必须跑 `lockfile` 并提交锁文件** —— v1.31.6 漏了这一步,CI 从此一直红(红在"测试根本没跑",见 CHANGELOG v1.31.10)
|
|
328
|
+
- **宿主类型基准 = devDependencies**(v1.31.11):`tsconfig.json` / `client/tsconfig.json` 的 `paths` 指向**仓库内** `node_modules/@deepseek-ai/*`,由精确钉版的 devDependencies 提供 → **新增 paths 条目必须同时加 devDependency**(否则 tsc 静默回落 node_modules = 假绿,CI 的 typecheck 也就形同虚设)。机械闸门见 `tests/compliance.test.ts` F7;升级宿主时只改 `package.json` 一处 + 重跑 `lockfile`
|
|
329
|
+
- **升级宿主(v1.31.12)**:`dsh-develop host-upgrade <版本|dist-tag>` 全局升级 DSH CLI(包名硬编码 `@deepseek-ai/dsh`、默认官方源、`--dry-run` 预览)→ 把 `package.json` 的 peer/devDeps 基准抬到同一版本 + 重跑 `lockfile`(`compliance.test.ts` F6c/F7d 与 `host-manifest.test.ts` 会强制各声明面同步,漏一处必红)→ `restart-web` → `dashboard health` 看 `dshVersion`
|
|
326
330
|
- **架构**:Cordis 原生插件,用 DSH 的正式接口注册工具和拦截点——**从不修改 DSH 本体**
|
|
327
331
|
- **代码地图**:[docs/codebase-overview-v1.22.md](https://github.com/tellmewhattodo/dsh-serenity-plugin/blob/master/docs/codebase-overview-v1.22.md)
|
|
328
332
|
- **设计决策**:见 [CHANGELOG.md](https://github.com/tellmewhattodo/dsh-serenity-plugin/blob/master/CHANGELOG.md) 和维护技能 `dsh-serenity-plugin-development`
|
|
@@ -381,4 +385,4 @@ pnpm build # 打包(lib/index.js + client.js)
|
|
|
381
385
|
|
|
382
386
|
MIT(见 [LICENSE](https://github.com/tellmewhattodo/dsh-serenity-plugin/blob/master/LICENSE))
|
|
383
387
|
|
|
384
|
-
> **版本**:v1.31.
|
|
388
|
+
> **版本**:v1.31.12 | **前置**:DSH 0.1.5-rc.2+ / Node ≥ 20 或 bun | **测试**:80 个文件 / 1180 个用例
|
package/dsh.plugin.json
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"id": "dsh-serenity-hooks",
|
|
3
|
-
"version": "1.31.
|
|
3
|
+
"version": "1.31.12",
|
|
4
4
|
"main": "lib/index.js",
|
|
5
|
-
"description": "宁静号 ACC harness(Native Cordis 插件):给 DSH 装一个「AI 工作区」——11 个工具(container_fs/logbook/dashboard/container_git/msm/praxis/handyman/localstore/container_admin/autopilot-trajectory/im-bridge)+ 机械约束(安全模式/工作区围墙/密钥守卫)+ 工作日志与原地重建 + 网页登录入口/微信桥/子角色/对外问答页/自主巡航。适配 DSH 0.1.5-rc.
|
|
5
|
+
"description": "宁静号 ACC harness(Native Cordis 插件):给 DSH 装一个「AI 工作区」——11 个工具(container_fs/logbook/dashboard/container_git/msm/praxis/handyman/localstore/container_admin/autopilot-trajectory/im-bridge)+ 机械约束(安全模式/工作区围墙/密钥守卫)+ 工作日志与原地重建 + 网页登录入口/微信桥/子角色/对外问答页/自主巡航。适配 DSH 0.1.5-rc.2(deepseek-ai/deepseek-harness)。",
|
|
6
6
|
"engines": {
|
|
7
|
-
"dsh": ">=0.1.5-rc.
|
|
7
|
+
"dsh": ">=0.1.5-rc.2"
|
|
8
8
|
},
|
|
9
9
|
"contributes": {
|
|
10
10
|
"tools": [
|
package/lib/host/contract.d.ts
CHANGED
|
@@ -62,7 +62,7 @@ export type HostEventName = (typeof HOST_EVENT_NAMES)[number];
|
|
|
62
62
|
*/
|
|
63
63
|
export declare const HOST_EVENTS: readonly HostEventContract[];
|
|
64
64
|
/** dsp 被验证过的宿主版本范围(与 package.json peerDependencies 同源,单一真相源) */
|
|
65
|
-
export declare const REQUIRED_HOST_RANGE = "^0.1.5-rc.
|
|
65
|
+
export declare const REQUIRED_HOST_RANGE = "^0.1.5-rc.2";
|
|
66
66
|
export interface HostContractIssue {
|
|
67
67
|
id: string;
|
|
68
68
|
kind: 'service' | 'member' | 'version';
|
package/lib/index.js
CHANGED
|
@@ -1302,8 +1302,8 @@ const HOST_SERVICES = [
|
|
|
1302
1302
|
}
|
|
1303
1303
|
];
|
|
1304
1304
|
/** dsp 被验证过的宿主版本范围(与 package.json peerDependencies 同源,单一真相源) */
|
|
1305
|
-
const REQUIRED_HOST_RANGE = "^0.1.5-rc.
|
|
1306
|
-
/** 范围 floor:剥掉 caret/比较前缀(`^0.1.5-rc.
|
|
1305
|
+
const REQUIRED_HOST_RANGE = "^0.1.5-rc.2";
|
|
1306
|
+
/** 范围 floor:剥掉 caret/比较前缀(`^0.1.5-rc.2` → `0.1.5-rc.2`),供 {@link checkHostVersion} 使用 */
|
|
1307
1307
|
const REQUIRED_HOST_FLOOR = REQUIRED_HOST_RANGE.replace(/^[\^~>=<\s]+/, "");
|
|
1308
1308
|
/** 范围 ceiling:`^0.1.x` 的上界 = `<0.2.0`(显式常量,见 {@link checkHostVersion} 注释) */
|
|
1309
1309
|
const REQUIRED_HOST_CEILING = "0.2.0";
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shgroup/dsh-serenity-hooks",
|
|
3
|
-
"version": "1.31.
|
|
4
|
-
"description": "宁静号 ACC harness(Native Cordis 插件)——给 DeepSeek Harness 装一个「AI 工作区」:11 个工具(container_fs/logbook/dashboard/container_git/msm/praxis/handyman/localstore/container_admin/autopilot-trajectory/im-bridge)+ 机械约束(安全模式/工作区围墙/密钥守卫/对外输出守卫)+ 工作日志与原地重建 + 网页登录入口/微信桥/子角色/对外问答页/自主巡航。适配 DSH 0.1.5-rc.
|
|
3
|
+
"version": "1.31.12",
|
|
4
|
+
"description": "宁静号 ACC harness(Native Cordis 插件)——给 DeepSeek Harness 装一个「AI 工作区」:11 个工具(container_fs/logbook/dashboard/container_git/msm/praxis/handyman/localstore/container_admin/autopilot-trajectory/im-bridge)+ 机械约束(安全模式/工作区围墙/密钥守卫/对外输出守卫)+ 工作日志与原地重建 + 网页登录入口/微信桥/子角色/对外问答页/自主巡航。适配 DSH 0.1.5-rc.2。",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
7
7
|
"type": "git",
|
|
@@ -52,24 +52,24 @@
|
|
|
52
52
|
}
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
|
-
"@deepseek-ai/
|
|
56
|
-
"@deepseek-ai/dsh-agent
|
|
57
|
-
"@deepseek-ai/dsh-agent-
|
|
58
|
-
"@deepseek-ai/dsh-
|
|
59
|
-
"@deepseek-ai/dsh-
|
|
60
|
-
"@deepseek-ai/dsh-
|
|
61
|
-
"@deepseek-ai/dsh-
|
|
62
|
-
"@deepseek-ai/dsh-session
|
|
63
|
-
"@deepseek-ai/dsh-
|
|
64
|
-
"@deepseek-ai/dsh-shell
|
|
65
|
-
"@deepseek-ai/dsh-
|
|
66
|
-
"@deepseek-ai/dsh-
|
|
67
|
-
"@deepseek-ai/dsh-
|
|
68
|
-
"@deepseek-ai/dsh-
|
|
69
|
-
"@deepseek-ai/dsh-web
|
|
55
|
+
"@deepseek-ai/cordis": "^4.0.2",
|
|
56
|
+
"@deepseek-ai/dsh-agent": "^0.1.5-rc.2",
|
|
57
|
+
"@deepseek-ai/dsh-agent-loop": "^0.1.5-rc.2",
|
|
58
|
+
"@deepseek-ai/dsh-agent-presets": "^0.1.5-rc.2",
|
|
59
|
+
"@deepseek-ai/dsh-compaction": "^0.1.5-rc.2",
|
|
60
|
+
"@deepseek-ai/dsh-host-webserver": "^0.1.5-rc.2",
|
|
61
|
+
"@deepseek-ai/dsh-llm": "^0.1.5-rc.2",
|
|
62
|
+
"@deepseek-ai/dsh-session": "^0.1.5-rc.2",
|
|
63
|
+
"@deepseek-ai/dsh-session-title": "^0.1.5-rc.2",
|
|
64
|
+
"@deepseek-ai/dsh-shell": "^0.1.5-rc.2",
|
|
65
|
+
"@deepseek-ai/dsh-shell-env": "^0.1.5-rc.2",
|
|
66
|
+
"@deepseek-ai/dsh-skill": "^0.1.5-rc.2",
|
|
67
|
+
"@deepseek-ai/dsh-system-prompt": "^0.1.5-rc.2",
|
|
68
|
+
"@deepseek-ai/dsh-tools": "^0.1.5-rc.2",
|
|
69
|
+
"@deepseek-ai/dsh-web": "^0.1.5-rc.2",
|
|
70
|
+
"@deepseek-ai/dsh-web-fetch-http": "^0.1.5-rc.2",
|
|
70
71
|
"@deepseek-ai/schemastery": "^3.18.2",
|
|
71
|
-
"cordis": "^4.0.
|
|
72
|
-
"@deepseek-ai/cordis": "^4.0.2"
|
|
72
|
+
"cordis": "^4.0.0-rc.7"
|
|
73
73
|
},
|
|
74
74
|
"peerDependenciesMeta": {
|
|
75
75
|
"@deepseek-ai/dsh-host-webserver": {
|
|
@@ -95,6 +95,38 @@
|
|
|
95
95
|
}
|
|
96
96
|
},
|
|
97
97
|
"devDependencies": {
|
|
98
|
+
"@deepseek-ai/cordis": "^4.0.2",
|
|
99
|
+
"@deepseek-ai/dsh-agent": "0.1.5-rc.2",
|
|
100
|
+
"@deepseek-ai/dsh-agent-loop": "0.1.5-rc.2",
|
|
101
|
+
"@deepseek-ai/dsh-agent-presets": "0.1.5-rc.2",
|
|
102
|
+
"@deepseek-ai/dsh-api-session-controller": "0.1.5-rc.2",
|
|
103
|
+
"@deepseek-ai/dsh-client-connection": "0.1.5-rc.2",
|
|
104
|
+
"@deepseek-ai/dsh-client-locale": "0.1.5-rc.2",
|
|
105
|
+
"@deepseek-ai/dsh-client-ui-conversation": "0.1.5-rc.2",
|
|
106
|
+
"@deepseek-ai/dsh-client-ui-primitives": "0.1.5-rc.2",
|
|
107
|
+
"@deepseek-ai/dsh-client-ui-renderer": "0.1.5-rc.2",
|
|
108
|
+
"@deepseek-ai/dsh-client-ui-session": "0.1.5-rc.2",
|
|
109
|
+
"@deepseek-ai/dsh-client-ui-settings": "0.1.5-rc.2",
|
|
110
|
+
"@deepseek-ai/dsh-client-ui-slots": "0.1.5-rc.2",
|
|
111
|
+
"@deepseek-ai/dsh-compaction": "0.1.5-rc.2",
|
|
112
|
+
"@deepseek-ai/dsh-host-webserver": "0.1.5-rc.2",
|
|
113
|
+
"@deepseek-ai/dsh-llm": "0.1.5-rc.2",
|
|
114
|
+
"@deepseek-ai/dsh-session": "0.1.5-rc.2",
|
|
115
|
+
"@deepseek-ai/dsh-session-persistence": "0.1.5-rc.2",
|
|
116
|
+
"@deepseek-ai/dsh-session-projection": "0.1.5-rc.2",
|
|
117
|
+
"@deepseek-ai/dsh-session-title": "0.1.5-rc.2",
|
|
118
|
+
"@deepseek-ai/dsh-settings": "0.1.5-rc.2",
|
|
119
|
+
"@deepseek-ai/dsh-shell": "0.1.5-rc.2",
|
|
120
|
+
"@deepseek-ai/dsh-shell-env": "0.1.5-rc.2",
|
|
121
|
+
"@deepseek-ai/dsh-skill": "0.1.5-rc.2",
|
|
122
|
+
"@deepseek-ai/dsh-subagent": "0.1.5-rc.2",
|
|
123
|
+
"@deepseek-ai/dsh-system-prompt": "0.1.5-rc.2",
|
|
124
|
+
"@deepseek-ai/dsh-token-meter": "0.1.5-rc.2",
|
|
125
|
+
"@deepseek-ai/dsh-tools": "0.1.5-rc.2",
|
|
126
|
+
"@deepseek-ai/dsh-web": "0.1.5-rc.2",
|
|
127
|
+
"@deepseek-ai/dsh-web-fetch-http": "0.1.5-rc.2",
|
|
128
|
+
"@deepseek-ai/dsh-workspace": "0.1.5-rc.2",
|
|
129
|
+
"@deepseek-ai/schemastery": "^3.18.2",
|
|
98
130
|
"@types/node": "^20.0.0",
|
|
99
131
|
"@types/qrcode-generator": "^1.0.6",
|
|
100
132
|
"@types/react": "^18.2.0",
|