diff --git a/.github/configs/amd-master.yaml b/.github/configs/amd-master.yaml index fb3966ce6..7f1c8192d 100644 --- a/.github/configs/amd-master.yaml +++ b/.github/configs/amd-master.yaml @@ -304,25 +304,6 @@ qwen3.5-fp8-mi355x-sglang-mtp: - { tp: 2, ep: 2, conc-start: 4, conc-end: 32, spec-decoding: mtp } - { tp: 4, ep: 1, conc-start: 32, conc-end: 256, spec-decoding: mtp } -# Diverged from qwen3.5-fp8-mi355x-sglang (agentic-coding sibling). Metadata is -# identical to origin/main's qwen3.5-fp8-mi355x-sglang; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original qwen3.5-fp8-mi355x-sglang entry stays byte-identical to origin/main. -qwen3.5-fp8-mi355x-sglang-agentic: - image: lmsysorg/sglang-rocm:v0.5.10rc0-rocm720-mi35x-20260414 - model: Qwen/Qwen3.5-397B-A17B-FP8 - model-prefix: qwen3.5 - runner: mi355x - precision: fp8 - framework: sglang - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } - qwen3.5-fp8-mi355x-atom: image: rocm/atom:rocm7.2.3_ubuntu24.04_py3.12_pytorch_release_2.10.0_atom20260511 model: Qwen/Qwen3.5-397B-A17B-FP8 @@ -704,26 +685,6 @@ glm5.1-fp4-mi355x-sglang: - { tp: 2, conc-start: 4, conc-end: 256 } - { tp: 4, conc-start: 4, conc-end: 16 } -# Diverged from glm5.1-fp4-mi355x-sglang (agentic-coding sibling). Metadata is -# identical to origin/main's glm5.1-fp4-mi355x-sglang; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original glm5.1-fp4-mi355x-sglang entry stays byte-identical to origin/main. -glm5.1-fp4-mi355x-sglang-agentic: - image: lmsysorg/sglang-rocm:v0.5.10rc0-rocm720-mi35x-20260415 - model: amd/GLM-5.1-MXFP4 - model-prefix: glm5.1 - runner: mi355x - precision: fp4 - framework: sglang - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - # sglang manages KV eviction; mi355x glm5.1 caps at tp=4 conc=16 in fixed-seq, so cap conservatively - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } - glm5.1-fp4-mi355x-atom: image: rocm/atom:rocm7.2.2_ubuntu24.04_py3.12_pytorch_release_2.10.0_atom0.1.2.post model: amd/GLM-5.1-MXFP4 @@ -744,7 +705,7 @@ glm5.1-fp4-mi355x-atom: - { tp: 4, conc-start: 4, conc-end: 256 } kimik2.5-int4-mi355x-vllm: - image: vllm/vllm-openai-rocm:v0.21.0 + image: vllm/vllm-openai-rocm:v0.22.0 model: moonshotai/Kimi-K2.5 model-prefix: kimik2.5 runner: mi355x @@ -763,7 +724,7 @@ kimik2.5-int4-mi355x-vllm: - { tp: 8, conc-start: 4, conc-end: 64 } kimik2.5-int4-mi325x-vllm: - image: vllm/vllm-openai-rocm:v0.21.0 + image: vllm/vllm-openai-rocm:v0.22.0 model: moonshotai/Kimi-K2.5 model-prefix: kimik2.5 runner: mi325x @@ -782,7 +743,7 @@ kimik2.5-int4-mi325x-vllm: - { tp: 8, conc-start: 4, conc-end: 64 } kimik2.5-int4-mi300x-vllm: - image: vllm/vllm-openai-rocm:v0.21.0 + image: vllm/vllm-openai-rocm:v0.22.0 model: moonshotai/Kimi-K2.5 model-prefix: kimik2.5 runner: mi300x @@ -821,38 +782,6 @@ kimik2.5-fp4-mi355x-vllm: - { tp: 8, conc-start: 4, conc-end: 64 } - { tp: 4, conc-start: 4, conc-end: 64 } -# Diverged from kimik2.5-fp4-mi355x-vllm (agentic-coding sibling). Reasons below; -# the original kimik2.5-fp4-mi355x-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai-rocm:v0.18.0' -> 'vllm/vllm-openai-rocm:v0.21.0' -kimik2.5-fp4-mi355x-vllm-agentic: - # v0.21.0 (released 2026-05-14) supersedes the prior nightly pin - # (51f22dcf...) which was carrying the SimpleCPUOffloadConnector ROCm - # cpu_offload_blocks > 0 fix. v0.21.0 is much newer than that fix and - # includes all subsequent ROCm offload work. - image: vllm/vllm-openai-rocm:v0.21.0 - model: amd/Kimi-K2.5-MXFP4 - model-prefix: kimik2.5 - runner: mi355x - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 16, 24, 32, 40, 48] } - # CPU offload only above the KV cliff. Lower concurrencies fit - # entirely on-GPU, so paying the offload-path overhead there would - # just slow them down without measuring anything new. - - { tp: 8, offloading: cpu, conc-list: [32, 40, 48, 56] } - # TP=4 probe: half-node layout doubles per-GPU weight footprint - # (~62 GB on MI355X's 288 GB HBM, plenty of headroom). Restrict to - # cliff-region concurrencies on both offload modes so we can directly - # compare TP=4 vs TP=8 at the same conc points. - - { tp: 4, offloading: none, conc-list: [16, 24, 32, 40] } - - { tp: 4, offloading: cpu, conc-list: [16, 24, 32, 40] } - kimik2.5-fp4-mi355x-atom: image: rocm/atom:rocm7.2.3_ubuntu24.04_py3.12_pytorch_release_2.10.0_atom20260511 model: amd/Kimi-K2.5-MXFP4 @@ -897,33 +826,6 @@ minimaxm2.5-fp8-mi355x-vllm: - { tp: 4, ep: 4, conc-start: 4, conc-end: 512 } - { tp: 8, ep: 8, conc-start: 2, conc-end: 2 } -# Diverged from minimaxm2.5-fp8-mi355x-vllm (agentic-coding sibling). Reasons below; -# the original minimaxm2.5-fp8-mi355x-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai-rocm:v0.19.0' -> 'vllm/vllm-openai-rocm:nightly-51f22dcfd068fe8f1e3192da2a1e825b930223cf' -minimaxm2.5-fp8-mi355x-vllm-agentic: - # Nightly carrying vllm-project/vllm@20cac26b ("[Bug fix][KV Connector] - # add cpu_offload_blocks > 0 check before maybe_run_layer_kv_offload"), - # which enables SimpleCPUOffloadConnector on ROCm. Required for the - # cpu-offload sweep points to use the same offload path as the NVIDIA - # agentic-coding configs. - image: vllm/vllm-openai-rocm:nightly-51f22dcfd068fe8f1e3192da2a1e825b930223cf - model: MiniMaxAI/MiniMax-M2.5 - model-prefix: minimaxm2.5 - runner: mi355x - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - # MI355X tp=4 ep=4: compute ceiling ~60 (empirical), KV cliff ~91 (analytical). - # Compute saturates first; cpu offload likely won't help, but worth confirming. - # AMD uses native OffloadingConnector (NOT SimpleCPUOffloadConnector). - - duration: 1800 - search-space: - - { tp: 4, ep: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 48, 56, 64, 72, 96] } - - { tp: 4, ep: 4, offloading: cpu, conc-list: [48, 56, 64, 72, 96] } - minimaxm2.5-fp8-mi355x-atom: image: rocm/atom:rocm7.2.2_ubuntu24.04_py3.12_pytorch_release_2.10.0_atom0.1.2.post model: MiniMaxAI/MiniMax-M2.5 @@ -994,7 +896,7 @@ minimaxm2.5-fp4-mi355x-vllm: - { tp: 4, conc-start: 4, conc-end: 64 } minimaxm2.5-fp8-mi300x-vllm: - image: vllm/vllm-openai-rocm:v0.21.0 + image: vllm/vllm-openai-rocm:v0.22.0 model: MiniMaxAI/MiniMax-M2.5 model-prefix: minimaxm2.5 runner: mi300x @@ -1014,29 +916,6 @@ minimaxm2.5-fp8-mi300x-vllm: - { tp: 2, conc-start: 4, conc-end: 64 } - { tp: 4, conc-start: 4, conc-end: 64 } -# Diverged from minimaxm2.5-fp8-mi300x-vllm (agentic-coding sibling). Reasons below; -# the original minimaxm2.5-fp8-mi300x-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai-rocm:v0.16.0' -> 'vllm/vllm-openai-rocm:nightly-51f22dcfd068fe8f1e3192da2a1e825b930223cf' -minimaxm2.5-fp8-mi300x-vllm-agentic: - # Nightly carrying vllm-project/vllm@20cac26b — see mi355x config above. - image: vllm/vllm-openai-rocm:nightly-51f22dcfd068fe8f1e3192da2a1e825b930223cf - model: MiniMaxAI/MiniMax-M2.5 - model-prefix: minimaxm2.5 - runner: mi300x - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - # MI300X tp=4: compute ceiling ~25 (estimated, between H100 and H200); - # KV cliff ~52. Compute saturates first. - # AMD uses native OffloadingConnector (NOT SimpleCPUOffloadConnector). - - duration: 1800 - search-space: - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 20, 24, 28, 32, 40, 48] } - - { tp: 4, offloading: cpu, conc-list: [16, 20, 24, 28, 32] } - minimaxm2.5-fp8-mi325x-vllm: image: vllm/vllm-openai-rocm:v0.22.0 model: MiniMaxAI/MiniMax-M2.5 @@ -1058,32 +937,8 @@ minimaxm2.5-fp8-mi325x-vllm: - { tp: 2, conc-start: 4, conc-end: 64 } - { tp: 8, ep: 8, conc-start: 4, conc-end: 256 } -# Diverged from minimaxm2.5-fp8-mi325x-vllm (agentic-coding sibling). Reasons below; -# the original minimaxm2.5-fp8-mi325x-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai-rocm:v0.18.0' -> 'vllm/vllm-openai-rocm:nightly-51f22dcfd068fe8f1e3192da2a1e825b930223cf' -minimaxm2.5-fp8-mi325x-vllm-agentic: - # Nightly carrying vllm-project/vllm@20cac26b — see mi355x config above. - image: vllm/vllm-openai-rocm:nightly-51f22dcfd068fe8f1e3192da2a1e825b930223cf - model: MiniMaxAI/MiniMax-M2.5 - model-prefix: minimaxm2.5 - runner: mi325x - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - # MI325X tp=4: cloned from MI300X recipe (slightly faster compute, - # similar HBM profile). Compute saturates first; cpu-offload window - # exercises the SimpleCPUOffloadConnector path enabled by the rocm - # nightly. Mirror MI300X conc grid for cross-vendor comparability. - - duration: 1800 - search-space: - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 20, 24, 28, 32, 40, 48] } - - { tp: 4, offloading: cpu, conc-list: [16, 20, 24, 28, 32] } - gptoss-fp4-mi300x-vllm: - image: vllm/vllm-openai-rocm:v0.17.0 + image: vllm/vllm-openai-rocm:v0.22.0 model: openai/gpt-oss-120b model-prefix: gptoss runner: mi300x @@ -1524,7 +1379,7 @@ dsr1-fp8-mi355x-sglang-disagg-mtp: - "DECODE_MTP_SIZE=2" kimik2.5-fp4-mi355x-vllm-disagg: - image: vllm/vllm-openai-rocm:nightly-bf610c2f56764e1b30bc6065f4ceace3d6e59036 + image: vllm/vllm-openai-rocm:v0.22.0 model: amd/Kimi-K2.5-MXFP4 model-prefix: kimik2.5 runner: mi355x-disagg @@ -1578,7 +1433,7 @@ kimik2.5-fp4-mi355x-vllm-disagg: - "DECODE_NODES=2" minimaxm2.5-fp8-mi355x-vllm-disagg: - image: vllm/vllm-openai-rocm:nightly-a6682d1d259cca69a9ae737ea5608fbbe7520031 + image: vllm/vllm-openai-rocm:v0.22.0 model: MiniMaxAI/MiniMax-M2.5 model-prefix: minimaxm2.5 runner: mi355x-disagg @@ -1971,7 +1826,6 @@ dsr1-fp4-mi355x-sglang-disagg-1k1k-mtp: - "DECODE_NODES=1" - "DECODE_MTP_SIZE=1" - dsr1-fp4-mi355x-sglang-disagg-8k1k-mtp: image: lmsysorg/sglang-rocm:v0.5.12.post1-rocm720-mi35x-20260529 model: amd/DeepSeek-R1-0528-MXFP4-v2 @@ -2082,7 +1936,6 @@ dsr1-fp4-mi355x-sglang-disagg-8k1k-mtp: - "DECODE_NODES=1" - "DECODE_MTP_SIZE=3" - # 1*DEP8 + 1*DEP8 - spec-decoding: "mtp" conc-list: [ 128 ] @@ -2140,11 +1993,6 @@ dsr1-fp4-mi355x-sglang-disagg-8k1k-mtp: - "DECODE_NODES=1" - "DECODE_MTP_SIZE=1" - -# DSv4-Pro FP4 on MI355X via SGLang. Uses a rocm720 mi35x image built off the -# amd/deepseek_v4 branch in sgl-project/sglang; the SHA is encoded in the -# image tag, so bumping sglang is just an image tag bump here. Sweeps -# DP-attention on/off and EP=8. dsv4-fp4-mi355x-sglang: image: rocm/sgl-dev:rocm720-mi35x-f96ac98-20260526-DSv4 model: deepseek-ai/DeepSeek-V4-Pro @@ -2201,25 +2049,6 @@ dsv4-fp4-mi355x-sglang-mtp: - { tp: 8, dp-attn: true, conc-start: 64, conc-end: 2048, spec-decoding: mtp } - { tp: 8, dp-attn: false, conc-start: 1, conc-end: 32, spec-decoding: mtp } -# DSv4 on MI355X via vLLM, using the official vllm/vllm-openai-rocm -# nightly image. DSv4 base ROCm support (vllm-project/vllm#40871) merged -# on 2026-05-05, so any nightly built after that includes the -# DeepseekV4ForCausalLM model class. -# -# IMPORTANT: pin to a digest-suffixed nightly tag rather than the -# floating `:nightly`. launch_mi355x-amds.sh caches enroot squashfs -# files keyed on the image string and short-circuits re-import if the -# file already exists, so the floating tag silently keeps a stale build -# even after Docker Hub updates `:nightly`. -# -# DeepSeek-V4-Pro is FP4+FP8 mixed (FP4 MoE expert weights, FP8 for the -# rest); InferenceX classifies this as fp4 — same as the sister sglang -# and atom DSv4 mi355x entries below. Image and serving flags follow the -# validated recipe from vllm-project/recipes#433: AITER+AITER_LINEAR, mp -# executor, triton_unfused MoE (required for the FP4 expert format), -# async scheduling, max-num-seqs=128, max-num-batched-tokens=8192, -# gpu-mem-util=0.6. TP8 sweeps conc 4-64; DEP8 has a single conc=64 -# probe to validate the ROCm DP+EP path. dsv4-fp4-mi355x-vllm: image: vllm/vllm-openai-rocm:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro @@ -2408,44 +2237,6 @@ glm5-fp8-mi325x-sglang-mtp: search-space: - { tp: 8, ep: 1, conc-start: 4, conc-end: 64, spec-decoding: mtp } -# ============================================================================ -# Net-new agentic recipes from chore/agentx-v0.3 (no overlap with main entries). -# Recipes that ALREADY existed on main were intentionally left at main's version -# to preserve main behavior; PR-branch modifications to those recipes are NOT -# brought in here. -# ============================================================================ - -qwen3.5-fp8-mi355x-sglang-agentic-hicache: - image: lmsysorg/sglang-rocm:v0.5.12-rocm720-mi35x-20260521 - model: Qwen/Qwen3.5-397B-A17B-FP8 - model-prefix: qwen3.5 - runner: mi355x - precision: fp8 - framework: sglang - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } - - { tp: 8, ep: 1, offloading: hicache, conc-list: [16, 32, 48, 64] } - -dsv4-fp4-mi355x-vllm-agentic: - image: vllm/vllm-openai-rocm:v0.21.0 - model: deepseek-ai/DeepSeek-V4-Pro - model-prefix: dsv4 - runner: mi355x - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, offloading: none, conc-list: [1, 2, 4] } - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 10, 12, 16] } - - { tp: 4, ep: 4, dp-attn: true, offloading: none, conc-list: [16, 24, 32, 40, 48] } - dsr1-fp4-mi355x-sglang-disagg-mtp: image: lmsysorg/sglang-rocm:v0.5.12-rocm720-mi35x-20260519 model: amd/DeepSeek-R1-0528-MXFP4-v2 @@ -2674,20 +2465,145 @@ dsr1-fp4-mi355x-sglang-disagg-mtp: - "DECODE_NODES=1" - "DECODE_MTP_SIZE=1" +qwen3.5-fp8-mi355x-sglang-agentic: + image: lmsysorg/sglang-rocm:v0.5.10rc0-rocm720-mi35x-20260414 + model: Qwen/Qwen3.5-397B-A17B-FP8 + model-prefix: qwen3.5 + runner: mi355x + precision: fp8 + framework: sglang + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } + +glm5.1-fp4-mi355x-sglang-agentic: + image: lmsysorg/sglang-rocm:v0.5.10rc0-rocm720-mi35x-20260415 + model: amd/GLM-5.1-MXFP4 + model-prefix: glm5.1 + runner: mi355x + precision: fp4 + framework: sglang + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + # sglang manages KV eviction; mi355x glm5.1 caps at tp=4 conc=16 in fixed-seq, so cap conservatively + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } + +kimik2.5-fp4-mi355x-vllm-agentic: + image: vllm/vllm-openai-rocm:v0.22.0 + model: amd/Kimi-K2.5-MXFP4 + model-prefix: kimik2.5 + runner: mi355x + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 16, 24, 32, 40, 48] } + # CPU offload only above the KV cliff. Lower concurrencies fit + # entirely on-GPU, so paying the offload-path overhead there would + # just slow them down without measuring anything new. + - { tp: 8, offloading: cpu, conc-list: [32, 40, 48, 56] } + # TP=4 probe: half-node layout doubles per-GPU weight footprint + # (~62 GB on MI355X's 288 GB HBM, plenty of headroom). Restrict to + # cliff-region concurrencies on both offload modes so we can directly + # compare TP=4 vs TP=8 at the same conc points. + - { tp: 4, offloading: none, conc-list: [16, 24, 32, 40] } + - { tp: 4, offloading: cpu, conc-list: [16, 24, 32, 40] } + +minimaxm2.5-fp8-mi355x-vllm-agentic: + image: vllm/vllm-openai-rocm:v0.22.0 + model: MiniMaxAI/MiniMax-M2.5 + model-prefix: minimaxm2.5 + runner: mi355x + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + # MI355X tp=4 ep=4: compute ceiling ~60 (empirical), KV cliff ~91 (analytical). + # Compute saturates first; cpu offload likely won't help, but worth confirming. + # AMD uses native OffloadingConnector (NOT SimpleCPUOffloadConnector). + - duration: 1800 + search-space: + - { tp: 4, ep: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 48, 56, 64, 72, 96] } + - { tp: 4, ep: 4, offloading: cpu, conc-list: [48, 56, 64, 72, 96] } + +minimaxm2.5-fp8-mi300x-vllm-agentic: + image: vllm/vllm-openai-rocm:v0.22.0 + model: MiniMaxAI/MiniMax-M2.5 + model-prefix: minimaxm2.5 + runner: mi300x + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + # MI300X tp=4: compute ceiling ~25 (estimated, between H100 and H200); + # KV cliff ~52. Compute saturates first. + # AMD uses native OffloadingConnector (NOT SimpleCPUOffloadConnector). + - duration: 1800 + search-space: + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 20, 24, 28, 32, 40, 48] } + - { tp: 4, offloading: cpu, conc-list: [16, 20, 24, 28, 32] } + +minimaxm2.5-fp8-mi325x-vllm-agentic: + image: vllm/vllm-openai-rocm:v0.22.0 + model: MiniMaxAI/MiniMax-M2.5 + model-prefix: minimaxm2.5 + runner: mi325x + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + # MI325X tp=4: cloned from MI300X recipe (slightly faster compute, + # similar HBM profile). Compute saturates first; cpu-offload window + # exercises the SimpleCPUOffloadConnector path enabled by the rocm + # nightly. Mirror MI300X conc grid for cross-vendor comparability. + - duration: 1800 + search-space: + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 20, 24, 28, 32, 40, 48] } + - { tp: 4, offloading: cpu, conc-list: [16, 20, 24, 28, 32] } + +qwen3.5-fp8-mi355x-sglang-agentic-hicache: + image: lmsysorg/sglang-rocm:v0.5.12-rocm720-mi35x-20260521 + model: Qwen/Qwen3.5-397B-A17B-FP8 + model-prefix: qwen3.5 + runner: mi355x + precision: fp8 + framework: sglang + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } + - { tp: 8, ep: 1, offloading: hicache, conc-list: [16, 32, 48, 64] } + +dsv4-fp4-mi355x-vllm-agentic: + image: vllm/vllm-openai-rocm:v0.22.0 + model: deepseek-ai/DeepSeek-V4-Pro + model-prefix: dsv4 + runner: mi355x + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, offloading: none, conc-list: [1, 2, 4] } + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 10, 12, 16] } + - { tp: 4, ep: 4, dp-attn: true, offloading: none, conc-list: [16, 24, 32, 40, 48] } -# DSv4-Pro FP4 on MI355X via SGLang. Uses a rocm720 mi35x image built off the -# amd/deepseek_v4 branch in sgl-project/sglang; the SHA is encoded in the -# image tag, so bumping sglang is just an image tag bump here. Sweeps -# DP-attention on/off and EP=8. - -# Diverged from dsv4-fp4-mi355x-sglang (agentic-coding sibling). Reasons below; -# the original dsv4-fp4-mi355x-sglang entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - scenarios: replaced fixed-seq-len with agentic-coding. -# Image is identical to the base entry (rocm/sgl-dev DSv4 build). -# CONC ranges mirror dsv4-fp4-b200-vllm-agentic for cross-hardware -# comparability. Offload sweep is none-only (SGLang has no equivalent of -# vLLM's SimpleCPUOffloadConnector path that we exercise on b200). dsv4-fp4-mi355x-sglang-agentic: image: rocm/sgl-dev:rocm720-mi35x-0363e6c-20260509-DSv4 model: deepseek-ai/DeepSeek-V4-Pro @@ -2702,23 +2618,3 @@ dsv4-fp4-mi355x-sglang-agentic: search-space: - { tp: 8, offloading: none, conc-list: [16, 32, 64] } - { tp: 8, dp-attn: true, offloading: none, conc-list: [64, 128, 256] } - -# DSv4 on MI355X via vLLM, using the official vllm/vllm-openai-rocm -# nightly image. DSv4 base ROCm support (vllm-project/vllm#40871) merged -# on 2026-05-05, so any nightly built after that includes the -# DeepseekV4ForCausalLM model class. -# -# IMPORTANT: pin to a digest-suffixed nightly tag rather than the -# floating `:nightly`. launch_mi355x-amds.sh caches enroot squashfs -# files keyed on the image string and short-circuits re-import if the -# file already exists, so the floating tag silently keeps a stale build -# even after Docker Hub updates `:nightly`. -# -# DeepSeek-V4-Pro is FP4+FP8 mixed (FP4 MoE expert weights, FP8 for the -# rest); InferenceX classifies this as fp4 — same as the sister sglang -# and atom DSv4 mi355x entries below. Image and serving flags follow the -# validated recipe from vllm-project/recipes#433: AITER+AITER_LINEAR, mp -# executor, triton_unfused MoE (required for the FP4 expert format), -# async scheduling, max-num-seqs=128, max-num-batched-tokens=8192, -# gpu-mem-util=0.6. TP8 sweeps conc 4-64; DEP8 has a single conc=64 -# probe to validate the ROCm DP+EP path. diff --git a/.github/configs/nvidia-master.yaml b/.github/configs/nvidia-master.yaml index d3b1b6729..652c65afd 100644 --- a/.github/configs/nvidia-master.yaml +++ b/.github/configs/nvidia-master.yaml @@ -384,25 +384,6 @@ dsr1-fp4-b200-dynamo-trt: ep: 8 dp-attn: true - agentic-coding: - - duration: 300 - search-space: - - spec-decoding: "none" - conc-list: [ 1, 2, 4, 8, 16, 32 ] - prefill: - num-worker: 1 - tp: 4 - ep: 4 - dp-attn: true - additional-settings: - # https://github.com/cquil11/srt-slurm-nv/blob/cam/sa-submission-q2-2026/recipes/trtllm/b200-fp4/agentic/ctx1_gen1_tep8_128k_agentic.yaml - - "CONFIG_FILE=recipes/trtllm/b200-fp4/agentic/ctx1_gen1_tep8_128k_agentic.yaml" - decode: - num-worker: 1 - tp: 8 - ep: 8 - dp-attn: false - dsr1-fp8-b200-dynamo-trt: image: nvcr.io/nvidia/ai-dynamo/tensorrtllm-runtime:0.8.1.post2 model: deepseek-ai/DeepSeek-R1-0528 @@ -1778,28 +1759,6 @@ dsv4-fp4-b200-vllm: - { tp: 8, conc-start: 1, conc-end: 32 } - { tp: 8, ep: 8, dp-attn: true, conc-start: 64, conc-end: 1024 } -# Diverged from dsv4-fp4-b200-vllm (agentic-coding sibling). Reasons below; -# the original dsv4-fp4-b200-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - runner: 'b200-dsv4' -> 'b200-dgxc' -dsv4-fp4-b200-vllm-agentic: - image: vllm/vllm-openai:v0.20.0-cu130 - model: deepseek-ai/DeepSeek-V4-Pro - model-prefix: dsv4 - runner: b200-dgxc - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - # cpu offload only this iteration — none entries already validated in - # earlier runs (B200 25332045030: TP=8 1..32 + DEP=8 16..128 all 100%). - # Re-add when investigating regressions in offload=none. - - { tp: 8, offloading: cpu, conc-list: [16, 32, 64] } - - { tp: 8, ep: 8, dp-attn: true, offloading: cpu, conc-list: [64, 128, 256] } - dsv4-fp4-b200-trt: image: ghcr.io#semianalysisai/trtllm-deepseek-v4:feat-deepseek_v4-9aa3715 model: deepseek-ai/DeepSeek-V4-Pro @@ -1845,7 +1804,7 @@ dsv4-fp4-b200-trt-mtp: # MTP variant of dsv4-fp4-b200-vllm. Mirrors the base search space and adds # --speculative-config '{"method":"mtp","num_speculative_tokens":2}'. dsv4-fp4-b200-vllm-mtp: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: b200-dsv4 @@ -2105,23 +2064,6 @@ qwen3.5-bf16-b200-sglang-mtp: search-space: - { tp: 8, ep: 1, conc-start: 4, conc-end: 64, spec-decoding: mtp } -# agentic-coding sibling — temporarily disabled, blocked by e2e-tests.yml -# artifact-name mismatch (downloads `agentic_*` but benchmark-tmpl.yml uploads -# as `bmk_agentic_*`). Re-enable once that workflow is aligned. -# qwen3.5-bf16-b200-sglang-agentic: -# image: lmsysorg/sglang:v0.5.12-cu130 -# model: Qwen/Qwen3.5-397B-A17B -# model-prefix: qwen3.5 -# runner: b200 -# precision: bf16 -# framework: sglang -# multinode: false -# scenarios: -# agentic-coding: -# - duration: 1800 -# search-space: -# - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } - qwen3.5-fp8-b200-sglang: image: lmsysorg/sglang:v0.5.12-cu130 model: Qwen/Qwen3.5-397B-A17B-FP8 @@ -2143,25 +2085,6 @@ qwen3.5-fp8-b200-sglang: - { tp: 8, conc-start: 4, conc-end: 4 } - { tp: 4, ep: 1, conc-start: 4, conc-end: 256 } -# Diverged from qwen3.5-fp8-b200-sglang (agentic-coding sibling). Metadata is -# identical to origin/main's qwen3.5-fp8-b200-sglang; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original qwen3.5-fp8-b200-sglang entry stays byte-identical to origin/main. -qwen3.5-fp8-b200-sglang-agentic: - image: lmsysorg/sglang:nightly-dev-20260422-de962f32 - model: Qwen/Qwen3.5-397B-A17B-FP8 - model-prefix: qwen3.5 - runner: b200 - precision: fp8 - framework: sglang - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } - qwen3.5-fp4-b200-sglang: image: lmsysorg/sglang:v0.5.12-cu130 model: nvidia/Qwen3.5-397B-A17B-NVFP4 @@ -2245,26 +2168,6 @@ glm5-fp8-b200-sglang-mtp: # NOTE: At the time of submission, https://cookbook.sglang.io/autoregressive/GLM/GLM-5.1 # does not have a B300-specific recipe, so this config reuses the existing GLM5 FP8 # B200 SGLang recipe as-is until B300-specific tuning is available. -# Diverged from glm5-fp8-b200-sglang (agentic-coding sibling). Metadata is -# identical to origin/main's glm5-fp8-b200-sglang; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original glm5-fp8-b200-sglang entry stays byte-identical to origin/main. -glm5-fp8-b200-sglang-agentic: - image: lmsysorg/sglang:v0.5.12-cu130 - model: zai-org/GLM-5-FP8 - model-prefix: glm5 - runner: b200 - precision: fp8 - framework: sglang - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - # sglang manages its own KV eviction via radix cache, so just sweep concurrency on offloading=none - - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 64, 128] } - glm5-fp8-b300-sglang: image: lmsysorg/sglang:v0.5.12-cu130 model: zai-org/GLM-5-FP8 @@ -2411,7 +2314,6 @@ qwen3.5-fp8-b200-sglang-mtp: - { tp: 8, ep: 1, conc-start: 4, conc-end: 4, spec-decoding: mtp } - { tp: 4, ep: 1, conc-start: 4, conc-end: 256, spec-decoding: mtp } - qwen3.5-fp8-b300-sglang-mtp: image: lmsysorg/sglang:v0.5.12-cu130 model: Qwen/Qwen3.5-397B-A17B-FP8 @@ -2553,39 +2455,8 @@ kimik2.5-int4-b200-vllm: search-space: - { tp: 8, conc-start: 4, conc-end: 64 } -# NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/moonshotai/Kimi-K2.5.html -# does not have a B300-specific recipe, so this config reuses the existing -# Kimi-K2.5 INT4 B200 vLLM recipe as-is until B300-specific tuning is available. -# Diverged from kimik2.5-int4-b200-vllm (agentic-coding sibling). Reasons below; -# the original kimik2.5-int4-b200-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - runner: 'b200' -> 'b200-dgxc' -kimik2.5-int4-b200-vllm-agentic: - # Bumped from v0.19.1 — that release tripped a bug in - # `flashinfer_trtllm_mxint4_moe` ('list' object has no attribute 'to') - # during warmup `profile_run` on the agentic-coding path - # (max_model_len=131072 + prefix caching enabled). v0.20.x carries the - # flashinfer fix. - image: vllm/vllm-openai:v0.20.2 - model: moonshotai/Kimi-K2.5 - model-prefix: kimik2.5 - runner: b200-dgxc - precision: int4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } - - { tp: 8, offloading: cpu, conc-list: [32, 64, 96, 128] } - -# NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/moonshotai/Kimi-K2.5.html -# does not have a B300-specific recipe, so this config reuses the existing -# Kimi-K2.5 INT4 B200 vLLM recipe as-is until B300-specific tuning is available. - kimik2.5-int4-b300-vllm: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: moonshotai/Kimi-K2.5 model-prefix: kimik2.5 runner: b300 @@ -2624,29 +2495,6 @@ kimik2.5-int4-h200-vllm: search-space: - { tp: 8, conc-start: 4, conc-end: 64 } -# Diverged from kimik2.5-int4-h200-vllm (agentic-coding sibling). Reasons below; -# the original kimik2.5-int4-h200-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - runner: 'h200' -> 'h200-dgxc' -kimik2.5-int4-h200-vllm-agentic: - image: vllm/vllm-openai:v0.20.2 - model: moonshotai/Kimi-K2.5 - model-prefix: kimik2.5 - # Pinned to h200-dgxc (NVIDIA DGX Cloud Slurm pool) so we hit a host with - # the /home/sa-shared/gharunners/ai-perf-cache mount where aiperf's - # content-addressed dataset mmap cache lives. Other h200 pools (cw, nb) - # don't have that mount and would re-materialize 65 GB to /tmp every job. - runner: h200-dgxc - precision: int4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, offloading: none, conc-list: [1, 2, 3, 4, 5, 6, 7] } - - { tp: 8, offloading: cpu, conc-list: [6, 7, 8, 9, 10, 11, 12, 13, 14] } - kimik2.5-fp4-b200-vllm: image: vllm/vllm-openai:v0.22.0 model: nvidia/Kimi-K2.5-NVFP4 @@ -2668,40 +2516,8 @@ kimik2.5-fp4-b200-vllm: - { tp: 8, ep: 1, conc-start: 4, conc-end: 4 } - { tp: 4, ep: 1, conc-start: 4, conc-end: 64 } -# NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/moonshotai/Kimi-K2.5.html -# does not have a B300-specific recipe, so this config reuses the existing -# Kimi-K2.5 FP4 B200 vLLM recipe as-is until B300-specific tuning is available. -# Diverged from kimik2.5-fp4-b200-vllm (agentic-coding sibling). Reasons below; -# the original kimik2.5-fp4-b200-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai:v0.17.0' -> 'vllm/vllm-openai:v0.20.2' -# - runner: 'b200' -> 'b200-dgxc' -kimik2.5-fp4-b200-vllm-agentic: - # Same image as the INT4 sibling: v0.20.x carries the flashinfer fix that - # cleared the agentic-coding warmup crash on max_model_len=131072 + - # prefix caching. - image: vllm/vllm-openai:v0.20.2 - model: nvidia/Kimi-K2.5-NVFP4 - model-prefix: kimik2.5 - runner: b200-dgxc - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 24] } - - { tp: 8, ep: 1, offloading: cpu, conc-list: [16, 24, 32, 36] } - - { tp: 4, ep: 1, offloading: none, conc-list: [8, 12, 14, 16, 18, 20] } - - { tp: 4, ep: 1, offloading: cpu, conc-list: [12, 14, 16, 18, 20, 22, 24, 32] } - -# NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/moonshotai/Kimi-K2.5.html -# does not have a B300-specific recipe, so this config reuses the existing -# Kimi-K2.5 FP4 B200 vLLM recipe as-is until B300-specific tuning is available. - kimik2.5-fp4-b300-vllm: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: nvidia/Kimi-K2.5-NVFP4 model-prefix: kimik2.5 runner: b300 @@ -2763,34 +2579,6 @@ dsr1-fp8-b300-sglang-mtp: search-space: - { tp: 8, ep: 1, conc-start: 1, conc-end: 512, spec-decoding: mtp } -# Diverged from kimik2.5-fp4-b300-vllm (agentic-coding sibling). Reasons below; -# the original kimik2.5-fp4-b300-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'lmsysorg/sglang:v0.5.10.post1-cu130' -> 'vllm/vllm-openai:v0.20.0-cu130' -# - model: 'deepseek-ai/DeepSeek-R1-0528' -> 'nvidia/Kimi-K2.5-NVFP4' -# - model-prefix: 'dsr1' -> 'kimik2.5' -# - precision: 'fp8' -> 'fp4' -# - framework: 'sglang' -> 'vllm' -kimik2.5-fp4-b300-vllm-agentic: - # v0.20.2 (cu129) lacks the flashinfer kernels for B300's reported SM - # (sm_12x); workers hit "Only SM 10.x and 11.x are supported" in the - # trtllm_fp4_block_scale_moe path. v0.20.0-cu130 is the Blackwell-targeted - # build that has the full sm_10x/sm_11x/sm_12x kernel set and is what the - # INT4 B300 sister already uses successfully. - image: vllm/vllm-openai:v0.20.0-cu130 - model: nvidia/Kimi-K2.5-NVFP4 - model-prefix: kimik2.5 - runner: b300 - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 40, 48, 56, 64] } - - { tp: 8, ep: 1, offloading: cpu, conc-list: [1, 2, 4, 8, 16, 32, 40, 48, 56, 64] } - dsr1-fp8-b200-trt: image: nvcr.io#nvidia/tensorrt-llm/release:1.3.0rc14 model: deepseek-ai/DeepSeek-R1-0528 @@ -2880,7 +2668,7 @@ dsr1-fp8-h200-sglang-mtp: # Uses the cu129 image. H200 has no FP4 path, so the FP4 indexer cache # flag is omitted. Max-model-len is pinned at 800k per the recipe. dsv4-fp8-h200-vllm: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: h200 @@ -2904,7 +2692,7 @@ dsv4-fp8-h200-vllm: # (the non-MTP entry above is still on the deepseekv4-cu129 tag) and adds # --speculative-config '{"method":"mtp","num_speculative_tokens":2}'. dsv4-fp8-h200-vllm-mtp: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: h200 @@ -2924,31 +2712,6 @@ dsv4-fp8-h200-vllm-mtp: - { tp: 8, ep: 1, dp-attn: false, conc-start: 1, conc-end: 256, spec-decoding: mtp } - { tp: 8, ep: 8, dp-attn: true, conc-start: 1, conc-end: 256, spec-decoding: mtp } -# DeepSeek-V4-Pro H200 single-node with SGLang (Marlin FP8, TP-only). -# Pinned to the h200-dgxc-slurm runner pool because the deepseek-v4-hopper -# image needs the /ix mount layout that only launch_h200-dgxc-slurm.sh sets up. -# Diverged from dsv4-fp8-h200-vllm (agentic-coding sibling). Reasons below; -# the original dsv4-fp8-h200-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai:v0.20.1@sha256:9eff9734a30b6713a8566217d36f8277630fd2d31cec7f0a0292835901a23aa4' -> 'vllm/vllm-openai:deepseekv4-cu129' -dsv4-fp8-h200-vllm-agentic: - image: vllm/vllm-openai:deepseekv4-cu129 - model: deepseek-ai/DeepSeek-V4-Pro - model-prefix: dsv4 - runner: h200 - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, ep: 8, dp-attn: true, offloading: none, conc-list: [1, 2, 4, 8, 16] } - -# MTP variant of dsv4-fp8-h200-vllm. Uses the canonical v0.20.1 image -# (the non-MTP entry above is still on the deepseekv4-cu129 tag) and adds -# --speculative-config '{"method":"mtp","num_speculative_tokens":2}'. - dsv4-fp8-h200-sglang: image: lmsysorg/sglang:deepseek-v4-hopper@sha256:7f19c6dc092e47a10fac2e41f47eab78970280d06648b8e50d312a82f0ae722f model: deepseek-ai/DeepSeek-V4-Pro @@ -3024,30 +2787,6 @@ dsv4-fp4-b300-vllm: - { tp: 4, ep: 4, dp-attn: true, conc-start: 256, conc-end: 512 } - { tp: 8, ep: 8, dp-attn: true, conc-start: 2048, conc-end: 2048 } -# Diverged from dsv4-fp4-b300-vllm (agentic-coding sibling). Metadata is -# identical to origin/main's dsv4-fp4-b300-vllm; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original dsv4-fp4-b300-vllm entry stays byte-identical to origin/main. -dsv4-fp4-b300-vllm-agentic: - image: vllm/vllm-openai:v0.20.0-cu130 - model: deepseek-ai/DeepSeek-V4-Pro - model-prefix: dsv4 - runner: b300 - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - # cpu offload only this iteration — none entries already validated in - # earlier runs. Re-add when investigating regressions in offload=none. - - { tp: 4, offloading: cpu, conc-list: [16, 32, 64] } - - { tp: 8, offloading: cpu, conc-list: [16, 32, 64] } - - { tp: 4, ep: 4, dp-attn: true, offloading: cpu, conc-list: [64, 128, 256] } - - { tp: 8, ep: 8, dp-attn: true, offloading: cpu, conc-list: [128, 256, 512] } - dsv4-fp4-b300-trt: image: ghcr.io#semianalysisai/trtllm-deepseek-v4:feat-deepseek_v4-9aa3715 model: deepseek-ai/DeepSeek-V4-Pro @@ -3095,7 +2834,7 @@ dsv4-fp4-b300-trt-mtp: - { tp: 8, ep: 8, dp-attn: true, conc-start: 256, conc-end: 1024, spec-decoding: mtp } dsv4-fp4-b300-vllm-mtp: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: b300 @@ -4284,27 +4023,6 @@ gptoss-fp4-b200-vllm: - { tp: 4, conc-start: 4, conc-end: 64 } - { tp: 8, conc-start: 4, conc-end: 4 } -# Diverged from gptoss-fp4-b200-vllm (agentic-coding sibling). Reasons below; -# the original gptoss-fp4-b200-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai:v0.15.1' -> 'vllm/vllm-openai:v0.19.1' -gptoss-fp4-b200-vllm-agentic: - image: vllm/vllm-openai:v0.19.1 - model: openai/gpt-oss-120b - model-prefix: gptoss - runner: b200 - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 64] } - - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 64] } - - { tp: 4, offloading: cpu, conc-list: [64, 96, 128, 192, 256] } - - { tp: 8, offloading: cpu, conc-list: [64, 96, 128, 192, 256] } - minimaxm2.5-fp8-b200-vllm: image: vllm/vllm-openai:v0.22.0 model: MiniMaxAI/MiniMax-M2.5 @@ -4330,35 +4048,8 @@ minimaxm2.5-fp8-b200-vllm: # NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/MiniMax/MiniMax-M2.html # does not have a B300-specific recipe, so this config reuses the existing # MiniMax-M2.5 FP8 B200 vLLM recipe as-is until B300-specific tuning is available. -# Diverged from minimaxm2.5-fp8-b200-vllm (agentic-coding sibling). Reasons below; -# the original minimaxm2.5-fp8-b200-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai:v0.19.0-cu130' -> 'vllm/vllm-openai:v0.19.1' -# - runner: 'b200' -> 'b200-dgxc' -minimaxm2.5-fp8-b200-vllm-agentic: - image: vllm/vllm-openai:v0.19.1 - model: MiniMaxAI/MiniMax-M2.5 - model-prefix: minimaxm2.5 - runner: b200-dgxc - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - # B200 tp=4: compute ceiling ~50 (empirical), KV cliff ~48 (analytical). - # Push none past the KV cliff (96, 128) to make the no-offload throughput - # collapse visible; cpu range overlaps fully for same-conc comparison. - - duration: 1800 - search-space: - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 48, 56, 64, 96, 128] } - - { tp: 4, offloading: cpu, conc-list: [48, 56, 64, 96, 128] } - - # NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/MiniMax/MiniMax-M2.html - # does not have a B300-specific recipe, so this config reuses the existing - # MiniMax-M2.5 FP8 B200 vLLM recipe as-is until B300-specific tuning is available. - minimaxm2.5-fp8-b300-vllm: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: MiniMaxAI/MiniMax-M2.5 model-prefix: minimaxm2.5 runner: b300 @@ -4381,31 +4072,6 @@ minimaxm2.5-fp8-b300-vllm: - { tp: 2, conc-start: 64, conc-end: 256 } - { tp: 4, conc-start: 4, conc-end: 8 } -# Diverged from minimaxm2.5-fp8-b300-vllm (agentic-coding sibling). Reasons below; -# the original minimaxm2.5-fp8-b300-vllm entry is left identical to origin/main so -# its fixed-seq-len sweep is unaffected. -# - image: 'vllm/vllm-openai:v0.19.0-cu130' -> 'vllm/vllm-openai:v0.19.1' -minimaxm2.5-fp8-b300-vllm-agentic: - image: vllm/vllm-openai:v0.19.1 - model: MiniMaxAI/MiniMax-M2.5 - model-prefix: minimaxm2.5 - runner: b300 - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - # B300 tp=4: compute ceiling ~60 (empirical), KV cliff ~85 (analytical). - # Push none past the KV cliff (96, 128, 192) so the no-offload throughput - # collapse is visible; cpu range overlaps fully so each high-conc point - # has a same-conc no-offload counterpart for direct comparison. - # Dense sampling between 96 and 128 (step=4) to resolve the sharp dropoff - # observed in v6 cpu data right past conc=96. - - duration: 1800 - search-space: - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 48, 64, 96, 100, 104, 108, 112, 116, 120, 124, 128, 192] } - - { tp: 4, offloading: cpu, conc-list: [48, 64, 96, 100, 104, 108, 112, 116, 120, 124, 128, 192] } - minimaxm2.5-fp4-b200-vllm: image: vllm/vllm-openai:v0.22.0 model: nvidia/MiniMax-M2.5-NVFP4 @@ -4438,31 +4104,8 @@ minimaxm2.5-fp4-b200-vllm: # NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/MiniMax/MiniMax-M2.html # does not have a B300-specific recipe, so this config reuses the existing # MiniMax-M2.5 FP4 B200 vLLM recipe as-is until B300-specific tuning is available. -# Diverged from minimaxm2.5-fp4-b200-vllm (agentic-coding sibling). Metadata is -# identical to origin/main's minimaxm2.5-fp4-b200-vllm; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original minimaxm2.5-fp4-b200-vllm entry stays byte-identical to origin/main. -minimaxm2.5-fp4-b200-vllm-agentic: - image: vllm/vllm-openai:v0.19.0-cu130 - model: nvidia/MiniMax-M2.5-NVFP4 - model-prefix: minimaxm2.5 - runner: b200 - precision: fp4 - framework: vllm - multinode: false - scenarios: - agentic-coding: - - duration: 1800 - search-space: - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } - - # NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/MiniMax/MiniMax-M2.html - # does not have a B300-specific recipe, so this config reuses the existing - # MiniMax-M2.5 FP4 B200 vLLM recipe as-is until B300-specific tuning is available. - minimaxm2.5-fp4-b300-vllm: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: nvidia/MiniMax-M2.5-NVFP4 model-prefix: minimaxm2.5 runner: b300 @@ -4489,7 +4132,7 @@ minimaxm2.5-fp4-b300-vllm: - { tp: 8, conc-start: 4, conc-end: 4 } gptoss-fp4-h100-vllm: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: openai/gpt-oss-120b model-prefix: gptoss runner: h100 @@ -4530,29 +4173,6 @@ minimaxm2.5-fp8-h100-vllm: search-space: - { tp: 8, ep: 8, conc-start: 4, conc-end: 128 } -# Diverged from minimaxm2.5-fp8-h100-vllm (agentic-coding sibling). Metadata is -# identical to origin/main's minimaxm2.5-fp8-h100-vllm; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original minimaxm2.5-fp8-h100-vllm entry stays byte-identical to origin/main. -minimaxm2.5-fp8-h100-vllm-agentic: - image: vllm/vllm-openai:v0.20.2 - model: MiniMaxAI/MiniMax-M2.5 - model-prefix: minimaxm2.5 - runner: h100 - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - # H100 tp=4 ep=4: compute ceiling ~10 (empirical), KV cliff ~6 (analytical). - # Best cpu-offload demo SKU — 4-conc-point window between cliffs. - # Dense sampling 4-12 covers both cliffs; conc 16 confirms compute plateau. - - duration: 1800 - search-space: - - { tp: 4, ep: 4, offloading: none, conc-list: [1, 2, 4, 5, 6, 7, 8, 10, 12, 16] } - - { tp: 4, ep: 4, offloading: cpu, conc-list: [5, 6, 7, 8, 10, 12] } - dsr1-fp8-h100-dynamo-sglang: image: lmsysorg/sglang:v0.5.8-cu130 model: deepseek-ai/DeepSeek-R1-0528 @@ -4757,28 +4377,6 @@ minimaxm2.5-fp8-h200-vllm: search-space: - { tp: 4, conc-start: 1, conc-end: 256 } -# Diverged from minimaxm2.5-fp8-h200-vllm (agentic-coding sibling). Metadata is -# identical to origin/main's minimaxm2.5-fp8-h200-vllm; the split exists because this -# PR adds an agentic-coding scenarios block that differs from main -# (either main had none or had a different conc/offload sweep). -# The original minimaxm2.5-fp8-h200-vllm entry stays byte-identical to origin/main. -minimaxm2.5-fp8-h200-vllm-agentic: - image: vllm/vllm-openai:v0.20.2 - model: MiniMaxAI/MiniMax-M2.5 - model-prefix: minimaxm2.5 - runner: h200 - precision: fp8 - framework: vllm - multinode: false - scenarios: - agentic-coding: - # H200 tp=4: compute ceiling ~35 (empirical), KV cliff ~29 (analytical). - # cpu offload window conc 29-35 — dense sampling 24-40 captures both cliffs. - - duration: 1800 - search-space: - - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 24, 28, 32, 36, 48] } - - { tp: 4, offloading: cpu, conc-list: [24, 28, 32, 36, 40, 48] } - dsr1-fp4-gb200-dynamo-trt: image: nvcr.io/nvidia/ai-dynamo/tensorrtllm-runtime:0.8.1.post2 model: nvidia/DeepSeek-R1-0528-NVFP4-v2 @@ -8267,7 +7865,7 @@ kimik2.5-fp4-gb200-dynamo-trt: dp-attn: true kimik2.5-fp4-gb200-dynamo-vllm: - image: vllm/vllm-openai:v0.18.0-cu130 + image: vllm/vllm-openai:v0.22.0 model: nvidia/Kimi-K2.5-NVFP4 model-prefix: kimik2.5 runner: gb200 @@ -8369,7 +7967,7 @@ kimik2.5-fp4-gb200-dynamo-vllm: dp-attn: true dsv4-fp4-b200-dynamo-vllm: - image: vllm/vllm-openai:v0.20.1 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: b200-multinode @@ -8425,7 +8023,7 @@ dsv4-fp4-b200-dynamo-vllm: dp-attn: true dsv4-fp4-gb200-dynamo-vllm: - image: vllm/vllm-openai:v0.20.0-ubuntu2404 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: gb200 @@ -8525,7 +8123,7 @@ dsv4-fp4-gb200-dynamo-vllm: # MTP2 variant of dsv4-fp4-gb200-dynamo-vllm. Uses the vLLM 0.20.1 image # and hand-picked 8k/1k Pareto points mirrored from NVIDIA/srt-slurm. dsv4-fp4-gb200-dynamo-vllm-mtp2: - image: vllm/vllm-openai:v0.20.1-ubuntu2404 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: gb200 @@ -8605,7 +8203,7 @@ dsv4-fp4-gb200-dynamo-vllm-mtp2: dp-attn: true dsv4-fp4-b300-dynamo-vllm: - image: vllm/vllm-openai:v0.20.1 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: b300 @@ -8661,7 +8259,7 @@ dsv4-fp4-b300-dynamo-vllm: dp-attn: true dsv4-fp4-gb300-dynamo-vllm: - image: vllm/vllm-openai:v0.20.0-ubuntu2404 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: gb300-nv @@ -9202,27 +8800,6 @@ dsv4-fp4-gb300-dynamo-sglang-mtp: ep: 8 dp-attn: true - -kimik2.5-int4-h100-vllm: - image: vllm/vllm-openai:v0.20.2 - model: moonshotai/Kimi-K2.5 - model-prefix: kimik2.5 - runner: h100 - precision: int4 - framework: vllm - multinode: false - scenarios: - # New entry, agentic-coding only: this PR intentionally does NOT add - # fixed-seq-len coverage for kimik2.5-int4 on H100 to keep the - # fixed-seq-len test surface identical to origin/main. - # H100 has 80 GB HBM per GPU (smallest in this set); the KV cliff arrives - # early. Sweep saturates conc=20 to keep total HBM headroom. - agentic-coding: - - duration: 1800 - search-space: - - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 12, 16, 20] } - - { tp: 8, offloading: cpu, conc-list: [1, 2, 4, 8, 12, 16, 20] } - qwen3.5-fp8-h100-sglang: image: lmsysorg/sglang:v0.5.12-cu130 model: Qwen/Qwen3.5-397B-A17B-FP8 @@ -9681,12 +9258,304 @@ glm5-fp8-gb300-dynamo-sglang: ep: 1 dp-attn: false -# ============================================================================ -# Net-new agentic recipes from chore/agentx-v0.3 (no overlap with main entries). -# Recipes that ALREADY existed on main were intentionally left at main's version -# to preserve main behavior; PR-branch modifications to those recipes are NOT -# brought in here. -# ============================================================================ +dsv4-fp4-b200-vllm-agentic: + image: vllm/vllm-openai:nightly-d0975a4b50140a9d953f00955a1cbb2a4945edef + model: deepseek-ai/DeepSeek-V4-Pro + model-prefix: dsv4 + runner: b200-dgxc + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, offloading: none, conc-list: [1, 4, 8, 16, 32, 40] } + - { tp: 8, offloading: cpu, conc-list: [40, 48, 52, 64, 72] } + - { tp: 8, ep: 8, dp-attn: true, offloading: none, conc-list: [52, 64, 72, 84, 100, 128, 196, 256, 512] } + - { tp: 8, ep: 8, dp-attn: true, offloading: cpu, conc-list: [64, 128, 196, 256, 512] } + +qwen3.5-fp8-b200-sglang-agentic: + image: lmsysorg/sglang:nightly-dev-20260422-de962f32 + model: Qwen/Qwen3.5-397B-A17B-FP8 + model-prefix: qwen3.5 + runner: b200 + precision: fp8 + framework: sglang + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } + +glm5-fp8-b200-sglang-agentic: + image: lmsysorg/sglang:v0.5.12-cu130 + model: zai-org/GLM-5-FP8 + model-prefix: glm5 + runner: b200 + precision: fp8 + framework: sglang + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + # sglang manages its own KV eviction via radix cache, so just sweep concurrency on offloading=none + - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 64, 128] } + +kimik2.5-int4-b200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: moonshotai/Kimi-K2.5 + model-prefix: kimik2.5 + runner: b200-dgxc + precision: int4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } + - { tp: 8, offloading: cpu, conc-list: [32, 64, 96, 128] } + +# NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/moonshotai/Kimi-K2.5.html +# does not have a B300-specific recipe, so this config reuses the existing +# Kimi-K2.5 INT4 B200 vLLM recipe as-is until B300-specific tuning is available. + +kimik2.5-int4-h200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: moonshotai/Kimi-K2.5 + model-prefix: kimik2.5 + # Pinned to h200-dgxc (NVIDIA DGX Cloud Slurm pool) so we hit a host with + # the /home/sa-shared/gharunners/ai-perf-cache mount where aiperf's + # content-addressed dataset mmap cache lives. Other h200 pools (cw, nb) + # don't have that mount and would re-materialize 65 GB to /tmp every job. + runner: h200-dgxc + precision: int4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, offloading: none, conc-list: [1, 2, 3, 4, 5, 6, 7] } + - { tp: 8, offloading: cpu, conc-list: [6, 7, 8, 9, 10, 11, 12, 13, 14] } + +kimik2.5-fp4-b200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: nvidia/Kimi-K2.5-NVFP4 + model-prefix: kimik2.5 + runner: b200-dgxc + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 24] } + - { tp: 8, ep: 1, offloading: cpu, conc-list: [16, 24, 32, 36] } + - { tp: 4, ep: 1, offloading: none, conc-list: [8, 12, 14, 16, 18, 20] } + - { tp: 4, ep: 1, offloading: cpu, conc-list: [12, 14, 16, 18, 20, 22, 24, 32] } + +# NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/moonshotai/Kimi-K2.5.html +# does not have a B300-specific recipe, so this config reuses the existing +# Kimi-K2.5 FP4 B200 vLLM recipe as-is until B300-specific tuning is available. + +kimik2.5-fp4-b300-vllm-agentic: + # v0.20.2 (cu129) lacks the flashinfer kernels for B300's reported SM + # (sm_12x); workers hit "Only SM 10.x and 11.x are supported" in the + # trtllm_fp4_block_scale_moe path. v0.20.0-cu130 is the Blackwell-targeted + # build that has the full sm_10x/sm_11x/sm_12x kernel set and is what the + # INT4 B300 sister already uses successfully. + image: vllm/vllm-openai:v0.22.0 + model: nvidia/Kimi-K2.5-NVFP4 + model-prefix: kimik2.5 + runner: b300 + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, ep: 1, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 40, 48, 56, 64] } + - { tp: 8, ep: 1, offloading: cpu, conc-list: [1, 2, 4, 8, 16, 32, 40, 48, 56, 64] } + +dsv4-fp8-h200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: deepseek-ai/DeepSeek-V4-Pro + model-prefix: dsv4 + runner: h200 + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, ep: 8, dp-attn: true, offloading: none, conc-list: [1, 2, 4, 8, 16] } + +# MTP variant of dsv4-fp8-h200-vllm. Uses the canonical v0.20.1 image +# (the non-MTP entry above is still on the deepseekv4-cu129 tag) and adds +# --speculative-config '{"method":"mtp","num_speculative_tokens":2}'. + +dsv4-fp4-b300-vllm-agentic: + # image: vllm/vllm-openai:v0.22.0 + # includes https://github.com/vllm-project/vllm/pull/43447 up to 6c529f3001ab8bf44b1657e779dc54b622397045 + # image: cquil/vllm-openai:v0.22.0-6c529f3001ab8bf44b1657e779dc54b622397045' + image: vllm/vllm-openai:nightly-d0975a4b50140a9d953f00955a1cbb2a4945edef + model: deepseek-ai/DeepSeek-V4-Pro + model-prefix: dsv4 + runner: b300 + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + # TEMPORARY: run only MooncakeStore CPU-offload scenarios while + # diagnosing the native/SimpleCPU offload failures. + - { tp: 4, offloading: none, conc-list: [1, 4, 8, 16, 32] } + - { tp: 8, offloading: none, conc-list: [1, 4, 8, 16, 32, 40, 48, 52, 64, 72] } + - { tp: 4, ep: 4, dp-attn: true, offloading: none, conc-list: [8, 16, 32, 64, 128] } + - { tp: 4, ep: 4, dp-attn: true, offloading: cpu, conc-list: [32, 48, 64, 96, 128, 192, 256] } + - { tp: 8, ep: 8, dp-attn: true, offloading: none, conc-list: [52, 64, 72, 84, 100, 128, 196, 256, 512] } + +gptoss-fp4-b200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: openai/gpt-oss-120b + model-prefix: gptoss + runner: b200 + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 64] } + - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 64] } + - { tp: 4, offloading: cpu, conc-list: [64, 96, 128, 192, 256] } + - { tp: 8, offloading: cpu, conc-list: [64, 96, 128, 192, 256] } + +minimaxm2.5-fp8-b200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: MiniMaxAI/MiniMax-M2.5 + model-prefix: minimaxm2.5 + runner: b200-dgxc + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + # B200 tp=4: compute ceiling ~50 (empirical), KV cliff ~48 (analytical). + # Push none past the KV cliff (96, 128) to make the no-offload throughput + # collapse visible; cpu range overlaps fully for same-conc comparison. + - duration: 1800 + search-space: + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 48, 56, 64, 96, 128] } + - { tp: 4, offloading: cpu, conc-list: [48, 56, 64, 96, 128] } + + # NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/MiniMax/MiniMax-M2.html + # does not have a B300-specific recipe, so this config reuses the existing + # MiniMax-M2.5 FP8 B200 vLLM recipe as-is until B300-specific tuning is available. + +minimaxm2.5-fp8-b300-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: MiniMaxAI/MiniMax-M2.5 + model-prefix: minimaxm2.5 + runner: b300 + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + # B300 tp=4: compute ceiling ~60 (empirical), KV cliff ~85 (analytical). + # Push none past the KV cliff (96, 128, 192) so the no-offload throughput + # collapse is visible; cpu range overlaps fully so each high-conc point + # has a same-conc no-offload counterpart for direct comparison. + # Dense sampling between 96 and 128 (step=4) to resolve the sharp dropoff + # observed in v6 cpu data right past conc=96. + - duration: 1800 + search-space: + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32, 48, 64, 96, 100, 104, 108, 112, 116, 120, 124, 128, 192] } + - { tp: 4, offloading: cpu, conc-list: [48, 64, 96, 100, 104, 108, 112, 116, 120, 124, 128, 192] } + +minimaxm2.5-fp4-b200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: nvidia/MiniMax-M2.5-NVFP4 + model-prefix: minimaxm2.5 + runner: b200 + precision: fp4 + framework: vllm + multinode: false + scenarios: + agentic-coding: + - duration: 1800 + search-space: + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 32] } + + # NOTE: At the time of submission, https://docs.vllm.ai/projects/recipes/en/latest/MiniMax/MiniMax-M2.html + # does not have a B300-specific recipe, so this config reuses the existing + # MiniMax-M2.5 FP4 B200 vLLM recipe as-is until B300-specific tuning is available. + +minimaxm2.5-fp8-h100-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: MiniMaxAI/MiniMax-M2.5 + model-prefix: minimaxm2.5 + runner: h100 + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + # H100 tp=4 ep=4: compute ceiling ~10 (empirical), KV cliff ~6 (analytical). + # Best cpu-offload demo SKU — 4-conc-point window between cliffs. + # Dense sampling 4-12 covers both cliffs; conc 16 confirms compute plateau. + - duration: 1800 + search-space: + - { tp: 4, ep: 4, offloading: none, conc-list: [1, 2, 4, 5, 6, 7, 8, 10, 12, 16] } + - { tp: 4, ep: 4, offloading: cpu, conc-list: [5, 6, 7, 8, 10, 12] } + +minimaxm2.5-fp8-h200-vllm-agentic: + image: vllm/vllm-openai:v0.22.0 + model: MiniMaxAI/MiniMax-M2.5 + model-prefix: minimaxm2.5 + runner: h200 + precision: fp8 + framework: vllm + multinode: false + scenarios: + agentic-coding: + # H200 tp=4: compute ceiling ~35 (empirical), KV cliff ~29 (analytical). + # cpu offload window conc 29-35 — dense sampling 24-40 captures both cliffs. + - duration: 1800 + search-space: + - { tp: 4, offloading: none, conc-list: [1, 2, 4, 8, 16, 24, 28, 32, 36, 48] } + - { tp: 4, offloading: cpu, conc-list: [24, 28, 32, 36, 40, 48] } + +kimik2.5-int4-h100-vllm: + image: vllm/vllm-openai:v0.22.0 + model: moonshotai/Kimi-K2.5 + model-prefix: kimik2.5 + runner: h100 + precision: int4 + framework: vllm + multinode: false + scenarios: + # New entry, agentic-coding only: this PR intentionally does NOT add + # fixed-seq-len coverage for kimik2.5-int4 on H100 to keep the + # fixed-seq-len test surface identical to origin/main. + # H100 has 80 GB HBM per GPU (smallest in this set); the KV cliff arrives + # early. Sweep saturates conc=20 to keep total HBM headroom. + agentic-coding: + - duration: 1800 + search-space: + - { tp: 8, offloading: none, conc-list: [1, 2, 4, 8, 12, 16, 20] } + - { tp: 8, offloading: cpu, conc-list: [1, 2, 4, 8, 12, 16, 20] } qwen3.5-fp8-b300-sglang-agentic-hicache: image: lmsysorg/sglang:nightly-dev-cu13-20260520-425dffbd @@ -9704,7 +9573,7 @@ qwen3.5-fp8-b300-sglang-agentic-hicache: - { tp: 4, ep: 1, offloading: hicache, conc-list: [16, 32, 48, 64] } kimik2.5-fp4-b200-vllm-agentic-lmcache: - image: vllm/vllm-openai:v0.21.0 + image: vllm/vllm-openai:v0.22.0 model: nvidia/Kimi-K2.5-NVFP4 model-prefix: kimik2.5 runner: b200-dgxc @@ -9724,17 +9593,8 @@ kimik2.5-fp4-b200-vllm-agentic-lmcache: # does not have a B300-specific recipe, so this config reuses the existing # Kimi-K2.5 FP4 B200 vLLM recipe as-is until B300-specific tuning is available. -# Diverged from dsv4-fp4-gb300-dynamo-vllm (agentic-coding sibling). Reasons -# below; the original dsv4-fp4-gb300-dynamo-vllm entry is left identical to -# origin/main so its fixed-seq-len sweep is unaffected. -# - scenarios: replaced fixed-seq-len with agentic-coding; single 1p6d shape -# mirroring the conc=192 point in the base entry's fixed-seq-len sweep. -# - additional-settings.CONFIG_FILE: points at the new agentic recipe under -# recipes/vllm/deepseek-v4/agentic/, which runners/launch_gb300-nv.sh -# overlays into the cquil11/srt-slurm-nv fork at run time (the IS_AGENTIC -# branch). Local-overlay pattern mirrors the existing 8k1k overlay. dsv4-fp4-gb300-dynamo-vllm-agentic: - image: vllm/vllm-openai:v0.21.0-ubuntu2404 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 # gb300-nv (not generic gb300) — the generic label is shared by both NV @@ -9823,7 +9683,7 @@ dsv4-fp4-gb300-dynamo-vllm-agentic: # overlay (recipes/vllm/deepseek-v4/agentic/), so a change to the recipe # applies to both clusters with no duplication. dsv4-fp4-gb300-cw-dynamo-vllm-agentic: - image: vllm/vllm-openai:v0.21.0-ubuntu2404 + image: vllm/vllm-openai:v0.22.0 model: deepseek-ai/DeepSeek-V4-Pro model-prefix: dsv4 runner: gb300-cw @@ -9881,16 +9741,6 @@ dsv4-fp4-gb300-cw-dynamo-vllm-agentic: ep: 8 dp-attn: true -# Diverged from qwen3.5-fp8-h100-sglang (agentic-coding sibling). Reasons below; -# the original qwen3.5-fp8-h100-sglang entry stays byte-identical to origin/main -# so its fixed-seq-len sweep is unaffected. -# - scenarios: replaced fixed-seq-len with agentic-coding. -# - runner: 'h100' -> 'h100-dgxc' (agentic runs need the dgxc-slurm cluster). -# Image is identical to the base entry (lmsysorg/sglang:v0.5.12-cu130). -# CONC range conservative for H100's 80 GB HBM3 under the long-ISL with- -# subagents corpus. hicache arm capped at conc 16 since high-conc + hicache -# tends to flake on first runs and conc 16 covers the cliff. The bench script -# sets WEKA_LOADER_OVERRIDE to the 256k-capped corpus variant. qwen3.5-fp8-h100-sglang-agentic: image: lmsysorg/sglang:v0.5.12-cu130 model: Qwen/Qwen3.5-397B-A17B-FP8 @@ -9905,3 +9755,33 @@ qwen3.5-fp8-h100-sglang-agentic: search-space: - { tp: 8, ep: 8, offloading: none, conc-list: [1, 2, 4, 8, 12, 14, 16] } - { tp: 8, ep: 8, offloading: hicache, conc-list: [12, 14, 16, 20, 24, 28, 32, 42] } + +# Split from dsr1-fp4-b200-dynamo-trt: agentic-coding scenario only. +dsr1-fp4-b200-dynamo-trt-agentic: + image: nvcr.io/nvidia/ai-dynamo/tensorrtllm-runtime:0.8.1.post1 + model: deepseek-r1-fp4 + model-prefix: dsr1 + runner: b200-multinode + precision: fp4 + framework: dynamo-trt + multinode: true + disagg: true + scenarios: + agentic-coding: + - duration: 300 + search-space: + - spec-decoding: "none" + conc-list: [ 1, 2, 4, 8, 16, 32 ] + prefill: + num-worker: 1 + tp: 4 + ep: 4 + dp-attn: true + additional-settings: + # https://github.com/cquil11/srt-slurm-nv/blob/cam/sa-submission-q2-2026/recipes/trtllm/b200-fp4/agentic/ctx1_gen1_tep8_128k_agentic.yaml + - "CONFIG_FILE=recipes/trtllm/b200-fp4/agentic/ctx1_gen1_tep8_128k_agentic.yaml" + decode: + num-worker: 1 + tp: 8 + ep: 8 + dp-attn: false diff --git a/.github/workflows/benchmark-tmpl.yml b/.github/workflows/benchmark-tmpl.yml index 2148def36..46f305fe8 100644 --- a/.github/workflows/benchmark-tmpl.yml +++ b/.github/workflows/benchmark-tmpl.yml @@ -239,7 +239,10 @@ jobs: name: agentic_${{ env.RESULT_FILENAME }} path: | results/server.log + results/router.log results/lmcache_server.log + results/mooncake_master.log + results/mooncake_config.json results/benchmark.log results/config.yaml results/lmcache_command.txt @@ -279,7 +282,10 @@ jobs: name: ${{ inputs.eval-only && 'eval_server_logs_' || 'server_logs_' }}${{ env.RESULT_FILENAME }} path: | ${{ inputs.scenario-type == 'agentic-coding' && 'results/server.log' || 'server.log' }} + ${{ inputs.scenario-type == 'agentic-coding' && 'results/router.log' || '' }} ${{ inputs.scenario-type == 'agentic-coding' && 'results/lmcache_server.log' || '' }} + ${{ inputs.scenario-type == 'agentic-coding' && 'results/mooncake_master.log' || '' }} + ${{ inputs.scenario-type == 'agentic-coding' && 'results/mooncake_config.json' || '' }} if-no-files-found: ignore - name: Upload GPU metrics diff --git a/benchmarks/benchmark_lib.sh b/benchmarks/benchmark_lib.sh index e3080b4bf..3fd56e7e4 100644 --- a/benchmarks/benchmark_lib.sh +++ b/benchmarks/benchmark_lib.sh @@ -899,6 +899,7 @@ run_eval() { INFMAX_CONTAINER_WORKSPACE="${INFMAX_CONTAINER_WORKSPACE:-/workspace}" AGENTIC_DIR="${AGENTIC_DIR:-${INFMAX_CONTAINER_WORKSPACE}/utils/agentic-benchmark}" AIPERF_DIR="${AIPERF_DIR:-${INFMAX_CONTAINER_WORKSPACE}/utils/aiperf}" +AIPERF_FAILED_REQUEST_THRESHOLD=0.10 agentic_pip_install() { local pip_install=(python3 -m pip install) @@ -924,8 +925,21 @@ resolve_trace_source() { # public-dataset loader names allowed by the inferencex-agentx-mvp # scenario. Used by recipes whose servers have non-default context # caps (e.g. minimaxm2.5 at max_model_len ~256k can't replay the - # unfiltered 052726 corpus and switches to the 256k-capped variant). - local loader="${WEKA_LOADER_OVERRIDE:-semianalysis_cc_traces_weka_with_subagents}" + # unfiltered corpus and switches to the 256k-capped variant), or + # by recipes that want to pin an older corpus generation. + # + # Default (no override): the 060826 v6 corpus, selected by model family. + # DSv4 (full context) rides the unfiltered base corpus; every non-DSv4 + # recipe defaults to the 256k-capped variant because those servers run at + # max_model_len ~256k and would reject >256k requests. Any recipe can still + # pin a specific corpus via WEKA_LOADER_OVERRIDE. + local default_loader + if [[ "${MODEL_PREFIX:-}" == dsv4* ]]; then + default_loader="semianalysis_cc_traces_weka_with_subagents_060826" + else + default_loader="semianalysis_cc_traces_weka_with_subagents_060826_256k" + fi + local loader="${WEKA_LOADER_OVERRIDE:-$default_loader}" local dataset case "$loader" in semianalysis_cc_traces_weka_with_subagents) @@ -934,13 +948,31 @@ resolve_trace_source() { semianalysis_cc_traces_weka_with_subagents_256k) dataset="semianalysisai/cc-traces-weka-with-subagents-052726-256k" ;; + semianalysis_cc_traces_weka_with_subagents_060226) + dataset="semianalysisai/cc-traces-weka-with-subagents-060226" + ;; + semianalysis_cc_traces_weka_with_subagents_060226_256k) + dataset="semianalysisai/cc-traces-weka-with-subagents-060226-256k" + ;; + semianalysis_cc_traces_weka_with_subagents_060526) + dataset="semianalysisai/cc-traces-weka-with-subagents-060526" + ;; + semianalysis_cc_traces_weka_with_subagents_060526_256k) + dataset="semianalysisai/cc-traces-weka-with-subagents-060526-256k" + ;; + semianalysis_cc_traces_weka_with_subagents_060826) + dataset="semianalysisai/cc-traces-weka-with-subagents-060826" + ;; + semianalysis_cc_traces_weka_with_subagents_060826_256k) + dataset="semianalysisai/cc-traces-weka-with-subagents-060826-256k" + ;; *) - echo "Error: unknown WEKA_LOADER_OVERRIDE='$loader'. Allowed: semianalysis_cc_traces_weka_with_subagents, semianalysis_cc_traces_weka_with_subagents_256k" >&2 + echo "Error: unknown WEKA_LOADER_OVERRIDE='$loader'. Allowed: semianalysis_cc_traces_weka_with_subagents, semianalysis_cc_traces_weka_with_subagents_256k, semianalysis_cc_traces_weka_with_subagents_060226, semianalysis_cc_traces_weka_with_subagents_060226_256k, semianalysis_cc_traces_weka_with_subagents_060526, semianalysis_cc_traces_weka_with_subagents_060526_256k, semianalysis_cc_traces_weka_with_subagents_060826, semianalysis_cc_traces_weka_with_subagents_060826_256k" >&2 exit 1 ;; esac TRACE_SOURCE_FLAG="--public-dataset $loader" - echo "Loading traces via aiperf public-dataset: $loader ($dataset)" + echo "Loading traces via aiperf public-dataset: $loader ($dataset) [MODEL_PREFIX=${MODEL_PREFIX:-unset}]" # Pre-download the dataset into the shared HF_HUB_CACHE (same mount used # for model weights) so subsequent runs read from cache instead of # re-downloading every job. @@ -1017,7 +1049,7 @@ build_replay_cmd() { # transient low-rate failures from killing long sweeps while still # catching malformed payloads or server crashes before they get aggregated # as benchmarkable data. - REPLAY_CMD+=" --failed-request-threshold 0.10" + REPLAY_CMD+=" --failed-request-threshold $AIPERF_FAILED_REQUEST_THRESHOLD" # Sample each trajectory's warmup start position uniformly from # [25%, 75%] of the trace's turn count (was hardcoded 0%-70% upstream). # Avoids starting trajectories right at turn 0 where the KV cache is @@ -1031,6 +1063,14 @@ build_replay_cmd() { # CPU on minimax-m2.5 at high concurrency. Lossless for vLLM (server # usage is authoritative). REPLAY_CMD+=" --use-server-token-count" + # Disable DCGM GPU telemetry collection. aiperf's GpuMetricTimeSeries + # freezes its metric schema on the first DCGM scrape, then KeyErrors when + # an optional field (xid_errors, power_violation, encoder_utilization) + # first appears mid-run. We don't consume the gpu_telemetry artifact in + # downstream processing, and the server-metrics path (Prometheus /metrics + # from vLLM) is unaffected by this flag and still gives us KV usage, + # prefix cache hit rate, etc. + REPLAY_CMD+=" --no-gpu-telemetry" # aiperf's dataset manager (separate from the inference parser) loads # the model's tokenizer for trace-prompt tokenization regardless of # --use-server-token-count. Models like kimi (amd/Kimi-K2.5-MXFP4, @@ -1070,8 +1110,9 @@ build_replay_cmd() { write_agentic_result_json() { # Aggregate aiperf's profile_export.{json,jsonl} + server_metrics_export.json - # into $AGENTIC_OUTPUT_DIR/$RESULT_FILENAME.json. The workflow's existing - # retry-based existence check is the single success gate. + # into $AGENTIC_OUTPUT_DIR/$RESULT_FILENAME.json. The workflow checks that + # this file exists; run_agentic_replay_and_write_outputs separately rejects + # aggregates whose request error rate exceeds the configured limit. local result_dir="$1" RESULT_DIR="$result_dir" AGENTIC_OUTPUT_DIR="${AGENTIC_OUTPUT_DIR:-$INFMAX_CONTAINER_WORKSPACE}" \ python3 "$INFMAX_CONTAINER_WORKSPACE/utils/process_agentic_result.py" @@ -1085,6 +1126,7 @@ write_agentic_result_json() { run_agentic_replay_and_write_outputs() { local result_dir="$1" local replay_rc + local validation_rc echo "$REPLAY_CMD" > "$result_dir/benchmark_command.txt" @@ -1100,8 +1142,20 @@ run_agentic_replay_and_write_outputs() { python3 "$AGENTIC_DIR/scripts/analyze_benchmark_distributions.py" \ "$result_dir/aiperf_artifacts" -o "$result_dir" 2>&1 || true + set +e + python3 "$INFMAX_CONTAINER_WORKSPACE/utils/validate_agentic_result.py" \ + "$result_dir/aiperf_artifacts" \ + --failed-request-threshold "$AIPERF_FAILED_REQUEST_THRESHOLD" + validation_rc=$? + set -e + if [ "$replay_rc" -ne 0 ]; then echo "ERROR: agentic trace replay exited with code $replay_rc after writing available results" >&2 return "$replay_rc" fi + + if [ "$validation_rc" -ne 0 ]; then + echo "ERROR: agentic trace replay produced invalid results after writing available artifacts" >&2 + return "$validation_rc" + fi } diff --git a/benchmarks/single_node/agentic/dsr1_fp4_b200.sh b/benchmarks/single_node/agentic/dsr1_fp4_b200.sh index f9955adc7..16dc3bfd5 100755 --- a/benchmarks/single_node/agentic/dsr1_fp4_b200.sh +++ b/benchmarks/single_node/agentic/dsr1_fp4_b200.sh @@ -17,7 +17,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -33,7 +43,7 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 python3 -m sglang.launch_server \ ---model-path $MODEL \ +--model-path "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --trust-remote-code \ diff --git a/benchmarks/single_node/agentic/dsr1_fp4_mi355x.sh b/benchmarks/single_node/agentic/dsr1_fp4_mi355x.sh index ff76b768d..3b2561fe2 100755 --- a/benchmarks/single_node/agentic/dsr1_fp4_mi355x.sh +++ b/benchmarks/single_node/agentic/dsr1_fp4_mi355x.sh @@ -16,7 +16,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi amd-smi || true @@ -34,7 +44,7 @@ export ROCM_QUICK_REDUCE_QUANTIZATION=INT4 export PYTHONNOUSERSITE=1 python3 -m sglang.launch_server \ ---model-path=$MODEL \ +--model-path=$MODEL_PATH --served-model-name=$MODEL \ --host=0.0.0.0 \ --port=$PORT \ --trust-remote-code \ diff --git a/benchmarks/single_node/agentic/dsv4_fp4_b200_vllm.sh b/benchmarks/single_node/agentic/dsv4_fp4_b200_vllm.sh index 108347479..a2b2db625 100755 --- a/benchmarks/single_node/agentic/dsv4_fp4_b200_vllm.sh +++ b/benchmarks/single_node/agentic/dsv4_fp4_b200_vllm.sh @@ -13,18 +13,17 @@ set -x # experts EP-sharded across DP ranks (per the vLLM blog recipe). # Highest aggregate throughput at large CONC. # -# Image is vllm/vllm-openai:v0.20.0-cu130. block_size=256, kv-cache-dtype=fp8, -# FP4 indexer cache enabled, FULL_AND_PIECEWISE cudagraph capture with -# custom_ops=all (per the vLLM blog recipe at https://vllm.ai/blog/deepseek-v4). +# Image is configured in nvidia-master.yaml. block_size=256, +# kv-cache-dtype=fp8, FP4 indexer cache enabled, FULL_AND_PIECEWISE cudagraph +# capture with custom_ops=all (per the vLLM blog recipe at +# https://vllm.ai/blog/deepseek-v4). # # Required env vars: # MODEL, TP, CONC, OFFLOADING, TOTAL_CPU_DRAM_GB, RESULT_DIR # # OFFLOADING values: -# none - vLLM GPU KV only, with DSv4 hybrid KV manager enabled. -# cpu - vLLM native OffloadingConnector, with hybrid KV manager enabled. -# lmcache-mp - Temporarily disabled for DSv4. LMCache PR #3261 must merge -# first so LMCacheMPConnector can support HMA block-id tuples. +# none - vLLM GPU KV only. +# cpu - MooncakeStoreConnector with a shared 2.5 TB host-memory KV tier. source "$(dirname "$0")/../../benchmark_lib.sh" @@ -38,157 +37,125 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- resolve_trace_source install_agentic_deps +# vllm-project/router expands the one HTTP backend into one logical worker per +# DP rank and sends X-data-parallel-rank on forwarded requests. aiperf's +# X-Correlation-ID is stable for every turn of a conversation; alias it to the +# router's preferred X-Session-ID header. +USE_VLLM_ROUTER=false +VLLM_BACKEND_PORT="$PORT" +if [ "$DP_ATTENTION" = "true" ]; then + USE_VLLM_ROUTER=true + VLLM_BACKEND_PORT=$((PORT + 1)) + VLLM_ROUTER_VERSION=0.1.14 + VLLM_ROUTER_POLICY=consistent_hash + VLLM_ROUTER_METRICS_PORT=$((PORT + 10000)) + export AIPERF_HTTP_X_SESSION_ID_FROM_CORRELATION_ID=1 + agentic_pip_install --quiet "vllm-router==$VLLM_ROUTER_VERSION" +fi + # DeepSeek-V4-Pro weights are large; engine startup can exceed default 600s. export VLLM_ENGINE_READY_TIMEOUT_S=3600 +# vllm-project/vllm#43447: keep SWA prefix-cache tails sparsely so transient +# sliding-window allocations don't evict useful prefix entries. 32k matches +# the trace-replay tuning the PR author validated (0% -> 74% hit rate). +# Requires the custom cquil image configured for this recipe. +export VLLM_PREFIX_CACHE_RETENTION_INTERVAL=32768 + # ---- Server config ---------------------------------------------------------- SERVER_LOG="$RESULT_DIR/server.log" -LMCACHE_LOG="$RESULT_DIR/lmcache_server.log" +ROUTER_LOG="$RESULT_DIR/router.log" +MOONCAKE_MASTER_LOG="$RESULT_DIR/mooncake_master.log" mkdir -p "$RESULT_DIR" OFFLOAD_ARGS=() -HYBRID_KV_ARGS=(--no-disable-hybrid-kv-cache-manager) -LMCACHE_PID="" - -cleanup_lmcache_server() { - if [[ -n "$LMCACHE_PID" ]] && kill -0 "$LMCACHE_PID" 2>/dev/null; then - kill "$LMCACHE_PID" 2>/dev/null || true - wait "$LMCACHE_PID" 2>/dev/null || true - fi -} - -trap cleanup_lmcache_server EXIT - -wait_for_lmcache_ready() { - { set +x; } 2>/dev/null - local attempts="${LMCACHE_READY_ATTEMPTS:-120}" - local tail_pid="" - - while [ ! -f "$LMCACHE_LOG" ]; do - if [[ -n "$LMCACHE_PID" ]] && ! kill -0 "$LMCACHE_PID" 2>/dev/null; then - echo "LMCache server died before creating log file. Exiting." >&2 - exit 1 - fi - sleep 1 - done - - tail -f -n +1 "$LMCACHE_LOG" & - tail_pid=$! - - for ((i = 1; i <= attempts; i++)); do - if curl --output /dev/null --silent --fail "http://127.0.0.1:${LMCACHE_HTTP_PORT}/healthcheck"; then - kill "$tail_pid" 2>/dev/null || true - wait "$tail_pid" 2>/dev/null || true - return 0 - fi - if [[ -n "$LMCACHE_PID" ]] && ! kill -0 "$LMCACHE_PID" 2>/dev/null; then - echo "LMCache server died before becoming healthy. Log follows:" >&2 - kill "$tail_pid" 2>/dev/null || true - wait "$tail_pid" 2>/dev/null || true - cat "$LMCACHE_LOG" >&2 || true - exit 1 - fi - sleep 1 - done - - echo "Timed out waiting for LMCache server healthcheck. Log follows:" >&2 - kill "$tail_pid" 2>/dev/null || true - wait "$tail_pid" 2>/dev/null || true - cat "$LMCACHE_LOG" >&2 || true - exit 1 -} case "$OFFLOADING" in none) ;; cpu) - # b200-dgxc compute nodes have ~3.8 TiB host RAM; SLURM cgroup limits - # individual jobs to a fraction of that. Aim for ~1.2 TB total native - # CPU offload pool across the engine(s); previously 2.8 TB but every - # DP-attn worker stalled for 4+ min during pinned-CPU-tensor allocation - # and the shm_broadcast watchdog killed them (run 26246044726). 150 GB - # per worker (1.2 TB / 8) completes the alloc within the 60 s window. + # B200 DGXC compute nodes have about 3.9 TB host RAM. Leave enough + # headroom for model workers and the runtime. # - # Native --kv-offloading-size becomes OffloadingConnector's - # cpu_bytes_to_use. For DP-attn there are $TP independent DP engines, - # so pre-divide to keep aggregate host commit near TOTAL_CPU_DRAM_GB. - # For pure TP, vLLM treats the size as the total across TP ranks. - TOTAL_CPU_DRAM_GB=1200 - if [ "$DP_ATTENTION" = "true" ]; then - PER_ENGINE_GB=$((TOTAL_CPU_DRAM_GB / TP)) - else - PER_ENGINE_GB=$TOTAL_CPU_DRAM_GB + # Embedded mode contributes one segment per GPU rank to a shared + # distributed store, so pre-divide the aggregate host-memory budget. + TOTAL_CPU_DRAM_GB=2500 + PER_RANK_GB=$((TOTAL_CPU_DRAM_GB / TP)) + + MOONCAKE_VERSION=0.3.11.post1 + agentic_pip_install --quiet --no-cache-dir --no-deps \ + --force-reinstall "mooncake-transfer-engine-cuda13==$MOONCAKE_VERSION" + python3 -c "from mooncake.store import MooncakeDistributedStore" >/dev/null + + MOONCAKE_MASTER_PORT=$((PORT + 12000)) + MOONCAKE_CONFIG_PATH="$RESULT_DIR/mooncake_config.json" + cat > "$MOONCAKE_CONFIG_PATH" < "$MOONCAKE_MASTER_LOG" 2>&1 & + MOONCAKE_MASTER_PID=$! + sleep 2 + if ! kill -0 "$MOONCAKE_MASTER_PID" 2>/dev/null; then + echo "Mooncake master died during startup." >&2 + cat "$MOONCAKE_MASTER_LOG" >&2 + exit 1 fi unset VLLM_USE_SIMPLE_KV_OFFLOAD - OFFLOAD_ARGS=( - --kv-offloading-backend native - --kv-offloading-size "$PER_ENGINE_GB" - ) - ;; - lmcache-mp) - { set +x; } 2>/dev/null - # LMCacheMPConnector needs HMA support before it can run DSv4 with the - # hybrid KV manager. Re-enable this path after - # https://github.com/LMCache/LMCache/pull/3261 is merged. - echo "Error: OFFLOADING=lmcache-mp is disabled for DSv4 until LMCache PR #3261 adds HMA support." >&2 - exit 1 - - # LMCache docs recommend MP mode for production: start an external - # `lmcache server`, then point vLLM's LMCacheMPConnector at it. For - # vLLM >= 0.20, prefer the LMCache-shipped connector module because it - # tracks the latest server protocol ahead of vLLM's vendored copy. - # - # Important DSv4 caveat: LMCacheMPConnector currently only accepts the - # non-hybrid KV block layout. The connector raises if vLLM returns the - # hybrid block-id tuple used by the CSA/HCA hybrid KV manager. This - # mode therefore disables the hybrid manager; `none` and `cpu` keep it - # enabled for the normal B200 DSv4 path. - agentic_pip_install --quiet --no-cache-dir lmcache - python3 -c "import lmcache.integration.vllm.lmcache_mp_connector" >/dev/null - - TOTAL_CPU_DRAM_GB=2800 - LMCACHE_HOST="${LMCACHE_HOST:-127.0.0.1}" - LMCACHE_PORT="${LMCACHE_PORT:-5555}" - LMCACHE_HTTP_PORT="${LMCACHE_HTTP_PORT:-8080}" - LMCACHE_L1_SIZE_GB="${LMCACHE_L1_SIZE_GB:-$TOTAL_CPU_DRAM_GB}" - LMCACHE_L1_INIT_SIZE_GB="${LMCACHE_L1_INIT_SIZE_GB:-200}" - LMCACHE_CHUNK_SIZE="${LMCACHE_CHUNK_SIZE:-256}" - LMCACHE_MAX_WORKERS="${LMCACHE_MAX_WORKERS:-$TP}" - - echo "Starting LMCache MP server..." - LMCACHE_CMD=( - lmcache server - --host "$LMCACHE_HOST" - --port "$LMCACHE_PORT" - --http-host "$LMCACHE_HOST" - --http-port "$LMCACHE_HTTP_PORT" - --l1-size-gb "$LMCACHE_L1_SIZE_GB" - --l1-init-size-gb "$LMCACHE_L1_INIT_SIZE_GB" - --chunk-size "$LMCACHE_CHUNK_SIZE" - --max-workers "$LMCACHE_MAX_WORKERS" - --eviction-policy LRU - ) - printf '%q ' "${LMCACHE_CMD[@]}" > "$RESULT_DIR/lmcache_command.txt" - printf '\n' >> "$RESULT_DIR/lmcache_command.txt" - "${LMCACHE_CMD[@]}" > "$LMCACHE_LOG" 2>&1 & - LMCACHE_PID=$! - echo "LMCache server PID: $LMCACHE_PID" - wait_for_lmcache_ready - - HYBRID_KV_ARGS=(--disable-hybrid-kv-cache-manager) OFFLOAD_ARGS=( --kv-transfer-config - "{\"kv_connector\":\"LMCacheMPConnector\",\"kv_connector_module_path\":\"lmcache.integration.vllm.lmcache_mp_connector\",\"kv_role\":\"kv_both\",\"kv_connector_extra_config\":{\"lmcache.mp.host\":\"$LMCACHE_HOST\",\"lmcache.mp.port\":$LMCACHE_PORT}}" + '{"kv_connector":"MooncakeStoreConnector","kv_role":"kv_both","kv_connector_extra_config":{"load_async":true}}' ) ;; *) - echo "Error: unsupported OFFLOADING value '$OFFLOADING' (expected one of: none, cpu, lmcache-mp)" >&2 + echo "Error: unsupported OFFLOADING value '$OFFLOADING' (expected one of: none, cpu)" >&2 exit 1 ;; esac @@ -221,9 +188,9 @@ export VLLM_FLOAT32_MATMUL_PRECISION=high { set +x; } 2>/dev/null VLLM_CMD=( - vllm serve "$MODEL" + vllm serve "$MODEL_PATH" --served-model-name "$MODEL" --host 0.0.0.0 - --port "$PORT" + --port "$VLLM_BACKEND_PORT" --trust-remote-code --kv-cache-dtype fp8 --block-size 256 @@ -236,7 +203,7 @@ VLLM_CMD=( --enable-auto-tool-choice --reasoning-parser deepseek_v4 --enable-prefix-caching - "${HYBRID_KV_ARGS[@]}" + --no-disable-hybrid-kv-cache-manager --max-model-len "$MAX_MODEL_LEN" --max-num-seqs "$PER_ENGINE_MAX_NUM_SEQS" "${OFFLOAD_ARGS[@]}" @@ -247,7 +214,24 @@ printf '\n' | tee -a "$RESULT_DIR/vllm_command.txt" SERVER_PID=$! echo "Server PID: $SERVER_PID" -wait_for_server_ready --port "$PORT" --server-log "$SERVER_LOG" --server-pid "$SERVER_PID" +wait_for_server_ready --port "$VLLM_BACKEND_PORT" --server-log "$SERVER_LOG" --server-pid "$SERVER_PID" + +if [ "$USE_VLLM_ROUTER" = "true" ]; then + echo "Starting native vLLM router on port $PORT for $TP DP ranks..." + vllm-router \ + --worker-urls "http://localhost:$VLLM_BACKEND_PORT" \ + --policy "$VLLM_ROUTER_POLICY" \ + --intra-node-data-parallel-size "$TP" \ + --host 0.0.0.0 \ + --port "$PORT" \ + --prometheus-host 127.0.0.1 \ + --prometheus-port "$VLLM_ROUTER_METRICS_PORT" \ + --request-timeout-secs 3600 \ + --disable-retries > "$ROUTER_LOG" 2>&1 & + ROUTER_PID=$! + echo "Router PID: $ROUTER_PID" + wait_for_server_ready --port "$PORT" --server-log "$ROUTER_LOG" --server-pid "$ROUTER_PID" +fi # ---- Run benchmark ---------------------------------------------------------- build_replay_cmd "$RESULT_DIR" diff --git a/benchmarks/single_node/agentic/dsv4_fp4_b300_vllm.sh b/benchmarks/single_node/agentic/dsv4_fp4_b300_vllm.sh index f6748a5f8..c73aa5c6a 100755 --- a/benchmarks/single_node/agentic/dsv4_fp4_b300_vllm.sh +++ b/benchmarks/single_node/agentic/dsv4_fp4_b300_vllm.sh @@ -24,62 +24,135 @@ source "$(dirname "$0")/../../benchmark_lib.sh" check_env_vars MODEL TP CONC OFFLOADING TOTAL_CPU_DRAM_GB RESULT_DIR DURATION EP_SIZE DP_ATTENTION -if [ -z "${MAX_MODEL_LEN:-}" ] || [ "$MAX_MODEL_LEN" = "0" ]; then +if ! declare -p MAX_MODEL_LEN >/dev/null 2>&1; then + MAX_MODEL_LEN=1000000 +elif [[ -z "$MAX_MODEL_LEN" || "$MAX_MODEL_LEN" = "0" ]]; then MAX_MODEL_LEN=1000000 fi -if [[ -n "${SLURM_JOB_ID:-}" ]]; then - echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" +if declare -p SLURM_JOB_ID >/dev/null 2>&1 && [ -n "$SLURM_JOB_ID" ]; then + SLURM_NODE=unknown + if declare -p SLURMD_NODENAME >/dev/null 2>&1 && [ -n "$SLURMD_NODENAME" ]; then + SLURM_NODE="$SLURMD_NODENAME" + fi + echo "JOB $SLURM_JOB_ID running on $SLURM_NODE" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if declare -p MODEL_PATH >/dev/null 2>&1 && [ -n "$MODEL_PATH" ]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- resolve_trace_source install_agentic_deps +# vllm-project/router expands the one HTTP backend into one logical worker per +# DP rank and sends X-data-parallel-rank on forwarded requests. aiperf's +# X-Correlation-ID is stable for every turn of a conversation; alias it to the +# router's preferred X-Session-ID header. This also keeps affinity correct when +# testing older wheels that prioritize per-request X-Request-ID. +USE_VLLM_ROUTER=false +VLLM_BACKEND_PORT="$PORT" +if [ "$DP_ATTENTION" = "true" ]; then + USE_VLLM_ROUTER=true + VLLM_BACKEND_PORT=$((PORT + 1)) + VLLM_ROUTER_VERSION=0.1.14 + VLLM_ROUTER_POLICY=consistent_hash + VLLM_ROUTER_METRICS_PORT=$((PORT + 10000)) + export AIPERF_HTTP_X_SESSION_ID_FROM_CORRELATION_ID=1 + agentic_pip_install --quiet "vllm-router==$VLLM_ROUTER_VERSION" +fi + # DeepSeek-V4-Pro weights are large; engine startup can exceed default 600s. export VLLM_ENGINE_READY_TIMEOUT_S=3600 +# vllm-project/vllm#43447: keep SWA prefix-cache tails sparsely so transient +# sliding-window allocations don't evict useful prefix entries. 32k matches +# the trace-replay tuning the PR author validated (0% -> 74% hit rate). +# Requires the custom image (cquil/vllm-openai:*-7ead0a0f...) that carries +# the patch; on stock images the env var is ignored. +export VLLM_PREFIX_CACHE_RETENTION_INTERVAL=32768 + # ---- Server config ---------------------------------------------------------- SERVER_LOG="$RESULT_DIR/server.log" +ROUTER_LOG="$RESULT_DIR/router.log" +MOONCAKE_MASTER_LOG="$RESULT_DIR/mooncake_master.log" mkdir -p "$RESULT_DIR" -OFFLOAD_ARGS="" +OFFLOAD_ARGS=() case "$OFFLOADING" in none) ;; cpu) - # B300 compute nodes have ~3.8 TiB host RAM; SLURM cgroup limits - # individual jobs to a fraction of that. Aim for ~2.2 TB total host - # CPU pool across the engine(s). + # Leave enough host-memory headroom for model workers and the runtime. + # Use the 2.5 TB host-memory budget across all GPU ranks. # - # SimpleCPUOffloadConnector divides cpu_bytes_to_use by - # parallel_config.world_size (= TP*PP, NOT including DP — see - # vllm/config/parallel.py docstring). So: - # - DP-attn=true → each of $TP DP engines has world_size=1 in - # its parallel_config; the connector does no internal divide, - # and each engine torch.zeros + pin_tensor allocates the full - # --kv_offloading_size value. Pre-divide by $TP here so the - # aggregate host commit ≈ TOTAL_CPU_DRAM_GB. - # - DP-attn=false → single engine with world_size=TP. Pass the - # full TOTAL_CPU_DRAM_GB; the connector's internal divide - # yields TOTAL/TP per rank, and TP-shared mmap (PR #37206) - # keeps the aggregate at TOTAL. - TOTAL_CPU_DRAM_GB=2200 - if [ "$DP_ATTENTION" = "true" ]; then - PER_ENGINE_GB=$((TOTAL_CPU_DRAM_GB / TP)) - else - PER_ENGINE_GB=$TOTAL_CPU_DRAM_GB + # Mooncake embedded mode contributes one global segment per GPU rank to + # a shared distributed store. Pre-divide the aggregate host budget + # across those rank-contributed segments. + TOTAL_CPU_DRAM_GB=2500 + PER_RANK_GB=$((TOTAL_CPU_DRAM_GB / TP)) + + MOONCAKE_VERSION=0.3.11.post1 + agentic_pip_install --quiet --no-cache-dir --no-deps \ + --force-reinstall "mooncake-transfer-engine-cuda13==$MOONCAKE_VERSION" + python3 -c "from mooncake.store import MooncakeDistributedStore" >/dev/null + + MOONCAKE_MASTER_PORT=$((PORT + 12000)) + MOONCAKE_CONFIG_PATH="$RESULT_DIR/mooncake_config.json" + cat > "$MOONCAKE_CONFIG_PATH" < "$MOONCAKE_MASTER_LOG" 2>&1 & + MOONCAKE_MASTER_PID=$! + sleep 2 + if ! kill -0 "$MOONCAKE_MASTER_PID" 2>/dev/null; then + echo "Mooncake master died during startup." >&2 + cat "$MOONCAKE_MASTER_LOG" >&2 + exit 1 fi - PER_ENGINE_BYTES=$((PER_ENGINE_GB * 1024 * 1024 * 1024)) - # Use --kv-transfer-config JSON to also pass lazy_offload=true. Eager - # mode (default) hits an AssertionError in - # vllm/v1/core/kv_cache_utils.py:269 popleft_n at low/mid CONC; lazy - # mode defers the store path and clears low/mid CONC at 80-100%. - # See SimpleCPUOffloadConnector PR #37160 for the lazy_offload knob. - export VLLM_USE_SIMPLE_KV_OFFLOAD=1 - OFFLOAD_ARGS="--kv-transfer-config {\"kv_connector\":\"SimpleCPUOffloadConnector\",\"kv_role\":\"kv_both\",\"kv_connector_extra_config\":{\"cpu_bytes_to_use\":$PER_ENGINE_BYTES,\"lazy_offload\":true}}" + + unset VLLM_USE_SIMPLE_KV_OFFLOAD + OFFLOAD_ARGS=( + --kv-transfer-config + '{"kv_connector":"MooncakeStoreConnector","kv_role":"kv_both","kv_connector_extra_config":{"load_async":true}}' + ) ;; *) echo "Error: unsupported OFFLOADING value '$OFFLOADING' (expected one of: none, cpu)" >&2 @@ -113,9 +186,9 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 export VLLM_FLOAT32_MATMUL_PRECISION=high -vllm serve "$MODEL" \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ ---port "$PORT" \ +--port "$VLLM_BACKEND_PORT" \ --trust-remote-code \ --kv-cache-dtype fp8 \ --block-size 256 \ @@ -131,11 +204,28 @@ vllm serve "$MODEL" \ --no-disable-hybrid-kv-cache-manager \ --max-model-len "$MAX_MODEL_LEN" \ --max-num-seqs "$PER_ENGINE_MAX_NUM_SEQS" \ -$OFFLOAD_ARGS > "$SERVER_LOG" 2>&1 & +"${OFFLOAD_ARGS[@]}" > "$SERVER_LOG" 2>&1 & SERVER_PID=$! echo "Server PID: $SERVER_PID" -wait_for_server_ready --port "$PORT" --server-log "$SERVER_LOG" --server-pid "$SERVER_PID" +wait_for_server_ready --port "$VLLM_BACKEND_PORT" --server-log "$SERVER_LOG" --server-pid "$SERVER_PID" + +if [ "$USE_VLLM_ROUTER" = "true" ]; then + echo "Starting native vLLM router on port $PORT for $TP DP ranks..." + vllm-router \ + --worker-urls "http://localhost:$VLLM_BACKEND_PORT" \ + --policy "$VLLM_ROUTER_POLICY" \ + --intra-node-data-parallel-size "$TP" \ + --host 0.0.0.0 \ + --port "$PORT" \ + --prometheus-host 127.0.0.1 \ + --prometheus-port "$VLLM_ROUTER_METRICS_PORT" \ + --request-timeout-secs 3600 \ + --disable-retries > "$ROUTER_LOG" 2>&1 & + ROUTER_PID=$! + echo "Router PID: $ROUTER_PID" + wait_for_server_ready --port "$PORT" --server-log "$ROUTER_LOG" --server-pid "$ROUTER_PID" +fi # ---- Run benchmark ---------------------------------------------------------- build_replay_cmd "$RESULT_DIR" diff --git a/benchmarks/single_node/agentic/dsv4_fp4_mi355x_sglang.sh b/benchmarks/single_node/agentic/dsv4_fp4_mi355x_sglang.sh index 99aec25fe..029c8ea7f 100755 --- a/benchmarks/single_node/agentic/dsv4_fp4_mi355x_sglang.sh +++ b/benchmarks/single_node/agentic/dsv4_fp4_mi355x_sglang.sh @@ -31,7 +31,17 @@ if [ -n "${ROCR_VISIBLE_DEVICES:-}" ]; then export HIP_VISIBLE_DEVICES="$ROCR_VISIBLE_DEVICES" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -135,7 +145,7 @@ fi echo "Starting sglang server..." python3 -m sglang.launch_server \ - --model-path "$MODEL" \ + --model-path "$MODEL_PATH" --served-model-name "$MODEL" \ --host=0.0.0.0 \ --port "$PORT" \ "${PARALLEL_ARGS[@]}" \ diff --git a/benchmarks/single_node/agentic/dsv4_fp8_h200.sh b/benchmarks/single_node/agentic/dsv4_fp8_h200.sh index 0a0177983..799c2bf26 100755 --- a/benchmarks/single_node/agentic/dsv4_fp8_h200.sh +++ b/benchmarks/single_node/agentic/dsv4_fp8_h200.sh @@ -21,7 +21,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -40,7 +50,7 @@ export PYTHONNOUSERSITE=1 # Per recipe: EP + DP=8 (no --tensor-parallel-size). TP from search space is # used for GPU allocation by the runner and as the DP size. -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --trust-remote-code \ diff --git a/benchmarks/single_node/agentic/glm5.1_fp4_mi355x.sh b/benchmarks/single_node/agentic/glm5.1_fp4_mi355x.sh index 500b456f5..3b85a31cd 100755 --- a/benchmarks/single_node/agentic/glm5.1_fp4_mi355x.sh +++ b/benchmarks/single_node/agentic/glm5.1_fp4_mi355x.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -42,7 +52,7 @@ echo "Starting SGLang server..." export PYTHONNOUSERSITE=1 python3 -m sglang.launch_server \ - --model-path $MODEL \ + --model-path "$MODEL_PATH" --served-model-name "$MODEL" \ --host=0.0.0.0 \ --port $PORT \ --tensor-parallel-size $TP \ diff --git a/benchmarks/single_node/agentic/glm5_fp8_b200.sh b/benchmarks/single_node/agentic/glm5_fp8_b200.sh index 259c19586..b3597cf52 100755 --- a/benchmarks/single_node/agentic/glm5_fp8_b200.sh +++ b/benchmarks/single_node/agentic/glm5_fp8_b200.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -39,7 +49,7 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 python3 -m sglang.launch_server \ ---model-path=$MODEL \ +--model-path=$MODEL_PATH --served-model-name=$MODEL \ --host=0.0.0.0 \ --port=$PORT \ --trust-remote-code \ diff --git a/benchmarks/single_node/agentic/gptoss_fp4_b200.sh b/benchmarks/single_node/agentic/gptoss_fp4_b200.sh index 6e921db58..80d70e724 100755 --- a/benchmarks/single_node/agentic/gptoss_fp4_b200.sh +++ b/benchmarks/single_node/agentic/gptoss_fp4_b200.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -53,7 +63,7 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 export VLLM_USE_FLASHINFER_MOE_MXFP4_MXFP8=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --config "$RESULT_DIR/config.yaml" \ diff --git a/benchmarks/single_node/agentic/gptoss_fp4_h100.sh b/benchmarks/single_node/agentic/gptoss_fp4_h100.sh index 557986b0d..13e32d315 100755 --- a/benchmarks/single_node/agentic/gptoss_fp4_h100.sh +++ b/benchmarks/single_node/agentic/gptoss_fp4_h100.sh @@ -21,7 +21,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -57,7 +67,7 @@ export TORCH_CUDA_ARCH_LIST="9.0" export PYTHONNOUSERSITE=1 export VLLM_MXFP4_USE_MARLIN=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --config "$RESULT_DIR/config.yaml" \ diff --git a/benchmarks/single_node/agentic/gptoss_fp4_h200.sh b/benchmarks/single_node/agentic/gptoss_fp4_h200.sh index 1592a8d5c..e0d967246 100755 --- a/benchmarks/single_node/agentic/gptoss_fp4_h200.sh +++ b/benchmarks/single_node/agentic/gptoss_fp4_h200.sh @@ -21,7 +21,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -57,7 +67,7 @@ export TORCH_CUDA_ARCH_LIST="9.0" export PYTHONNOUSERSITE=1 export VLLM_MXFP4_USE_MARLIN=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --config "$RESULT_DIR/config.yaml" \ diff --git a/benchmarks/single_node/agentic/gptoss_fp4_mi300x.sh b/benchmarks/single_node/agentic/gptoss_fp4_mi300x.sh index eb1883ff1..ff597c9a4 100755 --- a/benchmarks/single_node/agentic/gptoss_fp4_mi300x.sh +++ b/benchmarks/single_node/agentic/gptoss_fp4_mi300x.sh @@ -21,7 +21,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi amd-smi || true @@ -65,7 +75,7 @@ esac echo "Starting vllm server..." -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --attention-backend ROCM_AITER_UNIFIED_ATTN \ diff --git a/benchmarks/single_node/agentic/gptoss_fp4_mi325x.sh b/benchmarks/single_node/agentic/gptoss_fp4_mi325x.sh index 99e29c819..1f8c29351 100755 --- a/benchmarks/single_node/agentic/gptoss_fp4_mi325x.sh +++ b/benchmarks/single_node/agentic/gptoss_fp4_mi325x.sh @@ -21,7 +21,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi # If the machine runs a MEC FW older than 177, RCCL cannot reclaim some memory. @@ -64,7 +74,7 @@ esac echo "Starting vllm server..." -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --attention-backend ROCM_AITER_UNIFIED_ATTN \ diff --git a/benchmarks/single_node/agentic/kimik2.5_fp4_b200.sh b/benchmarks/single_node/agentic/kimik2.5_fp4_b200.sh index ad0b4495a..34b45c9ec 100755 --- a/benchmarks/single_node/agentic/kimik2.5_fp4_b200.sh +++ b/benchmarks/single_node/agentic/kimik2.5_fp4_b200.sh @@ -21,7 +21,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -178,7 +188,7 @@ export VLLM_MEMORY_PROFILER_ESTIMATE_CUDAGRAPHS=0 { set +x; } 2>/dev/null VLLM_CMD=( - vllm serve "$MODEL" + vllm serve "$MODEL_PATH" --served-model-name "$MODEL" --host 0.0.0.0 --port "$PORT" --tensor-parallel-size="$TP" diff --git a/benchmarks/single_node/agentic/kimik2.5_fp4_b300.sh b/benchmarks/single_node/agentic/kimik2.5_fp4_b300.sh index 8cebe4f20..9667003e1 100755 --- a/benchmarks/single_node/agentic/kimik2.5_fp4_b300.sh +++ b/benchmarks/single_node/agentic/kimik2.5_fp4_b300.sh @@ -21,7 +21,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -85,7 +95,7 @@ export PYTHONNOUSERSITE=1 { set +x; } 2>/dev/null VLLM_CMD=( - vllm serve "$MODEL" + vllm serve "$MODEL_PATH" --served-model-name "$MODEL" --host 0.0.0.0 --port "$PORT" --tensor-parallel-size="$TP" diff --git a/benchmarks/single_node/agentic/kimik2.5_fp4_mi355x.sh b/benchmarks/single_node/agentic/kimik2.5_fp4_mi355x.sh index fd0ce3677..139b12256 100755 --- a/benchmarks/single_node/agentic/kimik2.5_fp4_mi355x.sh +++ b/benchmarks/single_node/agentic/kimik2.5_fp4_mi355x.sh @@ -33,7 +33,17 @@ if [ -n "${ROCR_VISIBLE_DEVICES:-}" ]; then export HIP_VISIBLE_DEVICES="$ROCR_VISIBLE_DEVICES" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -786,7 +796,7 @@ export PYTHONNOUSERSITE=1 { set +x; } 2>/dev/null VLLM_CMD=( - vllm serve "$MODEL" + vllm serve "$MODEL_PATH" --served-model-name "$MODEL" --host 0.0.0.0 --port "$PORT" --tensor-parallel-size="$TP" diff --git a/benchmarks/single_node/agentic/kimik2.5_int4_b200.sh b/benchmarks/single_node/agentic/kimik2.5_int4_b200.sh index 697d3fa45..5685f098c 100755 --- a/benchmarks/single_node/agentic/kimik2.5_int4_b200.sh +++ b/benchmarks/single_node/agentic/kimik2.5_int4_b200.sh @@ -16,7 +16,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -45,7 +55,7 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 export VLLM_USE_FLASHINFER_MOE_INT4=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --gpu-memory-utilization 0.95 \ diff --git a/benchmarks/single_node/agentic/kimik2.5_int4_h100.sh b/benchmarks/single_node/agentic/kimik2.5_int4_h100.sh index 2fd3b381c..cb6c67f4b 100755 --- a/benchmarks/single_node/agentic/kimik2.5_int4_h100.sh +++ b/benchmarks/single_node/agentic/kimik2.5_int4_h100.sh @@ -16,7 +16,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -45,7 +55,7 @@ echo "Starting vllm server..." export PYTHONNOUSERSITE=1 export VLLM_USE_FLASHINFER_MOE_INT4=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --gpu-memory-utilization 0.95 \ diff --git a/benchmarks/single_node/agentic/kimik2.5_int4_h200.sh b/benchmarks/single_node/agentic/kimik2.5_int4_h200.sh index 97929e43e..1bfa0c33b 100755 --- a/benchmarks/single_node/agentic/kimik2.5_int4_h200.sh +++ b/benchmarks/single_node/agentic/kimik2.5_int4_h200.sh @@ -16,7 +16,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -56,7 +66,7 @@ echo "Starting vllm server..." export PYTHONNOUSERSITE=1 export VLLM_USE_FLASHINFER_MOE_INT4=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --gpu-memory-utilization 0.95 \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp4_b200.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp4_b200.sh index 38ef72b56..b4a63eff3 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp4_b200.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp4_b200.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -58,7 +68,7 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 export VLLM_FLOAT32_MATMUL_PRECISION=high -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ $PARALLEL_ARGS \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp8_b200.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp8_b200.sh index 4ce131cba..0724aba5b 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp8_b200.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp8_b200.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -62,7 +72,7 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 export VLLM_FLOAT32_MATMUL_PRECISION=high -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --tensor-parallel-size=$TP \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp8_b300.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp8_b300.sh index 9f2d83a0b..c291a2ceb 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp8_b300.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp8_b300.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -62,7 +72,7 @@ export TORCH_CUDA_ARCH_LIST="10.0" export PYTHONNOUSERSITE=1 export VLLM_FLOAT32_MATMUL_PRECISION=high -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --tensor-parallel-size=$TP \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp8_h100.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp8_h100.sh index d21690da6..516bc4696 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp8_h100.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp8_h100.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -58,7 +68,7 @@ echo "Starting vllm server..." export TORCH_CUDA_ARCH_LIST="9.0" export PYTHONNOUSERSITE=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --tensor-parallel-size=$TP \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp8_h200.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp8_h200.sh index ed59991cb..e6343b8ba 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp8_h200.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp8_h200.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -58,7 +68,7 @@ echo "Starting vllm server..." export TORCH_CUDA_ARCH_LIST="9.0" export PYTHONNOUSERSITE=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --tensor-parallel-size=$TP \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi300x.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi300x.sh index 260bbdc68..8988316d3 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi300x.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi300x.sh @@ -24,7 +24,17 @@ if [ -n "${ROCR_VISIBLE_DEVICES:-}" ]; then export HIP_VISIBLE_DEVICES="$ROCR_VISIBLE_DEVICES" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -64,7 +74,7 @@ echo "Starting vllm server..." export VLLM_ROCM_USE_AITER=1 export PYTHONNOUSERSITE=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --tensor-parallel-size=$TP \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi325x.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi325x.sh index edac27a45..caa70de63 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi325x.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi325x.sh @@ -24,7 +24,17 @@ if [ -n "${ROCR_VISIBLE_DEVICES:-}" ]; then export HIP_VISIBLE_DEVICES="$ROCR_VISIBLE_DEVICES" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -61,7 +71,7 @@ echo "Starting vllm server..." export VLLM_ROCM_USE_AITER=1 export PYTHONNOUSERSITE=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --tensor-parallel-size=$TP \ diff --git a/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi355x.sh b/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi355x.sh index 39dd63293..cd114fe96 100755 --- a/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi355x.sh +++ b/benchmarks/single_node/agentic/minimaxm2.5_fp8_mi355x.sh @@ -24,7 +24,17 @@ if [ -n "${ROCR_VISIBLE_DEVICES:-}" ]; then export HIP_VISIBLE_DEVICES="$ROCR_VISIBLE_DEVICES" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -65,7 +75,7 @@ export VLLM_ROCM_USE_AITER=1 export VLLM_ROCM_QUICK_REDUCE_QUANTIZATION=INT4 export PYTHONNOUSERSITE=1 -vllm serve $MODEL \ +vllm serve "$MODEL_PATH" --served-model-name "$MODEL" \ --host 0.0.0.0 \ --port $PORT \ --tensor-parallel-size=$TP \ diff --git a/benchmarks/single_node/agentic/patch_vllm_mooncake_transfer_batches.py b/benchmarks/single_node/agentic/patch_vllm_mooncake_transfer_batches.py new file mode 100755 index 000000000..5c061606f --- /dev/null +++ b/benchmarks/single_node/agentic/patch_vllm_mooncake_transfer_batches.py @@ -0,0 +1,102 @@ +#!/usr/bin/env python3 +"""Temporarily bound MooncakeStoreConnector transfer batches. + +Mooncake's TCP connection pool grows without a concurrency ceiling. Large +DeepSeek-V4 requests therefore create enough simultaneous per-layer transfers +to exhaust the node's TCP ports. This patch preserves the same keys and buffer +lists but submits them in smaller sequential batches. +""" + +import argparse +from pathlib import Path + + +HELPER_ANCHOR = '''def _rotate_list(values: list[_T], offset: int) -> list[_T]: + return values[offset:] + values[:offset] +''' + +HELPER = ''' + +_INFERENCEX_MOONCAKE_BATCH_PATCH = True + + +def _run_mooncake_transfer_batches(fn, keys, addrs, sizes, *args): + max_keys = int(os.getenv("INFERENCEX_MOONCAKE_MAX_TRANSFER_BATCH_KEYS", "0")) + if max_keys <= 0 or len(keys) <= max_keys: + return fn(keys, addrs, sizes, *args) + + results = [] + for start in range(0, len(keys), max_keys): + end = start + max_keys + results.extend(fn(keys[start:end], addrs[start:end], sizes[start:end], *args)) + return results +''' + +PUT_CALL = '''res = self.store.batch_put_from_multi_buffers( + keys, + addrs, + sizes, + self.replicate_config, + )''' + +PATCHED_PUT_CALL = '''res = _run_mooncake_transfer_batches( + self.store.batch_put_from_multi_buffers, + keys, + addrs, + sizes, + self.replicate_config, + )''' + +GET_CALL = '''res = self.store.batch_get_into_multi_buffers( + batch_keys, batch_addrs, batch_sizes + )''' + +PATCHED_GET_CALL = '''res = _run_mooncake_transfer_batches( + self.store.batch_get_into_multi_buffers, + batch_keys, + batch_addrs, + batch_sizes, + )''' + + +def patch_worker(worker_path: Path) -> None: + source = worker_path.read_text() + if "_INFERENCEX_MOONCAKE_BATCH_PATCH = True" in source: + print(f"Mooncake transfer batching already patched: {worker_path}") + return + + replacements = ( + (HELPER_ANCHOR, HELPER_ANCHOR + HELPER), + (PUT_CALL, PATCHED_PUT_CALL), + (GET_CALL, PATCHED_GET_CALL), + ) + for old, new in replacements: + count = source.count(old) + if count != 1: + raise RuntimeError( + f"Expected exactly one patch target in {worker_path}, found {count}: " + f"{old.splitlines()[0]}" + ) + source = source.replace(old, new, 1) + + worker_path.write_text(source) + print(f"Patched Mooncake transfer batching: {worker_path}") + + +def main() -> None: + parser = argparse.ArgumentParser() + parser.add_argument("--worker-path", type=Path) + args = parser.parse_args() + + worker_path = args.worker_path + if worker_path is None: + import vllm + + worker_path = Path(vllm.__file__).parent / ( + "distributed/kv_transfer/kv_connector/v1/mooncake/store/worker.py" + ) + patch_worker(worker_path) + + +if __name__ == "__main__": + main() diff --git a/benchmarks/single_node/agentic/qwen3.5_bf16_b200.sh b/benchmarks/single_node/agentic/qwen3.5_bf16_b200.sh index 4ba87976b..d06d82ec8 100755 --- a/benchmarks/single_node/agentic/qwen3.5_bf16_b200.sh +++ b/benchmarks/single_node/agentic/qwen3.5_bf16_b200.sh @@ -20,7 +20,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -39,7 +49,7 @@ export SGL_ENABLE_JIT_DEEPGEMM=false export SGLANG_ENABLE_FLASHINFER_GEMM=true python3 -m sglang.launch_server \ ---model-path=$MODEL \ +--model-path=$MODEL_PATH --served-model-name=$MODEL \ --host=0.0.0.0 \ --port=$PORT \ --served-model-name "Qwen/Qwen3.5-397B-A17B" \ diff --git a/benchmarks/single_node/agentic/qwen3.5_fp8_b200.sh b/benchmarks/single_node/agentic/qwen3.5_fp8_b200.sh index 3432af5c9..ad49b2b67 100755 --- a/benchmarks/single_node/agentic/qwen3.5_fp8_b200.sh +++ b/benchmarks/single_node/agentic/qwen3.5_fp8_b200.sh @@ -20,7 +20,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -39,7 +49,7 @@ export SGL_ENABLE_JIT_DEEPGEMM=false export SGLANG_ENABLE_FLASHINFER_GEMM=true python3 -m sglang.launch_server \ ---model-path=$MODEL \ +--model-path=$MODEL_PATH --served-model-name=$MODEL \ --host=0.0.0.0 \ --port=$PORT \ --served-model-name "Qwen/Qwen3.5-397B-A17B-FP8" \ diff --git a/benchmarks/single_node/agentic/qwen3.5_fp8_b300_sglang.sh b/benchmarks/single_node/agentic/qwen3.5_fp8_b300_sglang.sh index 9d9c1d7d5..4f9b12659 100755 --- a/benchmarks/single_node/agentic/qwen3.5_fp8_b300_sglang.sh +++ b/benchmarks/single_node/agentic/qwen3.5_fp8_b300_sglang.sh @@ -24,7 +24,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -85,7 +95,7 @@ export SGLANG_ENABLE_FLASHINFER_GEMM=true { set +x; } 2>/dev/null SGLANG_CMD=( python3 -m sglang.launch_server - --model-path="$MODEL" + --model-path="$MODEL_PATH" --served-model-name="$MODEL" --host=0.0.0.0 --port="$PORT" --served-model-name "Qwen/Qwen3.5-397B-A17B-FP8" diff --git a/benchmarks/single_node/agentic/qwen3.5_fp8_h100.sh b/benchmarks/single_node/agentic/qwen3.5_fp8_h100.sh index 95f0397a0..b280fff8b 100755 --- a/benchmarks/single_node/agentic/qwen3.5_fp8_h100.sh +++ b/benchmarks/single_node/agentic/qwen3.5_fp8_h100.sh @@ -27,7 +27,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi nvidia-smi # ---- Resolve traces and install deps ---------------------------------------- @@ -98,7 +108,7 @@ fi { set +x; } 2>/dev/null SGLANG_CMD=( python3 -m sglang.launch_server - --model-path="$MODEL" + --model-path="$MODEL_PATH" --served-model-name="$MODEL" --host=0.0.0.0 --port="$PORT" --served-model-name "Qwen/Qwen3.5-397B-A17B-FP8" diff --git a/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x.sh b/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x.sh index aef9650ca..ff901b674 100755 --- a/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x.sh +++ b/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x.sh @@ -19,7 +19,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -36,7 +46,7 @@ export PYTHONNOUSERSITE=1 python3 -m sglang.launch_server \ --attention-backend triton \ - --model-path $MODEL \ + --model-path "$MODEL_PATH" --served-model-name "$MODEL" \ --host=0.0.0.0 \ --port $PORT \ --tensor-parallel-size $TP \ diff --git a/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x_sglang.sh b/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x_sglang.sh index 5427d0d31..cdded8860 100755 --- a/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x_sglang.sh +++ b/benchmarks/single_node/agentic/qwen3.5_fp8_mi355x_sglang.sh @@ -24,7 +24,17 @@ if [[ -n "${SLURM_JOB_ID:-}" ]]; then echo "JOB $SLURM_JOB_ID running on ${SLURMD_NODENAME:-unknown}" fi -if [[ "$MODEL" != /* ]]; then hf download "$MODEL"; fi +# `hf download` creates the target dir if missing and is itself idempotent. +# When MODEL_PATH is unset (stand-alone runs), fall back to the HF_HUB_CACHE +# Either way, MODEL_PATH is what the server is launched with. +if [[ -n "${MODEL_PATH:-}" ]]; then + if [[ ! -d "$MODEL_PATH" || -z "$(ls -A "$MODEL_PATH" 2>/dev/null)" ]]; then + hf download "$MODEL" --local-dir "$MODEL_PATH" + fi +else + hf download "$MODEL" + export MODEL_PATH="$MODEL" +fi rocm-smi || true amd-smi || true @@ -110,7 +120,7 @@ export PYTHONNOUSERSITE=1 SGLANG_CMD=( python3 -m sglang.launch_server --attention-backend triton - --model-path "$MODEL" + --model-path "$MODEL_PATH" --served-model-name "$MODEL" --host=0.0.0.0 --port "$PORT" --tensor-parallel-size "$TP" diff --git a/runners/launch_b300-nv.sh b/runners/launch_b300-nv.sh index 67e8b48cc..cb4a634c3 100644 --- a/runners/launch_b300-nv.sh +++ b/runners/launch_b300-nv.sh @@ -387,6 +387,7 @@ else --container-image=$SQUASH_FILE \ --container-mounts=$GITHUB_WORKSPACE:$CONTAINER_MOUNT_DIR,$HF_HUB_CACHE_MOUNT:$HF_HUB_CACHE_MOUNT,$WRITABLE_MODELS_DIR:$WRITABLE_MODELS_DIR \ --no-container-mount-home \ + --container-remap-root \ --container-workdir=$CONTAINER_MOUNT_DIR \ --no-container-entrypoint --export=ALL,PORT=8888 \ bash "$BENCH_SCRIPT" diff --git a/utils/aiperf b/utils/aiperf index 062a5de92..8c4ba9def 160000 --- a/utils/aiperf +++ b/utils/aiperf @@ -1 +1 @@ -Subproject commit 062a5de92c8ac8a0a6dd5d2a7fb9a539a147f3d9 +Subproject commit 8c4ba9deffea3ec98757545cedb7563c9d6a6a14 diff --git a/utils/process_agentic_result.py b/utils/process_agentic_result.py index 3c4015ce6..90f1aaca9 100644 --- a/utils/process_agentic_result.py +++ b/utils/process_agentic_result.py @@ -37,7 +37,6 @@ # Trace metadata lookup: conversation_id (= trace id) -> per-turn dict with # ``hash_ids`` and ``output_length``. Built lazily from the HF dataset cache. _TRACE_METADATA_CACHE: dict[str, list[dict]] | None = None -_HF_DATASET = "semianalysisai/cc-traces-weka-with-subagents-051926" # ---- helpers --------------------------------------------------------------- @@ -118,10 +117,17 @@ def load_server_metrics(path: Path) -> dict: def _hf_traces_dir() -> Path | None: """Locate the HuggingFace cache directory for the weka traces dataset. - Returns the directory containing per-trace JSON files, or None if the - dataset isn't present locally. Mirrors the layout + Returns the directory containing per-trace JSON files, or None if no + weka dataset is present locally. Mirrors the layout huggingface_hub.snapshot_download() produces: ``$HF_HUB_CACHE/datasets----/snapshots//``. + + The bench script supports several corpus revisions + (cc-traces-weka-with-subagents-052726, ...-060226, ...-060226-256k, etc.) + and may switch between them per-recipe via WEKA_LOADER_OVERRIDE. Rather + than hardcode a single dataset name, scan all ``datasets--semianalysisai + --cc-traces-weka*`` directories in the cache and pick the most-recently- + modified snapshot that contains usable trace files. """ hub_cache = os.environ.get("HF_HUB_CACHE") or os.environ.get("HUGGINGFACE_HUB_CACHE") if hub_cache: @@ -130,17 +136,23 @@ def _hf_traces_dir() -> Path | None: home = os.environ.get("HF_HOME") cache_root = Path(home) / "hub" if home else Path.home() / ".cache" / "huggingface" / "hub" - org, name = _HF_DATASET.split("/", 1) - snapshots = cache_root / f"datasets--{org}--{name}" / "snapshots" - if not snapshots.is_dir(): + if not cache_root.is_dir(): return None - candidates = sorted(snapshots.iterdir(), key=lambda p: p.stat().st_mtime, reverse=True) + + # Collect every weka-corpus snapshot dir across all matching dataset + # entries, sorted newest first. + snapshots: list[Path] = [] + for dataset_dir in cache_root.glob("datasets--semianalysisai--cc-traces-weka*"): + snap_root = dataset_dir / "snapshots" + if not snap_root.is_dir(): + continue + snapshots.extend(p for p in snap_root.iterdir() if p.is_dir()) + snapshots.sort(key=lambda p: p.stat().st_mtime, reverse=True) + # Prefer the snapshot that contains usable trace files. The published HF # dataset ships a single ``traces.jsonl`` (one trace per line); older / # local mirrors may use per-trace ``*.json`` files instead. Accept either. - for c in candidates: - if not c.is_dir(): - continue + for c in snapshots: if any(c.glob("*.jsonl")) or any(c.glob("*.json")): return c return None @@ -382,16 +394,36 @@ def compute_throughput_stats(records: list[dict], aggregate: dict) -> dict: def compute_cache_stats(records: list[dict], server_metrics: dict) -> dict: - """Cache-hit metrics: theoretical (from trace metadata) + actual (server).""" + """Cache-hit metrics: theoretical (from trace metadata) + actual (server). + + Server-metric coverage depends on the engine + KV connector combination, + so several fields are structurally null for some configs. The matrix: + + | engine + connector | populated server fields | + |----------------------------------------------|------------------------------------| + | vLLM, no connector | server_gpu_cache_hit_rate, | + | | gpu_kv_cache_usage_pct | + | vLLM + SimpleCPUOffloadConnector | same as above (the CPU tier | + | | extends the local LRU; reloads are | + | | counted as prefix_cache_hits — no | + | | separate vllm:cpu_prefix_cache_* | + | | counter exists) | + | vLLM + LMCacheMPConnector (kv_role=kv_both) | server_external_cache_hit_rate. | + | | server_gpu_cache_hit_rate goes to | + | | ~0 because delay_cache_blocks=True | + | | suppresses local hash registration | + | SGLang | not yet wired | + """ result: dict = { "theoretical_cache_hit_rate": None, "server_gpu_cache_hit_rate": None, - "server_cpu_cache_hit_rate": None, + "server_external_cache_hit_rate": None, + "gpu_kv_cache_usage_pct": None, + "cpu_kv_cache_usage_pct": None, "kv_offload_bytes_gpu_to_cpu": None, "kv_offload_bytes_cpu_to_gpu": None, "kv_offload_time_gpu_to_cpu": None, "kv_offload_time_cpu_to_gpu": None, - "cpu_kv_cache_usage_pct": None, "total_prompt_tokens": None, "total_generation_tokens": None, "total_requests_completed": None, @@ -476,15 +508,30 @@ def _final_value(metric_name: str) -> float | None: return agg return None + # Local GPU prefix cache (every vLLM config emits these). Note: with + # LMCacheMPConnector + kv_role=kv_both, the scheduler sets + # delay_cache_blocks=True on every load and these hits stay at ~0 even + # when overall cache efficiency is high — read server_external_*. hits = _final_value("vllm:prefix_cache_hits") queries = _final_value("vllm:prefix_cache_queries") if hits is not None and queries and queries > 0: result["server_gpu_cache_hit_rate"] = hits / queries - cpu_hits = _final_value("vllm:cpu_prefix_cache_hits") - cpu_queries = _final_value("vllm:cpu_prefix_cache_queries") - if cpu_hits is not None and cpu_queries and cpu_queries > 0: - result["server_cpu_cache_hit_rate"] = cpu_hits / cpu_queries + # External KV connector (LMCacheMPConnector and similar). Only populated + # when the connector implements get_num_new_matched_tokens; absent for + # SimpleCPUOffloadConnector and for pure-vLLM (no connector) runs. + ext_hits = _final_value("vllm:external_prefix_cache_hits") + ext_queries = _final_value("vllm:external_prefix_cache_queries") + if ext_hits is not None and ext_queries and ext_queries > 0: + result["server_external_cache_hit_rate"] = ext_hits / ext_queries + + # GPU KV pool fill ratio gauge. vLLM emits vllm:kv_cache_usage_perc on V1 + # and vllm:gpu_cache_usage_perc on V0 (kept for older deployments). + kv_usage = _final_value("vllm:kv_cache_usage_perc") + if kv_usage is None: + kv_usage = _final_value("vllm:gpu_cache_usage_perc") + if kv_usage is not None: + result["gpu_kv_cache_usage_pct"] = kv_usage for src_key, dst_key in ( ("vllm:kv_offload_bytes_gpu_to_cpu", "kv_offload_bytes_gpu_to_cpu"), @@ -679,6 +726,13 @@ def main() -> int: ) if agg.get("server_gpu_cache_hit_rate") is not None: print(f" GPU cache hit rate: {agg['server_gpu_cache_hit_rate']:.1%}") + if agg.get("server_external_cache_hit_rate") is not None: + print( + f" External cache hit rate: " + f"{agg['server_external_cache_hit_rate']:.1%}" + ) + if agg.get("gpu_kv_cache_usage_pct") is not None: + print(f" GPU KV cache usage: {agg['gpu_kv_cache_usage_pct']:.1%}") if agg.get("response_cache_hit_rate") is not None: print(f" Response cache hit rate: {agg['response_cache_hit_rate']:.1%}") if agg.get("theoretical_cache_hit_rate") is not None: diff --git a/utils/test_validate_agentic_result.py b/utils/test_validate_agentic_result.py new file mode 100644 index 000000000..f21bfa069 --- /dev/null +++ b/utils/test_validate_agentic_result.py @@ -0,0 +1,73 @@ +"""Tests for the agentic aiperf result validity gate.""" + +from __future__ import annotations + +import json +from pathlib import Path + +from validate_agentic_result import validate_result + + +def _write_aggregate(tmp_path: Path, aggregate: dict, *, per_run: bool = False) -> Path: + artifact_dir = tmp_path / "aiperf_artifacts" + output_dir = artifact_dir / "run_0" if per_run else artifact_dir + output_dir.mkdir(parents=True) + with open(output_dir / "profile_export_aiperf.json", "w") as f: + json.dump(aggregate, f) + return artifact_dir + + +def test_passes_when_request_error_rate_is_within_limit(tmp_path: Path): + artifact_dir = _write_aggregate( + tmp_path, + { + "request_count": {"avg": 90}, + "error_request_count": {"avg": 10}, + "completed_request_count": {"avg": 100}, + }, + ) + + assert validate_result(artifact_dir, 0.10) == [] + + +def test_fails_when_request_error_rate_exceeds_limit(tmp_path: Path): + artifact_dir = _write_aggregate( + tmp_path, + { + "request_count": {"avg": 2}, + "error_request_count": {"avg": 65}, + "completed_request_count": {"avg": 67}, + }, + ) + + errors = validate_result(artifact_dir, 0.10) + assert errors == [ + "aiperf request error rate exceeded the benchmark limit: " + "65/67 = 97.015% > 10.000%" + ] + + +def test_treats_missing_error_count_as_zero(tmp_path: Path): + artifact_dir = _write_aggregate( + tmp_path, + {"request_count": {"avg": 12}}, + ) + + assert validate_result(artifact_dir, 0.10) == [] + + +def test_supports_per_run_artifact_layout(tmp_path: Path): + artifact_dir = _write_aggregate( + tmp_path, + {"request_count": {"avg": 12}}, + per_run=True, + ) + + assert validate_result(artifact_dir, 0.10) == [] + + +def test_fails_when_aggregate_is_missing(tmp_path: Path): + errors = validate_result(tmp_path / "aiperf_artifacts", 0.10) + + assert len(errors) == 1 + assert errors[0].endswith("profile_export_aiperf.json not found") diff --git a/utils/validate_agentic_result.py b/utils/validate_agentic_result.py new file mode 100644 index 000000000..e54691059 --- /dev/null +++ b/utils/validate_agentic_result.py @@ -0,0 +1,111 @@ +#!/usr/bin/env python3 +"""Validate whether an aiperf agentic replay produced benchmarkable results.""" + +from __future__ import annotations + +import argparse +import json +import math +import sys +from pathlib import Path +from typing import Any + + +def _resolve_aggregate_path(artifact_dir: Path) -> Path: + """Find aiperf's aggregate JSON in the direct or per-run artifact layout.""" + direct = artifact_dir / "profile_export_aiperf.json" + if direct.is_file(): + return direct + + if artifact_dir.is_dir(): + for child in sorted(artifact_dir.iterdir()): + candidate = child / "profile_export_aiperf.json" + if child.is_dir() and candidate.is_file(): + return candidate + + return direct + + +def _metric_avg(aggregate: dict[str, Any], name: str) -> float | None: + """Read an aggregate metric's numeric average, if present.""" + metric = aggregate.get(name) + if metric is None: + return None + if not isinstance(metric, dict): + raise ValueError(f"{name} must be an object") + + value = metric.get("avg") + if value is None: + return None + if not isinstance(value, int | float) or isinstance(value, bool): + raise ValueError(f"{name}.avg must be numeric") + + value = float(value) + if not math.isfinite(value) or value < 0: + raise ValueError(f"{name}.avg must be a finite non-negative number") + return value + + +def validate_result(artifact_dir: Path, failed_request_threshold: float) -> list[str]: + """Return validation errors for an aiperf artifact directory.""" + aggregate_path = _resolve_aggregate_path(artifact_dir) + if not aggregate_path.is_file(): + return [f"{aggregate_path} not found"] + + try: + with open(aggregate_path) as f: + aggregate = json.load(f) + if not isinstance(aggregate, dict): + return [f"{aggregate_path} must contain a JSON object"] + + successes = _metric_avg(aggregate, "request_count") + errors = _metric_avg(aggregate, "error_request_count") or 0.0 + completed = _metric_avg(aggregate, "completed_request_count") + except (OSError, json.JSONDecodeError, ValueError) as exc: + return [f"failed to read {aggregate_path}: {exc}"] + + if successes is None: + return ["request_count.avg is missing"] + if completed is None: + completed = successes + errors + if completed <= 0: + return ["aiperf completed zero requests"] + + error_rate = errors / completed + if error_rate > failed_request_threshold: + return [ + "aiperf request error rate exceeded the benchmark limit: " + f"{errors:g}/{completed:g} = {error_rate:.3%} > " + f"{failed_request_threshold:.3%}" + ] + + print( + "Validated aiperf request error rate: " + f"{errors:g}/{completed:g} = {error_rate:.3%} <= " + f"{failed_request_threshold:.3%}" + ) + return [] + + +def main() -> int: + parser = argparse.ArgumentParser() + parser.add_argument("artifact_dir", type=Path) + parser.add_argument( + "--failed-request-threshold", + type=float, + required=True, + help="Maximum accepted error fraction, inclusive", + ) + args = parser.parse_args() + + if not 0 <= args.failed_request_threshold <= 1: + parser.error("--failed-request-threshold must be between 0 and 1") + + errors = validate_result(args.artifact_dir, args.failed_request_threshold) + for error in errors: + print(f"ERROR: {error}", file=sys.stderr) + return 1 if errors else 0 + + +if __name__ == "__main__": + sys.exit(main())