LTX-2.3: Text to Video
Generate a video from a text prompt, optionally using an image for reference. Receive a high-quality video with improved motion, audio, and detail, optimized for portrait or landscape formats.
查看工作流内部
源模板的只读预览。在 Cloud 中打开,即可查看节点并进行修改。
Loading the graph
Open full-size workflow preview- 输出
- 视频
- 作者
- ComfyUI
从代码中调用该模型
以下请求使用与体验区相同的预设图和设置。每次提交都可能开始一次付费运行;如果提交结果未知,请勿自动重试。
What you need
- Runs on
- Comfy Cloud
- 密钥
- COMFY_API_KEY
需要付费的 Cloud 方案和额度。
# Python 3.10+: pip install comfy-sdk==0.4.0
import os
from comfy_sdk import Comfy
api_key = os.environ.get("COMFY_API_KEY", "").strip()
if not api_key: raise RuntimeError("Set COMFY_API_KEY")
os.environ.setdefault("COMFY_BASE_URL", "https://cloud.comfy.org")
client = Comfy(api_key=api_key)
workflow = client.workflows.from_json({
"75": {
"class_type": "SaveVideo",
"inputs": {
"filename_prefix": "video/LTX_2.3_t2v",
"format": "auto",
"format.codec": "auto",
"video": [
"267:242",
0
]
},
"_meta": {
"title": "Save Video"
}
},
"269": {
"class_type": "LoadImage",
"inputs": {
"image": "example.png"
},
"_meta": {
"title": "Load Image"
}
},
"267:201": {
"class_type": "PrimitiveBoolean",
"inputs": {
"value": True
},
"_meta": {
"title": "Switch to Text to Video?"
}
},
"267:209": {
"class_type": "KSamplerSelect",
"inputs": {
"sampler_name": "euler_ancestral_cfg_pp"
},
"_meta": {
"title": "KSamplerSelect"
}
},
"267:211": {
"class_type": "ManualSigmas",
"inputs": {
"sigmas": "0.85, 0.7250, 0.4219, 0.0"
},
"_meta": {
"title": "ManualSigmas"
}
},
"267:212": {
"class_type": "LTXVCropGuides",
"inputs": {
"latent": [
"267:217",
0
],
"negative": [
"267:239",
1
],
"positive": [
"267:239",
0
]
},
"_meta": {
"title": "LTXVCropGuides"
}
},
"267:213": {
"class_type": "CFGGuider",
"inputs": {
"cfg": 1,
"model": [
"267:232",
0
],
"negative": [
"267:212",
1
],
"positive": [
"267:212",
0
]
},
"_meta": {
"title": "CFG Guider"
}
},
"267:214": {
"class_type": "LTXVEmptyLatentAudio",
"inputs": {
"audio_vae": [
"267:221",
0
],
"batch_size": 1,
"frame_rate": [
"267:261",
1
],
"frames_number": [
"267:225",
0
]
},
"_meta": {
"title": "Empty LTXV Latent Audio"
}
},
"267:215": {
"class_type": "SamplerCustomAdvanced",
"inputs": {
"guider": [
"267:231",
0
],
"latent_image": [
"267:222",
0
],
"noise": [
"267:237",
0
],
"sampler": [
"267:209",
0
],
"sigmas": [
"267:252",
0
]
},
"_meta": {
"title": "SamplerCustomAdvanced"
}
},
"267:216": {
"class_type": "RandomNoise",
"inputs": {
"noise_seed": 42
},
"_meta": {
"title": "RandomNoise"
}
},
"267:217": {
"class_type": "LTXVSeparateAVLatent",
"inputs": {
"av_latent": [
"267:215",
0
]
},
"_meta": {
"title": "Separate AV Latent"
}
},
"267:218": {
"class_type": "LTXVSeparateAVLatent",
"inputs": {
"av_latent": [
"267:219",
0
]
},
"_meta": {
"title": "Separate AV Latent"
}
},
"267:219": {
"class_type": "SamplerCustomAdvanced",
"inputs": {
"guider": [
"267:213",
0
],
"latent_image": [
"267:229",
0
],
"noise": [
"267:216",
0
],
"sampler": [
"267:246",
0
],
"sigmas": [
"267:211",
0
]
},
"_meta": {
"title": "SamplerCustomAdvanced"
}
},
"267:220": {
"class_type": "LTXVAudioVAEDecode",
"inputs": {
"audio_vae": [
"267:221",
0
],
"samples": [
"267:218",
1
]
},
"_meta": {
"title": "LTXV Audio VAE Decode"
}
},
"267:221": {
"class_type": "LTXVAudioVAELoader",
"inputs": {
"ckpt_name": "ltx-2.3-22b-dev-fp8.safetensors"
},
"_meta": {
"title": "Load LTXV Audio VAE"
}
},
"267:222": {
"class_type": "LTXVConcatAVLatent",
"inputs": {
"audio_latent": [
"267:214",
0
],
"video_latent": [
"267:249",
0
]
},
"_meta": {
"title": "Concat AV Latent"
}
},
"267:225": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 121
},
"_meta": {
"title": "Length"
}
},
"267:228": {
"class_type": "EmptyLTXVLatentVideo",
"inputs": {
"batch_size": 1,
"height": [
"267:259",
1
],
"length": [
"267:225",
0
],
"width": [
"267:256",
1
]
},
"_meta": {
"title": "Empty LTXV Latent Video"
}
},
"267:229": {
"class_type": "LTXVConcatAVLatent",
"inputs": {
"audio_latent": [
"267:217",
1
],
"video_latent": [
"267:230",
0
]
},
"_meta": {
"title": "Concat AV Latent"
}
},
"267:230": {
"class_type": "LTXVImgToVideoInplace",
"inputs": {
"bypass": [
"267:201",
0
],
"image": [
"267:248",
0
],
"latent": [
"267:253",
0
],
"strength": 1,
"vae": [
"267:236",
2
]
},
"_meta": {
"title": "LTXVImgToVideoInplace"
}
},
"267:231": {
"class_type": "CFGGuider",
"inputs": {
"cfg": 1,
"model": [
"267:232",
0
],
"negative": [
"267:239",
1
],
"positive": [
"267:239",
0
]
},
"_meta": {
"title": "CFG Guider"
}
},
"267:232": {
"class_type": "LoraLoaderModelOnly",
"inputs": {
"lora_name": "ltx-2.3-22b-distilled-lora-384.safetensors",
"model": [
"267:236",
0
],
"strength_model": 0.5
},
"_meta": {
"title": "Load LoRA"
}
},
"267:233": {
"class_type": "LatentUpscaleModelLoader",
"inputs": {
"model_name": "ltx-2.3-spatial-upscaler-x2-1.1.safetensors"
},
"_meta": {
"title": "Load Latent Upscale Model"
}
},
"267:235": {
"class_type": "ResizeImagesByLongerEdge",
"inputs": {
"images": [
"267:238",
0
],
"longer_edge": 1536
},
"_meta": {
"title": "Resize Images by Longer Edge (DEPRECATED)"
}
},
"267:236": {
"class_type": "CheckpointLoaderSimple",
"inputs": {
"ckpt_name": "ltx-2.3-22b-dev-fp8.safetensors"
},
"_meta": {
"title": "Load Checkpoint"
}
},
"267:237": {
"class_type": "RandomNoise",
"inputs": {
"noise_seed": 731987174230470
},
"_meta": {
"title": "RandomNoise"
}
},
"267:238": {
"class_type": "ResizeImageMaskNode",
"inputs": {
"input": [
"269",
0
],
"resize_type": "scale dimensions",
"resize_type.crop": "center",
"resize_type.height": [
"267:258",
0
],
"resize_type.width": [
"267:257",
0
],
"scale_method": "lanczos"
},
"_meta": {
"title": "Resize Image/Mask"
}
},
"267:239": {
"class_type": "LTXVConditioning",
"inputs": {
"frame_rate": [
"267:261",
0
],
"negative": [
"267:247",
0
],
"positive": [
"267:240",
0
]
},
"_meta": {
"title": "LTXVConditioning"
}
},
"267:240": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"267:243",
0
],
"text": [
"267:274",
0
]
},
"_meta": {
"title": "CLIP Text Encode (Prompt)"
}
},
"267:242": {
"class_type": "CreateVideo",
"inputs": {
"audio": [
"267:220",
0
],
"bit_depth": "auto",
"codec": "none",
"color_space": "sRGB",
"fps": [
"267:261",
0
],
"images": [
"267:251",
0
]
},
"_meta": {
"title": "Create Video"
}
},
"267:243": {
"class_type": "LTXAVTextEncoderLoader",
"inputs": {
"ckpt_name": "ltx-2.3-22b-dev-fp8.safetensors",
"device": "default",
"text_encoder": "gemma_3_12B_it_fp4_mixed.safetensors"
},
"_meta": {
"title": "Load LTXV Audio Text Encoder"
}
},
"267:246": {
"class_type": "KSamplerSelect",
"inputs": {
"sampler_name": "euler_cfg_pp"
},
"_meta": {
"title": "KSamplerSelect"
}
},
"267:247": {
"class_type": "CLIPTextEncode",
"inputs": {
"clip": [
"267:272",
1
],
"text": "pc game, console game, video game, cartoon, childish, ugly"
},
"_meta": {
"title": "CLIP Text Encode (Prompt)"
}
},
"267:248": {
"class_type": "LTXVPreprocess",
"inputs": {
"image": [
"267:235",
0
],
"img_compression": 18
},
"_meta": {
"title": "LTXV Preprocess"
}
},
"267:249": {
"class_type": "LTXVImgToVideoInplace",
"inputs": {
"bypass": [
"267:201",
0
],
"image": [
"267:248",
0
],
"latent": [
"267:228",
0
],
"strength": 0.7,
"vae": [
"267:236",
2
]
},
"_meta": {
"title": "LTXVImgToVideoInplace"
}
},
"267:251": {
"class_type": "VAEDecodeTiled",
"inputs": {
"overlap": 64,
"samples": [
"267:218",
0
],
"temporal_overlap": 4,
"temporal_size": 4096,
"tile_size": 768,
"vae": [
"267:236",
2
]
},
"_meta": {
"title": "VAE Decode (Tiled)"
}
},
"267:252": {
"class_type": "ManualSigmas",
"inputs": {
"sigmas": "1.0, 0.99375, 0.9875, 0.98125, 0.975, 0.909375, 0.725, 0.421875, 0.0"
},
"_meta": {
"title": "ManualSigmas"
}
},
"267:253": {
"class_type": "LTXVLatentUpsampler",
"inputs": {
"samples": [
"267:217",
0
],
"upscale_model": [
"267:233",
0
],
"vae": [
"267:236",
2
]
},
"_meta": {
"title": "LTXVLatentUpsampler"
}
},
"267:256": {
"class_type": "ComfyMathExpression",
"inputs": {
"expression": "a/2",
"values.a": [
"267:257",
0
]
},
"_meta": {
"title": "Math Expression"
}
},
"267:257": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 1280
},
"_meta": {
"title": "Width"
}
},
"267:258": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 720
},
"_meta": {
"title": "Height"
}
},
"267:259": {
"class_type": "ComfyMathExpression",
"inputs": {
"expression": "a/2",
"values.a": [
"267:258",
0
]
},
"_meta": {
"title": "Math Expression"
}
},
"267:260": {
"class_type": "PrimitiveInt",
"inputs": {
"value": 25
},
"_meta": {
"title": "Frame Rate"
}
},
"267:261": {
"class_type": "ComfyMathExpression",
"inputs": {
"expression": "a",
"values.a": [
"267:260",
0
]
},
"_meta": {
"title": "Math Expression"
}
},
"267:266": {
"class_type": "PrimitiveStringMultiline",
"inputs": {
"value": "At stormy dusk, a solitary medieval warrior clad in hammered iron plate and sodden chainmail stands atop an expansive, muddy ridge. He wears an open-faced, rounded steel helmet revealing a weathered, scarred face streaked with grime. Sheets of heavy rain cut diagonally through the air, catching the fiery amber glow of a setting sun trapped beneath bruised violet storm clouds. Over five seconds, gale-force winds violently whip his frayed crimson cloak while tempestuous clouds churn rapidly overhead. The warrior slowly shifts his weight, gripping a notched steel longsword. The camera executes a low, continuous arc around his waist before smoothly pushing into a dramatic close-up of his steely, rain-soaked gaze. Ambient audio carries the violent drumming of downpour against steel plate, howling wind, and the distinct, wet creak of shifting leather armor."
},
"_meta": {
"title": "Prompt"
}
},
"267:272": {
"class_type": "LoraLoader",
"inputs": {
"clip": [
"267:243",
0
],
"lora_name": "gemma-3-12b-it-abliterated_lora_rank64_bf16.safetensors",
"model": [
"267:236",
0
],
"strength_clip": 1,
"strength_model": 1
},
"_meta": {
"title": "Load LoRA (Model and CLIP)"
}
},
"267:274": {
"class_type": "TextGenerateLTX2Prompt",
"inputs": {
"clip": [
"267:272",
1
],
"max_length": 256,
"mtp": "auto",
"prompt": [
"267:266",
0
],
"sampling_mode": "on",
"sampling_mode.min_p": 0.05,
"sampling_mode.repetition_penalty": 1.05,
"sampling_mode.seed": 0,
"sampling_mode.temperature": 0.7,
"sampling_mode.top_k": 64,
"sampling_mode.top_p": 0.95,
"thinking": False,
"use_default_template": True
},
"_meta": {
"title": "Generate LTX2 Prompt"
}
},
"267:275": {
"class_type": "PreviewAny",
"inputs": {
"source": [
"267:274",
0
]
},
"_meta": {
"title": "Preview as Text"
}
}
})
# run() also passes api_key to the partner nodes in this workflow.
job = client.run(workflow, api_key=api_key)
for output in job.get_outputs("75"):
output.to_file(output.name)试试一个示例
关于此工作流
The LTX-2.3: Text to Video workflow in ComfyUI is designed to transform a text prompt into a dynamic video, with the option to use an image as a reference. This workflow leverages the LTX-2.3 model, developed by Lightricks, which is optimized for generating high-quality videos with enhanced motion, audio, and detail. The workflow is particularly effective for creating videos in both portrait and landscape formats, making it versatile for various applications.
Technically, the workflow integrates several key nodes, including the SaveVideo node for outputting the final video, and the LoadImage node for incorporating reference images. The MarkdownNote node is used to provide inline documentation and guidance within the workflow. The core of the process involves using the b94257db-cdc1-45d3-8913-ca61e782d9c1 node, which is responsible for interpreting the text prompt and generating the corresponding video content.
This workflow is beneficial for users looking to quickly produce visually compelling videos from textual descriptions, with the added ability to refine the output using reference images.
常见问答
Yes, uploading an image is required to provide visual reference and enhance the detail in the generated video.
Yes, the workflow is optimized for both portrait and landscape formats, allowing you to choose based on your needs.
The workflow uses the LTX-2.3 model developed by Lightricks, which is available on Huggingface.
You can refine the video by adjusting the text prompt for more precise descriptions and uploading different reference images to influence visual details.