recipe.toml 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. # Aiden's published production-1.1 DCP2 stack (prebuilt image, no build).
  2. #
  3. # Image: aidendle94/sparkrun-vllm-dsv41-gb10:production-1.1 (Docker Hub, 23.4 GB,
  4. # published 2026-09-11T16:54Z). Internals (verified):
  5. # vllm 0.28.1rc1.dev388+g8a728663c (base vllm/vllm-openai nightly 8a728663,
  6. # NOT our e47aa780 pin) + b12x 1.3.0 + FlashInfer 0.7.0rc1 + torch 2.13.0+cu130.
  7. # The 24-file DCP2 patch set is baked into the tree (manifest at
  8. # /opt/dsv41-dcp2-mounts.txt) + FI source with trtllm_dcp_alltoall.cu /
  9. # cake_dcp.py. DCP knobs are env-gated, OFF by default in-image:
  10. # DSV41_DCP_STAGE=3 (default), DSV41_DCP_COMBINE=ag_rs, DSV41_DCP_PREFILL_GATHER=0,
  11. # DSV41_ENGRAM_MMAP=0, DSV41_ENGRAM_PREFETCH=0.
  12. #
  13. # This recipe = their DCP2 core (TP4 + --decode-context-parallel-size 2 +
  14. # --dcp-comm-backend a2a + 8 GiB pinned KV, their measured 300K-ctx row) on our
  15. # serving config (DSpark k=5 exact capture, max-num-seqs 8, thinking+max
  16. # default, deepseek-v4-flash alias) so the A/B isolates the DCP2 delta.
  17. #
  18. # A/B baseline: dsv41-flash-4x-b12x (167/176 @ 512K ctx, DSV41_ENGRAM_LOCAL on
  19. # our clone-at-pin stack). Context differs on purpose: their top-k/indexer
  20. # validation row is 300K.
  21. #
  22. # Engram: our per-node local copies (47.2 GiB each, /var/tmp/engram-local) —
  23. # the engine reads its rank's row ranges from there, no NFS at runtime.
  24. #
  25. # Prebuilt: no docker_image_dir — the image is pulled manually to the nodes
  26. # (sm121 does not pull external images).
  27. engine = "vllm"
  28. name = "DeepSeek-V4.1-Flash MXFP4 (Aiden production-1.1 img, 4x, DCP2)"
  29. docker_image = "aidendle94/sparkrun-vllm-dsv41-gb10:production-1.1"
  30. model = "deepseek-ai/DeepSeek-V4.1-Flash"
  31. port = 30000
  32. required_nodes = 4
  33. tensor_parallel_size = 4
  34. pipeline_parallel_size = 1
  35. distributed_backend = "mp"
  36. shm_size = "32gb"
  37. args = [
  38. "--served-model-name", "deepseek-v4-flash",
  39. "--trust-remote-code",
  40. "--distributed-executor-backend", "mp",
  41. "--gpu-memory-utilization", "0.85",
  42. # Aiden's validated row: 300K ctx (their top-k fix is validated <=300K)
  43. "--max-model-len", "300000",
  44. "--max-num-seqs", "8",
  45. "--max-num-batched-tokens", "8192",
  46. "--block-size", "128",
  47. # Our exact capture sizes for DSpark k=5, SEQS=8 (no padding batches)
  48. "--compilation-config", """
  49. '{"cudagraph_mode":"FULL_AND_PIECEWISE","cudagraph_capture_sizes":[5,6,10,12,15,18,20,24,25,30,35,36,40,42,48]}'""",
  50. "--speculative-config", """
  51. '{"method":"dspark","num_speculative_tokens":5,"draft_sample_method":"probabilistic","rejection_sample_method":"block","enable_adaptive_verification":false}'""",
  52. "--moe-backend", "b12x",
  53. "--linear-backend", "b12x",
  54. "--kv-cache-dtype", "fp8",
  55. # Their DCP2 core: 2-way decode context parallelism over the a2a path
  56. "--decode-context-parallel-size", "2",
  57. "--dcp-comm-backend", "a2a",
  58. # Their pinned KV (8 GiB = 1.26M tokens at 300K, ~1.89M with DCP2)
  59. "--kv-cache-memory-bytes", "8589934592",
  60. "--tool-call-parser", "deepseek_v41",
  61. "--enable-auto-tool-choice",
  62. "--reasoning-parser", "deepseek_v41",
  63. "--default-chat-template-kwargs", """
  64. '{"thinking": true, "reasoning_effort": "max"}'""",
  65. ]
  66. [env]
  67. HF_HUB_OFFLINE = "1"
  68. # Engram tables on node-local sparse copies (disk mode, their launch defaults)
  69. DSV41_ENGRAM_DISK = "1"
  70. DSV41_ENGRAM_DISK_THREADS = "32"
  71. DSV41_ENGRAM_DISK_CHUNK = "16"
  72. DSV41_ENGRAM_LOCAL = "1"
  73. DSV41_ENGRAM_DIR = "/engram-local"
  74. # DCP2 activation (image defaults are off; Aiden's launcher enables these)
  75. DSV41_DCP_STAGE = "3"
  76. DSV41_DCP_COMBINE = "a2a"
  77. DSV41_DCP_PREFILL_GATHER = "1"
  78. DSV41_ENGRAM_MMAP = "1"
  79. DSV41_ENGRAM_PREFETCH = "1"
  80. # Runtime JIT wedge countermeasure + arch pins (same stack family)
  81. MAX_JOBS = "2"
  82. OMP_NUM_THREADS = "2"
  83. PYTORCH_CUDA_ALLOC_CONF = "expandable_segments:True"
  84. TORCH_CUDA_ARCH_LIST = "12.1a"
  85. FLASHINFER_CUDA_ARCH_LIST = "12.1a"
  86. VLLM_ENGINE_READY_TIMEOUT_S = "3600"
  87. # Per-node sparse Engram copy (model-00047/00048 shards + engram-local.json)
  88. [[extra_mounts]]
  89. host = "/var/tmp/engram-local/DeepSeek-V4.1-Flash"
  90. container = "/engram-local"
  91. read_only = true
  92. # JIT caches persist per node (fresh tree => first boot re-JITs, then cached)
  93. [[extra_mounts]]
  94. host = "~/sm121-cache/jit-121f/flashinfer"
  95. container = "/root/.cache/flashinfer"
  96. [[extra_mounts]]
  97. host = "~/sm121-cache/jit-121f/torchinductor"
  98. container = "/root/.cache/torchinductor"
  99. [[extra_mounts]]
  100. host = "~/sm121-cache/jit-121f/vllm"
  101. container = "/root/.cache/vllm"
  102. # B12X kernel JIT cache (B12X_CACHE_DIR)
  103. [[extra_mounts]]
  104. host = "~/sm121-cache/jit-121f/b12x"
  105. container = "/root/.cache/b12x"