@openclaw/deepseek-provider 0.0.0 → 2026.6.9-beta.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.md +11 -2
- package/dist/api.js +4 -0
- package/dist/index.js +59 -0
- package/dist/models-DCxTAfJ0.js +106 -0
- package/dist/models.js +2 -0
- package/dist/onboard.js +24 -0
- package/dist/provider-catalog.js +11 -0
- package/dist/provider-discovery.js +14 -0
- package/dist/provider-policy-api.js +68 -0
- package/dist/stream.js +12 -0
- package/dist/thinking.js +23 -0
- package/npm-shrinkwrap.json +12 -0
- package/openclaw.plugin.json +137 -0
- package/package.json +44 -8
package/README.md
CHANGED
|
@@ -1,3 +1,12 @@
|
|
|
1
|
-
#
|
|
1
|
+
# OpenClaw DeepSeek Provider
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
Official OpenClaw provider plugin for DeepSeek.
|
|
4
|
+
|
|
5
|
+
Install from OpenClaw:
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
openclaw plugins install @openclaw/deepseek-provider
|
|
9
|
+
openclaw gateway restart
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
See <https://docs.openclaw.ai/providers/deepseek> for setup and configuration.
|
package/dist/api.js
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { n as DEEPSEEK_MODEL_CATALOG, r as buildDeepSeekModelDefinition, t as DEEPSEEK_BASE_URL } from "./models-DCxTAfJ0.js";
|
|
2
|
+
import { buildDeepSeekProvider } from "./provider-catalog.js";
|
|
3
|
+
import { createDeepSeekV4ThinkingWrapper } from "./stream.js";
|
|
4
|
+
export { DEEPSEEK_BASE_URL, DEEPSEEK_MODEL_CATALOG, buildDeepSeekModelDefinition, buildDeepSeekProvider, createDeepSeekV4ThinkingWrapper };
|
package/dist/index.js
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { buildDeepSeekProvider } from "./provider-catalog.js";
|
|
2
|
+
import { createDeepSeekV4ThinkingWrapper } from "./stream.js";
|
|
3
|
+
import { DEEPSEEK_DEFAULT_MODEL_REF, applyDeepSeekConfig } from "./onboard.js";
|
|
4
|
+
import { resolveDeepSeekV4ThinkingProfile } from "./thinking.js";
|
|
5
|
+
import { readConfiguredProviderCatalogEntries } from "openclaw/plugin-sdk/provider-catalog-shared";
|
|
6
|
+
import { defineSingleProviderPluginEntry } from "openclaw/plugin-sdk/provider-entry";
|
|
7
|
+
import { buildProviderReplayFamilyHooks } from "openclaw/plugin-sdk/provider-model-shared";
|
|
8
|
+
import { buildProviderToolCompatFamilyHooks } from "openclaw/plugin-sdk/provider-tools";
|
|
9
|
+
import { fetchDeepSeekUsage } from "openclaw/plugin-sdk/provider-usage";
|
|
10
|
+
//#region extensions/deepseek/index.ts
|
|
11
|
+
const PROVIDER_ID = "deepseek";
|
|
12
|
+
var deepseek_default = defineSingleProviderPluginEntry({
|
|
13
|
+
id: PROVIDER_ID,
|
|
14
|
+
name: "DeepSeek Provider",
|
|
15
|
+
description: "Bundled DeepSeek provider plugin",
|
|
16
|
+
provider: {
|
|
17
|
+
label: "DeepSeek",
|
|
18
|
+
docsPath: "/providers/deepseek",
|
|
19
|
+
auth: [{
|
|
20
|
+
methodId: "api-key",
|
|
21
|
+
label: "DeepSeek API key",
|
|
22
|
+
hint: "API key",
|
|
23
|
+
optionKey: "deepseekApiKey",
|
|
24
|
+
flagName: "--deepseek-api-key",
|
|
25
|
+
envVar: "DEEPSEEK_API_KEY",
|
|
26
|
+
promptMessage: "Enter DeepSeek API key",
|
|
27
|
+
defaultModel: DEEPSEEK_DEFAULT_MODEL_REF,
|
|
28
|
+
applyConfig: (cfg) => applyDeepSeekConfig(cfg),
|
|
29
|
+
wizard: {
|
|
30
|
+
choiceId: "deepseek-api-key",
|
|
31
|
+
choiceLabel: "DeepSeek API key",
|
|
32
|
+
groupId: "deepseek",
|
|
33
|
+
groupLabel: "DeepSeek",
|
|
34
|
+
groupHint: "API key"
|
|
35
|
+
}
|
|
36
|
+
}],
|
|
37
|
+
catalog: { buildProvider: buildDeepSeekProvider },
|
|
38
|
+
augmentModelCatalog: ({ config }) => readConfiguredProviderCatalogEntries({
|
|
39
|
+
config,
|
|
40
|
+
providerId: PROVIDER_ID
|
|
41
|
+
}),
|
|
42
|
+
matchesContextOverflowError: ({ errorMessage }) => /\bdeepseek\b.*(?:input.*too long|context.*exceed)/i.test(errorMessage),
|
|
43
|
+
...buildProviderReplayFamilyHooks({
|
|
44
|
+
family: "openai-compatible",
|
|
45
|
+
dropReasoningFromHistory: false
|
|
46
|
+
}),
|
|
47
|
+
...buildProviderToolCompatFamilyHooks("deepseek"),
|
|
48
|
+
wrapStreamFn: (ctx) => createDeepSeekV4ThinkingWrapper(ctx.streamFn, ctx.thinkingLevel),
|
|
49
|
+
resolveThinkingProfile: ({ modelId }) => resolveDeepSeekV4ThinkingProfile(modelId),
|
|
50
|
+
isModernModelRef: ({ modelId }) => Boolean(resolveDeepSeekV4ThinkingProfile(modelId)),
|
|
51
|
+
resolveUsageAuth: async (ctx) => {
|
|
52
|
+
const apiKey = ctx.resolveApiKeyFromConfigAndStore({ envDirect: [ctx.env.DEEPSEEK_API_KEY] });
|
|
53
|
+
return apiKey ? { token: apiKey } : null;
|
|
54
|
+
},
|
|
55
|
+
fetchUsageSnapshot: async (ctx) => await fetchDeepSeekUsage(ctx.token, ctx.timeoutMs, ctx.fetchFn)
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
//#endregion
|
|
59
|
+
export { deepseek_default as default };
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { buildManifestModelProviderConfig } from "openclaw/plugin-sdk/provider-catalog-shared";
|
|
2
|
+
//#endregion
|
|
3
|
+
//#region extensions/deepseek/models.ts
|
|
4
|
+
const DEEPSEEK_MANIFEST_PROVIDER = buildManifestModelProviderConfig({
|
|
5
|
+
providerId: "deepseek",
|
|
6
|
+
catalog: {
|
|
7
|
+
"providers": { "deepseek": {
|
|
8
|
+
"baseUrl": "https://api.deepseek.com",
|
|
9
|
+
"api": "openai-completions",
|
|
10
|
+
"models": [
|
|
11
|
+
{
|
|
12
|
+
"id": "deepseek-v4-flash",
|
|
13
|
+
"name": "DeepSeek V4 Flash",
|
|
14
|
+
"reasoning": true,
|
|
15
|
+
"input": ["text"],
|
|
16
|
+
"contextWindow": 1e6,
|
|
17
|
+
"maxTokens": 384e3,
|
|
18
|
+
"cost": {
|
|
19
|
+
"input": .14,
|
|
20
|
+
"output": .28,
|
|
21
|
+
"cacheRead": .028,
|
|
22
|
+
"cacheWrite": 0
|
|
23
|
+
},
|
|
24
|
+
"compat": {
|
|
25
|
+
"supportsUsageInStreaming": true,
|
|
26
|
+
"supportsReasoningEffort": true,
|
|
27
|
+
"maxTokensField": "max_tokens"
|
|
28
|
+
}
|
|
29
|
+
},
|
|
30
|
+
{
|
|
31
|
+
"id": "deepseek-v4-pro",
|
|
32
|
+
"name": "DeepSeek V4 Pro",
|
|
33
|
+
"reasoning": true,
|
|
34
|
+
"input": ["text"],
|
|
35
|
+
"contextWindow": 1e6,
|
|
36
|
+
"maxTokens": 384e3,
|
|
37
|
+
"cost": {
|
|
38
|
+
"input": 1.74,
|
|
39
|
+
"output": 3.48,
|
|
40
|
+
"cacheRead": .145,
|
|
41
|
+
"cacheWrite": 0
|
|
42
|
+
},
|
|
43
|
+
"compat": {
|
|
44
|
+
"supportsUsageInStreaming": true,
|
|
45
|
+
"supportsReasoningEffort": true,
|
|
46
|
+
"maxTokensField": "max_tokens"
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
{
|
|
50
|
+
"id": "deepseek-chat",
|
|
51
|
+
"name": "DeepSeek Chat",
|
|
52
|
+
"input": ["text"],
|
|
53
|
+
"contextWindow": 131072,
|
|
54
|
+
"maxTokens": 8192,
|
|
55
|
+
"cost": {
|
|
56
|
+
"input": .28,
|
|
57
|
+
"output": .42,
|
|
58
|
+
"cacheRead": .028,
|
|
59
|
+
"cacheWrite": 0
|
|
60
|
+
},
|
|
61
|
+
"compat": {
|
|
62
|
+
"supportsUsageInStreaming": true,
|
|
63
|
+
"maxTokensField": "max_tokens"
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"id": "deepseek-reasoner",
|
|
68
|
+
"name": "DeepSeek Reasoner",
|
|
69
|
+
"reasoning": true,
|
|
70
|
+
"input": ["text"],
|
|
71
|
+
"contextWindow": 131072,
|
|
72
|
+
"maxTokens": 65536,
|
|
73
|
+
"cost": {
|
|
74
|
+
"input": .28,
|
|
75
|
+
"output": .42,
|
|
76
|
+
"cacheRead": .028,
|
|
77
|
+
"cacheWrite": 0
|
|
78
|
+
},
|
|
79
|
+
"compat": {
|
|
80
|
+
"supportsUsageInStreaming": true,
|
|
81
|
+
"supportsReasoningEffort": false,
|
|
82
|
+
"maxTokensField": "max_tokens"
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
]
|
|
86
|
+
} },
|
|
87
|
+
"discovery": { "deepseek": "static" }
|
|
88
|
+
}.providers.deepseek
|
|
89
|
+
});
|
|
90
|
+
const DEEPSEEK_BASE_URL = DEEPSEEK_MANIFEST_PROVIDER.baseUrl;
|
|
91
|
+
const DEEPSEEK_MODEL_CATALOG = DEEPSEEK_MANIFEST_PROVIDER.models;
|
|
92
|
+
function buildDeepSeekModelDefinition(model) {
|
|
93
|
+
return {
|
|
94
|
+
...model,
|
|
95
|
+
api: "openai-completions"
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
const DEEPSEEK_V4_MODEL_IDS = new Set(["deepseek-v4-flash", "deepseek-v4-pro"]);
|
|
99
|
+
function isDeepSeekV4ModelId(modelId) {
|
|
100
|
+
return DEEPSEEK_V4_MODEL_IDS.has(modelId.toLowerCase());
|
|
101
|
+
}
|
|
102
|
+
function isDeepSeekV4ModelRef(model) {
|
|
103
|
+
return model.provider === "deepseek" && typeof model.id === "string" && isDeepSeekV4ModelId(model.id);
|
|
104
|
+
}
|
|
105
|
+
//#endregion
|
|
106
|
+
export { isDeepSeekV4ModelRef as a, isDeepSeekV4ModelId as i, DEEPSEEK_MODEL_CATALOG as n, buildDeepSeekModelDefinition as r, DEEPSEEK_BASE_URL as t };
|
package/dist/models.js
ADDED
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
import { a as isDeepSeekV4ModelRef, i as isDeepSeekV4ModelId, n as DEEPSEEK_MODEL_CATALOG, r as buildDeepSeekModelDefinition, t as DEEPSEEK_BASE_URL } from "./models-DCxTAfJ0.js";
|
|
2
|
+
export { DEEPSEEK_BASE_URL, DEEPSEEK_MODEL_CATALOG, buildDeepSeekModelDefinition, isDeepSeekV4ModelId, isDeepSeekV4ModelRef };
|
package/dist/onboard.js
ADDED
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { n as DEEPSEEK_MODEL_CATALOG, r as buildDeepSeekModelDefinition, t as DEEPSEEK_BASE_URL } from "./models-DCxTAfJ0.js";
|
|
2
|
+
import "./api.js";
|
|
3
|
+
import { applyAgentDefaultModelPrimary, applyProviderConfigWithModelCatalog } from "openclaw/plugin-sdk/provider-onboard";
|
|
4
|
+
//#region extensions/deepseek/onboard.ts
|
|
5
|
+
const DEEPSEEK_DEFAULT_MODEL_REF = "deepseek/deepseek-v4-flash";
|
|
6
|
+
function applyDeepSeekProviderConfig(cfg) {
|
|
7
|
+
const models = { ...cfg.agents?.defaults?.models };
|
|
8
|
+
models[DEEPSEEK_DEFAULT_MODEL_REF] = {
|
|
9
|
+
...models[DEEPSEEK_DEFAULT_MODEL_REF],
|
|
10
|
+
alias: models["deepseek/deepseek-v4-flash"]?.alias ?? "DeepSeek"
|
|
11
|
+
};
|
|
12
|
+
return applyProviderConfigWithModelCatalog(cfg, {
|
|
13
|
+
agentModels: models,
|
|
14
|
+
providerId: "deepseek",
|
|
15
|
+
api: "openai-completions",
|
|
16
|
+
baseUrl: DEEPSEEK_BASE_URL,
|
|
17
|
+
catalogModels: DEEPSEEK_MODEL_CATALOG.map(buildDeepSeekModelDefinition)
|
|
18
|
+
});
|
|
19
|
+
}
|
|
20
|
+
function applyDeepSeekConfig(cfg) {
|
|
21
|
+
return applyAgentDefaultModelPrimary(applyDeepSeekProviderConfig(cfg), DEEPSEEK_DEFAULT_MODEL_REF);
|
|
22
|
+
}
|
|
23
|
+
//#endregion
|
|
24
|
+
export { DEEPSEEK_DEFAULT_MODEL_REF, applyDeepSeekConfig };
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { n as DEEPSEEK_MODEL_CATALOG, r as buildDeepSeekModelDefinition, t as DEEPSEEK_BASE_URL } from "./models-DCxTAfJ0.js";
|
|
2
|
+
//#region extensions/deepseek/provider-catalog.ts
|
|
3
|
+
function buildDeepSeekProvider() {
|
|
4
|
+
return {
|
|
5
|
+
baseUrl: DEEPSEEK_BASE_URL,
|
|
6
|
+
api: "openai-completions",
|
|
7
|
+
models: DEEPSEEK_MODEL_CATALOG.map(buildDeepSeekModelDefinition)
|
|
8
|
+
};
|
|
9
|
+
}
|
|
10
|
+
//#endregion
|
|
11
|
+
export { buildDeepSeekProvider };
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { buildDeepSeekProvider } from "./provider-catalog.js";
|
|
2
|
+
//#region extensions/deepseek/provider-discovery.ts
|
|
3
|
+
const deepSeekProviderDiscovery = {
|
|
4
|
+
id: "deepseek",
|
|
5
|
+
label: "DeepSeek",
|
|
6
|
+
docsPath: "/providers/deepseek",
|
|
7
|
+
auth: [],
|
|
8
|
+
staticCatalog: {
|
|
9
|
+
order: "simple",
|
|
10
|
+
run: async () => ({ provider: buildDeepSeekProvider() })
|
|
11
|
+
}
|
|
12
|
+
};
|
|
13
|
+
//#endregion
|
|
14
|
+
export { deepSeekProviderDiscovery as default };
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import { n as DEEPSEEK_MODEL_CATALOG } from "./models-DCxTAfJ0.js";
|
|
2
|
+
import { resolveDeepSeekV4ThinkingProfile } from "./thinking.js";
|
|
3
|
+
//#region extensions/deepseek/provider-policy-api.ts
|
|
4
|
+
/**
|
|
5
|
+
* Build a lookup from the bundled DeepSeek model catalog so we can hydrate
|
|
6
|
+
* missing metadata (contextWindow, cost, maxTokens) into user-configured
|
|
7
|
+
* model rows without overwriting explicit overrides.
|
|
8
|
+
*/
|
|
9
|
+
function buildCatalogIndex() {
|
|
10
|
+
const index = /* @__PURE__ */ new Map();
|
|
11
|
+
for (const model of DEEPSEEK_MODEL_CATALOG) index.set(model.id, model);
|
|
12
|
+
return index;
|
|
13
|
+
}
|
|
14
|
+
function isPositiveNumber(value) {
|
|
15
|
+
return typeof value === "number" && Number.isFinite(value) && value > 0;
|
|
16
|
+
}
|
|
17
|
+
function hasCostValues(cost) {
|
|
18
|
+
if (!cost || typeof cost !== "object") return false;
|
|
19
|
+
const c = cost;
|
|
20
|
+
return typeof c.input === "number" || typeof c.output === "number" || typeof c.cacheRead === "number" || typeof c.cacheWrite === "number";
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Provider policy surface for DeepSeek.
|
|
24
|
+
*
|
|
25
|
+
* Hydrates missing `contextWindow`, `cost`, and `maxTokens` from the bundled
|
|
26
|
+
* catalog for matching model ids. Explicit user overrides are preserved.
|
|
27
|
+
*/
|
|
28
|
+
function normalizeConfig(params) {
|
|
29
|
+
const { providerConfig } = params;
|
|
30
|
+
if (!Array.isArray(providerConfig.models) || providerConfig.models.length === 0) return providerConfig;
|
|
31
|
+
const catalog = buildCatalogIndex();
|
|
32
|
+
let mutated = false;
|
|
33
|
+
const nextModels = providerConfig.models.map((model) => {
|
|
34
|
+
const raw = model;
|
|
35
|
+
const catalogEntry = catalog.get(raw.id);
|
|
36
|
+
if (!catalogEntry) return model;
|
|
37
|
+
let modelMutated = false;
|
|
38
|
+
const patched = {};
|
|
39
|
+
if (!isPositiveNumber(raw.contextWindow) && isPositiveNumber(catalogEntry.contextWindow)) {
|
|
40
|
+
patched.contextWindow = catalogEntry.contextWindow;
|
|
41
|
+
modelMutated = true;
|
|
42
|
+
}
|
|
43
|
+
if (!isPositiveNumber(raw.maxTokens) && isPositiveNumber(catalogEntry.maxTokens)) {
|
|
44
|
+
patched.maxTokens = catalogEntry.maxTokens;
|
|
45
|
+
modelMutated = true;
|
|
46
|
+
}
|
|
47
|
+
if (!hasCostValues(raw.cost) && hasCostValues(catalogEntry.cost)) {
|
|
48
|
+
patched.cost = catalogEntry.cost;
|
|
49
|
+
modelMutated = true;
|
|
50
|
+
}
|
|
51
|
+
if (!modelMutated) return model;
|
|
52
|
+
mutated = true;
|
|
53
|
+
return {
|
|
54
|
+
...raw,
|
|
55
|
+
...patched
|
|
56
|
+
};
|
|
57
|
+
});
|
|
58
|
+
if (!mutated) return providerConfig;
|
|
59
|
+
return {
|
|
60
|
+
...providerConfig,
|
|
61
|
+
models: nextModels
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
function resolveThinkingProfile(params) {
|
|
65
|
+
return params.provider.trim().toLowerCase() === "deepseek" ? resolveDeepSeekV4ThinkingProfile(params.modelId) : null;
|
|
66
|
+
}
|
|
67
|
+
//#endregion
|
|
68
|
+
export { normalizeConfig, resolveThinkingProfile };
|
package/dist/stream.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { a as isDeepSeekV4ModelRef } from "./models-DCxTAfJ0.js";
|
|
2
|
+
import { createDeepSeekV4OpenAICompatibleThinkingWrapper } from "openclaw/plugin-sdk/provider-stream-shared";
|
|
3
|
+
//#region extensions/deepseek/stream.ts
|
|
4
|
+
function createDeepSeekV4ThinkingWrapper(baseStreamFn, thinkingLevel) {
|
|
5
|
+
return createDeepSeekV4OpenAICompatibleThinkingWrapper({
|
|
6
|
+
baseStreamFn,
|
|
7
|
+
thinkingLevel,
|
|
8
|
+
shouldPatchModel: isDeepSeekV4ModelRef
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
//#endregion
|
|
12
|
+
export { createDeepSeekV4ThinkingWrapper };
|
package/dist/thinking.js
ADDED
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { i as isDeepSeekV4ModelId } from "./models-DCxTAfJ0.js";
|
|
2
|
+
//#region extensions/deepseek/thinking.ts
|
|
3
|
+
const V4_THINKING_LEVEL_IDS = [
|
|
4
|
+
"off",
|
|
5
|
+
"minimal",
|
|
6
|
+
"low",
|
|
7
|
+
"medium",
|
|
8
|
+
"high",
|
|
9
|
+
"xhigh",
|
|
10
|
+
"max"
|
|
11
|
+
];
|
|
12
|
+
function buildDeepSeekV4ThinkingLevel(id) {
|
|
13
|
+
return { id };
|
|
14
|
+
}
|
|
15
|
+
const DEEPSEEK_V4_THINKING_PROFILE = {
|
|
16
|
+
levels: V4_THINKING_LEVEL_IDS.map(buildDeepSeekV4ThinkingLevel),
|
|
17
|
+
defaultLevel: "high"
|
|
18
|
+
};
|
|
19
|
+
function resolveDeepSeekV4ThinkingProfile(modelId) {
|
|
20
|
+
return isDeepSeekV4ModelId(modelId) ? DEEPSEEK_V4_THINKING_PROFILE : void 0;
|
|
21
|
+
}
|
|
22
|
+
//#endregion
|
|
23
|
+
export { resolveDeepSeekV4ThinkingProfile };
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
{
|
|
2
|
+
"id": "deepseek",
|
|
3
|
+
"activation": {
|
|
4
|
+
"onStartup": false
|
|
5
|
+
},
|
|
6
|
+
"enabledByDefault": true,
|
|
7
|
+
"providerCatalogEntry": "./provider-discovery.ts",
|
|
8
|
+
"providers": ["deepseek"],
|
|
9
|
+
"providerEndpoints": [
|
|
10
|
+
{
|
|
11
|
+
"endpointClass": "deepseek-native",
|
|
12
|
+
"hosts": ["api.deepseek.com"]
|
|
13
|
+
}
|
|
14
|
+
],
|
|
15
|
+
"providerRequest": {
|
|
16
|
+
"providers": {
|
|
17
|
+
"deepseek": {
|
|
18
|
+
"family": "deepseek"
|
|
19
|
+
}
|
|
20
|
+
}
|
|
21
|
+
},
|
|
22
|
+
"modelCatalog": {
|
|
23
|
+
"providers": {
|
|
24
|
+
"deepseek": {
|
|
25
|
+
"baseUrl": "https://api.deepseek.com",
|
|
26
|
+
"api": "openai-completions",
|
|
27
|
+
"models": [
|
|
28
|
+
{
|
|
29
|
+
"id": "deepseek-v4-flash",
|
|
30
|
+
"name": "DeepSeek V4 Flash",
|
|
31
|
+
"reasoning": true,
|
|
32
|
+
"input": ["text"],
|
|
33
|
+
"contextWindow": 1000000,
|
|
34
|
+
"maxTokens": 384000,
|
|
35
|
+
"cost": {
|
|
36
|
+
"input": 0.14,
|
|
37
|
+
"output": 0.28,
|
|
38
|
+
"cacheRead": 0.028,
|
|
39
|
+
"cacheWrite": 0
|
|
40
|
+
},
|
|
41
|
+
"compat": {
|
|
42
|
+
"supportsUsageInStreaming": true,
|
|
43
|
+
"supportsReasoningEffort": true,
|
|
44
|
+
"maxTokensField": "max_tokens"
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
{
|
|
48
|
+
"id": "deepseek-v4-pro",
|
|
49
|
+
"name": "DeepSeek V4 Pro",
|
|
50
|
+
"reasoning": true,
|
|
51
|
+
"input": ["text"],
|
|
52
|
+
"contextWindow": 1000000,
|
|
53
|
+
"maxTokens": 384000,
|
|
54
|
+
"cost": {
|
|
55
|
+
"input": 1.74,
|
|
56
|
+
"output": 3.48,
|
|
57
|
+
"cacheRead": 0.145,
|
|
58
|
+
"cacheWrite": 0
|
|
59
|
+
},
|
|
60
|
+
"compat": {
|
|
61
|
+
"supportsUsageInStreaming": true,
|
|
62
|
+
"supportsReasoningEffort": true,
|
|
63
|
+
"maxTokensField": "max_tokens"
|
|
64
|
+
}
|
|
65
|
+
},
|
|
66
|
+
{
|
|
67
|
+
"id": "deepseek-chat",
|
|
68
|
+
"name": "DeepSeek Chat",
|
|
69
|
+
"input": ["text"],
|
|
70
|
+
"contextWindow": 131072,
|
|
71
|
+
"maxTokens": 8192,
|
|
72
|
+
"cost": {
|
|
73
|
+
"input": 0.28,
|
|
74
|
+
"output": 0.42,
|
|
75
|
+
"cacheRead": 0.028,
|
|
76
|
+
"cacheWrite": 0
|
|
77
|
+
},
|
|
78
|
+
"compat": {
|
|
79
|
+
"supportsUsageInStreaming": true,
|
|
80
|
+
"maxTokensField": "max_tokens"
|
|
81
|
+
}
|
|
82
|
+
},
|
|
83
|
+
{
|
|
84
|
+
"id": "deepseek-reasoner",
|
|
85
|
+
"name": "DeepSeek Reasoner",
|
|
86
|
+
"reasoning": true,
|
|
87
|
+
"input": ["text"],
|
|
88
|
+
"contextWindow": 131072,
|
|
89
|
+
"maxTokens": 65536,
|
|
90
|
+
"cost": {
|
|
91
|
+
"input": 0.28,
|
|
92
|
+
"output": 0.42,
|
|
93
|
+
"cacheRead": 0.028,
|
|
94
|
+
"cacheWrite": 0
|
|
95
|
+
},
|
|
96
|
+
"compat": {
|
|
97
|
+
"supportsUsageInStreaming": true,
|
|
98
|
+
"supportsReasoningEffort": false,
|
|
99
|
+
"maxTokensField": "max_tokens"
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
]
|
|
103
|
+
}
|
|
104
|
+
},
|
|
105
|
+
"discovery": {
|
|
106
|
+
"deepseek": "static"
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
"setup": {
|
|
110
|
+
"providers": [
|
|
111
|
+
{
|
|
112
|
+
"id": "deepseek",
|
|
113
|
+
"envVars": ["DEEPSEEK_API_KEY"]
|
|
114
|
+
}
|
|
115
|
+
]
|
|
116
|
+
},
|
|
117
|
+
"providerAuthChoices": [
|
|
118
|
+
{
|
|
119
|
+
"provider": "deepseek",
|
|
120
|
+
"method": "api-key",
|
|
121
|
+
"choiceId": "deepseek-api-key",
|
|
122
|
+
"choiceLabel": "DeepSeek API key",
|
|
123
|
+
"groupId": "deepseek",
|
|
124
|
+
"groupLabel": "DeepSeek",
|
|
125
|
+
"groupHint": "API key",
|
|
126
|
+
"optionKey": "deepseekApiKey",
|
|
127
|
+
"cliFlag": "--deepseek-api-key",
|
|
128
|
+
"cliOption": "--deepseek-api-key <key>",
|
|
129
|
+
"cliDescription": "DeepSeek API key"
|
|
130
|
+
}
|
|
131
|
+
],
|
|
132
|
+
"configSchema": {
|
|
133
|
+
"type": "object",
|
|
134
|
+
"additionalProperties": false,
|
|
135
|
+
"properties": {}
|
|
136
|
+
}
|
|
137
|
+
}
|
package/package.json
CHANGED
|
@@ -1,14 +1,50 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/deepseek-provider",
|
|
3
|
-
"version": "
|
|
4
|
-
"description": "
|
|
5
|
-
"license": "MIT",
|
|
3
|
+
"version": "2026.6.9-beta.1",
|
|
4
|
+
"description": "OpenClaw DeepSeek provider plugin.",
|
|
6
5
|
"repository": {
|
|
7
6
|
"type": "git",
|
|
8
|
-
"url": "
|
|
7
|
+
"url": "https://github.com/openclaw/openclaw"
|
|
9
8
|
},
|
|
10
|
-
"
|
|
11
|
-
|
|
12
|
-
"
|
|
13
|
-
|
|
9
|
+
"type": "module",
|
|
10
|
+
"openclaw": {
|
|
11
|
+
"extensions": [
|
|
12
|
+
"./index.ts"
|
|
13
|
+
],
|
|
14
|
+
"install": {
|
|
15
|
+
"clawhubSpec": "clawhub:@openclaw/deepseek-provider",
|
|
16
|
+
"npmSpec": "@openclaw/deepseek-provider",
|
|
17
|
+
"defaultChoice": "npm",
|
|
18
|
+
"minHostVersion": ">=2026.6.8"
|
|
19
|
+
},
|
|
20
|
+
"compat": {
|
|
21
|
+
"pluginApi": ">=2026.6.9-beta.1"
|
|
22
|
+
},
|
|
23
|
+
"build": {
|
|
24
|
+
"openclawVersion": "2026.6.9-beta.1",
|
|
25
|
+
"bundledDist": false
|
|
26
|
+
},
|
|
27
|
+
"release": {
|
|
28
|
+
"publishToClawHub": true,
|
|
29
|
+
"publishToNpm": true
|
|
30
|
+
},
|
|
31
|
+
"runtimeExtensions": [
|
|
32
|
+
"./dist/index.js"
|
|
33
|
+
]
|
|
34
|
+
},
|
|
35
|
+
"files": [
|
|
36
|
+
"dist/**",
|
|
37
|
+
"openclaw.plugin.json",
|
|
38
|
+
"npm-shrinkwrap.json",
|
|
39
|
+
"README.md"
|
|
40
|
+
],
|
|
41
|
+
"peerDependencies": {
|
|
42
|
+
"openclaw": ">=2026.6.9-beta.1"
|
|
43
|
+
},
|
|
44
|
+
"peerDependenciesMeta": {
|
|
45
|
+
"openclaw": {
|
|
46
|
+
"optional": true
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"bundledDependencies": []
|
|
14
50
|
}
|