Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
182ea3a
Add LingBot-Video (Dense-1.3B) support with attention-only LoRA SFT
NancyFyong Jul 25, 2026
67bcd02
Add docs, prompt rewriting, LoRA validation, and low-VRAM example for…
NancyFyong Jul 26, 2026
55c8357
Add LingBot-Video MoE-30B-A3B support
NancyFyong Jul 27, 2026
df7ea8e
Address PR #1539 review: unify scheduler, restore VAE, split rewriter
NancyFyong Jul 27, 2026
5fbf50a
Fix low-VRAM fp32/bf16 dtype mismatch in LingBot-Video DiT
NancyFyong Jul 27, 2026
a9e7cc2
Fold normalize_caption into lingbot_video pipeline module
NancyFyong Jul 27, 2026
c62ea4f
Add normalize_caption to lingbot_video and fix importers
NancyFyong Jul 27, 2026
e83d7d6
Trim verbose comments in LingBot-Video code
NancyFyong Jul 27, 2026
038bad0
Merge lingbot_sft into lingbot_moe: apply PR #1539 review fixes to th…
NancyFyong Jul 27, 2026
3333443
Fix dtype mismatch feeding the fp32-pinned time_embedder
NancyFyong Jul 27, 2026
4ecc892
Add t2v_example_4 structured caption
NancyFyong Jul 27, 2026
0a107bb
Merge lingbot_sft into lingbot_moe (dtype fix + sample 4 prompt)
NancyFyong Jul 27, 2026
ea73e8b
Add TI2V (image-to-video) support to LingBot-Video pipeline
NancyFyong Jul 27, 2026
670ec22
Add text-to-image (t2i) support and example to LingBot-Video
NancyFyong Jul 27, 2026
8d8b7c7
Add ti2v/t2i low-VRAM inference + ti2v LoRA training examples
NancyFyong Jul 28, 2026
b2492dd
update vae&inner_func
mi804 Jul 27, 2026
a10c026
tmp commit for code refactor
mi804 Jul 27, 2026
94e8baa
low vram patch&refactor scripts
mi804 Jul 28, 2026
7caae83
remove fp32 cast to keep compatibility with low-vram-inference
mi804 Jul 28, 2026
5f604e2
add support for full train
mi804 Jul 28, 2026
cae44a0
style refactor
mi804 Jul 28, 2026
531ba56
pop changes for ti2v pipeline
mi804 Jul 28, 2026
4c9ee93
Align TI2V / T2I examples, LoRA + full training, docs and README with…
NancyFyong Jul 28, 2026
5fa49f5
fix: manage Qwen3-VL vision tower in LingBotVideoTextEncoder VRAM map
NancyFyong Jul 28, 2026
56334bf
style: group input_image under image-to-video in pipeline __call__
NancyFyong Jul 28, 2026
7d0852e
refactor: move TI2V helpers into the units that use them
NancyFyong Jul 28, 2026
91fcb94
Merge lingbot_sft into lingbot_moe: integrate TI2V/T2I + full trainin…
NancyFyong Jul 28, 2026
5bc41d2
style: strip comments and align MoE-30B-A3B integration with repo con…
NancyFyong Jul 29, 2026
eed0d72
style: align MoE examples with the Dense inference examples
NancyFyong Jul 29, 2026
b4aec8c
feat: add TI2V / T2I MoE-30B-A3B examples and load captions from the …
NancyFyong Jul 29, 2026
9476867
fix: restore every DiT parameter under low-VRAM offload for the MoE map
NancyFyong Jul 29, 2026
ce0e732
Merge upstream main (LingBot-Video Dense-1.3B, #1539) into the MoE br…
NancyFyong Jul 30, 2026
823fae0
fix: point the MoE examples at the published Dense example-dataset di…
NancyFyong Jul 30, 2026
7bd0ad8
refactor: drop the resolve_bulk_dtype helper from the MoE DiT
NancyFyong Jul 30, 2026
44c506b
fix: cast the MoE router and expert weights inside the model under of…
NancyFyong Jul 30, 2026
c2e4975
feat: add LoRA and full-parameter training examples for MoE-30B-A3B
NancyFyong Jul 30, 2026
3cfbbf1
style: align the MoE accelerate config with the 14B training config
NancyFyong Jul 30, 2026
e0ce129
feat: support the LingBot-Video MoE refiner for two-stage high-resolu…
NancyFyong Jul 30, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ We believe that a well-developed open-source code framework can lower the thresh

> Currently, the development personnel of this project are limited, with most of the work handled by [Artiprocher](https://github.com/Artiprocher) and [mi804](https://github.com/mi804). Therefore, the progress of new feature development will be relatively slow, and the speed of responding to and resolving issues is limited. We apologize for this and ask developers to understand.

- **July 28, 2026** LingBot-Video open-sourced, welcome a new member to the video model family! Support includes text-to-video, image-to-video and text-to-image generation, low VRAM inference, and LoRA / full training capabilities. For details, please refer to the [documentation](/docs/en/Model_Details/LingBot-Video.md) and [example code](/examples/lingbot_video/). Huge thanks to [NancyFyong](https://github.com/NancyFyong) for contributing the integration of this model!
- **July 28, 2026** LingBot-Video open-sourced, welcome a new member to the video model family! Support includes text-to-video, image-to-video and text-to-image generation, low VRAM inference, and LoRA / full training capabilities. The MoE-30B-A3B variant serves the same three tasks with 30B total parameters and ~3B active per token. For details, please refer to the [documentation](/docs/en/Model_Details/LingBot-Video.md) and [example code](/examples/lingbot_video/). Huge thanks to [NancyFyong](https://github.com/NancyFyong) for contributing the integration of this model!

- **July 21, 2026** We have open-sourced [DiffSynth-Studio Model Integration Skills](https://www.modelscope.cn/collections/DiffSynth-Studio/DiffSynth-Studio-Model-Integration-Skills). This is a composable collection of Agent Skills that automates the entire workflow of integrating external diffusion models into DiffSynth-Studio, significantly improving the standardization and efficiency of model integration. Get started with the [example](https://www.modelscope.cn/skills/DiffSynth-Studio/diffsynth-integrator/file/view/master/example.md?status=1)!

Expand Down Expand Up @@ -1518,6 +1518,11 @@ Example code for LingBot-Video is available at: [/examples/lingbot_video/](/exam
|[Robbyant/lingbot-video-dense-1.3b: T2V](https://modelscope.cn/models/Robbyant/lingbot-video-dense-1.3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-dense-1.3b_t2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-dense-1.3b_t2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-dense-1.3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-dense-1.3b_t2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-dense-1.3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-dense-1.3b_t2v.py)|
|[Robbyant/lingbot-video-dense-1.3b: TI2V](https://modelscope.cn/models/Robbyant/lingbot-video-dense-1.3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-dense-1.3b_ti2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-dense-1.3b_ti2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-dense-1.3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-dense-1.3b_ti2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-dense-1.3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-dense-1.3b_ti2v.py)|
|[Robbyant/lingbot-video-dense-1.3b: T2I](https://modelscope.cn/models/Robbyant/lingbot-video-dense-1.3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-dense-1.3b_t2i.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-dense-1.3b_t2i.py)|-|-|-|-|
|[Robbyant/lingbot-video-moe-30b-a3b: T2V](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_t2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_t2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-moe-30b-a3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-moe-30b-a3b_t2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-moe-30b-a3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-moe-30b-a3b_t2v.py)|
|[Robbyant/lingbot-video-moe-30b-a3b: TI2V](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_ti2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_ti2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-moe-30b-a3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-moe-30b-a3b_ti2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-moe-30b-a3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-moe-30b-a3b_ti2v.py)|
|[Robbyant/lingbot-video-moe-30b-a3b: T2I](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_t2i.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_t2i.py)|-|-|-|-|
|[Robbyant/lingbot-video-moe-30b-a3b: T2V + Refinement](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_t2v_refiner.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_t2v_refiner.py)|-|-|-|-|
|[Robbyant/lingbot-video-moe-30b-a3b: TI2V + Refinement](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_ti2v_refiner.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_ti2v_refiner.py)|-|-|-|-|

</details>

Expand Down
7 changes: 6 additions & 1 deletion README_zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ DiffSynth 目前包括两个开源项目:

> 目前本项目的开发人员有限,大部分工作由 [Artiprocher](https://github.com/Artiprocher) 和 [mi804](https://github.com/mi804) 负责,因此新功能的开发进展会比较缓慢,issue 的回复和解决速度有限,我们对此感到非常抱歉,请各位开发者理解。

- **2026年7月28日** LingBot-Video 开源,欢迎加入视频生成模型家族!支持文生视频、图生视频、文生图推理、低显存推理以及 LoRA / 全量训练能力。详情请参考[文档](/docs/zh/Model_Details/LingBot-Video.md)和[示例代码](/examples/lingbot_video/)。特别感谢 [NancyFyong](https://github.com/NancyFyong) 贡献了本模型的接入代码!
- **2026年7月28日** LingBot-Video 开源,欢迎加入视频生成模型家族!支持文生视频、图生视频、文生图推理、低显存推理以及 LoRA / 全量训练能力。MoE-30B-A3B 总参数量 30B、每个 token 激活约 3B,同样支持这三种任务。详情请参考[文档](/docs/zh/Model_Details/LingBot-Video.md)和[示例代码](/examples/lingbot_video/)。特别感谢 [NancyFyong](https://github.com/NancyFyong) 贡献了本模型的接入代码!

- **2026年7月21日** 我们开源了 [DiffSynth-Studio Model Integration Skills](https://www.modelscope.cn/collections/DiffSynth-Studio/DiffSynth-Studio-Model-Integration-Skills)。这是一套可组合的 Agent Skill 合集,将外部扩散模型接入 DiffSynth-Studio 的全流程自动化,大幅提升模型接入标准化程度与效率。从[使用示例](https://www.modelscope.cn/skills/DiffSynth-Studio/diffsynth-integrator/file/view/master/example.md?status=1)开始体验吧!

Expand Down Expand Up @@ -1518,6 +1518,11 @@ LingBot-Video 的示例代码位于:[/examples/lingbot_video/](/examples/lingb
|[Robbyant/lingbot-video-dense-1.3b: T2V](https://modelscope.cn/models/Robbyant/lingbot-video-dense-1.3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-dense-1.3b_t2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-dense-1.3b_t2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-dense-1.3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-dense-1.3b_t2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-dense-1.3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-dense-1.3b_t2v.py)|
|[Robbyant/lingbot-video-dense-1.3b: TI2V](https://modelscope.cn/models/Robbyant/lingbot-video-dense-1.3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-dense-1.3b_ti2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-dense-1.3b_ti2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-dense-1.3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-dense-1.3b_ti2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-dense-1.3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-dense-1.3b_ti2v.py)|
|[Robbyant/lingbot-video-dense-1.3b: T2I](https://modelscope.cn/models/Robbyant/lingbot-video-dense-1.3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-dense-1.3b_t2i.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-dense-1.3b_t2i.py)|-|-|-|-|
|[Robbyant/lingbot-video-moe-30b-a3b: T2V](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_t2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_t2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-moe-30b-a3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-moe-30b-a3b_t2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-moe-30b-a3b_t2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-moe-30b-a3b_t2v.py)|
|[Robbyant/lingbot-video-moe-30b-a3b: TI2V](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_ti2v.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_ti2v.py)|[code](/examples/lingbot_video/model_training/full/lingbot-video-moe-30b-a3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_full/lingbot-video-moe-30b-a3b_ti2v.py)|[code](/examples/lingbot_video/model_training/lora/lingbot-video-moe-30b-a3b_ti2v.sh)|[code](/examples/lingbot_video/model_training/validate_lora/lingbot-video-moe-30b-a3b_ti2v.py)|
|[Robbyant/lingbot-video-moe-30b-a3b: T2I](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_t2i.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_t2i.py)|-|-|-|-|
|[Robbyant/lingbot-video-moe-30b-a3b: T2V + Refinement](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_t2v_refiner.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_t2v_refiner.py)|-|-|-|-|
|[Robbyant/lingbot-video-moe-30b-a3b: TI2V + Refinement](https://modelscope.cn/models/Robbyant/lingbot-video-moe-30b-a3b)|[code](/examples/lingbot_video/model_inference/lingbot-video-moe-30b-a3b_ti2v_refiner.py)|[code](/examples/lingbot_video/model_inference_low_vram/lingbot-video-moe-30b-a3b_ti2v_refiner.py)|-|-|-|-|

</details>

Expand Down
8 changes: 8 additions & 0 deletions diffsynth/configs/model_configs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1330,6 +1330,14 @@
"model_class": "diffsynth.models.lingbot_video_dit.LingBotVideoDiT",
"state_dict_converter": "diffsynth.utils.state_dict_converters.lingbot_video_dit.LingBotVideoDiTStateDictConverter",
},
{
# Example: ModelConfig(model_id="Robbyant/lingbot-video-moe-30b-a3b", origin_file_pattern="transformer/diffusion_pytorch_model*.safetensors")
"model_hash": "65b83aa625cd362ff5ff3409fb367a6f",
"model_name": "lingbot_video_dit",
"model_class": "diffsynth.models.lingbot_video_dit.LingBotVideoDiT",
"state_dict_converter": "diffsynth.utils.state_dict_converters.lingbot_video_dit.LingBotVideoDiTStateDictConverter",
"extra_kwargs": {'depth': 48, 'axes_lens': (4096, 512, 512), 'num_experts': 128, 'moe_intermediate_size': 768, 'n_group': 4, 'topk_group': 2, 'n_shared_experts': 1, 'routed_scaling_factor': 2.5},
},
]

MODEL_CONFIGS = (
Expand Down
4 changes: 3 additions & 1 deletion diffsynth/configs/vram_management_module_maps.py
Original file line number Diff line number Diff line change
Expand Up @@ -412,7 +412,9 @@
"transformers.models.qwen3_vl.modeling_qwen3_vl.Qwen3VLVisionRotaryEmbedding": "diffsynth.core.vram.layers.AutoWrappedModule",
},
"diffsynth.models.lingbot_video_dit.LingBotVideoDiT": {
"diffsynth.models.lingbot_video_dit.LingBotVideoBlock": "diffsynth.core.vram.layers.AutoWrappedModule",
"diffsynth.models.lingbot_video_dit.LingBotVideoBlock": "diffsynth.core.vram.layers.AutoWrappedNonRecurseModule",
"diffsynth.models.lingbot_video_dit.LingBotVideoRouter": "diffsynth.core.vram.layers.AutoWrappedNonRecurseModule",
"diffsynth.models.lingbot_video_dit.LingBotVideoGroupedExperts": "diffsynth.core.vram.layers.AutoWrappedNonRecurseModule",
"diffsynth.models.lingbot_video_dit.LingBotVideoRMSNorm": "diffsynth.core.vram.layers.AutoWrappedModule",
"torch.nn.Linear": "diffsynth.core.vram.layers.AutoWrappedLinear",
},
Expand Down
25 changes: 24 additions & 1 deletion diffsynth/diffusion/flow_match.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

class FlowMatchScheduler():

def __init__(self, template: Literal["FLUX.1", "Wan", "Qwen-Image", "FLUX.2", "Z-Image", "LTX-2", "Qwen-Image-Lightning", "ERNIE-Image", "ACE-Step", "Ideogram4", "Krea-2", "Boogu"] = "FLUX.1"):
def __init__(self, template: Literal["FLUX.1", "Wan", "Qwen-Image", "FLUX.2", "Z-Image", "LTX-2", "Qwen-Image-Lightning", "ERNIE-Image", "ACE-Step", "Ideogram4", "Krea-2", "Boogu", "LingBot-Video"] = "FLUX.1"):
self.set_timesteps_fn = {
"FLUX.1": FlowMatchScheduler.set_timesteps_flux,
"Wan": FlowMatchScheduler.set_timesteps_wan,
Expand All @@ -20,6 +20,7 @@ def __init__(self, template: Literal["FLUX.1", "Wan", "Qwen-Image", "FLUX.2", "Z
"Ideogram4": FlowMatchScheduler.set_timesteps_ideogram4,
"Krea-2": FlowMatchScheduler.set_timesteps_krea2,
"Boogu": FlowMatchScheduler.set_timesteps_boogu,
"LingBot-Video": FlowMatchScheduler.set_timesteps_lingbot_video,
}.get(template, FlowMatchScheduler.set_timesteps_flux)
self.num_train_timesteps = 1000

Expand Down Expand Up @@ -79,6 +80,28 @@ def set_timesteps_qwen_image(num_inference_steps=100, denoising_strength=1.0, ex
timesteps = sigmas * num_train_timesteps
return sigmas, timesteps

@staticmethod
def set_timesteps_lingbot_video(num_inference_steps=100, denoising_strength=1.0, shift=None, t_thresh=None, sigma_tail_steps=0):
sigma_min = 0.0
sigma_max = 1.0
shift = 5 if shift is None else shift
num_train_timesteps = 1000
sigma_start = sigma_min + (sigma_max - sigma_min) * denoising_strength
sigmas = torch.linspace(sigma_start, sigma_min, num_inference_steps + 1)[:-1]
sigmas = shift * sigmas / (1 + (shift - 1) * sigmas)
if t_thresh is not None:
# Refinement schedule: keep the sub-threshold part of the shifted grid, pin the first
# sigma exactly at t_thresh, then append extra low-noise steps that end at sigma_min.
sigmas = sigmas[sigmas <= t_thresh + 1e-6]
if sigmas.numel() == 0 or abs(float(sigmas[0]) - t_thresh) > 1e-6:
sigmas = torch.cat([torch.tensor([t_thresh], dtype=sigmas.dtype), sigmas])
if sigma_tail_steps > 0:
tail_start = float(sigmas[-1])
tail = torch.linspace(tail_start, min(sigma_min, tail_start), sigma_tail_steps + 2)[1:-1]
sigmas = torch.cat([sigmas, tail.to(dtype=sigmas.dtype)])
timesteps = sigmas * num_train_timesteps
return sigmas, timesteps

@staticmethod
def set_timesteps_qwen_image_lightning(num_inference_steps=100, denoising_strength=1.0, exponential_shift_mu=None, dynamic_shift_len=None):
sigma_min = 0.0
Expand Down
Loading