dsh-custom-mode 1.11.2 → 1.11.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.
- package/README.i18n.yaml +2 -2
- package/README.md +3 -3
- package/README.zh.md +3 -3
- package/assistants.mjs +17 -1
- package/package.json +1 -1
package/README.i18n.yaml
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
# 双语配对一致性记录:两侧在「上次确认一致」时的 git blob 哈希。
|
|
2
2
|
# 两份文档权威相同——改完任意一侧,请把另一侧也改掉,然后重新记录:
|
|
3
3
|
# node tools/verify-translation-pairing.mjs --write
|
|
4
|
-
README.md:
|
|
5
|
-
README.zh.md:
|
|
4
|
+
README.md: fbadaafe0eb03a398ee41f8edcd4b76c3eba89fd
|
|
5
|
+
README.zh.md: 476ff7b04b4a1c2392bc04c022ba6d14de191235
|
package/README.md
CHANGED
|
@@ -59,7 +59,7 @@ One command installs everything — the settings-page plugin, and the preset it
|
|
|
59
59
|
activation:
|
|
60
60
|
|
|
61
61
|
```sh
|
|
62
|
-
dsh plugin --profile web add dsh-custom-mode@1.11.
|
|
62
|
+
dsh plugin --profile web add dsh-custom-mode@1.11.3 # pin the version to get this one for sure
|
|
63
63
|
# A bare `add dsh-custom-mode` is subject to pnpm's release cooldown (`minimumReleaseAge`, 1 day by
|
|
64
64
|
# default): for hours after a release it can silently install an OLDER version — measured: a bare
|
|
65
65
|
# install 38 minutes after 1.3.0 shipped landed on 1.0.3. Check what you got with `npm ls
|
|
@@ -118,7 +118,7 @@ Electron shell**, so this plugin's page renders there unchanged. One install pat
|
|
|
118
118
|
too and points you at the app, so the two agree instead of one silently working around the other.
|
|
119
119
|
(A lab simulation of the profile shape can override it with `DSH_ALLOW_DESKTOP_PROFILE=1`.)
|
|
120
120
|
**The app's own bundled CLI is the exception** — `<install>\resources\runtime\cli\bin\dsh.cmd` is allowed
|
|
121
|
-
to operate on that profile (measured on 1.11.1: `add dsh-custom-mode@1.11.
|
|
121
|
+
to operate on that profile (measured on 1.11.1: `add dsh-custom-mode@1.11.3` → `+ dsh-custom-mode 1.11.1`).
|
|
122
122
|
It is a launcher, not a dsh feature: it starts Electron with `ELECTRON_RUN_AS_NODE=1` and runs the
|
|
123
123
|
desktop-host CLI, so it is the app talking to its own profile rather than something driving from outside.
|
|
124
124
|
- **Nothing else to do on the preset side**: `$DSH_HOME/.agent-presets/` is product data shared by the
|
|
@@ -430,7 +430,7 @@ installing again — your data is not touched:
|
|
|
430
430
|
|
|
431
431
|
```sh
|
|
432
432
|
# the pinned form: what you ask for is what you get
|
|
433
|
-
dsh plugin --profile web add dsh-custom-mode@1.11.
|
|
433
|
+
dsh plugin --profile web add dsh-custom-mode@1.11.3
|
|
434
434
|
# then restart the DSH process that serves the web profile
|
|
435
435
|
```
|
|
436
436
|
|
package/README.zh.md
CHANGED
|
@@ -48,7 +48,7 @@ base mode / plugin switches / multi-assistant / multi-persona。
|
|
|
48
48
|
一条命令装完——设置页插件,以及它在首次激活时自动播种的 preset:
|
|
49
49
|
|
|
50
50
|
```sh
|
|
51
|
-
dsh plugin --profile web add dsh-custom-mode@1.11.
|
|
51
|
+
dsh plugin --profile web add dsh-custom-mode@1.11.3 # 钉版本才能确定拿到这一版
|
|
52
52
|
# 不带版本号会受 pnpm 的发布冷却期影响(`minimumReleaseAge`,默认一天):发布后数小时内按名安装
|
|
53
53
|
# 可能**静默装到旧版** —— 实测 1.3.0 发布 38 分钟后按名安装装到了 1.0.3。用 profile 里的
|
|
54
54
|
# `npm ls dsh-custom-mode` 核对实际装到的版本,或像上面那样钉版本。
|
|
@@ -98,7 +98,7 @@ dsh `0.1.6-alpha.2` 起有插件管理页:**侧边栏 → 插件 → 添加插
|
|
|
98
98
|
`cordis.patch.yml`。所以 `install.sh` 也**拒绝** `--profile desktop` 并指向应用内安装 —— 两边一致,
|
|
99
99
|
而不是某一方偷偷绕过去。(只想在本机模拟 profile 形状时可设 `DSH_ALLOW_DESKTOP_PROFILE=1`。)
|
|
100
100
|
**应用自带的捆绑 CLI 是例外**:`<安装目录>\resources\runtime\cli\bin\dsh.cmd` 可以操作那个 profile
|
|
101
|
-
(1.11.1 实测:`add dsh-custom-mode@1.11.
|
|
101
|
+
(1.11.1 实测:`add dsh-custom-mode@1.11.3` → `+ dsh-custom-mode 1.11.1`)。它是启动器而不是 dsh 的
|
|
102
102
|
新功能 —— 它用 `ELECTRON_RUN_AS_NODE=1` 起 Electron 去跑 desktop-host 的 CLI,所以那是**应用在跟自己的
|
|
103
103
|
profile 说话**,不是从外面驱动它。
|
|
104
104
|
- **预设那一侧不用做任何事**:`$DSH_HOME/.agent-presets/` 是桌面端与 CLI 共享的产品数据,
|
|
@@ -330,7 +330,7 @@ MIT
|
|
|
330
330
|
|
|
331
331
|
```sh
|
|
332
332
|
# 钉版本的写法:要哪版就是哪版
|
|
333
|
-
dsh plugin --profile web add dsh-custom-mode@1.11.
|
|
333
|
+
dsh plugin --profile web add dsh-custom-mode@1.11.3
|
|
334
334
|
# 然后重启为该 profile 提供服务的 DSH 进程
|
|
335
335
|
```
|
|
336
336
|
|
package/assistants.mjs
CHANGED
|
@@ -34,7 +34,7 @@ import { dshHome, PRESET_DIR } from './paths.mjs'
|
|
|
34
34
|
import { readPresetMeta, writePresetMeta, presetMetaPath } from './meta.mjs'
|
|
35
35
|
import { writeAtomic } from './atomic.mjs'
|
|
36
36
|
import { unresolvableRows } from './composition.mjs'
|
|
37
|
-
import { seedPreset, seedPresetWithLog } from './seed.mjs'
|
|
37
|
+
import { seedPreset, seedPresetWithLog, dropShippedDescription } from './seed.mjs'
|
|
38
38
|
|
|
39
39
|
/**
|
|
40
40
|
* Preset ids a directory may use, mirrored from
|
|
@@ -326,6 +326,22 @@ export function seedOnActivation({ root, templateDir, composition, log = console
|
|
|
326
326
|
for (const error of result.errors) log(`custom-mode: 补全 ${dir} 失败 —— ${error}`)
|
|
327
327
|
}
|
|
328
328
|
|
|
329
|
+
// 描述迁移:清掉我们早年播种的那条中英拼接(详见 seed.mjs 的 dropShippedDescription)。
|
|
330
|
+
//
|
|
331
|
+
// ★ 必须放在**这里**,不能只放在 `seedPresetWithLog` 里:下面第 348 行 `isSeeded(root)` 一旦为真就直接
|
|
332
|
+
// return,那条路永远不会走到 —— 而"已经装过插件"恰恰是这个迁移唯一要处理的场景(实测:装到 1.11.2
|
|
333
|
+
// 之后描述仍是旧的)。放在这个循环里,每次激活都会检查,且 `dropShippedDescription` 只认**逐字**
|
|
334
|
+
// 等于我们自己写过的那些串,用户自己写的描述一个字都不会动。
|
|
335
|
+
for (const dir of existing) {
|
|
336
|
+
try {
|
|
337
|
+
if (dropShippedDescription(dir).migrated === true) {
|
|
338
|
+
info(`custom-mode: 已清空 ${dir} 的描述 —— 它还是我们早年播种的那条中英拼接,壳无法按界面语言本地化产品数据`)
|
|
339
|
+
}
|
|
340
|
+
} catch (error) {
|
|
341
|
+
log(`custom-mode: 描述迁移失败(已忽略)—— ${describe(error)}`)
|
|
342
|
+
}
|
|
343
|
+
}
|
|
344
|
+
|
|
329
345
|
// 启动告警:组成文件里有本机这条线解析不到的行时,平台会把整个预设判为 broken 并从选择器里**静默丢弃**。
|
|
330
346
|
// 以前这件事只在设置页可见 —— 用户从不打开设置页就完全无感知(外部评审实测)。这里至少在宿主日志里喊一声。
|
|
331
347
|
for (const dir of [...existing, join(root, LEGACY_ID)]) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-custom-mode",
|
|
3
|
-
"version": "1.11.
|
|
3
|
+
"version": "1.11.3",
|
|
4
4
|
"description": "Custom modes and custom prompts for DeepSeek Harness (dsh): edit a mode's system prompt on the settings page (it takes effect on the next model step), pick its base mode, switch plugin rows one by one, and keep several assistants side by side — coding, chat or roleplay (RP) personas (multi-mode / multi-agent).",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|