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.
TypeScript ai-videocomfyuicreative-toolsgenerative-aiideogramimage-generationimage-to-3dimage-to-videoltx-videominimax-h3nextjsopen-sourceopen-weightsqwen-imagetext-to-imagevideo-generationwan
MiniMax H3 at 2K: a Fast · Pika Flex take drafts on Flex's graph and finishes from its clip
Claude6490062467ba
diff --git a/src/lib/catalog/regenerate.ts b/src/lib/catalog/regenerate.tsindex d5d07460..cd062bb8 100644--- a/src/lib/catalog/regenerate.ts+++ b/src/lib/catalog/regenerate.ts@@ -296,11 +296,12 @@ export const H3_TURBO_4STEP_INFO = {* words, near the draft (sigma 0.8) with the 768p preset. Text to video drafts on the graph that keeps its latent (unless* `keepLatent` is false: its Turbo 4-step LoRA is switched off), and the finish may start from that latent: the server* decides when it starts (the draft's latent must be on the ComfyUI the finish runs on). Otherwise, and for a take from a- * start frame, the finish redraws the draft's clip.+ * start frame, the finish redraws the draft's clip. Quality → Fast · Pika Flex keeps its own 6-step graph for the draft+ * (the graph that keeps a latent loads the Turbo 4-step LoRA, not Pika's adapter), so its finish redraws the clip too.*/export function h3TwoKRequests(original: GenerationRequest, op: string, o: { keepLatent?: boolean } = {}): { draft: GenerationRequest; finish: GenerationRequest; fromLatent: boolean } {- const fromLatent = op === "t2v" && o.keepLatent !== false;const params = original.params ?? {};+ const fromLatent = op === "t2v" && o.keepLatent !== false && params.extra?.quality !== "flex";const draft: GenerationRequest = {...original,op: op as GenerationRequest["op"],diff --git a/src/lib/comfy-variants.ts b/src/lib/comfy-variants.tsindex c0345fec..fb66da71 100644--- a/src/lib/comfy-variants.ts+++ b/src/lib/comfy-variants.ts@@ -103,6 +103,7 @@ export function resolveWorkflowId(endpointTemplate: string, r: VariantRequest):const small = tier === "fast" || tier === "trim" ? tierGraphFor(endpoint, tier, r.has) : undefined;const flex = H3_FLEX_GRAPH[endpoint];const latentDraft = H3_LATENT_DRAFT_GRAPH[endpoint];+ // The 2K tier's text-to-video draft that keeps its latent (never a Flex take's: h3TwoKRequests drafts that on Flex's graph).if (latentDraft && r.extra.latentDraft === true && r.has(latentDraft)) endpoint = latentDraft;else if (orbit && r.extra.orbit === true && r.has(orbit)) endpoint = orbit;else if (flex && r.extra.quality === "flex" && r.has(flex)) endpoint = flex;diff --git a/tests/regenerate-more-api.test.ts b/tests/regenerate-more-api.test.tsindex 8b70084b..e8775732 100644--- a/tests/regenerate-more-api.test.ts+++ b/tests/regenerate-more-api.test.ts@@ -165,6 +165,25 @@ describe("MiniMax H3 at 2K on your GPU", () => {expect(gens.createGenerations({ feature: "video", modelId: "oss-minimax-h3", op: "t2v", prompt: "x", params: { resolution: "768p", duration: 5 } })).toHaveLength(1);});+ it("drafts a Fast · Pika Flex take on Flex's graph with Pika's adapter, and finishes it from its clip", async () => {+ const { pikaFlexGraphLoras, PIKA_FLEX_FL2VA } = await import("@/lib/catalog/pika-flex");+ const asked: GenerationRequest = { feature: "video", modelId: "oss-minimax-h3", op: "t2v", prompt: "A lighthouse in a storm", params: { resolution: "2K", duration: 5, extra: { quality: "flex" } } };+ const { draft, fromLatent } = R.h3TwoKRequests(asked, "t2v", { keepLatent: true });+ expect(fromLatent).toBe(false);+ const extra = draft.params!.extra!;+ expect(extra).toEqual({ quality: "flex" });+ const req = { op: "t2v", clips: 0, images: 0, audio2: false, extra, has: () => true };+ expect(resolveWorkflowId("minimax-h3-t2v", req)).toBe("minimax-h3-flex-t2v");+ // The run downloads (or an account's GPU is checked for) the adapter the graph loads, never the Turbo 4-step LoRA.+ expect(pikaFlexGraphLoras("minimax-h3-t2v", extra)).toEqual([PIKA_FLEX_FL2VA]);+ expect(R.regenerateGraphLoras("minimax-h3-t2v", extra)).toEqual([]);+ const [f, d] = gens.createGenerations(asked);+ expect(d.request.params).toMatchObject({ resolution: "768p", extra: { quality: "flex" } });+ expect(d.request.params?.extra?.latentDraft).toBeUndefined();+ expect(f.request.params?.extra).toMatchObject({ draftFrom: "h3" });+ expect(f.request.params?.extra?.latentFrom).toBeUndefined();+ });+it("offers 2K in Cinema only for MiniMax H3 models, and says how your GPU makes it", () => {for (const id of ["minimax-h3", "oss-minimax-h3", "minimax-h3-max"]) expect(videoResolutionsFor(getModel(id)), id).toContain("2K");for (const id of ["fuobe-cinema", "kling-4", "seedance-2-5", "oss-ltx25", "oss-wan22-14b", "veo-3-1"]) expect(videoResolutionsFor(getModel(id)), id).toEqual(["480p", "720p", "1080p"]);