fix: hide unsupported video audio refs · openclaw/openclaw@957d50a
steipete
·
2026-05-18
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -38,6 +38,7 @@ Docs: https://docs.openclaw.ai
|
38 | 38 | |
39 | 39 | ### Fixes |
40 | 40 | |
| 41 | +- Agents/video: hide `video_generate` reference-audio parameters unless a registered video provider supports audio inputs. |
41 | 42 | - Plugins/xAI: echo PKCE challenge fields during OAuth authorization-code token exchange for xAI token-endpoint compatibility. (#83499) Thanks @fuller-stack-dev. |
42 | 43 | - Codex app-server: hydrate current inbound image attachments before queued runs so Responses-backed agents receive Discord and other channel images as native vision input. Fixes #83466. Thanks @iannwu. |
43 | 44 | - Release stability: recover stale session diagnostics and Codex OAuth fallback state so stuck runs and reused refresh tokens clear without blocking follow-up work. (#83503) Thanks @100yenadmin. |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -241,12 +241,13 @@ stay in the plugin runtime.
|
241 | 241 | |
242 | 242 | Each metadata entry supports: |
243 | 243 | |
244 | | -| Field | Required | Type | What it means | |
245 | | -| --------------- | -------- | ---------- | ----------------------------------------------------------------------------------------------------------------------------------- | |
246 | | -| `aliases` | No | `string[]` | Additional provider ids that should count as static auth aliases for the generation provider. | |
247 | | -| `authProviders` | No | `string[]` | Provider ids whose configured auth profiles should count as auth for this generation provider. | |
248 | | -| `configSignals` | No | `object[]` | Cheap config-only availability signals for local or self-hosted providers that can be configured without auth profiles or env vars. | |
249 | | -| `authSignals` | No | `object[]` | Explicit auth signals. When present, these replace the default signal set from the provider id, `aliases`, and `authProviders`. | |
| 244 | +| Field | Required | Type | What it means | |
| 245 | +| ---------------------- | -------- | ---------- | --------------------------------------------------------------------------------------------------------------------------------------------------- | |
| 246 | +| `aliases` | No | `string[]` | Additional provider ids that should count as static auth aliases for the generation provider. | |
| 247 | +| `authProviders` | No | `string[]` | Provider ids whose configured auth profiles should count as auth for this generation provider. | |
| 248 | +| `configSignals` | No | `object[]` | Cheap config-only availability signals for local or self-hosted providers that can be configured without auth profiles or env vars. | |
| 249 | +| `authSignals` | No | `object[]` | Explicit auth signals. When present, these replace the default signal set from the provider id, `aliases`, and `authProviders`. | |
| 250 | +| `referenceAudioInputs` | No | `boolean` | Video-generation only. Set to `true` when the provider accepts reference audio assets; otherwise `video_generate` hides audio reference parameters. | |
250 | 251 | |
251 | 252 | Each `configSignals` entry supports: |
252 | 253 | |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -29,6 +29,11 @@
|
29 | 29 | "musicGenerationProviders": ["fal"], |
30 | 30 | "videoGenerationProviders": ["fal"] |
31 | 31 | }, |
| 32 | +"videoGenerationProviderMetadata": { |
| 33 | +"fal": { |
| 34 | +"referenceAudioInputs": true |
| 35 | + } |
| 36 | + }, |
32 | 37 | "configSchema": { |
33 | 38 | "type": "object", |
34 | 39 | "additionalProperties": false, |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -848,6 +848,16 @@
|
848 | 848 | ] |
849 | 849 | } |
850 | 850 | }, |
| 851 | +"videoGenerationProviderMetadata": { |
| 852 | +"openai": { |
| 853 | +"aliases": ["openai-codex"], |
| 854 | +"authSignals": [ |
| 855 | + { |
| 856 | +"provider": "openai" |
| 857 | + } |
| 858 | + ] |
| 859 | + } |
| 860 | + }, |
851 | 861 | "mediaUnderstandingProviderMetadata": { |
852 | 862 | "openai": { |
853 | 863 | "capabilities": ["image", "audio"], |
|
| Original file line number | Diff line number | Diff line change |
|---|
@@ -195,3 +195,71 @@ export function hasSnapshotProviderEnvAvailability(params: {
|
195 | 195 | } |
196 | 196 | return false; |
197 | 197 | } |
| 198 | + |
| 199 | +export function hasSnapshotCapabilityProviderAvailability(params: { |
| 200 | +snapshot: Pick<PluginMetadataSnapshot, "index" | "plugins">; |
| 201 | +key: CapabilityContractKey; |
| 202 | +providerId: string; |
| 203 | +config?: OpenClawConfig; |
| 204 | +authStore?: AuthProfileStore; |
| 205 | +}): boolean { |
| 206 | +if (params.config?.plugins?.enabled === false) { |
| 207 | +return false; |
| 208 | +} |
| 209 | +for (const plugin of params.snapshot.plugins) { |
| 210 | +if ( |
| 211 | +!isManifestPluginAvailableForControlPlane({ |
| 212 | +snapshot: params.snapshot, |
| 213 | + plugin, |
| 214 | +config: params.config, |
| 215 | +}) |
| 216 | +) { |
| 217 | +continue; |
| 218 | +} |
| 219 | +if (!plugin.contracts?.[params.key]?.includes(params.providerId)) { |
| 220 | +continue; |
| 221 | +} |
| 222 | +const metadataKey = metadataKeyForCapabilityContract(params.key); |
| 223 | +const metadata = metadataKey ? plugin[metadataKey]?.[params.providerId] : undefined; |
| 224 | +if ( |
| 225 | +metadata?.configSignals?.some((signal) => |
| 226 | +manifestConfigSignalPasses({ |
| 227 | +config: params.config, |
| 228 | +env: process.env, |
| 229 | + signal, |
| 230 | +}), |
| 231 | +) |
| 232 | +) { |
| 233 | +return true; |
| 234 | +} |
| 235 | +for (const signal of listCapabilityAuthSignals({ |
| 236 | + plugin, |
| 237 | +key: params.key, |
| 238 | +providerId: params.providerId, |
| 239 | +})) { |
| 240 | +if ( |
| 241 | +!manifestProviderBaseUrlGuardPasses({ |
| 242 | +config: params.config, |
| 243 | +guard: signal.providerBaseUrl, |
| 244 | +}) |
| 245 | +) { |
| 246 | +continue; |
| 247 | +} |
| 248 | +if ( |
| 249 | +params.authStore && |
| 250 | +listProfilesForProvider(params.authStore, signal.provider).length > 0 |
| 251 | +) { |
| 252 | +return true; |
| 253 | +} |
| 254 | +if ( |
| 255 | +hasNonEmptyManifestEnvCandidate( |
| 256 | +process.env, |
| 257 | +manifestPluginSetupProviderEnvVars(plugin, signal.provider), |
| 258 | +) |
| 259 | +) { |
| 260 | +return true; |
| 261 | +} |
| 262 | +} |
| 263 | +} |
| 264 | +return false; |
| 265 | +} |
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。