Open source CapCut alternative.
TypeScript
docs: document music generation
David Le367e4fd6fb28
diff --git a/docs/guides/backend-apis.md b/docs/guides/backend-apis.mdindex 40126e0e..036abbf9 100644--- a/docs/guides/backend-apis.md+++ b/docs/guides/backend-apis.md@@ -178,10 +178,10 @@ unless a database rate overrides them. The fallbacks mirror current publicprovider prices, mark them up by the supported margin, and round up to thenearest credit micro. Token models charge per million provider tokens; hiddenreasoning or output tokens are billed as output when the provider's-`totalTokens` exceeds visible input plus output. ElevenLabs speech and sound-effects bill by the provider's returned units; music bills by request duration-when the request fixes its length. Keep rate overrides and per-user limits in-backend-owned data, not the Mac app.+`totalTokens` exceeds visible input plus output. Speech bills by the provider's+returned units; a music render bills flat per generated clip, since the render is+a fixed-length interaction that carries no per-second usage. Keep rate overrides+and per-user limits in backend-owned data, not the Mac app.**Usage rows store units, never content.** They may keep sanitized providerusage metadata and normalized billable units. They must not keep prompts,diff --git a/docs/guides/cut/ai-assistant.md b/docs/guides/cut/ai-assistant.mdindex b23420c3..57735c77 100644--- a/docs/guides/cut/ai-assistant.md+++ b/docs/guides/cut/ai-assistant.md@@ -74,7 +74,7 @@ Tool calls execute in the open tab against the same store the user is editing## Generating a whole video-Most generation tools make one asset. `generate_scene` makes a whole cut: it writes a script, breaks it into shots, and — once the user approves — renders each shot and lays them on the timeline. The video model speaks each shot's line, so the clips carry their own narration; a music bed sits under them. It is genre-agnostic; the look comes from the brief and any references. It can also animate audio the project already has (`from_audio_asset_id`), tiling shots over that spine instead of writing a script.+Most generation tools make one asset — an image, a video clip, a voiceover, or an instrumental music bed (`generate_music`, scene-aware enough to score a whole video). `generate_scene` makes a whole cut: it writes a script, breaks it into shots, and — once the user approves — renders each shot and lays them on the timeline. The video model speaks each shot's line, so the clips carry their own narration; a music bed sits under them. It is genre-agnostic; the look comes from the brief and any references. It can also animate audio the project already has (`from_audio_asset_id`), tiling shots over that spine instead of writing a script.Because a scene renders many paid shots, the tool plans and then stops. `generate_scene` returns a shot list and waits; `approve_scene` starts the renders; `regenerate_shot` and `restyle_scene` revise afterward; `cancel_scene` kills the active run. The plan the user approves is the plan that renders: voicing runs after the gate and only rescales the approved shots to the real voice lengths (a line longer than one clip splits its shot). The run is browser-side like every generation here, held in a small store beside the panels (`lib/genScene.ts`) so switching tabs never orphans it; leaving the project pauses it, its persisted plan (`ProjectDoc.genvideo`) resumes on the next open, and a run that dies persists as failed so a reload never resumes it. Nothing runs behind the user's back: cancelling, dismissing an unrendered plan, or deleting the chat thread that asked all stop the run and clear its plan — clips already placed stay on the timeline. Progress shows on a card in the chat while the timeline fills on its own. The shots ride under one consistent AI voice with the video model's own audio off; this version has no talking-head lip-sync.