dsh-math-modeling-agent 0.2.1 → 0.2.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 +11 -6
- package/assets/mathmodelingagent-overview.svg +92 -0
- package/package.json +2 -1
package/README.md
CHANGED
|
@@ -8,6 +8,8 @@
|
|
|
8
8
|
|
|
9
9
|
## 工作方式
|
|
10
10
|
|
|
11
|
+
<p align="center"><img src="./assets/mathmodelingagent-overview.svg" alt="MathModelingAgent 工作流总览" width="100%"/></p>
|
|
12
|
+
|
|
11
13
|
1. **题目与数据**:明确问题目标、输入、约束、缺失信息与歧义。
|
|
12
14
|
2. **理解与拆解**:拆成可验证的子问题,登记假设、候选模型与关键主张。
|
|
13
15
|
3. **建模与执行**:提出候选方案,用数值计算、优化、仿真、符号计算、文献、形式验证执行并保留产物。
|
|
@@ -91,7 +93,7 @@ research/ walls/ # 文献检索 / 突破备忘录
|
|
|
91
93
|
reproducibility.json final-report.md
|
|
92
94
|
```
|
|
93
95
|
|
|
94
|
-
v0.2
|
|
96
|
+
自 v0.2 起:每个会改变模型结构的决策在对话中交互确认并写入 ledger(D0 重述/D1 路由/
|
|
95
97
|
D2 子问题假设/D3 方向/D4 裁决),`run-state.mjs gate` 在每次状态转移前强制校验;
|
|
96
98
|
终态前强制鲁棒性敏感度分析;失败尝试按类归档到独立目录。
|
|
97
99
|
|
|
@@ -106,14 +108,16 @@ D2 子问题假设/D3 方向/D4 裁决),`run-state.mjs gate` 在每次状态
|
|
|
106
108
|
安装:
|
|
107
109
|
|
|
108
110
|
```bash
|
|
109
|
-
dsh plugin --profile web add github:yohanchen1/MathModelingAgent#v0.2.
|
|
110
|
-
dsh --profile web --dump-config #
|
|
111
|
-
dsh web #
|
|
111
|
+
dsh plugin --profile web add github:yohanchen1/MathModelingAgent#v0.2.3
|
|
112
|
+
dsh --profile web --dump-config # 检查组合层(应看到 dsh-math-modeling-agent-skills 行)
|
|
113
|
+
dsh web # 重启以加载插件
|
|
112
114
|
```
|
|
113
115
|
|
|
114
|
-
(npm
|
|
116
|
+
(npm 通道装最新版:`dsh plugin --profile web add dsh-math-modeling-agent`;
|
|
117
|
+
如本机配置了镜像源且同步滞后,可显式走官方源:
|
|
118
|
+
`dsh plugin --profile web add dsh-math-modeling-agent --registry=https://registry.npmjs.org/`)
|
|
115
119
|
|
|
116
|
-
|
|
120
|
+
开始建模——直接描述任务即可。自 v0.2 起每个会改变模型结构的决策都会在对话中交互确认
|
|
117
121
|
(任务路由、各子问题假设、候选方向、每轮裁决),每轮在对话直接输出 runlog 式摘要
|
|
118
122
|
(问题重述/分析/假设/建模求解/验证/鲁棒性/评价改进/参考文献),失败尝试按类归档到独立目录,
|
|
119
123
|
终态前强制鲁棒性敏感度分析:
|
|
@@ -135,6 +139,7 @@ dsh web # 然后重启
|
|
|
135
139
|
skills/
|
|
136
140
|
├── math-modeling-agent/ # 建模、执行、修正、生成证据
|
|
137
141
|
└── math-modeling-audit/ # 独立复算、反例攻击、证据审查、MCM/ICM 终审
|
|
142
|
+
assets/ # README 工作流总览图
|
|
138
143
|
tests/ # 状态机、锁与恢复、验证协议、打包完整性、MCM 评分
|
|
139
144
|
cordis.patch.yml package.json README.md LICENSE
|
|
140
145
|
```
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" width="1066" height="620" viewBox="0 0 1066 620" role="img" aria-label="MathModelingAgent 工作流总览">
|
|
2
|
+
<defs>
|
|
3
|
+
<filter id="shadow" x="-4%" y="-4%" width="108%" height="112%">
|
|
4
|
+
<feDropShadow dx="0" dy="2" stdDeviation="4" flood-color="#0f172a" flood-opacity="0.06"/>
|
|
5
|
+
</filter>
|
|
6
|
+
</defs>
|
|
7
|
+
<rect width="1066" height="620" rx="16" fill="#f8fafc"/>
|
|
8
|
+
<text x="40" y="52" font-family="system-ui,-apple-system,'Segoe UI',sans-serif" font-size="30" font-weight="700" fill="#0f172a">MathModelingAgent</text>
|
|
9
|
+
<text x="40" y="84" font-family="system-ui,-apple-system,'Segoe UI',sans-serif" font-size="15" fill="#475569">从题目到可复现结论 · 模型负责提出,证据负责裁决</text>
|
|
10
|
+
<g font-family="system-ui,-apple-system,'Segoe UI',sans-serif" font-size="11" fill="#334155">
|
|
11
|
+
<rect x="774" y="26" width="116" height="28" rx="14" fill="#ffffff" stroke="#e2e8f0"/>
|
|
12
|
+
<text x="832" y="44" text-anchor="middle" fill="#475569">不绑定具体状态名</text>
|
|
13
|
+
<rect x="900" y="26" width="122" height="28" rx="14" fill="#ffffff" stroke="#e2e8f0"/>
|
|
14
|
+
<text x="961" y="44" text-anchor="middle" fill="#475569">不绑定文件结构</text>
|
|
15
|
+
<rect x="1032" y="26" width="104" height="28" rx="14" fill="#ffffff" stroke="#e2e8f0"/>
|
|
16
|
+
<text x="1084" y="44" text-anchor="middle" fill="#475569">工具可替换</text>
|
|
17
|
+
</g>
|
|
18
|
+
<g font-family="system-ui,-apple-system,'Segoe UI',sans-serif">
|
|
19
|
+
<rect x="40" y="112" width="184" height="250" rx="14" fill="#ffffff" stroke="#e2e8f0" filter="url(#shadow)"/>
|
|
20
|
+
<rect x="40" y="112" width="184" height="8" rx="4" fill="#34d399"/>
|
|
21
|
+
<text x="56" y="156" font-size="17" font-weight="700" fill="#0f172a">题目与数据</text>
|
|
22
|
+
<text x="56" y="178" font-size="11" font-weight="700" letter-spacing="1" fill="#34d399">INPUT</text>
|
|
23
|
+
<circle cx="62" cy="208" r="4" fill="#34d399"/><text x="74" y="212" font-size="13" fill="#475569">题目 / PDF</text>
|
|
24
|
+
<circle cx="62" cy="240" r="4" fill="#34d399"/><text x="74" y="244" font-size="13" fill="#475569">数据与附件</text>
|
|
25
|
+
<circle cx="62" cy="272" r="4" fill="#34d399"/><text x="74" y="276" font-size="13" fill="#475569">目标与约束</text>
|
|
26
|
+
|
|
27
|
+
<rect x="246" y="112" width="184" height="250" rx="14" fill="#ffffff" stroke="#e2e8f0" filter="url(#shadow)"/>
|
|
28
|
+
<rect x="246" y="112" width="184" height="8" rx="4" fill="#60a5fa"/>
|
|
29
|
+
<text x="262" y="156" font-size="17" font-weight="700" fill="#0f172a">理解与拆解</text>
|
|
30
|
+
<text x="262" y="178" font-size="11" font-weight="700" letter-spacing="1" fill="#60a5fa">UNDERSTAND</text>
|
|
31
|
+
<circle cx="268" cy="208" r="4" fill="#60a5fa"/><text x="280" y="212" font-size="13" fill="#475569">明确问题边界</text>
|
|
32
|
+
<circle cx="268" cy="240" r="4" fill="#60a5fa"/><text x="280" y="244" font-size="13" fill="#475569">拆成可验证子问题</text>
|
|
33
|
+
<circle cx="268" cy="272" r="4" fill="#60a5fa"/><text x="280" y="276" font-size="13" fill="#475569">登记关键假设</text>
|
|
34
|
+
|
|
35
|
+
<rect x="452" y="112" width="184" height="250" rx="14" fill="#ffffff" stroke="#e2e8f0" filter="url(#shadow)"/>
|
|
36
|
+
<rect x="452" y="112" width="184" height="8" rx="4" fill="#a78bfa"/>
|
|
37
|
+
<text x="468" y="156" font-size="17" font-weight="700" fill="#0f172a">建模与执行</text>
|
|
38
|
+
<text x="468" y="178" font-size="11" font-weight="700" letter-spacing="1" fill="#a78bfa">EXPLORE</text>
|
|
39
|
+
<circle cx="474" cy="208" r="4" fill="#a78bfa"/><text x="486" y="212" font-size="13" fill="#475569">提出候选模型</text>
|
|
40
|
+
<circle cx="474" cy="240" r="4" fill="#a78bfa"/><text x="486" y="244" font-size="13" fill="#475569">计算 / 搜索 / 推导</text>
|
|
41
|
+
<circle cx="474" cy="272" r="4" fill="#a78bfa"/><text x="486" y="276" font-size="13" fill="#475569">保留过程产物</text>
|
|
42
|
+
|
|
43
|
+
<rect x="658" y="112" width="184" height="250" rx="14" fill="#ffffff" stroke="#e2e8f0" filter="url(#shadow)"/>
|
|
44
|
+
<rect x="658" y="112" width="184" height="8" rx="4" fill="#fb923c"/>
|
|
45
|
+
<text x="674" y="156" font-size="17" font-weight="700" fill="#0f172a">证据验证</text>
|
|
46
|
+
<text x="674" y="178" font-size="11" font-weight="700" letter-spacing="1" fill="#fb923c">VERIFY</text>
|
|
47
|
+
<circle cx="680" cy="208" r="4" fill="#fb923c"/><text x="692" y="212" font-size="13" fill="#475569">主张 ↔ 验证义务</text>
|
|
48
|
+
<circle cx="680" cy="240" r="4" fill="#fb923c"/><text x="692" y="244" font-size="13" fill="#475569">独立重算 / 反例攻击</text>
|
|
49
|
+
<circle cx="680" cy="272" r="4" fill="#fb923c"/><text x="692" y="276" font-size="13" fill="#475569">证据不足就回去修正</text>
|
|
50
|
+
|
|
51
|
+
<rect x="864" y="112" width="184" height="250" rx="14" fill="#ffffff" stroke="#e2e8f0" filter="url(#shadow)"/>
|
|
52
|
+
<rect x="864" y="112" width="184" height="8" rx="4" fill="#f472b6"/>
|
|
53
|
+
<text x="880" y="156" font-size="17" font-weight="700" fill="#0f172a">结果交付</text>
|
|
54
|
+
<text x="880" y="178" font-size="11" font-weight="700" letter-spacing="1" fill="#f472b6">DELIVER</text>
|
|
55
|
+
<circle cx="886" cy="208" r="4" fill="#f472b6"/><text x="898" y="212" font-size="13" fill="#475569">结论 + 局限</text>
|
|
56
|
+
<circle cx="886" cy="240" r="4" fill="#f472b6"/><text x="898" y="244" font-size="13" fill="#475569">代码 / 数据 / 复现材料</text>
|
|
57
|
+
<circle cx="886" cy="272" r="4" fill="#f472b6"/><text x="898" y="276" font-size="13" fill="#475569">审计 / 终态报告</text>
|
|
58
|
+
</g>
|
|
59
|
+
<g stroke="#94a3b8" stroke-width="2.5" fill="none" marker-end="url(#arrow)">
|
|
60
|
+
<line x1="224" y1="237" x2="242" y2="237"/>
|
|
61
|
+
<line x1="430" y1="237" x2="448" y2="237"/>
|
|
62
|
+
<line x1="636" y1="237" x2="654" y2="237"/>
|
|
63
|
+
<line x1="842" y1="237" x2="860" y2="237"/>
|
|
64
|
+
</g>
|
|
65
|
+
<defs><marker id="arrow" markerWidth="8" markerHeight="8" refX="6" refY="4" orient="auto"><path d="M0,0 L8,4 L0,8 Z" fill="#94a3b8"/></marker></defs>
|
|
66
|
+
<path d="M750 362 C 750 430, 700 452, 544 452 L 544 366" fill="none" stroke="#6366f1" stroke-width="2" stroke-dasharray="6 5" marker-end="url(#arrowLoop)"/>
|
|
67
|
+
<defs><marker id="arrowLoop" markerWidth="8" markerHeight="8" refX="6" refY="4" orient="auto"><path d="M0,0 L8,4 L0,8 Z" fill="#6366f1"/></marker></defs>
|
|
68
|
+
<rect x="404" y="430" width="284" height="28" rx="14" fill="#eef2ff" stroke="#c7d2fe"/>
|
|
69
|
+
<text x="546" y="448" text-anchor="middle" font-family="system-ui,-apple-system,'Segoe UI',sans-serif" font-size="13" fill="#4338ca">证据不够 → 修正,而不是硬通过</text>
|
|
70
|
+
|
|
71
|
+
<rect x="40" y="478" width="1008" height="118" rx="14" fill="#ffffff" stroke="#e2e8f0"/>
|
|
72
|
+
<text x="64" y="512" font-family="system-ui,-apple-system,'Segoe UI',sans-serif" font-size="15" font-weight="700" fill="#0f172a">可插拔能力</text>
|
|
73
|
+
<text x="64" y="534" font-family="system-ui,-apple-system,'Segoe UI',sans-serif" font-size="12" fill="#64748b">实现可以换,语义不变:任何工具都只是为"建模"或"验证"提供证据。</text>
|
|
74
|
+
<g font-family="system-ui,-apple-system,'Segoe UI',sans-serif" text-anchor="middle">
|
|
75
|
+
<rect x="64" y="552" width="180" height="26" rx="8" fill="#f1f5f9"/>
|
|
76
|
+
<text x="154" y="569" font-size="12" font-weight="600" fill="#0f172a">数值计算</text>
|
|
77
|
+
<text x="154" y="582" font-size="10" fill="#64748b">Python / 其他运行时</text>
|
|
78
|
+
<rect x="258" y="552" width="180" height="26" rx="8" fill="#f1f5f9"/>
|
|
79
|
+
<text x="348" y="569" font-size="12" font-weight="600" fill="#0f172a">形式验证</text>
|
|
80
|
+
<text x="348" y="582" font-size="10" fill="#64748b">Lean / theorem prover</text>
|
|
81
|
+
<rect x="452" y="552" width="180" height="26" rx="8" fill="#f1f5f9"/>
|
|
82
|
+
<text x="542" y="569" font-size="12" font-weight="600" fill="#0f172a">符号计算</text>
|
|
83
|
+
<text x="542" y="582" font-size="10" fill="#64748b">Wolfram / CAS</text>
|
|
84
|
+
<rect x="646" y="552" width="180" height="26" rx="8" fill="#f1f5f9"/>
|
|
85
|
+
<text x="736" y="569" font-size="12" font-weight="600" fill="#0f172a">研究检索</text>
|
|
86
|
+
<text x="736" y="582" font-size="10" fill="#64748b">文献 / Web</text>
|
|
87
|
+
<rect x="840" y="552" width="180" height="26" rx="8" fill="#f1f5f9"/>
|
|
88
|
+
<text x="930" y="569" font-size="12" font-weight="600" fill="#0f172a">终审</text>
|
|
89
|
+
<text x="930" y="582" font-size="10" fill="#64748b">MCM / ICM audit</text>
|
|
90
|
+
</g>
|
|
91
|
+
<text x="1032" y="612" text-anchor="end" font-family="system-ui,-apple-system,'Segoe UI',sans-serif" font-size="10" fill="#94a3b8">README overview</text>
|
|
92
|
+
</svg>
|
package/package.json
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-math-modeling-agent",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3",
|
|
4
4
|
"description": "Evidence-driven mathematical modeling and verification skills for DeepSeek Harness",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"files": [
|
|
7
7
|
"cordis.patch.yml",
|
|
8
8
|
"skills",
|
|
9
|
+
"assets",
|
|
9
10
|
"README.md",
|
|
10
11
|
"LICENSE"
|
|
11
12
|
],
|