sglang-diffusion-modelopt-quant

Quantize diffusion transformers with NVIDIA ModelOpt to generate FP8 or NVFP4 checkpoints for SGLang Diffusion.

Updated Jun 29, 2026
One-click install
npx skills add https://github.com/hey-kong/sglang --skill sglang-diffusion-modelopt-quant-hey-kong
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: sglang-diffusion-modelopt-quant
Source: https://github.com/hey-kong/sglang/tree/main/python/sglang/multimodal_gen/.claude/skills/sglang-diffusion-modelopt-quant
Command: npx skills add https://github.com/hey-kong/sglang --skill sglang-diffusion-modelopt-quant-hey-kong

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

NVIDIA ModelOpt FP8/NVFP4 quantization is complex and brittle for diffusion DiT models; this skill provides a structured, end-to-end workflow to produce loadable, verifiable and benchmarked quantized checkpoints for SGLang Diffusion.

Core Features & Use Cases

  • Quantize diffusion transformers using ModelOpt FP8 or NVFP4 exports and adapt checkpoints for SGLang Diffusion.
  • Support single-transformer and multi-transformer pipelines with per-component overrides and validation tooling.
  • Validate accuracy and benchmark performance to ensure parity or gains across quantized paths.

Quick Start

Quantize a diffusion DiT with NVIDIA ModelOpt and load the resulting SGLang Diffusion checkpoint for testing.

Frequently Asked Questions about sglang-diffusion-modelopt-quant

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I quantize diffusion transformers using ModelOpt for SGLang?

To quantize diffusion transformers using ModelOpt for SGLang, apply this skill to run official ModelOpt scripts, producing FP8 or NVFP4 checkpoints. You then adapt and convert these checkpoints for direct loading into the SGLang Diffusion runtime.

Does ModelOpt FP8 quantization work with multi-transformer pipelines?

Yes, ModelOpt FP8 quantization works with multi-transformer pipelines. This skill supports both single-transformer and multi-transformer workflows, allowing per-component overrides and validation tooling to ensure proper calibration data alignment across all components.

Can I use NVFP4 checkpoints in SGLang Diffusion?

Yes, you can use NVFP4 checkpoints in SGLang Diffusion. This skill bridges NVIDIA ModelOpt NVFP4 exports to the SGLang runtime, generating loadable quantized models while ensuring proper calibration data alignment and layout adaptation.

What is needed to verify accuracy after FP8 quantization of DiT models?

To verify accuracy after FP8 quantization of DiT models, this skill provides a structured workflow to validate quality and benchmark speed. It ensures parity or gains across quantized paths by comparing outputs against the base transformer layout.

Why does my ModelOpt FP8 quantization fail to load in SGLang?

ModelOpt FP8 quantization may fail to load in SGLang if calibration data is misaligned or the base transformer layout is incorrect. This skill ensures per-component overrides and proper checkpoint conversion to generate loadable SGLang runtime models.

Do I need official ModelOpt scripts for NVFP4 quantization?

Yes, you need official ModelOpt scripts for NVFP4 quantization. This skill requires these official scripts, a base transformer layout, and SGLang runtime utilities to generate, convert, and load the quantized models successfully.