dsh-file-convert 0.4.3 → 0.4.5
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 +9 -5
- package/README.zh-CN.md +9 -5
- package/package.json +21 -6
package/README.md
CHANGED
|
@@ -6,6 +6,8 @@ Convert images, PDFs and data files directly inside your DSH agent sessions —
|
|
|
6
6
|
|
|
7
7
|
> **Unofficial community plugin.** Not affiliated with or endorsed by DeepSeek.
|
|
8
8
|
|
|
9
|
+
> **Compatibility:** v0.4.5+ targets DeepSeek Harness 0.1.5-rc.2 and its canonical-output tool API. Node.js `^22.19.0 || >=24.0.0` is required.
|
|
10
|
+
|
|
9
11
|
## Why
|
|
10
12
|
|
|
11
13
|
Agents constantly need file conversions: "turn this PDF into images", "give me that JSON as YAML", "convert all JPGs in this folder to WebP". Instead of shelling out or pasting data around, `dsh-file-convert` gives your agent seven purpose-built tools backed by battle-tested local libraries.
|
|
@@ -209,10 +211,12 @@ All 26 conversions with their live availability on *this* machine — unavailabl
|
|
|
209
211
|
```sh
|
|
210
212
|
npm install
|
|
211
213
|
npm run build # tsc -> lib/
|
|
212
|
-
npm test # vitest,
|
|
214
|
+
npm test # vitest, 77 tests (plus environment-gated suites)
|
|
213
215
|
npm run smoke # end-to-end against lib/
|
|
214
216
|
```
|
|
215
217
|
|
|
218
|
+
Local development pulls the dsh-tools peer closure into `devDependencies` so typecheck and vitest can load the 0.1.5 tool registry. End users of the published plugin do not install these — the host profile provides them.
|
|
219
|
+
|
|
216
220
|
Add a conversion = add one capability row + implement it in a converter. Add a backend = implement the `Converter` interface and register it in `createRouter()`.
|
|
217
221
|
|
|
218
222
|
## Fidelity & safety expectations
|
|
@@ -225,10 +229,10 @@ Add a conversion = add one capability row + implement it in a converter. Add a b
|
|
|
225
229
|
|
|
226
230
|
| Component | Verified version |
|
|
227
231
|
| --- | --- |
|
|
228
|
-
| DeepSeek Harness | 0.1.
|
|
229
|
-
| @deepseek-ai/dsh-tools | 0.
|
|
230
|
-
| @deepseek-ai/cordis | 4.0.
|
|
231
|
-
| Node.js | >=
|
|
232
|
+
| DeepSeek Harness | 0.1.5-rc.2 |
|
|
233
|
+
| @deepseek-ai/dsh-tools | 0.1.5-rc.2 |
|
|
234
|
+
| @deepseek-ai/cordis | 4.0.2 |
|
|
235
|
+
| Node.js | `^22.19.0 \|\| >=24.0.0` (CI covers 22) |
|
|
232
236
|
|
|
233
237
|
DSH is a developer preview and its APIs will move - the plugin keeps all DSH imports inside a thin glue layer so adapting stays cheap.
|
|
234
238
|
|
package/README.zh-CN.md
CHANGED
|
@@ -6,6 +6,8 @@
|
|
|
6
6
|
|
|
7
7
|
> **非官方社区插件。** 与 DeepSeek 官方无隶属关系。
|
|
8
8
|
|
|
9
|
+
> **兼容性:** v0.4.5 起正式适配 DeepSeek Harness 0.1.5-rc.2 及其规范输出工具 API,需要 Node.js `^22.19.0 || >=24.0.0`。
|
|
10
|
+
|
|
9
11
|
## 为什么做这个
|
|
10
12
|
|
|
11
13
|
Agent 日常需要各种格式转换:"把这个 PDF 转成图片"、"把这个 JSON 变成 YAML"、"把文件夹里所有 JPG 转成 WebP"。`dsh-file-convert` 提供七个专用 tool,背后是久经考验的本地库,你只需用自然语言提需求。
|
|
@@ -189,10 +191,12 @@ PDF 走 Ghostscript 三档预设(printer/ebook/screen)自动迭代:某档
|
|
|
189
191
|
```sh
|
|
190
192
|
npm install
|
|
191
193
|
npm run build # tsc -> lib/
|
|
192
|
-
npm test # vitest,
|
|
194
|
+
npm test # vitest,77 项测试(另有个位数按环境门控的套件)
|
|
193
195
|
npm run smoke # 针对 lib/ 的端到端冒烟测试
|
|
194
196
|
```
|
|
195
197
|
|
|
198
|
+
本地开发会在 `devDependencies` 里拉齐 dsh-tools 的 peer 闭包,便于 typecheck 与 vitest 加载 0.1.5 工具注册表。最终用户安装插件时不需要这些——由宿主 profile 提供。
|
|
199
|
+
|
|
196
200
|
加一种转换 = 在 converter 的能力表里加一行数据并实现它。加一类后端 = 实现 `Converter` 接口并在 `createRouter()` 注册。
|
|
197
201
|
|
|
198
202
|
## 保真度与安全预期
|
|
@@ -205,10 +209,10 @@ npm run smoke # 针对 lib/ 的端到端冒烟测试
|
|
|
205
209
|
|
|
206
210
|
| 组件 | 已验证版本 |
|
|
207
211
|
| --- | --- |
|
|
208
|
-
| DeepSeek Harness | 0.1.
|
|
209
|
-
| @deepseek-ai/dsh-tools | 0.
|
|
210
|
-
| @deepseek-ai/cordis | 4.0.
|
|
211
|
-
| Node.js |
|
|
212
|
+
| DeepSeek Harness | 0.1.5-rc.2 |
|
|
213
|
+
| @deepseek-ai/dsh-tools | 0.1.5-rc.2 |
|
|
214
|
+
| @deepseek-ai/cordis | 4.0.2 |
|
|
215
|
+
| Node.js | `^22.19.0 \|\| >=24.0.0`(CI 覆盖 22) |
|
|
212
216
|
|
|
213
217
|
DSH 仍处于 developer preview,API 可能变化——插件把 DSH 依赖隔离在薄胶水层,适配成本被刻意压低。
|
|
214
218
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-file-convert",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.5",
|
|
4
4
|
"description": "Local-first file conversion for DeepSeek Harness - images, PDF, data, audio/video and office documents. No API keys, no uploads, no token cost.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
},
|
|
15
15
|
"homepage": "https://github.com/zzy-12345678/dsh-file-convert#readme",
|
|
16
16
|
"engines": {
|
|
17
|
-
"node": ">=
|
|
17
|
+
"node": "^22.19.0 || >=24.0.0"
|
|
18
18
|
},
|
|
19
19
|
"files": [
|
|
20
20
|
"lib",
|
|
@@ -42,19 +42,34 @@
|
|
|
42
42
|
"local-first"
|
|
43
43
|
],
|
|
44
44
|
"dependencies": {
|
|
45
|
-
"@deepseek-ai/
|
|
46
|
-
"@deepseek-ai/dsh-tools": "0.0.1-rc.1",
|
|
47
|
-
"@deepseek-ai/schemastery": "^3.18.1",
|
|
45
|
+
"@deepseek-ai/schemastery": "^3.18.2",
|
|
48
46
|
"@napi-rs/canvas": "^1.0.8",
|
|
49
47
|
"csv-parse": "^7.0.2",
|
|
50
48
|
"csv-stringify": "^6.8.3",
|
|
51
49
|
"file-type": "^22.0.2",
|
|
52
50
|
"js-yaml": "^4.1.0",
|
|
53
|
-
"pdfjs-dist": "^6.
|
|
51
|
+
"pdfjs-dist": "^6.3.289",
|
|
54
52
|
"sharp": "^0.35.4",
|
|
55
53
|
"tesseract.js": "^7.0.0"
|
|
56
54
|
},
|
|
55
|
+
"peerDependencies": {
|
|
56
|
+
"@deepseek-ai/cordis": "^4.0.2",
|
|
57
|
+
"@deepseek-ai/dsh-tools": "^0.1.5-rc.2"
|
|
58
|
+
},
|
|
57
59
|
"devDependencies": {
|
|
60
|
+
"@deepseek-ai/cordis": "^4.0.2",
|
|
61
|
+
"@deepseek-ai/dsh-agent": "^0.1.5-rc.2",
|
|
62
|
+
"@deepseek-ai/dsh-brand": "^0.1.5-rc.2",
|
|
63
|
+
"@deepseek-ai/dsh-code-runtime": "^0.1.5-rc.2",
|
|
64
|
+
"@deepseek-ai/dsh-invariants": "^0.1.5-rc.2",
|
|
65
|
+
"@deepseek-ai/dsh-llm": "^0.1.5-rc.2",
|
|
66
|
+
"@deepseek-ai/dsh-scope": "^0.1.5-rc.2",
|
|
67
|
+
"@deepseek-ai/dsh-session": "^0.1.5-rc.2",
|
|
68
|
+
"@deepseek-ai/dsh-session-projection": "^0.1.5-rc.2",
|
|
69
|
+
"@deepseek-ai/dsh-system-prompt": "^0.1.5-rc.2",
|
|
70
|
+
"@deepseek-ai/dsh-tools": "^0.1.5-rc.2",
|
|
71
|
+
"@deepseek-ai/dsh-user-approval": "^0.1.5-rc.2",
|
|
72
|
+
"@deepseek-ai/dsh-util-values": "^0.1.5-rc.2",
|
|
58
73
|
"@types/js-yaml": "^4.0.9",
|
|
59
74
|
"@types/node": "^22.0.0",
|
|
60
75
|
"docx": "^9.7.1",
|