Field SOP
Field SOP

LingBot-World 2.0 Local Small Model Deployment SOP

A hands-on SOP for running LingBot-World 2.0's 1.3B causal-fast locally: environment and dependencies (torch 2.4.0 or newer, flash-attn and the rest, commands taken verbatim from the official requirements.txt), then weights download (the 1.3B package ships DiT weights only, while T5, VAE and the tokenizer are shared with 14B, so you must point assets_dir at a 14B directory or it will not start), then a first successful clip (torchrun or the official run_fast.sh), then parameter tuning (frame_num must be 4n+1, local_attn_size 18, sink_size 6, chunk_size, base_seed, save_dir), and finally production and deployment paths (the official team releases no deployment code, so reference the SGLang cookbook or NVIDIA flashdreams), closing with eight pitfalls and a ten-item launch checklist. Key pitfalls: the hardware bar has three conflicting versions (README 1.3B example uses 4 GPUs, run_fast.sh reference says 2, media claim consumer single-card real time), so trust the repo, treat 2 GPUs as the reproducible floor, and mark single-card real time unconfirmed; ulysses_size must divide the attention head count (12 for 1.3B, 40 for 14B) and equal nproc_per_node; choose between causal_fast (4 steps per chunk, no CFG) and causal_pretrain (40 steps per chunk, with CFG); and the CC BY-NC-SA 4.0 license is non-commercial, so confirm authorization before any productization.

Published September 14, 202611 min read
<!-- lingbot-world-small-local-deploy-sop | sop | LingBot-World 2.0 Local Small Model Deployment SOP -->

Who Should Read This

LingBot-World 2.0 (repo alias LingBot-World-Infinity) is Robbyant's open-source "world model" video system, built on Wan2.2 (Wan-Video). Its core is causal, chunk-by-chunk inference: given a first frame plus a camera/action path, it keeps generating interactive video along that path. Input is not just a prompt; it is one image plus one camera/action path plus one textual event. Output is a long video extending along the path.

This SOP targets Chinese technical practitioners who want to run this system locally, reproduce the official demo, and build on it. Keep reading if you are a researcher on world models or video generation needing a local base; an engineering lead checking feasibility before productization; or a developer already on the Wan family who wants interactive long video in an existing pipeline.

Skip this if you only want to click and play (use Reactor for international web, or LingGuang for domestic mobile); if you plan to ship a commercial product (read the license section first, CC BY-NC-SA 4.0, non-commercial); or if you have only one consumer GPU under 24G (there is no single-card real-time path in the repo). One-line judgment: this is a hands-on manual to get the official repo running and stable, not a concept primer and not a commercial plan.

Environment and Dependencies

Clarify the hardware bar first, because the repo is internally inconsistent here and I list the versions honestly.

On hardware, the 1.3B model has two official reference configs. The README example uses 4 GPUs (--nproc_per_node=4), while run_fast.sh comments state the 1.3B reference is 2 GPUs (ulysses_size=2, the 1.3B causal-ODE CP=1 recipe). The 14B model uses 8 GPUs. Media and the official demo claim "1.3B Small runs in real time on a consumer single GPU", but that has no reproducible command in the repo. Taking the repo as truth, the minimum reproducible reference for 1.3B is 2 GPUs; single-card real time is officially unconfirmed. For the easy path, use run_fast.sh, which infers GPU count from the weights directory name.

Key dependencies from requirements.txt: torch>=2.4.0, torchvision>=0.19.0, diffusers>=0.31.0, transformers>=4.49.0,<=4.51.3 (note the upper bound), flash_attn, numpy>=1.23.5,<2 (numpy 2.x breaks, pin to 1.x), opencv-python>=4.9.0.80. Use Python 3.10 and CUDA 12.1+, matching Wan2.2.

Install commands, verbatim from the official files:

sh
git clone https://github.com/robbyant/lingbot-world-v2.git
cd lingbot-world-v2
pip install -r requirements.txt
pip install flash-attn --no-build-isolation

flash-attn needs --no-build-isolation because it compiles from source against the current torch. Install it last and separately so failures are easy to locate. If you already have a Wan2.2 environment, reuse it; for install problems, consult Wan-Video docs, since this repo is modified from Wan2.2.

Weight Download (Including 1.3B Missing-Asset Handling)

Four variants, by hardware and quality:

  • lingbot-world-v2-14b-causal-fast: 14B, distilled few-step, default mode.
  • lingbot-world-v2-14b-causal-pretrain: 14B, pretrained causal, higher quality, slower.
  • lingbot-world-v2-14b-bid: 14B, bidirectional.
  • lingbot-world-v2-1.3b-causal-fast: 1.3B, distilled few-step, small-model choice.

Download with huggingface-cli, verbatim. Note the 1.3B --local-dir carries a /transformers suffix; this is official, do not remove it:

sh
pip install "huggingface_hub[cli]"
huggingface-cli download robbyant/lingbot-world-v2-1.3b-causal-fast --local-dir ./lingbot-world-v2-1.3b-causal-fast/transformers

The 14B download has no suffix:

sh
huggingface-cli download robbyant/lingbot-world-v2-14b-causal-fast --local-dir ./lingbot-world-v2-14b-causal-fast

In regions where HuggingFace is slow, use ModelScope: modelscope download robbyant/... --local_dir ./..., swapping the command, with the same directory structure.

The key pitfall: the 1.3B package contains only DiT weights; T5, VAE, and the tokenizer are shared with 14B. Download a 14B directory too, then point --assets_dir at it during inference (or use the third argument of run_fast.sh). I strongly recommend small-model users keep the 14B weights as an asset library; disk for stability is worth it.

Run Your First Clip

Goal: generate one official example clip end to end to prove environment, weights, and parallel config are correct.

The simplest path is the official run_fast.sh. It infers task and GPU count from the directory name: 1.3b or 1p3b means 1.3B, NPROC=2, GPU 0,1; otherwise 14B, NPROC=8, GPU 0-7. The third argument is assets_dir, mandatory for 1.3B:

sh
bash run_fast.sh lingbot-world-v2-1.3b-causal-fast 361 lingbot-world-v2-14b-causal-fast

This equals the full torchrun form below (README 1.3B example, 4 GPUs). Note --assets_dir points at 14B:

sh
torchrun --nproc_per_node=4 generate.py --task i2v-1.3B --size 480*832 --ckpt_dir lingbot-world-v2-1.3b-causal-fast --assets_dir lingbot-world-v2-14b-causal-fast --image examples/03/image.jpg --action_path examples/03 --dit_fsdp --t5_fsdp --ulysses_size 4 --frame_num 361 --local_attn_size 18 --sink_size 6 --prompt "A serene lakeside scene with a lone tree standing in calm water, surrounded by distant snow-capped mountains under a bright blue sky with drifting white clouds — gentle ripples reflect the tree and sky, creating a tranquil, meditative atmosphere."

For the 14B pretrained causal model (higher quality, 40 steps per chunk with CFG), the official command is:

sh
torchrun --nproc_per_node=8 generate.py --task i2v-A14B --infer_mode causal_pretrain --size 480*832 --ckpt_dir lingbot-world-v2-14b-causal-pretrain --image examples/03/image.jpg --action_path examples/03 --dit_fsdp --t5_fsdp --ulysses_size 8 --frame_num 81 --prompt "A serene lakeside scene with a lone tree standing in calm water, surrounded by distant snow-capped mountains under a bright blue sky with drifting white clouds — gentle ripples reflect the tree and sky, creating a tranquil, meditative atmosphere."

Success is an .mp4 under output/ whose name contains causal_fast or causal_pretrain, size, ulysses_size, and a timestamp. Import or compile errors mean check versions; an assert about attention heads means read ulysses_size below.

Parameter Tuning: Frames, Window, Chunk, Seed

Defaults below come from the argparse in generate.py.

--frame_num: frames to generate, must be 4n+1 (81, 161, 361). Sets duration with cfg.sample_fps. Longer means more memory and time.

--local_attn_size: KV-cache local attention window, default -1 (use config). Official uses 18. Controls how many past frames the model sees; too small breaks long-range consistency, too large costs memory and compute.

--sink_size: KV-cache sink size, default 0, official uses 6. With local_attn_size it shapes the window; keep the official combo for long video.

--chunk_size: frames per chunk, default 4. The streaming unit; usually keep default.

--base_seed: seed, default 42. Fix to reproduce, change for variety. Rank 0 broadcasts it under multi-GPU, so set one.

--save_dir: output directory, default output.

--size: area width*height, default 1280*720, official uses 480*832. Under i2v the aspect follows the input image, so this mainly sets total area and compute.

The critical parallel arg is --ulysses_size: Ulysses degree, default 1, must divide head count. generate.py asserts cfg.num_heads % ulysses_size == 0. 1.3B has 12 heads (use 2 or 4); 14B has 40 (official 8). Wrong value raises cannot be divided evenly. Also ulysses_size must equal world_size (nproc_per_node), so change both together.

--infer_mode: causal_fast (default, 4 steps per chunk, no CFG, fast) or causal_pretrain (40 steps per chunk, with CFG, slower, higher quality). --dit_fsdp/--t5_fsdp shard across GPUs, required multi-GPU. --t5_cpu puts T5 on CPU to save GPU memory but slower. --offload_model unloads to CPU after each forward; turn these on in order when memory is tight.

Production and Deployment Paths

The official repo states "We do NOT plan to release our deployment code". For a service, high concurrency, or low latency, build it yourself; do not wait for an official solution.

Two reference paths. First, the SGLang LingBot-World cookbook at https://docs.sglang.io/cookbook/diffusion/LingBot-World/LingBot-World-2.0, which targets diffusion deployment with a ready pattern. Second, NVIDIA's flashdreams repo. Both are references, not turnkey; you must wire weights, pre/post-processing, and scheduling yourself.

On scaling: ulysses_size is sequence parallelism bounded by head divisibility (max 12 for 1.3B, 40 for 14B). For more throughput, layer FSDP and data parallelism on top. But generate.py is single-node multi-GPU; cross-node, dynamic batching, and streaming serving are outside its scope and must be built on SGLang or flashdreams. Use generate.py for local work, a separate stack for production.

Before you provision hardware, do the arithmetic honestly. Sequence parallelism is bounded by head divisibility, so a 1.3B run tops out at 4 ranks and a 14B run at 8; adding more GPUs past that point buys nothing for a single clip and only helps if you also shard weights with FSDP or run several independent jobs. For a research loop, two to four cards is a realistic floor, and one long clip still occupies those cards for its whole duration, so you cannot batch many clips on the same rig without a queue. Treat throughput as clips per hour per GPU set, measure it once at your own resolution and frame count, and budget from that number instead of vendor framing. Because the official team ships no serving layer, the request queue, scheduler, health checks, and retry logic are all yours to write, so budget engineering time alongside GPU hours.

Pitfalls (Eight Notes)

  1. The 1.3B package has only DiT weights. T5, VAE, and the tokenizer are shared with 14B, so point --assets_dir (or run_fast.sh's third arg) at the 14B directory, or it will not run. The most common newcomer pitfall.

  2. Hardware bar has three conflicting versions, listed honestly. README 1.3B example uses 4 GPUs; run_fast.sh comment says 2 GPUs (12 heads, ulysses divides 12, the 1.3B causal-ODE CP=1 recipe); media and demo claim consumer single-card real time. Conclusion: repo truth is 2 GPUs minimum; single-card real time is unconfirmed in the repo.

  3. ulysses_size must divide head count. 1.3B=12 heads (2 or 4), 14B=40 heads (8). Wrong value triggers the assert in generate.py.

  4. causal_fast versus causal_pretrain. Fast is distilled, 4 steps per chunk, no CFG, default. Pretrain is 40 steps per chunk, with CFG, slower, higher quality. Do not demand one from the other.

  5. No open-source deployment code. For production use SGLang or flashdreams yourself; do not expect generate.py as a service.

  6. License is CC BY-NC-SA 4.0, non-commercial. Confirm authorization before any commercial use; derivatives must share the license. A legal red line, not a detail.

  7. Built on Wan2.2. For install and compile issues, Wan-Video docs are the fastest reference, same origin.

  8. Frame count and window params strongly affect long video. --frame_num sets duration; --local_attn_size 18 and --sink_size 6 are the official long-video combo; --chunk_size is the streaming unit; --base_seed controls reproducibility; --save_dir controls output. Tune these together for long video.

Pre-Launch Checklist (Ten Items)

  1. Repo cloned and cded in, path correct.
  2. pip install -r requirements.txt and flash-attn --no-build-isolation both succeeded.
  3. transformers in >=4.49.0,<=4.51.3 and numpy in >=1.23.5,<2.
  4. Weights directory exists, plus a 14B directory as the --assets_dir library.
  5. 1.3B command carries --assets_dir pointing at 14B, or it fails.
  6. --ulysses_size divides head count (1.3B=12, 14B=40) and equals nproc_per_node.
  7. --frame_num is 4n+1 and matches the wanted duration.
  8. An .mp4 exists under output/, normal size, playable.
  9. Chosen infer_mode matches speed/quality expectation.
  10. License assessed: continue only non-commercial; confirm authorization for commercial.

Sister Articles and Further Reading

Companion pieces, already published:

  • Hotspot analysis: /en/posts/lingbot-world-2-0-hotspot
  • Open-source resource roundup: /en/posts/gods-eye-view-resource
  • World-model comparison review: /en/posts/open-world-model-comparison-review

What You Can and Cannot Do Today (Honest Judgment)

What it can do today: on 2-plus GPUs (1.3B) or 8 GPUs (14B), it stably reproduces official-demo-grade interactive long video; it supports research reproduction and secondary development; and it lets you wire first-frame-plus-trajectory driven video into your pipeline. Quality ceiling is visible in the examples, with 14B causal_pretrain at the top.

What it cannot do: first, it cannot run in real time on a consumer single card. That is the demo/media claim with no repo reproduction path, so do not set boss expectations with it. Second, it is not a ready service; production depends on SGLang or flashdreams you build. Third, and key, it cannot be commercial. The license is CC BY-NC-SA 4.0, non-commercial. Any productization, charging, or closed distribution must confirm authorization first and prepare derivatives to be open-sourced under the same license. Think that through before investing engineering resources.

One practical way to decide is to separate evaluation from production. Use the local, single-node path to answer whether the model's output quality clears your bar for a specific scene, then decide separately whether the serving story justifies the engineering. If the answer to the first is yes and the second is no, the honest move is to keep the model inside an offline content pipeline rather than promise an interactive feature you cannot operate. Also watch the moving parts: the repo is young, the public issue list is small, and the license forbids the commercial use most product teams quietly assume, so any plan that depends on shipping it should start from the license, not from the demo video.

FAQ

Q1: I only have one consumer GPU; can I run 1.3B? A1: Repo truth is 2 GPUs minimum (ulysses_size=2). README uses 4, run_fast.sh says 2. "Consumer single-card real time" is the demo/media claim with no repo path, marked unconfirmed. Whether single card runs is unverified, so we call it unconfirmed.

Q2: Why does 1.3B fail to find T5/VAE after download? A2: The 1.3B package has only DiT weights; T5, VAE, and tokenizer are shared with 14B. Download a 14B directory and point --assets_dir at it (or run_fast.sh's third arg). This is explicit in the README, not a broken environment.

Q3: Can I set ulysses_size to 3? A3: No. generate.py asserts ulysses_size must divide head count. 1.3B has 12 heads (2 or 4); 14B has 40 (official 8). Setting 3 raises an assert. It must also equal nproc_per_node.

Q4: causal_fast or causal_pretrain? A4: causal_fast for speed (default, 4 steps per chunk, no CFG). causal_pretrain for quality (40 steps per chunk, with CFG, slower). A speed-quality trade-off, neither better; depends on scenario.

Q5: I want to ship a product; will the official team give deployment code? A5: No. The official team does not release deployment code. For production use the SGLang cookbook or NVIDIA flashdreams and build it yourself. Also the license is CC BY-NC-SA 4.0, non-commercial; confirm authorization before commercial use, derivatives under the same license.

This article is AI-assisted and human-edited. Last updated: 2026-09-14

FAQ

I only have one consumer GPU; can I run 1.3B?
Repo truth is 2 GPUs minimum (ulysses_size=2). README uses 4, run_fast.sh says 2. "Consumer single-card real time" is the demo/media claim with no repo path, marked unconfirmed. Whether single card runs is unverified, so we call it unconfirmed.
Why does 1.3B fail to find T5/VAE after download?
The 1.3B package has only DiT weights; T5, VAE, and tokenizer are shared with 14B. Download a 14B directory and point `--assets_dir` at it (or run_fast.sh's third arg). This is explicit in the README, not a broken environment.
Can I set ulysses_size to 3?
No. generate.py asserts ulysses_size must divide head count. 1.3B has 12 heads (2 or 4); 14B has 40 (official 8). Setting 3 raises an assert. It must also equal nproc_per_node.
causal_fast or causal_pretrain?
causal_fast for speed (default, 4 steps per chunk, no CFG). causal_pretrain for quality (40 steps per chunk, with CFG, slower). A speed-quality trade-off, neither better; depends on scenario.
I want to ship a product; will the official team give deployment code?
No. The official team does not release deployment code. For production use the SGLang cookbook or NVIDIA flashdreams and build it yourself. Also the license is CC BY-NC-SA 4.0, non-commercial; confirm authorization before commercial use, derivatives under the same license.

Related

Field SOP

428B Weights Are Out, Budget 8 H100s: M3.1 Flash Local Deploy

A deployment log for M3.1 Flash (428B, 23B active). Cold water first: there is no consumer or single-GPU recipe anywhere official - the smallest validated tiers are 4x Blackwell (B200/B300/GB200/GB300, TP4), 4x AMD MI355X (TP4), or a full node of 8x H100/H200 (TP8, FP8 path). Weights come from HF or ModelScope (public, not gated); three size calibers coexist: community-count 252.4GB over 48 shards plus a 2.3GB DSpark head, and the vLLM recipe listing NVFP4 at 285GB, MXFP4 at 293GB, FP8 at 533GB; there is no official quantized repo. vLLM needs 0.33.0 or newer (absent from PyPI on release day, so use the vllm/vllm-openai:minimax-m31-flash Docker image or nightly); three official commands transcribed verbatim - H100/H200 TP8, GB200 TP4, MI355X TP4 - all forcing --block-size 128 and --disable-hybrid-kv-cache-manager (omit it and you get No common block size for 16); 1M context opens via --max-model-len (the Hopper sample caps at 262144). SGLang is not merged to main yet (Blackwell needs the MSA kernel at a pinned commit plus nvcc 13.4 minimum - cu130 does not count). The memory ledger: BF16 at roughly 856GB is an inference, not an official figure; 23B active lowers compute, not the VRAM floor - all 428B experts must stay resident, which is exactly why consumer cards are out; total KV cache for 1M context is unpublished. Domestic compute rides FlagOS Day-0 across nine chips (Huawei Ascend included, via SGLang-plugin-FL), numbers flagged as FlagOS official. Thirteen official error notes collected with fixes: HugeTLB 560GiB, B200 OOM, parser spelling, and more. License: MiniMax Community License, commercial attribution plus the 20-million-dollar threshold. One line of reality: 428B weights are out - budget 8 H100s.

Oct 24, 20269 min read
Field SOP

Nemotron 3.5 Bolt Local Deployment: 74B on a 24GB Card

NVIDIA released Nemotron 3.5 Bolt 74B-A9B 24GB on October 15, 2026: a compression of the 120B Super VL via Star Elastic budget-conditioned architecture search (expert top-K down from 22 to 9, distilled recovery training over 120B tokens), on a hybrid Mamba-2 and Transformer architecture. The quantization plan is the story - the expert layers that dominate the weights drop to IQ2_XXS at 2.0625 bits per element (about 19GB), Mamba linear layers use NVFP4, and lm_head, embeddings, and attention stay at Q8_0, landing the full model at 22-24GB with accuracy recovered through quantization-aware distillation from the compression stage onward. Four deployment routes, with commands: Ollama (supported since 0.40.5, ollama run nemotron-3.5-bolt, a 25GB download, verify 100 percent GPU via ollama ps); Unsloth (UD-IQ2_XXS about 22GB, UD-IQ1_M about 20.3GB, ctx from a conservative 4096); llama.cpp official recipes (builds after October 15 to recognize nemotron_h_moe; the 28GB recipe runs 65K context with 8-bit KV and 6 draft tokens, the 32GB recipe reaches 262K; llama-server defaults to port 9931 since b11521); and vLLM (Blackwell SM120 with the LiLiCorr drafter for multi-user serving). Two context starting points coexist: 16K-32K for bare weights, 4K for Unsloth whose default drafter eats another 1-2GB. Eight troubleshooting entries cover OOM context cuts, layers spilling to system RAM, the missing --mmproj flag, and the shared 16384 max_tokens budget. OpenMDW-1.1 grants free unrestricted commercial use, leaves outputs unencumbered, requires notices only on redistribution, and carries a patent-retaliation clause. Vendor-reported: GPQA Diamond 86.4, Terminal-Bench 2.1 at 51.0, PinchBench first in class (83.99 TPS on RTX Spark; no official consumer-card figure). The 4GB Bolt E4B followed on October 23.

Oct 23, 20268 min read
Field SOP

Xing4.0-29B-Intent Local Deploy: 4B Active, Which Command?

Getting Xing4.0-29B-Intent running hinges on a detail that trips most people up: the official deployment instructions do not live in the intent repository but in the base model repository. The intent README only says to replace the model path with the Xing4.0-29B-Intent weights and set --served-model-name to Xing4.0-29B-Intent, so the full vLLM and SGLang launch commands must be taken from the Xing4.0-29B-A4B base repo. Several flags are hard requirements: --trust-remote-code is mandatory because model_type is the in-house xing4_0 architecture, neither llama nor qwen; --tensor-parallel-size 2 implies at least two cards; --max-model-len 262144 matches the 256K context; --reasoning-parser xing4_0 and --tool-call-parser xing4_0 supply the matching parsers; --speculative-config uses the mtp method; and --gpu-memory-utilization 0.90 with --max-num-seqs 4 is the official example ratio. The weights ship as 41 safetensors shards totaling 62.43 GB, and the only official quantizations are FP8 (33.17 GB, e4m3) and GGUF (a single IQ4_NL file at 17.75 GB) - there is no AWQ, GPTQ, or INT8 safetensors. Minimum VRAM is not published at all; the official line is to configure GPU memory, parallelism, and context length for your environment. What the base repo does spell out: bfloat16 is required because the mHC path errors out on FP16 or quantized weights, --pipeline-parallel-size greater than 1 is not yet supported, the CUDA mHC path needs tilelang installed, and the host needs Docker 24.0 or newer with driver 535 or newer. The Ascend route explicitly wants 910B2 NPUs with at least two cards, with three official quay.io images (none of which bundle the weights). Consumer and CPU paths appear only in the base llama.cpp docs: int4 weights quantized with IQ4_NL come to about 19 GB and fit on a single consumer GPU, with an RTX 3090 24 GB as the example. The SDK is just an httpx HTTP client and is not on PyPI, and structured output comes in two layers - the model's native category plus args array, and SDK-guided JSON Schema constraints through vLLM response_format. The license is Apache-2.0, yet the weight side has no standalone LICENSE file, the repository LICENSE is an unfilled placeholder template, and the original terms of the 61 upstream datasets still need checking.

Oct 22, 20269 min read