dsh-office-tools 0.1.0 → 0.2.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 +27 -3
- package/README.zh.md +27 -3
- package/dsh.plugin.json +1 -1
- package/lib/index.js +44564 -43469
- package/lib/index.js.map +4 -4
- package/lib/types/index.d.ts +18 -1
- package/package.json +8 -9
package/lib/types/index.d.ts
CHANGED
|
@@ -10,10 +10,27 @@
|
|
|
10
10
|
* All file access is confined to the calling agent's session workspace and
|
|
11
11
|
* every registration is wrapped in `ctx.effect` so Cordis disposes the tools
|
|
12
12
|
* with the plugin fiber.
|
|
13
|
+
*
|
|
14
|
+
* The PowerPoint pair is config-gated: dedicated presentation plugins such as
|
|
15
|
+
* dsh-ppt register a colliding `ppt_create`, and DSH refuses duplicate tool
|
|
16
|
+
* names at startup, so profiles running one of those set `enablePptTools: false`
|
|
17
|
+
* to load this plugin for Word/Excel only.
|
|
13
18
|
*/
|
|
14
19
|
import type { Context } from '@deepseek-ai/cordis';
|
|
20
|
+
import z from '@deepseek-ai/schemastery';
|
|
15
21
|
/** Plugin identity for cordis.yml rows. */
|
|
16
22
|
export declare const name = "dsh-office-tools";
|
|
17
23
|
/** The tool registry is the only runtime service this plugin requires. */
|
|
18
24
|
export declare const inject: string[];
|
|
19
|
-
|
|
25
|
+
/** Host plugin configuration, validated at load by the Loader. */
|
|
26
|
+
export interface Config {
|
|
27
|
+
/** Register `ppt_create` / `ppt_read`. */
|
|
28
|
+
enablePptTools: boolean;
|
|
29
|
+
}
|
|
30
|
+
/** Configuration schema; the callable form applies schema defaults. */
|
|
31
|
+
export declare const Config: z<Schemastery.ObjectS<{
|
|
32
|
+
enablePptTools: z<boolean, boolean>;
|
|
33
|
+
}>, Schemastery.ObjectT<{
|
|
34
|
+
enablePptTools: z<boolean, boolean>;
|
|
35
|
+
}>>;
|
|
36
|
+
export declare function apply(ctx: Context, config?: Config): void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "dsh-office-tools",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.2.0",
|
|
4
4
|
"description": "DSH model-facing Office tools: create, read, and update Word (.docx), Excel (.xlsx), and PowerPoint (.pptx) files inside the session workspace.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
@@ -32,13 +32,6 @@
|
|
|
32
32
|
"test": "vitest run",
|
|
33
33
|
"check": "pnpm run typecheck && pnpm run test && pnpm run build"
|
|
34
34
|
},
|
|
35
|
-
"dependencies": {
|
|
36
|
-
"docx": "^9.5.1",
|
|
37
|
-
"jszip": "^3.10.1",
|
|
38
|
-
"mammoth": "^1.11.0",
|
|
39
|
-
"pptxgenjs": "^4.0.1",
|
|
40
|
-
"xlsx": "^0.18.5"
|
|
41
|
-
},
|
|
42
35
|
"peerDependencies": {
|
|
43
36
|
"@deepseek-ai/cordis": "^4.0.1",
|
|
44
37
|
"@deepseek-ai/dsh-agent": "^0.1.0-rc.6",
|
|
@@ -69,10 +62,16 @@
|
|
|
69
62
|
"@deepseek-ai/dsh-llm": "^0.1.0-rc.6",
|
|
70
63
|
"@deepseek-ai/dsh-session": "^0.1.0-rc.6",
|
|
71
64
|
"@deepseek-ai/dsh-tools": "^0.1.0-rc.6",
|
|
65
|
+
"@deepseek-ai/schemastery": "^3.18.1",
|
|
72
66
|
"@types/node": "^24.0.0",
|
|
67
|
+
"docx": "^9.5.1",
|
|
73
68
|
"esbuild": "^0.25.0",
|
|
69
|
+
"jszip": "^3.10.1",
|
|
70
|
+
"mammoth": "^1.11.0",
|
|
71
|
+
"pptxgenjs": "^4.0.1",
|
|
74
72
|
"typescript": "^5.6.0",
|
|
75
|
-
"vitest": "^4.1.8"
|
|
73
|
+
"vitest": "^4.1.8",
|
|
74
|
+
"xlsx": "https://cdn.sheetjs.com/xlsx-0.20.3/xlsx-0.20.3.tgz"
|
|
76
75
|
},
|
|
77
76
|
"author": "kw78",
|
|
78
77
|
"homepage": "https://github.com/kw78/dsh-office-tools#readme",
|