executing-plans
executing-plans
Use when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available
inferenceBuilds and troubleshoots HunyuanVideo single-GPU text-to-video CLI and Python API inference workflows.
Independent GitHub snapshot · Automated classification · Original documentation governs
Use this sub-skill for single-GPU text-to-video generation with the canonical sampling entry point and the HunyuanVideoSampler API. Route setup/checkpoint problems to ../checkpoint-and-setup/SKILL.md, FP8 or multi-GPU decisions to ../parallel-and-optimization/SKILL.md, and browser UI tasks to ../web-demo/SKILL.md.
references/workflows.md for practical single-GPU generation recipes.references/cli-reference.md for parser flags, defaults, and constraints.references/api-reference.md for verified Python signatures and return contracts.references/troubleshooting.md for common CLI/API failures.scripts/build_sample_command.py to construct a safe command without launching generation.Generate a command for a prepared HunyuanVideo checkout:
python sub-skills/inference/scripts/build_sample_command.py \
--prompt "A cat walks on the grass, realistic style." \
--height 544 --width 960 --video-length 129 \
--seed 42 --use-cpu-offload --save-path ./results
The helper validates positive dimensions and the default 3D VAE frame rule before printing the command. It does not load checkpoints or use CUDA.
4n+1.--flow-reverse; the repository examples use it.--use-cpu-offload for single-GPU memory pressure, but do not use it for xDiT distributed mode.The high-level Python path is:
from pathlib import Path
from hyvideo.config import parse_args
from hyvideo.inference import HunyuanVideoSampler
args = parse_args()
sampler = HunyuanVideoSampler.from_pretrained(Path(args.model_base), args=args)
outputs = sampler.predict(prompt=args.prompt, height=args.video_size[0], width=args.video_size[1], video_length=args.video_length)
Read references/api-reference.md before writing nontrivial API code because prompt, seed, video length, and guidance handling have implementation-specific behavior.