NVIDIA Request Extensions (nvext)
NVIDIA Request Extensions (nvext)
nvext is a top-level JSON object on the request body that provides NVIDIA-specific extensions to the OpenAI-compatible API. nvext fields are consumed by the Dynamo frontend, preprocessor, router, and backend workers to control routing, preprocessing, response metadata, scheduling, and engine-level priority.
Usage
Include nvext as a top-level field alongside standard OpenAI-compatible fields:
Field Reference
Header Overrides
Routing fields can also be set via HTTP headers, which take priority over nvext values:
Agent Hints
The agent_hints sub-object carries per-request hints that the router uses for scheduling, load balancing, and KV cache optimization.
priority
priority is the single user-facing scheduling hint. Higher values mean “more important” across Dynamo.
When --router-queue-threshold is set and the queue is active, higher-priority requests are shifted earlier in the router queue. Once dispatched, Dynamo forwards the same semantic priority to the backend engine for queue ordering, preemption, and KV cache eviction. Dynamo normalizes backend-specific polarity internally, including vLLM’s lower-is-higher convention.
osl
Expected output sequence length — the estimated number of output tokens the request will generate. The router uses this hint in two ways:
- Output block tracking: When
--router-track-output-blocksis enabled, the router adds placeholder blocks during generation and applies fractional decay based on progress towardosl. - Resource estimation: Helps the router estimate total resource requirements when making routing decisions.
speculative_prefill
When set to true, the system speculatively prefills the predicted next-turn prompt after the current assistant turn completes. This is designed for multi-turn agentic workloads where the next request’s prefix is predictable.
How it works:
- As the assistant response streams, the system accumulates the full response text.
- Once the response finishes, a background task constructs the next-turn prompt by appending the assistant response to the conversation history (with thinking content stripped for non-last turns).
- The constructed prompt is tokenized and sent as a
max_tokens=1request to warm the KV cache on a worker. - When the actual next request arrives, it benefits from the already-warm KV cache, reducing TTFT.
Backend details:
- SGLang: Requires
--enable-priority-schedulingfor queue ordering and--radix-eviction-policy priorityfor priority-based eviction. - vLLM: Requires
--scheduling-policy priority. - TensorRT-LLM: Does not currently support per-request priority.
Session Control
session_control enables subagent KV isolation with sticky routing. The router uses session_id to keep a session on the same worker and can issue open / close lifecycle RPCs around streaming sessions.
Requires --router-mode=kv on the frontend. Session control activates automatically when requests carry nvext.session_control. See SGLang for Agentic Workloads for backend setup details.
Response Extensions
When the client requests response metadata via extra_fields, the response includes an nvext object with the requested fields: