@marsken/dsh-studio 0.1.16 → 0.1.17
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/AGENTS.md +4 -1
- package/README.md +23 -5
- package/docs/compatibility.md +1 -1
- package/docs/images/board.png +0 -0
- package/docs/images/cases.png +0 -0
- package/docs/images/drawer.png +0 -0
- package/docs/images/quality.png +0 -0
- package/docs/images/releases.png +0 -0
- package/docs/images/requirements.png +0 -0
- package/docs/images/settings-cost.png +0 -0
- package/docs/images/settings-execution.png +0 -0
- package/docs/images/settings-experts.png +0 -0
- package/docs/images/workbench.png +0 -0
- package/docs/publish.md +7 -1
- package/package.json +5 -2
package/AGENTS.md
CHANGED
|
@@ -78,7 +78,9 @@ STUDIO_TOKEN=$(sudo journalctl -u dsh-web -n 50 | grep -o 'token=[A-Za-z0-9_-]*'
|
|
|
78
78
|
6. `npm test`(条数以 `npm run check` 打印的为准,别再写死数字;覆盖范围是:`tests/repo.test.mjs` 管 manifest / 产物一致 / 宿主接口 / 领域层拆分与导入 / **导入只读绑定不许赋值** / **跨模块符号必须导入** / 迁移 / 文档 / locale / **用了 `React.` 的组件必须从 `client()` 或工厂参数拿到 `React`**;`tests/client-units.test.mjs` 用真实模块跑标签表/负责人/日期/命令面板检索这些纯函数;`tests/notify.test.mjs` 起一个本地 HTTP 桩验证飞书通知(正文归一、`botWants` 的事件矩阵、`feishuBroadcast` 只发给订阅该事件的机器人);`tests/store-boot.test.mjs` 真的起一个 `StudioStore`,把「搬完代码启动就炸」这类问题挡在部署前。想连真数据验证:把生产库三个文件(`.db`/`-wal`/`-shm`)拷到临时目录,用 `new StudioStore()` + `await store.ready` 跑一遍,`tmp/boot-real.mjs` 就是这么写的);`npm run check` = 语法 + 契约一把过
|
|
79
79
|
7. 构建期守卫:`web/scripts/guard.mjs`(`pnpm build` 自动跑两次)——禁 CSS 里出现 `hsl(var(--x))`、禁 Radix Portal 不挂 `container={portalRoot()}`、产物里必须留下 `data-dsh-studio-portal`。单独跑:`cd web && npm run guard`
|
|
80
80
|
8. 真库自检:`npm run smoke:store -- ~/.dsh/dsh-studio.db`(把 `.db/-wal/-shm` 拷到临时目录起一遍真实 `StudioStore`,专抓「空库能起、真库就炸」的导入问题)
|
|
81
|
-
9.
|
|
81
|
+
9. 成本数字可疑时跑 `npm run verify:usage [taskId]`:ssh 取原始会话日志现算一遍 token,与 `/costs` 对账(两条路径不同:一条走 session-usage 的 zstd 缓存,一条走 usage.js 直接解析)。
|
|
82
|
+
10. 发版后跑 `npm run verify:release`:比对 package.json 版本 / 本地 tag / origin main 与 tag / npm registry,不一致直接退出码 1。
|
|
83
|
+
11. CI 在 `.github/workflows/ci.yml`:语法 → 契约 → `web/` 里 `pnpm install --frozen-lockfile && pnpm build` → `cmp dist/client.js client.js` → `git diff --exit-code`(产物必须可复现,改了前端忘记构建会直接红)
|
|
82
84
|
|
|
83
85
|
## 5. 禁止事项
|
|
84
86
|
|
|
@@ -149,4 +151,5 @@ GIT_SSH_COMMAND="ssh -p 443" git push
|
|
|
149
151
|
| 点击页面卡顿 | DevTools Performance 找长任务;`keyboardPatch` 之类全量扫描是历史元凶 |
|
|
150
152
|
| 派单没留言 | 会话日志里找 `turn/end reason.kind=error`;常见是模型无可用通道(503) |
|
|
151
153
|
| 保存成功但字段为空 | `publicConfig`/`mergeConfig`/`sanitize*` 白名单漏字段 |
|
|
154
|
+
| 测完失败路径改动没生效 | 用 `git checkout -- package.json` 还原测试用的假版本,会把**同一个文件里**刚加的其它改动一起还原。还原后 `grep` 一下你新加的那行还在不在 |
|
|
152
155
|
| 用脚本改文档后「什么都没变」 | 生成脚本文本里带了反引号,把模板字符串截断了:Node 抛 `ReferenceError: xxx is not defined` 但**编辑一句都没执行**。改完看 `git status`,别只看脚本退出码 |
|
package/README.md
CHANGED
|
@@ -9,13 +9,29 @@
|
|
|
9
9
|
|
|
10
10
|
## 它长什么样
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
## 它长什么样
|
|
13
|
+
|
|
14
|
+
| 工作台:今天该做什么、谁在忙 | 看板:八列、角色负责人、卡片带进度/用例 |
|
|
15
|
+
| --- | --- |
|
|
16
|
+
|  |  |
|
|
17
|
+
|
|
18
|
+
| 卡片抽屉:状态 / 清单 / 用例 / 执行记录 | 需求:基线、变更影响面、可追溯矩阵 |
|
|
13
19
|
| --- | --- |
|
|
14
|
-
|  |  |
|
|
15
21
|
|
|
16
|
-
|
|
|
17
|
-
| --- |
|
|
18
|
-
|  |  |
|
|
25
|
+
|
|
26
|
+
| 版本:发布、灰度、部署记录 | 设置·测试执行:执行开关、数量上限、出站 webhook |
|
|
27
|
+
| --- | --- |
|
|
28
|
+
|  |  |
|
|
29
|
+
|
|
30
|
+
| 设置·成本与预算:价目表(元/百万 token) | 设置·专家:8 位专家、模型与提示词 |
|
|
31
|
+
| --- | --- |
|
|
32
|
+
|  |  |
|
|
33
|
+
|
|
34
|
+
截图不是手截的:`npm run shots`(`tools/visual/capture.mjs`)会登录面板、逐个页签截一遍,顺手断言没有「渲染失败」。
|
|
19
35
|
|
|
20
36
|
|
|
21
37
|
## 部署
|
|
@@ -417,6 +433,8 @@ sudo systemctl restart dsh-web
|
|
|
417
433
|
] } }
|
|
418
434
|
```
|
|
419
435
|
|
|
436
|
+
对账命令:`npm run verify:usage [taskId]`——ssh 取原始日志现算一遍,和 `/costs` 的数字比。
|
|
437
|
+
|
|
420
438
|
**实测**(线上 3045 次调用 / 2.42 亿 token):配价目表后算出 ¥81.47,其中 719 次调用因模型没配价目记「未知」;清空价目表后花费显示 `null`(未知),不会按 0 算。
|
|
421
439
|
- 口径见上一节七条;订阅通道(`*-coding` / `*-token-plan`)记 token、不计钱。
|
|
422
440
|
|
package/docs/compatibility.md
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
| 项 | 值 |
|
|
8
8
|
| --- | --- |
|
|
9
|
-
| dsh-studio | `package.json` `version: 0.1.
|
|
9
|
+
| dsh-studio | `package.json` `version: 0.1.17` |
|
|
10
10
|
| DeepSeek Harness | `0.2.2-rc.1`(`dsh --version`) |
|
|
11
11
|
| Node | `v24.22.2`(Linux 目标机);本机 Windows `v24.19.0` |
|
|
12
12
|
| 目标系统 | Ubuntu 24.04,`dsh web` 监听 `18080`,nginx `:80` 反代并注入 `dsh-auth-*` cookie |
|
package/docs/images/board.png
CHANGED
|
Binary file
|
package/docs/images/cases.png
CHANGED
|
Binary file
|
|
Binary file
|
package/docs/images/quality.png
CHANGED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/docs/publish.md
CHANGED
|
@@ -127,6 +127,7 @@ token 只写进临时 npmrc(放在仓库外或 `tmp/` 且不提交),发完
|
|
|
127
127
|
| --- | --- | --- |
|
|
128
128
|
| `0.1.0` | 2026-11-13 | 首个公开版:看板 / 需求 / 用例回归 / 效能 / 设计评审四期 |
|
|
129
129
|
| `0.1.1` | 2026-11-13 | 补三张 README 截图(npm 页可看图);默认值与文档去掉公司内网信息 |
|
|
130
|
+
| `0.1.17` | 2026-11-15 | 截图补到 10 张,且有脚本可重跑 |
|
|
130
131
|
| `0.1.16` | 2026-11-15 | quickstart 命令修正 + GitLab 打桩验证配方 |
|
|
131
132
|
| `0.1.15` | 2026-11-15 | 清掉三处过期的「已知限制」 |
|
|
132
133
|
| `0.1.14` | 2026-11-15 | 修正成本口径的过期文案 |
|
|
@@ -147,4 +148,9 @@ token 只写进临时 npmrc(放在仓库外或 `tmp/` 且不提交),发完
|
|
|
147
148
|
|
|
148
149
|
1. `npm run check` + `pnpm build` + `cmp -s dist/client.js client.js`(产物必须逐字节一致);
|
|
149
150
|
2. 发完**在临时 profile 里装一遍**并跑 `dsh --profile <tmp> --dump-config | grep dsh-studio`,确认宿主真认到了,然后把 profile 删掉;
|
|
150
|
-
3.
|
|
151
|
+
3. **发版一致性用命令查,不靠记性**:`npm run verify:release`(= `node tools/verify-release.mjs`)比对五处——
|
|
152
|
+
package.json 版本、本地 tag、tag 里的 package.json、origin/main 与 origin 上的 tag、npm registry 的版本与 latest。
|
|
153
|
+
全绿输出「发版一致」,有不一致退出码 1。
|
|
154
|
+
这条是因为 0.1.15/0.1.16 真的发到 npm 了、git 却没推上去:`git tag -f vX.Y.Z && git push ... | tail -1` 会把 push 的失败吞掉。
|
|
155
|
+
npm latest 滞后(刚发几分钟)只算 warn,不算失败。
|
|
156
|
+
4. 部署脚本退出码 0 **不等于服务活着**——它打印的 `state=` 要自己看一眼,再单独 `curl -o /dev/null -w '%{http_code}' <host>/studio-api/state` 确认 200(2026-11-13 有过一次 `state=404` 被当成成功,线上挂了十分钟)。
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@marsken/dsh-studio",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.17",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "DSH Studio: role-based multi-agent workspace (product / architect / developer / QA) with a live work board, GitLab + Feishu connection settings, all configurable from the web GUI.",
|
|
6
6
|
"main": "index.js",
|
|
@@ -13,7 +13,10 @@
|
|
|
13
13
|
"check": "node --check index.js && node --check client.src.js && node --test tests/repo.test.mjs tests/store-boot.test.mjs tests/client-units.test.mjs tests/notify.test.mjs",
|
|
14
14
|
"smoke:store": "node scripts/smoke-store.mjs",
|
|
15
15
|
"mock:gitlab": "node tools/mock-gitlab.mjs",
|
|
16
|
-
"verify:gitlab": "node tools/verify-gitlab-facts.mjs"
|
|
16
|
+
"verify:gitlab": "node tools/verify-gitlab-facts.mjs",
|
|
17
|
+
"verify:release": "node tools/verify-release.mjs",
|
|
18
|
+
"verify:usage": "node tools/verify-usage.mjs",
|
|
19
|
+
"shots": "node tools/visual/capture.mjs"
|
|
17
20
|
},
|
|
18
21
|
"exports": {
|
|
19
22
|
".": "./index.js",
|