dsh-vibe-math 1.4.1 → 2.0.0
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 +35 -102
- package/cordis.patch.yml +3 -3
- package/installer.js +25 -14
- package/package.json +5 -9
- package/vibe-math-v3//345/256/236/347/216/260/346/226/271/346/241/210.md +2 -2
- package/vibe-math-v1/agent.cordis.yml +0 -198
- package/vibe-math-v1/preset.yml +0 -2
- package/vibe-math-v1/vibe-math.js +0 -692
- package/vibe-math-v1//345/256/236/347/216/260/346/226/271/346/241/210-/345/244/232/344/273/243/347/220/206/346/225/260/345/255/246/351/227/256/351/242/230/346/261/202/350/247/243/344/270/216/351/252/214/350/257/201/346/241/206/346/236/266.md +0 -161
package/README.md
CHANGED
|
@@ -1,32 +1,25 @@
|
|
|
1
|
-
# Vibe Mathematics —
|
|
1
|
+
# Vibe Mathematics — 多代理数学问题求解与验证框架(三架构)
|
|
2
2
|
|
|
3
3
|
[](https://www.npmjs.com/package/dsh-vibe-math)
|
|
4
4
|
[](https://opensource.org/licenses/MIT)
|
|
5
5
|
[](https://github.com/ChongCyrus/Vibe-Mathematics)
|
|
6
6
|
|
|
7
|
-
> 运行在 **DeepSeek Harness** 内的一组 **agent preset**(`vibe-math-
|
|
8
|
-
>
|
|
9
|
-
>
|
|
7
|
+
> 运行在 **DeepSeek Harness** 内的一组 **agent preset**(`vibe-math-v2` / `vibe-math-v3` / `vibe-math-v4`),
|
|
8
|
+
> 用多代理协作自动求解数学问题并对结论做多代理交叉验证。三个预设共享「**断点续跑**、
|
|
9
|
+
> **中途人工干预**、**进度汇报**、**自然语言驱动**」底座能力,但采用三代不同的求解架构:
|
|
10
10
|
> **💡 `vibe-math-v2` 与 `vibe-math-v3` 同级主推**——两者都是成熟可用、正在维护的主推架构,根据你的实际需求自行选择(详见下方「怎么选」);`vibe-math-v4` 是最新的「常驻自组织合作研究」架构(实验性)。
|
|
11
11
|
>
|
|
12
|
-
> - **`vibe-math-v1`(经典流水线)⚠️ 将弃用**:「广度探索 → 深度迭代 → 交叉验证 → 知识沉淀」闭环;
|
|
13
12
|
> - **`vibe-math-v2`(概率驱动 · JSON 数据层)✅ 主推**:`qs.json` 问题清单 + `Propos/` 命题库 + 概率驱动调度 + 代码启发式调度;
|
|
14
13
|
> - **`vibe-math-v3`(第三代 · 论文式 md + 规划代理 + 方法库)✅ 主推**:全部知识以 **Markdown 论文/研究报告式** 存储与续写(`Problems/` 问题清单+依赖+来源动机、`Progress/` 研究日志、`Propos/` 命题库、`Methods/` 通用理论发明库、`Verified/` 绝对可信);调度前由**规划代理**自主制定接下来 N 步计划;解决过程中发明的理论/框架/工具/方法/思想由 **Method Keeper** 沉淀为可复用方法体系(如发明群论、泛函分析那样)。
|
|
15
14
|
> - **`vibe-math-v4`(第四代 · 常驻自组织合作研究)🧪 实验性**:一组**持久化常驻子代理**互相**留言 + 开会**,自主决定一切任务安排(无中央调度);各自沉淀进度/命题/方法/子问题库并互相查阅;验证**仅当全体常驻一致(真 或 假)**才写入 `Verified/`,否则留库附概率;上下文达阈值自动 `/compact`;仅当全体一致认为原问题已解决才停止。
|
|
16
15
|
|
|
17
|
-
安装本插件包(或手动复制预设)后,DSH
|
|
16
|
+
安装本插件包(或手动复制预设)后,DSH 的预设选择器里会出现**三个** agent preset。
|
|
18
17
|
|
|
19
18
|
---
|
|
20
19
|
|
|
21
|
-
## 🧩 架构图(
|
|
20
|
+
## 🧩 架构图(v2 + v3 + v4)
|
|
22
21
|
|
|
23
|
-
> 静态架构图;完整流程说明见 [docs/架构图.md](docs/架构图.md);可编辑生成脚本:[
|
|
24
|
-
|
|
25
|
-
### Vibe Math V1(经典流水线)⚠️ 早期架构 · 将弃用 · 不建议新项目使用
|
|
26
|
-
|
|
27
|
-

|
|
28
|
-
|
|
29
|
-
**一句话流水线**:`qs.csv` → Brainstorm 拆方向 → 每方向一个 Solver 多轮迭代(卡死则 Derive 派生新方向)→ 输出拆成最小验证单元 → ≥3 个 Verifier 独立审查 → 辩论 → 裁决 → 通过晋升 `Verified/` → Decider 回写 `qs.csv`;全程状态落盘 `VibeMath_State/`,`resume` 断点续跑,`manual` 模式在派发/裁决/晋升处挂起人工决策。
|
|
22
|
+
> 静态架构图;完整流程说明见 [docs/架构图.md](docs/架构图.md);可编辑生成脚本:[v2](docs/generate_framework_diagram_v2.py) / [v3](docs/generate_framework_diagram_v3.py) / [v4](docs/generate_framework_diagram_v4.py)。
|
|
30
23
|
|
|
31
24
|
### Vibe Math V2(概率驱动 · JSON 数据层)✅ 主推
|
|
32
25
|
|
|
@@ -72,7 +65,7 @@
|
|
|
72
65
|
|
|
73
66
|
## ✨ 功能特色
|
|
74
67
|
|
|
75
|
-
- **多代理自动求解**:主代理把问题交给调度器,调度器派发 explorer / solver / verifier(
|
|
68
|
+
- **多代理自动求解**:主代理把问题交给调度器,调度器派发 explorer / solver / verifier(v2/v3)与 **planner(规划代理,v3)**、**method-keeper(方法整理代理,v3)** 等子代理协同求解,**你无需逐节点手操**。
|
|
76
69
|
- **多代理交叉验证**:每个结论交给 ≥3 个「严苛审稿人」**独立审查 → 辩论(交流群)→ 裁决**(v3 默认**近共识裁决**:同侧且均值 ≥0.85/≤0.15 取均值,避免"0.9 vs 1"被误判成 0.5)。
|
|
77
70
|
- **论文式 Markdown 知识库(v3)**:问题清单(含问题间依赖、后生问题产生原因与计划)、研究日志、命题、方法库全部以 md 论文/研究报告式书写与续写(方向重派生时旧方向的日志自动归档保留);**只有 `Verified/` 与验证器判真/假的对象绝对可信**,其余 md(含方法库未验证断言)仅作经验参考。
|
|
78
71
|
- **通用理论发明库(v3)**:解决过程中发明的理论体系/框架/工具/方法/思想(含经验性总结)经 `methods_used`/`new_inventions` 上报,由 **Method Keeper** 沉淀为 `Methods/` 方法卡(可组成体系层级、跨项目复用),像"解决方程时发明群论"一样形成系统化方法理论体系。
|
|
@@ -100,8 +93,8 @@ dsh plugin --profile <你的 profile> add dsh-vibe-math
|
|
|
100
93
|
dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
101
94
|
```
|
|
102
95
|
|
|
103
|
-
安装时插件会自动把三个 preset 写入 `~/.dsh/.agent-presets/`:`vibe-math-
|
|
104
|
-
之后新建会话,预设选择器里选择 **Vibe Math V3**(v3,**主推**)、**Vibe Math V2**(v2,**主推**)或 **Vibe Math**(
|
|
96
|
+
安装时插件会自动把三个 preset 写入 `~/.dsh/.agent-presets/`:`vibe-math-v2/`、`vibe-math-v3/` 与 `vibe-math-v4/`。
|
|
97
|
+
之后新建会话,预设选择器里选择 **Vibe Math V3**(v3,**主推**)、**Vibe Math V2**(v2,**主推**)或 **Vibe Math V4**(v4,常驻自组织)即可——v2 与 v3 同级主推,按实际需求自选(见「怎么选」)。
|
|
105
98
|
**升级包版本后重启 DSH,未手动改过的 preset 文件会自动更新到新版本**(细节见文末「v2/v3」安装器说明)。
|
|
106
99
|
|
|
107
100
|
### 方式 B:作为 agent preset 手动安装
|
|
@@ -109,12 +102,12 @@ dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
|
109
102
|
1. 把本仓库对应目录的文件复制到 preset 目录:
|
|
110
103
|
|
|
111
104
|
```
|
|
112
|
-
C:\Users\<你>\.dsh\.agent-presets\vibe-math-v1\ ← 复制 vibe-math-v1/ 下的 agent.cordis.yml / preset.yml / vibe-math.js
|
|
113
105
|
C:\Users\<你>\.dsh\.agent-presets\vibe-math-v2\ ← 复制 vibe-math-v2/ 下的 agent.cordis.yml / preset.yml / vibe-math-v2.js
|
|
114
106
|
C:\Users\<你>\.dsh\.agent-presets\vibe-math-v3\ ← 复制 vibe-math-v3/ 下的 agent.cordis.yml / preset.yml / vibe-math-v3.js
|
|
107
|
+
C:\Users\<你>\.dsh\.agent-presets\vibe-math-v4\ ← 复制 vibe-math-v4/ 下的 agent.cordis.yml / preset.yml / vibe-math-v4.js
|
|
115
108
|
```
|
|
116
109
|
|
|
117
|
-
2. 新建一个会话,在 preset 选择器里选 **「Vibe Math」** / **「Vibe Math
|
|
110
|
+
2. 新建一个会话,在 preset 选择器里选 **「Vibe Math V2」** / **「Vibe Math V3」** / **「Vibe Math V4」**。
|
|
118
111
|
3. 会话启动后即可使用:工具列表里会出现 `vibe_math_*` 工具,输入框键入 `/vibe` 有自动补全。
|
|
119
112
|
|
|
120
113
|
> 修改 preset 文件后需**重启 DSH 进程**再开新会话(preset 的 standing mount 会缓存到进程退出)。
|
|
@@ -123,8 +116,8 @@ dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
|
123
116
|
|
|
124
117
|
- **形态依赖**:三个 preset 依赖 DSH 的标准 **agent-preset 机制**(`~/.dsh/.agent-presets/<id>/` + preset picker)与 **bundle patch 机制**(`cordis.patch.yml` 注入安装器)。
|
|
125
118
|
- **宿主插件行**:`agent.cordis.yml` 引用宿主提供的 `@deepseek-ai/dsh-*` 插件行(persona、agent-instructions、tool-bash/pwsh、tool-fs/fs-search、tool-jobs、skill-filesystem、tool-skill、tool-goal、plan-mode、compaction、subagent/workflow、ask-user、todo、web 等,约 21 个唯一包名)。宿主缺行会导致 preset 挂载失败(会话启动时报错)。
|
|
126
|
-
- **宿主服务 API**:预设插件消费 `subagents`(startContinuable / followup / interrupt)、`agents`(roots)、`tools`(register)、`commands`(register)、`fs`(resolve/stat/readText/writeText/listDir)、可选 `subprocess` / `sandboxPolicy`。这些 API 形状随 DSH 版本演进;本项目**已充分测试并确认适配 `dsh-v0.1.
|
|
127
|
-
- **运行时自检**:安装器(bundle 插件)每次启动时对上述服务与关键 API 做**能力自检**(DSH 不暴露版本号,故按能力而非版本检测;含 `fs.resolve`
|
|
119
|
+
- **宿主服务 API**:预设插件消费 `subagents`(startContinuable / followup / interrupt)、`agents`(roots)、`tools`(register)、`commands`(register)、`fs`(resolve/stat/readText/writeText/listDir)、可选 `subprocess` / `sandboxPolicy`。这些 API 形状随 DSH 版本演进;本项目**已充分测试并确认适配 `dsh-v0.1.2-rc.1`**(`package.json` 的 `dsh.testedVersion`;`minVersion` 为 `0.1.2-rc.1`)。**注意:DSH 0.1.2 起 `subagents.startContinuable` 的 `agentOptions` / `toolFilter` 需要宿主 provider 声明对应 capability**(spawn / fork 进程内 provider 均支持,v4 指定常驻模型/路由与工具权限依赖于此)。
|
|
120
|
+
- **运行时自检**:安装器(bundle 插件)每次启动时对上述服务与关键 API 做**能力自检**(DSH 不暴露版本号,故按能力而非版本检测;含 `fs.resolve` 返回形状检测与 subagent `agentOptions`/`toolFilter` capability 检测);不满足时打 warning 并提示升级 DSH。preset 挂载失败时先看 DSH 日志里的自检 warning。
|
|
128
121
|
- **升级路径**:DSH 升级后无需重装本包;升级本包用 `dsh plugin update dsh-vibe-math`,重启 DSH 后安装器会自动把 preset 更新到新版本(见上文「安装」说明)。
|
|
129
122
|
|
|
130
123
|
---
|
|
@@ -145,39 +138,21 @@ dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
|
145
138
|
>
|
|
146
139
|
> 两者都成熟可用、持续维护,且都支持断点续跑、人工/自动干预、进度汇报、多会话隔离、命题晋升、近共识/加权裁决等核心能力;切换成本低(同一套 `vibe_math_*` 工具与 `/vibe` 命令、同一套参数体系)。
|
|
147
140
|
>
|
|
148
|
-
> **⚠️ `vibe-math-
|
|
149
|
-
|
|
150
|
-
| | **
|
|
151
|
-
|
|
152
|
-
| 定位 |
|
|
153
|
-
| 核心思想 |
|
|
154
|
-
| 数据 | `qs/qs.
|
|
155
|
-
| 角色 |
|
|
156
|
-
| 调度方式 |
|
|
157
|
-
| 收口规则 |
|
|
158
|
-
| 停止 | 全解或卡死 |
|
|
159
|
-
| 上下文 | 无 | 无 |
|
|
160
|
-
| 特设能力 |
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
---
|
|
165
|
-
|
|
166
|
-
## 🧠 架构与分工(v1 · 经典)⚠️ 早期架构 · 将弃用 · 不建议新项目使用
|
|
167
|
-
|
|
168
|
-
框架 = **一个主代理(助手)+ 一个代码调度器 + 五类子代理**。
|
|
169
|
-
|
|
170
|
-
| 角色 | 类型 | 职责 |
|
|
171
|
-
|---|---|---|
|
|
172
|
-
| **主代理** | LLM(会话里的那个助手) | **自然语言接口 + 汇报者 + 助手**。它**自己不求解、不调度**,只负责:把你的话翻译成 `vibe_math_*` 工具调用、汇报进展、问答式配置参数、执行调控命令。 |
|
|
173
|
-
| **调度器** | 插件代码(非模型) | 唯一主控:读 `qs.csv`、派发子代理、写文件、推进状态机。**所有调度靠编程,不靠代理**。 |
|
|
174
|
-
| **Brainstorm 子代理** | 子代理 | 元认知头脑风暴:约束分解、边界测试、相似问题映射,把问题拆成多个「大相径庭」的求解方向。 |
|
|
175
|
-
| **Solver 子代理** | 子代理 | 每个方向一个专属求解器,**同一会话内多轮迭代**,产出引理(含证明)、子路线、存活概率、完整解法。 |
|
|
176
|
-
| **Derive 子代理** | 子代理 | 当某问题的所有方向都走进死路仍未解决时,基于历史痛点**派生 1~3 个全新方向**。 |
|
|
177
|
-
| **Verifier 子代理** | 子代理 | 每个验证单元 ≥3 个独立「严苛审稿人」,独立审查 → 辩论(交流群)→ 裁决。 |
|
|
178
|
-
| **Decider 子代理** | 子代理 | `Verified/` 出现新结论时,判断它是否解决了某未解决问题,回写 `qs.csv` 并重命名解法文件。 |
|
|
179
|
-
|
|
180
|
-
> 一句话分工:**主代理负责“和人对话”,调度器负责“干活”,子代理负责“动脑”。**
|
|
141
|
+
> **⚠️ `vibe-math-v2` 与 `vibe-math-v3` 是成熟主推架构;`vibe-math-v4` 是实验性的常驻自组织架构,** 均可选择;老 `vibe-math-v1` 已被移除(本包仅含 v2/v3/v4)。
|
|
142
|
+
|
|
143
|
+
| | **v2(概率驱动 · 主推)** | **v3(论文式 md · 主推)** | **v4(常驻自组织 · 实验)** |
|
|
144
|
+
|---|---|---|---|
|
|
145
|
+
| 定位 | **主推**(JSON 数据层) | **主推**(第三代) | **实验性**(第四代) |
|
|
146
|
+
| 核心思想 | 概率驱动:`qs.json` 问题 + `Propos/` 命题库,按「正确概率 / 价值」调度 | **论文式 md 知识库 + 规划代理调度 + 通用理论发明库** | **持久化常驻子代理自组织**:互相留言 + 开会决定一切任务,无中央调度 |
|
|
147
|
+
| 数据 | `qs/qs.json` + `Propos/<分类>_Propos.json` + `Reliable/` | `Problems/` + `Progress/` + `Propos/` + `Methods/`(全部 md,软规范锚点 + 自由叙述)+ `Verified/` | `Problems/` + **按常驻 id 归属**的 `Progress|Propos|Methods|Subproblems/<id>/` + `Shared/`(会议/任务板/辩论)+ `Verified/` |
|
|
148
|
+
| 角色 | explorer → 逐方向 solver → verifier | **planner(规划代理)** → explorer → 逐方向 solver → verifier → **method-keeper(方法整理代理)** | **N 个常驻研究者**(continuable),由它们互相通信/开会分工,无固定角色 |
|
|
149
|
+
| 调度方式 | 代码启发式(优先级 + 概率) | **规划代理产出 N 步计划**(校验后执行,失败回退启发式) | **无中央调度**:任务由常驻互相留言/开会(框架只做媒介,不指派) |
|
|
150
|
+
| 收口规则 | 解法/证明达概率 `1` 即收口,`never` 永不调度 | 同 v2(近共识裁决修复 flat 误判) | **仅当全体常驻一致(真 或 假)**才写入 `Verified/`,否则留库附概率 |
|
|
151
|
+
| 停止 | 全解或卡死 | 全解/无候选 | **仅当全体常驻一致认为原问题已解决**才停止 |
|
|
152
|
+
| 上下文 | 无 | 无 | **常驻上下文达阈值自动 `/compact`**(可调) |
|
|
153
|
+
| 特设能力 | 命题「价值/关键性」自动晋升问题清单;`reportMode file/push/both`;`priorityAdjust` | **方法库沉淀循环**(`methods_used`/`new_inventions` → Method Keeper);**计划审批门/方法晋升门**;**项目锁**;后生问题「来源与动机」一等公民 | **常驻各自沉淀 + 互相阅读**;**全体一致验证**;**随时增开/关闭常驻、留言干预**;**断点续跑** |
|
|
154
|
+
|
|
155
|
+
三者都支持:断点续跑(`vibe_math_resume` / `vibe_v4_resume`)、人工/自动模式切换、`vibe_math_*` / `vibe_v4_*` 工具集与 `/vibe` `/v4` 命令、按项目隔离、子代理权限调控。**v2 与 v3 均为同级主推**——偏好结构化 JSON 数据与确定性调度选 v2,偏好论文式 md、规划代理与理论发明库选 v3;v4 是最新的「常驻自组织合作研究」实验架构。
|
|
181
156
|
|
|
182
157
|
---
|
|
183
158
|
|
|
@@ -202,24 +177,6 @@ dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
|
202
177
|
|
|
203
178
|
## 📁 目录结构
|
|
204
179
|
|
|
205
|
-
### v1(经典)
|
|
206
|
-
|
|
207
|
-
```
|
|
208
|
-
<会话工作区>/VibeMath/
|
|
209
|
-
├─ current.json # 当前项目
|
|
210
|
-
├─ vibe_math_setting.json # (可选,全局回退)默认参数 JSONC,含注释
|
|
211
|
-
└─ Projects/<项目>/
|
|
212
|
-
├─ vibe_math_setting.json # 该项目默认参数
|
|
213
|
-
├─ qs/qs.csv # 问题清单:id,description,priority,status,deps
|
|
214
|
-
├─ Verified/ # 已验证可信知识库(绝对可信)
|
|
215
|
-
├─ Pending_Verification/ # 待验证原始输出
|
|
216
|
-
├─ Under_Verification/ # 拆解后的最小验证单元
|
|
217
|
-
├─ Temp/ # 临时工作区
|
|
218
|
-
├─ Temp_Validated/ # 已验证、待晋升
|
|
219
|
-
├─ Progress_Logs/ # 每问题进度 + 辩论日志 + 定期报告
|
|
220
|
-
└─ VibeMath_State/ # 调度器私有持久状态(断点恢复用)
|
|
221
|
-
```
|
|
222
|
-
|
|
223
180
|
### v2(概率驱动 · 主推)
|
|
224
181
|
|
|
225
182
|
```
|
|
@@ -262,7 +219,7 @@ dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
|
262
219
|
└─ State/ # 调度器私有持久状态(agents/tasks/plans/verifier_accuracy/index/项目锁/进程纪元)
|
|
263
220
|
```
|
|
264
221
|
|
|
265
|
-
**铁律(
|
|
222
|
+
**铁律(v2 通用)**:调度器是**唯一文件写者**(子代理只返回结构化 JSON,从不写文件)。
|
|
266
223
|
**v3 铁律**:只有 `Verified/` 与验证器判真/假的对象**绝对可信**;其余 md(未定论命题、研究日志、方法库未验证断言)仅作经验参考;调度器只解析软规范锚点行与条目标题行,从不解析正文散文。**v3 支持代理直接写 md**(自组织定位各自归属文件,如求解器写 `Progress/<id>/<方向id>.md`、新引理写 `Propos/<分类>/<id>.md`、方法整理代理写 `Methods/<id>.md`);并发安全靠**写锁**——写任何文件前调 `vibe_math_claim_write`、写完 `vibe_math_release_write`(同一文件同一时刻只允许一个代理写),内容留在 md,轻量元数据经 `vibe_math_sync_meta` 上报给调度器。
|
|
267
224
|
|
|
268
225
|
---
|
|
@@ -419,25 +376,6 @@ dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
|
419
376
|
|
|
420
377
|
## ⚙️ 参数速查表
|
|
421
378
|
|
|
422
|
-
### v1(经典)默认值
|
|
423
|
-
|
|
424
|
-
| 参数 | 默认 | 说明 |
|
|
425
|
-
|---|---|---|
|
|
426
|
-
| `mode` | `auto` | `auto` / `manual` |
|
|
427
|
-
| `maxParallelThreshold` | 4 | 全局最大并发子代理数 |
|
|
428
|
-
| `solverMaxRounds` | 20 | 每个求解方向最大迭代轮数 |
|
|
429
|
-
| `verifierCount` | 3 | 每验证单元独立验证器数(≥3) |
|
|
430
|
-
| `debateMaxRounds` | 5 | 验证辩论最大轮数 |
|
|
431
|
-
| `verdictMode` | `direct-veto` | `direct-veto` / `weighted-vote` |
|
|
432
|
-
| `provider` / `model` | 空 | 子代理模型(空 = 继承根代理) |
|
|
433
|
-
| `solverPersona` / `verifierPersona` | 空 | 注入求解器/验证器的额外要求 |
|
|
434
|
-
| `solverToolAllow` / `solverToolDeny` | `[]` | 求解器允许/禁止的工具(硬性 toolFilter) |
|
|
435
|
-
| `verifierToolAllow` / `verifierToolDeny` | `[]` | 验证器允许/禁止的工具 |
|
|
436
|
-
| `solverMaxToolCalls` / `verifierMaxToolCalls` | 0 | 每轮外部工具调用上限(0=不限,软性) |
|
|
437
|
-
| `reportIntervalMs` | 0 | 0 = 仅事件驱动(有代理状态更新等事件才写报告);>0 = 定时自动写(毫秒) |
|
|
438
|
-
| `tickIntervalMs` | 2000 | 调度器心跳间隔(毫秒) |
|
|
439
|
-
| `activityLogCap` | 100 | 活动日志保留条数(report 最多显示 30 条) |
|
|
440
|
-
|
|
441
379
|
### v2(概率驱动 · 主推)默认值
|
|
442
380
|
|
|
443
381
|
| 参数 | 默认 | 说明 |
|
|
@@ -507,29 +445,24 @@ dsh plugin --profile <你的 profile> add github:ChongCyrus/Vibe-Mathematics
|
|
|
507
445
|
|
|
508
446
|
## 📝 断点续跑 & 人工干预(两大硬性需求)
|
|
509
447
|
|
|
510
|
-
- **断点续跑**:所有状态落盘(
|
|
511
|
-
- **中途人工干预**:`manual` 模式在关键节点挂起决策(
|
|
512
|
-
- **进度汇报**:默认**事件驱动** —— 只有代理状态更新等事件发生时才会写报告(
|
|
448
|
+
- **断点续跑**:所有状态落盘(v2:`VibeMath_State/*.json`;v3:`State/*.json`),每个子代理都是 DSH 的 **continuable 持久会话**(对话由 DSH 自动保存)。重启后新开会话 → `vibe_math_resume` 即可续跑。v2/v3 额外用**进程纪元**区分"同进程暂停→恢复"(保留存活子代理继续)与"跨进程重启"(清理陈旧任务)。**v3 的 md 知识库本身就是叙事断点**——代理 resume 时从研究日志/问题卡/命题卡尾部续写。
|
|
449
|
+
- **中途人工干预**:`manual` 模式在关键节点挂起决策(v2:explorer/solver 派发、验证裁决;v3:**计划审批门**(规划代理产出计划后等你 approve/reject)、验证裁决门、**方法晋升门**(项目方法 → 全局库));可随时 `set_mode auto` 切回自动(自动放行所有挂起决策);可对任意子代理 `message_agent` / `interrupt_agent`。
|
|
450
|
+
- **进度汇报**:默认**事件驱动** —— 只有代理状态更新等事件发生时才会写报告(v2:`Progress_Logs/report.json`;v3:`Progress_Logs/report.json` + `Logs/报告.md` 论文式人读摘要;`reportMode` 可 `file`/`push`/`both`,`push` 通过 `rootAgent.followup()` 唤醒主代理主动汇报);只有把 `reportIntervalMs` 设为 >0 才启动定时自动汇报(间隔毫秒)。
|
|
513
451
|
|
|
514
452
|
---
|
|
515
453
|
|
|
516
454
|
## 📚 规格文档
|
|
517
455
|
|
|
518
|
-
- **v1(经典)**:[`vibe-math-v1/实现方案-多代理数学问题求解与验证框架.md`](vibe-math-v1/实现方案-多代理数学问题求解与验证框架.md)
|
|
519
456
|
- **v2(概率驱动)**:[`vibe-math-v2/实现方案.md`](vibe-math-v2/实现方案.md)
|
|
520
457
|
- **v3(论文式 md + 规划代理 + 方法库)**:[`vibe-math-v3/实现方案.md`](vibe-math-v3/实现方案.md)
|
|
458
|
+
- **v4(常驻自组织)**:[`vibe-math-v4/实现方案.md`](vibe-math-v4/实现方案.md)
|
|
521
459
|
|
|
522
460
|
---
|
|
523
461
|
|
|
524
462
|
## ⚠️ 已知边界(有意简化)
|
|
525
463
|
|
|
526
|
-
**v1**:
|
|
527
|
-
- `Pending_Verification` 按文件逐个拆解,未做跨文件的“去重 / 引用整合”(不损正确性)。
|
|
528
|
-
- `weighted-vote` 会记录每个验证器的历史准确率 + 严谨性权重,但最终裁决仍遵循“证伪优先 / 全 Uncertain→False”(数值权重仅用于审计)。
|
|
529
|
-
- manual 模式在第一个未决关键节点暂停整条主循环。
|
|
530
|
-
|
|
531
464
|
**v2**:
|
|
532
|
-
- 安装器带**版本化自动更新**:每次 DSH 启动时对比包版本与 `<presetRoot>/.vibe-math-installed.json` 记录——版本升级会自动替换**未被手动修改**的 preset 文件(哈希一致才覆盖);你改过的文件会被保留并在日志中提示。无记录的老安装首次会一次性刷新到当前版本。想强制全量重装:删除 `~/.dsh/.agent-presets/vibe-math-
|
|
465
|
+
- 安装器带**版本化自动更新**:每次 DSH 启动时对比包版本与 `<presetRoot>/.vibe-math-installed.json` 记录——版本升级会自动替换**未被手动修改**的 preset 文件(哈希一致才覆盖);你改过的文件会被保留并在日志中提示。无记录的老安装首次会一次性刷新到当前版本。想强制全量重装:删除 `~/.dsh/.agent-presets/vibe-math-v2`、`vibe-math-v3` 与 `vibe-math-v4` 目录后重启 DSH。
|
|
533
466
|
- `flat` 裁决在辩论不一致时直接判 `0.5`(高置信分歧如 0.9 vs 1 也会被误判 0.5——**v3 已用近共识规则修复**);`forced` 按历史准确率+置信度加权。
|
|
534
467
|
- `never` 优先级的问题/命题**永不调度**,且不阻塞严格终止(视为主动弃权)。
|
|
535
468
|
- 三个 preset 文件互相独立、可共存;同一会话同时只能选一个预设。
|
package/cordis.patch.yml
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
# The dsh-vibe-math merged bundle patch. Installing this bundle (dsh plugin add
|
|
2
2
|
# dsh-vibe-math / dsh-market) runs ONE plugin row: the preset installer, which
|
|
3
|
-
# copies
|
|
4
|
-
# root. The presets themselves register the vibe_math_* tools — nothing
|
|
5
|
-
# injected into the profile composition directly.
|
|
3
|
+
# copies the agent presets (vibe-math-v2 + vibe-math-v3 + vibe-math-v4) into the
|
|
4
|
+
# DSH preset root. The presets themselves register the vibe_math_* tools — nothing
|
|
5
|
+
# is injected into the profile composition directly.
|
|
6
6
|
|
|
7
7
|
- insert:
|
|
8
8
|
- id: vibe-math-preset-installer
|
package/installer.js
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
1
1
|
// dsh-vibe-math merged bundle installer — VERSIONED AUTO-UPDATE.
|
|
2
2
|
// When this bundle is installed (e.g. `dsh plugin add dsh-vibe-math` or from the
|
|
3
|
-
// dsh-market), this plugin copies ALL
|
|
4
|
-
// the DSH preset root, so the user immediately gets
|
|
5
|
-
// vibe-math-v1/ (classic pipeline architecture)
|
|
3
|
+
// dsh-market), this plugin copies ALL THREE agent presets out of the package into
|
|
4
|
+
// the DSH preset root, so the user immediately gets three presets in the picker:
|
|
6
5
|
// vibe-math-v2/ (probability-driven architecture)
|
|
7
6
|
// vibe-math-v3/ (THIRD-generation: paper-style Markdown knowledge base +
|
|
8
7
|
// planner-agent scheduling + universal theory/method library)
|
|
9
8
|
// vibe-math-v4/ (FOURTH-generation: persistent self-organizing resident
|
|
10
9
|
// subagents — message bus / meetings / unanimous-consensus
|
|
11
|
-
// verification / per-resident libraries)
|
|
10
|
+
// verification / per-resident libraries)
|
|
11
|
+
//
|
|
12
|
+
// (vibe-math-v1 — the classic pipeline — was removed at v2.0.0; this bundle now
|
|
13
|
+
// ships v2/v3/v4 only.)
|
|
12
14
|
//
|
|
13
15
|
// UPDATE POLICY (state recorded in <presetRoot>/.vibe-math-installed.json):
|
|
14
16
|
// - baseline (no state file — e.g. upgrading from an installer that predates
|
|
@@ -31,11 +33,6 @@ import { fileURLToPath } from 'node:url'
|
|
|
31
33
|
export const name = 'vibe-math-preset-installer'
|
|
32
34
|
|
|
33
35
|
const PRESETS = [
|
|
34
|
-
{
|
|
35
|
-
src: 'vibe-math-v1',
|
|
36
|
-
dst: 'vibe-math-v1',
|
|
37
|
-
files: ['agent.cordis.yml', 'preset.yml', 'vibe-math.js', '实现方案-多代理数学问题求解与验证框架.md'],
|
|
38
|
-
},
|
|
39
36
|
{
|
|
40
37
|
src: 'vibe-math-v2',
|
|
41
38
|
dst: 'vibe-math-v2',
|
|
@@ -77,8 +74,7 @@ function writeState(path, state) {
|
|
|
77
74
|
}
|
|
78
75
|
|
|
79
76
|
// DSH 适配性自检(能力检测,而非版本号——DSH 不向插件暴露版本)。
|
|
80
|
-
//
|
|
81
|
-
// 缺失时打 warning 提示宿主版本可能过旧 / 缺少对应插件行。
|
|
77
|
+
// 检查 preset 运行时需要的宿主服务与关键 API 形状是否可用,缺失时打 warning。
|
|
82
78
|
async function checkHostCapabilities(ctx, logger) {
|
|
83
79
|
const problems = []
|
|
84
80
|
const checks = [
|
|
@@ -104,14 +100,29 @@ async function checkHostCapabilities(ctx, logger) {
|
|
|
104
100
|
if (f && typeof f.resolve === 'function') {
|
|
105
101
|
const r = await f.resolve('x', { cwd: process.cwd() })
|
|
106
102
|
if (typeof r !== 'object' || r === null || typeof r.targetKey !== 'string') {
|
|
107
|
-
problems.push('fs.resolve 返回形状不符(期望 {targetKey, displayPath},v3 预设要求 DSH ≥ 0.1.1)')
|
|
103
|
+
problems.push('fs.resolve 返回形状不符(期望 {targetKey, displayPath},v3/v4 预设要求 DSH ≥ 0.1.1)')
|
|
108
104
|
}
|
|
109
105
|
}
|
|
110
106
|
} catch (e) { problems.push('fs.resolve 能力检测失败:' + String((e && e.message) || e)) }
|
|
107
|
+
// v4 依赖 subagents.startContinuable 的 agentOptions / toolFilter 能力(DSH 0.1.2 起由
|
|
108
|
+
// dsh-subagent 声明 SubagentCapabilities.agentOptions;spawn/fork 进程内 provider 均支持。
|
|
109
|
+
// 缺省 provider 名按 spawn 探测;探测失败不视为致命(等价于回退到再试一次、只警告)。
|
|
110
|
+
try {
|
|
111
|
+
const sa = (ctx && ctx.get) ? ctx.get('subagents') : undefined
|
|
112
|
+
if (sa && typeof sa.list === 'function') {
|
|
113
|
+
const names = (sa.list ? sa.list() : [])
|
|
114
|
+
const name = names.indexOf('spawn') !== -1 ? 'spawn' : (names[0] || '')
|
|
115
|
+
if (name && typeof sa.getProvider === 'function') {
|
|
116
|
+
const cap = (sa.getProvider(name) || {}).capabilities
|
|
117
|
+
if (cap && cap.agentOptions === false) problems.push('subagents provider "' + name + '" 不支持 agentOptions(v4 指定常驻模型/路由需要)')
|
|
118
|
+
if (cap && cap.toolFilter === false) problems.push('subagents provider "' + name + '" 不支持 toolFilter(v4 常驻工具权限需要)')
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
} catch (e) { /* 探测失败不致命 */ }
|
|
111
122
|
if (problems.length > 0) {
|
|
112
|
-
logger?.warn?.('[dsh-vibe-math] 宿主能力自检:' + problems.length + ' 项不满足(' + problems.join(';') + '
|
|
123
|
+
logger?.warn?.('[dsh-vibe-math] 宿主能力自检:' + problems.length + ' 项不满足(' + problems.join(';') + ')。v2/v3/v4 预设依赖这些宿主服务/API,旧版 DSH 可能无法挂载,建议升级 DSH(本项目已充分测试并确认适配 dsh-v0.1.2-rc.1,见 package.json 的 dsh.minVersion/testedVersion)。')
|
|
113
124
|
} else {
|
|
114
|
-
logger?.info?.('[dsh-vibe-math] 宿主能力自检通过:subagents / agents / tools / commands / fs 服务及关键 API 均可用(已确认适配 DSH 0.1.
|
|
125
|
+
logger?.info?.('[dsh-vibe-math] 宿主能力自检通过:subagents / agents / tools / commands / fs 服务及关键 API 均可用(已确认适配 DSH 0.1.2-rc.1)。')
|
|
115
126
|
}
|
|
116
127
|
}
|
|
117
128
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-vibe-math",
|
|
3
|
-
"description": "Multi-agent mathematical problem-solving & verification frameworks for DeepSeek Harness —
|
|
4
|
-
"version": "
|
|
3
|
+
"description": "Multi-agent mathematical problem-solving & verification frameworks for DeepSeek Harness — THREE agent presets in one install: vibe-math-v2 (probability-driven: qs.json + Propos knowledge base + explorer→solver→review/debate verdict), vibe-math-v3 (THIRD-generation, recommended: paper-style Markdown knowledge base with Problems/Progress/Propos/Methods/Verified + planner-agent scheduling that decides the next N actions + universal theory/method invention library + agents write their own Markdown directly via a per-file write lock), and vibe-math-v4 (FOURTH-generation: persistent self-organizing resident subagents that message & meet to decide all tasks, verify only by unanimous consensus, /compact at a context threshold, and stop only when all agree the problem is solved). Installing this bundle auto-installs all three presets (v1 was removed at v2.0.0).",
|
|
4
|
+
"version": "2.0.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "installer.js",
|
|
7
7
|
"exports": {
|
|
@@ -12,10 +12,6 @@
|
|
|
12
12
|
"files": [
|
|
13
13
|
"installer.js",
|
|
14
14
|
"cordis.patch.yml",
|
|
15
|
-
"vibe-math-v1/agent.cordis.yml",
|
|
16
|
-
"vibe-math-v1/preset.yml",
|
|
17
|
-
"vibe-math-v1/vibe-math.js",
|
|
18
|
-
"vibe-math-v1/实现方案-多代理数学问题求解与验证框架.md",
|
|
19
15
|
"vibe-math-v2/agent.cordis.yml",
|
|
20
16
|
"vibe-math-v2/preset.yml",
|
|
21
17
|
"vibe-math-v2/vibe-math-v2.js",
|
|
@@ -56,8 +52,8 @@
|
|
|
56
52
|
"bundle": {
|
|
57
53
|
"patch": "./cordis.patch.yml"
|
|
58
54
|
},
|
|
59
|
-
"minVersion": "0.1.
|
|
60
|
-
"testedVersion": "0.1.
|
|
61
|
-
"compatNote": "依赖宿主提供的 subagents/agents/tools/commands/fs 服务与 @deepseek-ai/dsh-* 插件行。本项目已充分测试并确认适配 dsh-v0.1.
|
|
55
|
+
"minVersion": "0.1.2-rc.1",
|
|
56
|
+
"testedVersion": "0.1.2-rc.1",
|
|
57
|
+
"compatNote": "依赖宿主提供的 subagents/agents/tools/commands/fs 服务与 @deepseek-ai/dsh-* 插件行。本项目已充分测试并确认适配 dsh-v0.1.2-rc.1(v2/v3/v4;v1 已于 v2.0.0 移除)。注意:DSH 0.1.2 起 subagents.startContinuable 的 agentOptions/toolFilter 需要宿主 provider 声明对应 capability(spawn/fork 进程内 provider 均支持),安装器启动时会做能力自检并在旧版宿主上告警。"
|
|
62
58
|
}
|
|
63
59
|
}
|
|
@@ -526,12 +526,12 @@ VibeMath/ # 工作区级
|
|
|
526
526
|
|
|
527
527
|
## 16. 明确假设与待确认项
|
|
528
528
|
|
|
529
|
-
1. **v3 目录名** `vibe-math-v3/`(与
|
|
529
|
+
1. **v3 目录名** `vibe-math-v3/`(与 v2/v4 并列,沿用惯例)。
|
|
530
530
|
2. **方法库作用域**:项目级 `Methods/` + 工作区全局 `VibeMath/Methods/` 两级(跨项目复用最大化,理论发明体系化后值得全局沉淀);项目→全局晋升走人工门。备选:仅项目级。
|
|
531
531
|
3. **Verified 采用"调度器生成副本"**(Propos 保留历史,Verified 为定论只读版本),而非原位删除/移动。
|
|
532
532
|
4. **规划代理输出 JSON**(机器接口),知识才用 md——调度器需要可校验的动作流,JSON 是最低成本的机器契约;md 的自由叙述留给知识对象。
|
|
533
533
|
5. **软规范取折中**(锚点行强制 + 正文自由),而非完全零规范——否则调度器无法可靠索引;锚点仅 4~7 行,符合"不设较高严格规范"。
|
|
534
|
-
6. **v3 作为新 preset id** `vibe-math-v3` 并入现有 npm 包 `dsh-vibe-math`(与
|
|
534
|
+
6. **v3 作为新 preset id** `vibe-math-v3` 并入现有 npm 包 `dsh-vibe-math`(与 v2/v4 同包多预设),版本发布策略沿用(README 标注 v2 与 v3 同级主推、按需选择;老的 `vibe-math-v1` 已于 v2.0.0 移除,本包仅含 v2/v3/v4)。
|
|
535
535
|
7. **v2 审计发现的两个缺陷**(flat 高置信分歧误判 0.5、引用被证伪卡片)在 v3 默认修复(§8.2)。
|
|
536
536
|
8. **方法库收录范围**:不限解题技巧——任何过程中发明的/经验性总结出的有价值理论体系、框架、工具、方法、思想、范式、技巧均可沉淀(§7.1);允许经验性条目(§7.4);条目可组成体系层级并跨项目持续扩充(§7.3)。
|
|
537
537
|
|
|
@@ -1,198 +0,0 @@
|
|
|
1
|
-
# The `vibe-math` agent preset: the full coding agent (`standard`), plus the
|
|
2
|
-
# multi-agent mathematical problem-solving & verification framework.
|
|
3
|
-
#
|
|
4
|
-
# The vibe-math plugin row consumes the HOST subagents/agents/fs/tools services
|
|
5
|
-
# and publishes nothing, so it needs no isolate realm (like tool-fs / tool-web).
|
|
6
|
-
|
|
7
|
-
# ── identity ────────────────────────────────────────────────────────────────
|
|
8
|
-
|
|
9
|
-
- id: persona
|
|
10
|
-
name: '@deepseek-ai/dsh-persona'
|
|
11
|
-
config:
|
|
12
|
-
text: |-
|
|
13
|
-
You are a coding agent powered by the {{model}} model. Your working directory is {{cwd}}.
|
|
14
|
-
|
|
15
|
-
## Vibe Math toolkit (available in this preset)
|
|
16
|
-
|
|
17
|
-
This session includes the "Vibe Math" multi-agent mathematical problem-solving and
|
|
18
|
-
verification framework. It is driven by a background scheduler (code), NOT by the model:
|
|
19
|
-
you only issue the control tools below and read status; the scheduler then automatically
|
|
20
|
-
runs brainstorm → solver iteration → multi-verifier debate → promotion to Verified →
|
|
21
|
-
triage back to the problem list (priority 2 > 3 > 1, concurrency-gated).
|
|
22
|
-
|
|
23
|
-
- vibe_math_add_problem {id, description, priority} — add a problem to qs.csv.
|
|
24
|
-
- vibe_math_start / vibe_math_resume — start / resume the scheduler (resume = continue after a checkpoint or restart).
|
|
25
|
-
- vibe_math_status / vibe_math_report — read scheduler status / full progress report (report also writes Progress_Logs/report.json).
|
|
26
|
-
- vibe_math_pause / vibe_math_abort — pause / abort (abort interrupts all children).
|
|
27
|
-
- vibe_math_set_mode {mode: manual|auto} — switch manual / auto control.
|
|
28
|
-
- vibe_math_set_params {...} — tune any parameter (see vibe_math_setup for the full schema).
|
|
29
|
-
- vibe_math_setup — return the parameter schema (name, type, current, default, description, options, suggestion) for guided configuration.
|
|
30
|
-
- vibe_math_save_settings — write current params to <project>/vibe_math_setting.json (JSON-with-comments) as new defaults.
|
|
31
|
-
- vibe_math_new_project / vibe_math_set_project / vibe_math_list_projects — manage per-project folders.
|
|
32
|
-
- vibe_math_list_decisions / vibe_math_decide {id, action: approve|reject|override, verdict?} — resolve manual decisions.
|
|
33
|
-
- vibe_math_list_agents / vibe_math_message_agent / vibe_math_interrupt_agent — inspect / steer / interrupt subagents.
|
|
34
|
-
|
|
35
|
-
A /vibe slash command mirrors these: /vibe start|resume|pause|abort|status|report|mode <auto|manual>|setup|save|add <id> <description>|project [list|new <name>|<name>]|decisions|agents.
|
|
36
|
-
|
|
37
|
-
Configurable subagent permissions (via vibe_math_set_params or the settings file): solverToolAllow/solverToolDeny and verifierToolAllow/verifierToolDeny restrict which tools a child sees (hard toolFilter); solverMaxToolCalls/verifierMaxToolCalls cap external tool calls per round (soft). Each child is also told it may read Verified/ and, for solvers, Progress_Logs/{qid}_progress.csv.
|
|
38
|
-
|
|
39
|
-
Interactive configuration: when the user wants to configure or adjust Vibe Math parameters, call vibe_math_setup to get the schema (each item has description, options, and a suggestion), then use ask_user_question to ask the user for the choices, apply them with vibe_math_set_params, and finally ask whether to persist them to vibe_math_setting.json via vibe_math_save_settings.
|
|
40
|
-
|
|
41
|
-
When the user asks to solve or verify a math problem with Vibe Math: add the problem (or ask for it first), then vibe_math_start, then report vibe_math_status. In manual mode, poll vibe_math_list_decisions and resolve each with vibe_math_decide. Data lives under {{cwd}}/VibeMath/Projects/<project>/ and survives restarts via vibe_math_resume.
|
|
42
|
-
|
|
43
|
-
- id: agent-instructions
|
|
44
|
-
name: '@deepseek-ai/dsh-agent-instructions'
|
|
45
|
-
config:
|
|
46
|
-
maxBytes: 65536
|
|
47
|
-
|
|
48
|
-
# ── shell ───────────────────────────────────────────────────────────────────
|
|
49
|
-
|
|
50
|
-
- id: tool-bash
|
|
51
|
-
name: '@deepseek-ai/dsh-tool-bash'
|
|
52
|
-
disabled: !!js process.platform === 'win32'
|
|
53
|
-
|
|
54
|
-
- id: tool-pwsh
|
|
55
|
-
name: '@deepseek-ai/dsh-tool-pwsh'
|
|
56
|
-
disabled: !!js process.platform !== 'win32'
|
|
57
|
-
|
|
58
|
-
# ── filesystem ──────────────────────────────────────────────────────────────
|
|
59
|
-
|
|
60
|
-
- id: tool-fs
|
|
61
|
-
name: '@deepseek-ai/dsh-tool-fs'
|
|
62
|
-
|
|
63
|
-
- id: tool-fs-search
|
|
64
|
-
name: '@deepseek-ai/dsh-tool-fs-search'
|
|
65
|
-
config:
|
|
66
|
-
sampleOverCapGlobResults: false
|
|
67
|
-
|
|
68
|
-
# ── background jobs ────────────────────────────────────────────────────────
|
|
69
|
-
|
|
70
|
-
- id: tool-jobs
|
|
71
|
-
name: '@deepseek-ai/dsh-tool-jobs'
|
|
72
|
-
|
|
73
|
-
# ── skills ──────────────────────────────────────────────────────────────────
|
|
74
|
-
|
|
75
|
-
- id: skill-filesystem
|
|
76
|
-
name: '@deepseek-ai/dsh-skill-filesystem'
|
|
77
|
-
|
|
78
|
-
- id: tool-skill
|
|
79
|
-
name: '@deepseek-ai/dsh-tool-skill'
|
|
80
|
-
|
|
81
|
-
# ── goals ───────────────────────────────────────────────────────────────────
|
|
82
|
-
|
|
83
|
-
- id: tool-goal
|
|
84
|
-
name: '@deepseek-ai/dsh-tool-goal'
|
|
85
|
-
|
|
86
|
-
# ── plan mode ───────────────────────────────────────────────────────────────
|
|
87
|
-
|
|
88
|
-
- id: planning
|
|
89
|
-
name: cordis:group
|
|
90
|
-
group: true
|
|
91
|
-
isolate:
|
|
92
|
-
planMode: true
|
|
93
|
-
config:
|
|
94
|
-
- id: plan-mode
|
|
95
|
-
name: '@deepseek-ai/dsh-plan-mode'
|
|
96
|
-
config:
|
|
97
|
-
section: |
|
|
98
|
-
You are in plan mode. Stay in plan mode until exit_plan_mode succeeds or the user 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.
|
|
99
|
-
|
|
100
|
-
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.
|
|
101
|
-
|
|
102
|
-
The tool catalog stays the same across modes for request-cache stability. These plan-mode rules override any later tool description or guidance that suggests using mutation tools; those tools remain listed to keep the tool catalog unchanged. Do not use todo_write to track this planning phase: it tracks implementation after an approved plan, while the plan itself belongs in exit_plan_mode.
|
|
103
|
-
|
|
104
|
-
Resolve discoverable facts by inspection. Use ask_user_question only for user-owned choices or material ambiguity that inspection cannot answer. Do not ask the user where code lives or how current behavior works when you can find out.
|
|
105
|
-
|
|
106
|
-
Make the plan decision-complete: state the goal and success criteria; group implementation changes by subsystem; identify public API, schema, and data-flow changes; cover edge cases, failure modes, tests, acceptance criteria, and explicit assumptions. Keep it concise enough to review but detailed enough that another engineer can implement it without making design decisions.
|
|
107
|
-
|
|
108
|
-
When ready, call exit_plan_mode with the complete plan markdown, starting with a # title. Make exit_plan_mode the only and final tool call in that assistant response: it presents the plan for approval, and implementation begins only in a later step after approval. Do not paste the final plan as a plain reply or ask "should I proceed?" through prose or ask_user_question. If review rejects it, incorporate the feedback and present again. If the review channel is unavailable or aborted, stay in plan mode and ask the user to switch modes manually; do not proceed with implementation.
|
|
109
|
-
|
|
110
|
-
# ── compaction ──────────────────────────────────────────────────────────────
|
|
111
|
-
|
|
112
|
-
- id: compaction
|
|
113
|
-
name: cordis:group
|
|
114
|
-
group: true
|
|
115
|
-
isolate:
|
|
116
|
-
compaction: true
|
|
117
|
-
toolResultPruner: true
|
|
118
|
-
config:
|
|
119
|
-
- id: compaction-basic
|
|
120
|
-
name: '@deepseek-ai/dsh-compaction-basic'
|
|
121
|
-
|
|
122
|
-
- id: command-compact
|
|
123
|
-
name: '@deepseek-ai/dsh-command-compact'
|
|
124
|
-
|
|
125
|
-
- id: tool-result-pruner
|
|
126
|
-
name: '@deepseek-ai/dsh-compaction-tool-result-pruner'
|
|
127
|
-
config:
|
|
128
|
-
thresholdChars: 8192
|
|
129
|
-
headChars: 4096
|
|
130
|
-
tailChars: 1024
|
|
131
|
-
|
|
132
|
-
# ── delegation and workflows ────────────────────────────────────────────────
|
|
133
|
-
|
|
134
|
-
- id: delegation
|
|
135
|
-
name: cordis:group
|
|
136
|
-
group: true
|
|
137
|
-
isolate:
|
|
138
|
-
workflowEngine: true
|
|
139
|
-
config:
|
|
140
|
-
- id: tool-subagent-control
|
|
141
|
-
name: '@deepseek-ai/dsh-tool-subagent-control'
|
|
142
|
-
|
|
143
|
-
- id: tool-subagent-list-agents
|
|
144
|
-
name: '@deepseek-ai/dsh-tool-subagent-control/list-agents'
|
|
145
|
-
|
|
146
|
-
- id: tool-subagent
|
|
147
|
-
name: '@deepseek-ai/dsh-tool-subagent'
|
|
148
|
-
config:
|
|
149
|
-
provider: spawn
|
|
150
|
-
toolName: subagent
|
|
151
|
-
backgroundMode: continuable
|
|
152
|
-
|
|
153
|
-
- id: tool-subagent-fork
|
|
154
|
-
name: '@deepseek-ai/dsh-tool-subagent'
|
|
155
|
-
config:
|
|
156
|
-
provider: fork
|
|
157
|
-
toolName: subagent_fork
|
|
158
|
-
backgroundMode: continuable
|
|
159
|
-
|
|
160
|
-
- id: workflow-worker-thread
|
|
161
|
-
name: '@deepseek-ai/dsh-workflow-worker-thread'
|
|
162
|
-
config:
|
|
163
|
-
provider: spawn
|
|
164
|
-
|
|
165
|
-
- id: tool-workflow
|
|
166
|
-
name: '@deepseek-ai/dsh-tool-workflow'
|
|
167
|
-
|
|
168
|
-
- id: tool-ralph
|
|
169
|
-
name: '@deepseek-ai/dsh-tool-ralph'
|
|
170
|
-
config:
|
|
171
|
-
subagentProvider: spawn
|
|
172
|
-
maxRounds: 64
|
|
173
|
-
|
|
174
|
-
# ── remaining model-facing rows ─────────────────────────────────────────────
|
|
175
|
-
|
|
176
|
-
- id: tool-ask-user
|
|
177
|
-
name: '@deepseek-ai/dsh-tool-ask-user'
|
|
178
|
-
|
|
179
|
-
- id: tool-todo
|
|
180
|
-
name: '@deepseek-ai/dsh-tool-todo'
|
|
181
|
-
config:
|
|
182
|
-
allowParallelInProgress: true
|
|
183
|
-
|
|
184
|
-
- id: tool-web
|
|
185
|
-
name: '@deepseek-ai/dsh-tool-web'
|
|
186
|
-
config:
|
|
187
|
-
fetch: false
|
|
188
|
-
searchTimeoutMs: 60000
|
|
189
|
-
|
|
190
|
-
# ── Vibe Math ───────────────────────────────────────────────────────────────
|
|
191
|
-
|
|
192
|
-
# The multi-agent math solver + verification framework: a preset-local plugin
|
|
193
|
-
# (./vibe-math.js) that registers 16 model tools (vibe_math_*), a /vibe slash
|
|
194
|
-
# command, and a background scheduler. It consumes the HOST
|
|
195
|
-
# subagents/agents/fs/tools/commands services and provides nothing, so it sits
|
|
196
|
-
# loose (no isolate realm).
|
|
197
|
-
- id: vibe-math
|
|
198
|
-
name: './vibe-math.js'
|
package/vibe-math-v1/preset.yml
DELETED