Video Director Mode
Director Mode extends NeuroLink's video generation capability to produce multi-segment videos with seamless AI-generated transitions. Instead of a single clip, you define an array of segments — each with its own prompt and image — and NeuroLink orchestrates the full pipeline: generating each clip, extracting boundary frames, producing transition videos (with individually configurable durations) using Veo 3.1's first-and-last-frame interpolation, and merging everything into one continuous video.
Overview
Director Mode is triggered automatically when you supply an input.segments array to the video generation API. Each segment is a self-documenting { prompt, image } object, mapping cleanly to the pipeline concept of ordered video segments.
graph TD
A["Segment 1: Image A + Prompt 1"] --> G1["Generate Clip 1 (4-8s)"]
B["Segment 2: Image B + Prompt 2"] --> G2["Generate Clip 2 (4-8s)"]
C["Segment 3: Image C + Prompt 3"] --> G3["Generate Clip 3 (4-8s)"]
G1 --> F1["Extract Last Frame of Clip 1"]
G2 --> F2a["Extract First Frame of Clip 2"]
G2 --> F2b["Extract Last Frame of Clip 2"]
G3 --> F3["Extract First Frame of Clip 3"]
F1 --> T1["Generate Transition 1→2"]
F2a --> T1
F2b --> T2["Generate Transition 2→3"]
F3 --> T2
G1 --> M["Merge: Clip1 + Trans1 + Clip2 + Trans2 + Clip3"]
T1 --> M
G2 --> M
T2 --> M
G3 --> M
M --> O["Final Merged Video (MP4)"]
How It Works
- Parallel clip generation – All main clips are generated concurrently (fixed concurrency of 2) via Veo 3.1's image-to-video endpoint, with a circuit breaker that trips after 2 consecutive failures to avoid wasted API calls
- Frame extraction – The last frame of clip N and first frame of clip N+1 are extracted from generated video buffers (with MP4 ftyp header validation)
- Parallel transition generation – Veo 3.1 Fast's first-and-last-frame interpolation API generates transitions between each pair of adjacent clips in parallel (same concurrency limit), with individually configurable duration (4, 6, or 8 seconds each)
- Sequential merge – Clips and transitions are concatenated:
Clip₁ → Trans₁₋₂ → Clip₂ → Trans₂₋₃ → Clip₃ → … - Single output – The merged result is returned as one
VideoGenerationResultbuffer