@lynn123411/dsh-preset-plugin-upgrade-cordis 0.1.0 → 0.1.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.md +26 -2
- package/UPSTREAM.md +26 -1
- package/package.json +5 -2
- package/plugin-upgrade-cordis.patch.yml +7 -27
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# plugin-upgrade-cordis — 插件升级创造模式
|
|
2
2
|
|
|
3
|
-
> 官方**创造模式**(preset id `cordis`)**逐字保留**:同样的 persona、同样的工具矩阵、同样的计划 / 压缩 / 子代理编排与动态插件工具 `tool-cordis`。在此之上并入 [oh-my-dsh/dsh-plugin-upgrade-skill](https://github.com/oh-my-dsh/dsh-plugin-upgrade-skill) 的 **11 个插件工程技能**(随包 `skills/`)。会话选择器里的显示名是**插件升级创造模式**。
|
|
3
|
+
> 官方**创造模式**(preset id `cordis`,抄自 DSH **0.2.1-alpha.3** 的 `presets/cordis.patch.yml`)**逐字保留**:同样的 persona、同样的工具矩阵、同样的计划 / 压缩 / 子代理编排与动态插件工具 `tool-cordis`。在此之上并入 [oh-my-dsh/dsh-plugin-upgrade-skill](https://github.com/oh-my-dsh/dsh-plugin-upgrade-skill) 的 **11 个插件工程技能**(随包 `skills/`)。会话选择器里的显示名是**插件升级创造模式**。
|
|
4
4
|
|
|
5
5
|
## 与官方创造模式的异同
|
|
6
6
|
|
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
|
|
13
13
|
`skill-filesystem` 那一行只改了 `customSkillDirs`:在官方那条之前插入本包的根,其余字段一字未动。
|
|
14
14
|
|
|
15
|
+
抄本的基线随 DSH 走:**抄本必须与运行中的 DSH 同一个版本**。官方 `presets/*.patch.yml` 每一版都会动——0.2.1-alpha.2 → 0.2.1-alpha.3 就动了两处(plan-mode 那句的措辞、子代理两行删掉 `toolFilter.deny` 的 `schedule_*`)。抄本落后不会报错,只会静默地与官方不一致;**唯一会当场炸的是引用了已被删掉的提示词变量**(如 0.2.0-rc.2 删掉的 `{{cwd}}`:变量严格解析,抛错即整轮请求失败),见下面「已知边界」。
|
|
16
|
+
|
|
15
17
|
## 组成
|
|
16
18
|
|
|
17
19
|
```
|
|
@@ -58,7 +60,7 @@ plugin-upgrade-cordis/
|
|
|
58
60
|
| `dsh-v0.1.7-rc.2 → dsh-v0.2.0-rc.1` | ✅ 6 张卡([v0.2.0-rc.1.md](skills/plugin-upgrade/references/v0.2.0-rc.1.md)) |
|
|
59
61
|
| `dsh-v0.1.7-rc.1 → dsh-v0.1.7-rc.2` | ❌ 未成卡(卡文件内自带声明) |
|
|
60
62
|
| `dsh-v0.2.0-rc.1 → dsh-v0.2.0-rc.2` | ⚠️ 只有同文件末尾两条 field notes,未成卡 |
|
|
61
|
-
| `dsh-v0.2.0-rc.2 → dsh-v0.2.1-alpha.1` | ❌ 上游尚无(DSH 已发布 0.2.1-alpha.
|
|
63
|
+
| `dsh-v0.2.0-rc.2 → dsh-v0.2.1-alpha.1` | ❌ 上游尚无(DSH 已发布 0.2.1-alpha.3) |
|
|
62
64
|
|
|
63
65
|
完整索引在 [references/README.md](skills/plugin-upgrade/references/README.md),**按 `from → to` 走廊读,不按文件名顺序**。目标版本没有卡时,**同步上游解决不了**——那正是随包 `dsh-upgrade-audit`(对比两个版本、产证据)与 `plugin-workflow`(编排)的用武之地;产出的证据可以回馈成上游的一张新卡。
|
|
64
66
|
|
|
@@ -123,6 +125,26 @@ node presets/plugin-upgrade-cordis/check-upstream.mjs
|
|
|
123
125
|
|
|
124
126
|
**真装载**——隔离 `DSH_HOME` 的 profile 里 `dsh plugin add` 本目录后 boot(`--port 0 --no-open`),在新会话里选中本 preset,打开 `/` 菜单的「技能」段:应与官方 4 个技能同时在列。实测记录见下。
|
|
125
127
|
|
|
128
|
+
### 适配实测记录(0.2.1-alpha.3,2026-10-15)
|
|
129
|
+
|
|
130
|
+
运行中的 DSH 升到 0.2.1-alpha.3 后按 [UPSTREAM.md](./UPSTREAM.md)「再抄官方 preset」重抄一遍。这版官方只动了两处,抄本都已跟上:plan-mode 那句改成「until the user approves your plan through exit_plan_mode」,子代理两行删掉 `toolFilter.deny` 的 `schedule_*`(子代理从此照官方拿得到 `schedule_*` 工具)。
|
|
131
|
+
|
|
132
|
+
- `diff -u <官方 cordis.patch.yml> plugin-upgrade-cordis.patch.yml`:只剩三处既定差异(顶部注释、行 id / 显示名 / `order`、`skill-filesystem` 多一个 custom root)。
|
|
133
|
+
- `--dump-config` exit 0,组合树里 `preset-plugin-upgrade-cordis` 行与它的 `config.plugins` 齐全。
|
|
134
|
+
- `check-upstream.mjs --verify` PASS(11 个技能的树哈希与锁一致),在线模式报 `identical`。
|
|
135
|
+
- 裸探针(真实 0.2.1-alpha.3 的 `FileSystemSkillProvider` + `customSkillDirs=[skills/]`、`includeDefaultRoots: false`、`watch: false`):11 个候选、`source=custom`、0 条警告、11 个 `SKILL.md` 正文全部可加载、`resourceBase` 指向各自的技能目录。
|
|
136
|
+
- 提示词变量扫描仍只落在 `{{model}}`:0.2.1-alpha.3 的 `agent-loop` 也只注册 `model` 与 `provider` 两个变量。
|
|
137
|
+
|
|
138
|
+
> 本轮没有重跑真装载与浏览器里的选择器那一段。
|
|
139
|
+
|
|
140
|
+
### 适配实测记录(0.2.1-alpha.2,2026-10-11)
|
|
141
|
+
|
|
142
|
+
隔离 `DSH_HOME` 里建一个只挂 `dsh-base` + `dsh-web-app` + 本目录的 web profile(`pnpm install` 重建 `link:`),boot(`--port 0 --no-open`)**无任何启动诊断**;`--dump-config` exit 0,组合树里 `preset-plugin-upgrade-cordis` 行的 `config.plugins` 与官方 `cordis` 逐行对齐(只剩三处既定差异:行 id、显示名 / order、`skill-filesystem` 多一个 custom root)。裸探针(真实 `FileSystemSkillProvider` + `customSkillDirs=[skills/]`,取 0.2.1 的 `get(candidate, options)` 签名)给:11 个候选、`source=custom`、0 条警告、11 个 `SKILL.md` 正文全部可加载。
|
|
143
|
+
|
|
144
|
+
**提示词变量是这一版的重点**:0.2.1 的 `agent-loop` 只注册 `model` 与 `provider` 两个变量(`cwd` 已删,工作目录改由 `working-directory` 服务的 context 注入),而 `{{…}}` 严格解析、未注册即抛错。本 preset 的 patch 现在只引用 `{{model}}`——`grep -oE '\{\{[a-zA-Z_]+\}\}' <patch>` 的结果必须落在 `model` / `provider` 之内。
|
|
145
|
+
|
|
146
|
+
> **选择器里的会话形式**:0.2.0 的记录(官方 4 个 + 本包 11 个全部在列、order 第 6 位)仍然成立,本轮没有在浏览器里重跑选择器那一段。
|
|
147
|
+
|
|
126
148
|
### 适配实测记录(0.2.0-rc.2,2026-10-06)
|
|
127
149
|
|
|
128
150
|
隔离 `DSH_HOME`(复制 web profile 后 `pnpm install` 重建 `link:`)装本目录并 boot,无任何启动诊断;选择器按 order 列出:
|
|
@@ -136,6 +158,8 @@ node presets/plugin-upgrade-cordis/check-upstream.mjs
|
|
|
136
158
|
## 已知边界
|
|
137
159
|
|
|
138
160
|
- **上游技能正文按上游仓库根写**:`dsh-benchmark-case` 提到 `benchmark/tasks/`、`scripts/validate.mjs`,`plugin-release` / `plugin-test` 提到上游的 cohort 与快照目录。这些**不是本包内容**,本包只随 `skills/`——用到那些技能时按上游仓库(或用户自己的插件仓库)的实际布局走。上游的 `scripts/`、`benchmark/`、`paper/` 一律未收录。
|
|
161
|
+
- **抄本的基线会随 DSH 漂**:`plugin-upgrade-cordis.patch.yml` 抄自 0.2.1-alpha.3 的官方 `cordis`,官方每版都可能改它。升级 DSH 后要按新版官方文件重抄一遍(步骤见 [UPSTREAM.md](./UPSTREAM.md)「再抄官方 preset」)。抄本落后不会报错,只会静默地少几个插件行;**唯一会当场炸的是引用已被删掉的提示词变量**——那种情况下这一轮的请求会以 `unknown prompt variable` 失败,而 preset 照旧出现在选择器里。
|
|
162
|
+
- **`engines.dsh` 按 semver 管不到预发布版**:`>=0.2.1-alpha.3` 只容得下三位号完全相同的预发布版本;更旧的 `>=0.2.0-rc.2` 根本不收 `0.2.1-alpha.3`(预发布只在 `[major, minor, patch]` 全等时进范围)。所以这个字段是**声明与文档**,不是闸门——0.2.1 里强制的是 `peerDependencies`。
|
|
139
163
|
- **技能正文逐字复制、不做本地改写**:要改内容就改上游,再按 [UPSTREAM.md](./UPSTREAM.md) 重新同步,否则下次同步会把本地改动冲掉。`check-upstream.mjs --verify` 就是用来抓这种「本地被改过」的。
|
|
140
164
|
- **上游更新了要不要跟**:只看 `skills/` 下的变更——`node check-upstream.mjs` 说了算;上游的 `benchmark/` / `paper/` / CI 再热闹也与此无关。**卡缺口(见上「版本卡覆盖」)不是同步能解决的**,那种目标版本要用 `dsh-upgrade-audit` 自己产证据。
|
|
141
165
|
- 上游 `skills/README.md` 的收录清单与作者表保留在 `upstream/`,便于对照。
|
package/UPSTREAM.md
CHANGED
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
# 上游来源与再同步
|
|
2
2
|
|
|
3
|
-
本 preset
|
|
3
|
+
本 preset 有**两份外来内容**,来源与再同步方式各不相同:
|
|
4
|
+
|
|
5
|
+
1. `skills/` —— [oh-my-dsh/dsh-plugin-upgrade-skill](https://github.com/oh-my-dsh/dsh-plugin-upgrade-skill) 的**逐字复制**,见「来源」与「再同步步骤」;
|
|
6
|
+
2. `plugin-upgrade-cordis.patch.yml` —— DSH 官方 `@deepseek-ai/dsh-web-app/presets/cordis.patch.yml` 的**抄本**,见「再抄官方 preset」。
|
|
7
|
+
|
|
8
|
+
本文记来源、钉住的提交、哈希配方、同步步骤与判据;机器可读的那一份是 [upstream-lock.json](./upstream-lock.json),检查工具是 [check-upstream.mjs](./check-upstream.mjs)(只覆盖第 1 项,第 2 项靠版本对齐与 `--dump-config`)。
|
|
4
9
|
|
|
5
10
|
## 来源
|
|
6
11
|
|
|
@@ -73,6 +78,26 @@ node presets/$ID/check-upstream.mjs --verify
|
|
|
73
78
|
|
|
74
79
|
上游 `skills/README.md` 的表若增删了技能,本 preset 的 `README.md`「随包技能」表、`package.json` 的 `description`、`upstream-lock.json`(`--write` 自动)一起改;内容变了就把 `package.json` 的 `version` 加一位。
|
|
75
80
|
|
|
81
|
+
## 再抄官方 preset
|
|
82
|
+
|
|
83
|
+
`plugin-upgrade-cordis.patch.yml` 是官方 `presets/cordis.patch.yml` 的抄本,**抄的版本必须等于运行中的 DSH**。升级 DSH 后按下面重抄(本包只改三处,别多改):
|
|
84
|
+
|
|
85
|
+
```
|
|
86
|
+
BASE=<DSH 安装>/node_modules/.pnpm/@deepseek-ai+dsh-web-app@<版本>_*/node_modules/@deepseek-ai/dsh-web-app/presets/cordis.patch.yml
|
|
87
|
+
```
|
|
88
|
+
|
|
89
|
+
1. 把 `$BASE` 整份内容抄成 `plugin-upgrade-cordis.patch.yml`;
|
|
90
|
+
2. 只改三处:
|
|
91
|
+
- 顶部注释块(换成指向本 preset 与本文件);
|
|
92
|
+
- `- id: preset-cordis` → `- id: preset-plugin-upgrade-cordis`,`config.id` → `plugin-upgrade-cordis`,加 `config.name` / `config.description`,`config.order` → 台账值(见 [docs/rules/presets.md](../../docs/rules/presets.md)「order 台账」);
|
|
93
|
+
- `skill-filesystem` 行的 `customSkillDirs`:在官方那条**之前**插本包的根(`createRequire(baseUrl).resolve('@lynn123411/dsh-preset-plugin-upgrade-cordis/package.json')` + `join(dir, 'skills')`),并保留说明注释。**顺序即优先级**;
|
|
94
|
+
3. `diff -u "$BASE" plugin-upgrade-cordis.patch.yml` 复核:除上述三处外应当**没有别的差异**——这是唯一能证明「逐字保留」的检查;
|
|
95
|
+
4. 扫一遍提示词变量:`grep -oE '\{\{[a-zA-Z_]+\}\}' plugin-upgrade-cordis.patch.yml | sort -u`,结果必须落在该版 `agent-loop` 注册的变量里(0.2.1-alpha.3 只有 `model` 与 `provider`)。引用了不存在的变量 → 每次请求都抛 `unknown prompt variable`,而 preset 照样可选;
|
|
96
|
+
5. `--dump-config` exit 0,且组合树里出现 `preset-plugin-upgrade-cordis` 行;
|
|
97
|
+
6. 更新 `package.json` 的 `engines.dsh` 与 `version`(加一位),更新 README.md 的「与官方创造模式的异同」与实测记录。
|
|
98
|
+
|
|
99
|
+
`check-upstream.mjs` **不覆盖这一步**:它只管 `skills/`,与官方 preset 无关。
|
|
100
|
+
|
|
76
101
|
## 哈希配方
|
|
77
102
|
|
|
78
103
|
`upstream-lock.json` 里 `skills[name]` 是该技能目录的树哈希,`hash` 是整份收录集的集合哈希。规则固定、可复算:
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lynn123411/dsh-preset-plugin-upgrade-cordis",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.3",
|
|
4
4
|
"description": "插件升级创造模式:官方 cordis 组合(persona、工具矩阵、计划 / 压缩 / 子代理编排、动态插件工具)逐字保留,另并入 dsh-plugin-upgrade-skill 的 11 个插件工程技能(升级迁移、编写、测试、发布、运行时排障、整队巡检、重依赖接入、DSH 版本兼容审计、benchmark 考题提取、通用迁移方法、生命周期编排)。",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"exports": {
|
|
@@ -16,6 +16,9 @@
|
|
|
16
16
|
"UPSTREAM.md"
|
|
17
17
|
],
|
|
18
18
|
"license": "MIT",
|
|
19
|
+
"scripts": {
|
|
20
|
+
"check": "node check-upstream.mjs --verify"
|
|
21
|
+
},
|
|
19
22
|
"keywords": [
|
|
20
23
|
"deepseek-harness",
|
|
21
24
|
"dsh",
|
|
@@ -30,7 +33,7 @@
|
|
|
30
33
|
"directory": "presets/plugin-upgrade-cordis"
|
|
31
34
|
},
|
|
32
35
|
"engines": {
|
|
33
|
-
"dsh": ">=0.2.
|
|
36
|
+
"dsh": ">=0.2.1-alpha.3",
|
|
34
37
|
"node": "^22.19 || >=24"
|
|
35
38
|
},
|
|
36
39
|
"publishConfig": {
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
# Agent preset plugin-upgrade-cordis: the shipped `cordis` row copied verbatim
|
|
2
|
-
#
|
|
2
|
+
# from dsh 0.2.1-alpha.3 (`@deepseek-ai/dsh-web-app/presets/cordis.patch.yml`) —
|
|
3
|
+
# same persona, same tool matrix, same sub-agent/compaction groups — plus the
|
|
3
4
|
# 11 plugin-engineering skills vendored under ./skills/. See README.md.
|
|
4
5
|
- insert:
|
|
5
6
|
- id: preset-plugin-upgrade-cordis
|
|
@@ -15,13 +16,14 @@
|
|
|
15
16
|
- id: persona
|
|
16
17
|
name: '@deepseek-ai/dsh-persona'
|
|
17
18
|
config:
|
|
18
|
-
suffix: Your working directory is {{cwd}}.
|
|
19
19
|
prefix: >-
|
|
20
20
|
You are a coding agent powered by the {{model}} model.
|
|
21
21
|
- id: agent-instructions
|
|
22
22
|
name: '@deepseek-ai/dsh-agent-instructions'
|
|
23
23
|
config:
|
|
24
24
|
maxBytes: 65536
|
|
25
|
+
- id: time-context
|
|
26
|
+
name: '@deepseek-ai/dsh-time-context'
|
|
25
27
|
- id: tool-bash
|
|
26
28
|
name: '@deepseek-ai/dsh-tool-bash'
|
|
27
29
|
disabled: !!js process.platform === 'win32'
|
|
@@ -36,6 +38,8 @@
|
|
|
36
38
|
sampleOverCapGlobResults: false
|
|
37
39
|
- id: tool-jobs
|
|
38
40
|
name: '@deepseek-ai/dsh-tool-jobs'
|
|
41
|
+
- id: tool-schedule
|
|
42
|
+
name: '@deepseek-ai/dsh-tool-schedule'
|
|
39
43
|
- id: command-goal
|
|
40
44
|
name: '@deepseek-ai/dsh-command-goal'
|
|
41
45
|
- id: tool-goal
|
|
@@ -50,7 +54,7 @@
|
|
|
50
54
|
name: '@deepseek-ai/dsh-plan-mode'
|
|
51
55
|
config:
|
|
52
56
|
section: |
|
|
53
|
-
You are in plan mode. Stay in plan mode until
|
|
57
|
+
You are in plan mode. Stay in plan mode until the user approves your plan through exit_plan_mode or switches the session mode. Imperative language to implement changes means plan the implementation, not execute it. A user's conversational agreement — including an answer confirming something you asked — approves nothing and does not end plan mode; fold the confirmed decision into the plan and submit it through exit_plan_mode.
|
|
54
58
|
|
|
55
59
|
Explore first. Use non-mutating reads, searches, static analysis, and checks to ground the plan in the actual repository. Do not edit or write files, change configuration, run formatters or code generation that rewrites tracked files, commit, or otherwise carry out the plan. Prefer existing functions and patterns over new machinery.
|
|
56
60
|
|
|
@@ -94,41 +98,17 @@
|
|
|
94
98
|
provider: spawn
|
|
95
99
|
toolName: subagent
|
|
96
100
|
modelSelectionSettings: true
|
|
97
|
-
backgroundMode: continuable
|
|
98
101
|
- id: tool-subagent-fork
|
|
99
102
|
name: '@deepseek-ai/dsh-tool-subagent'
|
|
100
103
|
config:
|
|
101
104
|
provider: fork
|
|
102
105
|
toolName: subagent_fork
|
|
103
|
-
backgroundMode: continuable
|
|
104
|
-
- id: tool-subagent-codex
|
|
105
|
-
name: '@deepseek-ai/dsh-tool-subagent'
|
|
106
|
-
disabled: true
|
|
107
|
-
config:
|
|
108
|
-
provider: codex
|
|
109
|
-
toolName: subagent_codex
|
|
110
|
-
backgroundMode: one-shot
|
|
111
|
-
maxDepth: provider-managed
|
|
112
|
-
- id: tool-subagent-claude-code
|
|
113
|
-
name: '@deepseek-ai/dsh-tool-subagent'
|
|
114
|
-
disabled: true
|
|
115
|
-
config:
|
|
116
|
-
provider: claude-code
|
|
117
|
-
toolName: subagent_claude_code
|
|
118
|
-
backgroundMode: one-shot
|
|
119
|
-
maxDepth: provider-managed
|
|
120
106
|
- id: workflow-ptc
|
|
121
107
|
name: '@deepseek-ai/dsh-workflow-ptc'
|
|
122
108
|
config:
|
|
123
109
|
provider: spawn
|
|
124
110
|
- id: tool-workflow
|
|
125
111
|
name: '@deepseek-ai/dsh-tool-workflow'
|
|
126
|
-
- id: tool-ralph
|
|
127
|
-
name: '@deepseek-ai/dsh-tool-ralph'
|
|
128
|
-
disabled: true
|
|
129
|
-
config:
|
|
130
|
-
subagentProvider: spawn
|
|
131
|
-
maxRounds: 64
|
|
132
112
|
- id: tool-ask-user
|
|
133
113
|
name: '@deepseek-ai/dsh-tool-ask-user'
|
|
134
114
|
- id: tool-todo
|