recipe.toml 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109
  1. # BLOCKED 2026-09-06 (night shift): the eugr 0904 image's DeepseekV4ForCausalLM
  2. # has no `aligner` module (predates V4-Vision support) — the Vision-Exp
  3. # checkpoint's vision weights fail to load. Re-check on a newer eugr image;
  4. # the fork lane `dsv4-flash-vision` remains the only V4-Vision path.
  5. #
  6. # DeepSeek-V4-Flash-Vision-Exp — eugr B12X variant (vLLM) — 2× DGX Spark, TP=2.
  7. #
  8. # The eugr-stack A/B cell against our fork lane `dsv4-flash-vision` (same
  9. # model, same node shape; their prebuilt image vs our dsv4-flash-vision:local
  10. # overlay + dsv4_vision plugin). Port of eugr's deepseek-v4-flash-0731.yaml
  11. # shape (eugr/spark-vllm-docker @ main) onto the Vision-Exp model.
  12. #
  13. # Image: eugr/spark-vllm-b12x:nightly-20260904 (digest c3b44d3f…, = :latest).
  14. # local-inference-lab/vllm dev/jovian-judgement 09-04 tip (ref switched from
  15. # dev/infernal-invocation by their e91bc76, 09-03) + lukealonso/b12x @ master
  16. # + their patch set; torch 2.13.0, CUDA 13.0.2, cutlass-dsl 4.7.0.
  17. # NOTE: image ships NO ENTRYPOINT → entrypoint = ["vllm","serve"] below.
  18. # Exact b12x pin baked in-image: /workspace/b12x-source-commit.
  19. #
  20. # Model: deepseek-ai/DeepSeek-V4-Flash-Vision-Exp (MIT; ~168 GB on disk,
  21. # experts MXFP4 / attention FP8, 32-layer ViT BF16). Reuse the per-node
  22. # local NVMe copies from the fork lane if present (~/dsv4vision-hf on
  23. # dgx3/dgx4, rsync'd 2026-09-01 — check the HF_HOME mapping); else
  24. # huggingface-cli download on BOTH nodes (HF_HUB_OFFLINE=1 below).
  25. #
  26. # Diffs vs the fork lane (dsv4-flash-vision) — deliberate parity choices:
  27. # - attention backend: plain B12X (their 09-03 switch away from
  28. # B12X_MLA_SPARSE) — the fork lane keeps B12X_MLA_SPARSE
  29. # - VLLM_USE_MEGA_AOT_ARTIFACT=1 (their 09-03 switch; fork lane: -1)
  30. # - max-cudagraph-capture-size 48 (their 09-03 value)
  31. # - spec: vendor card k=3 + enable_adaptive_verification (published:
  32. # 2.99 mean acceptance, 66.3%); k=6 (fork lane's proven value) is the
  33. # fallback if adaptive verification misbehaves on this stack
  34. # - VLLM_USE_B12X_MHC forced 0 like the fork lane: this checkpoint has
  35. # rms_norm_eps 1e-20, the fused Gram mHC kernel only accepts 1e-6
  36. # - no dsv4_vision plugin (their image has stock vLLM vision path) — if
  37. # boot fails on the vision processor, that's the first suspect
  38. #
  39. # REFERENCE:
  40. # https://github.com/eugr/spark-vllm-docker (recipes/deepseek-v4-flash-0731.yaml)
  41. # https://huggingface.co/deepseek-ai/DeepSeek-V4-Flash-Vision-Exp
  42. # https://recipes.vllm.ai/deepseek-ai/DeepSeek-V4-Flash-Vision-Exp
  43. engine = "vllm"
  44. name = "DeepSeek V4 Flash Vision-Exp (vLLM, 2x Spark, eugr B12X, DSpark-3)"
  45. docker_image = "eugr/spark-vllm-b12x:nightly-20260904"
  46. model = "deepseek-ai/DeepSeek-V4-Flash-Vision-Exp"
  47. required_nodes = 2
  48. tensor_parallel_size = 2
  49. pipeline_parallel_size = 1
  50. distributed_backend = "mp"
  51. shm_size = "32gb"
  52. # image ships no ENTRYPOINT — the launcher supplies the vllm command
  53. entrypoint = ["vllm", "serve"]
  54. args = [
  55. # Stable served name (shared with the fork lane — quant/stack-agnostic)
  56. "--served-model-name", "deepseek-v4-flash-vision",
  57. "--trust-remote-code",
  58. "--distributed-executor-backend", "mp",
  59. # eugr 0731 shape: full b12x cluster, plain B12X attention (09-03 switch)
  60. "--moe-backend", "b12x",
  61. "--linear-backend", "b12x",
  62. "--attention-backend", "B12X",
  63. "--max-model-len", "1048576",
  64. "--kv-cache-dtype", "fp8",
  65. # fork lane's proven pool for this checkpoint on 2 Sparks (1.25M tokens)
  66. "--kv-cache-memory-bytes", "12884901888",
  67. "--gpu-memory-utilization", "0.85",
  68. "--max-num-seqs", "2",
  69. "--max-num-batched-tokens", "8192",
  70. "--block-size", "256",
  71. "--max-cudagraph-capture-size", "48",
  72. # vendor card (published numbers): DSpark k=3, probabilistic, adaptive
  73. "--speculative-config", """
  74. '{"method":"dspark","num_speculative_tokens":3,"draft_sample_method":"probabilistic","attention_backend":"B12X","enable_adaptive_verification":true}'""",
  75. "--tokenizer-mode", "deepseek_v4",
  76. "--tool-call-parser", "deepseek_v4",
  77. "--enable-auto-tool-choice",
  78. "--reasoning-parser", "deepseek_v4",
  79. "--reasoning-config", """
  80. '{"reasoning_parser":"deepseek_v4","reasoning_start_str":"","reasoning_end_str":""}'""",
  81. "--default-chat-template-kwargs", """
  82. '{"thinking":false,"reasoning_effort":"low"}'""",
  83. "--limit-mm-per-prompt", """
  84. '{"image":8}'""",
  85. "--enable-prefix-caching",
  86. "--load-format", "instanttensor",
  87. ]
  88. [env]
  89. CUTE_DSL_ARCH = "sm_121a"
  90. VLLM_USE_AOT_COMPILE = "1"
  91. VLLM_USE_BREAKABLE_CUDAGRAPH = "0"
  92. VLLM_USE_MEGA_AOT_ARTIFACT = "1"
  93. VLLM_MEMORY_PROFILE_INCLUDE_ATTN = "1"
  94. VLLM_USE_FLASHINFER_SAMPLER = "1"
  95. VLLM_USE_B12X_WO_PROJECTION = "1"
  96. # OFF for this checkpoint (rms_norm_eps 1e-20 — see header); their 0731
  97. # text recipe sets it 1, but the model constraint wins
  98. VLLM_USE_B12X_MHC = "0"
  99. VLLM_USE_B12X_FP8_GEMM = "1"
  100. VLLM_USE_B12X_MOE = "1"
  101. VLLM_USE_B12X_SPARSE_INDEXER = "1"
  102. VLLM_USE_V2_MODEL_RUNNER = "1"
  103. B12X_MLA_SM120_UNIFIED = "1"
  104. B12X_MOE_FORCE_A8 = "1"
  105. HF_HUB_OFFLINE = "1"
  106. VLLM_ENGINE_READY_TIMEOUT_S = "3600"