TensorRT-LLM Local Deployment Examples

Copyable commands for running the TensorRT-LLM launch scripts in the Dynamo repository.

View as Markdown

Clone the NVIDIA Dynamo repository before running an example. The launch scripts load supporting files through paths relative to examples/backends/trtllm.

$git clone https://github.com/ai-dynamo/dynamo.git
$cd dynamo/examples/backends/trtllm

Review the selected script and confirm its model, GPU, and environment requirements before running the command. Set the environment variables defined at the top of a script to override its defaults.

Aggregated

Starts the frontend and one TensorRT-LLM worker that handles both prefill and decode. Use it as the baseline local text-generation deployment.

The default model is Qwen/Qwen3-0.6B.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-0.6BModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-0.6BModel name registered with and accepted by the frontend.
AGG_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/agg.yamlTensorRT-LLM engine configuration for the aggregated worker.
MODALITYtextInput modality registered by the worker.
OTEL_EXPORTER_OTLP_TRACES_ENDPOINThttp://localhost:4317OpenTelemetry Protocol endpoint that receives traces.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.

Command-line flags: --enable-otel enables OpenTelemetry tracing; --unified uses the unified backend entry point.

Pass-through arguments: Additional unrecognized arguments are forwarded to the backend worker command.

$./launch/agg.sh

View the launch script.

Runs the baseline topology with the worker metrics configuration enabled. Use it to inspect TensorRT-LLM and Dynamo metrics during local testing.

The default model is Qwen/Qwen3-0.6B.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-0.6BModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-0.6BModel name registered with and accepted by the frontend.
AGG_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/agg.yamlTensorRT-LLM engine configuration for the aggregated worker.
MODALITYtextInput modality registered by the worker.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
DYN_SYSTEM_PORT8081System and metrics port for the worker.
$./launch/agg_metrics.sh

View the launch script.

Starts one multimodal TensorRT-LLM worker for requests that combine media and text. Override the model and engine settings through the environment variables defined by the script.

The default model is Qwen/Qwen2-VL-7B-Instruct.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen2-VL-7B-InstructModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen2-VL-7B-InstructModel name registered with and accepted by the frontend.
AGG_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen2-vl-7b-instruct/agg.yamlTensorRT-LLM engine configuration for the aggregated worker.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/agg_multimodal.sh

View the launch script.

Places a multimodal router worker between the frontend and TensorRT-LLM. The router computes media hashes and uses cache overlap to select a backend worker.

The default model is Qwen/Qwen3-VL-2B-Instruct.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-VL-2B-InstructModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-VL-2B-InstructModel name registered with and accepted by the frontend.
AGG_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/agg.yamlTensorRT-LLM engine configuration for the aggregated worker.
MODEL_TYPEqwen3_vlTensorRT-LLM multimodal model type used by the router worker.
BLOCK_SIZE32KV-cache block size; it must match the backend block size for KV routing.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/agg_multimodal_router.sh

View the launch script.

Starts workers behind the KV router and publishes cache events for prefix-aware request placement. Use it to test cache reuse across replicated workers.

The default model is Qwen/Qwen3-0.6B.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-0.6BModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-0.6BModel name registered with and accepted by the frontend.
AGG_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/agg.yamlTensorRT-LLM engine configuration for the aggregated worker.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/agg_router.sh

View the launch script.

Runs the KV router in approximate mode, which predicts cache placement without consuming backend KV events. Use it when the workers cannot publish cache events.

The default model is Qwen/Qwen3-0.6B.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-0.6BModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-0.6BModel name registered with and accepted by the frontend.
AGG_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/agg.yamlTensorRT-LLM engine configuration for the aggregated worker.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/agg_router_approx.sh

View the launch script.

Disaggregated

Runs prefill and decode in separate TensorRT-LLM workers and transfers KV cache between them. Use it to tune or scale the two inference stages independently.

The default model is Qwen/Qwen3-0.6B.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-0.6BModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-0.6BModel name registered with and accepted by the frontend.
PREFILL_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/prefill.yamlTensorRT-LLM engine configuration for the prefill worker.
DECODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/decode.yamlTensorRT-LLM engine configuration for the decode worker.
PREFILL_CUDA_VISIBLE_DEVICES0GPU devices assigned to the prefill worker.
DECODE_CUDA_VISIBLE_DEVICES1GPU devices assigned to the decode worker.
MODALITYtextInput modality registered by the worker.
OTEL_EXPORTER_OTLP_TRACES_ENDPOINThttp://localhost:4317OpenTelemetry Protocol endpoint that receives traces.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
DYN_SYSTEM_PORT18081System and metrics port for the first worker.
DYN_SYSTEM_PORT28082System and metrics port for the second worker.

Command-line flags: --unified uses the unified backend entry point; --enable-otel enables OpenTelemetry tracing.

$./launch/disagg.sh

View the launch script.

Adds KV-aware placement to the disaggregated topology. Requests with reusable prefixes are routed to the prefill worker that is most likely to hold the matching cache blocks.

The default model is Qwen/Qwen3-0.6B.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-0.6BModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-0.6BModel name registered with and accepted by the frontend.
PREFILL_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/prefill.yamlTensorRT-LLM engine configuration for the prefill worker.
DECODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/decode.yamlTensorRT-LLM engine configuration for the decode worker.
PREFILL_CUDA_VISIBLE_DEVICES0GPU devices assigned to the prefill worker.
DECODE_CUDA_VISIBLE_DEVICES1GPU devices assigned to the decode worker.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/disagg_router.sh

View the launch script.

Runs separate prefill and decode processes on one GPU with explicit KV-token limits. Use it for functional testing of disaggregation on a single-GPU host.

The default model is Qwen/Qwen3-0.6B.

Configuration

VariableDefaultDescription
MAX_SEQ_LEN4096Maximum sequence length configured for TensorRT-LLM.
MAX_CONCURRENT_SEQS2Maximum number of sequences scheduled concurrently.
MAX_TOTAL_TOKENS25000TensorRT-LLM KV-cache token capacity per worker.
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
PREFILL_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/prefill.yamlTensorRT-LLM engine configuration for the prefill worker.
DECODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3/decode.yamlTensorRT-LLM engine configuration for the decode worker.
CUDA_VISIBLE_DEVICES0GPU devices visible to the launched worker processes.
MODALITYtextInput modality registered by the worker.
OTEL_EXPORTER_OTLP_TRACES_ENDPOINThttp://localhost:4317OpenTelemetry Protocol endpoint that receives traces.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
DYN_SYSTEM_PORT18081System and metrics port for the first worker.
DYN_SYSTEM_PORT28082System and metrics port for the second worker.

Command-line flags: --enable-otel enables OpenTelemetry tracing.

$./launch/disagg_same_gpu.sh

View the launch script.

Launches GPT-OSS 120B with one four-GPU prefill worker and one four-GPU decode worker. The complete topology requires eight GPUs.

The local model path defaults to /model, and the served model name defaults to openai/gpt-oss-120b.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATH/modelModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEopenai/gpt-oss-120bModel name registered with and accepted by the frontend.
PREFILL_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/gpt-oss-120b/prefill.yamlTensorRT-LLM engine configuration for the prefill worker.
DECODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/gpt-oss-120b/decode.yamlTensorRT-LLM engine configuration for the decode worker.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/gpt_oss_disagg.sh

View the launch script.

Multimodal and Diffusion

Aggregated

Starts an image-diffusion worker with FLUX as the default model. The default configuration uses one GPU.

The default model is black-forest-labs/FLUX.2-klein-4B.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHblack-forest-labs/FLUX.2-klein-4BModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEblack-forest-labs/FLUX.2-klein-4BModel name registered with and accepted by the frontend.
MEDIA_OUTPUT_FS_URLfile:///tmp/dynamo_mediaObject-store URL where generated media is written.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.

Pass-through arguments: Additional unrecognized arguments are forwarded to the backend worker command.

$./launch/agg_image_diffusion.sh

View the launch script.

Starts a video-diffusion worker with a Wan model as the default. The default configuration uses one GPU.

The default model is Wan-AI/Wan2.1-T2V-1.3B-Diffusers.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHWan-AI/Wan2.1-T2V-1.3B-DiffusersModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEWan-AI/Wan2.1-T2V-1.3B-DiffusersModel name registered with and accepted by the frontend.
MEDIA_OUTPUT_FS_URLfile:///tmp/dynamo_mediaObject-store URL where generated media is written.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.

Pass-through arguments: Additional unrecognized arguments are forwarded to the backend worker command.

$./launch/agg_video_diffusion.sh

View the launch script.

Disaggregated

Runs a vision encoder separately from a worker that performs both prefill and decode. The default Qwen vision-language configuration co-locates both workers on one GPU.

The default model is Qwen/Qwen3-VL-2B-Instruct.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-VL-2B-InstructModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-VL-2B-InstructModel name registered with and accepted by the frontend.
ENCODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/encode.yamlTensorRT-LLM engine configuration for the encode worker.
PD_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/agg.yamlTensorRT-LLM engine configuration for the combined prefill/decode worker.
ENCODE_CUDA_VISIBLE_DEVICES0GPU devices assigned to the encode worker.
ENCODE_ENDPOINTdyn://dynamo.encode.generateDynamo endpoint used to send work to the encode worker.
ALLOWED_LOCAL_MEDIA_PATH/tmpLocal directory from which multimodal requests may load media.
MAX_FILE_SIZE_MB50Maximum accepted local media file size, in MiB.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
DYN_SYSTEM_PORT18081System and metrics port for the first worker.
DYN_SYSTEM_PORT28082System and metrics port for the second worker.
$./launch/disagg_e_pd.sh

View the launch script.

Splits multimodal inference across prefill and decode workers while applying the script’s KV-cache settings to both stages. Use it to test multimodal KV transfer.

The default model is Qwen/Qwen3-VL-2B-Instruct.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-VL-2B-InstructModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen3-VL-2B-InstructModel name registered with and accepted by the frontend.
PREFILL_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/prefill.yamlTensorRT-LLM engine configuration for the prefill worker.
DECODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/decode.yamlTensorRT-LLM engine configuration for the decode worker.
PREFILL_CUDA_VISIBLE_DEVICES0GPU devices assigned to the prefill worker.
DECODE_CUDA_VISIBLE_DEVICES1GPU devices assigned to the decode worker.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/disagg_multimodal.sh

View the launch script.

Runs each multimodal stage in its own worker so encoding, prefill, and decode can be placed and tuned independently.

The default model is meta-llama/Llama-4-Scout-17B-16E-Instruct.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHmeta-llama/Llama-4-Scout-17B-16E-InstructModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEmeta-llama/Llama-4-Scout-17B-16E-InstructModel name registered with and accepted by the frontend.
PREFILL_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/llama4/multimodal/llama4-Scout/prefill.yamlTensorRT-LLM engine configuration for the prefill worker.
DECODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/llama4/multimodal/llama4-Scout/decode.yamlTensorRT-LLM engine configuration for the decode worker.
ENCODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/llama4/multimodal/llama4-Scout/encode.yamlTensorRT-LLM engine configuration for the encode worker.
PREFILL_CUDA_VISIBLE_DEVICES0,1,2,3GPU devices assigned to the prefill worker.
DECODE_CUDA_VISIBLE_DEVICES4,5,6,7GPU devices assigned to the decode worker.
ENCODE_CUDA_VISIBLE_DEVICES0GPU devices assigned to the encode worker.
ENCODE_ENDPOINTdyn://dynamo.encode.generateDynamo endpoint used to send work to the encode worker.
ALLOWED_LOCAL_MEDIA_PATH/tmpLocal directory from which multimodal requests may load media.
MAX_FILE_SIZE_MB50Maximum accepted local media file size, in MiB.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
$./launch/epd_disagg.sh

View the launch script.

Runs the encode-prefill-decode pipeline with the multimodal image and embedding-transfer path enabled. Use it to test transferring prepared media features between workers.

The default model is Qwen/Qwen3-VL-2B-Instruct.

Configuration

VariableDefaultDescription
DYNAMO_HOME/workspaceDynamo checkout or container workspace used to resolve configuration files.
MODEL_PATHQwen/Qwen3-VL-2B-InstructModel identifier or local model path passed to TensorRT-LLM.
SERVED_MODEL_NAMEQwen/Qwen3-VL-2B-InstructModel name registered with and accepted by the frontend.
PREFILL_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/prefill.yamlTensorRT-LLM engine configuration for the prefill worker.
DECODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/decode.yamlTensorRT-LLM engine configuration for the decode worker.
ENCODE_ENGINE_ARGS$DYNAMO_HOME/examples/backends/trtllm/engine_configs/qwen3-vl-2b-instruct/encode.yamlTensorRT-LLM engine configuration for the encode worker.
PREFILL_CUDA_VISIBLE_DEVICES0GPU devices assigned to the prefill worker.
DECODE_CUDA_VISIBLE_DEVICES0GPU devices assigned to the decode worker.
ENCODE_CUDA_VISIBLE_DEVICES0GPU devices assigned to the encode worker.
ENCODE_ENDPOINTdyn://dynamo.encode.generateDynamo endpoint used to send work to the encode worker.
ALLOWED_LOCAL_MEDIA_PATH/tmpLocal directory from which multimodal requests may load media.
MAX_FILE_SIZE_MB50Maximum accepted local media file size, in MiB.
DYN_HTTP_PORT8000HTTP port exposed by the Dynamo frontend.
DYN_SYSTEM_PORT18081System and metrics port for the first worker.
DYN_SYSTEM_PORT28082System and metrics port for the second worker.
DYN_SYSTEM_PORT38083System and metrics port for the third worker.
$./launch/epd_multimodal_image_and_embeddings.sh

View the launch script.

Source

Browse all TensorRT-LLM launch scripts in the Dynamo repository.