@openclaw/qianfan-provider 2026.7.2-beta.7 → 2026.7.34

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.
@@ -0,0 +1,48 @@
1
+ import { buildManifestModelProviderConfig } from "openclaw/plugin-sdk/provider-catalog-shared";
2
+ //#region extensions/qianfan/openclaw.plugin.json
3
+ var modelCatalog = {
4
+ "providers": { "qianfan": {
5
+ "baseUrl": "https://qianfan.baidubce.com/v2",
6
+ "api": "openai-completions",
7
+ "models": [{
8
+ "id": "deepseek-v3.2",
9
+ "name": "DEEPSEEK V3.2",
10
+ "input": ["text"],
11
+ "reasoning": true,
12
+ "contextWindow": 98304,
13
+ "maxTokens": 32768,
14
+ "cost": {
15
+ "input": 0,
16
+ "output": 0,
17
+ "cacheRead": 0,
18
+ "cacheWrite": 0
19
+ }
20
+ }, {
21
+ "id": "ernie-5.0-thinking-preview",
22
+ "name": "ERNIE-5.0-Thinking-Preview",
23
+ "input": ["text", "image"],
24
+ "reasoning": true,
25
+ "contextWindow": 119e3,
26
+ "maxTokens": 64e3,
27
+ "cost": {
28
+ "input": 0,
29
+ "output": 0,
30
+ "cacheRead": 0,
31
+ "cacheWrite": 0
32
+ }
33
+ }]
34
+ } },
35
+ "discovery": { "qianfan": "static" }
36
+ };
37
+ //#endregion
38
+ //#region extensions/qianfan/provider-catalog.ts
39
+ const QIANFAN_BASE_URL = "https://qianfan.baidubce.com/v2";
40
+ const QIANFAN_DEFAULT_MODEL_ID = "deepseek-v3.2";
41
+ function buildQianfanProvider() {
42
+ return buildManifestModelProviderConfig({
43
+ providerId: "qianfan",
44
+ catalog: modelCatalog.providers.qianfan
45
+ });
46
+ }
47
+ //#endregion
48
+ export { QIANFAN_DEFAULT_MODEL_ID as n, buildQianfanProvider as r, QIANFAN_BASE_URL as t };
package/dist/api.js CHANGED
@@ -1,3 +1,3 @@
1
- import { n as QIANFAN_DEFAULT_MODEL_ID, r as buildQianfanProvider, t as QIANFAN_BASE_URL } from "./provider-catalog-lJjGnZjf.js";
1
+ import { n as QIANFAN_DEFAULT_MODEL_ID, r as buildQianfanProvider, t as QIANFAN_BASE_URL } from "./.setup/provider-catalog-CFKdseZa.mjs";
2
2
  import { QIANFAN_DEFAULT_MODEL_REF } from "./onboard.js";
3
3
  export { QIANFAN_BASE_URL, QIANFAN_DEFAULT_MODEL_ID, QIANFAN_DEFAULT_MODEL_REF, buildQianfanProvider };
package/dist/index.js CHANGED
@@ -1,19 +1,25 @@
1
- import { i as openclaw_plugin_default } from "./provider-catalog-lJjGnZjf.js";
1
+ import { r as buildQianfanProvider } from "./.setup/provider-catalog-CFKdseZa.mjs";
2
2
  import { QIANFAN_DEFAULT_MODEL_REF, applyQianfanConfig } from "./onboard.js";
3
3
  import { defineSingleProviderPluginEntry } from "openclaw/plugin-sdk/provider-entry";
4
4
  var qianfan_default = defineSingleProviderPluginEntry({
5
5
  id: "qianfan",
6
6
  name: "Qianfan Provider",
7
7
  description: "Bundled Qianfan provider plugin",
8
- manifest: openclaw_plugin_default,
9
8
  provider: {
10
9
  label: "Qianfan",
11
10
  docsPath: "/providers/qianfan",
12
- manifestAuth: {
11
+ auth: [{
12
+ methodId: "api-key",
13
+ label: "Qianfan API key",
14
+ hint: "API key",
15
+ optionKey: "qianfanApiKey",
16
+ flagName: "--qianfan-api-key",
17
+ envVar: "QIANFAN_API_KEY",
18
+ promptMessage: "Enter Qianfan API key",
13
19
  defaultModel: QIANFAN_DEFAULT_MODEL_REF,
14
- applyConfig: applyQianfanConfig
15
- },
16
- catalog: { liveModelDiscovery: true }
20
+ applyConfig: (cfg) => applyQianfanConfig(cfg)
21
+ }],
22
+ catalog: { buildProvider: buildQianfanProvider }
17
23
  }
18
24
  });
19
25
  //#endregion
package/dist/onboard.js CHANGED
@@ -1,4 +1,4 @@
1
- import { n as QIANFAN_DEFAULT_MODEL_ID, r as buildQianfanProvider } from "./provider-catalog-lJjGnZjf.js";
1
+ import { n as QIANFAN_DEFAULT_MODEL_ID, r as buildQianfanProvider } from "./.setup/provider-catalog-CFKdseZa.mjs";
2
2
  import { createDefaultModelsPresetAppliers } from "openclaw/plugin-sdk/provider-onboard";
3
3
  //#region extensions/qianfan/onboard.ts
4
4
  const QIANFAN_DEFAULT_MODEL_REF = `qianfan/${QIANFAN_DEFAULT_MODEL_ID}`;
@@ -12,7 +12,7 @@ function resolveQianfanPreset(cfg) {
12
12
  defaultModels: defaultProvider.models ?? []
13
13
  };
14
14
  }
15
- const { applyConfig: applyQianfanConfig } = createDefaultModelsPresetAppliers({
15
+ const qianfanPresetAppliers = createDefaultModelsPresetAppliers({
16
16
  primaryModelRef: QIANFAN_DEFAULT_MODEL_REF,
17
17
  resolveParams: (cfg) => {
18
18
  const preset = resolveQianfanPreset(cfg);
@@ -29,5 +29,11 @@ const { applyConfig: applyQianfanConfig } = createDefaultModelsPresetAppliers({
29
29
  };
30
30
  }
31
31
  });
32
+ function applyQianfanProviderConfig(cfg) {
33
+ return qianfanPresetAppliers.applyProviderConfig(cfg);
34
+ }
35
+ function applyQianfanConfig(cfg) {
36
+ return qianfanPresetAppliers.applyConfig(cfg);
37
+ }
32
38
  //#endregion
33
- export { QIANFAN_DEFAULT_MODEL_REF, applyQianfanConfig };
39
+ export { QIANFAN_DEFAULT_MODEL_REF, applyQianfanConfig, applyQianfanProviderConfig };
@@ -1,2 +1,2 @@
1
- import { n as QIANFAN_DEFAULT_MODEL_ID, r as buildQianfanProvider, t as QIANFAN_BASE_URL } from "./provider-catalog-lJjGnZjf.js";
1
+ import { n as QIANFAN_DEFAULT_MODEL_ID, r as buildQianfanProvider, t as QIANFAN_BASE_URL } from "./.setup/provider-catalog-CFKdseZa.mjs";
2
2
  export { QIANFAN_BASE_URL, QIANFAN_DEFAULT_MODEL_ID, buildQianfanProvider };
@@ -22,153 +22,38 @@
22
22
  "api": "openai-completions",
23
23
  "models": [
24
24
  {
25
- "id": "deepseek-v4-pro",
26
- "name": "DeepSeek V4 Pro",
27
- "input": ["text"],
28
- "reasoning": true,
29
- "contextWindow": 1000000,
30
- "maxTokens": 393216,
31
- "cost": {
32
- "input": 1.771957,
33
- "output": 3.543915,
34
- "cacheRead": 0.147663,
35
- "cacheWrite": 0
36
- },
37
- "compat": {
38
- "codeMode": "capable"
39
- }
40
- },
41
- {
42
- "id": "ernie-5.1",
43
- "name": "ERNIE 5.1",
25
+ "id": "deepseek-v3.2",
26
+ "name": "DEEPSEEK V3.2",
44
27
  "input": ["text"],
45
- "reasoning": false,
46
- "contextWindow": 128000,
47
- "maxTokens": 65536,
48
- "cost": {
49
- "input": 0.590652,
50
- "output": 2.657936,
51
- "cacheRead": 0,
52
- "cacheWrite": 0,
53
- "tieredPricing": [
54
- {
55
- "input": 0.590652,
56
- "output": 2.657936,
57
- "cacheRead": 0,
58
- "cacheWrite": 0,
59
- "range": [0, 32001]
60
- },
61
- {
62
- "input": 0.885979,
63
- "output": 3.248589,
64
- "cacheRead": 0,
65
- "cacheWrite": 0,
66
- "range": [32001]
67
- }
68
- ]
69
- }
70
- },
71
- {
72
- "id": "ernie-5.0",
73
- "name": "ERNIE 5.0",
74
- "input": ["text", "image"],
75
28
  "reasoning": true,
76
- "contextWindow": 128000,
77
- "maxTokens": 65536,
29
+ "contextWindow": 98304,
30
+ "maxTokens": 32768,
78
31
  "cost": {
79
- "input": 0.885979,
80
- "output": 3.543915,
32
+ "input": 0,
33
+ "output": 0,
81
34
  "cacheRead": 0,
82
- "cacheWrite": 0,
83
- "tieredPricing": [
84
- {
85
- "input": 0.885979,
86
- "output": 3.543915,
87
- "cacheRead": 0,
88
- "cacheWrite": 0,
89
- "range": [0, 32001]
90
- },
91
- {
92
- "input": 1.476631,
93
- "output": 5.906525,
94
- "cacheRead": 0,
95
- "cacheWrite": 0,
96
- "range": [32001]
97
- }
98
- ]
35
+ "cacheWrite": 0
99
36
  }
100
37
  },
101
- {
102
- "id": "deepseek-v3.2",
103
- "name": "DeepSeek V3.2",
104
- "input": ["text"],
105
- "reasoning": false,
106
- "contextWindow": 128000,
107
- "maxTokens": 32768,
108
- "cost": {
109
- "input": 0.295326,
110
- "output": 0.442989,
111
- "cacheRead": 0.059065,
112
- "cacheWrite": 0,
113
- "tieredPricing": [
114
- {
115
- "input": 0.295326,
116
- "output": 0.442989,
117
- "cacheRead": 0.059065,
118
- "cacheWrite": 0,
119
- "range": [0, 32001]
120
- },
121
- {
122
- "input": 0.590652,
123
- "output": 0.885979,
124
- "cacheRead": 0.059065,
125
- "cacheWrite": 0,
126
- "range": [32001]
127
- }
128
- ]
129
- },
130
- "status": "deprecated",
131
- "statusReason": "Still available by exact reference; use deepseek-v4-pro for new Qianfan setups.",
132
- "replacedBy": "deepseek-v4-pro"
133
- },
134
38
  {
135
39
  "id": "ernie-5.0-thinking-preview",
136
40
  "name": "ERNIE-5.0-Thinking-Preview",
137
41
  "input": ["text", "image"],
138
42
  "reasoning": true,
139
- "contextWindow": 128000,
140
- "maxTokens": 65536,
43
+ "contextWindow": 119000,
44
+ "maxTokens": 64000,
141
45
  "cost": {
142
- "input": 0.885979,
143
- "output": 3.543915,
46
+ "input": 0,
47
+ "output": 0,
144
48
  "cacheRead": 0,
145
- "cacheWrite": 0,
146
- "tieredPricing": [
147
- {
148
- "input": 0.885979,
149
- "output": 3.543915,
150
- "cacheRead": 0,
151
- "cacheWrite": 0,
152
- "range": [0, 32001]
153
- },
154
- {
155
- "input": 1.476631,
156
- "output": 5.906525,
157
- "cacheRead": 0,
158
- "cacheWrite": 0,
159
- "range": [32001]
160
- }
161
- ]
162
- },
163
- "status": "deprecated",
164
- "statusReason": "Still available by exact reference; use the stable ernie-5.0 id for new Qianfan setups.",
165
- "replacedBy": "ernie-5.0"
49
+ "cacheWrite": 0
50
+ }
166
51
  }
167
52
  ]
168
53
  }
169
54
  },
170
55
  "discovery": {
171
- "qianfan": "refreshable"
56
+ "qianfan": "static"
172
57
  }
173
58
  },
174
59
  "providerAuthChoices": [
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/qianfan-provider",
3
- "version": "2026.7.2-beta.7",
3
+ "version": "2026.7.34",
4
4
  "description": "OpenClaw Qianfan provider plugin.",
5
5
  "repository": {
6
6
  "type": "git",
@@ -18,10 +18,10 @@
18
18
  "minHostVersion": ">=2026.6.8"
19
19
  },
20
20
  "compat": {
21
- "pluginApi": ">=2026.7.2-beta.7"
21
+ "pluginApi": ">=2026.7.34"
22
22
  },
23
23
  "build": {
24
- "openclawVersion": "2026.7.2-beta.7",
24
+ "openclawVersion": "2026.7.34",
25
25
  "bundledDist": false
26
26
  },
27
27
  "release": {
@@ -38,7 +38,7 @@
38
38
  "README.md"
39
39
  ],
40
40
  "peerDependencies": {
41
- "openclaw": ">=2026.7.2-beta.7"
41
+ "openclaw": ">=2026.7.34"
42
42
  },
43
43
  "peerDependenciesMeta": {
44
44
  "openclaw": {
@@ -1,183 +0,0 @@
1
- import { buildManifestModelProviderConfig } from "openclaw/plugin-sdk/provider-catalog-shared";
2
- //#region extensions/qianfan/openclaw.plugin.json
3
- var openclaw_plugin_default = {
4
- id: "qianfan",
5
- icon: "https://cdn.simpleicons.org/baidu",
6
- activation: { "onStartup": false },
7
- enabledByDefault: true,
8
- providers: ["qianfan"],
9
- setup: { "providers": [{
10
- "id": "qianfan",
11
- "authMethods": ["api-key"],
12
- "envVars": ["QIANFAN_API_KEY"]
13
- }] },
14
- modelCatalog: {
15
- "providers": { "qianfan": {
16
- "baseUrl": "https://qianfan.baidubce.com/v2",
17
- "api": "openai-completions",
18
- "models": [
19
- {
20
- "id": "deepseek-v4-pro",
21
- "name": "DeepSeek V4 Pro",
22
- "input": ["text"],
23
- "reasoning": true,
24
- "contextWindow": 1e6,
25
- "maxTokens": 393216,
26
- "cost": {
27
- "input": 1.771957,
28
- "output": 3.543915,
29
- "cacheRead": .147663,
30
- "cacheWrite": 0
31
- },
32
- "compat": { "codeMode": "capable" }
33
- },
34
- {
35
- "id": "ernie-5.1",
36
- "name": "ERNIE 5.1",
37
- "input": ["text"],
38
- "reasoning": false,
39
- "contextWindow": 128e3,
40
- "maxTokens": 65536,
41
- "cost": {
42
- "input": .590652,
43
- "output": 2.657936,
44
- "cacheRead": 0,
45
- "cacheWrite": 0,
46
- "tieredPricing": [{
47
- "input": .590652,
48
- "output": 2.657936,
49
- "cacheRead": 0,
50
- "cacheWrite": 0,
51
- "range": [0, 32001]
52
- }, {
53
- "input": .885979,
54
- "output": 3.248589,
55
- "cacheRead": 0,
56
- "cacheWrite": 0,
57
- "range": [32001]
58
- }]
59
- }
60
- },
61
- {
62
- "id": "ernie-5.0",
63
- "name": "ERNIE 5.0",
64
- "input": ["text", "image"],
65
- "reasoning": true,
66
- "contextWindow": 128e3,
67
- "maxTokens": 65536,
68
- "cost": {
69
- "input": .885979,
70
- "output": 3.543915,
71
- "cacheRead": 0,
72
- "cacheWrite": 0,
73
- "tieredPricing": [{
74
- "input": .885979,
75
- "output": 3.543915,
76
- "cacheRead": 0,
77
- "cacheWrite": 0,
78
- "range": [0, 32001]
79
- }, {
80
- "input": 1.476631,
81
- "output": 5.906525,
82
- "cacheRead": 0,
83
- "cacheWrite": 0,
84
- "range": [32001]
85
- }]
86
- }
87
- },
88
- {
89
- "id": "deepseek-v3.2",
90
- "name": "DeepSeek V3.2",
91
- "input": ["text"],
92
- "reasoning": false,
93
- "contextWindow": 128e3,
94
- "maxTokens": 32768,
95
- "cost": {
96
- "input": .295326,
97
- "output": .442989,
98
- "cacheRead": .059065,
99
- "cacheWrite": 0,
100
- "tieredPricing": [{
101
- "input": .295326,
102
- "output": .442989,
103
- "cacheRead": .059065,
104
- "cacheWrite": 0,
105
- "range": [0, 32001]
106
- }, {
107
- "input": .590652,
108
- "output": .885979,
109
- "cacheRead": .059065,
110
- "cacheWrite": 0,
111
- "range": [32001]
112
- }]
113
- },
114
- "status": "deprecated",
115
- "statusReason": "Still available by exact reference; use deepseek-v4-pro for new Qianfan setups.",
116
- "replacedBy": "deepseek-v4-pro"
117
- },
118
- {
119
- "id": "ernie-5.0-thinking-preview",
120
- "name": "ERNIE-5.0-Thinking-Preview",
121
- "input": ["text", "image"],
122
- "reasoning": true,
123
- "contextWindow": 128e3,
124
- "maxTokens": 65536,
125
- "cost": {
126
- "input": .885979,
127
- "output": 3.543915,
128
- "cacheRead": 0,
129
- "cacheWrite": 0,
130
- "tieredPricing": [{
131
- "input": .885979,
132
- "output": 3.543915,
133
- "cacheRead": 0,
134
- "cacheWrite": 0,
135
- "range": [0, 32001]
136
- }, {
137
- "input": 1.476631,
138
- "output": 5.906525,
139
- "cacheRead": 0,
140
- "cacheWrite": 0,
141
- "range": [32001]
142
- }]
143
- },
144
- "status": "deprecated",
145
- "statusReason": "Still available by exact reference; use the stable ernie-5.0 id for new Qianfan setups.",
146
- "replacedBy": "ernie-5.0"
147
- }
148
- ]
149
- } },
150
- "discovery": { "qianfan": "refreshable" }
151
- },
152
- providerAuthChoices: [{
153
- "provider": "qianfan",
154
- "method": "api-key",
155
- "choiceId": "qianfan-api-key",
156
- "appGuidedSecret": true,
157
- "choiceLabel": "Qianfan API key",
158
- "groupId": "qianfan",
159
- "groupLabel": "Qianfan",
160
- "groupHint": "API key",
161
- "optionKey": "qianfanApiKey",
162
- "cliFlag": "--qianfan-api-key",
163
- "cliOption": "--qianfan-api-key <key>",
164
- "cliDescription": "QIANFAN API key"
165
- }],
166
- configSchema: {
167
- "type": "object",
168
- "additionalProperties": false,
169
- "properties": {}
170
- }
171
- };
172
- //#endregion
173
- //#region extensions/qianfan/provider-catalog.ts
174
- const QIANFAN_BASE_URL = "https://qianfan.baidubce.com/v2";
175
- const QIANFAN_DEFAULT_MODEL_ID = "deepseek-v4-pro";
176
- function buildQianfanProvider() {
177
- return buildManifestModelProviderConfig({
178
- providerId: "qianfan",
179
- catalog: openclaw_plugin_default.modelCatalog.providers.qianfan
180
- });
181
- }
182
- //#endregion
183
- export { openclaw_plugin_default as i, QIANFAN_DEFAULT_MODEL_ID as n, buildQianfanProvider as r, QIANFAN_BASE_URL as t };