vllm_omni.diffusion.worker.utils ¶
Per-request mutable state for step-wise diffusion execution.
BatchRunnerOutput dataclass ¶
Bases: BaseRunnerOutput
DiffusionRequestState dataclass ¶
Per-request mutable state across all pipeline stages.
Owned by Runner and passed through all step-execution stages: prepare_encode() initializes/updates fields, denoise_step() and step_scheduler() mutate per-step fields, and post_decode() consumes final latents. This state object is also the cache unit for future continuous batching.
This dataclass keeps only the minimal cross-model state required by the step-execution contract. Pipeline-specific state should be stored in extra and promoted here only when it becomes shared across models.
Examples:
- Wan-style pipelines may keep
condition,first_frame_mask, orimage_embedsinextra. - Bagel-style pipelines may keep
gen_context,cfg_text_context,cfg_img_context, orimage_shapeinextra.
RunnerOutput dataclass ¶
Bases: BaseRunnerOutput
Output of a single denoising step for a request.
NOTE: latents may be None when returned through IPC to avoid serialization overhead. The actual latents are kept in Worker's _request_state_cache.