openclaw - ✅(Solved) Fix Nvidia provider sends bare model id to integrate.api.nvidia.com → HTTP 404 (vendor prefix dropped in normalizeStaticProviderModelId) [2 pull requests, 1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#71552Fetched 2026-04-26 05:11:35
View on GitHub
Comments
0
Participants
1
Timeline
8
Reactions
0
Participants
Timeline (top)
cross-referenced ×3referenced ×3closed ×1labeled ×1

When agents.defaults.model.primary is set to a Nvidia NIM model id like nvidia/nemotron-3-super-120b-a12b, the gateway strips the nvidia/ prefix before the outbound request reaches integrate.api.nvidia.com/v1/chat/completions, causing HTTP 404 model_not_found. The Nvidia NIM API expects the full vendor-prefixed model id on the wire (same convention as OpenRouter, which is already handled correctly).

Root cause is in dist/model-ref-shared-DxJ4s7gE.js: parseStaticModelRef() splits the configured ref on the first / into provider + modelRaw, then calls normalizeStaticProviderModelId(provider, modelRaw). That function has a re-prefixing case for openrouter but no equivalent for nvidia, so the bare suffix becomes the runtime model.id and is what reaches pi-ai's openai-completions request body.

Error Message

{"event":"embedded_run_agent_end","isError":true,"error":"HTTP 404: 404 page not found","failoverReason":"model_not_found","model":"nemotron-3-super-120b-a12b","provider":"nvidia","sourceModel":"nemotron-3-super-120b-a12b","providerRuntimeFailureKind":"unknown"}

Root Cause

Root cause is in dist/model-ref-shared-DxJ4s7gE.js: parseStaticModelRef() splits the configured ref on the first / into provider + modelRaw, then calls normalizeStaticProviderModelId(provider, modelRaw). That function has a re-prefixing case for openrouter but no equivalent for nvidia, so the bare suffix becomes the runtime model.id and is what reaches pi-ai's openai-completions request body.

Fix Action

Fixed

PR fix notes

PR #71567: fix(model): re-prefix nvidia/ on bare model ids (#71552)

Description (problem / solution / changelog)

Summary

Fixes #71552 — Nvidia NIM models (e.g. nvidia/nemotron-3-super-120b-a12b) fail with HTTP 404 because parseStaticModelRef() strips the nvidia/ prefix and normalizeStaticProviderModelId() has no re-prefix case for nvidia.

Root Cause

parseStaticModelRef() splits the configured ref on the first / into provider + modelRaw. For nvidia/nemotron-3-super-120b-a12b, this yields provider='nvidia' and modelRaw='nemotron-3-super-120b-a12b'.

normalizeStaticProviderModelId() already re-prefixes bare model ids for openrouter (line 74), but had no equivalent case for nvidia. The Nvidia NIM API at integrate.api.nvidia.com expects the full vendor-prefixed id on the wire.

Fix

Add the same !model.includes('/') guard for nvidia provider, mirroring the existing openrouter pattern. Models with inner slashes (e.g. moonshotai/kimi-k2.5) are unaffected since the guard only triggers when the slash was consumed by the parser.

Testing

  • nvidia/nemotron-3-super-120b-a12b → re-prefixed to nvidia/nemotron-3-super-120b-a12b
  • moonshotai/kimi-k2.5 on nvidia provider → keeps inner slash, not re-prefixed ✅
  • openrouter behavior unchanged ✅

Changed files

  • src/agents/model-ref-shared.ts (modified, +3/-0)

PR #71660: fix(model-ref): re-add nvidia/ prefix in normalizeStaticProviderModelId (#71552)

Description (problem / solution / changelog)

Fix: Nvidia provider drops vendor model prefix (#71552)

Root cause: parseStaticModelRef splits nvidia/nemotron-3-super-120b-a12b on the first / → provider=nvidia, modelRaw=nemotron-3-super-120b-a12b. normalizeStaticProviderModelId has a re-prefixing case for openrouter but not nvidia, so the bare model id reaches integrate.api.nvidia.com → HTTP 404.

Fix: Added the missing nvidia re-prefixing case in normalizeStaticProviderModelId:

if (provider === "nvidia" && !model.includes("/")) {
  return `nvidia/${model}`;
}

Test: Added src/agents/model-ref-shared.test.ts covering:

  • Bare nvidia model ids get the prefix restored (nemotron-3-super-120b-a12bnvidia/nemotron-3-super-120b-a12b)
  • Already-prefixed models pass through unchanged (no double-prefix)

Closes #71552

Changed files

  • src/agents/model-ref-shared.test.ts (added, +16/-0)
  • src/agents/model-ref-shared.ts (modified, +3/-0)

Code Example

{"event":"embedded_run_agent_end","isError":true,"error":"HTTP 404: 404 page not found","failoverReason":"model_not_found","model":"nemotron-3-super-120b-a12b","provider":"nvidia","sourceModel":"nemotron-3-super-120b-a12b","providerRuntimeFailureKind":"unknown"}


After applying the proposed fix locally, `openclaw agent --agent main -m "ping"` returns `status: ok` in ~17s with metadata showing `provider: "nvidia"`, `model: "nvidia/nemotron-3-super-120b-a12b"` — full prefix preserved end-to-end.

---

// dist/model-ref-shared-DxJ4s7gE.js, in normalizeStaticProviderModelId
if (provider === "openrouter" && !model.includes("/")) return `openrouter/${model}`;
if (provider === "nvidia" && !model.includes("/")) return `nvidia/${model}`;   // ← add
if (provider === "xai") return normalizeNativeXaiModelId(model);
RAW_BUFFERClick to expand / collapse

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

When agents.defaults.model.primary is set to a Nvidia NIM model id like nvidia/nemotron-3-super-120b-a12b, the gateway strips the nvidia/ prefix before the outbound request reaches integrate.api.nvidia.com/v1/chat/completions, causing HTTP 404 model_not_found. The Nvidia NIM API expects the full vendor-prefixed model id on the wire (same convention as OpenRouter, which is already handled correctly).

Root cause is in dist/model-ref-shared-DxJ4s7gE.js: parseStaticModelRef() splits the configured ref on the first / into provider + modelRaw, then calls normalizeStaticProviderModelId(provider, modelRaw). That function has a re-prefixing case for openrouter but no equivalent for nvidia, so the bare suffix becomes the runtime model.id and is what reaches pi-ai's openai-completions request body.

Steps to reproduce

  1. npm i -g [email protected] (Node 22)
  2. Configure a provider entry under models.providers.nvidia:
    • baseUrl: https://integrate.api.nvidia.com/v1
    • api: openai-completions
    • models: [{ id: "nvidia/nemotron-3-super-120b-a12b", ... }]
    • valid nvapi-… key
  3. Set agents.defaults.model.primary to nvidia/nemotron-3-super-120b-a12b
  4. Trigger any agent run, e.g. openclaw agent --agent main -m "ping"

A direct curl https://integrate.api.nvidia.com/v1/chat/completions -H "Authorization: Bearer $NVAPI_KEY" -d '{"model":"nvidia/nemotron-3-super-120b-a12b","messages":[...]}' succeeds with the same key, confirming the API expects the full prefix.

Expected behavior

Agent completes successfully. Outbound request to integrate.api.nvidia.com carries "model": "nvidia/nemotron-3-super-120b-a12b" — matching the catalog entry's id and the documented Nvidia NIM model identifier.

Actual behavior

HTTP 404: 404 page not found, failoverReason: model_not_found. Gateway log shows the runtime/agent layer with model: "nemotron-3-super-120b-a12b" and sourceModel: "nemotron-3-super-120b-a12b" — both stripped of the nvidia/ prefix before pi-ai constructs the request body.

OpenClaw version

2026.4.23

Operating system

macOS 14

Install method

npm i -g openclaw (Node 22.22.2 via nvm)

Model

nvidia/nemotron-3-super-120b-a12b

Provider / routing chain

openclaw -> nvidia (integrate.api.nvidia.com/v1, openai-completions API)

Additional provider/model setup details

No response

Logs, screenshots, and evidence

{"event":"embedded_run_agent_end","isError":true,"error":"HTTP 404: 404 page not found","failoverReason":"model_not_found","model":"nemotron-3-super-120b-a12b","provider":"nvidia","sourceModel":"nemotron-3-super-120b-a12b","providerRuntimeFailureKind":"unknown"}


After applying the proposed fix locally, `openclaw agent --agent main -m "ping"` returns `status: ok` in ~17s with metadata showing `provider: "nvidia"`, `model: "nvidia/nemotron-3-super-120b-a12b"` — full prefix preserved end-to-end.

Impact and severity

Nvidia NIM provider is unusable out of the box for any model whose catalog id starts with nvidia/ (Nemotron variants in the bundled catalog). Catalog entries with non-nvidia/ vendor prefixes in the same provider (moonshotai/kimi-k2.5, minimaxai/minimax-m2.5, z-ai/glm5) happen to work because the inner slash survives the split. So the breakage is silent and partial — users may assume "only Nemotron is broken" rather than recognizing the underlying normalize-table gap.

Additional information

Suggested one-line fix (mirrors the existing OpenRouter case):

// dist/model-ref-shared-DxJ4s7gE.js, in normalizeStaticProviderModelId
if (provider === "openrouter" && !model.includes("/")) return `openrouter/${model}`;
if (provider === "nvidia" && !model.includes("/")) return `nvidia/${model}`;   // ← add
if (provider === "xai") return normalizeNativeXaiModelId(model);

The !model.includes("/") guard preserves correct behavior for already-prefixed catalog entries like moonshotai/kimi-k2.5 (which after the parser's split becomes moonshotai/kimi-k2.5 with the slash intact, so re-prefixing is skipped).

Cosmetic follow-up (separate, pre-existing): dist/server-startup-log-DMedWp7m.js builds the displayed model ref via naive ${provider}/${model} interpolation rather than the modelKey() helper that other call sites use. After applying the fix, the startup banner shows agent model: nvidia/nvidia/nemotron-3-super-120b-a12b — purely a display issue (runtime is correct), but worth swapping to modelKey() for consistency.

extent analysis

TL;DR

Add a conditional statement to normalizeStaticProviderModelId in dist/model-ref-shared-DxJ4s7gE.js to re-prefix the model ID with "nvidia/" when the provider is "nvidia" and the model ID does not contain a slash.

Guidance

  • Identify the normalizeStaticProviderModelId function in dist/model-ref-shared-DxJ4s7gE.js and add the suggested one-line fix to handle the "nvidia" provider case.
  • Verify that the fix works by running openclaw agent --agent main -m "ping" and checking the metadata for the preserved "nvidia/" prefix.
  • Consider addressing the cosmetic issue in dist/server-startup-log-DMedWp7m.js by using the modelKey() helper for consistency.
  • Test the fix with different model IDs and providers to ensure the solution is robust.

Example

The suggested one-line fix:

if (provider === "nvidia" && !model.includes("/")) return `nvidia/${model}`;

adds the necessary re-prefixing logic for the "nvidia" provider.

Notes

The fix assumes that the normalizeStaticProviderModelId function is the correct place to add the re-prefixing logic. Additional testing and verification may be necessary to ensure the solution works as expected.

Recommendation

Apply the workaround by adding the suggested one-line fix to normalizeStaticProviderModelId in dist/model-ref-shared-DxJ4s7gE.js, as it directly addresses the identified issue and preserves the correct behavior for other providers and model IDs.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

Agent completes successfully. Outbound request to integrate.api.nvidia.com carries "model": "nvidia/nemotron-3-super-120b-a12b" — matching the catalog entry's id and the documented Nvidia NIM model identifier.

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - ✅(Solved) Fix Nvidia provider sends bare model id to integrate.api.nvidia.com → HTTP 404 (vendor prefix dropped in normalizeStaticProviderModelId) [2 pull requests, 1 participants]