Skip to content

vllm_omni.diffusion.models.ltx2.ltx2_recipes

Declarative execution recipes for the LTX model family.

LTX23_DISTILLED_ONE_STAGE_RECIPE module-attribute

LTX23_DISTILLED_ONE_STAGE_RECIPE = (
    _distilled_one_stage_recipe(
        LTX23_DISTILLED_TWO_STAGE_RECIPE
    )
)

LTX23_DISTILLED_TWO_STAGE_RECIPE module-attribute

LTX23_DISTILLED_TWO_STAGE_RECIPE = (
    LTX2_DISTILLED_TWO_STAGE_RECIPE
)

LTX23_ONE_STAGE_RECIPE module-attribute

LTX23_ONE_STAGE_RECIPE = LTXPipelineRecipe(
    supports_cache_dit=True,
    num_inference_steps=30,
    phases=(
        LTXPhaseRecipe(
            name="generate", guidance=_official_guidance(28)
        ),
    ),
)

LTX23_TWO_STAGE_RECIPE module-attribute

LTX23_TWO_STAGE_RECIPE = _official_two_stage_recipe(
    LTX23_ONE_STAGE_RECIPE
)

LTX25_DEFAULT_NEGATIVE_PROMPT module-attribute

LTX25_DEFAULT_NEGATIVE_PROMPT = (
    "has_subtitles, has_blurbox, transition from black, transition to black, speech_ending_short, "
    + LTX_DEFAULT_NEGATIVE_PROMPT
)

LTX25_DISTILLED_ONE_STAGE_RECIPE module-attribute

LTX25_DISTILLED_ONE_STAGE_RECIPE = (
    _distilled_one_stage_recipe(
        LTX25_DISTILLED_TWO_STAGE_RECIPE,
        supports_cache_dit=False,
    )
)

LTX25_DISTILLED_TWO_STAGE_RECIPE module-attribute

LTX25_DISTILLED_TWO_STAGE_RECIPE = LTXPipelineRecipe(
    height=1088,
    width=1920,
    num_inference_steps=len(LTX_DISTILLED_SIGMAS) - 1,
    negative_prompt="",
    phases=(
        LTXPhaseRecipe(
            name="generate_lowres",
            guidance=LTXGuidanceSpec.positive_only(),
            spatial_downscale=2,
            sigmas=LTX_DISTILLED_SIGMAS,
            noise_scale=1.0,
            allow_guidance_override=False,
            use_official_sigma_schedule=False,
            sampler="euler_ancestral",
        ),
        LTXPhaseRecipe(
            name="refine",
            guidance=LTXGuidanceSpec.positive_only(),
            sigmas=LTX_STAGE_2_DISTILLED_SIGMAS,
            noise_scale=LTX_STAGE_2_DISTILLED_SIGMAS[0],
            input_transform="spatial_upsample",
            allow_guidance_override=False,
            use_official_sigma_schedule=False,
        ),
    ),
    video_output_phase=1,
    audio_output_phase=1,
    allow_request_sigmas=False,
    allow_request_phase_sigmas=True,
    allow_request_latents=False,
    allow_negative_prompt=False,
    fixed_num_inference_steps=True,
)

LTX25_FULL_RECIPE module-attribute

LTX25_FULL_RECIPE = LTXPipelineRecipe(
    height=544,
    width=960,
    num_inference_steps=30,
    negative_prompt=LTX25_DEFAULT_NEGATIVE_PROMPT,
    phases=(
        LTXPhaseRecipe(
            name="generate",
            guidance=_official_guidance(28),
            noise_scale=1.0,
        ),
    ),
)

LTX25_TWO_STAGE_RECIPE module-attribute

LTX25_TWO_STAGE_RECIPE = _official_two_stage_recipe(
    LTX25_FULL_RECIPE
)

LTX2_DISTILLED_ONE_STAGE_RECIPE module-attribute

LTX2_DISTILLED_ONE_STAGE_RECIPE = (
    _distilled_one_stage_recipe(
        LTX2_DISTILLED_TWO_STAGE_RECIPE
    )
)

LTX2_DISTILLED_TWO_STAGE_RECIPE module-attribute

LTX2_DISTILLED_TWO_STAGE_RECIPE = LTXPipelineRecipe(
    height=1024,
    width=1536,
    num_inference_steps=len(LTX_DISTILLED_SIGMAS) - 1,
    negative_prompt="",
    phases=(
        LTXPhaseRecipe(
            name="generate_lowres",
            guidance=LTXGuidanceSpec.positive_only(),
            spatial_downscale=2,
            sigmas=LTX_DISTILLED_SIGMAS,
            noise_scale=1.0,
            allow_guidance_override=False,
            use_official_sigma_schedule=False,
        ),
        LTXPhaseRecipe(
            name="refine",
            guidance=LTXGuidanceSpec.positive_only(),
            sigmas=LTX_STAGE_2_DISTILLED_SIGMAS,
            noise_scale=LTX_STAGE_2_DISTILLED_SIGMAS[0],
            input_transform="spatial_upsample",
            allow_guidance_override=False,
            use_official_sigma_schedule=False,
        ),
    ),
    video_output_phase=1,
    audio_output_phase=1,
    allow_request_sigmas=False,
    allow_request_latents=False,
    allow_negative_prompt=False,
    fixed_num_inference_steps=True,
)

LTX2_ONE_STAGE_RECIPE module-attribute

LTX2_ONE_STAGE_RECIPE = LTXPipelineRecipe(
    supports_cache_dit=True,
    phases=(
        LTXPhaseRecipe(
            name="generate", guidance=_official_guidance(29)
        ),
    ),
)

LTX2_TWO_STAGE_RECIPE module-attribute

LTX2_TWO_STAGE_RECIPE = _official_two_stage_recipe(
    LTX2_ONE_STAGE_RECIPE
)

LTX_DEFAULT_NEGATIVE_PROMPT module-attribute

LTX_DEFAULT_NEGATIVE_PROMPT = "blurry, out of focus, overexposed, underexposed, low contrast, washed out colors, excessive noise, grainy texture, poor lighting, flickering, motion blur, distorted proportions, unnatural skin tones, deformed facial features, asymmetrical face, missing facial features, extra limbs, disfigured hands, wrong hand count, artifacts around text, inconsistent perspective, camera shake, incorrect depth of field, background too sharp, background clutter, distracting reflections, harsh shadows, inconsistent lighting direction, color banding, cartoonish rendering, 3D CGI look, unrealistic materials, uncanny valley effect, incorrect ethnicity, wrong gender, exaggerated expressions, wrong gaze direction, mismatched lip sync, silent or muted audio, distorted voice, robotic voice, echo, background noise, off-sync audio, incorrect dialogue, added dialogue, repetitive speech, jittery movement, awkward pauses, incorrect timing, unnatural transitions, inconsistent framing, tilted camera, flat lighting, inconsistent tone, cinematic oversaturation, stylized filters, or AI artifacts."

LTX_DISTILLED_ADAPTER_SLOT module-attribute

LTX_DISTILLED_ADAPTER_SLOT = 'ltx_distilled'

LTX_DISTILLED_SIGMAS module-attribute

LTX_DISTILLED_SIGMAS = (
    1.0,
    0.99375,
    0.9875,
    0.98125,
    0.975,
    0.909375,
    0.725,
    0.421875,
    0.0,
)

LTX_POSITIVE_ONLY_RECIPE module-attribute

LTX_POSITIVE_ONLY_RECIPE = LTXPipelineRecipe(
    supports_cache_dit=True,
    phases=(
        LTXPhaseRecipe(
            name="generate",
            guidance=LTXGuidanceSpec.positive_only(),
            use_official_sigma_schedule=False,
        ),
    ),
)

LTX_STAGE_2_DISTILLED_SIGMAS module-attribute

LTX_STAGE_2_DISTILLED_SIGMAS = (
    0.909375,
    0.725,
    0.421875,
    0.0,
)

LTXPhaseRecipe dataclass

One denoise phase and the transition used to construct its input.

adapter_slot class-attribute instance-attribute

adapter_slot: str | None = None

allow_guidance_override class-attribute instance-attribute

allow_guidance_override: bool = True

guidance instance-attribute

guidance: LTXGuidanceSpec

input_transform class-attribute instance-attribute

input_transform: Literal["initial", "spatial_upsample"] = (
    "initial"
)

name instance-attribute

name: str

noise_scale class-attribute instance-attribute

noise_scale: float = 0.0

num_inference_steps property

num_inference_steps: int | None

sampler class-attribute instance-attribute

sampler: Literal['euler', 'euler_ancestral'] = 'euler'

sigmas class-attribute instance-attribute

sigmas: tuple[float, ...] | None = None

spatial_downscale class-attribute instance-attribute

spatial_downscale: int = 1

use_official_sigma_schedule class-attribute instance-attribute

use_official_sigma_schedule: bool = True

LTXPipelineRecipe dataclass

Request defaults, ordered phases, output routing, and request capabilities.

allow_negative_prompt class-attribute instance-attribute

allow_negative_prompt: bool = True

allow_request_latents class-attribute instance-attribute

allow_request_latents: bool = True

allow_request_phase_sigmas class-attribute instance-attribute

allow_request_phase_sigmas: bool = False

allow_request_sigmas class-attribute instance-attribute

allow_request_sigmas: bool = True

audio_output_phase class-attribute instance-attribute

audio_output_phase: int = -1

fixed_num_inference_steps class-attribute instance-attribute

fixed_num_inference_steps: bool = False

frame_rate class-attribute instance-attribute

frame_rate: float = 24.0

height class-attribute instance-attribute

height: int = 512

max_spatial_downscale property

max_spatial_downscale: int

negative_prompt class-attribute instance-attribute

negative_prompt: str = LTX_DEFAULT_NEGATIVE_PROMPT

num_frames class-attribute instance-attribute

num_frames: int = 121

num_inference_steps class-attribute instance-attribute

num_inference_steps: int = 40

phases instance-attribute

phases: tuple[LTXPhaseRecipe, ...]

request_guidance property

request_guidance: LTXGuidanceSpec

supports_cache_dit class-attribute instance-attribute

supports_cache_dit: bool = False

video_output_phase class-attribute instance-attribute

video_output_phase: int = -1

width class-attribute instance-attribute

width: int = 768

resolve_ltx_pipeline_recipe

resolve_ltx_pipeline_recipe(
    pipeline_kind: str, model_version: str
) -> LTXPipelineRecipe

Resolve execution independently from component loading.