@openclaw/qwen-provider 2026.7.2-beta.5 → 2026.8.1-beta.2
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/dist/index.js +5 -7
- package/dist/models.js +140 -165
- package/dist/stream.js +4 -6
- package/dist/video-generation-provider.js +31 -65
- package/package.json +4 -4
package/dist/index.js
CHANGED
|
@@ -4,10 +4,11 @@ import { wrapQwenProviderStream } from "./stream.js";
|
|
|
4
4
|
import "./api.js";
|
|
5
5
|
import { buildQwenMediaUnderstandingProvider } from "./media-understanding-provider.js";
|
|
6
6
|
import { applyQwenConfig, applyQwenConfigCn, applyQwenStandardConfig, applyQwenStandardConfigCn, applyQwenTokenPlanConfig } from "./onboard.js";
|
|
7
|
-
import {
|
|
7
|
+
import { qwenVideoGenerationProvider } from "./video-generation-provider.js";
|
|
8
8
|
import { createProviderApiKeyAuthMethod } from "openclaw/plugin-sdk/provider-auth-api-key";
|
|
9
9
|
import { buildOpenAICompatibleLiveModelProviderConfig } from "openclaw/plugin-sdk/provider-catalog-live-runtime";
|
|
10
10
|
import { defineSingleProviderPluginEntry } from "openclaw/plugin-sdk/provider-entry";
|
|
11
|
+
import { normalizeLowercaseStringOrEmpty } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
11
12
|
//#region extensions/qwen/index.ts
|
|
12
13
|
const PROVIDER_ID = "qwen";
|
|
13
14
|
const LEGACY_PROVIDER_ID = "modelstudio";
|
|
@@ -21,14 +22,11 @@ const QWEN_TOKEN_PLAN_THINKING_LEVEL_IDS = [
|
|
|
21
22
|
"max"
|
|
22
23
|
];
|
|
23
24
|
const QWEN_TOKEN_PLAN_GLM_NO_MAX_THINKING_LEVEL_IDS = QWEN_TOKEN_PLAN_THINKING_LEVEL_IDS.filter((id) => id !== "max");
|
|
24
|
-
function normalizeProviderId(value) {
|
|
25
|
-
return value.trim().toLowerCase();
|
|
26
|
-
}
|
|
27
25
|
function resolveConfiguredQwenBaseUrl(config) {
|
|
28
26
|
const providers = config?.models?.providers;
|
|
29
27
|
if (!providers) return;
|
|
30
28
|
for (const [providerId, provider] of Object.entries(providers)) {
|
|
31
|
-
const normalized =
|
|
29
|
+
const normalized = normalizeLowercaseStringOrEmpty(providerId);
|
|
32
30
|
if (normalized !== PROVIDER_ID && normalized !== LEGACY_PROVIDER_ID) continue;
|
|
33
31
|
const baseUrl = provider?.baseUrl?.trim();
|
|
34
32
|
if (baseUrl) return baseUrl;
|
|
@@ -38,7 +36,7 @@ function resolveConfiguredQwenTokenPlanBaseUrl(config) {
|
|
|
38
36
|
const providers = config?.models?.providers;
|
|
39
37
|
if (!providers) return;
|
|
40
38
|
for (const [providerId, provider] of Object.entries(providers)) {
|
|
41
|
-
if (
|
|
39
|
+
if (normalizeLowercaseStringOrEmpty(providerId) !== "qwen-token-plan") continue;
|
|
42
40
|
const baseUrl = provider?.baseUrl?.trim();
|
|
43
41
|
if (baseUrl) return baseUrl;
|
|
44
42
|
}
|
|
@@ -250,7 +248,7 @@ var qwen_default = defineSingleProviderPluginEntry({
|
|
|
250
248
|
wrapStreamFn: wrapQwenProviderStream
|
|
251
249
|
});
|
|
252
250
|
api.registerMediaUnderstandingProvider(buildQwenMediaUnderstandingProvider());
|
|
253
|
-
api.registerVideoGenerationProvider(
|
|
251
|
+
api.registerVideoGenerationProvider(qwenVideoGenerationProvider);
|
|
254
252
|
}
|
|
255
253
|
});
|
|
256
254
|
//#endregion
|
package/dist/models.js
CHANGED
|
@@ -46,172 +46,147 @@ const QWEN_TOKEN_PLAN_BASE_URLS = {
|
|
|
46
46
|
function resolveQwenTokenPlanBaseUrl(region) {
|
|
47
47
|
return QWEN_TOKEN_PLAN_BASE_URLS[region];
|
|
48
48
|
}
|
|
49
|
-
|
|
50
|
-
{
|
|
51
|
-
id
|
|
52
|
-
name:
|
|
53
|
-
reasoning
|
|
54
|
-
input
|
|
49
|
+
function buildQwenCatalogModels(rows) {
|
|
50
|
+
return rows.map(([id, reasoning, input, contextWindow, maxTokens]) => ({
|
|
51
|
+
id,
|
|
52
|
+
name: id,
|
|
53
|
+
reasoning,
|
|
54
|
+
input,
|
|
55
55
|
cost: QWEN_DEFAULT_COST,
|
|
56
|
-
contextWindow
|
|
57
|
-
maxTokens
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
reasoning: false,
|
|
191
|
-
input: ["text"],
|
|
192
|
-
cost: QWEN_DEFAULT_COST,
|
|
193
|
-
contextWindow: 202752,
|
|
194
|
-
maxTokens: 16384
|
|
195
|
-
},
|
|
196
|
-
{
|
|
197
|
-
id: "glm-4.7",
|
|
198
|
-
name: "glm-4.7",
|
|
199
|
-
reasoning: false,
|
|
200
|
-
input: ["text"],
|
|
201
|
-
cost: QWEN_DEFAULT_COST,
|
|
202
|
-
contextWindow: 202752,
|
|
203
|
-
maxTokens: 16384
|
|
204
|
-
},
|
|
205
|
-
{
|
|
206
|
-
id: "kimi-k2.5",
|
|
207
|
-
name: "kimi-k2.5",
|
|
208
|
-
reasoning: false,
|
|
209
|
-
input: ["text", "image"],
|
|
210
|
-
cost: QWEN_DEFAULT_COST,
|
|
211
|
-
contextWindow: 262144,
|
|
212
|
-
maxTokens: 32768
|
|
213
|
-
}
|
|
214
|
-
];
|
|
56
|
+
contextWindow,
|
|
57
|
+
maxTokens
|
|
58
|
+
}));
|
|
59
|
+
}
|
|
60
|
+
const QWEN_TOKEN_PLAN_MODEL_CATALOG = buildQwenCatalogModels([
|
|
61
|
+
[
|
|
62
|
+
QWEN_37_PLUS_MODEL_ID,
|
|
63
|
+
true,
|
|
64
|
+
["text", "image"],
|
|
65
|
+
1e6,
|
|
66
|
+
65536
|
|
67
|
+
],
|
|
68
|
+
[
|
|
69
|
+
QWEN_36_PLUS_MODEL_ID,
|
|
70
|
+
true,
|
|
71
|
+
["text", "image"],
|
|
72
|
+
1e6,
|
|
73
|
+
65536
|
|
74
|
+
],
|
|
75
|
+
[
|
|
76
|
+
"qwen3-coder-next",
|
|
77
|
+
true,
|
|
78
|
+
["text"],
|
|
79
|
+
262144,
|
|
80
|
+
65536
|
|
81
|
+
],
|
|
82
|
+
[
|
|
83
|
+
"kimi-k2.5",
|
|
84
|
+
true,
|
|
85
|
+
["text", "image"],
|
|
86
|
+
262144,
|
|
87
|
+
98304
|
|
88
|
+
],
|
|
89
|
+
[
|
|
90
|
+
"glm-5",
|
|
91
|
+
true,
|
|
92
|
+
["text"],
|
|
93
|
+
202752,
|
|
94
|
+
16384
|
|
95
|
+
],
|
|
96
|
+
[
|
|
97
|
+
"MiniMax-M2.5",
|
|
98
|
+
true,
|
|
99
|
+
["text"],
|
|
100
|
+
196608,
|
|
101
|
+
32768
|
|
102
|
+
]
|
|
103
|
+
]);
|
|
104
|
+
const QWEN_MODEL_CATALOG = buildQwenCatalogModels([
|
|
105
|
+
[
|
|
106
|
+
QWEN_DEFAULT_MODEL_ID,
|
|
107
|
+
false,
|
|
108
|
+
["text", "image"],
|
|
109
|
+
1e6,
|
|
110
|
+
65536
|
|
111
|
+
],
|
|
112
|
+
[
|
|
113
|
+
QWEN_36_FLASH_MODEL_ID,
|
|
114
|
+
true,
|
|
115
|
+
["text", "image"],
|
|
116
|
+
1e6,
|
|
117
|
+
65536
|
|
118
|
+
],
|
|
119
|
+
[
|
|
120
|
+
QWEN_36_PLUS_MODEL_ID,
|
|
121
|
+
true,
|
|
122
|
+
["text", "image"],
|
|
123
|
+
1e6,
|
|
124
|
+
65536
|
|
125
|
+
],
|
|
126
|
+
[
|
|
127
|
+
QWEN_37_MAX_MODEL_ID,
|
|
128
|
+
true,
|
|
129
|
+
["text"],
|
|
130
|
+
1e6,
|
|
131
|
+
65536
|
|
132
|
+
],
|
|
133
|
+
[
|
|
134
|
+
QWEN_37_PLUS_MODEL_ID,
|
|
135
|
+
true,
|
|
136
|
+
["text", "image"],
|
|
137
|
+
1e6,
|
|
138
|
+
65536
|
|
139
|
+
],
|
|
140
|
+
[
|
|
141
|
+
"qwen3-max-2026-01-23",
|
|
142
|
+
false,
|
|
143
|
+
["text"],
|
|
144
|
+
262144,
|
|
145
|
+
65536
|
|
146
|
+
],
|
|
147
|
+
[
|
|
148
|
+
"qwen3-coder-next",
|
|
149
|
+
false,
|
|
150
|
+
["text"],
|
|
151
|
+
262144,
|
|
152
|
+
65536
|
|
153
|
+
],
|
|
154
|
+
[
|
|
155
|
+
"qwen3-coder-plus",
|
|
156
|
+
false,
|
|
157
|
+
["text"],
|
|
158
|
+
1e6,
|
|
159
|
+
65536
|
|
160
|
+
],
|
|
161
|
+
[
|
|
162
|
+
"MiniMax-M2.5",
|
|
163
|
+
true,
|
|
164
|
+
["text"],
|
|
165
|
+
1e6,
|
|
166
|
+
65536
|
|
167
|
+
],
|
|
168
|
+
[
|
|
169
|
+
"glm-5",
|
|
170
|
+
false,
|
|
171
|
+
["text"],
|
|
172
|
+
202752,
|
|
173
|
+
16384
|
|
174
|
+
],
|
|
175
|
+
[
|
|
176
|
+
"glm-4.7",
|
|
177
|
+
false,
|
|
178
|
+
["text"],
|
|
179
|
+
202752,
|
|
180
|
+
16384
|
|
181
|
+
],
|
|
182
|
+
[
|
|
183
|
+
"kimi-k2.5",
|
|
184
|
+
false,
|
|
185
|
+
["text", "image"],
|
|
186
|
+
262144,
|
|
187
|
+
32768
|
|
188
|
+
]
|
|
189
|
+
]);
|
|
215
190
|
function isQwenCodingPlanBaseUrl(baseUrl) {
|
|
216
191
|
const trimmed = baseUrl?.trim();
|
|
217
192
|
if (!trimmed) return false;
|
package/dist/stream.js
CHANGED
|
@@ -1,11 +1,9 @@
|
|
|
1
1
|
import { isQwenTokenPlanDeepSeekV4ModelId, isQwenTokenPlanGlmModelId, isQwenTokenPlanKimiModelId, isQwenTokenPlanThinkingOnlyModelId, supportsQwenTokenPlanGlmMaxThinking } from "./models.js";
|
|
2
|
+
import { asOptionalRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
|
|
2
3
|
import { streamSimple } from "openclaw/plugin-sdk/llm";
|
|
3
4
|
import { normalizeProviderId } from "openclaw/plugin-sdk/provider-model-shared";
|
|
4
5
|
import { createPayloadPatchStreamWrapper, isOpenAICompatibleThinkingEnabled, normalizeOpenAICompatibleReasoningReplay, setQwenChatTemplateThinking } from "openclaw/plugin-sdk/provider-stream-shared";
|
|
5
6
|
//#region extensions/qwen/stream.ts
|
|
6
|
-
function asPayloadRecord(value) {
|
|
7
|
-
return value && typeof value === "object" && !Array.isArray(value) ? value : void 0;
|
|
8
|
-
}
|
|
9
7
|
function resolveQwenThinkingLevel(thinkingLevel, options) {
|
|
10
8
|
const runtimeOptions = options ?? {};
|
|
11
9
|
const raw = runtimeOptions.reasoningEffort ?? runtimeOptions.reasoning ?? thinkingLevel;
|
|
@@ -61,7 +59,7 @@ function patchTokenPlanKimiPayload(payload, enableThinking) {
|
|
|
61
59
|
function normalizeTokenPlanThinkingToolChoice(payload, enableThinking, forceThinking) {
|
|
62
60
|
if (!enableThinking) return false;
|
|
63
61
|
const toolChoice = payload.tool_choice;
|
|
64
|
-
const toolChoiceType =
|
|
62
|
+
const toolChoiceType = asOptionalRecord(toolChoice)?.type;
|
|
65
63
|
if (toolChoiceType === "auto" || toolChoiceType === "none") {
|
|
66
64
|
payload.tool_choice = toolChoiceType;
|
|
67
65
|
return true;
|
|
@@ -95,7 +93,7 @@ function enforceQwenTokenPlanPayloadAfterCaller(payload, tokenPlanContract, forc
|
|
|
95
93
|
delete payload.reasoning;
|
|
96
94
|
}
|
|
97
95
|
function finalizeQwenTokenPlanPayloadAfterCaller(value, fallbackPayload, tokenPlanContract, forceThinking, requestedEnableThinking, requestedThinkingLevel) {
|
|
98
|
-
const finalPayload =
|
|
96
|
+
const finalPayload = asOptionalRecord(value) ?? fallbackPayload;
|
|
99
97
|
if (finalPayload) enforceQwenTokenPlanPayloadAfterCaller(finalPayload, tokenPlanContract, forceThinking, requestedEnableThinking, requestedThinkingLevel);
|
|
100
98
|
return value;
|
|
101
99
|
}
|
|
@@ -112,7 +110,7 @@ function createQwenTokenPlanConstraintWrapper(baseStreamFn, tokenPlanContract, f
|
|
|
112
110
|
return underlying(model, context, {
|
|
113
111
|
...options,
|
|
114
112
|
onPayload(payload, payloadModel) {
|
|
115
|
-
const payloadObj =
|
|
113
|
+
const payloadObj = asOptionalRecord(payload);
|
|
116
114
|
const result = originalOnPayload?.(payload, payloadModel);
|
|
117
115
|
if (result && typeof result.then === "function") return Promise.resolve(result).then((resolved) => finalizeQwenTokenPlanPayloadAfterCaller(resolved, payloadObj, tokenPlanContract, forceThinking, requestedEnableThinking, requestedThinkingLevel));
|
|
118
116
|
return finalizeQwenTokenPlanPayloadAfterCaller(result, payloadObj, tokenPlanContract, forceThinking, requestedEnableThinking, requestedThinkingLevel);
|
|
@@ -1,13 +1,18 @@
|
|
|
1
|
-
import "./models.js";
|
|
2
|
-
import {
|
|
3
|
-
import { isProviderApiKeyConfigured } from "openclaw/plugin-sdk/provider-auth";
|
|
4
|
-
import { resolveApiKeyForProvider } from "openclaw/plugin-sdk/provider-auth-runtime";
|
|
5
|
-
import { DASHSCOPE_WAN_VIDEO_CAPABILITIES, DASHSCOPE_WAN_VIDEO_MODELS, DEFAULT_DASHSCOPE_WAN_VIDEO_MODEL, DEFAULT_VIDEO_GENERATION_TIMEOUT_MS, runDashscopeVideoGenerationTask } from "openclaw/plugin-sdk/video-generation";
|
|
1
|
+
import { isQwenCodingPlanBaseUrl } from "./models.js";
|
|
2
|
+
import { buildDashscopeVideoGenerationProvider } from "openclaw/plugin-sdk/video-generation";
|
|
6
3
|
//#region extensions/qwen/video-generation-provider.ts
|
|
7
4
|
const DEFAULT_QWEN_VIDEO_BASE_URL = "https://dashscope-intl.aliyuncs.com";
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
5
|
+
function isQwenVideoEndpointSupported(baseUrl) {
|
|
6
|
+
if (isQwenCodingPlanBaseUrl(baseUrl)) return false;
|
|
7
|
+
try {
|
|
8
|
+
const hostname = new URL(baseUrl ?? DEFAULT_QWEN_VIDEO_BASE_URL).hostname;
|
|
9
|
+
return !/^token-plan\..+\.maas\.aliyuncs\.com\.?$/iu.test(hostname);
|
|
10
|
+
} catch {
|
|
11
|
+
return true;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
function resolveQwenVideoBaseUrl(configuredBaseUrl) {
|
|
15
|
+
const direct = configuredBaseUrl?.trim();
|
|
11
16
|
if (!direct) return DEFAULT_QWEN_VIDEO_BASE_URL;
|
|
12
17
|
try {
|
|
13
18
|
return new URL(direct).toString();
|
|
@@ -16,63 +21,24 @@ function resolveQwenVideoBaseUrl(req) {
|
|
|
16
21
|
}
|
|
17
22
|
}
|
|
18
23
|
function resolveDashscopeAigcApiBaseUrl(baseUrl) {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
} catch {}
|
|
23
|
-
if (baseUrl.startsWith("https://dashscope.aliyuncs.com/compatible-mode/v1")) return "https://dashscope.aliyuncs.com";
|
|
24
|
-
if (baseUrl.startsWith("https://dashscope-intl.aliyuncs.com/compatible-mode/v1")) return DEFAULT_QWEN_VIDEO_BASE_URL;
|
|
24
|
+
const url = new URL(baseUrl);
|
|
25
|
+
const hostname = url.hostname.toLowerCase().replace(/\.+$/u, "");
|
|
26
|
+
if (/(?:^|\.)dashscope(?:-[^.]+)?\.aliyuncs\.com$/u.test(hostname) || hostname.endsWith(".maas.aliyuncs.com")) return url.origin;
|
|
25
27
|
return baseUrl.replace(/\/+$/u, "");
|
|
26
28
|
}
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
provider: "qwen",
|
|
42
|
-
cfg: req.cfg,
|
|
43
|
-
agentDir: req.agentDir,
|
|
44
|
-
store: req.authStore
|
|
45
|
-
});
|
|
46
|
-
if (!auth.apiKey) throw new Error("Qwen API key missing");
|
|
47
|
-
const providerConfig = req.cfg?.models?.providers?.qwen;
|
|
48
|
-
const { baseUrl, allowPrivateNetwork, headers, dispatcherPolicy } = resolveProviderHttpRequestConfig({
|
|
49
|
-
baseUrl: resolveQwenVideoBaseUrl(req),
|
|
50
|
-
defaultBaseUrl: DEFAULT_QWEN_VIDEO_BASE_URL,
|
|
51
|
-
defaultHeaders: {
|
|
52
|
-
Authorization: `Bearer ${auth.apiKey}`,
|
|
53
|
-
"Content-Type": "application/json",
|
|
54
|
-
"X-DashScope-Async": "enable"
|
|
55
|
-
},
|
|
56
|
-
provider: "qwen",
|
|
57
|
-
capability: "video",
|
|
58
|
-
transport: "http",
|
|
59
|
-
request: sanitizeConfiguredModelProviderRequest(providerConfig?.request)
|
|
60
|
-
});
|
|
61
|
-
return await runDashscopeVideoGenerationTask({
|
|
62
|
-
providerLabel: "Qwen",
|
|
63
|
-
model: req.model?.trim() || DEFAULT_QWEN_VIDEO_MODEL,
|
|
64
|
-
req,
|
|
65
|
-
url: `${resolveDashscopeAigcApiBaseUrl(baseUrl)}/api/v1/services/aigc/video-generation/video-synthesis`,
|
|
66
|
-
headers,
|
|
67
|
-
baseUrl: resolveDashscopeAigcApiBaseUrl(baseUrl),
|
|
68
|
-
timeoutMs: req.timeoutMs,
|
|
69
|
-
fetchFn,
|
|
70
|
-
allowPrivateNetwork,
|
|
71
|
-
dispatcherPolicy,
|
|
72
|
-
defaultTimeoutMs: DEFAULT_VIDEO_GENERATION_TIMEOUT_MS
|
|
73
|
-
});
|
|
74
|
-
}
|
|
75
|
-
};
|
|
76
|
-
}
|
|
29
|
+
const qwenVideoGenerationProvider = buildDashscopeVideoGenerationProvider({
|
|
30
|
+
providerId: "qwen",
|
|
31
|
+
label: "Qwen Cloud",
|
|
32
|
+
taskLabel: "Qwen",
|
|
33
|
+
apiKeyLabel: "Qwen",
|
|
34
|
+
defaultBaseUrl: DEFAULT_QWEN_VIDEO_BASE_URL,
|
|
35
|
+
resolveRequestBaseUrl: resolveQwenVideoBaseUrl,
|
|
36
|
+
resolveAigcBaseUrl: resolveDashscopeAigcApiBaseUrl,
|
|
37
|
+
credentialPolicy: {
|
|
38
|
+
acceptsApiKey: (apiKey) => !apiKey.trim().startsWith("sk-sp-"),
|
|
39
|
+
acceptsBaseUrl: isQwenVideoEndpointSupported,
|
|
40
|
+
unsupportedMessage: "Qwen Wan video generation requires a Standard DashScope endpoint and a same-region Standard API key; Coding Plan and Token Plan credentials are not supported."
|
|
41
|
+
}
|
|
42
|
+
});
|
|
77
43
|
//#endregion
|
|
78
|
-
export {
|
|
44
|
+
export { qwenVideoGenerationProvider };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@openclaw/qwen-provider",
|
|
3
|
-
"version": "2026.
|
|
3
|
+
"version": "2026.8.1-beta.2",
|
|
4
4
|
"description": "OpenClaw Qwen Cloud 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.
|
|
21
|
+
"pluginApi": ">=2026.8.1-beta.2"
|
|
22
22
|
},
|
|
23
23
|
"build": {
|
|
24
|
-
"openclawVersion": "2026.
|
|
24
|
+
"openclawVersion": "2026.8.1-beta.2",
|
|
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.
|
|
41
|
+
"openclaw": ">=2026.8.1-beta.2"
|
|
42
42
|
},
|
|
43
43
|
"peerDependenciesMeta": {
|
|
44
44
|
"openclaw": {
|