Repository navigation
fix(nemotron-super): OpenRouter readiness: inlined video above 8 MiB, JSON response format with tools - #1560
Conversation
The Super media binding refused any encoded body over 8 MiB as invalid input, so OpenRouter's input-video-url readiness test (a 6.9 MB MP4 the coordinator inlines into a 9.3 MB body) failed with invalid_media. Raise NemotronSuperServingPolicy.maximumEncodedBodyBytes to 40 MiB, which holds one part at the shared 25 MiB inline-media cap as base64 and any body the provider's transports deliver, and make encodedHeaderQuote use it as its single bound. A body above it now fails as media_too_large. The media charge quotes and the default prefix bank follow the larger bound. Add NemotronSuperOpenRouterVideoTests: both OpenRouter readiness clips pass ingress, inspection, the pinned template's prompt, the media plan and every frame's decode, and serve on the tiny installed fixture.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Threat model review — advisoryReviewed head Review not completed for this head. Previous findings are superseded, not confirmed resolved. Reviewers: anthropic/claude-sonnet-5.5: first pass completed LOW: Image/video media memory charge quintupled with the 40 MiB body bound; admission and sizing assumptions need reviewprovider-swift/Sources/ProviderCore/Inference/Engine/Factory/NemotronSuperServingPolicy.swift:369 · ADV-002, TB-007 maximumEncodedBodyBytes rises from 8 MiB to 40 MiB (NemotronSuperServingPolicy.swift:369). It feeds encodedHeaderQuote, encodedCopies (UInt64(bodyBytes/4*3)*2 at line 406) and videoChargeBytes (lines 445-448). Every image or video request is therefore charged a much larger ledger reservation, and defaultPrefixBankBytes subtracts mediaChargeBytes(imageCount: 1) (line 293), which shrinks the default prefix bank. A consumer can submit a single large media body, up to the 32 MiB transport cap, and reserve far more shared memory than before. This can starve or refuse concurrent requests and could trigger the Super load/serving admission. The hardcoded pinned constants and the 'video charge stays within one image charge' comment were not re-verified against the new bound. The consumer-controlled memory reservation is availability-relevant (ADV-002), and the effect is bounded by the ledger. Raised by: anthropic/claude-sonnet-5.5 Models: budgeted Sonnet / selective Opus / selective Sol 6.1. Findings require human validation; this review never requests changes or blocks merging. Coverage: 111/111 source units; cross-file integration complete. 9 selected depth batch(es) pending. All threat definitions indexed; relevant full definitions selected. Unchanged callers are not scanned. Cost this run: $0.0000 reported, $0.0000 reserved with unknown cost; 0 paid request(s), 18 reused batch(es), 0 provider cache-hit tokens. Saved findings and earlier report · Historical findings are not confirmed resolved. Bedrock: 7 request(s), 353405 uncached + 0 cache-read + 0 cache-write input / 6508 output tokens; 0 request(s) with unknown usage. OpenRouter backup used 0 time(s). Dollar amounts above cover OpenRouter only; AWS billing is reconciled separately. |
…ests NemotronSuperOpenRouterVideoTests copied NemotronSuperVideoBindingTests' tiny-fixture video owner (same tower, budget, load lease, context and teardown checks) and its generation-event recorder. Reuse videoOwner(contextLength:), VideoOwner.close() and SuperVideoEvents instead, and drop the unused MLXLMCommon import. Correct two test comments: the inlined link makes a body of more than 9 MB here (9.39 MB once JSONSerialization escapes slashes, not 9.3), and only invalid input, not every other binding refusal, still leaves as invalid_media.
The 40 MiB encoded-body bound made the 8 MiB case pass ingress; it was refused only by the context bound the next case already covers. Over local HTTP the body bound is unreachable because the 32 MiB upload limit answers 413 first (tested above), and the binding's over-cap refusal is covered by oversizeBodyIsMediaTooLarge.
M5 Ultra combined build that includes this PR: GLM-5.3-Flash unaffected (no Super run here)For cross-reference with the Nemotron Super real-model before/after, which runs on the M5 Max.
|
Real-checkpoint before/after: Nemotron 3.5 Super, OpenRouter
|
| Runner SHA-256 | |
|---|---|
| BEFORE | 27649794c864c99d8ec73eb580dc88764b1c1e4d7c879fa858229f0285115cc0 |
| AFTER | af15a3baf531e18365cf8a87dbab2f557dccfa2d89302c7c724d44da9f5275e3 |
| Case | Body bytes | BEFORE | AFTER | AFTER excerpt |
|---|---|---|---|---|
text |
223 | 200 (5.74 s) | 200 (7.02 s) | 323 |
text_stream |
262 | 200 (2.27 s) | 200 (2.263 s) | 323 |
image_jpeg |
93558 | 200 (9.198 s) | 200 (9.015 s) | A close-up view shows clusters of small blue and pink flowers with yellow centers growing among fuzzy green le… |
image_jpeg_stream |
93597 | 200 (7.147 s) | 200 (7.584 s) | A close-up view shows clusters of small blue and pink flowers with yellow centers growing among fuzzy green le… |
video_mp4_url_clip |
9246847 | 400 (0.059 s) | 200 (13.591 s) | A blue neon sign reading "OpenRouter" glows brightly in a window. As the camera slowly pans to the right, the … |
video_mp4_url_clip_stream |
9246886 | 400 (0.055 s) | 200 (16.136 s) | A blue neon sign reading "OpenRouter" glows brightly in a window. As the camera slowly pans to the right, the … |
video_mov_base64_clip |
670173 | 200 (31.981 s) | 200 (32.062 s) | The video shows a screen recording of a developer working in a code editor with a dark theme. The code appears… |
video_mov_base64_clip_stream |
670212 | 200 (43.382 s) | 200 (31.911 s) | The video shows a screen recording of a developer working in a code editor with a dark theme. The code appears… |
tools_auto |
565 | 200 (3.289 s) | 200 (3.278 s) | tool_calls: [{"function": {"arguments": "{"location":"Paris","unit":"celsius"}", "name": "get_… |
tools_required |
543 | 200 (2.668 s) | 200 (2.729 s) | tool_calls: [{"function": {"arguments": "{"location":"Tokyo"}", "name": "get_weather"}, "id": "cal… |
tools_forced |
590 | 200 (3.529 s) | 200 (3.116 s) | tool_calls: [{"function": {"arguments": "{"location":"Berlin"}", "name": "get_weather"}, "id": "ca… |
tools_none |
558 | 200 (2.131 s) | 200 (1.854 s) | Bonjour |
json_object |
292 | 200 (5.181 s) | 200 (4.307 s) | {"name": "Alice", "age": 30} |
json_schema |
559 | 200 (3.631 s) | 200 (3.22 s) | {"name":"Ada","age":36,"languages":["English","French"]} |
logprobs |
245 | 400 (0.001 s) | 400 (0.001 s) |
Result. BEFORE reproduces the production failure: OpenRouter's input-video-url clip, inlined, is refused with 400 "Invalid media input." in about 0.06 s, streaming and non-streaming, because the 8 MiB encoded-body cap rejects the 9.25 MB body. AFTER serves it (200) with a correct description of the clip. Every other case is unchanged. logprobs is unsupported on both arms; that's separate work, not part of this PR.
Receipts: m5max-proof/m3u-emu128/runs/{before,after}/receipt.json on the qualification host.
OpenRouter tests every capability on our Super endpoint (tools, all tool_choice modes, json_object, strict json_schema, reasoning on and off). Replaying each test shape, derived from the captured OpenRouter tool request, through the owner's relay path (inbound decode, native controls, response format preparation, request plan, pinned template, output parser) admits all of them except a JSON response format combined with tools: the request plan refused that pair with 400 (unsupportedControl). Serve it. The plan no longer refuses the pair, and the output validates the format only for an answer: a turn that calls tools returns its calls, with any text unchanged, and an answer without calls must be JSON for the format (422 otherwise). A required or named tool_choice still needs its call. NemotronSuperOpenRouterCapabilityTests replays all 20 shapes (10 tests, reasoning enabled and disabled) and validates a compliant response for each, streamed and complete; the captured request's SHA-256 is pinned to the platform conformance fixture. The live HTTP test now serves both a call and a JSON answer for a JSON format with tools, and refuses prose with 422.
…mat with tools) into the consolidated Super PR
Behavior-preserving cleanup of the Nemotron Super JSON response format with tools change: - NemotronSuperLocalOutput.finish named the text a call turn passes through unchanged `answer`, which the comment above it says a call turn is not. Name it `text` and lay the conditional validation out on three lines. - NemotronSuperOpenRouterCapabilityTests.check repeated compliantAnswer's "tool-call-step-5" name test; it now asserts the call when the shape was answered with the call, so the step-5 choice lives in one place. - The live HTTP test declares its JSON-format-with-tools options once and reuses them for the 422 case. - The shape corpus comment describes the shapes instead of what the owner used to refuse. Same control flow, values and assertions.
* chore(release): prepare provider 0.10.1 Set ProviderCore.version to 0.10.1 and render the v0.10.1 changelog entry from the 13 fragments added since v0.10.0: the GLM-5.3-Flash and Nemotron 3.5 Super OpenRouter readiness work (#1561, #1560) and the many-file download progress display (#1558), plus already-merged installer, sign-in and release-note fixes (#1505, #1493, #1482). Order the entries by theme behind an upgrade and rollout section. Logprobs are deferred, so the native-engine entry keeps the typed refusal and calls the GLM logprob code disabled groundwork. Drop the forced-tool-choice refusal that the GLM JSON and forced-choice entry supersedes, and clarify the GLM startup savings and the wired-limit notice. Mark v0.10.0 as published on 2026-10-23. Record in the provider release runbook that darkbloom-platform#411 must be deployed before tagging, that no catalog row gains the logprobs capability for 0.10.1, and that #1561 re-pins mlx-swift-lm to the #340 squash commit before it merges. No tag, registration, upload or deployment is performed. * chore(release): render the desktop app entries into provider 0.10.1 The desktop app (#1518) merged to master after this preparation was rendered, so its six changelog fragments were still pending. Render them verbatim into the v0.10.1 entry and remove them: the desktop control API and hardware report ship in the provider CLI. Note in the rollout notes and the runbook that the provider release does not build, sign or publish the Electron desktop app, whose public distribution still needs a signed, notarized build and an update feed. * chore(release): render the Autopilot entry into provider 0.10.1 Autopilot placements, downloads and busy reasons (#1565) merged to master after the desktop update. Render its fragment into the v0.10.1 entry and remove it, correcting "startup is not slower": with consent, start first fetches the catalog, waiting up to 10 s. Add rollout notes: changes apply only to Macs with saved consent; the wider selected_models also counts toward reward qualification, approval counts and operation victims on the current coordinator; one reconnect after start; holds, adopted routing and downloads need darkbloom-platform#439. --------- Co-authored-by: Jonathan Spangler <5055076+jonathan308@users.noreply.github.com>
…probs follow-up master squash-merged #1561 (9389559) and #1560 (e483dcc), whose original heads this branch merged, then prepared provider 0.10.1, which rendered and deleted their changelog fragments. restack-after-squash.py refuses this stack (#1564 targets master and the squash trees differ from the original heads), so this is the content-aware signed merge. The resolution is master plus this branch's own diff (598af60..e74c482): - changelog.d: drop the GLM and Super fragments 0.10.1 rendered; keep nemotron-super-logprobs.md, which describes only this follow-up. - Conflicted docs, Super plan and tests, GLM logprobs tests: master's squashed content with this branch's hunks applied. - libs/mlx-swift-lm stays at 54a1004a (mlx-swift-lm #342 head; SDK main is still 6148b6da).
Summary
OpenRouter's provider-readiness test
input-video-urlfails onnvidia-nemotron-3.5-superwith400 invalid_request_error "invalid media input". The coordinator fetches the linked 6,934,922-byte MP4 and inlines it asdata:video/mp4;base64,…, which makes a request body of about 9.25 MB. The Super media binding's ingress quote (NemotronSuperLocalImageBinding.encodedHeaderQuote) refused any body over a hard-coded 8 MiB asFailure.invalidInput.SuperHTTPErrorsmaps that tomultimodalRejected, so the provider sentinvalid_media, which the coordinator returns as "invalid media input".Fix
NemotronSuperServingPolicy.maximumEncodedBodyBytesis now 40 MiB (was 8 MiB). That holds one part at the sharedMediaIngest.maxMediaDecodedBytesdefault (25 MiB decoded, 33.3 MiB as base64) plus the rest of the request. It also covers every body the provider's transports can deliver (localInferenceMaxUploadBytesandCoordinatorClient.maxInboundMessageBytes, both 32 MiB).encodedHeaderQuotenow takes its bound from that policy constant instead of its own literal. The charge formula is unchanged:body*32 + template*4 + 16 MiB.Failure.bodyTooLarge.SuperHTTPErrorsmaps it toMediaIngest.MediaError.mediaTooLargewith fixed text, so the wire code ismedia_too_large(the coordinator returns 413) instead ofinvalid_media. All other refusals keep their current mapping.Before
flowchart LR OR["OpenRouter<br/>input-video-url"]:::client --> C["Coordinator<br/>fetch 6.9 MB MP4,<br/>inline as data:video/mp4"]:::coord C -->|"9.25 MB body"| Q{"encodedHeaderQuote<br/>body <= 8 MiB?"}:::gate Q -->|"no"| E["Failure.invalidInput<br/>→ multimodalRejected<br/>→ invalid_media"]:::bad E --> R["400 'invalid media input'"]:::bad Q -.->|"yes (≤ 8 MiB only)"| P["inspect → prompt → plan<br/>→ frames → tower → generate"]:::ok classDef client fill:#dbeafe,stroke:#1d4ed8,color:#0b1b3f classDef coord fill:#ede9fe,stroke:#6d28d9,color:#1e0b4f classDef gate fill:#fef9c3,stroke:#a16207,color:#3b2a00 classDef bad fill:#fee2e2,stroke:#b91c1c,color:#450a0a classDef ok fill:#dcfce7,stroke:#15803d,color:#052e16After
flowchart LR OR["OpenRouter<br/>input-video-url"]:::client --> C["Coordinator<br/>fetch 6.9 MB MP4,<br/>inline as data:video/mp4"]:::coord C -->|"9.25 MB body"| Q{"encodedHeaderQuote<br/>body <= Policy.maximumEncodedBodyBytes<br/>(40 MiB)?"}:::gate Q -->|"yes"| P["inspect → prompt → plan<br/>→ frames → tower → generate"]:::ok P --> S["200 streamed answer"]:::ok Q -.->|"no (> 40 MiB)"| T["Failure.bodyTooLarge<br/>→ MediaError.mediaTooLarge<br/>→ media_too_large (413)"]:::warn classDef client fill:#dbeafe,stroke:#1d4ed8,color:#0b1b3f classDef coord fill:#ede9fe,stroke:#6d28d9,color:#1e0b4f classDef gate fill:#fef9c3,stroke:#a16207,color:#3b2a00 classDef warn fill:#ffedd5,stroke:#c2410c,color:#431407 classDef ok fill:#dcfce7,stroke:#15803d,color:#052e16Legend: green = served path, red = the refusal this PR removes, orange = what an over-bound body now returns.
Evidence
The new
NemotronSuperOpenRouterVideoTestsuse OpenRouter's real readiness clips. They are the SDK's committedMiMoOpenRouterresources at the pinnedlibs/mlx-swift-lmrevision, checked by SHA-256 and read through the source tree, so no new binaries are added.input-video-url.mp4(H.264 1280x720, 24 fps, 121 frames, edit list, AAC track)data:video/mp4;base64,[0,13,26,…,120], 5 tubelets, 42x24-patch gridinput-video-base64.mov(H.264 1490x534 QuickTime, VFR, 211 frames)data:video/quicktime;base64,[0,10,21,…,210], 11 tubelets, 52x18-patch gridmastercf3c45107, new tests only):bothClipsServeOnTheInstalledFixture()fails with.bodyTooLargeon the first clip.provider-swift/afterswift build --build-testsand../scripts/stage-test-metallib.sh, with isolatedDARKBLOOM_STATE_FILE/DARKBLOOM_LOADED_MODELS_FILE:swift test --skip-build --no-parallel --filter 'NemotronSuper|InferenceFailure|ErrorMapping|MediaIngest'→ 274 Swift Testing tests in 31 suites passed (plus the XCTest cases; only the gated pinned-checkpoint and reference-tokenizer cases skipped).make docs-check,make docs-impact-check BASE=origin/master,make changelog-check,make changelog-preview: all OK.No other check rejects either clip on the Super video path. The edit list and AAC track (URL clip), and VFR timing (base64 clip), all pass. So do the sampling plan, the grid (1,008 and 936 patches, both under 1,088), the decoded-pixel budget, the per-frame validation and the decode allowance.
Merge Danger
Door: two-way. This is a constant and an error mapping, with no wire, protocol or storage change.
media_too_largeis an existingInferenceFailureCode.Blast Radius: Super media quotes.
Runtime reservations still use each request's actual body size. Only the static worst case grows:
mediaChargeBytes(1)mediaChargeBytes(16)videoMediaChargeBytesThe ingress at the maximum body grows by exactly 1 GiB, and the two encoded copies grow by 48 MiB. A video stays under one largest image.
Capacity quotes for Super media probes need about 1.05 GiB more room.
defaultPrefixBankByteskeeps one image's charge free. Whereserving / 2binds (KV grants of about 34–50 GiB), the default bank is 512 MiB smaller: 3 → 2.5 GiB at 34 GiB, 8.5 → 8 GiB at 45 GiB. The 128 GiB default owner's bank (5.25 GiB) and the 256/512 GB banks (16 GiB) are unchanged, and the 128 GiB claim and gate tests still pass.The coordinator has no mirror of the 8 MiB bound or of these charges (checked on platform
masterf512258), so no companion platform PR is needed.Components touched
Protocol / interface changes
media_too_largefailure code is now used for an over-bound Super body.Documentation impact
docs/architecture/inference.md,docs/architecture/hardware-support.md(charges),docs/reference/nemotron-super-image-formats.md,docs/provider/direct-mode.md,docs/developer/test.md.Changelog
changelog.d/nemotron-super-video-body-bound.mdand ranmake changelog-check.Notes for reviewers
request_bytes670,210 forinput-video-base64and 93,577 forinput-image-base64. Subtracting each payload's base64 length and an equal JSON skeleton leaves a 28-character data-URI label for the video. That matchesdata:video/quicktime;base64,, which Super andMediaIngest.decodeVideoalready admit, soadmittedVideoDataURIPrefixesis unchanged. If adata:video/mov;base64,label is ever needed, the sharedMediaIngest.decodeVideomust accept it first, because Super'sinspectcalls it. Super's prefix list would then mirror that change.MediaIngest.MediaError.mediaTooLargeerrors raised inside the Super path, such as a part over 25 MiB decoded or a video over 600 s, still map toinvalid_media. That is the existinginvalidVideosTakeTheInvalidMediaPathcontract.MediaIngestalso usesmediaTooLargefor unreadable metadata, so passing it through would mislabel those cases.Refactor Pass
Outcome: one behavior-preserving test cleanup, signed commit
a2a51d5("refactor: share the Super video test owner with the OpenRouter clip tests"). A dedicated refactor subagent reviewed the whole diff againstorigin/master, editing only files already in it. This replaces the earlier "Not run" status: the worker that wrote the fix could not spawn subagents, so the coordinating session ran this gate.Changed (tests only; no source, docs, changelog, wire or charge change):
NemotronSuperOpenRouterVideoTests.bothClipsServeOnTheInstalledFixturehad copiedNemotronSuperVideoBindingTests' tiny-fixture video owner line for line (same tower, 16 GiB budget, pending-load lease, 4,096-token context and teardown checks), plus its event recorder. It now usesNemotronSuperVideoBindingTests.videoOwner(contextLength:),VideoOwner.close()andSuperVideoEvents, which are no longerprivate. The copiedOpenRouterVideoEventsactor and the unusedMLXLMCommonimport are gone. The assertions are unchanged.JSONSerializationbody is 9,393,454 B because slashes are escaped; the coordinator's body is about 9.25 MB.oversizeBodyIsMediaTooLargenow says only invalid input still leaves asinvalid_media. Capacity, busy and closed refusals map elsewhere.Reviewed, no change needed:
encodedHeaderQuote's guards,Failure.bodyTooLarge,SuperHTTPErrors.mapand themaximumEncodedBodyBytescomment match the invariants:media_too_large; any other bad body or template maps toinvalid_media.inlinedLinkVideoPassesIngress, the image decoder's unrelated scratch, and the frozenCHANGELOG.md.MiMoOpenRouterresources, with SHA-256 checks. I re-verified both digests, and no binaries were added.Outside this pass's files, resolved by the coordinating session in signed commit
fceb642("test: drop the stale 8 MiB body case from the Super HTTP bounds test"):NemotronSuperLocalHTTPTests.imageRequestsOutsideTheirBoundsAreRefusedWith400had a case labelled "body over the 8 MiB encoded ceiling". Its 8.4 MB body now passes the 40 MiB bound, and the case was refused only by the context bound that the next case already covers.text:helper parameter dropped and the test comment corrected. Over local HTTP the body bound can't be reached: the 32 MiB upload limit returns 413 first, which the same file already tests (contentTooLarge). The binding's over-cap refusal is covered byoversizeBodyIsMediaTooLarge.run-nested-suite.sh 'NemotronSuper|InferenceFailure|ErrorMapping|MediaIngest' --no-parallelreported✔ Test run with 274 tests in 31 suites passedwith 0 failures; the edited test passed. Skips are the same gated cases, and the runner's any-skip tripwire still exits 1.make docs-impact-check BASE=origin/masterpasses.Validation after the refactor (from
provider-swift/, reusing the worktree build):swift build --build-tests, then../scripts/stage-test-metallib.sh "$(swift build --show-bin-path)": OK.../scripts/run-nested-suite.sh 'NemotronSuper|InferenceFailure|ErrorMapping|MediaIngest' --no-parallel, with isolatedDARKBLOOM_STATE_FILE/DARKBLOOM_LOADED_MODELS_FILE, reported✔ Test run with 274 tests in 31 suites passedwith 0 failures. XCTest ran 36 cases, also with 0 failures.realTokenizerReproducesTheReferencePromptIDs,testRealTokenizerReproducesGoldenTokenIDs). Swift Testing's aggregate counts its 13 skips as passed.make docs-check(192 files OK),make docs-impact-check BASE=origin/master(coverage OK),make changelog-check(2 valid fragments) andmake changelog-previewall pass.Part 2 — OpenRouter capability shapes (merged via
9403e76f8fromfeat/super-openrouter-capabilities587e123b9)Before / After
flowchart LR subgraph Before A1[relayed request: json_object or json_schema + tools] --> B1[NemotronSuperRequestPlan.validateWireControls] B1 -->|unsupportedControl| C1[400 invalid inference request] end subgraph After A2[relayed request: json_object or json_schema + tools] --> B2[NemotronSuperRequestPlan] B2 --> D2[pinned template: tools + JSON instruction] D2 --> E2[NemotronSuperLocalOutput.finish] E2 -->|tool calls| F2[200 tool_calls; text unchanged] E2 -->|answer without calls| G2{normalizedContent: JSON for the format?} G2 -->|yes| H2[200 JSON content] G2 -->|no| I2[422] endWhat changed
NemotronSuperRequestPlan.validateWireControlsno longer refuses a JSONresponse format combined with tools.
NemotronSuperLocalOutput.finishvalidates the response format only for ananswer without calls; a call turn returns its calls with its text unchanged.
A required/named
tool_choicestill needs its call.Evidence
NemotronSuperOpenRouterCapabilityTests.everyCapabilityShapeIsServed):20 shapes = 10 OpenRouter capability tests x reasoning enabled/disabled,
built from the captured OpenRouter request (SHA-256
d63598aa…229844b,pinned to the platform conformance fixture), through inbound decode, native
controls, response-format preparation, request plan, pinned template render
and output parser.
cf3c45107: 16/20 served; the 4 JSON-format-with-tools shapesrefused at the request plan (
unsupportedControl).compliantResponsesPassTheOwnersParser: a compliant response for everyshape validates streamed and complete (calls with schema-valid arguments,
JSON objects, schema-conforming structured output, reasoning split off when
enabled).
jsonFormatWithToolsValidatesTheAnswerNotTheCall: call -> calls; JSONanswer -> content; prose answer -> 422; forced choice without a call -> error.
(
liveHTTPTextReasoningToolsAndStructuredOutput): JSON format with toolsreturns a call as
tool_callsand a JSON answer as content, streamed andnot; prose returns 422.
NemotronSuperOpenRouterCapabilityTests4/4,NemotronSuperLocalHTTPTests5/5,NemotronSuperLocalOutputTests13/13 XCTest.run-nested-suite.sh 'NemotronSuper' --no-parallel: 213 SwiftTesting tests in 29 suites passed; XCTest 36 executed, 0 failures, 1 skipped.
The runner exits 1 only for the 13 gated checkpoint/reference skips. With
NEMOTRON_SUPER_REFERENCE_DIR(pinned tokenizer and template): prompt golden4/4 XCTest and 12 Swift Testing tests passed, no skips.
NemotronSuperRunnerRelease from this branch, runnerSHA-256
fa8e8001…, metallib156f2624…, M3 Ultra emulating 128 GiB, KV 43GiB, production engine settings incl. MTP
3,2,2,2,1, checkpoint2026-10-20-nvfp4-r2): 20/20 OpenRouter shapes streamed as the relaydelivers them returned 200 and passed their checks, reasoning enabled
(160-1,243 reasoning chars) and disabled (none): every call shape returned
get_current_weather {"location":"Boston, MA","unit":"fahrenheit"}(including JSON format with tools, auto and required),
tool_choice: noneanswered without a call, the 5-step history summarized all four cities,
json_objectreturned an object and strictjson_schemaexactlylocation/temperature/conditions. Load 83 s; clean retirement (exit 0).fix/nemotron-super-video-body-cap(git merge-tree, no conflicts).Limitations
validation (unchanged). The prompt sidecar still declines to plan a JSON
format with tools for Super, so such requests use heuristic prompt work.
Refactor pass (Super capabilities)
Outcome: small behavior-preserving cleanup, signed commit
a86de72c3("refactor: tidy the Super JSON-format-with-tools output and tests"). A dedicated refactor subagent reviewed Part 2 (587e123b9) and edited only files from that commit. The request plan, wire behavior, docs and changelog are unchanged.Changed:
NemotronSuperLocalOutput.finish: the variable holding a call turn's text was namedanswer, but the comment above it says a call turn is not an answer. It is nowtext, and the conditional format check is split over three lines. Control flow and values are unchanged.NemotronSuperOpenRouterCapabilityTests.check: the"tool-call-step-5"name check appeared in bothcompliantAnswerandcheck.checknow expects the call whenever the test answered with the call (compliantAnswer(shape) == call), so the step-5 special case is defined only once. Each shape gets the same assertions as before.liveHTTPTextReasoningToolsAndStructuredOutput: the JSON-format-with-tools options are declared once and reused for the 422 case.SuperOpenRouterCapabilityShapes.all()comment now describes the shapes instead of what the owner "used to refuse".Reviewed, no change needed:
validateWireControlsstill refuseslogprobs,top_logprobs,prompt_cache_key,n > 1,logit_bias,min_p,tool_call_parserandreasoning_parser. Its comment explains why JSON with tools is not refused.tool_choicestill needs its call.routerefuses visible text, andfinishrefuses a non-whitespace residual before the format check.normalizedContent(422 for invalid JSON). Without a JSON format, the text passes through unchanged, as before.inference.md,direct-mode.md,test.mdand the changelog fragment match the code.Validation (fresh detached worktree at
9403e76f8plus the commit, run fromprovider-swift/):swift build --build-testsand../scripts/stage-test-metallib.sh "$(swift build --show-bin-path)". The metallib SHA-256 is156f2624….../scripts/run-nested-suite.sh 'NemotronSuper' --no-parallelran with isolatedDARKBLOOM_STATE_FILEandDARKBLOOM_LOADED_MODELS_FILE:✔ Test run with 218 tests in 30 suites passed. This branch has one more suite than the 213/29 figure above,NemotronSuperOpenRouterVideoTestsfrom Part 1.everyCapabilityShapeIsServed: 20/20 shapes served.make docs-check(192 files OK),make docs-impact-check BASE=origin/master(coverage OK),make changelog-check(3 valid fragments) andmake changelog-previewall pass.Need help on this PR? Tag
@codesmith-botwith what you need.