dsh-image-gen 0.2.0 → 0.2.1
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.en.md +171 -171
- package/README.md +181 -187
- package/README.zh-CN.md +171 -171
- package/lib/index.js +111 -32
- package/lib/types/dashscope.d.ts +2 -2
- package/lib/types/google.d.ts +2 -2
- package/lib/types/openai-compatible.d.ts +1 -1
- package/lib/types/reference-image.d.ts +17 -0
- package/lib/types/seedream.d.ts +2 -2
- package/package.json +131 -131
|
@@ -32,6 +32,23 @@ export declare function resolveReferenceImage(input: {
|
|
|
32
32
|
maxBytes?: number;
|
|
33
33
|
signal: AbortSignal;
|
|
34
34
|
}): Promise<ResolvedReferenceImage>;
|
|
35
|
+
/**
|
|
36
|
+
* Resolve one or more edit references while keeping every DSH-specific detail
|
|
37
|
+
* behind this compatibility boundary. Explicit selectors preserve caller order;
|
|
38
|
+
* without selectors, all images in the newest image-bearing message are used.
|
|
39
|
+
*/
|
|
40
|
+
export declare function resolveReferenceImages(input: {
|
|
41
|
+
agent?: ReferenceImageAgent;
|
|
42
|
+
attachments: ReferenceImageStore;
|
|
43
|
+
sourceAttachmentId?: string;
|
|
44
|
+
sourceAttachmentIds?: readonly string[];
|
|
45
|
+
sourcePath?: string;
|
|
46
|
+
sourcePaths?: readonly string[];
|
|
47
|
+
maxBytes?: number;
|
|
48
|
+
signal: AbortSignal;
|
|
49
|
+
}): Promise<ResolvedReferenceImage[]>;
|
|
50
|
+
/** Find images in caller order, or every image in the newest image-bearing message. */
|
|
51
|
+
export declare function findReferenceImages(messages: readonly Message[], sourceAttachmentIds?: readonly string[]): ImageAttachmentRef[];
|
|
35
52
|
/** Find the newest matching image in the effective, replacement-aware history. */
|
|
36
53
|
export declare function findReferenceImage(messages: readonly Message[], sourceAttachmentId?: string): ImageAttachmentRef | undefined;
|
|
37
54
|
/** Validate an untrusted serialized image reference at an HTTP/UI boundary. */
|
package/lib/types/seedream.d.ts
CHANGED
|
@@ -7,10 +7,10 @@ export declare function editSeedreamImage(input: {
|
|
|
7
7
|
baseURL: string;
|
|
8
8
|
model: string;
|
|
9
9
|
prompt: string;
|
|
10
|
-
|
|
10
|
+
sourceImages: Array<{
|
|
11
11
|
data: Uint8Array;
|
|
12
12
|
mediaType: ImageMediaType;
|
|
13
|
-
}
|
|
13
|
+
}>;
|
|
14
14
|
size?: string;
|
|
15
15
|
maxBytes: number;
|
|
16
16
|
signal: AbortSignal;
|
package/package.json
CHANGED
|
@@ -1,131 +1,131 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "dsh-image-gen",
|
|
3
|
-
"version": "0.2.
|
|
4
|
-
"description": "Bring ChatGPT-like image generation to DeepSeek Harness — Gemini, OpenAI, Seedream, DashScope & more.",
|
|
5
|
-
"type": "module",
|
|
6
|
-
"author": "shanliuling",
|
|
7
|
-
"repository": {
|
|
8
|
-
"type": "git",
|
|
9
|
-
"url": "git+https://github.com/shanliuling/dsh-image-gen.git"
|
|
10
|
-
},
|
|
11
|
-
"bugs": {
|
|
12
|
-
"url": "https://github.com/shanliuling/dsh-image-gen/issues"
|
|
13
|
-
},
|
|
14
|
-
"homepage": "https://github.com/shanliuling/dsh-image-gen#readme",
|
|
15
|
-
"main": "lib/index.js",
|
|
16
|
-
"types": "lib/types/index.d.ts",
|
|
17
|
-
"exports": {
|
|
18
|
-
".": {
|
|
19
|
-
"types": "./lib/types/index.d.ts",
|
|
20
|
-
"default": "./lib/index.js"
|
|
21
|
-
},
|
|
22
|
-
"./client": {
|
|
23
|
-
"types": "./lib/types/client/index.d.ts",
|
|
24
|
-
"default": "./lib/client.js"
|
|
25
|
-
},
|
|
26
|
-
"./package.json": "./package.json"
|
|
27
|
-
},
|
|
28
|
-
"files": [
|
|
29
|
-
"lib/index.js",
|
|
30
|
-
"lib/client.js",
|
|
31
|
-
"lib/client.js.map",
|
|
32
|
-
"lib/types/**/*.d.ts",
|
|
33
|
-
"skills/**/*.md",
|
|
34
|
-
"cordis.patch.yml",
|
|
35
|
-
"README.md",
|
|
36
|
-
"README.zh-CN.md",
|
|
37
|
-
"LICENSE"
|
|
38
|
-
],
|
|
39
|
-
"dsh": {
|
|
40
|
-
"bundle": {
|
|
41
|
-
"patch": "./cordis.patch.yml"
|
|
42
|
-
},
|
|
43
|
-
"client": {
|
|
44
|
-
"inject": [
|
|
45
|
-
"@deepseek-ai/dsh-client-connection",
|
|
46
|
-
"@deepseek-ai/dsh-api-remotes",
|
|
47
|
-
"@deepseek-ai/dsh-client-runtime",
|
|
48
|
-
"@deepseek-ai/dsh-client-ui-conversation",
|
|
49
|
-
"@deepseek-ai/dsh-client-ui-settings",
|
|
50
|
-
"@deepseek-ai/dsh-client-ui-settings-plugins",
|
|
51
|
-
"@deepseek-ai/dsh-client-ui-tool",
|
|
52
|
-
"@deepseek-ai/dsh-client-locale"
|
|
53
|
-
],
|
|
54
|
-
"platform": "web"
|
|
55
|
-
}
|
|
56
|
-
},
|
|
57
|
-
"scripts": {
|
|
58
|
-
"typecheck": "tsc --noEmit",
|
|
59
|
-
"build": "tsc && tsdown",
|
|
60
|
-
"prepare": "pnpm run build",
|
|
61
|
-
"test": "vitest run",
|
|
62
|
-
"pack:check": "pnpm pack --dry-run"
|
|
63
|
-
},
|
|
64
|
-
"engines": {
|
|
65
|
-
"node": "^22.19.0 || >=24.0.0"
|
|
66
|
-
},
|
|
67
|
-
"license": "MIT",
|
|
68
|
-
"keywords": [
|
|
69
|
-
"deepseek",
|
|
70
|
-
"deepseek-harness",
|
|
71
|
-
"dsh",
|
|
72
|
-
"dsh-plugin",
|
|
73
|
-
"ai-agent",
|
|
74
|
-
"image-generation",
|
|
75
|
-
"ai-image-generation",
|
|
76
|
-
"multimodal",
|
|
77
|
-
"gemini",
|
|
78
|
-
"openai",
|
|
79
|
-
"openai-compatible",
|
|
80
|
-
"seedream",
|
|
81
|
-
"dashscope",
|
|
82
|
-
"wanx",
|
|
83
|
-
"aliyun",
|
|
84
|
-
"volcengine",
|
|
85
|
-
"byok",
|
|
86
|
-
"cordis"
|
|
87
|
-
],
|
|
88
|
-
"peerDependencies": {
|
|
89
|
-
"@deepseek-ai/cordis": ">=4.0.0 <5",
|
|
90
|
-
"@deepseek-ai/dsh-api-remotes": ">=0.1.1-rc.2 <0.2.0",
|
|
91
|
-
"@deepseek-ai/dsh-attachment": ">=0.1.1-rc.2 <0.2.0",
|
|
92
|
-
"@deepseek-ai/dsh-client-connection": ">=0.1.1-rc.2 <0.2.0",
|
|
93
|
-
"@deepseek-ai/dsh-client-runtime": ">=0.1.1-rc.2 <0.2.0",
|
|
94
|
-
"@deepseek-ai/dsh-client-ui-conversation": ">=0.1.1-rc.2 <0.2.0",
|
|
95
|
-
"@deepseek-ai/dsh-client-ui-settings": ">=0.1.1-rc.2 <0.2.0",
|
|
96
|
-
"@deepseek-ai/dsh-client-ui-settings-plugins": ">=0.1.1-rc.2 <0.2.0",
|
|
97
|
-
"@deepseek-ai/dsh-client-ui-slots": ">=0.1.1-rc.2 <0.2.0",
|
|
98
|
-
"@deepseek-ai/dsh-client-ui-tool": ">=0.1.1-rc.2 <0.2.0",
|
|
99
|
-
"@deepseek-ai/dsh-credentials": ">=0.1.1-rc.2 <0.2.0",
|
|
100
|
-
"@deepseek-ai/dsh-host-webserver": ">=0.1.1-rc.2 <0.2.0",
|
|
101
|
-
"@deepseek-ai/dsh-settings": ">=0.1.1-rc.2 <0.2.0",
|
|
102
|
-
"@deepseek-ai/dsh-tools": ">=0.1.1-rc.2 <0.2.0",
|
|
103
|
-
"@deepseek-ai/schemastery": ">=3.18.0 <4",
|
|
104
|
-
"react": ">=18.2.0 <19"
|
|
105
|
-
},
|
|
106
|
-
"devDependencies": {
|
|
107
|
-
"@deepseek-ai/cordis": "4.0.1",
|
|
108
|
-
"@deepseek-ai/dsh-api-remotes": "0.1.1-rc.2",
|
|
109
|
-
"@deepseek-ai/dsh-attachment": "0.1.1-rc.2",
|
|
110
|
-
"@deepseek-ai/dsh-client-connection": "0.1.1-rc.2",
|
|
111
|
-
"@deepseek-ai/dsh-client-runtime": "0.1.1-rc.2",
|
|
112
|
-
"@deepseek-ai/dsh-client-ui-conversation": "0.1.1-rc.2",
|
|
113
|
-
"@deepseek-ai/dsh-client-ui-settings": "0.1.1-rc.2",
|
|
114
|
-
"@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.1-rc.2",
|
|
115
|
-
"@deepseek-ai/dsh-client-ui-slots": "0.1.1-rc.2",
|
|
116
|
-
"@deepseek-ai/dsh-client-ui-tool": "0.1.1-rc.2",
|
|
117
|
-
"@deepseek-ai/dsh-credentials": "0.1.1-rc.2",
|
|
118
|
-
"@deepseek-ai/dsh-host-webserver": "0.1.1-rc.2",
|
|
119
|
-
"@deepseek-ai/dsh-llm": "0.1.1-rc.2",
|
|
120
|
-
"@deepseek-ai/dsh-settings": "0.1.1-rc.2",
|
|
121
|
-
"@deepseek-ai/dsh-tools": "0.1.1-rc.2",
|
|
122
|
-
"@deepseek-ai/schemastery": "3.18.1",
|
|
123
|
-
"@types/node": "^22.20.0",
|
|
124
|
-
"@types/react": "~18.3.1",
|
|
125
|
-
"react": "^18.2.0",
|
|
126
|
-
"tsdown": "^0.22.2",
|
|
127
|
-
"typescript": "^6.0.3",
|
|
128
|
-
"vitest": "^4.1.8"
|
|
129
|
-
},
|
|
130
|
-
"packageManager": "pnpm@11.7.0"
|
|
131
|
-
}
|
|
1
|
+
{
|
|
2
|
+
"name": "dsh-image-gen",
|
|
3
|
+
"version": "0.2.1",
|
|
4
|
+
"description": "Bring ChatGPT-like image generation to DeepSeek Harness — Gemini, OpenAI, Seedream, DashScope & more.",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"author": "shanliuling",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "git+https://github.com/shanliuling/dsh-image-gen.git"
|
|
10
|
+
},
|
|
11
|
+
"bugs": {
|
|
12
|
+
"url": "https://github.com/shanliuling/dsh-image-gen/issues"
|
|
13
|
+
},
|
|
14
|
+
"homepage": "https://github.com/shanliuling/dsh-image-gen#readme",
|
|
15
|
+
"main": "lib/index.js",
|
|
16
|
+
"types": "lib/types/index.d.ts",
|
|
17
|
+
"exports": {
|
|
18
|
+
".": {
|
|
19
|
+
"types": "./lib/types/index.d.ts",
|
|
20
|
+
"default": "./lib/index.js"
|
|
21
|
+
},
|
|
22
|
+
"./client": {
|
|
23
|
+
"types": "./lib/types/client/index.d.ts",
|
|
24
|
+
"default": "./lib/client.js"
|
|
25
|
+
},
|
|
26
|
+
"./package.json": "./package.json"
|
|
27
|
+
},
|
|
28
|
+
"files": [
|
|
29
|
+
"lib/index.js",
|
|
30
|
+
"lib/client.js",
|
|
31
|
+
"lib/client.js.map",
|
|
32
|
+
"lib/types/**/*.d.ts",
|
|
33
|
+
"skills/**/*.md",
|
|
34
|
+
"cordis.patch.yml",
|
|
35
|
+
"README.md",
|
|
36
|
+
"README.zh-CN.md",
|
|
37
|
+
"LICENSE"
|
|
38
|
+
],
|
|
39
|
+
"dsh": {
|
|
40
|
+
"bundle": {
|
|
41
|
+
"patch": "./cordis.patch.yml"
|
|
42
|
+
},
|
|
43
|
+
"client": {
|
|
44
|
+
"inject": [
|
|
45
|
+
"@deepseek-ai/dsh-client-connection",
|
|
46
|
+
"@deepseek-ai/dsh-api-remotes",
|
|
47
|
+
"@deepseek-ai/dsh-client-runtime",
|
|
48
|
+
"@deepseek-ai/dsh-client-ui-conversation",
|
|
49
|
+
"@deepseek-ai/dsh-client-ui-settings",
|
|
50
|
+
"@deepseek-ai/dsh-client-ui-settings-plugins",
|
|
51
|
+
"@deepseek-ai/dsh-client-ui-tool",
|
|
52
|
+
"@deepseek-ai/dsh-client-locale"
|
|
53
|
+
],
|
|
54
|
+
"platform": "web"
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
"scripts": {
|
|
58
|
+
"typecheck": "tsc --noEmit",
|
|
59
|
+
"build": "tsc && tsdown",
|
|
60
|
+
"prepare": "pnpm run build",
|
|
61
|
+
"test": "vitest run",
|
|
62
|
+
"pack:check": "pnpm pack --dry-run"
|
|
63
|
+
},
|
|
64
|
+
"engines": {
|
|
65
|
+
"node": "^22.19.0 || >=24.0.0"
|
|
66
|
+
},
|
|
67
|
+
"license": "MIT",
|
|
68
|
+
"keywords": [
|
|
69
|
+
"deepseek",
|
|
70
|
+
"deepseek-harness",
|
|
71
|
+
"dsh",
|
|
72
|
+
"dsh-plugin",
|
|
73
|
+
"ai-agent",
|
|
74
|
+
"image-generation",
|
|
75
|
+
"ai-image-generation",
|
|
76
|
+
"multimodal",
|
|
77
|
+
"gemini",
|
|
78
|
+
"openai",
|
|
79
|
+
"openai-compatible",
|
|
80
|
+
"seedream",
|
|
81
|
+
"dashscope",
|
|
82
|
+
"wanx",
|
|
83
|
+
"aliyun",
|
|
84
|
+
"volcengine",
|
|
85
|
+
"byok",
|
|
86
|
+
"cordis"
|
|
87
|
+
],
|
|
88
|
+
"peerDependencies": {
|
|
89
|
+
"@deepseek-ai/cordis": ">=4.0.0 <5",
|
|
90
|
+
"@deepseek-ai/dsh-api-remotes": ">=0.1.1-rc.2 <0.2.0",
|
|
91
|
+
"@deepseek-ai/dsh-attachment": ">=0.1.1-rc.2 <0.2.0",
|
|
92
|
+
"@deepseek-ai/dsh-client-connection": ">=0.1.1-rc.2 <0.2.0",
|
|
93
|
+
"@deepseek-ai/dsh-client-runtime": ">=0.1.1-rc.2 <0.2.0",
|
|
94
|
+
"@deepseek-ai/dsh-client-ui-conversation": ">=0.1.1-rc.2 <0.2.0",
|
|
95
|
+
"@deepseek-ai/dsh-client-ui-settings": ">=0.1.1-rc.2 <0.2.0",
|
|
96
|
+
"@deepseek-ai/dsh-client-ui-settings-plugins": ">=0.1.1-rc.2 <0.2.0",
|
|
97
|
+
"@deepseek-ai/dsh-client-ui-slots": ">=0.1.1-rc.2 <0.2.0",
|
|
98
|
+
"@deepseek-ai/dsh-client-ui-tool": ">=0.1.1-rc.2 <0.2.0",
|
|
99
|
+
"@deepseek-ai/dsh-credentials": ">=0.1.1-rc.2 <0.2.0",
|
|
100
|
+
"@deepseek-ai/dsh-host-webserver": ">=0.1.1-rc.2 <0.2.0",
|
|
101
|
+
"@deepseek-ai/dsh-settings": ">=0.1.1-rc.2 <0.2.0",
|
|
102
|
+
"@deepseek-ai/dsh-tools": ">=0.1.1-rc.2 <0.2.0",
|
|
103
|
+
"@deepseek-ai/schemastery": ">=3.18.0 <4",
|
|
104
|
+
"react": ">=18.2.0 <19"
|
|
105
|
+
},
|
|
106
|
+
"devDependencies": {
|
|
107
|
+
"@deepseek-ai/cordis": "4.0.1",
|
|
108
|
+
"@deepseek-ai/dsh-api-remotes": "0.1.1-rc.2",
|
|
109
|
+
"@deepseek-ai/dsh-attachment": "0.1.1-rc.2",
|
|
110
|
+
"@deepseek-ai/dsh-client-connection": "0.1.1-rc.2",
|
|
111
|
+
"@deepseek-ai/dsh-client-runtime": "0.1.1-rc.2",
|
|
112
|
+
"@deepseek-ai/dsh-client-ui-conversation": "0.1.1-rc.2",
|
|
113
|
+
"@deepseek-ai/dsh-client-ui-settings": "0.1.1-rc.2",
|
|
114
|
+
"@deepseek-ai/dsh-client-ui-settings-plugins": "0.1.1-rc.2",
|
|
115
|
+
"@deepseek-ai/dsh-client-ui-slots": "0.1.1-rc.2",
|
|
116
|
+
"@deepseek-ai/dsh-client-ui-tool": "0.1.1-rc.2",
|
|
117
|
+
"@deepseek-ai/dsh-credentials": "0.1.1-rc.2",
|
|
118
|
+
"@deepseek-ai/dsh-host-webserver": "0.1.1-rc.2",
|
|
119
|
+
"@deepseek-ai/dsh-llm": "0.1.1-rc.2",
|
|
120
|
+
"@deepseek-ai/dsh-settings": "0.1.1-rc.2",
|
|
121
|
+
"@deepseek-ai/dsh-tools": "0.1.1-rc.2",
|
|
122
|
+
"@deepseek-ai/schemastery": "3.18.1",
|
|
123
|
+
"@types/node": "^22.20.0",
|
|
124
|
+
"@types/react": "~18.3.1",
|
|
125
|
+
"react": "^18.2.0",
|
|
126
|
+
"tsdown": "^0.22.2",
|
|
127
|
+
"typescript": "^6.0.3",
|
|
128
|
+
"vitest": "^4.1.8"
|
|
129
|
+
},
|
|
130
|
+
"packageManager": "pnpm@11.7.0"
|
|
131
|
+
}
|