Skip to content

armgit / fuobe

Public Imported from GitHub
0

The open creative studio on ComfyUI: images, video, 3D and audio on open weights, on your own GPU or the cloud. Camera motions, effects, apps, Cinema, Layers, Image to 3D and an AI agent.

Translate & dub: a Voice split on the open engine, with DBS that keeps the music and effects

Claude8fb819e87058
diff --git a/scripts/comfy/hand-built/dub-prepare-dbs-transcribe.json b/scripts/comfy/hand-built/dub-prepare-dbs-transcribe.json
new file mode 100644
index 00000000..a63ac492
--- /dev/null
+++ b/scripts/comfy/hand-built/dub-prepare-dbs-transcribe.json
@@ -0,0 +1,151 @@
+{
+ "1": {
+ "class_type": "LoadAudio",
+ "inputs": {
+ "audio": "input.wav"
+ },
+ "_meta": {
+ "title": "Speech to dub (audio, or a video with sound)"
+ }
+ },
+ "2": {
+ "class_type": "DBSLoader",
+ "inputs": {
+ "model": "DBS-BSRNN-DnR",
+ "device": "auto"
+ },
+ "_meta": {
+ "title": "DBS Loader"
+ }
+ },
+ "3": {
+ "class_type": "DBSSeparate",
+ "inputs": {
+ "model": [
+ "2",
+ 0
+ ],
+ "audio": [
+ "1",
+ 0
+ ],
+ "channels": "mono",
+ "output_sample_rate": "input"
+ },
+ "_meta": {
+ "title": "DBS Separate (music / sfx / speech)"
+ }
+ },
+ "4": {
+ "class_type": "AudioMerge",
+ "inputs": {
+ "audio1": [
+ "1",
+ 0
+ ],
+ "audio2": [
+ "3",
+ 2
+ ],
+ "merge_method": "subtract"
+ },
+ "_meta": {
+ "title": "Background: the original minus the speech"
+ }
+ },
+ "5": {
+ "class_type": "SaveAudioAdvanced",
+ "inputs": {
+ "audio": [
+ "3",
+ 2
+ ],
+ "filename_prefix": "fuobe/dub-dbs/voice",
+ "format": "flac"
+ },
+ "_meta": {
+ "title": "Voice stem (the speech to clone)"
+ }
+ },
+ "6": {
+ "class_type": "SaveAudioAdvanced",
+ "inputs": {
+ "audio": [
+ "4",
+ 0
+ ],
+ "filename_prefix": "fuobe/dub-dbs/background",
+ "format": "flac"
+ },
+ "_meta": {
+ "title": "Background stem (music & effects)"
+ }
+ },
+ "7": {
+ "class_type": "AILab_Qwen3ASRSubtitle",
+ "inputs": {
+ "audio": [
+ "3",
+ 2
+ ],
+ "model": "Qwen/Qwen3-ASR-1.7B-hf",
+ "precision": "bf16",
+ "attention": "auto",
+ "forced_aligner": "Qwen/Qwen3-ForcedAligner-0.6B-hf",
+ "language": "auto",
+ "hints": "",
+ "output_format": "none",
+ "output_path": "",
+ "split_mode": "split_by_punctuation_or_pause",
+ "max_gap_sec": 0.6,
+ "max_chars": 40,
+ "max_inference_batch_size": 32,
+ "max_new_tokens": 256,
+ "normalize_text": true,
+ "unload_models": true
+ },
+ "_meta": {
+ "title": "AILab_Qwen3ASRSubtitle"
+ }
+ },
+ "8": {
+ "class_type": "SaveText",
+ "inputs": {
+ "text": [
+ "7",
+ 1
+ ],
+ "filename_prefix": "fuobe/dub-dbs/segments",
+ "format": "txt"
+ },
+ "_meta": {
+ "title": "SaveText"
+ }
+ },
+ "9": {
+ "class_type": "SaveText",
+ "inputs": {
+ "text": [
+ "7",
+ 0
+ ],
+ "filename_prefix": "fuobe/dub-dbs/transcript",
+ "format": "txt"
+ },
+ "_meta": {
+ "title": "SaveText"
+ }
+ },
+ "10": {
+ "class_type": "PreviewAny",
+ "inputs": {
+ "source": [
+ "7",
+ 2
+ ]
+ },
+ "_meta": {
+ "title": "PreviewAny"
+ }
+ }
+}
diff --git a/scripts/comfy/library.spec.mjs b/scripts/comfy/library.spec.mjs
index 9b6e1c3a..f2406ded 100644
--- a/scripts/comfy/library.spec.mjs
+++ b/scripts/comfy/library.spec.mjs
@@ -2966,6 +2966,42 @@ export const SPEC = [
'Outputs in order: voice stem, background stem (music + effects), cue lines ("start-end: text", seconds), plain transcript, detected language (PreviewAny, folded into the text outputs\' meta). ' +
'ASR runs on the separated vocals. 52 languages auto-detected (30 selectable).',
},
+ // Graph B of docs/research/dbs-separation-7.md §4.4 (DBS D3): the open dub's first step with DBS in place of MelBand
+ // RoFormer, so the background keeps the score and the sound effects (a vocals model takes singing with the voice).
+ // Same output contract as dub-prepare-separate-transcribe; node 7 is that graph's Qwen3-ASR node with its bindings.
+ {
+ id: 'dub-prepare-dbs-transcribe',
+ title: 'Separate the dialogue from the music and effects (DBS) and transcribe it with timestamps (Qwen3-ASR 1.7B)',
+ capability: 'separate-audio',
+ handBuilt: 'hand-built/dub-prepare-dbs-transcribe.json',
+ packs: ['ComfyUI-DBS'],
+ // Both DBS models, as in separate-soundtrack-dbs: a CUDA host runs DBS-TIGER unless asked otherwise.
+ requiredModels: ['DBS-BSRNN-DnR/model.safetensors', 'DBS-BSRNN-DnR/config.json', 'DBS-TIGER-DnR/model.safetensors', 'DBS-TIGER-DnR/config.json'],
+ bindings: {
+ audio: [b('1', 'audio')], separationModel: [b('2', 'model')],
+ sourceLanguage: [b('7', 'language')], asrModel: [b('7', 'model')], hints: [b('7', 'hints')], maxChars: [b('7', 'max_chars')],
+ },
+ outputs: [
+ { node: '5', kind: 'audio', stem: 'voice' },
+ { node: '6', kind: 'audio', stem: 'background' },
+ { node: '8', kind: 'text', role: 'cues' },
+ { node: '9', kind: 'text', role: 'transcript' },
+ { node: '10', kind: 'text', role: 'language' },
+ ],
+ defaults: { separationModel: 'DBS-BSRNN-DnR', sourceLanguage: 'auto', asrModel: 'Qwen/Qwen3-ASR-1.7B-hf' },
+ vramGb: 8,
+ license: 'DBS weights Apache-2.0 (trained on DnR v2, CC BY 4.0); Qwen3-ASR / ForcedAligner Apache-2.0; ComfyUI-QwenASR GPL-3.0; ComfyUI-DBS MIT',
+ autoDownloads: [
+ 'AILab_Qwen3ASRSubtitle downloads Qwen/Qwen3-ASR-1.7B-hf (4.08 GB; 0.6B: 1.56 GB) and Qwen/Qwen3-ForcedAligner-0.6B-hf (1.84 GB) into models/Qwen3-ASR on first run',
+ ],
+ notes:
+ 'Dubbing step 1 with DBS: the voice split runs on a CPU (23 MB of weights) and the background keeps the music and the sound effects, singing included. ' +
+ 'Qwen3-ASR still needs the 8 GB listing on a GPU. audio = an audio file or a video (LoadAudio reads a video\'s soundtrack without decoding frames). ' +
+ 'DBSLoader model DBS-BSRNN-DnR (fast, the CPU default) or DBS-TIGER-DnR (best, the CUDA default); DBSSeparate in mono at the input\'s rate. ' +
+ 'Outputs in order: voice stem (speech), background stem = the original minus the speech (AudioMerge subtract: it keeps the stereo image), cue lines ("start-end: text", seconds), plain transcript, ' +
+ 'detected language (PreviewAny, folded into the text outputs\' meta). Both stems are FLAC, so voice + background add up to the source. ' +
+ 'The provider splits a file with more than 2 channels with its background from music + effects (node 4 rewired to AudioMerge add): ComfyUI saves mono or stereo only. ASR runs on the separated speech.',
+ },
// DBS soundtrack separation (docs/research/dbs-separation-7.md §4.4, graph A): the one graph behind Split soundtrack (and
// Remove dialogue, Clean up dialogue, "Original sound" later). ComfyUI-DBS is not on the validation server: checked
// statically there (core nodes) and validated + run on an isolated worker with the pack and the weights.
diff --git a/scripts/comfy/validation-state.json b/scripts/comfy/validation-state.json
index f6bfb4b9..77833cfd 100644
--- a/scripts/comfy/validation-state.json
+++ b/scripts/comfy/validation-state.json
@@ -53,6 +53,12 @@
"error": null,
"at": "2026-10-16T23:33:15.735Z"
},
+ "dub-prepare-dbs-transcribe": {
+ "sha256": "bbb7b31a35cb858c1f92835b73b13f5dd93de06441637ca57bd40253ab8c7a7d",
+ "validated": true,
+ "error": null,
+ "at": "2026-11-01T14:15:07.842Z"
+ },
"dub-prepare-separate-transcribe": {
"sha256": "9e19d9c940f8e38941e2581fbd8619ccf48ff9dad07edc69941acd7d262aa60f",
"validated": true,
diff --git a/src/app/api/dub/route.ts b/src/app/api/dub/route.ts
index 1590d5da..4a3c4d7a 100644
--- a/src/app/api/dub/route.ts
+++ b/src/app/api/dub/route.ts
@@ -1,6 +1,6 @@
import { connection } from "next/server";
import { z } from "zod";
-import { ONE_SHOT_MODELS } from "@/lib/av/dub";
+import { ONE_SHOT_MODELS, VOICE_SPLIT_IDS, type VoiceSplit } from "@/lib/av/dub";
import { createDubSession, listDubSessions, previewDub } from "@/server/dub";
import { connectRefusal } from "@/server/connect-refusal";
import { priceAs } from "@/server/visitor";
@@ -15,6 +15,8 @@ const Body = z.object({
model: z.enum(ONE_SHOT_MODELS).optional(),
/** The video's length as the browser measured it (seconds). */
duration: z.number().positive().max(36_000).optional(),
+ /** Open engine: the voice split (MelBand RoFormer or DBS). */
+ voiceSplit: z.enum(VOICE_SPLIT_IDS as [VoiceSplit, ...VoiceSplit[]]).optional(),
});
/** Recent dubs with the state of every step. */
diff --git a/src/components/dub/dub-studio.tsx b/src/components/dub/dub-studio.tsx
index bf83af1b..da49a15c 100644
--- a/src/components/dub/dub-studio.tsx
+++ b/src/components/dub/dub-studio.tsx
@@ -21,7 +21,28 @@ import { useEngine, useLikelyVisitor, useModelAccess } from "@/lib/api";
import { isPlaceholder } from "@/lib/demo-mode";
import { keepOffered, offered } from "@/lib/model-access";
import { cueProblems } from "@/lib/av/cue-edit";
-import { BACKGROUND_DB, crowdedLines, dubResult, languageStage, ONE_SHOT_MODELS, priceLine, reviewCues, takeLines, translateKey, voiceOnly, type DubPrice, type DubSessionView, type DubStage, type OneShotModel } from "@/lib/av/dub";
+import {
+ BACKGROUND_DB,
+ crowdedLines,
+ DEFAULT_VOICE_SPLIT,
+ dubResult,
+ languageStage,
+ MUSIC_MODEL_NOTE,
+ ONE_SHOT_MODELS,
+ priceLine,
+ reviewCues,
+ takeLines,
+ translateKey,
+ VOICE_SPLIT_IDS,
+ VOICE_SPLITS,
+ voiceOnly,
+ voiceSplitOf,
+ type DubPrice,
+ type DubSessionView,
+ type DubStage,
+ type OneShotModel,
+ type VoiceSplit,
+} from "@/lib/av/dub";
import { languageByCode, supportsTarget, type DubRoute } from "@/lib/av/languages";
import type { Cue } from "@/lib/cues";
import { cn } from "@/lib/utils";
@@ -34,8 +55,12 @@ const ONE_SHOT: Record<OneShotModel, { name: string; note: string }> = {
"elevenlabs-dubbing": { name: "ElevenLabs Dubbing", note: "Keeps each speaker's voice, no lip re-sync · ≈ $0.60 per minute" },
};
+// The Voice split menu (open engine): what each one does to the soundtrack.
+const SPLIT_LABEL: Record<VoiceSplit, string> = { dbs: "DBS: keeps music and effects, CPU-friendly", melband: "MelBand RoFormer" };
+
const ROUTE_LINE = {
- open: "Open source: MelBand RoFormer splits the voice from the music and Qwen3-ASR times it → an AI translates each line → you review → Chatterbox speaks each line in the cloned voice, at its time → InfiniteTalk re-syncs the lips → mixed back over the music.",
+ open: (split: VoiceSplit) =>
+ `Open source: ${split === "dbs" ? "DBS splits the dialogue from the music and effects" : "MelBand RoFormer splits the voice from the music"} and Qwen3-ASR times it → an AI translates each line → you review → Chatterbox speaks each line in the cloned voice, at its time → InfiniteTalk re-syncs the lips → mixed back over the ${split === "dbs" ? "music and effects" : "music"}.`,
cloud: "Cloud: ElevenLabs isolates the voice and Demucs lifts out the music and effects → Scribe v2 times the voice → Claude (or a local model) translates → you review → ElevenLabs speaks each line at its time and Chatterbox turns it into the speaker's voice → Sync Lipsync 3 → mixed back over the music and effects.",
};
@@ -106,6 +131,11 @@ function NewDub({ onStarted }: { onStarted: (id: string) => void }) {
const access = useModelAccess();
const oneShotModels = keepOffered(ONE_SHOT_MODELS, (m) => offered(access, m, "cloud"));
const model: OneShotModel = oneShotModels.includes(picked) ? picked : oneShotModels[0];
+ // The open engine's voice split: MelBand RoFormer (the default until the separation evaluation says otherwise) or DBS,
+ // either one left out when it's switched off in Settings → Models & licences.
+ const [pickedSplit, setSplit] = useState<VoiceSplit>(DEFAULT_VOICE_SPLIT);
+ const splits = keepOffered(VOICE_SPLIT_IDS, (k) => offered(access, VOICE_SPLITS[k].modelId, "open"));
+ const split: VoiceSplit = splits.includes(pickedSplit) ? pickedSplit : splits[0];
const [source, setSource] = useState("auto");
const [targets, setTargets] = useState<string[]>(["es"]);
const oneShot = mode === "oneshot" && engine === "cloud";
@@ -115,7 +145,10 @@ function NewDub({ onStarted }: { onStarted: (id: string) => void }) {
return l && supportsTarget(route, l);
});
const blocker = !video ? "Add the video to translate" : video.uploading ? "Uploading…" : !usable.length ? "Pick a language to dub into" : null;
- const body = video && !video.uploading && usable.length ? { engine, mode: oneShot ? ("oneshot" as const) : ("steps" as const), model: oneShot ? model : undefined, video: video.ref, source, targets: usable, duration } : null;
+ const body =
+ video && !video.uploading && usable.length
+ ? { engine, mode: oneShot ? ("oneshot" as const) : ("steps" as const), model: oneShot ? model : undefined, video: video.ref, source, targets: usable, duration, ...(engine === "open" && { voiceSplit: split }) }
+ : null;
const price = useDubPrice(body);
const start = () => {
if (visitor) return;
@@ -189,6 +222,36 @@ function NewDub({ onStarted }: { onStarted: (id: string) => void }) {
<p className="text-[12px] text-muted-foreground sm:ml-2">{ONE_SHOT[model].note}</p>
</div>
)}
+ {!oneShot && engine === "open" && (
+ <div className="mt-3 flex flex-col gap-1.5 sm:flex-row sm:items-start">
+ <Label htmlFor="dub-split" className="text-[13px] sm:w-32 sm:pt-2">
+ Voice split
+ </Label>
+ <div className="min-w-0 flex-1">
+ {splits.length > 1 ? (
+ <Select value={split} onValueChange={(v) => setSplit(v as VoiceSplit)}>
+ <SelectTrigger id="dub-split" className="h-9 w-full rounded-full sm:w-80">
+ <SelectValue />
+ </SelectTrigger>
+ <SelectContent>
+ {splits.map((k) => (
+ <SelectItem key={k} value={k}>
+ {SPLIT_LABEL[k]}
+ </SelectItem>
+ ))}
+ </SelectContent>
+ </Select>
+ ) : (
+ <p id="dub-split" className="pt-1.5 text-[13px] font-medium">
+ {VOICE_SPLITS[split].name}
+ </p>
+ )}
+ <p className="mt-1.5 text-[12px] leading-snug text-muted-foreground">{VOICE_SPLITS[split].note}.</p>
+ </div>
+ </div>
+ )}
+ {/* The cloud splits the music and effects with Demucs (no SAM Audio on the cloud: the owner's call). */}
+ {!oneShot && engine === "cloud" && <p className="mt-3 text-[12px] leading-snug text-muted-foreground">Music and effects: Demucs. {MUSIC_MODEL_NOTE}.</p>}
</Panel>
<Panel title="Languages">
<div className="space-y-3">
@@ -214,7 +277,7 @@ function NewDub({ onStarted }: { onStarted: (id: string) => void }) {
</Panel>
<div className="flex flex-col gap-3 pt-1 sm:flex-row sm:items-center">
<p className="flex-1 text-[12px] leading-relaxed text-muted-foreground">
- {oneShot ? `${ONE_SHOT[model].name} returns the finished video for each language.` : engine === "open" ? ROUTE_LINE.open : ROUTE_LINE.cloud}
+ {oneShot ? `${ONE_SHOT[model].name} returns the finished video for each language.` : engine === "open" ? ROUTE_LINE.open(split) : ROUTE_LINE.cloud}
</p>
<div className="flex shrink-0 items-center gap-3 self-end sm:self-auto">
<PriceNote price={price.data} loading={price.isFetching && !price.data} error={price.error as Error | null} hint={oneShot ? undefined : "Translating costs little; you'll see the voice's price before it speaks"} />
@@ -319,7 +382,13 @@ const PREPARE_LABEL: Record<string, string> = { stems: "Voice, background and tr
function prepareRows(s: DubSessionView, lang: string): StepRow[] {
// Older open dubs transcribed in a step of their own.
const keys = Object.keys(s.prepare ?? {}).filter((k) => !k.startsWith("translate:"));
- const label = (k: string) => (k === "stems" && keys.includes("words") ? "Voice and background" : (PREPARE_LABEL[k] ?? k));
+ // An open dub's split names its model (DBS keeps the music and effects; dubs before the setting ran MelBand RoFormer).
+ const stems = s.generations[s.prepare?.stems ?? ""];
+ const split = s.engine === "open" ? (s.voiceSplit ?? voiceSplitOf(stems?.modelId) ?? DEFAULT_VOICE_SPLIT) : undefined;
+ const label = (k: string) => {
+ const base = k === "stems" && keys.includes("words") ? "Voice and background" : (PREPARE_LABEL[k] ?? k);
+ return k === "stems" && split ? `${base} · ${VOICE_SPLITS[split].name}` : base;
+ };
return [...keys.map((k) => ({ key: k, label: label(k), g: s.generations[s.prepare![k]] })), { key: "t", label: `Translate into ${languageByCode(lang)?.name ?? lang}`, g: s.generations[s.prepare?.[translateKey(lang)] ?? ""] }];
}
diff --git a/src/components/dub/hooks.ts b/src/components/dub/hooks.ts
index 374d9816..2c6a74ac 100644
--- a/src/components/dub/hooks.ts
+++ b/src/components/dub/hooks.ts
@@ -3,7 +3,7 @@
import { keepPreviousData, useMutation, useQuery, useQueryClient } from "@tanstack/react-query";
import { useEffect, useState } from "react";
import { useGenerationEvents } from "@/lib/api";
-import type { DubPrice, DubSessionView, OneShotModel } from "@/lib/av/dub";
+import type { DubPrice, DubSessionView, OneShotModel, VoiceSplit } from "@/lib/av/dub";
import type { Cue } from "@/lib/cues";
import type { Engine, Generation } from "@/lib/catalog/types";
import { responseError } from "@/lib/refusals";
@@ -39,6 +39,8 @@ export interface NewDub {
model?: OneShotModel;
/** The video's length as the browser measured it (seconds). */
duration?: number;
+ /** Open engine: the voice split (MelBand RoFormer or DBS). */
+ voiceSplit?: VoiceSplit;
}
/** A value that settles `ms` after it last changed (so prices aren't asked for on every keystroke). */
diff --git a/src/lib/av/dub.ts b/src/lib/av/dub.ts
index 41568f5e..1734f2f9 100644
--- a/src/lib/av/dub.ts
+++ b/src/lib/av/dub.ts
@@ -17,8 +17,10 @@ import { timelineFor } from "./timeline";
* start on a silent track exactly as long as the source (the "timeline" step), so pauses are kept, the
* lip re-sync covers the whole clip and the dubbed video is as long as the original.
*
- * Open engine: MelBand RoFormer splits voice and background and Qwen3-ASR 1.7B times the voice stem, in
- * one job (oss-voice-separate); the local LLM translates the cues (oss-text-llm); Chatterbox Multilingual
+ * Open engine: one job splits voice and background and Qwen3-ASR 1.7B times the voice stem: MelBand RoFormer
+ * (oss-voice-separate, the default) or DBS (oss-dbs-voice-separate: the background keeps the music, the sound effects
+ * and any singing, and the split runs on a CPU), picked by the "Voice split" setting (VOICE_SPLITS); the local LLM
+ * translates the cues (oss-text-llm); Chatterbox Multilingual
* speaks each phrase in the cloned voice; the audio-timeline workflow lays them out; InfiniteTalk
* re-syncs the lips and the mux mixes the voice over the background stem.
* Cloud: ElevenLabs Voice Isolation (the clean voice to clone), Scribe v2 on it (transcript), Claude or
@@ -54,10 +56,38 @@ export const DUB_STEP_MODELS = {
lips: "sync-lipsync-3",
mux: "merge-audio-video",
},
- // The stems step also times the voice (Qwen3-ASR 1.7B + forced aligner inside the same workflow).
+ // The stems step also times the voice (Qwen3-ASR 1.7B + forced aligner inside the same workflow). Its model is the
+ // default voice split's: the "Voice split" setting picks another (VOICE_SPLITS, voiceSplitModel).
open: { stems: "oss-voice-separate", translate: "oss-text-llm", speech: "oss-chatterbox", timeline: "oss-audio-timeline", lips: "oss-infinitetalk-v2v", mux: "oss-mux" },
} as const;
+/**
+ * The open engine's voice split (the dub's first step), the "Voice split" setting. DBS was trained for film-style
+ * dialogue, music and effects, so the background keeps the score, the sound effects and any singing; MelBand RoFormer
+ * is a vocals model (singing goes with the voice and is replaced). MelBand stays the default until the separation
+ * evaluation (DBS D4) says otherwise. Both return the same stems and cues, so nothing after the split changes.
+ */
+/** What a music separation model (MelBand RoFormer, Demucs) does to a film's soundtrack, said beside it. */
+export const MUSIC_MODEL_NOTE = "Music model: some sound effects may be lowered, and singing may be replaced";
+
+export const VOICE_SPLITS = {
+ melband: { modelId: "oss-voice-separate", name: "MelBand RoFormer", note: MUSIC_MODEL_NOTE },
+ dbs: { modelId: "oss-dbs-voice-separate", name: "DBS", note: "Keeps the music and sound effects of the original" },
+} as const;
+export type VoiceSplit = keyof typeof VOICE_SPLITS;
+export const VOICE_SPLIT_IDS = Object.keys(VOICE_SPLITS) as VoiceSplit[];
+export const DEFAULT_VOICE_SPLIT: VoiceSplit = "melband";
+
+/** The open dub's first-step model for a voice split (the default's when none or an unknown one is named). */
+export function voiceSplitModel(split?: string): string {
+ return VOICE_SPLITS[split && split in VOICE_SPLITS ? (split as VoiceSplit) : DEFAULT_VOICE_SPLIT].modelId;
+}
+
+/** The voice split a first-step model stands for (an older dub's, or Assist's model id). */
+export function voiceSplitOf(modelId?: string): VoiceSplit | undefined {
+ return VOICE_SPLIT_IDS.find((k) => VOICE_SPLITS[k].modelId === modelId);
+}
+
/** How far the background (music and effects) sits under its original level once the new voice is on, both engines. */
export const BACKGROUND_DB = -3;
@@ -110,6 +140,8 @@ export interface PrepareInput {
source?: string;
targets: string[];
title?: string;
+ /** Open engine: the voice split (default DEFAULT_VOICE_SPLIT). The cloud ignores it. */
+ voiceSplit?: VoiceSplit;
}
/** Step 1 (both engines): the voice to clone, the timed transcript and one translation per target language. */
@@ -137,7 +169,7 @@ export function prepareSteps(o: PrepareInput): DubStep[] {
// One job splits the stems and times the voice stem (Qwen3-ASR 1.7B); the translations read its cues.
const m = targets.length + 1;
return [
- { key: "stems", request: { ...base, modelId: DUB_STEP_MODELS.open.stems, op: "separate-audio", inputs: { video: o.video }, ...lang, step: step("Voice, background and transcript", 0, m) } },
+ { key: "stems", request: { ...base, modelId: voiceSplitModel(o.voiceSplit), op: "separate-audio", inputs: { video: o.video }, ...lang, step: step("Voice, background and transcript", 0, m) } },
...targets.map((l, i) => translate(l, i + 1, "stems", m)),
];
}
@@ -378,6 +410,8 @@ export interface DubSession {
model?: OneShotModel;
/** Length of the source video (seconds), when known: the dubbed voice track is made this long. */
duration?: number;
+ /** Open engine, step mode: the voice split its first step ran (none on dubs made before the setting: MelBand). */
+ voiceSplit?: VoiceSplit;
batchId: string;
/** Step mode: the prepare pipeline's generation ids by step key. */
prepare?: Record<string, string>;
diff --git a/src/lib/catalog/models.ts b/src/lib/catalog/models.ts
index 5c5fb498..d6f0c15c 100644
--- a/src/lib/catalog/models.ts
+++ b/src/lib/catalog/models.ts
@@ -1404,6 +1404,19 @@ const open: ModelDef[] = [
routes: [comfy("separate-audio", "dub-prepare-separate-transcribe", "voice stem, background stem, timed cues, transcript")],
options: {},
}),
+ // DBS D3: the open dub's first step with DBS for the split (graph B, docs/research/dbs-separation-7.md §4.4): the
+ // background keeps the score, the sound effects and any singing. Translate & dub's "Voice split" picks it.
+ o({
+ id: "oss-dbs-voice-separate",
+ name: "DBS + Qwen3-ASR",
+ vendor: "Open source",
+ family: "dbs",
+ kind: "audio",
+ tagline: "Splits the dialogue from the music and effects (the split runs on a CPU) and transcribes it with timings · 8 GB GPU for the transcript · Apache-2.0",
+ badges: ["new"],
+ routes: [comfy("separate-audio", "dub-prepare-dbs-transcribe", "voice stem, background stem (FLAC), timed cues, transcript; ComfyUI-DBS + ComfyUI-QwenASR")],
+ options: {},
+ }),
// DBS (docs/research/dbs-separation-7.md): dialogue, music and effects from any soundtrack, small enough for a CPU. The
// provider picks the model by the host (DBS-TIGER on CUDA, DBS-BSRNN otherwise) unless one is asked for, and separates
// a file with more than 2 channels in mono (ComfyUI saves mono or stereo only). Split soundtrack (src/lib/av/split.ts) runs on it.
diff --git a/src/server/assist/studio-routes.ts b/src/server/assist/studio-routes.ts
index 871712f0..ae7ba7b5 100644
--- a/src/server/assist/studio-routes.ts
+++ b/src/server/assist/studio-routes.ts
@@ -248,9 +248,9 @@ const ONE_SHOT_NAMES: Record<OneShotModel, string> = { "heygen-translate": "HeyG
* null: a step no provider can run, or a demo step among real ones, which createPipeline refuses (a
* fal key without Claude or a local model: the translation would be a demo while the rest runs for real).
*/
-function prepareProblem(input: Pick<CreateDubInput, "engine" | "video" | "source" | "targets">): string | null {
+function prepareProblem(input: Pick<CreateDubInput, "engine" | "video" | "source" | "targets" | "voiceSplit">): string | null {
const modes: { label: string; needs: string; demo: boolean }[] = [];
- for (const s of prepareSteps({ engine: input.engine, video: input.video, source: input.source, targets: input.targets })) {
+ for (const s of prepareSteps({ engine: input.engine, video: input.video, source: input.source, targets: input.targets, voiceSplit: input.voiceSplit })) {
const m = getModel(s.request.modelId);
if (!m || !s.request.op) continue;
const label = s.request.step?.label ?? s.key;
@@ -282,6 +282,8 @@ function dubJob(i: DubToolInput, ctx: ToolContext): Checked<{ input: CreateDubIn
title: fileTitle(i.video),
source: (i.source_language && dubLanguageFor(i.source_language)?.code) || "auto",
targets: [...new Set(langs.map((l) => l.lang!.code))],
+ // The open engine's voice split (the cloud's step mode ignores it).
+ ...(engine === "open" && i.voice_split && { voiceSplit: i.voice_split }),
};
const steps: CreateDubInput = { ...base, mode: "steps" };
const once: CreateDubInput = { ...base, mode: "oneshot", model: oneShot };
diff --git a/src/server/assist/studio-tools.ts b/src/server/assist/studio-tools.ts
index 7bdc281b..7ab44536 100644
--- a/src/server/assist/studio-tools.ts
+++ b/src/server/assist/studio-tools.ts
@@ -2,6 +2,7 @@ import "server-only";
import { nanoid } from "nanoid";
import { z } from "zod";
import type { PlannedJob } from "@/lib/assist";
+import { VOICE_SPLIT_IDS, voiceSplitModel, type VoiceSplit } from "@/lib/av/dub";
import { getModel } from "@/lib/catalog";
import { routesFor } from "@/lib/catalog/plan";
import { FACELESS_STYLE_IDS, STYLES } from "@/lib/catalog/faceless";
@@ -80,6 +81,12 @@ const DubInput = z.object({
languages: z.array(z.string()).describe("1–4 languages to dub into, e.g. ['Spanish', 'German']."),
lipsync: z.boolean().optional().describe("Re-sync the lips to the new speech (default true)."),
source_language: z.string().optional().describe("The language spoken in the video, if known."),
+ voice_split: z
+ .enum(VOICE_SPLIT_IDS as [VoiceSplit, ...VoiceSplit[]])
+ .optional()
+ .describe(
+ "Open source only: how the voice is split from the rest. melband (default): MelBand RoFormer, a music model (some sound effects may be lowered, and singing may be replaced). dbs: DBS keeps the music and sound effects of the original, and its split runs on a CPU. The cloud splits with ElevenLabs and Demucs either way.",
+ ),
review: z
.boolean()
.optional()
@@ -231,7 +238,7 @@ function dubSteps(i: DubToolInput, ctx: ToolContext): PipelineStep[] {
return labelled(langs.map((l, k) => ({ key: `dub${k}`, label: `Dub · ${l}`, request: req({ modelId: "heygen-translate", op: "dub", inputs: { video: i.video }, params: { targetLanguage: l, sourceLanguage: i.source_language } }) })));
}
const steps: (PipelineStep & { label: string })[] = [
- { key: "stems", label: "Voice and background", request: req({ modelId: "oss-voice-separate", op: "separate-audio", inputs: { video: i.video } }) },
+ { key: "stems", label: "Voice and background", request: req({ modelId: voiceSplitModel(i.voice_split), op: "separate-audio", inputs: { video: i.video } }) },
{ key: "words", label: "Transcript", request: req({ modelId: "oss-qwen3-asr", op: "transcribe", params: { sourceLanguage: i.source_language } }), after: "stems", chain: [{ slot: "audio", stem: "voice" }] },
];
langs.forEach((l, k) => {
diff --git a/src/server/dub.ts b/src/server/dub.ts
index 8cb96e2a..2c728b33 100644
--- a/src/server/dub.ts
+++ b/src/server/dub.ts
@@ -15,6 +15,7 @@ import {
type DubPrice,
type DubSessionView,
type OneShotModel,
+ type VoiceSplit,
} from "@/lib/av/dub";
import { normalizeCues } from "@/lib/av/cue-edit";
import { getModel } from "@/lib/catalog";
@@ -92,6 +93,8 @@ export interface CreateDubInput {
model?: OneShotModel;
/** The video's length as the browser measured it (seconds); the file's header wins when it has one. */
duration?: number;
+ /** Open engine, step mode: the voice split (MelBand RoFormer by default, or DBS). */
+ voiceSplit?: VoiceSplit;
}
/**
@@ -121,6 +124,7 @@ export function createDubSession(input: CreateDubInput): DubSessionView {
source: input.source || "auto",
targets: [...new Set(input.targets)],
...(duration && { duration }),
+ ...(input.engine === "open" && input.mode === "steps" && input.voiceSplit && { voiceSplit: input.voiceSplit }),
batchId: nanoid(10),
createdAt: now,
updatedAt: now,
@@ -141,7 +145,7 @@ export function createDubSession(input: CreateDubInput): DubSessionView {
}
return dubView(save({ ...base, model, oneshot }));
}
- const steps = prepareSteps({ engine: input.engine, video: input.video, source: input.source, targets: base.targets, title });
+ const steps = prepareSteps({ engine: input.engine, video: input.video, source: input.source, targets: base.targets, title, voiceSplit: input.voiceSplit });
const run = createPipeline(steps, { batchId: base.batchId });
const prepare = Object.fromEntries(Object.entries(run.byKey).map(([k, g]) => [k, g.id]));
return dubView(save({ ...base, prepare }));
@@ -214,7 +218,7 @@ export function previewDub(input: CreateDubInput): DubPrice {
const jobs = oneShotRequests({ model: input.model ?? "heygen-translate", video: input.video, source: input.source, targets });
return priceSteps(input.engine, jobs.map((j, i) => ({ key: `dub:${i}`, request: j.request })), seconds);
}
- return priceSteps(input.engine, prepareSteps({ engine: input.engine, video: input.video, source: input.source, targets }), seconds);
+ return priceSteps(input.engine, prepareSteps({ engine: input.engine, video: input.video, source: input.source, targets, voiceSplit: input.voiceSplit }), seconds);
}
/** What voicing one language would cost (POST /api/dub/[id]/voice?preview=1). */
diff --git a/src/server/providers/comfyui.ts b/src/server/providers/comfyui.ts
index 2cbb0cfc..89fa2466 100644
--- a/src/server/providers/comfyui.ts
+++ b/src/server/providers/comfyui.ts
@@ -1423,10 +1423,11 @@ export async function prepareWorkflow(endpointTemplate: string, input: GenInput,
// A Video concatenator clip muted in the canvas (video-fit-clip): its sound becomes silence below.
const muted = manifest.id === "video-fit-clip" && extra.mute === true;
delete extra.mute;
- // DBS (separate-soundtrack-dbs): the model asked for, else the host's pick (DBS-TIGER on a CUDA GPU, DBS-BSRNN on a
- // CPU, the other one when the pick isn't on disk; a model that isn't there is refused in words); "each channel" for
- // stereo stems. A source with more than 2 channels (the header's count, else the browser's) is split in mono with a
- // mono Music & effects (dbsSurroundBed below): ComfyUI can't save more than 2 channels.
+ // DBS (separate-soundtrack-dbs, and the dub's dub-prepare-dbs-transcribe): the model asked for, else the host's pick
+ // (DBS-TIGER on a CUDA GPU, DBS-BSRNN on a CPU, the other one when the pick isn't on disk; a model that isn't there is
+ // refused in words); "each channel" for stereo stems. A source with more than 2 channels (the header's count, else the
+ // browser's) is split in mono with a mono Music & effects (dbsSurroundBed below): ComfyUI can't save more than 2
+ // channels. The dub's graph always splits in mono (no channels binding), so only its bed changes.
if (b.separationModel) {
const [device, installed] = await Promise.all([extra.separationModel ? undefined : ctx.device?.().catch(() => undefined), ctx.dbsModels?.().catch(() => undefined)]);
try {
@@ -1435,7 +1436,7 @@ export async function prepareWorkflow(endpointTemplate: string, input: GenInput,
throw new ProviderError((e as Error).message, 400);
}
}
- const sourceChannels = b.channels ? (ctx.media?.(String(values.audio ?? ""))?.channels ?? (Number(extra.sourceChannels) || undefined)) : undefined;
+ const sourceChannels = b.channels || b.separationModel ? (ctx.media?.(String(values.audio ?? ""))?.channels ?? (Number(extra.sourceChannels) || undefined)) : undefined;
if (b.channels) values.channels = dbsChannelsFor(extra.channels, sourceChannels);
for (const k of ["separationModel", "channels", "sourceChannels"]) delete extra[k];
for (const [k, v] of Object.entries(extra)) values[k as BindingKey] = v;
diff --git a/src/server/recipe-builder.ts b/src/server/recipe-builder.ts
index 9d0e3879..468bc6f0 100644
--- a/src/server/recipe-builder.ts
+++ b/src/server/recipe-builder.ts
@@ -406,7 +406,7 @@ function liftStudio(g: Generation, tool: string, studio: string): Lifted | null
if (tool === "dub_video") {
const rec = recordNaming("dub_sessions", g.id);
if (!rec) return null;
- const d = rec.data as { video?: string; source?: string; targets?: string[]; mode?: string; model?: string; voices?: Record<string, { lipsync?: boolean }[]> };
+ const d = rec.data as { video?: string; source?: string; targets?: string[]; mode?: string; model?: string; voiceSplit?: string; voices?: Record<string, { lipsync?: boolean }[]> };
if (!d.video || !d.targets?.length) return null;
const runs = Object.values(d.voices ?? {}).flat();
const lipsync = d.mode === "oneshot" ? d.model !== "elevenlabs-dubbing" : (runs.at(-1)?.lipsync ?? true);
@@ -416,6 +416,8 @@ function liftStudio(g: Generation, tool: string, studio: string): Lifted | null
...(langName(d.source) && { source_language: langName(d.source) }),
lipsync,
review: d.mode !== "oneshot",
+ // The open engine's voice split, when the dub picked one (DBS or MelBand RoFormer).
+ ...((d.voiceSplit === "dbs" || d.voiceSplit === "melband") && { voice_split: d.voiceSplit }),
};
return { tool, studio, record: `dub:${rec.id}`, input, inputs: [{ path: ["video"], type: "video", label: "Video to dub" }], texts: [] };
}
diff --git a/tests/assist-context.test.ts b/tests/assist-context.test.ts
index c0f287e9..fea03637 100644
--- a/tests/assist-context.test.ts
+++ b/tests/assist-context.test.ts
@@ -275,6 +275,11 @@ describe("studio tools", () => {
expect(steps.find((s) => s.key === "voice1")).toMatchObject({ after: ["tr1", "stems"], chain: [{ slot: "prompt" }, { slot: "voiceAudio", stem: "voice" }] });
expect(steps.find((s) => s.key === "film0")).toMatchObject({ after: ["lips0", "voice0", "stems"], chain: [{ slot: "video" }, { slot: "audio" }, { slot: "audio2", stem: "background" }] });
expect(steps[3].request.step).toMatchObject({ label: "Voice · Spanish", of: 10 });
+ expect(steps[0].request.modelId).toBe("oss-voice-separate");
+ // The Voice split: DBS keeps the music and effects; the rest of the plan is the same.
+ const withDbs = studio.fallbackSteps.dub({ video, languages: ["Spanish", "German"], voice_split: "dbs" }, { engine: "open" });
+ expect(withDbs[0].request.modelId).toBe("oss-dbs-voice-separate");
+ expect(withDbs.slice(1)).toEqual(steps.slice(1));
const noLips = studio.fallbackSteps.dub({ video, languages: ["French"], lipsync: false }, { engine: "open" });
expect(noLips.map((s) => s.request.op)).toEqual(["separate-audio", "transcribe", "translate", "tts", "mux"]);
// Cloud: one HeyGen job per language.
diff --git a/tests/assist-studio-routes.test.ts b/tests/assist-studio-routes.test.ts
index 3813c8a6..4283fed9 100644
--- a/tests/assist-studio-routes.test.ts
+++ b/tests/assist-studio-routes.test.ts
@@ -230,6 +230,22 @@ describe("Translate & dub", () => {
expect(b.next).toMatch(/reviews every line/);
});
+ it("takes the open engine's Voice split: DBS splits the first step, and the dub remembers it", async () => {
+ const b = body(await run("dub_video", { video: clip, languages: ["Spanish"], voice_split: "dbs" }, "open"));
+ const s = dub.getDubSession(b.dub)!;
+ expect(s).toMatchObject({ engine: "open", mode: "steps", voiceSplit: "dbs" });
+ expect(gen(s.prepare!.stems)).toMatchObject({ modelId: "oss-dbs-voice-separate", op: "separate-audio", provider: "mock" });
+ // Unknown splits are refused by the tool's schema (melband or dbs).
+ expect((await run("dub_video", { video: clip, languages: ["Spanish"], voice_split: "sam" }, "open")).isError).toBe(true);
+ // The studio's price check takes it too, and refuses one it doesn't know.
+ const post = (b: unknown) => dubRoute.POST(new Request("http://x/api/dub?preview=1", { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify(b) }));
+ const ok = await post({ engine: "open", mode: "steps", video: clip, targets: ["es"], voiceSplit: "dbs" });
+ expect(ok.status).toBe(200);
+ expect(await ok.json()).toMatchObject({ engine: "open", costUsd: 0, steps: 2 });
+ const bad = await post({ engine: "open", mode: "steps", video: clip, targets: ["es"], voiceSplit: "sam" });
+ expect([bad.status, (await bad.json()).error]).toEqual([400, "Check the dub settings"]);
+ });
+
it("dubs in one go on the cloud when asked, without lip sync", async () => {
const b = body(await run("dub_video", { video: clip, languages: ["French"], review: false, lipsync: false }));
const s = dub.getDubSession(b.dub)!;
diff --git a/tests/av-dub.test.ts b/tests/av-dub.test.ts
index 09789c5f..6d0f848e 100644
--- a/tests/av-dub.test.ts
+++ b/tests/av-dub.test.ts
@@ -4,7 +4,31 @@ import path from "node:path";
import { afterAll, beforeAll, describe, expect, it, vi } from "vitest";
import type { Generation } from "@/lib/catalog/types";
import { cueReducer, cueProblems, formatCueTime, normalizeCues, parseCueTime } from "@/lib/av/cue-edit";
-import { BLANK_FRAME, crowdedLines, linearGain, dubPhrases, languageStage, oneShotRequests, PHRASE_MAX, prepareMedia, prepareSteps, priceLine, reviewCues, spokenText, takeLines, voiceOnly, voiceSteps, type DubSessionView } from "@/lib/av/dub";
+import {
+ BLANK_FRAME,
+ crowdedLines,
+ DEFAULT_VOICE_SPLIT,
+ DUB_STEP_MODELS,
+ linearGain,
+ dubPhrases,
+ languageStage,
+ MUSIC_MODEL_NOTE,
+ OPTIONAL_PREPARE,
+ oneShotRequests,
+ PHRASE_MAX,
+ prepareMedia,
+ prepareSteps,
+ priceLine,
+ reviewCues,
+ spokenText,
+ takeLines,
+ VOICE_SPLITS,
+ voiceOnly,
+ voiceSplitModel,
+ voiceSplitOf,
+ voiceSteps,
+ type DubSessionView,
+} from "@/lib/av/dub";
import { timelineFor, timelineTracks } from "@/lib/av/timeline";
import { DUB_LANGUAGES, supportsTarget } from "@/lib/av/languages";
import { getModel } from "@/lib/catalog";
@@ -95,6 +119,44 @@ describe("dub pipeline DAGs", () => {
]);
});
+ it("open: the Voice split picks the first step's model (MelBand RoFormer by default, or DBS); nothing after it changes", () => {
+ const keys = (steps: ReturnType<typeof prepareSteps>) => steps.map((s) => [s.key, s.request.modelId, s.request.op, s.after ?? null]);
+ const melband = prepareSteps({ engine: "open", video, source: "en", targets: ["es"] });
+ const dbs = prepareSteps({ engine: "open", video, source: "en", targets: ["es"], voiceSplit: "dbs" });
+ expect(DEFAULT_VOICE_SPLIT).toBe("melband");
+ expect(DUB_STEP_MODELS.open.stems).toBe(VOICE_SPLITS.melband.modelId);
+ expect(keys(prepareSteps({ engine: "open", video, source: "en", targets: ["es"], voiceSplit: "melband" }))).toEqual(keys(melband));
+ expect(keys(dbs)).toEqual([
+ ["stems", "oss-dbs-voice-separate", "separate-audio", null],
+ ["translate:es", "oss-text-llm", "translate", "stems"],
+ ]);
+ // Same input, language and step label: only the model id differs.
+ expect({ ...dbs[0].request, modelId: "x" }).toEqual({ ...melband[0].request, modelId: "x" });
+ expect(dbs[1]).toEqual(melband[1]);
+ // Graph B: DBS + Qwen3-ASR in one ComfyUI job.
+ expect(getModel("oss-dbs-voice-separate")!.routes).toEqual([expect.objectContaining({ op: "separate-audio", provider: "comfyui", endpoint: "dub-prepare-dbs-transcribe" })]);
+ expect(getModel("oss-dbs-voice-separate")!.name).toBe("DBS + Qwen3-ASR");
+ expect(voiceSplitModel("dbs")).toBe("oss-dbs-voice-separate");
+ expect(voiceSplitModel("nope")).toBe("oss-voice-separate");
+ expect(voiceSplitModel()).toBe("oss-voice-separate");
+ expect(voiceSplitOf("oss-dbs-voice-separate")).toBe("dbs");
+ expect(voiceSplitOf("oss-voice-separate")).toBe("melband");
+ expect(voiceSplitOf("demucs")).toBeUndefined();
+ expect(VOICE_SPLITS.dbs.note).toBe("Keeps the music and sound effects of the original");
+ expect(VOICE_SPLITS.melband.note).toBe(MUSIC_MODEL_NOTE);
+ });
+
+ it("cloud: the Voice split changes nothing (no SAM Audio on the cloud: Demucs stays, three beds, voice only when it fails)", () => {
+ const keys = (steps: ReturnType<typeof prepareSteps>) => steps.map((s) => [s.key, s.request.modelId, s.after ?? null]);
+ expect(keys(prepareSteps({ engine: "cloud", video, targets: ["fr"], voiceSplit: "dbs" }))).toEqual(keys(prepareSteps({ engine: "cloud", video, targets: ["fr"] })));
+ expect(DUB_STEP_MODELS.cloud).toMatchObject({ sound: "extract-soundtrack", stems: "demucs", voice: "elevenlabs-voice-isolation" });
+ expect([...OPTIONAL_PREPARE]).toEqual(["sound", "background"]);
+ expect(getModel("sam-audio-separate")).toBeUndefined();
+ // Demucs' drums, bass and other: three beds, each lowered, then the mix.
+ const steps = voiceSteps({ engine: "cloud", video, lang: "es", cues: [{ start: 1, end: 2, text: "Hola" }], voiceRef: "/v.mp3", background: ["/a.mp3", "/b.mp3", "/c.mp3"], duration: 10 });
+ expect(steps.filter((s) => s.key.startsWith("bed:")).map((s) => s.request.modelId)).toEqual(["ffmpeg-loudnorm", "ffmpeg-loudnorm", "ffmpeg-loudnorm"]);
+ });
+
// Speech starts at 2 s, pauses at 7–12 s and ends at 26 s of a 30 s clip.
const cues = [
{ start: 2, end: 4, text: "Hola a todos" },
@@ -408,6 +470,36 @@ describe("dub sessions (demo mode)", () => {
expect(new Set(Object.values(dub.dubView(dub.getDubSession(view.id)!).generations).map((g) => g.batchId))).toEqual(new Set([view.batchId]));
});
+ it("open with DBS: the split returns voice, background and cues (demo), the session keeps its split, the dub mixes over the bed", async () => {
+ const s = dub.createDubSession({ engine: "open", mode: "steps", video: clip(), title: "Film", source: "en", targets: ["es"], voiceSplit: "dbs" });
+ expect(s.voiceSplit).toBe("dbs");
+ const split = await settle(s.prepare!.stems);
+ expect(split).toMatchObject({ modelId: "oss-dbs-voice-separate", provider: "mock", status: "succeeded" });
+ expect(split.outputs.map((o) => [o.kind, o.meta?.stem ?? o.meta?.role])).toEqual([
+ ["audio", "voice"],
+ ["audio", "background"],
+ ["text", "cues"],
+ ]);
+ for (const id of Object.values(s.prepare!)) await settle(id);
+ const view = dub.dubView(dub.getDubSession(s.id)!);
+ expect(languageStage(view, "es")).toBe("review");
+ const media = prepareMedia(view);
+ expect(media.voice).toBe(split.outputs[0].url);
+ expect(media.background).toBe(split.outputs[1].url);
+ const voiced = dub.voiceDub(s.id, "es");
+ expect(voiced.generations[voiced.voices!.es[0].ids.film].request.inputs?.audio2).toBe(split.outputs[1].url);
+ // The voice split is open-engine only: a cloud dub, or one shot, keeps none.
+ expect(dub.createDubSession({ engine: "cloud", mode: "steps", video: clip(), targets: ["es"], voiceSplit: "dbs" }).voiceSplit).toBeUndefined();
+ });
+
+ it("prices the open dub's first step free with either voice split", () => {
+ for (const voiceSplit of ["melband", "dbs"] as const) {
+ const p = dub.previewDub({ engine: "open", mode: "steps", video: clip(), targets: ["es"], voiceSplit });
+ expect(p).toMatchObject({ engine: "open", costUsd: 0, steps: 2 });
+ expect(priceLine(p)).toMatch(/^(Placeholder · free|Free on your GPU)$/);
+ }
+ });
+
it("refuses to voice before the translation is ready, and one-shot on the open engine", () => {
const s = dub.createDubSession({ engine: "open", mode: "steps", video: clip(), targets: ["fr"] });
expect(() => dub.voiceDub(s.id, "fr")).toThrow(/isn't ready yet/);
diff --git a/tests/comfy-dbs-dub.test.ts b/tests/comfy-dbs-dub.test.ts
new file mode 100644
index 00000000..88fed3c2
--- /dev/null
+++ b/tests/comfy-dbs-dub.test.ts
@@ -0,0 +1,137 @@
+import fs from "node:fs";
+import os from "node:os";
+import path from "node:path";
+import { afterAll, describe, expect, it } from "vitest";
+import type { GenInput } from "@/lib/catalog/types";
+import type { ComfyWorkflow, Manifest, ManifestWorkflow } from "@/lib/comfy";
+import { licenceInfo, workflowLicence } from "@/lib/licences";
+import type { DbsModel } from "@/lib/av/split";
+import type { MediaInfo } from "@/lib/media-probe";
+
+// DBS D3: graph B (dub-prepare-dbs-transcribe), the open dub's first step with DBS in place of MelBand RoFormer. Same
+// output contract and ASR bindings as dub-prepare-separate-transcribe, so the dub only changes its model id.
+const tmp = fs.mkdtempSync(path.join(os.tmpdir(), "fuobe-comfy-dbs-dub-"));
+process.env.FUOBE_DATA_DIR = tmp;
+process.env.COMFYUI_URL = "http://comfy.test:8188";
+const { collectOutputs, prepareWorkflow } = await import("@/server/providers/comfyui");
+afterAll(() => fs.rmSync(tmp, { recursive: true, force: true }));
+
+const root = path.resolve(__dirname, "..");
+const lib = (f: string) => JSON.parse(fs.readFileSync(path.join(root, "workflows/comfyui", f), "utf8"));
+const manifest = lib("manifest.json") as Manifest;
+const entryOf = (id: string) => manifest.workflows.find((w) => w.id === id) as ManifestWorkflow;
+const dbs = entryOf("dub-prepare-dbs-transcribe");
+const melband = entryOf("dub-prepare-separate-transcribe");
+const graphA = lib("separate-soundtrack-dbs.json") as ComfyWorkflow;
+const graph = lib("dub-prepare-dbs-transcribe.json") as ComfyWorkflow;
+const old = lib("dub-prepare-separate-transcribe.json") as ComfyWorkflow;
+
+describe("dub-prepare-dbs-transcribe in the manifest", () => {
+ it("has the MelBand graph's outputs: voice and background stems, cues, transcript and language", () => {
+ expect(dbs).toMatchObject({ capability: "separate-audio", vramGb: 8, validated: true });
+ expect(dbs.outputs).toEqual(melband.outputs);
+ expect(dbs.outputs.map((o) => o.stem ?? o.role)).toEqual(["voice", "background", "cues", "transcript", "language"]);
+ });
+
+ it("has its bindings (sourceLanguage, asrModel, hints, maxChars on node 7), plus the DBS model", () => {
+ const { separationModel, filenamePrefix, ...rest } = dbs.bindings;
+ const { filenamePrefix: oldPrefix, ...oldRest } = melband.bindings;
+ expect(rest).toEqual(oldRest);
+ expect(separationModel).toEqual([{ node: "2", input: "model" }]);
+ expect(filenamePrefix?.map((b) => b.node)).toEqual(oldPrefix?.map((b) => b.node));
+ expect(dbs.defaults).toMatchObject({ separationModel: "DBS-BSRNN-DnR", sourceLanguage: "auto", asrModel: "Qwen/Qwen3-ASR-1.7B-hf" });
+ expect(dbs.autoDownloads).toEqual(melband.autoDownloads);
+ });
+
+ it("names both packs and both DBS models, and records the licences as information", () => {
+ expect(dbs.customNodes?.map((c) => c.name)).toEqual(["ComfyUI-DBS", "ComfyUI-QwenASR"]);
+ expect(dbs.models.map((m) => [m.file, m.folder])).toEqual(entryOf("separate-soundtrack-dbs").models.map((m) => [m.file, m.folder]));
+ expect(dbs.models.every((m) => typeof m.sizeGb === "number")).toBe(true);
+ expect(dbs.license).toBe("DBS weights Apache-2.0 (trained on DnR v2, CC BY 4.0); Qwen3-ASR / ForcedAligner Apache-2.0; ComfyUI-QwenASR GPL-3.0; ComfyUI-DBS MIT");
+ expect(licenceInfo(workflowLicence(dbs)).name).toBeTruthy();
+ });
+
+ it("is in the GPU pre-flight's requirement index with both packs and the DBS files", () => {
+ const idx = lib("requirements.json");
+ expect(idx.workflows["dub-prepare-dbs-transcribe"]).toMatchObject({
+ packs: { "ComfyUI-DBS": ["DBSLoader", "DBSSeparate"], "ComfyUI-QwenASR": ["AILab_Qwen3ASRSubtitle"] },
+ files: ["dbs/DBS-BSRNN-DnR/config.json", "dbs/DBS-BSRNN-DnR/model.safetensors", "dbs/DBS-TIGER-DnR/config.json", "dbs/DBS-TIGER-DnR/model.safetensors"],
+ vramGb: 8,
+ });
+ });
+});
+
+describe("graph B", () => {
+ it("splits like graph A in mono at the input's rate: the speech is the voice stem, the original minus the speech the background (FLAC)", () => {
+ expect(Object.fromEntries(Object.entries(graph).map(([id, n]) => [id, n.class_type]))).toEqual({
+ "1": "LoadAudio",
+ "2": "DBSLoader",
+ "3": "DBSSeparate",
+ "4": "AudioMerge",
+ "5": "SaveAudioAdvanced",
+ "6": "SaveAudioAdvanced",
+ "7": "AILab_Qwen3ASRSubtitle",
+ "8": "SaveText",
+ "9": "SaveText",
+ "10": "PreviewAny",
+ });
+ for (const id of ["2", "3", "4"]) expect(graph[id].inputs).toEqual(graphA[id].inputs);
+ expect(graph["3"].inputs).toMatchObject({ channels: "mono", output_sample_rate: "input" });
+ expect([graph["5"].inputs.audio, graph["6"].inputs.audio]).toEqual([["3", 2], ["4", 0]]);
+ expect([graph["5"].inputs.format, graph["6"].inputs.format]).toEqual(["flac", "flac"]);
+ });
+
+ it("transcribes the speech with the MelBand graph's Qwen3-ASR node, its settings unchanged", () => {
+ const { audio, ...settings } = graph["7"].inputs;
+ const { audio: oldAudio, ...oldSettings } = old["7"].inputs;
+ expect(audio).toEqual(["3", 2]);
+ expect(oldAudio).toEqual(["4", 0]);
+ expect(settings).toEqual(oldSettings);
+ for (const id of ["8", "9", "10"]) expect(Object.keys(graph[id].inputs)).toEqual(Object.keys(old[id].inputs));
+ expect([graph["8"].inputs.text, graph["9"].inputs.text, graph["10"].inputs.source]).toEqual([["7", 1], ["7", 0], ["7", 2]]);
+ });
+});
+
+describe("the provider fills graph B", () => {
+ async function prepare(input: GenInput, opts: { device?: string; media?: Record<string, MediaInfo>; installed?: DbsModel[] } = {}) {
+ const res = await prepareWorkflow("dub-prepare-dbs-transcribe", { seed: 1, ...input }, {
+ generationId: "gen1",
+ op: "separate-audio",
+ upload: async (_d, _t, name) => `up_${name}`,
+ media: (name) => opts.media?.[name],
+ device: async () => opts.device,
+ dbsModels: async () => opts.installed,
+ });
+ return res.workflow;
+ }
+
+ it("reads the video's soundtrack, picks the DBS model by the host and fills the ASR settings", async () => {
+ const cpu = await prepare({ video: "clip.mp4", extra: { asrModel: "Qwen/Qwen3-ASR-0.6B-hf" } }, { device: "cpu" });
+ expect(cpu["1"].inputs.audio).toBe("clip.mp4");
+ expect(cpu["2"].inputs.model).toBe("DBS-BSRNN-DnR");
+ expect(cpu["7"].inputs.model).toBe("Qwen/Qwen3-ASR-0.6B-hf");
+ expect(["5", "6", "8", "9"].map((id) => cpu[id].inputs.filename_prefix)).toEqual(Array(4).fill("fuobe/gen1"));
+ expect((await prepare({ video: "clip.mp4" }, { device: "cuda" }))["2"].inputs.model).toBe("DBS-TIGER-DnR");
+ await expect(prepare({ video: "clip.mp4", extra: { separationModel: "DBS-TIGER-DnR" } }, { installed: ["DBS-BSRNN-DnR"] })).rejects.toThrow(/isn't installed on your ComfyUI/);
+ });
+
+ it("makes a surround source's background from music + effects (ComfyUI saves mono or stereo only)", async () => {
+ expect((await prepare({ video: "clip.mp4" }))["4"].inputs).toEqual({ audio1: ["1", 0], audio2: ["3", 2], merge_method: "subtract" });
+ const surround: MediaInfo = { container: "mp4", duration: 10, hasVideo: true, hasAudio: true, channels: 6 };
+ const wf = await prepare({ video: "clip.mp4" }, { media: { "clip.mp4": surround } });
+ expect(wf["3"].inputs.channels).toBe("mono");
+ expect(wf["4"].inputs).toEqual({ audio1: ["3", 0], audio2: ["3", 1], merge_method: "add" });
+ expect(JSON.stringify(wf)).not.toContain("sourceChannels");
+ });
+
+ it("returns the stems voice first, then the cues and the transcript", () => {
+ const flac = (n: string) => ({ audio: [{ filename: `gen1_${n}.flac`, subfolder: "fuobe", type: "output" }] });
+ const outs = collectOutputs(
+ { outputs: { "6": flac("6"), "5": flac("5"), "8": { text: ["0.00-1.20: Hello there"] }, "9": { text: ["Hello there"] }, "10": { text: ["English"] } } } as never,
+ dbs,
+ "http://comfy.test:8188",
+ );
+ expect(outs.filter((o) => o.kind === "audio").map((o) => o.meta?.stem)).toEqual(["voice", "background"]);
+ expect(outs.some((o) => o.kind === "text")).toBe(true);
+ });
+});
diff --git a/tests/recipe-builder.test.ts b/tests/recipe-builder.test.ts
index 73489c88..2edd6259 100644
--- a/tests/recipe-builder.test.ts
+++ b/tests/recipe-builder.test.ts
@@ -217,6 +217,12 @@ describe("draftFromGenerations", () => {
expect(refusals).toEqual([]);
expect(draft!.recipe.steps).toEqual([expect.objectContaining({ kind: "tool", tool: "dub_video", input: { video: clip, languages: ["Spanish", "German"], source_language: "English", lipsync: false, review: true } })]);
expect(draft!.candidates.filter((c) => c.kind === "media")).toEqual([expect.objectContaining({ type: "video", example: clip, at: [{ step: draft!.recipe.steps[0].key, path: ["video"] }] })]);
+ // An open dub that picked its Voice split keeps it in the recipe.
+ row({ id: "dub-film-dbs", feature: "dub", kind: "video", op: "mux", request: { feature: "dub", modelId: "oss-mux", op: "mux" }, outputs: [{ url: clip, kind: "video" }] });
+ db()
+ .prepare("INSERT INTO dub_sessions (id, data_json, created_at, updated_at) VALUES (?, ?, ?, ?)")
+ .run("dub2", JSON.stringify({ title: "talk", engine: "open", mode: "steps", video: clip, source: "en", targets: ["es"], voiceSplit: "dbs", batchId: "b2", prepare: { stems: "y" }, voices: { es: [{ ids: { film: "dub-film-dbs" }, at: now, lipsync: true }] } }), now, now);
+ expect(builder.draftFromGenerations(["dub-film-dbs"]).draft!.recipe.steps[0]).toMatchObject({ tool: "dub_video", input: { languages: ["Spanish"], voice_split: "dbs", review: true } });
row({ id: "cinema-1", feature: "cinema", kind: "video", request: { feature: "cinema", modelId: "fuobe-cinema", op: "t2v", prompt: "a chase" } });
row({ id: "dub-orphan", feature: "dub", kind: "video", request: { feature: "dub", modelId: "oss-mux", op: "mux" } });
diff --git a/workflows/comfyui/dub-prepare-dbs-transcribe.json b/workflows/comfyui/dub-prepare-dbs-transcribe.json
new file mode 100644
index 00000000..e2e25fc0
--- /dev/null
+++ b/workflows/comfyui/dub-prepare-dbs-transcribe.json
@@ -0,0 +1,151 @@
+{
+ "1": {
+ "class_type": "LoadAudio",
+ "inputs": {
+ "audio": "input.wav"
+ },
+ "_meta": {
+ "title": "Speech to dub (audio, or a video with sound)"
+ }
+ },
+ "2": {
+ "class_type": "DBSLoader",
+ "inputs": {
+ "model": "DBS-BSRNN-DnR",
+ "device": "auto"
+ },
+ "_meta": {
+ "title": "DBS Loader"
+ }
+ },
+ "3": {
+ "class_type": "DBSSeparate",
+ "inputs": {
+ "model": [
+ "2",
+ 0
+ ],
+ "audio": [
+ "1",
+ 0
+ ],
+ "channels": "mono",
+ "output_sample_rate": "input"
+ },
+ "_meta": {
+ "title": "DBS Separate (music / sfx / speech)"
+ }
+ },
+ "4": {
+ "class_type": "AudioMerge",
+ "inputs": {
+ "audio1": [
+ "1",
+ 0
+ ],
+ "audio2": [
+ "3",
+ 2
+ ],
+ "merge_method": "subtract"
+ },
+ "_meta": {
+ "title": "Background: the original minus the speech"
+ }
+ },
+ "5": {
+ "class_type": "SaveAudioAdvanced",
+ "inputs": {
+ "audio": [
+ "3",
+ 2
+ ],
+ "filename_prefix": "fuobe/dub-prepare-dbs-transcribe",
+ "format": "flac"
+ },
+ "_meta": {
+ "title": "Voice stem (the speech to clone)"
+ }
+ },
+ "6": {
+ "class_type": "SaveAudioAdvanced",
+ "inputs": {
+ "audio": [
+ "4",
+ 0
+ ],
+ "filename_prefix": "fuobe/dub-prepare-dbs-transcribe",
+ "format": "flac"
+ },
+ "_meta": {
+ "title": "Background stem (music & effects)"
+ }
+ },
+ "7": {
+ "class_type": "AILab_Qwen3ASRSubtitle",
+ "inputs": {
+ "audio": [
+ "3",
+ 2
+ ],
+ "model": "Qwen/Qwen3-ASR-1.7B-hf",
+ "precision": "bf16",
+ "attention": "auto",
+ "forced_aligner": "Qwen/Qwen3-ForcedAligner-0.6B-hf",
+ "language": "auto",
+ "hints": "",
+ "output_format": "none",
+ "output_path": "",
+ "split_mode": "split_by_punctuation_or_pause",
+ "max_gap_sec": 0.6,
+ "max_chars": 40,
+ "max_inference_batch_size": 32,
+ "max_new_tokens": 256,
+ "normalize_text": true,
+ "unload_models": true
+ },
+ "_meta": {
+ "title": "AILab_Qwen3ASRSubtitle"
+ }
+ },
+ "8": {
+ "class_type": "SaveText",
+ "inputs": {
+ "text": [
+ "7",
+ 1
+ ],
+ "filename_prefix": "fuobe/dub-prepare-dbs-transcribe",
+ "format": "txt"
+ },
+ "_meta": {
+ "title": "SaveText"
+ }
+ },
+ "9": {
+ "class_type": "SaveText",
+ "inputs": {
+ "text": [
+ "7",
+ 0
+ ],
+ "filename_prefix": "fuobe/dub-prepare-dbs-transcribe",
+ "format": "txt"
+ },
+ "_meta": {
+ "title": "SaveText"
+ }
+ },
+ "10": {
+ "class_type": "PreviewAny",
+ "inputs": {
+ "source": [
+ "7",
+ 2
+ ]
+ },
+ "_meta": {
+ "title": "PreviewAny"
+ }
+ }
+}
diff --git a/workflows/comfyui/manifest.json b/workflows/comfyui/manifest.json
index 4aebe904..c8ee018e 100644
--- a/workflows/comfyui/manifest.json
+++ b/workflows/comfyui/manifest.json
@@ -13391,6 +13391,146 @@
"AILab_Qwen3ASRSubtitle downloads Qwen/Qwen3-ASR-1.7B-hf (4.08 GB; 0.6B: 1.56 GB) and Qwen/Qwen3-ForcedAligner-0.6B-hf (1.84 GB) into models/Qwen3-ASR on first run"
]
},
+ {
+ "id": "dub-prepare-dbs-transcribe",
+ "title": "Separate the dialogue from the music and effects (DBS) and transcribe it with timestamps (Qwen3-ASR 1.7B)",
+ "capability": "separate-audio",
+ "file": "dub-prepare-dbs-transcribe.json",
+ "source": "hand-built (scripts/comfy/hand-built/dub-prepare-dbs-transcribe.json)",
+ "bindings": {
+ "audio": [
+ {
+ "node": "1",
+ "input": "audio"
+ }
+ ],
+ "separationModel": [
+ {
+ "node": "2",
+ "input": "model"
+ }
+ ],
+ "sourceLanguage": [
+ {
+ "node": "7",
+ "input": "language"
+ }
+ ],
+ "asrModel": [
+ {
+ "node": "7",
+ "input": "model"
+ }
+ ],
+ "hints": [
+ {
+ "node": "7",
+ "input": "hints"
+ }
+ ],
+ "maxChars": [
+ {
+ "node": "7",
+ "input": "max_chars"
+ }
+ ],
+ "filenamePrefix": [
+ {
+ "node": "5",
+ "input": "filename_prefix"
+ },
+ {
+ "node": "6",
+ "input": "filename_prefix"
+ },
+ {
+ "node": "8",
+ "input": "filename_prefix"
+ },
+ {
+ "node": "9",
+ "input": "filename_prefix"
+ }
+ ]
+ },
+ "outputs": [
+ {
+ "node": "5",
+ "kind": "audio",
+ "stem": "voice"
+ },
+ {
+ "node": "6",
+ "kind": "audio",
+ "stem": "background"
+ },
+ {
+ "node": "8",
+ "kind": "text",
+ "role": "cues"
+ },
+ {
+ "node": "9",
+ "kind": "text",
+ "role": "transcript"
+ },
+ {
+ "node": "10",
+ "kind": "text",
+ "role": "language"
+ }
+ ],
+ "defaults": {
+ "maxChars": 40,
+ "separationModel": "DBS-BSRNN-DnR",
+ "sourceLanguage": "auto",
+ "asrModel": "Qwen/Qwen3-ASR-1.7B-hf"
+ },
+ "limits": {},
+ "models": [
+ {
+ "file": "DBS-BSRNN-DnR/model.safetensors",
+ "folder": "dbs",
+ "url": "https://huggingface.co/JusperLee/DBS-BSRNN-DnR/resolve/5af343f57f106fbb95efe8a60f1a3999eeb0aef8/model.safetensors",
+ "sizeGb": 0.02
+ },
+ {
+ "file": "DBS-BSRNN-DnR/config.json",
+ "folder": "dbs",
+ "url": "https://huggingface.co/JusperLee/DBS-BSRNN-DnR/resolve/5af343f57f106fbb95efe8a60f1a3999eeb0aef8/config.json",
+ "sizeGb": 0
+ },
+ {
+ "file": "DBS-TIGER-DnR/model.safetensors",
+ "folder": "dbs",
+ "url": "https://huggingface.co/JusperLee/DBS-TIGER-DnR/resolve/22da7d4cd3ea63f9365181008bff1c0d2ab6fb2b/model.safetensors",
+ "sizeGb": 0.004
+ },
+ {
+ "file": "DBS-TIGER-DnR/config.json",
+ "folder": "dbs",
+ "url": "https://huggingface.co/JusperLee/DBS-TIGER-DnR/resolve/22da7d4cd3ea63f9365181008bff1c0d2ab6fb2b/config.json",
+ "sizeGb": 0
+ }
+ ],
+ "customNodes": [
+ {
+ "name": "ComfyUI-DBS",
+ "repo": "https://github.com/hiroki-abe-58/ComfyUI-DBS/tree/f656e53434b5485c148a2866fbd6ddc6b6152ed6"
+ },
+ {
+ "name": "ComfyUI-QwenASR",
+ "repo": "https://github.com/1038lab/ComfyUI-QwenASR"
+ }
+ ],
+ "vramGb": 8,
+ "license": "DBS weights Apache-2.0 (trained on DnR v2, CC BY 4.0); Qwen3-ASR / ForcedAligner Apache-2.0; ComfyUI-QwenASR GPL-3.0; ComfyUI-DBS MIT",
+ "validated": true,
+ "notes": "Dubbing step 1 with DBS: the voice split runs on a CPU (23 MB of weights) and the background keeps the music and the sound effects, singing included. Qwen3-ASR still needs the 8 GB listing on a GPU. audio = an audio file or a video (LoadAudio reads a video's soundtrack without decoding frames). DBSLoader model DBS-BSRNN-DnR (fast, the CPU default) or DBS-TIGER-DnR (best, the CUDA default); DBSSeparate in mono at the input's rate. Outputs in order: voice stem (speech), background stem = the original minus the speech (AudioMerge subtract: it keeps the stereo image), cue lines (\"start-end: text\", seconds), plain transcript, detected language (PreviewAny, folded into the text outputs' meta). Both stems are FLAC, so voice + background add up to the source. The provider splits a file with more than 2 channels with its background from music + effects (node 4 rewired to AudioMerge add): ComfyUI saves mono or stereo only. ASR runs on the separated speech.",
+ "autoDownloads": [
+ "AILab_Qwen3ASRSubtitle downloads Qwen/Qwen3-ASR-1.7B-hf (4.08 GB; 0.6B: 1.56 GB) and Qwen/Qwen3-ForcedAligner-0.6B-hf (1.84 GB) into models/Qwen3-ASR on first run"
+ ]
+ },
{
"id": "separate-soundtrack-dbs",
"title": "Split a soundtrack into dialogue, music and effects (DBS, ComfyUI-DBS)",
diff --git a/workflows/comfyui/requirements.json b/workflows/comfyui/requirements.json
index 029bbab7..10244ad5 100644
--- a/workflows/comfyui/requirements.json
+++ b/workflows/comfyui/requirements.json
@@ -1,6 +1,6 @@
{
"v": 1,
- "hash": "5b5d1c8c168a84339d23a853f8a40c40e7de647a9d7619813f0db19c4c014f08",
+ "hash": "d5fa3d00d0118c84cbb4cbbb6e7ae38252d9936847956bd11ea2b114dcee591e",
"comfyui": {"min":"0.42.0","testedCommit":"5841c187"},
"folders": ["audio_encoders","background_removal","checkpoints","clip_vision","dbs","diffusion_models","facerestore_models","foley","frame_interpolation","geometry_estimation","insightface","latent_upscale_models","loras","mmaudio","model_patches","optical_flow","text_encoders","thinksound","upscale_models","vae"],
"sentinels": ["AILab_Qwen3ASRSubtitle","AUSBOSS_NODES_CropForInpaint","AUSBOSS_NODES_ImageCropRotatePad","AUSBOSS_NODES_StitchInpaint","Add Subtitles To Frames","Apply Whisper","CFGOverride","ClothesSegment","ComfyMathExpression","DBSLoader","DBSSeparate","DownloadAndLoadWav2VecModel","DualModelGuider","FL_ChatterboxDialogTTS","FL_ChatterboxMultilingualTTS","FL_ChatterboxVC","GetImageRangeFromBatch","GetImageSizeAndCount","GrowMaskWithBlur","H3AdaLNLoRAFix","H3CharacterSwapAssemble","H3CharacterSwapController","H3CharacterSwapExpandMask","H3CharacterSwapModels","H3CharacterSwapPrepareVideo","H3CharacterSwapRecoverMasks","H3CharacterSwapSelectSubject","H3CharacterSwapSettings","H3CharacterSwapShot","H3CharacterSwapWindowPlan","H3RelayAppendWindow","H3RelayApplyEditMask","H3RelayApplyHistory","H3RelayExpandMask","H3RelayFinishWindows","H3RelayPrepareSource","H3RelayRecoverMasks","H3RelayReviewWindows","H3RelaySamplingMemory","H3RelaySelectMask","H3RelayTextMemory","H3RelayWindowInputs","H3RelayWindowPlan","H3SLAAttention","HunyuanDependenciesLoader","HunyuanFoleySampler","HunyuanModelLoader","INTConstant","Ideogram4Scheduler","ImageBatchExtendWithOverlap","ImageGridtoBatch","ImageResizeKJv2","IndexTTS2Simple","Krea2EditGroundedEncode","Krea2EditModelPatch","Krea2OstrisEditModelPatch","LTXAVTextEncoderLoader","LTXVAddGuide","LTXVAudioVAEDecode","LTXVAudioVAELoader","LTXVConcatAVLatent","LTXVConditioning","LTXVCropGuides","LTXVDualCFGGuider","LTXVEmptyLatentAudio","LTXVImgToVideoInplace","LTXVLatentUpsampler","LTXVPreprocess","LTXVScheduler","LTXVSeparateAVLatent","LatentSyncNode","LoadBackgroundRemovalModel","LoadVideoDepthAnythingModel","MMAudioFeatureUtilsLoader","MMAudioModelLoader","MMAudioSampler","MelBandRoFormerModelLoader","MelBandRoFormerSampler","MiniMaxH3TurboLoRA","MiniMaxH3TurboSampler","MultiTalkModelLoader","MultiTalkWav2VecEmbeds","QwenImage21Cache","RIFE VFI","RMBG","ReActorFaceSwap","RemoveBackground","SAM3_Detect","SAM3_TrackToMask","SAM3_VideoTrack","SeedVR2Conditioning","SeedVR2PostProcessing","SeedVR2Preprocess","TS_ImageToSVGStringColor_Vtracer","TS_SVGStringToSVGBytesIO","TextEncodeFibo2","TextEncodeKrea2OstrisEdit","TextEncodeQwenImage21","ThinkSoundFeatureUtilsLoader","ThinkSoundModelLoader","ThinkSoundSampler","Trellis2Conditioning","Trellis2ShapeStage","Trellis2TextureStage","Trellis2UpsampleStage","VHS_BatchManager","VHS_LoadAudioUpload","VHS_LoadVideo","VHS_SelectEveryNthImage","VHS_VideoCombine","VHS_VideoInfo","VHS_VideoInfoLoaded","VideoDepthAnythingOutput","VideoDepthAnythingProcess","VideoLengthAdjuster","WanVideoBlockSwap","WanVideoClipVisionEncode","WanVideoDecode","WanVideoEncode","WanVideoImageToVideoMultiTalk","WanVideoLoraSelect","WanVideoModelLoader","WanVideoPassImagesFromSamples","WanVideoSampler","WanVideoTextEncodeCached","WanVideoVAELoader"],
@@ -225,6 +225,7 @@
"captions-qwen3-asr": {"core":["LoadAudio","PreviewAny","SaveText"],"packs":{"ComfyUI-QwenASR":["AILab_Qwen3ASRSubtitle"]},"files":[],"optional":[],"vramGb":4,"isolated":false,"firstRun":["AILab_Qwen3ASRSubtitle downloads Qwen/Qwen3-ASR-0.6B-hf (1.56 GB) and Qwen/Qwen3-ForcedAligner-0.6B-hf (1.84 GB) into models/Qwen3-ASR on first run"],"validated":true},
"captions-whisper-burnin": {"core":["SaveText"],"packs":{"ComfyUI-VideoHelperSuite":["VHS_LoadVideo","VHS_VideoCombine","VHS_VideoInfoLoaded"],"ComfyUI-Whisper":["Add Subtitles To Frames","Apply Whisper"]},"files":[],"optional":[],"vramGb":6,"isolated":false,"firstRun":["Apply Whisper downloads large-v3-turbo.pt (1.62 GB) into models/stt/whisper on first run"],"validated":true},
"draw-to-video-wan-move": {"core":["CLIPLoader","CLIPTextEncode","CLIPVisionEncode","CLIPVisionLoader","CreateVideo","ImageScale","KSampler","LoadImage","LoraLoaderModelOnly","ModelSamplingSD3","PrimitiveStringMultiline","SaveVideo","UNETLoader","VAEDecode","VAELoader","WanMoveTrackToVideo","WanMoveTracksFromCoords"],"packs":{},"files":["clip_vision/clip_vision_h.safetensors","diffusion_models/Wan21-WanMove_fp8_scaled_e4m3fn_KJ.safetensors","loras/lightx2v_I2V_14B_480p_cfg_step_distill_rank64_bf16.safetensors","text_encoders/umt5_xxl_fp8_e4m3fn_scaled.safetensors","vae/wan_2.1_vae.safetensors"],"optional":[],"vramGb":24,"isolated":false,"firstRun":[],"validated":true},
+ "dub-prepare-dbs-transcribe": {"core":["AudioMerge","LoadAudio","PreviewAny","SaveAudioAdvanced","SaveText"],"packs":{"ComfyUI-DBS":["DBSLoader","DBSSeparate"],"ComfyUI-QwenASR":["AILab_Qwen3ASRSubtitle"]},"files":["dbs/DBS-BSRNN-DnR/config.json","dbs/DBS-BSRNN-DnR/model.safetensors","dbs/DBS-TIGER-DnR/config.json","dbs/DBS-TIGER-DnR/model.safetensors"],"optional":[],"vramGb":8,"isolated":false,"firstRun":["AILab_Qwen3ASRSubtitle downloads Qwen/Qwen3-ASR-1.7B-hf (4.08 GB; 0.6B: 1.56 GB) and Qwen/Qwen3-ForcedAligner-0.6B-hf (1.84 GB) into models/Qwen3-ASR on first run"],"validated":true},
"dub-prepare-separate-transcribe": {"core":["LoadAudio","PreviewAny","SaveAudioMP3","SaveText"],"packs":{"ComfyUI-MelBandRoFormer":["MelBandRoFormerModelLoader","MelBandRoFormerSampler"],"ComfyUI-QwenASR":["AILab_Qwen3ASRSubtitle"]},"files":["diffusion_models/MelBandRoformer_fp16.safetensors"],"optional":[],"vramGb":8,"isolated":false,"firstRun":["AILab_Qwen3ASRSubtitle downloads Qwen/Qwen3-ASR-1.7B-hf (4.08 GB; 0.6B: 1.56 GB) and Qwen/Qwen3-ForcedAligner-0.6B-hf (1.84 GB) into models/Qwen3-ASR on first run"],"validated":true},
"face-swap-reactor": {"core":["LoadImage","SaveImage"],"packs":{"ComfyUI-ReActor":["ReActorFaceSwap"]},"files":["facerestore_models/GFPGANv1.4.pth","insightface/inswapper_128.onnx"],"optional":[],"vramGb":4,"isolated":false,"firstRun":["insightface buffalo_l face analysis models -> models/insightface/models/buffalo_l (downloaded by ReActor on first run)","retinaface_resnet50 detector -> models/facedetection (downloaded on first run)"],"validated":true},
"fibo2-dev-edit": {"core":["CLIPLoader","KSampler","LoadImage","ResizeImageMaskNode","SaveImage","TextEncodeFibo2","UNETLoader","VAEDecode","VAELoader"],"packs":{},"files":["diffusion_models/fibo2_dev_int8_convrot.safetensors","text_encoders/qwen3vl_4b_int8_convrot.safetensors","vae/flux2-vae.safetensors"],"optional":[],"vramGb":16,"isolated":false,"firstRun":[]},