SageMaker Serving Image Selection
huggingface/skills
Chooses the right serving container and current image URI for deploying a Hugging Face model to a SageMaker endpoint, preferring Hugging Face images over generic ones.
Add a new diffusion model (text-to-image, text-to-video, image-to-video, text-to-audio, image editing) to vLLM-Omni, including native non-Diffusers ports, reference-parity validation, Cache-DiT…
$ npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a claude-codeProject install by default; add -g for ~/.claude/skills/.
$ gh skill install vllm-project/vllm-omni add-diffusion-model --agent claude-codeProject scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).
$ git clone --depth 1 https://github.com/vllm-project/vllm-omni.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/add-diffusion-model .claude/skills/add-diffusion-model && rm -rf skills-srcUse ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.
Claude Code skills documentation · loads skills from .claude/skills/
Install the "add-diffusion-model" agent skill from https://github.com/vllm-project/vllm-omni/tree/main/.claude/skills/add-diffusion-model into .claude/skills/add-diffusion-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-diffusion-model", then confirm the skill loads.Claude Code copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$skill-installer install https://github.com/vllm-project/vllm-omni/tree/main/.claude/skills/add-diffusion-modelType this inside Codex. $skill-installer <name> installs a curated skill from openai/skills. The installer writes to $CODEX_HOME/skills (default ~/.codex/skills). Restart Codex if the skill does not show up.
$ npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a codexProject install goes to .agents/skills/; add -g for ~/.codex/skills/.
$ gh skill install vllm-project/vllm-omni add-diffusion-model --agent codexProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/vllm-project/vllm-omni.git skills-src && mkdir -p .agents/skills && cp -r skills-src/.claude/skills/add-diffusion-model .agents/skills/add-diffusion-model && rm -rf skills-srcUse ~/.agents/skills/ instead of .agents/skills for a personal install.
Codex skills documentation · loads skills from .agents/skills/
Install the "add-diffusion-model" agent skill from https://github.com/vllm-project/vllm-omni/tree/main/.claude/skills/add-diffusion-model into .agents/skills/add-diffusion-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-diffusion-model", then confirm the skill loads.Codex copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a cursorProject install goes to .agents/skills/; add -g for ~/.cursor/skills/.
$ gh skill install vllm-project/vllm-omni add-diffusion-model --agent cursorProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/vllm-project/vllm-omni.git skills-src && mkdir -p .cursor/skills && cp -r skills-src/.claude/skills/add-diffusion-model .cursor/skills/add-diffusion-model && rm -rf skills-srcUse ~/.cursor/skills/ instead of .cursor/skills for a personal install.
Cursor skills documentation · loads skills from .cursor/skills/, .agents/skills/, .claude/skills/, .codex/skills/
Install the "add-diffusion-model" agent skill from https://github.com/vllm-project/vllm-omni/tree/main/.claude/skills/add-diffusion-model into .cursor/skills/add-diffusion-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-diffusion-model", then confirm the skill loads.Cursor copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gemini skills install https://github.com/vllm-project/vllm-omni.git --path .claude/skills/add-diffusion-model--scope user (default) or --scope workspace; --path is the subfolder of the repo that holds the skill; --consent skips the security confirmation prompt.
$ npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a gemini-cliProject install goes to .agents/skills/; add -g for ~/.gemini/skills/.
$ gh skill install vllm-project/vllm-omni add-diffusion-model --agent gemini-cliProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/vllm-project/vllm-omni.git skills-src && mkdir -p .gemini/skills && cp -r skills-src/.claude/skills/add-diffusion-model .gemini/skills/add-diffusion-model && rm -rf skills-srcUse ~/.gemini/skills/ instead of .gemini/skills for a personal install, then run /skills reload.
Gemini CLI skills documentation · loads skills from .gemini/skills/, .agents/skills/
Install the "add-diffusion-model" agent skill from https://github.com/vllm-project/vllm-omni/tree/main/.claude/skills/add-diffusion-model into .gemini/skills/add-diffusion-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-diffusion-model", then confirm the skill loads.Gemini CLI copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ gh skill install vllm-project/vllm-omni add-diffusion-modelInstalls for Copilot at project scope by default; add --scope user for a personal install. Preview a skill first with gh skill preview. Needs GitHub CLI 2.90.0 or later (public preview).
$ npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a github-copilotProject install goes to .agents/skills/; add -g for ~/.copilot/skills/.
$ git clone --depth 1 https://github.com/vllm-project/vllm-omni.git skills-src && mkdir -p .github/skills && cp -r skills-src/.claude/skills/add-diffusion-model .github/skills/add-diffusion-model && rm -rf skills-srcUse ~/.copilot/skills/ instead of .github/skills for a personal install. Commit .github/skills so cloud agent and code review can use it.
GitHub Copilot skills documentation · loads skills from .github/skills/, .claude/skills/, .agents/skills/
Install the "add-diffusion-model" agent skill from https://github.com/vllm-project/vllm-omni/tree/main/.claude/skills/add-diffusion-model into .github/skills/add-diffusion-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-diffusion-model", then confirm the skill loads.GitHub Copilot copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
$ npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a opencodeOpenCode documents no install command of its own. Project install goes to .agents/skills/; add -g for ~/.config/opencode/skills/.
$ gh skill install vllm-project/vllm-omni add-diffusion-model --agent opencodeProject scope by default (.agents/skills/); add --scope user for a personal install.
$ git clone --depth 1 https://github.com/vllm-project/vllm-omni.git skills-src && mkdir -p .opencode/skills && cp -r skills-src/.claude/skills/add-diffusion-model .opencode/skills/add-diffusion-model && rm -rf skills-srcUse ~/.config/opencode/skills/ instead of .opencode/skills for a personal install.
OpenCode skills documentation · loads skills from .opencode/skills/, .claude/skills/, .agents/skills/
Install the "add-diffusion-model" agent skill from https://github.com/vllm-project/vllm-omni/tree/main/.claude/skills/add-diffusion-model into .opencode/skills/add-diffusion-model/ in this project. Copy the whole folder (SKILL.md and every file beside it), keep the folder name "add-diffusion-model", then confirm the skill loads.OpenCode copies the folder itself, the same result as the manual copy. Check what it changed before you commit it.
add-diffusion-modelAdd a new diffusion model (text-to-image, text-to-video, image-to-video, text-to-audio, image editing) to vLLM-Omni, including native non-Diffusers ports, reference-parity validation, Cache-DiT…
Add Diffusion Model is an agent skill from vllm-project/vllm-omni. Add a new diffusion model (text-to-image, text-to-video, image-to-video, text-to-audio, image editing) to vLLM-Omni, including native non-Diffusers ports, reference-parity validation, Cache-DiT, offload, and parallelism support (TP, SP/USP, CFG-Parallel, HSDP). Use when integrating or reviewing a new diffusion model, porting a Diffusers pipeline or custom model repository, creating a DiT adapter, reusing shared examples, or qualifying multi-GPU and memory optimizations.
Its SKILL.md is about 7k tokens, which your agent loads only when the skill is triggered. The skill folder holds 7 other files, including reference files (for example `references/cache-dit-patterns.md`, `references/custom-model-patterns.md` and `references/native-model-integration-checklist.md`).
It sits in AI & LLM Engineering, covering Diffusion and image models, AI video generation and LLM inference and serving. It works with vLLM. The repository describes itself as: A framework for efficient model inference with omni-modality models. The licence is Apache-2.0.
Read from SKILL.md and the folder at commit c548a11. It shows what the files ask for, not the result of running them.
Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.
From allowed-tools in the SKILL.md frontmatter.
No scripts in the folder and no shell commands in SKILL.md (its code samples are python and json).
From the folder's file list and the shell code blocks in SKILL.md.
No URLs in SKILL.md.
From URLs in SKILL.md, links to its own repository left out.
Names no API keys, tokens, secrets or passwords.
From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.
Add Diffusion Model loads about 7k tokens when it runs, and up to ~22k if it reads all its reference files. Until then it costs about 124 tokens; SKILL.md has 2,468 words of instructions outside code blocks.
Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.
The automated check found no risky patterns in SKILL.md.
Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.
The full file from vllm-project/vllm-omni at commit c548a11, republished under its Apache-2.0 licence (© vllm-project). 2,468 words, ~6,999 tokens.
.claude/skills/add-diffusion-model/SKILL.md (or your agent's skills folder). This skill also uses 6 other files; get the full folder from GitHub.This skill guides you through adding a new diffusion model to vLLM-Omni. The model may come from HuggingFace Diffusers (structured pipeline) or from a private/custom repo. The workflow differs significantly depending on the source.
Before starting, determine:
Check the model's HF repo for model_index.json. This determines your path:
| Scenario | How to identify | Migration path |
|---|---|---|
| Already supported | _class_name in model_index.json matches a key in _DIFFUSION_MODELS in registry.py | Skip implementation, then validate model-specific examples, tests, and docs as needed |
| Diffusers-based | Has standard model_index.json with _diffusers_version, subfolders for transformer/, vae/, etc. | Follow Path A below |
| Native non-Diffusers model | No Diffusers index, non-standard checkpoint hierarchy, or custom architecture in a separate repo | Follow Path B below; port the runtime natively unless an external adapter was explicitly requested |
| Hybrid | Has some diffusers components (VAE) but custom transformer/fusion | Mix of Path A and Path B |
Before coding, write a short integration contract covering runtime ownership, checkpoint discovery, reference revision, I/O geometry, attention semantics, CFG behavior, auxiliary components, target hardware, and the default deployment. For Path B, hybrid models, or any optimization work, read references/native-model-integration-checklist.md and use its phase gates.
For models with a standard diffusers layout. See references/transformer-adaptation.md for detailed code patterns.
model_index.jsonIdentify components: transformer, scheduler, vae, text_encoder, tokenizer.
vllm_omni/diffusion/models/your_model_name/
├── __init__.py
├── pipeline_your_model.py
└── your_model_transformer.pyModelMixin, ConfigMixin, AttentionModuleMixin).vllm_omni.diffusion.attention.layer.Attention (QKV shape: [B, seq, heads, head_dim]).od_config: OmniDiffusionConfig | None = None to __init__.load_weights() method mapping diffusers weight names to vllm-omni names._repeated_blocks and _layerwise_offload_blocks_attrs (see references/transformer-adaptation.md for examples).Inherit from nn.Module. The key contract:
class YourPipeline(nn.Module):
def __init__(self, *, od_config: OmniDiffusionConfig, prefix: str = ""):
# Load VAE, text encoder, tokenizer via from_pretrained()
# Instantiate transformer (weights loaded later via weights_sources)
self.weights_sources = [
DiffusersPipelineLoader.ComponentSource(
model_or_path=od_config.model, subfolder="transformer",
prefix="transformer.", fall_back_to_pt=True)]
def forward(self, req: OmniDiffusionRequest) -> DiffusionOutput:
# Encode prompt → prepare latents → denoise loop → VAE decode
return DiffusionOutput(output=output)
def load_weights(self, weights):
return AutoWeightsLoader(self).load_weights(weights)Add post/pre-process functions in the same pipeline file. Register them in registry.py.
For pipelines with a standard denoising loop, prefer the existing progress bar pattern instead of hand-rolled logging.
from vllm_omni.diffusion.models.progress_bar import ProgressBarMixin
class YourPipeline(nn.Module, ProgressBarMixin):
def forward(self, req: OmniDiffusionRequest) -> DiffusionOutput:
# ... prepare timesteps / latents ...
with self.progress_bar(total=len(timesteps)) as progress_bar:
for i, t in enumerate(timesteps):
# predict noise / scheduler step
latents = ...
progress_bar.update()
return DiffusionOutput(output=output)For custom loop structures, follow vllm_omni/diffusion/models/progress_bar.py and existing pipelines using ProgressBarMixin.
For models without a Diffusers pipeline—weights in custom formats and model code in another public or private repository. Treat that repository as a pinned correctness oracle. A request for native support means the vLLM-Omni runtime must not import the reference implementation; an external adapter is appropriate only when the requested scope explicitly permits that dependency. See references/custom-model-patterns.md for concrete integration patterns.
Study the original model's code to identify:
.pth, custom checkpoint structure)This is the key design decision for custom models. Follow these placement rules:
| Code type | Where to place | Example |
|---|---|---|
| Pipeline orchestration (init, forward, denoise loop) | vllm_omni/diffusion/models/<name>/pipeline_<name>.py | Always required |
| Custom transformer/backbone (ported and adapted to vllm-omni) | vllm_omni/diffusion/models/<name>/<name>_transformer.py or similar | wan2_2.py, fusion.py, bagel_transformer.py |
| Custom sub-models (VAE, fusion, autoencoder) | vllm_omni/diffusion/models/<name>/ as separate files | autoencoder.py, fusion.py |
| Reference-only code | Keep outside the runtime; use a pinned revision for golden outputs and architecture analysis | Reference inference script |
| Explicit external adapter dependency | External package, only when the requested scope and maintainer direction allow it | Compatibility adapter, not native support |
| Hardcoded model configs | Module-level dicts in pipeline file | VIDEO_CONFIG, AUDIO_CONFIG dicts |
| Download/setup script | examples/offline_inference/<name>/download_<name>.py | download_<name>.py |
Custom model_index.json | Generated by download script, placed at model root | Minimal: {"_class_name": "YourPipeline", ...} |
If the model's code lives in a separate git repo, first decide whether the requested deliverable is native support or an external adapter. Do not silently choose the adapter path.
Option 1: Port the code directly (default for native support)
Copy the essential model files into vllm_omni/diffusion/models/<name>/ and
adapt them to shared vLLM-Omni contracts. Keep checkpoint loading strict and
use the pinned reference only to generate parity evidence.
Option 2: Import with graceful fallback (adapter scope only)
try:
from external_model.utils import init_vae, load_checkpoint
except ImportError:
raise ImportError(
"Failed to import from dependency 'external_model'. "
"Please run the download script first."
)Use an external runtime dependency only when the user explicitly requested an adapter or a maintainer approved the exception. Document the dependency, pinned revision, installation path, and unsupported native features.
Custom models have two common patterns for weight loading:
Pattern 1: Bypass standard loader (eager custom init)
When the original model has complex custom init functions that load weights in __init__:
class CustomPipeline(nn.Module):
def __init__(self, *, od_config, prefix=""):
super().__init__()
model = od_config.model
# Load everything eagerly in __init__ using custom helpers
self.vae = custom_init_vae(model, device=self.device)
self.text_encoder = custom_init_text_encoder(model, device=self.device)
self.transformer = CustomFusionModel(CONFIG)
load_custom_checkpoint(
self.transformer,
checkpoint_path=os.path.join(model, "model.safetensors"),
)
# NO weights_sources defined — bypasses standard loader
def load_weights(self, weights):
pass # No-op — all weights loaded in __init__Pattern 2: Use standard loader with custom load_weights (BAGEL style)
When weights are in safetensors format but need name remapping:
from vllm.model_executor.model_loader.weight_utils import default_weight_loader
class CustomPipeline(nn.Module):
def __init__(self, *, od_config, prefix=""):
super().__init__()
# Instantiate model architecture without weights
self.bagel = BagelModel(config)
self.vae = AutoEncoder(ae_params)
# Point loader at the safetensors in the model root
self.weights_sources = [
DiffusersPipelineLoader.ComponentSource(
model_or_path=od_config.model,
subfolder=None, # weights at root, not in subfolder
prefix="",
fall_back_to_pt=False,
)
]
def load_weights(self, weights):
# Custom name remapping for non-diffusers weight names
params = dict(self.named_parameters())
loaded = set()
for name, tensor in weights:
# Remap original weight names to vllm-omni module names
name = self._remap_weight_name(name)
if name in params:
param = params[name]
weight_loader = getattr(param, "weight_loader", default_weight_loader)
weight_loader(param, tensor)
loaded.add(name)
return loadedmodel_index.jsonPrefer a model_index.json at the model root when vLLM-Omni owns an assembled
checkpoint directory. For custom models, this is minimal:
{
"_class_name": "YourModelPipeline",
"custom_key": "path/to/custom_weights.safetensors"
}The _class_name must match a key in _DIFFUSION_MODELS in registry.py.
Additional keys are model-specific (accessed via od_config.model_config).
If the released repository is immutable and has neither a root config.json
nor a Diffusers index, add it to a generic native-checkpoint signature resolver:
match the exact Hub ID or a distinctive set of local files and return the
pipeline class. Do not use model-name substrings or add parallel one-off
predicates in CLI, config, and serving consumers.
If the model's weights come from multiple HF repos, write a download script that:
model_index.json.pth file)Place at: examples/offline_inference/<name>/download_<name>.py
If the model accepts images, audio, or other multi-modal inputs, implement the protocol classes from vllm_omni/diffusion/models/interface.py:
from vllm_omni.diffusion.models.interface import SupportImageInput, SupportAudioInput
class MyPipeline(nn.Module, SupportImageInput, SupportAudioInput):
# Protocol markers — the engine uses these to enable proper input routing
passPreprocessing for custom models is typically done inside forward() rather than via registered pre-process functions, since the logic is often tightly coupled to the model.
Edit vllm_omni/diffusion/registry.py:
_DIFFUSION_MODELS = {
"YourModelPipeline": ("your_model_name", "pipeline_your_model", "YourModelPipeline"),
}
_DIFFUSION_POST_PROCESS_FUNCS = {
"YourModelPipeline": "get_your_model_post_process_func", # if applicable
}
_DIFFUSION_PRE_PROCESS_FUNCS = {
"YourModelPipeline": "get_your_model_pre_process_func", # if applicable
}The registry key is the _class_name from model_index.json. The tuple is (folder_name, module_file, class_name).
Create __init__.py exporting the pipeline class and any factory functions.
Use the appropriate existing example script:
| Category | Script |
|---|---|
| Text-to-Image | examples/offline_inference/text_to_image/text_to_image.py |
| Text-to-Video | examples/offline_inference/text_to_video/text_to_video.py |
| Image-to-Video | examples/offline_inference/image_to_video/image_to_video.py |
| Image-to-Image | examples/offline_inference/image_to_image/image_edit.py |
| Text-to-Audio | examples/offline_inference/text_to_audio/text_to_audio.py |
Reuse these shared scripts even for custom models when their request and output contracts fit. Create a dedicated model script only when the shared category cannot represent the protocol, and document that gap in the PR.
Validation: No errors, output is meaningful, quality matches reference implementation.
See references/troubleshooting.md for common errors.
Only when the shared category scripts cannot represent the model, create:
examples/offline_inference/your_model_name/ — offline script + READMEexamples/online_serving/your_model_name/ — server script + clientFollow the add-recipe skill to add or update the
model-family recipe and its recipes/README.md row with verified specifications,
hardware, commands, feature links, and qualification evidence.
Required updates:
docs/user_guide/diffusion/parallelism/overview.md — parallelism support overview/tabledocs/user_guide/diffusion/cpu_offload.md — if CPU offload supported (add to supported models table)docs/user_guide/diffusion/cache_acceleration/teacache.md — if TeaCache supporteddocs/user_guide/diffusion/cache_acceleration/cache_dit.md — if Cache-DiT supportedexamples/offline_inference/<name>/ (README.md or category-specific .md)examples/online_serving/<name>/README.md — online serving docsFollow the vllm-omni-test skill for markers, file naming, Buildkite wiring, and run commands. Also read l4_functionality_tests.inc.md, test_system_overview.md, and test_writing_guide.md.
Classify the model's CI priority first:
| Priority | Required test levels | Files & markers |
|---|---|---|
| High (listed in #1832 or on the diffusion hot path) | L1 · L2 online · L3 online + offline · L4 feature + performance | See table below |
| Medium (normal priority in L4 docs) | L3 online + offline · L4 feature only | Fewer L4 parametrized rows |
| Low | L4 feature only | One or two *_expansion.py cases |
Per-level deliverables (diffusion / pytest.mark.diffusion):
| Level | Location | Marker | CI pipeline | Notes |
|---|---|---|---|---|
| L1 | tests/diffusion/models/{slug}/, tests/diffusion/cache/, transformer unit tests | core_model + cpu | test-ready.yml | Weight remap, _sp_plan, cache enabler registration, shape contracts |
| L2 | tests/e2e/online_serving/test_{slug}.py (and offline if the category is offline-first) | core_model + advanced_model (both on baseline smoke) + diffusion + @hardware_test / hardware_marks | test-ready.yml | Default deploy smoke — minimal num_inference_steps, single prompt |
| L3 | tests/e2e/online_serving/test_{slug}.py and tests/e2e/offline_inference/test_{slug}.py when offline matters | Baseline smoke: core_model + advanced_model; heavier cases: advanced_model only (+ diffusion) | test-merge.yml or merged into nightly diffusion function job | Real weights, streaming/API paths, LoRA/offload smoke |
| L4 | tests/e2e/online_serving/test_{slug}_expansion.py (+ offline expansion if needed) | full_model + diffusion | test-nightly.yml (X2I / X2V / X2A function groups) | Feature combos per #1832; perf → tests/dfx/perf/tests/test_{model}_vllm_omni.json with per-case mark (hardware_marks + full_model + diffusion) |
L2 & L3 online — same file, dual marks on the baseline smoke: The first / simplest case in test_{slug}.py (default deploy, minimal steps, single prompt) should carry both @pytest.mark.core_model and @pytest.mark.advanced_model on the same function so L2 (test-ready.yml) and L3 (test-merge.yml) share one smoke test. Heavier deploy variants or API paths in the same file use advanced_model only. When L3 moves to nightly, migrate those heavier cases into test_{slug}_expansion.py with full_model and remove the dedicated test-merge.yml job (see test_longcat_image_expansion.py, test_qwen_image_expansion.py).
L4 design (high priority): Combine multiple supported features (Cache-DiT, TP, USP, CFG, HSDP, CPU offload, quantization) into few parametrized OmniServerParams rows so each feature appears in at least one case without exploding GPU jobs. Shard single-GPU vs multi-GPU cases across the nightly X2I/X2V function steps (cards_1 vs not cards_1).
L4 design (medium / low): One or two parametrized rows covering the best quality/perf trade-off; skip perf JSON unless the model is high priority.
Reference implementations: tests/e2e/online_serving/test_qwen_image_edit_expansion.py, tests/e2e/online_serving/test_longcat_image_expansion.py, tests/e2e/online_serving/test_hunyuan_video_15_expansion.py.
Keep model-specific code inside test modules — not tests/helpers/{slug}.py: deploy constants, prompts, sampling dicts, and inline request_config / form_data belong in each test_{slug}.py and test_{slug}_expansion.py. Do not add per-model files under tests/helpers/; reuse only repo-wide harness (mark, media, runtime, stage_config, assertions). L2+ online/offline e2e: reuse or add send_*_request in tests/helpers/runtime.py — tests call the handler, not raw omni.generate / HTTP. See vllm-omni-test skill § Runtime send helpers.
Keep the model suite proportional using the six distinct failure owners in the native integration checklist. Combine supported features into a few parametrized E2E rows instead of creating one test per optimization.
Add caching only after uncached single-device correctness. Read
references/cache-dit-patterns.md, use the
automatic single-block-list path when possible, and add a registered
BlockAdapter only for genuinely custom block topology.
Verify a real cache hit and compare quality with the uncached baseline. Make a speed claim only at a realistic step count where warmup permits hits; an all-warmup smoke proves integration, not acceleration.
After the model works on a single GPU, add multi-GPU parallelism. Add each type incrementally, testing after each addition.
See references/parallelism-patterns.md for detailed code patterns and API reference.
Recommended order: TP → SP/USP → CFG Parallel → HSDP
Replace compatible projections with vLLM parallel linears, preserve checkpoint fusion/loading, and use local head counts. Require query/KV head divisibility and compare a multi-rank forward with the one-rank oracle.
Prefer the declarative _sp_plan. For packed variable-length attention or
learned-sink LSE correction, keep model math explicit and reuse shared exchange
utilities. Validate uneven sequence splits, RoPE coordinates, and outputs
against the one-rank oracle.
Confirm the model uses CFG. Then reuse CFGParallelMixin, overriding prediction
or recombination only for non-standard or multi-output pipelines. Distinguish a
packed positive/negative implementation from two independent branches and
validate the two-rank result against the packed one-rank oracle.
Declare layer shard conditions and ignored rank-local modules; preserve mixed checkpoint dtypes. HSDP cannot combine with TP. Measure parameter loading, FSDP materialization, warm HBM, and host PSS rather than assuming sharding saves peak memory. Keep the resident layout as default if HSDP is worse.
After adding parallelism support, update:
docs/user_guide/diffusion/parallelism/overview.md — add your model to the support overview/tableImplement SupportsComponentDiscovery on your pipeline class to enable
--enable-cpu-offload and --enable-layerwise-offload. The protocol
declares which submodules the offloader should manage:
from typing import ClassVar
from vllm_omni.diffusion.models.interface import SupportsComponentDiscovery
class YourPipeline(nn.Module, SupportsComponentDiscovery):
_dit_modules: ClassVar[list[str]] = ["transformer"]
_encoder_modules: ClassVar[list[str]] = ["text_encoder"]
_vae_modules: ClassVar[list[str]] = ["vae"]
_resident_modules: ClassVar[list[str]] = [] # optional_dit_modules: denoising submodules (kept on GPU during diffusion loop)_encoder_modules: encoder/vision submodules (offloaded to CPU during diffusion loop)_vae_modules: VAE(s) (handled by both sequential and layerwise backends)_resident_modules: additional modules to pin on GPU during layerwise
offloading (e.g. embedders, connectors). Only used by the layerwise
backend. Optional — defaults to [].All attribute names support dotted paths for nested submodules
(e.g. "pipe.transformer", "bagel.time_embedder").
Pipelines without SupportsComponentDiscovery fall back to scanning
well-known attribute names (transformer, text_encoder, vae,
etc.), which fails for non-standard names.
Keep model-specific checkpoint paths, nested block aliases, layout transforms,
and component lifecycles in the model package. Change a shared offloader only
for a general contract, demonstrate another consumer or a framework-level bug,
and add one focused shared regression. Avoid if ModelName branches in shared
backends.
After verifying correctness and implementing parallelism/caching, profile the model's performance to identify bottlenecks and ensure optimal execution.
See the Profiling Single-Stage Diffusion guide for detailed instructions on:
profiler: "torch") to capture detailed CPU/CUDA traces.nsys) with profiler: "cuda" for low-overhead CUDA traces.omni.start_profile() and omni.stop_profile().Report cold E2E, warm user latency, steady-state wave time, peak allocated and reserved HBM, host PSS for the full process tree, and stage boundaries. State whether prompt encoding and VAE/audio decoding are included. For multi-device layouts, plot user latency against throughput per device and keep different denoising-step counts on separate Pareto frontiers.
New library files must pass the local gates in
docs/contributing/README.md.
That page is the full hook list (SPDX, forbidden imports including Hugging Face
Hub / Triton / pickle, torch.cuda, mypy, test marks, markdownlint, Buildkite,
shellcheck). In particular:
vLLM-Omni project (stale vLLM project is rewritten).import regex as re and pybase64 in vllm_omni/; do not import stdlib
re or base64. Hugging Face Hub downloads go through
vllm.transformers_utils.repo_utils.torch.cuda.* call sites; use current_omni_platform.tests/**/test_*.py files need a CI level mark and a hardware mark.CHECK_IMPORTS[*].allowed_files or ALLOWED_FILES without review.pre-commit locally.--enforce-eager: Disable torch.compile during debugging© vllm-project, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file
SKILL.md and 6 other files (references) in .claude/skills/add-diffusion-model of vllm-project/vllm-omni.
Open the folder on GitHubat commit c548a11
Add Diffusion Model next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.
| Skill | Stars | Used in | Tokens | Auto-check | Licence | Repo updated |
|---|---|---|---|---|---|---|
| Add Diffusion Model this skillvllm-project/vllm-omni | 7.1k | — | ~7k | Automated safety check: Pass | Apache-2.0 | |
| SageMaker Serving Image Selectionhuggingface/skills | 11k | 1 repos | ~4.6k | Automated safety check: Pass | Apache-2.0 | |
| Hugging Face Local Model Evalshuggingface/skills | 11k | 2 repos | ~1.6k | Automated safety check: Pass | Apache-2.0 | |
| CI Fails Buildkiteguqiong96/Lvllm | 464 | 2 repos | ~349 | Automated safety check: Pass | Apache-2.0 | |
| Adapt New Diffusion Modelintel/auto-round | 1.6k | — | ~2.8k | Automated safety check: Pass | Apache-2.0 | |
| Gptqmodel Tokenizer NormalizationModelCloud/GPTQModel | 1.3k | — | ~1.1k | Automated safety check: Pass | Custom licence |
huggingface/skills
Chooses the right serving container and current image URI for deploying a Hugging Face model to a SageMaker endpoint, preferring Hugging Face images over generic ones.
huggingface/skills
Runs evaluations of Hugging Face Hub models on local hardware with inspect-ai or lighteval, and helps choose between vLLM, Transformers and accelerate backends.
guqiong96/Lvllm
Fetch and diagnose vLLM Buildkite CI failure logs. An agent skill from guqiong96/Lvllm.
intel/auto-round
Adapt AutoRound to support a new diffusion model architecture (DiT, UNet, hybrid AR+DiT).
ModelCloud/GPTQModel
Diagnose and correct GPT-QModel tokenizer initialization, tokenization normalization, special-token handling, prompt rendering, and chat-template problems.
MetaX-MACA/vLLM-metax
Review and upgrade MetaX model support against a target vLLM revision and installed MACA components, recursively including model-dependent attention and kernels.
vllm-project/vllm-omni
Diagnose and optimize vLLM Omni diffusion workloads, especially Wan/Qwen/Flux-style image and video generation.
vllm-project/vllm-omni
Self-check your branch before creating a PR — catch dead code, prevent new model-specific Python examples, verify accuracy/perf claims, validate PR title format, and confirm merge readiness.
vllm-project/vllm-omni
Work on vLLM-Omni quantization for diffusion, autoregressive, omni, or multi-stage models.
vllm-project/vllm-omni
Review pull requests and local branches for vllm-project/vllm-omni with a frozen snapshot, module-design ownership, feature-design overlays, targeted validation, and concise evidence-backed findings.
vllm-project/vllm-omni
Write MiniMax H3 video generation prompts for T2VA, I2VA, FL2VA, L2VA, and Ref2VA.
vllm-project/vllm-omni
Add or update an in-repository vLLM-Omni model recipe with verified task, input, output, hardware, command, feature, and validation contracts.
Works with
Categories
Add a new diffusion model (text-to-image, text-to-video, image-to-video, text-to-audio, image editing) to vLLM-Omni, including native non-Diffusers ports, reference-parity validation, Cache-DiT…. Add Diffusion Model is an agent skill from vllm-project/vllm-omni. Add a new diffusion model (text-to-image, text-to-video, image-to-video, text-to-audio, image editing) to vLLM-Omni, including native non-Diffusers ports, reference-parity validation, Cache-DiT, offload, and parallelism support (TP, SP/USP, CFG-Parallel, HSDP).
Add Diffusion Model fits situations like: reviewing a new diffusion model; porting a Diffusers pipeline; custom model repository; creating a DiT adapter.
Run `npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a claude-code`. Or copy the skill folder (.claude/skills/add-diffusion-model in vllm-project/vllm-omni) into .claude/skills/add-diffusion-model in your project. Claude Code loads it when a task matches its description.
Run `npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a codex`. Or copy the skill folder (.claude/skills/add-diffusion-model in vllm-project/vllm-omni) into .agents/skills/add-diffusion-model in your project. Codex loads it when a task matches its description.
Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add vllm-project/vllm-omni --skill add-diffusion-model -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/add-diffusion-model, .gemini/skills/add-diffusion-model, .github/skills/add-diffusion-model and .opencode/skills/add-diffusion-model in your project.
SKILL.md names no scripts, command-line tools or credentials: Add Diffusion Model is instructions for the agent only. Our summary lists: Python 3.
SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.
Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.
Add Diffusion Model is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.
About 7k tokens (SKILL.md is roughly 28k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full. Its references folder adds about 15k tokens, read only when the agent opens those files.
Skills that share tags, products or a category with Add Diffusion Model: SageMaker Serving Image Selection (huggingface/skills, 11k stars), Hugging Face Local Model Evals (huggingface/skills, 11k stars), CI Fails Buildkite (guqiong96/Lvllm, 464 stars) and Adapt New Diffusion Model (intel/auto-round, 1.6k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.
vllm-project (a GitHub organization) maintains it in vllm-project/vllm-omni, which has 7,072 GitHub stars. The repository holds 20 skills in this directory. The repository was last updated on October 8, 2026.
Source: vllm-project/vllm-omni on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.