2026-09-28_121802_mopd-4x.recipe.toml 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. # MiMo-V2.6-Flash-MOPD (Xiaomi, ~310B total / 12B-active MoE) on 4x DGX Spark
  2. # with SGLang + DFlash — the 4-node contingency lane for the 2x production.
  3. #
  4. # Rationale (2026-09-28): the 2x lane (recipes/mimo26-flash-mopd-2x) hit the
  5. # 512K target at GMU 0.90 with a 570,752-token pool but only ~109K tokens of
  6. # headroom and ~7 GB free host after a 515K probe. On 4 nodes each rank books
  7. # ~44.5 GB of weights (178 GB / TP4) instead of ~89 GB, so the KV pool grows
  8. # ~3x at equal GMU — a single 524K request needs only a fraction of it and
  9. # many concurrent long requests fit.
  10. #
  11. # GMU trials (SGLang accounts mem-fraction-static more precisely than vLLM's
  12. # ~0.84 ceiling on this stack — 2x booted clean at 0.90 with 8 GB GPU + 7 GB
  13. # host headroom, so pushing further on TP4 is cheap): 0.90 -> 0.92 -> 0.94.
  14. # Current: 0.94 (prod). Measured 2026-09-28: 0.92 → pool 3,971,456, GPU 6.3
  15. # GB free; 0.94 → pool 4,138,432, GPU 5.35 GB free, host ~4 GB during the
  16. # 515K-token probe (reclaimable page cache, not an OOM signal — the probe
  17. # served clean in 340 s). SGLang's static fraction is accounted tightly:
  18. # both values boot and serve without a hitch, so the knob is free to push.
  19. #
  20. # Image: docker-images/mimo26-spark (a14) — same as the 2x lane; at TP4 the
  21. # FP8 tile fallbacks of the 2x regime apply (RoCEnante one-shot all-reduce
  22. # is TP8-only, stock NCCL over the 200G fabric is used).
  23. #
  24. # Cluster: 4nodes-switch (dgx1..dgx4). Serve with --cluster 4nodes-switch;
  25. # NCCL HCA/ifaces come from [nccl."4nodes-switch"], the DAC-specific
  26. # NCCL_PROTO override of the 2x lane is kept (reference deployment).
  27. engine = "sglang"
  28. name = "MiMo-V2.6-Flash-MOPD (SGLang DFlash, 4x Spark TP4)"
  29. docker_image = "mimo26-spark:a14"
  30. docker_image_dir = "mimo26-spark"
  31. model = "XiaomiMiMo/MiMo-V2.6-Flash-MOPD"
  32. parent_model = "XiaomiMiMo/MiMo-V2.6-Flash-MOPD"
  33. port = 30000
  34. required_nodes = 4
  35. tensor_parallel_size = 4
  36. distributed_backend = "mp"
  37. shm_size = "16gb"
  38. entrypoint = ["python3", "-m", "sglang.launch_server"]
  39. args = [
  40. "--trust-remote-code",
  41. "--served-model-name", "mimo-v2.6-flash",
  42. # Attention / MoE backends (same as the 2x lane)
  43. "--attention-backend", "triton",
  44. "--prefill-attention-backend", "fa4",
  45. "--mm-attention-backend", "triton_attn",
  46. "--enable-multimodal",
  47. "--moe-runner-backend", "marlin",
  48. "--moe-a2a-backend", "none",
  49. "--mem-fraction-static", "0.94",
  50. "--context-length", "524288",
  51. "--max-running-requests", "8",
  52. "--chunked-prefill-size", "8192",
  53. "--page-size", "64",
  54. "--swa-full-tokens-ratio", "0.1",
  55. "--reasoning-parser", "mimo",
  56. "--tool-call-parser", "mimo",
  57. "--speculative-algorithm", "DFLASH",
  58. "--speculative-draft-model-path", "{{dflash}}",
  59. "--speculative-num-draft-tokens", "8",
  60. "--cuda-graph-max-bs-decode", "8",
  61. "--disable-prefill-cuda-graph",
  62. "--weight-loader-drop-cache-after-load",
  63. "--enable-metrics",
  64. "--enable-cache-report",
  65. "--watchdog-timeout", "1800",
  66. ]
  67. # DFlash draft weights: a subfolder of the main model repo, resolved per node.
  68. [[extra_mounts]]
  69. repo = "XiaomiMiMo/MiMo-V2.6-Flash-MOPD"
  70. subfolder = "dflash"
  71. container = "dflash"
  72. # JIT/compile cache (verified against the live container, 2026-09-28): SGLang
  73. # keeps everything under /root/.cache/sglang — triton .so (~35 hash dirs),
  74. # inductor (aotautograd/ev/fxgraph), nv/, flashinfer .cache. Bind it to a
  75. # node-local NVMe dir so boots reuse compiled artifacts instead of redoing
  76. # JIT; keys are content/hash based, so mixing images/lanes on one dir is
  77. # safe (and switching 2x<->4x reuses the other's cache). b12x-roce does not
  78. # materialize on TP<8 — nothing else to mount.
  79. [[extra_mounts]]
  80. host = "~/.cache/mimo26-jit/sglang"
  81. container = "/root/.cache/sglang"
  82. [env]
  83. # RoCEnante overlay is TP8-only (needs the TP8 Gloo exchange group) — stock
  84. # NCCL on TP4.
  85. # a13/a14 tuning switches
  86. MIMO26_FP8_OPROJ = "1"
  87. MIMO26_FP8_DRAFT = "1"
  88. MIMO26_DFLASH_ADAPTIVE = "1"
  89. # NCCL extras from the reference deployment (HCAs/ifname from [nccl."4nodes-switch"])
  90. NCCL_CUMEM_ENABLE = "0"
  91. NCCL_NVLS_ENABLE = "0"
  92. NCCL_PROTO = "^LL128"
  93. NCCL_BUFFSIZE = "1048576"
  94. NCCL_LL128_BUFFSIZE = "262144"
  95. NCCL_MAX_NCHANNELS = "8"
  96. NCCL_DEBUG = "WARN"