Director’s Cut is the final step of the WZRD Studio creation pipeline. Once every shot in your storyboard has an image or video, Director’s Cut syncs those assets into a chronological timeline, submits the job to a cloud video renderer (Fal-first with an automatic Editframe fallback), and returns a downloadable final video. The entire process is non-blocking — you trigger it, then poll until theDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/gratitude5dee/wzrd-studio-desktopfinal/llms.txt
Use this file to discover all available pages before exploring further.
completed stage is reached.
Route
syncAssets to pre-check readiness, and renders the current job state if one already exists for the project.
Before You Start
Director’s Cut requires every ordered shot to have at least an image (videos are preferred but images are accepted as fallbacks). The Sync Timeline Assets action checks readiness and surfaces blocking reasons before you can trigger the export.Shots
Total ordered shots across all scenes in the project.
Ready Shots
Shots with at least one visual asset (video or fallback image).
Missing
Shots with neither an image nor a video. These block export.
Ready Videos
Shots with a completed
video_url. Videos are preferred over images for a smoother output.Image Fallbacks
Shots that have an image but no video. These are still included in the export at a 5-second fixed duration.
How It Works
Sync Timeline Assets
Click Sync Timeline Assets or it runs automatically on page load. This calls:The edge function rebuilds the
timeline_assets table for the project — one row per shot visual (in position_order), plus audio tracks for any shot with dialogue or sound effects, plus any final_project_assets music files mapped to the music track. It returns a DirectorCutSummary.Start Director's Cut
Click Start Director’s Cut (The function checks readiness, loads the synced
DIRECTORS_CUT_CREDITS credits). This invokes:timeline_assets, and inserts an export_jobs row with status: 'processing'. It then calls processAssetsRemote in the background (via EdgeRuntime.waitUntil) and returns a jobId immediately.Poll for Status
The The response maps directly to
useDirectorCut hook polls every 2 seconds using:DirectorCutJobState. Polling stops automatically when status becomes completed or failed.Pipeline Stages
The Director’s Cut engine progresses through a fixed sequence of stages. TheStageIndicator component on the page renders each stage with a live spinner on the active stage and checkmarks on completed ones.
| Stage constant | STAGE_LABELS display |
|---|---|
syncing_assets | Syncing timeline assets |
preflighting_assets | Checking media URLs |
submitting_to_provider | Submitting to provider |
provider_processing | Provider processing |
fallback_processing | Editframe fallback |
downloading_assets | Downloading assets |
uploading_final_video | Uploading final video |
completed | Completed |
failed | Failed |
The
fallback_processing stage is reached when the primary Fal renderer is unavailable. The Editframe fallback requires the EDITFRAME_API_KEY secret to be configured in the Supabase edge function environment. If the secret is missing, the UI surfaces a targeted setup instruction.Type Reference
DirectorCutJobState
The full state object maintained by useDirectorCut and rendered on the page.
UUID of the
export_jobs row.One of:
pending | processing | completed | failed.Integer 0–100. Clamped by
clampProgress.Current pipeline stage. Drives the
StageIndicator and the status label in the progress bar header.Public download URL. Populated only when
status === 'completed'.Renderer that processed the job — typically
'fal_remote'.true when the Editframe fallback was activated.Array of
{ assetId, orderIndex, reason } entries for any shots that could not be rendered. Non-empty with partialSuccess: true means the video was produced from the remaining shots.true when the video completed despite some shot failures. A warning panel lists the skipped shots.Extended diagnostics:
renderer, falRequestId, providerJobId, fallbackReason, fallbackStatus, fallbackError, falError, failedShotCount, visualTracks, audioTracks.DirectorCutSummary
Returned by sync and checked before create.
Total ordered shots across all scenes.
Number of
timeline_assets rows written during the last sync.Shots with a
video_url.Shots with only an
image_url (will be rendered as a 5-second still).Shots with neither image nor video. Must be zero for export to proceed.
true when there are no missing shots and at least one visual asset exists.Human-readable explanation of why export is blocked.
null when canExport is true.Per-shot breakdown of missing visuals —
shotId, sceneNumber, shotNumber, reason, imageStatus, videoStatus.Credit Cost
ConfirmGenerateDialog) and directly on the button label in the Director’s Cut page itself.
useDirectorCut Hook
All page logic is encapsulated in this hook, exported from src/hooks/useDirectorCut.ts.
| Export | Type | Description |
|---|---|---|
summary | DirectorCutSummary | null | Latest sync summary. |
job | DirectorCutJobState | null | Current or last-known job state. |
error | string | null | Top-level error string from the latest failed operation. |
isSyncing | boolean | true while syncAssets is in flight. |
isStarting | boolean | true while startDirectorCut is submitting. |
isPolling | boolean | true while the 2-second poll interval is active. |
syncAssets() | async function | Calls action: 'sync'. Returns the new DirectorCutSummary. |
startDirectorCut(options?) | async function | Syncs (unless reuseSyncedAssets: true), then calls action: 'create' or 'retry', and starts polling. |
stopPolling() | function | Cancels the poll timer. Called automatically on unmount. |
StatCards
The seven metric cards at the top of the page map directly toDirectorCutSummary fields:
| Label | Field | Tone |
|---|---|---|
| Shots | totalShots | default |
| Ready Shots | readyShots | success (orange) |
| Synced Assets | syncedAssets | default |
| Ready Videos | readyVideos | success (orange) |
| Image Fallbacks | fallbackImages | warn (amber) |
| Audio | audioAssets | default |
| Missing | missingShots | warn (amber) |
Local Assembly Panel
For users running the WZRD Electron desktop app,LocalAssemblyPanel provides an alternative FFmpeg-based export that runs entirely on-device — no cloud credits required.
getDesktopBridge() Electron IPC bridge. It is rendered below the main cloud export UI and is only functional when the desktop bridge is present.
Error Recovery
When a Director’s Cut job fails, the page shows a diagnostic panel with:- The error message from
job.error - Provider name and status
- Whether the fallback was used
- A Render diagnostics section with
renderer,stage,falRequestId,providerJobId, andfallbackErrorfields - A Copy Debug Details button that copies the full
DirectorCutJobStateas formatted JSON to the clipboard - Per-shot failure details when
job.shotFailuresis non-empty
| Button | Action |
|---|---|
| Sync Again | Calls syncAssets() to rebuild timeline_assets |
| Retry Export | Calls startDirectorCut({ reuseSyncedAssets: true }) to skip re-syncing and reuse the last synced asset list |
MCP Tool: make_magic
The make_magic MCP tool orchestrates the entire WZRD pipeline end-to-end, including Director’s Cut. An agent using this tool does not need to navigate the UI at all.
Skill: agent-skills/make-magic/skill.md