@openclaw/deepinfra-provider 2026.9.3 → 2026.9.5

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,32 @@
1
+ <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
2
+ <!--
3
+ Adapted from OpenClaw ui/public/provider-icons/ProviderIcon-deepinfra.svg.
4
+ Source: @lobehub/icons-static-svg@1.94.0, deepinfra.svg
5
+ https://www.npmjs.com/package/@lobehub/icons-static-svg/v/1.94.0
6
+ https://github.com/lobehub/lobe-icons
7
+
8
+ MIT License
9
+ Copyright (c) 2023 LobeHub
10
+
11
+ Permission is hereby granted, free of charge, to any person obtaining a copy
12
+ of this software and associated documentation files (the "Software"), to deal
13
+ in the Software without restriction, including without limitation the rights
14
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
15
+ copies of the Software, and to permit persons to whom the Software is
16
+ furnished to do so, subject to the following conditions:
17
+
18
+ The above copyright notice and this permission notice shall be included in all
19
+ copies or substantial portions of the Software.
20
+
21
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
22
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
23
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
24
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
25
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
26
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
27
+ SOFTWARE.
28
+
29
+ Names and marks remain the property of their respective owners.
30
+ -->
31
+ <path fill="currentColor" fill-rule="evenodd" stroke="none" d="M3.294 7.821A2.297 2.297 0 011 5.527a2.297 2.297 0 012.294-2.295A2.297 2.297 0 015.59 5.527 2.297 2.297 0 013.294 7.82zm0-3.688a1.396 1.396 0 000 2.79 1.396 1.396 0 000-2.79zM3.294 14.293A2.297 2.297 0 011 11.998a2.297 2.297 0 012.294-2.294 2.297 2.297 0 012.295 2.294 2.297 2.297 0 01-2.295 2.295zm0-3.688a1.395 1.395 0 000 2.788 1.395 1.395 0 100-2.788zM3.294 20.761A2.297 2.297 0 011 18.467a2.297 2.297 0 012.294-2.295 2.297 2.297 0 012.295 2.295 2.297 2.297 0 01-2.295 2.294zm0-3.688a1.396 1.396 0 000 2.79 1.396 1.396 0 000-2.79zM20.738 7.821a2.297 2.297 0 01-2.295-2.294 2.297 2.297 0 012.294-2.295 2.297 2.297 0 012.295 2.295 2.297 2.297 0 01-2.294 2.294zm0-3.688a1.396 1.396 0 101.395 1.395c0-.77-.626-1.395-1.395-1.395zM20.738 14.293a2.297 2.297 0 01-2.295-2.295 2.297 2.297 0 012.294-2.294 2.297 2.297 0 012.295 2.294 2.297 2.297 0 01-2.294 2.295zm0-3.688c-.769 0-1.395.625-1.395 1.393a1.396 1.396 0 002.79 0c0-.77-.626-1.393-1.395-1.393zM20.738 20.761a2.297 2.297 0 01-2.295-2.294 2.297 2.297 0 012.294-2.295 2.297 2.297 0 012.295 2.295 2.297 2.297 0 01-2.294 2.294zm0-3.688a1.396 1.396 0 101.395 1.395c0-.77-.626-1.395-1.395-1.395zM12.016 11.057a2.297 2.297 0 01-2.294-2.294 2.297 2.297 0 012.294-2.295 2.297 2.297 0 012.295 2.295 2.297 2.297 0 01-2.295 2.294zm0-3.688a1.396 1.396 0 101.395 1.395c0-.77-.625-1.395-1.395-1.395zM12.017 4.589a2.297 2.297 0 01-2.295-2.295A2.297 2.297 0 0112.017 0a2.297 2.297 0 012.294 2.294 2.297 2.297 0 01-2.294 2.295zm0-3.688a1.396 1.396 0 101.395 1.395c0-.77-.626-1.395-1.395-1.395zM12.017 17.529a2.297 2.297 0 01-2.295-2.295 2.297 2.297 0 012.295-2.294 2.297 2.297 0 012.294 2.294 2.297 2.297 0 01-2.294 2.295zm0-3.688a1.396 1.396 0 101.395 1.395c0-.77-.626-1.395-1.395-1.395zM12.016 24a2.297 2.297 0 01-2.294-2.295 2.297 2.297 0 012.294-2.294 2.297 2.297 0 012.295 2.294A2.297 2.297 0 0112.016 24zm0-3.688a1.396 1.396 0 101.395 1.395c0-.77-.625-1.395-1.395-1.395z M8.363 8.222a.742.742 0 01-.277-.053l-1.494-.596a.75.75 0 11.557-1.392l1.493.595a.75.75 0 01-.278 1.446h-.001zM8.363 14.566a.743.743 0 01-.277-.053l-1.494-.595a.75.75 0 11.557-1.393l1.493.596a.75.75 0 01-.278 1.445h-.001zM17.124 11.397a.741.741 0 01-.277-.054l-1.493-.595a.75.75 0 11.555-1.392l1.493.595a.75.75 0 01-.278 1.446zM17.124 5.05a.744.744 0 01-.277-.054L15.354 4.4a.75.75 0 01.555-1.392l1.493.596a.75.75 0 01-.278 1.445zM17.124 17.739a.743.743 0 01-.277-.053l-1.494-.596a.75.75 0 11.556-1.392l1.493.596a.75.75 0 01-.278 1.445zM6.91 17.966a.75.75 0 01-.279-1.445l1.494-.595a.749.749 0 11.556 1.392l-1.493.595a.743.743 0 01-.277.053H6.91zM6.91 11.66a.75.75 0 01-.279-1.446l1.494-.595a.75.75 0 01.556 1.392l-1.493.595a.743.743 0 01-.277.053H6.91zM6.91 5.033a.75.75 0 01-.279-1.446l1.494-.595a.75.75 0 01.556 1.392l-1.493.596a.744.744 0 01-.277.053H6.91zM8.363 21.364a.743.743 0 01-.277-.053l-1.494-.596a.75.75 0 01.555-1.392l1.494.595a.75.75 0 01-.278 1.446zM15.63 8.223a.75.75 0 01-.278-1.447l1.494-.595a.75.75 0 01.556 1.393l-1.494.595a.744.744 0 01-.276.054h-.002zM15.63 14.567a.75.75 0 01-.278-1.446l1.494-.596a.75.75 0 01.556 1.394l-1.494.595a.743.743 0 01-.276.053h-.002zM15.63 21.363a.749.749 0 01-.278-1.445l1.494-.595a.75.75 0 11.555 1.392l-1.494.595a.741.741 0 01-.277.053z" />
32
+ </svg>
Binary file
package/dist/api.js CHANGED
@@ -1,9 +1,9 @@
1
1
  import { deepinfraEmbeddingProviderAdapter } from "./embedding-adapter.js";
2
2
  import { buildDeepInfraImageGenerationProvider } from "./image-generation-provider.js";
3
3
  import { deepinfraMediaUnderstandingProvider } from "./media-understanding-provider.js";
4
- import { DEEPINFRA_DEFAULT_MODEL_REF } from "./provider-models.js";
4
+ import { DEEPINFRA_DEFAULT_MODEL_REF, buildStaticDeepInfraProvider } from "./provider-static-catalog.js";
5
5
  import { applyDeepInfraConfig } from "./onboard.js";
6
- import { buildDeepInfraProvider, buildStaticDeepInfraProvider } from "./provider-catalog.js";
6
+ import { buildDeepInfraProvider } from "./provider-catalog.js";
7
7
  import { buildDeepInfraSpeechProvider } from "./speech-provider.js";
8
8
  import { buildDeepInfraVideoGenerationProvider } from "./video-generation-provider.js";
9
9
  export { DEEPINFRA_DEFAULT_MODEL_REF, applyDeepInfraConfig, buildDeepInfraImageGenerationProvider, buildDeepInfraProvider, buildDeepInfraSpeechProvider, buildDeepInfraVideoGenerationProvider, buildStaticDeepInfraProvider, deepinfraEmbeddingProviderAdapter, deepinfraMediaUnderstandingProvider };
@@ -1,4 +1,4 @@
1
- import { t as modelCatalog } from "./openclaw.plugin-BRaVociw.js";
1
+ import { t as modelCatalog } from "./.setup/openclaw.plugin-BRaVociw.mjs";
2
2
  import { asObjectRecord } from "openclaw/plugin-sdk/runtime-doctor-migrations";
3
3
  //#region extensions/deepinfra/doctor-contract-api.ts
4
4
  const PROVIDER_PATH = "models.providers.deepinfra";
package/dist/index.js CHANGED
@@ -2,9 +2,10 @@ import { createDeepInfraAnthropicCacheWrapper } from "./cache-wrapper.js";
2
2
  import { buildDeepInfraEmbeddingAdapter } from "./embedding-adapter.js";
3
3
  import { buildDeepInfraImageGenerationProvider } from "./image-generation-provider.js";
4
4
  import { buildDeepInfraMediaUnderstandingProvider } from "./media-understanding-provider.js";
5
- import { DEEPINFRA_DEFAULT_MODEL_REF, getDeepInfraSurfaceFallbackCatalog } from "./provider-models.js";
5
+ import { DEEPINFRA_DEFAULT_MODEL_REF, buildStaticDeepInfraProvider } from "./provider-static-catalog.js";
6
6
  import { applyDeepInfraConfig } from "./onboard.js";
7
- import { buildDeepInfraApiKeyCatalog, buildStaticDeepInfraProvider } from "./provider-catalog.js";
7
+ import { getDeepInfraSurfaceFallbackCatalog } from "./provider-models.js";
8
+ import { buildDeepInfraApiKeyCatalog } from "./provider-catalog.js";
8
9
  import { buildDeepInfraSpeechProvider } from "./speech-provider.js";
9
10
  import { listDeepInfraImageGenCatalog, listDeepInfraVideoGenCatalog } from "./surface-model-catalogs.js";
10
11
  import { buildDeepInfraVideoGenerationProvider } from "./video-generation-provider.js";
@@ -1,4 +1,4 @@
1
- import { t as modelCatalog } from "./openclaw.plugin-BRaVociw.js";
1
+ import { t as modelCatalog } from "./.setup/openclaw.plugin-BRaVociw.mjs";
2
2
  import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
3
3
  //#region extensions/deepinfra/media-models.ts
4
4
  const DEEPINFRA_BASE_URL = modelCatalog.providers.deepinfra.baseUrl;
package/dist/onboard.js CHANGED
@@ -1,4 +1,4 @@
1
- import { DEEPINFRA_DEFAULT_MODEL_REF } from "./provider-models.js";
1
+ import { DEEPINFRA_DEFAULT_MODEL_REF } from "./provider-static-catalog.js";
2
2
  import { createAliasOnlyPresetAppliers } from "openclaw/plugin-sdk/provider-onboard";
3
3
  //#region extensions/deepinfra/onboard.ts
4
4
  function applyDeepInfraConfig(cfg, modelRef = DEEPINFRA_DEFAULT_MODEL_REF) {
@@ -1,15 +1,8 @@
1
1
  import { DEEPINFRA_BASE_URL } from "./media-models.js";
2
- import { DEEPINFRA_MODEL_CATALOG, buildDeepInfraModelDefinition, discoverDeepInfraModels } from "./provider-models.js";
2
+ import { discoverDeepInfraModels } from "./provider-models.js";
3
3
  import { runLiveProviderCatalog } from "openclaw/plugin-sdk/provider-catalog-live-runtime";
4
4
  import { buildSingleProviderApiKeyCatalog } from "openclaw/plugin-sdk/provider-catalog-shared";
5
5
  //#region extensions/deepinfra/provider-catalog.ts
6
- function buildStaticDeepInfraProvider() {
7
- return {
8
- baseUrl: DEEPINFRA_BASE_URL,
9
- api: "openai-completions",
10
- models: DEEPINFRA_MODEL_CATALOG.map(buildDeepInfraModelDefinition)
11
- };
12
- }
13
6
  async function buildDeepInfraProvider(options) {
14
7
  const models = await discoverDeepInfraModels({
15
8
  ...options,
@@ -37,4 +30,4 @@ function buildDeepInfraApiKeyCatalog(ctx) {
37
30
  });
38
31
  }
39
32
  //#endregion
40
- export { buildDeepInfraApiKeyCatalog, buildDeepInfraProvider, buildStaticDeepInfraProvider };
33
+ export { buildDeepInfraApiKeyCatalog, buildDeepInfraProvider };
@@ -1,4 +1,4 @@
1
- import { buildDeepInfraApiKeyCatalog, buildStaticDeepInfraProvider } from "./provider-catalog.js";
1
+ import { buildStaticDeepInfraProvider } from "./provider-static-catalog.js";
2
2
  //#region extensions/deepinfra/provider-discovery.ts
3
3
  const deepinfraProviderDiscovery = {
4
4
  id: "deepinfra",
@@ -7,7 +7,10 @@ const deepinfraProviderDiscovery = {
7
7
  auth: [],
8
8
  catalog: {
9
9
  order: "simple",
10
- run: (ctx) => buildDeepInfraApiKeyCatalog(ctx)
10
+ run: async (ctx) => {
11
+ const { buildDeepInfraApiKeyCatalog } = await import("./provider-catalog.js");
12
+ return await buildDeepInfraApiKeyCatalog(ctx);
13
+ }
11
14
  },
12
15
  staticCatalog: {
13
16
  order: "simple",
@@ -1,25 +1,20 @@
1
- import { t as modelCatalog } from "./openclaw.plugin-BRaVociw.js";
1
+ import { t as modelCatalog } from "./.setup/openclaw.plugin-BRaVociw.mjs";
2
2
  import { DEEPINFRA_BASE_URL, DEEPINFRA_TTS_FALLBACK_CATALOG } from "./media-models.js";
3
+ import { DEEPINFRA_MODEL_CATALOG, buildDeepInfraModelDefinition } from "./provider-static-catalog.js";
3
4
  import { parseDeepInfraPricingCatalog } from "./pricing-api.js";
4
5
  import { asPositiveSafeInteger, isRecord } from "openclaw/plugin-sdk/string-coerce-runtime";
6
+ import { fetchLiveProviderModelRows } from "openclaw/plugin-sdk/provider-catalog-live-runtime";
7
+ import { getCachedLiveCatalogValue } from "openclaw/plugin-sdk/provider-catalog-shared";
5
8
  import { withTrustedEnvProxyGuardedFetchMode } from "openclaw/plugin-sdk/fetch-runtime";
6
9
  import { isProviderApiKeyConfigured } from "openclaw/plugin-sdk/provider-auth";
7
- import { fetchLiveProviderModelRows } from "openclaw/plugin-sdk/provider-catalog-live-runtime";
8
- import { buildManifestModelProviderConfig, getCachedLiveCatalogValue } from "openclaw/plugin-sdk/provider-catalog-shared";
9
10
  import { createSubsystemLogger } from "openclaw/plugin-sdk/runtime-env";
10
11
  import { fetchWithSsrFGuard } from "openclaw/plugin-sdk/ssrf-runtime";
11
12
  //#region extensions/deepinfra/provider-models.ts
12
13
  const log = createSubsystemLogger("deepinfra-models");
13
- const DEEPINFRA_MANIFEST_PROVIDER = buildManifestModelProviderConfig({
14
- providerId: "deepinfra",
15
- catalog: modelCatalog.providers.deepinfra
16
- });
17
14
  const DEEPINFRA_MODELS_URL = `${DEEPINFRA_BASE_URL}/models?sort_by=openclaw&filter=with_meta`;
18
15
  const DEEPINFRA_PRICING_URL = "https://api.deepinfra.com/models/list";
19
- const DEEPINFRA_DEFAULT_MODEL_REF = `deepinfra/deepseek-ai/DeepSeek-V4-Flash`;
20
16
  const DEEPINFRA_DEFAULT_CONTEXT_WINDOW = 128e3;
21
17
  const DEEPINFRA_DEFAULT_MAX_TOKENS = 8192;
22
- const DEEPINFRA_MODEL_CATALOG = DEEPINFRA_MANIFEST_PROVIDER.models;
23
18
  const DISCOVERY_TIMEOUT_MS = 5e3;
24
19
  const DISCOVERY_CACHE_TTL_MS = 3e5;
25
20
  const SURFACE_FOR_TAG = {
@@ -162,20 +157,6 @@ function manifestFallbackCatalog() {
162
157
  function getDeepInfraSurfaceFallbackCatalog() {
163
158
  return manifestFallbackCatalog();
164
159
  }
165
- function resolveDeepInfraThinkingFormat(modelId) {
166
- return (modelId ?? "").toLowerCase().split("/")[0] === "deepseek-ai" ? "deepseek" : void 0;
167
- }
168
- function buildDeepInfraModelDefinition(model) {
169
- const thinkingFormat = model.compat?.thinkingFormat ?? resolveDeepInfraThinkingFormat(model.id);
170
- return {
171
- ...model,
172
- compat: {
173
- ...model.compat,
174
- supportsUsageInStreaming: model.compat?.supportsUsageInStreaming ?? true,
175
- ...thinkingFormat ? { thinkingFormat } : {}
176
- }
177
- };
178
- }
179
160
  function chatSurfaceModelToModelDefinition(model) {
180
161
  const manifestModel = DEEPINFRA_MODEL_CATALOG.find((entry) => entry.id === model.id);
181
162
  const input = model.tags.includes("vlm") ? ["text", "image"] : ["text"];
@@ -294,4 +275,4 @@ async function discoverDeepInfraModels(options) {
294
275
  }));
295
276
  }
296
277
  //#endregion
297
- export { DEEPINFRA_DEFAULT_MODEL_REF, DEEPINFRA_MODEL_CATALOG, buildDeepInfraModelDefinition, discoverDeepInfraModels, discoverDeepInfraSurfaces, getDeepInfraSurfaceFallbackCatalog };
278
+ export { discoverDeepInfraModels, discoverDeepInfraSurfaces, getDeepInfraSurfaceFallbackCatalog };
@@ -0,0 +1,33 @@
1
+ import { t as modelCatalog } from "./.setup/openclaw.plugin-BRaVociw.mjs";
2
+ import { DEEPINFRA_BASE_URL } from "./media-models.js";
3
+ import { buildManifestModelProviderConfig } from "openclaw/plugin-sdk/provider-model-metadata";
4
+ //#region extensions/deepinfra/provider-static-catalog.ts
5
+ const DEEPINFRA_MANIFEST_PROVIDER = buildManifestModelProviderConfig({
6
+ providerId: "deepinfra",
7
+ catalog: modelCatalog.providers.deepinfra
8
+ });
9
+ const DEEPINFRA_DEFAULT_MODEL_REF = `deepinfra/deepseek-ai/DeepSeek-V4-Flash`;
10
+ const DEEPINFRA_MODEL_CATALOG = DEEPINFRA_MANIFEST_PROVIDER.models;
11
+ function resolveDeepInfraThinkingFormat(modelId) {
12
+ return (modelId ?? "").toLowerCase().split("/")[0] === "deepseek-ai" ? "deepseek" : void 0;
13
+ }
14
+ function buildDeepInfraModelDefinition(model) {
15
+ const thinkingFormat = model.compat?.thinkingFormat ?? resolveDeepInfraThinkingFormat(model.id);
16
+ return {
17
+ ...model,
18
+ compat: {
19
+ ...model.compat,
20
+ supportsUsageInStreaming: model.compat?.supportsUsageInStreaming ?? true,
21
+ ...thinkingFormat ? { thinkingFormat } : {}
22
+ }
23
+ };
24
+ }
25
+ function buildStaticDeepInfraProvider() {
26
+ return {
27
+ baseUrl: DEEPINFRA_BASE_URL,
28
+ api: "openai-completions",
29
+ models: DEEPINFRA_MODEL_CATALOG.map(buildDeepInfraModelDefinition)
30
+ };
31
+ }
32
+ //#endregion
33
+ export { DEEPINFRA_DEFAULT_MODEL_REF, DEEPINFRA_MODEL_CATALOG, buildDeepInfraModelDefinition, buildStaticDeepInfraProvider };
@@ -2,8 +2,9 @@ import { DEEPINFRA_BASE_URL, DEEPINFRA_VIDEO_ASPECT_RATIOS, DEEPINFRA_VIDEO_DURA
2
2
  import { resolveDeepInfraVideoModelCapabilities } from "./surface-model-catalogs.js";
3
3
  import { asSafeIntegerInRange, normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
4
4
  import { isProviderApiKeyConfigured } from "openclaw/plugin-sdk/provider-auth";
5
- import { extensionForMime } from "openclaw/plugin-sdk/media-mime";
6
- import { canonicalizeBase64 } from "openclaw/plugin-sdk/media-runtime";
5
+ import { resolveGeneratedMediaMaxBytes } from "openclaw/plugin-sdk/media-generation-runtime";
6
+ import { detectMime, extensionForMime, mediaKindFromMime, normalizeMimeType } from "openclaw/plugin-sdk/media-mime";
7
+ import { canonicalizeBase64, estimateBase64DecodedBytes } from "openclaw/plugin-sdk/media-runtime";
7
8
  import { resolveApiKeyForProvider } from "openclaw/plugin-sdk/provider-auth-runtime";
8
9
  import { assertOkOrThrowHttpError, createProviderOperationDeadline, pollProviderOperationJson, postJsonRequest, readProviderJsonResponse, resolveProviderHttpRequestConfig, resolveProviderOperationTimeoutMs, sanitizeConfiguredModelProviderRequest } from "openclaw/plugin-sdk/provider-http";
9
10
  //#region extensions/deepinfra/video-generation-provider.ts
@@ -14,17 +15,24 @@ function normalizeDeepInfraVideoUrl(url, baseUrl) {
14
15
  if (url.startsWith("http://") || url.startsWith("https://") || url.startsWith("data:")) return url;
15
16
  return new URL(url, baseUrl).href;
16
17
  }
17
- function parseVideoDataUrl(url) {
18
- const match = /^data:([^;,]+);base64,(.+)$/u.exec(url);
19
- if (!match) return;
20
- const mimeType = match[1] ?? "video/mp4";
21
- const ext = extensionForMime(mimeType)?.slice(1) ?? "mp4";
22
- const canonicalBase64 = canonicalizeBase64(match[2] ?? "");
18
+ async function parseVideoDataUrl(url, maxBytes) {
19
+ if (!url.startsWith("data:")) return;
20
+ const match = /^data:([^;,]+);base64,(.*)$/su.exec(url);
21
+ if (!match) throw new Error("DeepInfra video response: malformed video response");
22
+ const mimeType = normalizeMimeType(match[1]);
23
+ if (!mimeType || mediaKindFromMime(mimeType) !== "video" && mimeType !== "application/octet-stream") throw new Error("DeepInfra video response: malformed video response");
24
+ const base64 = match[2] ?? "";
25
+ if (!base64) throw new Error("DeepInfra video response: malformed video response");
26
+ if (estimateBase64DecodedBytes(base64) > maxBytes) throw new Error(`DeepInfra generated video exceeds ${maxBytes} bytes`);
27
+ const canonicalBase64 = canonicalizeBase64(base64);
23
28
  if (!canonicalBase64) throw new Error("DeepInfra video response returned malformed data URL base64");
29
+ const buffer = Buffer.from(canonicalBase64, "base64");
30
+ const detectedMime = await detectMime({ buffer });
31
+ if (!detectedMime || mediaKindFromMime(detectedMime) !== "video") throw new Error("DeepInfra video response: malformed video response");
24
32
  return {
25
- buffer: Buffer.from(canonicalBase64, "base64"),
26
- mimeType,
27
- fileName: `video-1.${ext}`
33
+ buffer,
34
+ mimeType: detectedMime,
35
+ fileName: `video-1.${extensionForMime(detectedMime)?.slice(1) ?? "mp4"}`
28
36
  };
29
37
  }
30
38
  function resolveDurationSeconds(value) {
@@ -61,11 +69,11 @@ function firstDeepInfraVideoUrl(job) {
61
69
  if (videoUrl) return videoUrl;
62
70
  }
63
71
  }
64
- function extractDeepInfraVideoAsset(job, baseUrl) {
72
+ async function extractDeepInfraVideoAsset(job, baseUrl, maxBytes) {
65
73
  const videoUrl = firstDeepInfraVideoUrl(job);
66
74
  if (!videoUrl) throw new Error("DeepInfra video response missing video URL");
67
75
  const normalizedUrl = normalizeDeepInfraVideoUrl(videoUrl, baseUrl);
68
- const dataAsset = parseVideoDataUrl(normalizedUrl);
76
+ const dataAsset = await parseVideoDataUrl(normalizedUrl, maxBytes);
69
77
  if (dataAsset) return dataAsset;
70
78
  return {
71
79
  url: normalizedUrl,
@@ -175,7 +183,7 @@ function buildDeepInfraVideoGenerationProvider(options) {
175
183
  getFailureMessage: (payload) => payload.status === "failed" ? normalizeOptionalString(payload.error) ?? "DeepInfra video generation failed" : void 0
176
184
  });
177
185
  return {
178
- videos: [extractDeepInfraVideoAsset(completed, baseUrl)],
186
+ videos: [await extractDeepInfraVideoAsset(completed, baseUrl, resolveGeneratedMediaMaxBytes(req.cfg, "video"))],
179
187
  model: normalizeOptionalString(completed.model) ?? model,
180
188
  metadata: {
181
189
  jobId,
@@ -1,5 +1,8 @@
1
1
  {
2
2
  "id": "deepinfra",
3
+ "categories": [
4
+ "models"
5
+ ],
3
6
  "capabilityCatalogEntry": "./dist/capability-catalog.js",
4
7
  "doctorContract": {
5
8
  "configRepair": true
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@openclaw/deepinfra-provider",
3
- "version": "2026.9.3",
3
+ "version": "2026.9.5",
4
4
  "description": "OpenClaw DeepInfra 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.9.3"
21
+ "pluginApi": ">=2026.9.5"
22
22
  },
23
23
  "build": {
24
- "openclawVersion": "2026.9.3",
24
+ "openclawVersion": "2026.9.5",
25
25
  "bundledDist": false
26
26
  },
27
27
  "release": {
@@ -35,10 +35,12 @@
35
35
  "files": [
36
36
  "dist/**",
37
37
  "openclaw.plugin.json",
38
- "README.md"
38
+ "README.md",
39
+ "assets/icon.png",
40
+ "assets/activity.svg"
39
41
  ],
40
42
  "peerDependencies": {
41
- "openclaw": ">=2026.9.3"
43
+ "openclaw": ">=2026.9.5"
42
44
  },
43
45
  "peerDependenciesMeta": {
44
46
  "openclaw": {