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
Image tools: edits run on Qwen-Image 2.1, Krea 2 and FIBO 2
Adarsh244bed92d02c
diff --git a/src/components/fashion/fashion-view.tsx b/src/components/fashion/fashion-view.tsxindex f0e4c9c1..96de99a3 100644--- a/src/components/fashion/fashion-view.tsx+++ b/src/components/fashion/fashion-view.tsx@@ -28,15 +28,16 @@ const LABELS = ["Select a template", "Character", "Generation", "Clothing", "Phoconst BANNER_KEY = "fuobe.fashion.banner";/*** The outfit and photoset models' names (FASHION_MODELS has each step's per engine): Fuobe Try-On (the Original, FLUX.2- * [klein] 4B + a try-on LoRA) and the Qwen edit models first, partners after.+ * [klein] 4B + a try-on LoRA), the Qwen-Image and Krea 2 edit models, partners after.*/const MODEL_LABELS: Record<string, string> = {"fuobe-tryon": "Fuobe Try-On","fashn-tryon": "FASHN Try-On","nano-banana-pro": "Nano Banana Pro","qwen-image-edit-2511-cloud": "Qwen-Image-Edit 2511",- "oss-qwen-edit": "Qwen-Image-Edit 2511","oss-qwen-image-21": "Qwen-Image 2.1",+ "oss-qwen-image-21-turbo": "Qwen-Image 2.1 Turbo",+ "oss-krea2-identity-edit": "Krea 2 Identity Edit",};const bannerListeners = new Set<() => void>();diff --git a/src/components/influencer/influencer-builder.tsx b/src/components/influencer/influencer-builder.tsxindex d69ef954..96aef81f 100644--- a/src/components/influencer/influencer-builder.tsx+++ b/src/components/influencer/influencer-builder.tsx@@ -406,7 +406,7 @@ export function InfluencerBuilder() {</div>) : (<p className="text-[12.5px] text-muted-foreground">- {visitor ? "Fuobe Soul" : "Fuobe Soul on your GPU"}: Z-Image Turbo draws the sheet in Soul's Realistic look (the Soul Cast sheet workflow); with a photo or clothing, Qwen-Image-Edit 2511 then puts them on it.+ {visitor ? "Fuobe Soul" : "Fuobe Soul on your GPU"}: Z-Image Turbo draws the sheet in Soul's Realistic look (the Soul Cast sheet workflow); with a photo or clothing, Qwen-Image 2.1 then puts them on it.{!visitor && (<>{" "}diff --git a/src/components/katana/katana-studio.tsx b/src/components/katana/katana-studio.tsxindex 1d49c358..07bf8413 100644--- a/src/components/katana/katana-studio.tsx+++ b/src/components/katana/katana-studio.tsx@@ -21,7 +21,7 @@ import { Panel, ToolHero, ToolShell } from "@/components/av/tool-shell";import { SelfHostNote } from "@/components/self-host-note";import { useEngine, useLikelyVisitor, useModelAccess } from "@/lib/api";import { formatCueTime } from "@/lib/av/cue-edit";-import { detectCutIndices, KATANA_LIMITS, katanaProgress, katanaStage, motionModel, MOTION_MODELS, nearestAspect, planSegments, refineCut, refineTimes, type KatanaJobView, type Segment } from "@/lib/av/katana";+import { detectCutIndices, KATANA_LIMITS, katanaProgress, katanaStage, motionModel, MOTION_MODELS, nearestAspect, OPEN_KEYFRAME_PHOTOS, planSegments, refineCut, refineTimes, type KatanaJobView, type Segment } from "@/lib/av/katana";import { keepOffered, offered } from "@/lib/model-access";import { cn } from "@/lib/utils";import { toastError } from "@/lib/refusals";@@ -246,7 +246,7 @@ export function KatanaStudio() {<p className="mt-2 flex items-start gap-1.5 text-[12px] text-muted-foreground"><Users className="mt-0.5 size-3.5 shrink-0" /> A person, a product or an outfit. Clear, well-lit photos from a couple of angles work best.</p>- {engine === "open" && <p className="mt-1 text-[12px] text-muted-foreground">The open engine uses your first 2 photos (Qwen-Image-Edit takes the frame and two references).</p>}+ {engine === "open" && <p className="mt-1 text-[12px] text-muted-foreground">The open engine uses your first {OPEN_KEYFRAME_PHOTOS} photos (Qwen-Image 2.1 Turbo takes the frame and {OPEN_KEYFRAME_PHOTOS} references).</p>}</Panel><Panel title="Instructions (optional)"><Textareadiff --git a/src/components/mixed-media/mixed-studio.tsx b/src/components/mixed-media/mixed-studio.tsxindex 75aec366..e5e1fe99 100644--- a/src/components/mixed-media/mixed-studio.tsx+++ b/src/components/mixed-media/mixed-studio.tsx@@ -161,14 +161,14 @@ function How({ onStart, cloud, visitor }: { onStart: () => void; cloud: boolean;A render is counted in frames: seconds × frame rate, rounded down (10 s at 8 FPS = 80 frames; at most 10 s × 24 FPS = 240). Fuobe Mixed Media draws everyframe again in the look — Z-Image Turbo following the frame's own outlines, with the look's LoRA and one seed — free{" "}{visitor ? "when you run Fuobe yourself" : "on your GPU"}- {cloud ? ", or on the cloud at about a cent a frame. Nano Banana 2 and Seedream 5.0 Flash redraw frames too, priced per frame." : "."} Smooth draws only the+ {cloud ? ", or on the cloud at about a cent a frame. Nano Banana 2.1 and Seedream 5.0 Flash redraw frames too, priced per frame." : "."} Smooth draws only thefirst frame in the look, then Wan 2.2 Fun VACE carries it through the clip by depth{cloud ? ", priced per second. Fast restyles the clip in one video-to-video pass, priced by the model" : ""}.The estimate shows before you generate.</p><p className="mt-2">Over {FRAME_LIMITS.perClip} frames, the frames go back together as clips and are joined.{cloud &&- ` Nano Banana 2 and Seedream redraw frames in runs of ${FRAME_LIMITS.lane} side by side, each frame matching the one before it and each run starting from your preview frame, so their look can shift slightly every ${FRAME_LIMITS.lane} frames.`}{" "}+ ` Nano Banana 2.1 and Seedream redraw frames in runs of ${FRAME_LIMITS.lane} side by side, each frame matching the one before it and each run starting from your preview frame, so their look can shift slightly every ${FRAME_LIMITS.lane} frames.`}{" "}If a frame fails, the frames still waiting stop, and Try again redraws only the frames that didn’t finish.</p></div>diff --git a/src/components/moodboards/logic.ts b/src/components/moodboards/logic.tsindex edccc6c0..272a4bc0 100644--- a/src/components/moodboards/logic.ts+++ b/src/components/moodboards/logic.ts@@ -122,7 +122,7 @@ export const STATUS_LABEL: Record<MoodboardStatus, string> = {};export const COVER_PROMPT = (name: string) =>- `A moodboard cover for “${name}”: one striking image that sums up this style — its palette, light, texture, grain and mood. No text.`;+ `A moodboard cover for “${name}”: one striking, purely visual image that sums up this style — its palette, light, texture, grain and mood.`;/** What stops a board from being saved, in Higgsfield's words, or null. */export function moodboardError(b: { name: string; images: string[] }): string | null {diff --git a/src/components/photodump/photodump-view.tsx b/src/components/photodump/photodump-view.tsxindex 6cbd635b..e4718e05 100644--- a/src/components/photodump/photodump-view.tsx+++ b/src/components/photodump/photodump-view.tsx@@ -30,10 +30,12 @@ const STEPS = ["Choose a Pack", "Add your photo", "Get your photos"];const MODEL_NAMES: Record<string, string> = {"fuobe-soul": "Fuobe Soul + Soul ID","nano-banana-pro": "Nano Banana Pro",+ "nano-banana-2-1": "Nano Banana 2.1","seedream-5-pro": "Seedream 5.0 Pro","qwen-image-edit-2511-cloud": "Qwen-Image-Edit 2511",- "oss-qwen-edit": "Qwen-Image-Edit 2511","oss-qwen-image-21": "Qwen-Image 2.1",+ "oss-qwen-image-21-turbo": "Qwen-Image 2.1 Turbo",+ "oss-krea2-identity-edit": "Krea 2 Identity Edit",};const TABS = [["all", "All"],@@ -365,7 +367,7 @@ export function PhotodumpView() {</div><div className="space-y-2"><p className="text-[12.5px] font-medium">Aspect ratio</p>- {/* A model that keeps the photo's shape (Qwen-Image-Edit) ignores the aspect ratio: the picker is off and the run line says why. */}+ {/* A model that keeps the photo's shape (Qwen-Image 2.1's edit) ignores the aspect ratio: the picker is off and the run line says why. */}<div role="radiogroup" aria-label="Aspect ratio" aria-disabled={fixedAspect || undefined} onKeyDown={radioKeys} className="flex flex-wrap gap-1">{PHOTODUMP_ASPECTS.map((a) => (<buttondiff --git a/src/components/shorts/shorts-studio.tsx b/src/components/shorts/shorts-studio.tsxindex fa4126d9..9c65aa19 100644--- a/src/components/shorts/shorts-studio.tsx+++ b/src/components/shorts/shorts-studio.tsx@@ -518,7 +518,7 @@ function SetupPanel({{model && (<p className="text-[12px] leading-snug text-muted-foreground">{engine === "open"- ? "Each ≤5 s segment: its first frame is restyled with Qwen-Image-Edit, then Wan 2.2 Fun VACE follows it and the clip's depth."+ ? "Each ≤5 s segment: its first frame is restyled with Qwen-Image 2.1 Turbo, then Wan 2.2 Fun VACE follows it and the clip's depth.": model.id === SHORTS_ORIGINAL? "Fuobe Original · each segment's first frame is drawn in the look (Qwen-Image-Edit 2511), then Wan 2.2 Fun VACE carries it through every frame by depth, on open weights hosted by fal.": model.tagline}diff --git a/src/lib/av/katana.ts b/src/lib/av/katana.tsindex dcefd187..f9c0cc16 100644--- a/src/lib/av/katana.ts+++ b/src/lib/av/katana.ts@@ -41,7 +41,10 @@ export const MOTION_MODELS: Record<Engine, MotionModel[]> = {],};-export const KEYFRAME_MODEL: Record<Engine, string> = { cloud: "nano-banana-pro", open: "oss-qwen-edit" };+/** The keyframe edit: Nano Banana Pro in the cloud; on your GPU Qwen-Image 2.1 Turbo (8 steps, up to 4 images). */+export const KEYFRAME_MODEL: Record<Engine, string> = { cloud: "nano-banana-pro", open: "oss-qwen-image-21-turbo" };+/** Your photos the open keyframe edit takes beside the frame (Qwen-Image 2.1 Turbo: the frame and three photos). */+export const OPEN_KEYFRAME_PHOTOS = 3;/** Katana's earlier open motion model, now Fuobe Genjutsu's Original (a saved job or an API call may still name it). */export const RETIRED_MOTION_MODELS: Record<string, string> = { "oss-wan22-animate": "fuobe-genjutsu-motion" };@@ -230,8 +233,8 @@ export function katanaSteps(o: KatanaInput): KatanaStep[] {// The keyframe a few frames in on the open engine (frame accurate); the cloud tool takes the first frame.const pick = o.engine === "open" ? { at: KEYFRAME_OFFSET } : ("first" as const);steps.push({ key: `frame${i}`, after: `cut${i}`, chain: [{ slot: "video" }], request: { ...base, modelId: FRAME_MODEL[o.engine], op: "frame", params: frameParams(o.engine, pick), step: label("first frame") } });- // Your subject in that frame (Qwen-Image-Edit takes up to 3 images: the frame and two photos).- const photos = o.engine === "open" ? o.photos.slice(0, 2) : o.photos;+ // Your subject in that frame (Qwen-Image 2.1 Turbo takes up to 4 images: the frame and three photos).+ const photos = o.engine === "open" ? o.photos.slice(0, OPEN_KEYFRAME_PHOTOS) : o.photos;steps.push({ key: `key${i}`, after: `frame${i}`, chain: [{ slot: "images", position: "first" }], request: { ...base, modelId: KEYFRAME_MODEL[o.engine], op: "edit", prompt: keyframePrompt(o.instructions, photos.length), inputs: { images: photos }, step: label("your subject") } });// Open models render as long as they're told (Wan Fun Control defaults to 81 frames ≈ 5 s): ask for the segment's length.// The engine is named: a Fuobe Original (Genjutsu's motion) runs on both.diff --git a/src/lib/catalog/apps.ts b/src/lib/catalog/apps.tsindex 977f9940..8b102cf5 100644--- a/src/lib/catalog/apps.ts+++ b/src/lib/catalog/apps.ts@@ -21,14 +21,15 @@ const VIDEO_OPEN: PresetRoute = { modelId: "oss-wan22-14b", op: "i2v", params: {const FLF_CLOUD: PresetRoute = { ...VIDEO_CLOUD, op: "flf2v" };const FLF_OPEN: PresetRoute = { ...VIDEO_OPEN, op: "flf2v" };/** Portrait + voice → talking video. */-const AVATAR_CLOUD: PresetRoute = { modelId: "kling-avatar", op: "avatar" };+const AVATAR_CLOUD: PresetRoute = { modelId: "kling-avatar-2", op: "avatar" };const AVATAR_OPEN: PresetRoute = { modelId: "oss-infinitetalk", op: "avatar" };-/** Character image + driving video → video (open source only). */+/** Character image + driving video → video on your GPU. */const ANIMATE_OPEN: PresetRoute = { modelId: "oss-wan22-animate", op: "motion-transfer" };const BG_CLOUD: PresetRoute = { modelId: "birefnet-cloud", op: "bg-remove" };const BG_OPEN: PresetRoute = { modelId: "oss-rmbg", op: "bg-remove" };const UPSCALE_CLOUD: PresetRoute = { modelId: "topaz-image", op: "upscale-image" };-const UPSCALE_OPEN: PresetRoute = { modelId: "oss-upscale-image", op: "upscale-image" };+/** SeedVR2 (image) restores detail as it enlarges (4x ESRGAN stays in the Upscale studio's list). */+const UPSCALE_OPEN: PresetRoute = { modelId: "oss-seedvr2-image", op: "upscale-image" };/*** Qwen-Image 2.1's expand: Qwen3-VL describes the picture on its grown canvas, and the words only add what goes in the* new margins. They never name the subject (it would appear again there), so the apps send their own short hint.@@ -191,7 +192,7 @@ export const APPS: Preset[] = []),],prompt:- "Give the portrait {option:level}. Make the skin look like a high-end editorial photograph shot on a sharp lens — real texture, no plastic smoothing, no makeup changes. Keep the face shape, identity, expression, hair, lighting and background exactly the same.",+ "Give the portrait {option:level}. Make the skin look like a high-end editorial photograph shot on a sharp lens, with real, natural skin texture and the same makeup. Keep the face shape, identity, expression, hair, lighting and background exactly the same.",}),app({name: "Age Shift",@@ -539,7 +540,7 @@ export const APPS: Preset[] = []),],prompt:- "Expand this image outward into {option:ratio}, continuing the scene naturally beyond every edge with matching perspective, lighting, textures and grain. Keep the original content untouched and add no new people or text.",+ "Expand this image outward into {option:ratio}, continuing the scene naturally beyond every edge with matching perspective, lighting, textures and grain. Keep the original content untouched, and fill the new area with more of the same surroundings.",open: OUTPAINT_OPEN,parity: "Set the matching aspect ratio in settings for an exact canvas size.",}),@@ -935,7 +936,7 @@ export const APPS: Preset[] = [second("Outfit reference", "A photo of someone wearing the outfit you want"),],prompt:- "Take the complete outfit worn in the second image — every garment, shoes and accessories, with their exact colors, fabrics, prints and fit — and put it on the person in the first image. Keep the first person's face, hair, body shape, pose, lighting and background unchanged; do not copy the second person's face or body.",+ "Take the complete outfit worn in the second image — every garment, shoes and accessories, with their exact colors, fabrics, prints and fit — and put it on the person in the first image. Keep the first person's face, hair, body shape, pose, lighting and background unchanged; only the clothing comes from the second image.",}),app({name: "AI Stylist",@@ -1209,7 +1210,7 @@ export const APPS: Preset[] = [["Glitch", "a digital glitch with RGB split and pixel tearing jumps from the first shot to the second"],]),],- prompt: "Seamless transition: {option:fx}. Continuous camera motion, no cuts, both shots keep their exact content.",+ prompt: "Seamless transition: {option:fx}. One continuous shot, the camera moving throughout; both shots keep their exact content.",cloud: FLF_CLOUD,open: FLF_OPEN,parity: "Makes the transition between two stills: the first shot and the second.",@@ -1787,7 +1788,7 @@ export const APPS: Preset[] = [hue: 95,inputs: [{ key: "image", label: "Opening frame", hint: "The first frame of your video", accept: "image", required: true }],prompt:- "Rework this opening frame into a scroll-stopping hook thumbnail: stronger contrast and color, clearer focal point on the face or product, a more expressive moment and bold composition. Keep the same people, product and setting; add no text.",+ "Rework this opening frame into a scroll-stopping hook thumbnail: stronger contrast and color, clearer focal point on the face or product, a more expressive moment and bold composition. Keep the same people, product and setting in a clean, purely photographic frame.",}),app({// Named for what it does: it takes out logos and recognizable IP (Fuobe has no detector to score similarity).diff --git a/src/lib/catalog/character-swap.ts b/src/lib/catalog/character-swap.tsindex 537f613c..c831bb9c 100644--- a/src/lib/catalog/character-swap.ts+++ b/src/lib/catalog/character-swap.ts@@ -375,12 +375,12 @@ export function swapPrompt(p: SwapPromptInput): string {export function anchorPrompt(o: Pick<CharacterOptions, "who" | "index" | "subject" | "description">): string {const description = tidy(o.description).slice(0, CHARACTER_SWAP.maxDescriptionChars);if (!description) {- return "Replace the person in image 1 with the character from image 2, including their face, hair, body and complete outfit exactly as shown in image 2. Do not keep any of the original person's clothing. Keep image 1's pose, framing, background and lighting.";+ return "Replace the person in image 1 with the character from image 2, including their face, hair, body and complete outfit exactly as shown in image 2: every garment they wear comes from image 2. Keep image 1's pose, framing, background and lighting.";}return (`Image 1 is the source frame to edit. Image 2 is character identity only: ${description}. Replace ONLY ${whoWords(o)} with that single character. ` +"Match the exact source pose, face angle, gaze, mouth opening, expression, limb placement, scale and occlusions. Preserve all other people, the entire original scene, camera framing, lighting and aspect ratio. " +- "Keep the reference identity and costume; do not copy the reference pose or background. One full-aspect edited source frame."+ "Take only the identity and costume from the reference; the pose and background come from the source frame. One full-aspect edited source frame.");}@@ -393,7 +393,7 @@ export const ANCHOR_MODELS: Record<Engine, { id: string; label: string; note: st],open: [{ id: "oss-qwen-image-21", label: "Qwen-Image 2.1", note: "Free on your GPU (20 GB)" },- { id: "oss-qwen-edit", label: "Qwen-Image-Edit 2511", note: "Free on your GPU (24 GB)" },+ { id: "oss-krea2-identity-edit", label: "Krea 2 Identity Edit", note: "Free on your GPU (20 GB)" },],};diff --git a/src/lib/catalog/dop.ts b/src/lib/catalog/dop.tsindex bf8fe091..f5e4913c 100644--- a/src/lib/catalog/dop.ts+++ b/src/lib/catalog/dop.ts@@ -10,7 +10,8 @@* - LTX-2.5 LoRAs (Slow Motion, Car Jump) run on the user's GPU only: fal has no LTX-2.5 LoRA endpoint, so the* cloud runs the preset's words. Focus Change is LTX-2.5's own focus_shift move, hosted (LTX-2.5 Fast).* - Effects that are a grade (15) animate without a LoRA, then the grade is applied in the browser; the relight- * effects (6) relight the start frame first (Qwen-Image-Edit 2509 + its Relight LoRA), then animate it.+ * effects (6) relight the start frame first (Qwen-Image 2.1 Turbo on the user's GPU, hosted Qwen-Image-Edit 2509 + its+ * Relight LoRA in the cloud), then animate it.* - Licences are information: a LoRA licensed for the user's GPU only (civitai "RentCivit") goes to the cloud route* too, unless Settings → Models & licences keeps such LoRAs on the GPU (fitLoras then leaves it out, saying so); a* non-commercial LoRA or one whose licence the research holds is used and said in the preset's line.@@ -33,11 +34,18 @@ export const DOP_LTX_MODEL = "fuobe-dop-ltx";const LTX25_OPEN = "oss-ltx25";/** LTX-2.5's camera_motion on fal's fast endpoint (Focus Change's focus_shift): open weights, hosted, no LoRAs. */export const LTX25_HOSTED = "ltx-2-5-fast";-/** The relight step before the clip: Qwen-Image-Edit 2509 + the Relight LoRA (the open graph has it built in). */-export const RELIGHT_OPEN = "oss-qwen-relight";+/**+ * The relight step before the clip. On the user's GPU Qwen-Image 2.1 Turbo relights from plain words in its own picture+ * tags (the wording the relight effects' covers were made with); in the cloud hosted Qwen-Image-Edit 2509 + the Relight+ * LoRA, with the LoRA's trigger.+ */+export const RELIGHT_OPEN = "oss-qwen-image-21-turbo";export const RELIGHT_CLOUD = "qwen-image-edit-2509-cloud";-/** The Relight LoRA's trigger ("relight"): the open graph prefixes it itself. */+/** The Relight LoRA's trigger ("relight"). */const RELIGHT_TRIGGER = "重新照明";+/** Qwen-Image 2.1's relight instruction for a light (its text encoder names the start frame <image1>). */+export const relightWords = (light: string): string =>+ `Relight <image1>: ${light}. Keep every person, face, pose, object, the setting and the framing exactly as in <image1>, same film grain.`;/** The Original's models (both engines). */export const DOP_MODELS = new Set([DOP_MODEL, DOP_LTX_MODEL]);@@ -100,7 +108,7 @@ export const DOP_GRADES: Record<string, string> = {"effect-sodium-decay": "sodium-decay",};-/** What the relight effects ask of the Relight LoRA (Fuobe's words for each light). */+/** The light each relight effect asks for (Fuobe's words for each light). */const RELIGHT_LIGHT: Record<string, string> = {"effect-silhouette": "strong backlight behind the subject, the subject nearly a dark silhouette with a glowing rim","effect-practicals": "lit only by warm practical lamps in the scene, warm pools of light and moody falloff",@@ -216,7 +224,7 @@ export function dopPreset(p: Preset): Preset {const relightLora = relight ? all.find((l) => l.family === "edit")?.ref : undefined;if (light && relightLora) {extras.prestep = {- open: { modelId: RELIGHT_OPEN, op: "edit", prompt: light },+ open: { modelId: RELIGHT_OPEN, op: "edit", prompt: relightWords(light) },cloud: { modelId: RELIGHT_CLOUD, op: "edit", prompt: `${RELIGHT_TRIGGER}, ${light}`, loras: [relightLora] },};}@@ -272,7 +280,7 @@ export function dopPreset(p: Preset): Preset {// Fuobe Mixed Media is Z-Image Turbo + ControlNet, with the look's LoRA when the map has one.parity = `Fuobe Mixed Media draws your still as ${mixedLook.name} first, then Fuobe DoP animates it, on your GPU and in the cloud. For a whole clip restyled frame by frame, use Mixed Media.`;} else if (extras.prestep) {- // The relight is Qwen-Image-Edit 2509 with its Relight LoRA.+ // The relight is Qwen-Image 2.1 Turbo on your GPU, Qwen-Image-Edit 2509 with its Relight LoRA in the cloud.parity = "Fuobe DoP relights your still first, then animates it.";} else if (status === "mixed-media-route") parity = `${p.parity ? `${sentence(p.parity)} ` : ""}For a whole clip restyled frame by frame, use Mixed Media.`;else if (!cloudSays && local.length) parity = `On your GPU, Fuobe DoP ${openSays}. ${its(local)} licensed for your GPU only, so in the cloud it runs on a partner model.`;diff --git a/src/lib/catalog/evolution.ts b/src/lib/catalog/evolution.tsindex 6662c930..6ce67747 100644--- a/src/lib/catalog/evolution.ts+++ b/src/lib/catalog/evolution.ts@@ -4,10 +4,10 @@* much of the clip stays. Research: docs/research/fuobe-originals-recipes-5.md §8 evolution and its JSON twin* (studios[evolution].original); what Higgsfield's does: higgsfield-originals-5.md §3.20.*- * - On your GPU: per ≤81-frame segment at 16 fps, Qwen-Image-Edit takes the segment's first frame toward the direction- * (the first references as images 2–3), then Wan 2.2 Fun VACE re-renders the segment from the segment itself, noised- * to the intensity's denoise, with depth control and that frame as its reference (video-evolution-wan22-fun-vace, which- * also loads a whole clip at 16 fps when Edit video sends one).+ * - On your GPU: per ≤81-frame segment at 16 fps, Qwen-Image 2.1 Turbo takes the segment's first frame toward the+ * direction (the first references as images 2–4), then Wan 2.2 Fun VACE re-renders the segment from the segment+ * itself, noised to the intensity's denoise, with depth control and that frame as its reference+ * (video-evolution-wan22-fun-vace, which also loads a whole clip at 16 fps when Edit video sends one).* - In the cloud: LTX-2.3 22B video to video on fal, video_strength = 1 − denoise, the direction as the scene; a clip* over 20 s runs as equal pieces. The endpoint takes no images: there the references shape the direction only.* - Then the pieces are joined and the clip's own sound put back.@@ -31,12 +31,12 @@ export const EVOLUTION = {promptChars: 1500,/** LTX-2.3 makes at most 481 frames a call: 20 s at 24 fps. */cloudPieceSeconds: 20,- /** Qwen-Image-Edit takes the frame plus two references. */- openReferences: 2,+ /** Qwen-Image 2.1 Turbo takes the frame plus three references. */+ openReferences: 3,/** The LLM sees this many references (Claude reads up to 20 images a turn; a local vision model fewer). */llmReferences: { cloud: 8, open: 4 } as Record<Engine, number>,- /** Helper on the GPU: the segment's first frame taken toward the direction. */- frameModel: "oss-qwen-edit",+ /** Helper on the GPU: the segment's first frame taken toward the direction (Qwen-Image 2.1 Turbo, 8 steps). */+ frameModel: "oss-qwen-image-21-turbo",maxBytes: 500 * 1024 * 1024,accept: "video/mp4,video/quicktime,video/webm,.mp4,.mov,.m4v,.webm",} as const;@@ -137,11 +137,17 @@ const FRAME_VERB: Record<Intensity, string> = {high: "Reimagine image 1 boldly in this direction",};-/** On the GPU: Qwen-Image-Edit's instruction for the segment's first frame (references are images 2 and 3). */+/** "image 2", "images 2 and 3", "images 2, 3 and 4": the references after the frame. */+function refImages(refs: number): string {+ const n = Array.from({ length: refs }, (_, k) => String(k + 2));+ return n.length === 1 ? `image ${n[0]}` : `images ${n.slice(0, -1).join(", ")} and ${n.at(-1)}`;+}++/** On the GPU: the edit model's instruction for the segment's first frame (references are images 2 onward). */export function directionFramePrompt(direction: string, i: Intensity, refs: number): string {const d = directionPrompt(direction).text.replace(/[.\s]+$/, "");const keep = i === "high" ? "Keep the composition and the poses of image 1." : "Keep the composition, the people, their faces and poses, and the framing of image 1.";- const match = refs ? ` Use the characters, objects and style of ${refs > 1 ? "images 2 and 3" : "image 2"} where they fit.` : "";+ const match = refs ? ` Use the characters, objects and style of ${refImages(refs)} where they fit.` : "";return `${FRAME_VERB[i]}: ${d}. ${keep}${match}`;}diff --git a/src/lib/catalog/genjutsu.ts b/src/lib/catalog/genjutsu.tsindex da7b75d5..cadb8d14 100644--- a/src/lib/catalog/genjutsu.ts+++ b/src/lib/catalog/genjutsu.ts@@ -55,7 +55,7 @@ import {type RemoveRange,type RemoveSource,} from "./remove-object";-import { firstFramePrompt, getShortsPreset, lookFromPreset, planShorts, segmentPrompt, type PlanStep, type ShortsLook } from "./shorts";+import { firstFramePrompt, getShortsPreset, lookFromPreset, planShorts, segmentPrompt, SHORTS_TOOLS, type PlanStep, type ShortsLook } from "./shorts";import { getModel } from "./index";import { REPLACED_BY } from "./replaced";import { soulLook } from "./soul";@@ -548,7 +548,7 @@ export const MAKERS: Maker[] = [engine: "open",modes: ["restyle"],label: "Fuobe Genjutsu",- note: "The first frame takes the look (Qwen-Image-Edit, or Z-Image with a Soul look's LoRAs), then Wan 2.2 Fun VACE by depth · 5 s segments at 16 fps, 480p",+ note: "The first frame takes the look (Qwen-Image 2.1 Turbo, or Z-Image with a Soul look's LoRAs), then Wan 2.2 Fun VACE by depth · 5 s segments at 16 fps, 480p",source: "original",refs: { min: 0, max: 0 },keepsSound: false,@@ -1325,14 +1325,15 @@ function planCharacterSwap(input: GenjutsuPlanInput): GenjutsuPlan {/*** The first frame's restyle: a Soul look's LoRAs on Z-Image (Fuobe Soul's edit, an Original: it runs on the engine the- * restyle does, never on whichever one is connected first), else Qwen-Image-Edit with the look's images.+ * restyle does, never on whichever one is connected first), else an edit model with the look's images: the Shorts+ * chain's own (Qwen-Image 2.1 Turbo on your GPU, hosted Qwen-Image-Edit 2511 in the cloud).*/function lookFrameRequest(engine: Engine, look: GenjutsuLook, sl: ShortsLook, refs: string[], seed: object): Pick<GenerationRequest, "modelId" | "op" | "prompt" | "presetId" | "inputs" | "params" | "engine"> {if (look.kind === "soul") {return { modelId: "fuobe-soul", engine, op: "edit", presetId: look.id, prompt: "The same frame: every person, face, pose and object in place", params: { ...seed } };}return {- modelId: engine === "open" ? "oss-qwen-edit" : "qwen-image-edit-2511-cloud",+ modelId: SHORTS_TOOLS[engine].frame,op: "edit",prompt: firstFramePrompt(sl, "auto", refs.length),...(refs.length ? { inputs: { images: refs } } : {}),@@ -1375,7 +1376,7 @@ function planFuobeRestyle(input: GenjutsuPlanInput): GenjutsuPlan {/*** The cloud Original's restyle: per piece of up to 241 frames, cut it, restyle its first frame (a Soul look's LoRAs on- * Z-Image, or Qwen-Image-Edit with the look's words and images), then Wan 2.2 Fun VACE carries the look through every+ * Z-Image, or hosted Qwen-Image-Edit 2511 with the look's words and images), then Wan 2.2 Fun VACE carries the look through every* frame by depth (fal's first_frame_url); the pieces are joined and the clip's sound put back.*/function planCloudRestyle(input: GenjutsuPlanInput): GenjutsuPlan {@@ -1490,7 +1491,7 @@ export function cleanCharacter(v: unknown): Omit<CharacterOptions, "dialogue"> |return Object.keys(out).length ? out : undefined;}-const ANCHOR_IDS = new Set(["gpt-image-2-5-sunburst", "nano-banana-pro", "oss-qwen-image-21", "oss-qwen-edit"]);+const ANCHOR_IDS = new Set(["gpt-image-2-5-sunburst", "nano-banana-pro", "oss-qwen-image-21", "oss-krea2-identity-edit", "oss-qwen-edit"]);/** A setup as a short code ("gj1." + base64url JSON with short keys; empty fields left out). */export function encodeSetup(s: GenjutsuSetup): string {diff --git a/src/lib/catalog/mixed-media.ts b/src/lib/catalog/mixed-media.tsindex 2db2b9e6..4a89b7bd 100644--- a/src/lib/catalog/mixed-media.ts+++ b/src/lib/catalog/mixed-media.ts@@ -53,7 +53,7 @@ export const MIXED_MODELS: Record<Engine, string[]> = {open: [MIXED_ORIGINAL],};export const MIXED_TOOLS = {- cloud: { cut: "trim-video", mux: "merge-audio-video", preview: "nano-banana-2", frames: "extract-frames", assemble: "images-to-video", join: "join-clips" },+ cloud: { cut: "trim-video", mux: "merge-audio-video", preview: "nano-banana-2-1", frames: "extract-frames", assemble: "images-to-video", join: "join-clips" },open: { preview: MIXED_ORIGINAL },} as const;@@ -66,10 +66,10 @@ export type MixedMode = "frames" | "smooth" | "fast";export const MIXED_MODES: Record<Engine, MixedMode[]> = { cloud: ["frames", "smooth", "fast"], open: ["frames", "smooth"] };/*** Cloud models that draw each frame (the first is the default): Fuobe Mixed Media (Z-Image Turbo + ControlNet with the- * look's LoRA, one seed, every frame on its own), then the partner image editors, Nano Banana 2 (it takes a seed) and+ * look's LoRA, one seed, every frame on its own), then the partner image editors, Nano Banana 2.1 (it takes a seed) and* Seedream 5.0 Flash, which redraw each frame looking at the one styled before it.*/-export const MIXED_FRAME_MODELS = [MIXED_ORIGINAL, "nano-banana-2", "seedream-5-flash"] as const;+export const MIXED_FRAME_MODELS = [MIXED_ORIGINAL, "nano-banana-2-1", "seedream-5-flash"] as const;/*** Cloud per-frame limits: fal's extract-nth-frame returns up to 500 frames a call and images-to-videodiff --git a/src/lib/catalog/motions.ts b/src/lib/catalog/motions.tsindex bfa8ecc7..8d308077 100644--- a/src/lib/catalog/motions.ts+++ b/src/lib/catalog/motions.ts@@ -107,7 +107,7 @@ const MOTION_SPECS: MotionSpec[] = [{ name: "Crane Over The Head", category: "Vertical", icon: "ArrowUpRight", prompt: "The camera rises and travels over the subject's head, ending looking down from behind" },{ name: "Jib Up", category: "Vertical", icon: "ArrowUp", prompt: "A short jib move upward that reveals the background behind the subject" },{ name: "Jib Down", category: "Vertical", icon: "ArrowDown", prompt: "A short jib move downward settling on the subject" },- { name: "Pedestal Down", category: "Vertical", icon: "ArrowDownToDot", prompt: "The camera lowers straight down on a pedestal without tilting, sliding from above the subject's head to their eye level" },+ { name: "Pedestal Down", category: "Vertical", icon: "ArrowDownToDot", prompt: "The camera lowers straight down on a pedestal, its angle held perfectly level, sliding from above the subject's head to their eye level" },{ name: "Tilt Up", category: "Vertical", icon: "ChevronUp", prompt: "The camera tilts up slowly from the subject's feet to their face" },{ name: "Tilt Down", category: "Vertical", icon: "ChevronDown", prompt: "The camera tilts down slowly from the sky to the subject" },{ name: "Overhead", category: "Vertical", icon: "LayoutGrid", prompt: "A top-down overhead shot that slowly rotates and descends toward the subject" },@@ -172,7 +172,7 @@ const MOTION_SPECS: MotionSpec[] = [{ name: "Kiss", category: "Action & Sports", icon: "Heart", prompt: "The two people lean in slowly and share a tender kiss in soft focus, the camera gently circling them" },{ name: "Moonwalk Left", category: "Action & Sports", icon: "ArrowLeft", prompt: "The subject performs a smooth moonwalk, gliding backward to the left while facing forward, retro dance style" },{ name: "Moonwalk Right", category: "Action & Sports", icon: "ArrowRight", prompt: "The subject performs a smooth moonwalk, gliding backward to the right while facing forward, retro dance style" },- { name: "Skate Cruise", category: "Action & Sports", icon: "Wind", prompt: "The subject cruises relaxed on a skateboard down a sunny street, pushing and gliding without tricks, the camera tracking alongside" },+ { name: "Skate Cruise", category: "Action & Sports", icon: "Wind", prompt: "The subject cruises relaxed on a skateboard down a sunny street, simply pushing and gliding with all four wheels on the ground, the camera tracking alongside" },{ name: "Skateboard Glide", category: "Action & Sports", icon: "Wind", prompt: "The subject glides smoothly on a skateboard, board rolling effortlessly, flowing and stylish" },{ name: "Skateboard Ollie", category: "Action & Sports", icon: "ArrowUp", prompt: "The subject pops a clean ollie, rider and board lifting off the ground together and landing smoothly" },{ name: "Ski Carving", category: "Action & Sports", icon: "MountainSnow", prompt: "A skier carves fast, clean turns down the slope, edges biting into the snow, the camera following" },@@ -186,7 +186,7 @@ const MOTION_SPECS: MotionSpec[] = [{ name: "Epic Scale", category: "Camera Styles", icon: "Mountain", prompt: "Epic large-scale camera work: sweeping crane and aerial moves that emphasize the vastness of the world around the subject" },{ name: "Impossible Camera", category: "Camera Styles", icon: "Infinity", prompt: "Impossible camera move that flies through tiny gaps, passes through glass and objects and swoops around the subject in one continuous path" },{ name: "Intimate Observer", category: "Camera Styles", icon: "Eye", prompt: "Intimate close camera that quietly observes the subject from near their shoulder, subtle breathing movement and shallow depth of field" },- { name: "One Take", category: "Camera Styles", icon: "Film", prompt: "Single continuous oner: a fluid Steadicam move follows the subject through the space without any cut" },+ { name: "One Take", category: "Camera Styles", icon: "Film", prompt: "Single continuous oner: a fluid Steadicam move follows the subject through the space in one unbroken take" },{ name: "Raw Chaos", category: "Camera Styles", icon: "Shuffle", prompt: "Chaotic, aggressive handheld camera with violent shakes, whip pans and crash zooms, raw and frantic" },{ name: "Silent Machine", category: "Camera Styles", icon: "Cog", prompt: "Precise, mechanical camera motion: perfectly linear slow slides and pushes with symmetrical framing, cold and controlled" },];@@ -308,7 +308,7 @@ const EFFECT_SPECS: MotionSpec[] = [{ name: "Crying", category: "Viral", icon: "Frown", prompt: "The subject's lip trembles and they burst into dramatic tears, sobbing as tears stream down their cheeks" },{ name: "Dream Date", category: "Viral", icon: "Heart", prompt: "A romantic date unfolds: candles, string lights and a sunset table appear around the subject as a date leans in smiling" },{ name: "Drunk Master", category: "Viral", icon: "Wine", prompt: "The subject sways and staggers in a comically drunken kung-fu style, then snaps into a flawless martial-arts pose" },- { name: "Explosion", category: "Viral", icon: "Bomb", prompt: "A huge explosion erupts behind the subject as they walk away from it without looking back, action-movie style" },+ { name: "Explosion", category: "Viral", icon: "Bomb", prompt: "A huge explosion erupts behind the subject as they walk calmly away from it, eyes fixed straight ahead, action-movie style" },{ name: "Fairies Around", category: "Viral", icon: "Sparkles", prompt: "Tiny glowing fairies flutter around the subject, leaving trails of sparkling dust" },{ name: "Firework", category: "Viral", icon: "PartyPopper", prompt: "Colorful fireworks burst in the night sky behind the subject, lighting their face in flashes of color" },{ name: "Flashback", category: "Viral", icon: "History", prompt: "The frame shifts into a hazy sepia flashback as younger memories of the subject flicker past, then returns to the present" },diff --git a/src/lib/catalog/packs.ts b/src/lib/catalog/packs.tsindex 7f61dac8..89477ac9 100644--- a/src/lib/catalog/packs.ts+++ b/src/lib/catalog/packs.ts@@ -365,24 +365,31 @@ export interface PlanCaps {export const PHOTODUMP_SOUL = "fuobe-soul";/**- * Instadump's Original (build plan O10): Qwen-Image-Edit 2511 with the photos as references, one Fuobe prompt per pack- * photo — hosted in the cloud, the 3-image graph on your GPU. It also makes a character's photos before a Soul ID.+ * Instadump's Original (build plan O10): an edit model with the photos as references, one Fuobe prompt per pack photo.+ * In the cloud hosted Qwen-Image-Edit 2511; on your GPU Qwen-Image 2.1 (up to 4 references). It also makes a+ * character's photos before a Soul ID.*/-export const PHOTO_EDIT: Record<Engine, string> = { cloud: "qwen-image-edit-2511-cloud", open: "oss-qwen-edit" };-/** The edit model your GPU runs first: Qwen-Image 2.1 (up to 4 references); Qwen-Image-Edit 2511 stays a choice after it. */-export const OPEN_PHOTO_EDIT = "oss-qwen-image-21";+export const PHOTO_EDIT: Record<Engine, string> = { cloud: "qwen-image-edit-2511-cloud", open: "oss-qwen-image-21" };+/** The edit model your GPU runs first: Qwen-Image 2.1 (up to 4 references). */+export const OPEN_PHOTO_EDIT = PHOTO_EDIT.open;+/** Its 8-step Turbo (up to 4 references). */+export const OPEN_PHOTO_EDIT_TURBO = "oss-qwen-image-21-turbo";+/** Krea 2 Identity Edit: restages the person in one photo (a new place, pose or outfit, the same face). */+export const OPEN_IDENTITY_EDIT = "oss-krea2-identity-edit";/** The models a pack's photos can run on, the default first after Fuobe Soul (which needs a trained Soul ID). */export const PHOTODUMP_MODELS: Record<Engine, string[]> = {- cloud: [PHOTODUMP_SOUL, PHOTO_EDIT.cloud, "nano-banana-pro", "seedream-5-pro"],- open: [PHOTODUMP_SOUL, OPEN_PHOTO_EDIT, PHOTO_EDIT.open],+ cloud: [PHOTODUMP_SOUL, PHOTO_EDIT.cloud, "nano-banana-pro", "nano-banana-2-1", "seedream-5-pro"],+ open: [PHOTODUMP_SOUL, OPEN_PHOTO_EDIT, OPEN_IDENTITY_EDIT, OPEN_PHOTO_EDIT_TURBO],};const EDIT_NAMES: Record<string, string> = {"qwen-image-edit-2511-cloud": "Qwen-Image-Edit 2511",- "oss-qwen-edit": "Qwen-Image-Edit 2511","oss-qwen-image-21": "Qwen-Image 2.1",+ "oss-qwen-image-21-turbo": "Qwen-Image 2.1 Turbo",+ "oss-krea2-identity-edit": "Krea 2 Identity Edit","nano-banana-pro": "Nano Banana Pro",+ "nano-banana-2-1": "Nano Banana 2.1","seedream-5-pro": "Seedream 5.0 Pro",};@@ -413,7 +420,7 @@ export function photodumpModel(subject: PhotoSubject, engine: Engine, _caps: Plareturn { modelId: fallback, note };}-const KEEP_FACE = "Keep their exact face, identity, skin tone and hair; a new photo, not a copy of the reference";+const KEEP_FACE = "Keep their exact face, identity, skin tone and hair, in a freshly composed new photo";/** One photo's prompt for a subject: an @mention for saved characters, image 1 for a selfie. */export function shotPrompt(pack: Pick<Pack, "look" | "custom">, shot: string, subject: PhotoSubject, refIndex?: number): string {@@ -598,14 +605,15 @@ export const getTemplate = (id: string) => FASHION.find((t) => t.id === id);/*** Fashion Factory's models per step (build plan O10): Fuobe Try-On (FLUX.2 [klein] 4B + the try-on LoRA) dresses the- * base shot on both engines, FASHN and Nano Banana Pro stay as cloud choices and Qwen-Image 2.1 (then Qwen-Image-Edit- * 2511) dresses it on your GPU when the try-on can't run. Qwen-Image-Edit 2511 makes the photoset in the cloud, Nano- * Banana Pro a choice; on your GPU Qwen-Image 2.1 makes it, Qwen-Image-Edit 2511 a choice.+ * base shot on both engines, FASHN and Nano Banana Pro stay as cloud choices, and on your GPU Qwen-Image 2.1 Turbo+ * (then Krea 2 Identity Edit) dresses it when the try-on can't run. Qwen-Image-Edit 2511 makes the photoset in the+ * cloud, Nano Banana Pro a choice; on your GPU Qwen-Image 2.1 makes it, Krea 2 Identity Edit (a new pose and place,+ * the same person) a choice.*/export const TRYON_MODEL = "fuobe-tryon";export const FASHION_MODELS = {- outfit: { cloud: [TRYON_MODEL, "fashn-tryon", "nano-banana-pro"], open: [TRYON_MODEL, OPEN_PHOTO_EDIT, PHOTO_EDIT.open] },- photoset: { cloud: [PHOTO_EDIT.cloud, "nano-banana-pro"], open: [OPEN_PHOTO_EDIT, PHOTO_EDIT.open] },+ outfit: { cloud: [TRYON_MODEL, "fashn-tryon", "nano-banana-pro"], open: [TRYON_MODEL, OPEN_PHOTO_EDIT_TURBO, OPEN_IDENTITY_EDIT] },+ photoset: { cloud: [PHOTO_EDIT.cloud, "nano-banana-pro"], open: [OPEN_PHOTO_EDIT, OPEN_IDENTITY_EDIT] },} as const;/**@@ -771,22 +779,27 @@ export function fashionReducer(s: FashionState, a: FashionAction): FashionStateexport const SHEET_MAX_REFS = 5;export const SHEET_PROMPT =- "A character turnaround sheet of the person in the reference images: full-body front view, three-quarter view, side profile and back view side by side, plus a close-up of the face, on a seamless light-grey studio backdrop with soft, even light. The same face, hairstyle, body and outfit in every view; photorealistic, natural skin texture, no text.";+ "A character turnaround sheet of the person in the reference images: full-body front view, three-quarter view, side profile and back view side by side, plus a close-up of the face, on a seamless light-grey studio backdrop with soft, even light. The same face, hairstyle, body and outfit in every view; photorealistic, natural skin texture, a clean picture made only of the views.";-/** From Reference: 1–5 photos → a turnaround sheet (Nano Banana Pro, or Qwen-Image-Edit with up to 3). */+/** The sheet from reference photos on your GPU: Qwen-Image 2.1 at 25 steps (its Turbo misses big camera turns). */+export const SHEET_OPEN_MODEL = "oss-qwen-image-21";+/** Qwen-Image 2.1 takes up to 4 reference photos. */+export const SHEET_OPEN_REFS = 4;++/** From Reference: 1–5 photos → a turnaround sheet (Nano Banana Pro, or Qwen-Image 2.1 with up to 4). */export function sheetFromReference(images: string[], engine: Engine, details?: string): { request: GenerationRequest; notes: string[] } {if (!images.length) throw new Error("Upload at least 1 image");if (images.length > SHEET_MAX_REFS) throw new Error(`Maximum ${SHEET_MAX_REFS} images`);const notes: string[] = [];- const max = engine === "open" ? 3 : SHEET_MAX_REFS;- if (images.length > max) notes.push(`Qwen-Image-Edit takes 3 photos — the first 3 are used`);+ const max = engine === "open" ? SHEET_OPEN_REFS : SHEET_MAX_REFS;+ if (images.length > max) notes.push(`Qwen-Image 2.1 takes ${max} photos — the first ${max} are used`);// The open workflow has no size setting: the sheet comes out in the first photo's shape.- if (engine === "open") notes.push("Qwen-Image-Edit keeps the shape of your first photo — put a landscape photo first for a wide sheet");+ if (engine === "open") notes.push("Qwen-Image 2.1 keeps the shape of your first photo — put a landscape photo first for a wide sheet");const extra = details?.trim().replace(/[.\s]+$/, "");return {request: {feature: "character-sheet",- modelId: engine === "open" ? "oss-qwen-edit" : "nano-banana-pro",+ modelId: engine === "open" ? SHEET_OPEN_MODEL : "nano-banana-pro",op: "edit",prompt: extra ? `${SHEET_PROMPT} ${extra}.` : SHEET_PROMPT,inputs: { images: images.slice(0, max) },diff --git a/src/lib/catalog/palettes.ts b/src/lib/catalog/palettes.tsindex fde7e1df..ab0d1659 100644--- a/src/lib/catalog/palettes.ts+++ b/src/lib/catalog/palettes.ts@@ -17,7 +17,7 @@* on every other model its words. Picks saved with Higgsfield's old style ids still find their look.* Personal: cloud = the board's Recraft style id (Recraft models) or its most representative images* as style references (Nano Banana Pro and other multi-reference models); open = the board's collages- * on Qwen-Image-Edit Style Reference (or the style-reference model picked), or its trained style LoRA+ * on Krea 2 Style Reference (or the style-reference model picked), or its trained style LoRA* on Z-Image Turbo.* Sentences (the palette's hex list, a look described in words, a reference legend) never go into* `request.prompt`: they ride in `request.signature.words`, which the server adds when it plans the@@ -400,7 +400,8 @@ export const SIGNATURE_MODELS = {cloudRefs: "nano-banana-pro",recraftStyle: "recraft-4-style",recraftSaved: "recraft-4-style-saved",- openStyle: "oss-style-qwen-edit",+ /** Krea 2 Style Reference: trained for style reference (1–2 images, the board's collages). */+ openStyle: "oss-style-krea2",openPalette: "oss-zimage-palette",openTurbo: "oss-z-image-turbo",/** A personal moodboard trained as a style LoRA runs here, the LoRA as its look (both engines). */diff --git a/src/lib/catalog/remove-object.ts b/src/lib/catalog/remove-object.tsindex 401ebaa4..9e8b801a 100644--- a/src/lib/catalog/remove-object.ts+++ b/src/lib/catalog/remove-object.ts@@ -731,8 +731,13 @@ export function planRemoval(input: RemovalPlanInput): RemovalPlan {return { steps, final, pieces, sound, tracked };}-/** The tools the H3 person removal prepares its inputs with (all on your GPU). */-export const PERSON_REMOVAL_TOOLS = { fit: "oss-fit-clip", frame: "oss-extract-frame", clean: "oss-qwen-edit" } as const;+/**+ * The tools the H3 person removal prepares its inputs with (all on your GPU). The clean frame is Qwen-Image 2.1 at 25+ * steps: its edit follows image 1's shape (the frame scaled to 2048 px on the long side, each side rounded to 32 px),+ * and the relay graph scales it back to the part's exact size with a centre crop. The framing stays the clip's: a 16:9+ * part (1344×736) comes back at 2048×1120, within a pixel of its shape; the rounding moves an edge by 1.5% at most.+ */+export const PERSON_REMOVAL_TOOLS = { fit: "oss-fit-clip", frame: "oss-extract-frame", clean: "oss-qwen-image-21" } as const;/** H3 Relay's Person Removal works at 24 fps (its windows are counted in frames of the clip as it comes in). */export const PERSON_REMOVAL_FPS = 24;@@ -749,7 +754,7 @@ export function cleanFramePrompt(words: string | undefined): string {/*** Remove a person on H3 (docs/research/openjutsu-6.md §4.4): the part fitted to 24 fps on the 32-pixel grid (the size* H3's pixel budget gives the clip at "768"), its first frame, a clean copy of that frame with the person gone- * (Qwen-Image-Edit), then H3 Relay's Person Removal from the clean frame; its output is silent, so the clip's sound is+ * (Qwen-Image 2.1), then H3 Relay's Person Removal from the clean frame; its output is silent, so the clip's sound is* put back.*/function planPersonRemoval(input: RemovalPlanInput): RemovalPlan {@@ -780,7 +785,7 @@ function planPersonRemoval(input: RemovalPlanInput): RemovalPlan {},{key: "clean",- request: { ...helper, modelId: PERSON_REMOVAL_TOOLS.clean, op: "edit", prompt: cleanFramePrompt(input.prompt), ...(input.seed !== undefined ? { params: { ...seed } } : {}), step: label("A clean first frame (Qwen-Image-Edit)", 2) },+ request: { ...helper, modelId: PERSON_REMOVAL_TOOLS.clean, op: "edit", prompt: cleanFramePrompt(input.prompt), ...(input.seed !== undefined ? { params: { ...seed } } : {}), step: label("A clean first frame (Qwen-Image 2.1)", 2) },after: ["frame"],chain: [{ slot: "images", position: "first" }],},diff --git a/src/lib/catalog/shorts.ts b/src/lib/catalog/shorts.tsindex e94db852..62d08600 100644--- a/src/lib/catalog/shorts.ts+++ b/src/lib/catalog/shorts.ts@@ -5,7 +5,7 @@* segments are stitched back together under the original sound.** Fuobe Shorts (build plan O9) is the default on both engines: each segment's first frame drawn in the look- * (Qwen-Image-Edit 2511), then Wan 2.2 Fun VACE carries it through every frame by depth, on your GPU (81 frames at+ * (Qwen-Image 2.1 Turbo on your GPU, hosted Qwen-Image-Edit 2511 on fal), then Wan 2.2 Fun VACE carries it through every frame by depth, on your GPU (81 frames at* 16 fps a segment) or on fal (pieces of up to 241 frames at the clip's own rate). Gemini Omni Flash (Higgsfield's* Shorts engine) and the other partner models stay as choices.*@@ -30,7 +30,7 @@ export const SHORTS = {openFps: 16,openMaxFrames: 81,maxReferences: 10,- /** Qwen-Image-Edit takes the frame plus two references (the Original's first frame, on both engines). */+ /** The first frame's edit takes the frame plus two references (the Original's first frame, on both engines). */openReferences: 2,/*** Fuobe Shorts in the cloud: fal's Wan 2.2 Fun VACE makes 17–241 frames at 5–30 fps, matching its input clip's count and@@ -95,10 +95,13 @@ export const SHORTS_MODELS: Record<Engine, string[]> = {open: [SHORTS_ORIGINAL],};-/** The helper models of the pipeline (the cloud Original's first frame: `still` takes it, `frame` restyles it). */+/**+ * The helper models of the pipeline (the cloud Original's first frame: `still` takes it, `frame` restyles it). The+ * first frame in the look: hosted Qwen-Image-Edit 2511 in the cloud, Qwen-Image 2.1 Turbo (8 steps) on your GPU.+ */export const SHORTS_TOOLS = {cloud: { cut: "trim-video", trim: "trim-video", fit: "scale-video", still: "extract-frame", frame: "qwen-image-edit-2511-cloud", join: "join-clips", mux: "merge-audio-video", joinMax: 24 },- open: { cut: "oss-segment", trim: "oss-trim", frame: "oss-qwen-edit", join: "oss-join-clips", mux: "oss-mux", joinMax: 4 },+ open: { cut: "oss-segment", trim: "oss-trim", frame: "oss-qwen-image-21-turbo", join: "oss-join-clips", mux: "oss-mux", joinMax: 4 },} as const;// ---------------------------------------------------------------------------@@ -267,7 +270,7 @@ export function restylePrompt(look: Pick<ShortsLook, "look" | "type" | "referencreturn `Restyle this video as ${tidy(look.look)}. Keep everything that happens exactly as it is: the same people, faces, poses, motion, timing and camera moves; change only the look.${refs}${wordsLine(look, language)}`;}-/** Open engine, step 1: restyle the segment's first frame (image 1) with Qwen-Image-Edit; references are images 2 and 3. */+/** Step 1: restyle the segment's first frame (image 1) with the edit model (SHORTS_TOOLS.frame); references are images 2 and 3. */export function firstFramePrompt(look: Pick<ShortsLook, "look" | "type">, language = "auto", refs = 0): string {const match = refs ? ` Match the style, colours and textures of ${refs > 1 ? "images 2 and 3" : "image 2"}.` : "";return `Redraw image 1 as ${tidy(look.look)}. Keep the composition, framing, people, faces, poses and expressions of image 1 exactly.${match}${wordsLine(look, language)}`;diff --git a/src/lib/catalog/storyboard.ts b/src/lib/catalog/storyboard.tsindex e9a68b75..6b41ba7d 100644--- a/src/lib/catalog/storyboard.ts+++ b/src/lib/catalog/storyboard.ts@@ -34,8 +34,9 @@ const NEXT_SCENE = loraEntry("next-scene-qwen-edit-2509");export const STORYBOARD_MODELS: Record<Engine, StoryboardModels> = {// Hosted open weights: Z-Image Turbo, Qwen-Image-Edit 2511 with references, then Qwen-Image-Edit 2509 + next-scene.cloud: { first: "z-image-turbo-cloud", firstWithRefs: "qwen-image-edit-2511-cloud", next: "qwen-image-edit-2509-cloud", chainFrom: "first", ...(NEXT_SCENE && { nextLoras: [loraRef(NEXT_SCENE)] }) },- // Qwen-Image-Edit + the next-scene LoRA takes the previous panel as image 1 and the character as image 2.- open: { first: "oss-z-image-turbo", firstWithRefs: "oss-qwen-edit", next: "oss-qwen-next-scene", chainFrom: "first" },+ // Frame 1 on Qwen-Image 2.1 (text to image, or an edit of up to 4 references); then Qwen-Image-Edit 2509 + the+ // next-scene LoRA takes the previous panel as image 1 and the character as image 2.+ open: { first: "oss-qwen-image-21", firstWithRefs: "oss-qwen-image-21", next: "oss-qwen-next-scene", chainFrom: "first" },};/** Partner models a cloud board can run on instead (a separate choice): every frame on it, each from the last one. */diff --git a/src/lib/catalog/turnaround.ts b/src/lib/catalog/turnaround.tsindex 34a53a36..862e41b7 100644--- a/src/lib/catalog/turnaround.ts+++ b/src/lib/catalog/turnaround.ts@@ -143,10 +143,10 @@ export const TURN_ROUTES: Record<TurnRoute, TurnRouteInfo> = {export const ROUTES_ON: Record<Engine, TurnRoute[]> = { open: ["frames"], cloud: ["references", "keyframes", "camera"] };-/** The Angles app's routes, which draw a missing side from the front view. */+/** The Angles app's routes, which draw a missing side from the front view (on your GPU the Multiple-Angles LoRA's base). */export const FILL_MODELS: Record<Engine, string> = { cloud: "qwen-multiple-angles", open: "oss-qwen-edit" };-/** What draws a front view from a whole sheet, when no picture shows the front alone. */-export const SHEET_FRONT_MODELS: Record<Engine, string> = { cloud: "nano-banana-pro", open: "oss-qwen-edit" };+/** What draws a front view from a whole sheet, when no picture shows the front alone (Qwen-Image 2.1 on your GPU). */+export const SHEET_FRONT_MODELS: Record<Engine, string> = { cloud: "nano-banana-pro", open: "oss-qwen-image-21" };/** The camera route's paths (N7-5's moves); the turnaround's own Orbit 360° passes the right side first, as the views do. */export const TURN_PATHS = [@@ -168,8 +168,9 @@ export function cameraWords(path: string, extra?: string): string {}const FILL_KEEP = "Keep the same person: identity, face, hair, body, outfit, lighting and plain background";-const SHEET_FRONT_PROMPT =- "Image 1 is a character turnaround sheet. Show only this character's front view as one full-body picture, centred and facing the camera, on the same plain backdrop and light. Keep the face, hair, body and outfit exactly as on the sheet; no text, no other views";+/** The edit that draws a front view from a whole sheet, when no picture shows the front alone. */+export const SHEET_FRONT_PROMPT =+ "Image 1 is a character turnaround sheet. Show only this character's front view as one full-body picture, centred and facing the camera, on the same plain backdrop and light. Keep the face, hair, body and outfit exactly as on the sheet; this one view alone fills the clean picture";const tidy = (p: string | undefined) => (p ?? "").trim().replace(/[.\s]+$/, "");const withWords = (base: string, extra: string | undefined) => (tidy(extra) ? `${base}. ${tidy(extra)}` : base);diff --git a/src/lib/influencer.ts b/src/lib/influencer.tsindex acd01447..b51f6fed 100644--- a/src/lib/influencer.ts+++ b/src/lib/influencer.ts@@ -797,16 +797,19 @@ export function cleanState(raw: unknown): { state: InfluencerState; problem: str/*** The cloud models that draw the sheet: Fuobe Soul (the default, build plan O10: the sheet in Soul's casting look, then- * Qwen-Image-Edit 2511 puts your face and clothing on it), or Nano Banana Pro / Seedream 5.0 Pro in one pass with them.+ * hosted Qwen-Image-Edit 2511 puts your face and clothing on it), or Nano Banana Pro / Seedream 5.0 Pro in one pass with them.*/export const INFLUENCER_CLOUD_MODELS = ["fuobe-soul", "nano-banana-pro", "seedream-5-pro"] as const;-export const INFLUENCER_OPEN_MODELS = { sheet: "oss-zimage-soul-cast", edit: "oss-qwen-edit" } as const;+/** On your GPU: the Soul Cast sheet, then Qwen-Image 2.1 (up to 4 references) puts your face and clothing on it. */+export const INFLUENCER_OPEN_MODELS = { sheet: "oss-zimage-soul-cast", edit: "oss-qwen-image-21" } as const;/** Fuobe Soul's steps in the cloud: the sheet on its hosted half, your face and clothing on hosted Qwen-Image-Edit 2511. */export const INFLUENCER_SOUL = { sheet: "fuobe-soul", edit: "qwen-image-edit-2511-cloud" } as const;/** The look the sheet is drawn in (Soul Cast's casting look: natural, unretouched skin and fabric). */export const INFLUENCER_LOOK = CAST_LOOK;-/** Qwen-Image-Edit 2511 takes three images on your GPU (the sheet, then the photo and clothing); fal takes more. */-const OPEN_EDIT_IMAGES = 3;+/** Qwen-Image 2.1 takes four images on your GPU (the sheet, then the photo and clothing); fal takes more. */+export const OPEN_EDIT_IMAGES = 4;+/** The edit step's model, by name, per engine. */+const EDIT_NAME: Record<Engine, string> = { open: "Qwen-Image 2.1", cloud: "Qwen-Image-Edit 2511" };export interface InfluencerRun {engine: Engine;@@ -851,7 +854,7 @@ export function influencerBlocker(run: Pick<InfluencerRun, "state" | "direction"/*** The jobs for a run. Open: the Soul Cast sheet workflow (Z-Image Turbo, with the casting look's LoRAs the server adds)- * draws the character; with a photo or clothing, Qwen-Image-Edit 2511 then puts your face and clothes on that sheet, so+ * draws the character; with a photo or clothing, Qwen-Image 2.1 then puts your face and clothes on that sheet, so* the sheet keeps its wide shape. Cloud: the same two steps on Fuobe Soul and hosted Qwen-Image-Edit 2511 by default, or* Nano Banana Pro (Seedream 5.0 Pro when asked) drawing the sheet from the compiled prompt with the photos as references.*/@@ -891,16 +894,18 @@ export function planInfluencer(run: InfluencerRun, caps: Pick<PlanCaps, "has">):},};if (!edits) return { steps: [sheet], modelId: sheetModel, notes };- const room = (open ? OPEN_EDIT_IMAGES : 1 + 1 + MAX_CLOTHING) - 1 - (photo ? 1 : 0);+ const takes = open ? OPEN_EDIT_IMAGES : 1 + 1 + MAX_CLOTHING;+ const room = takes - 1 - (photo ? 1 : 0);const used = clothing.slice(0, room);- if (clothing.length > used.length) notes.push(`Qwen-Image-Edit takes 3 images (the sheet${photo ? ", your photo" : ""} and clothing) — the first ${used.length === 1 ? "clothing reference is" : `${used.length} clothing references are`} used`);+ const editor = EDIT_NAME[run.engine];+ if (clothing.length > used.length) notes.push(`${editor} takes ${takes} images (the sheet${photo ? ", your photo" : ""} and clothing) — the first ${used.length === 1 ? "clothing reference is" : `${used.length} clothing references are`} used`);const drawer = open ? "Z-Image Turbo" : "Fuobe Soul";notes.push(photo? start === "face"- ? `Two steps: ${drawer} draws the sheet, then Qwen-Image-Edit 2511 puts your face on it`- : `Two steps: ${drawer} draws the sheet, then Qwen-Image-Edit 2511 matches it to your reference`- : `Two steps: ${drawer} draws the sheet, then Qwen-Image-Edit 2511 dresses it in your clothing`,+ ? `Two steps: ${drawer} draws the sheet, then ${editor} puts your face on it`+ : `Two steps: ${drawer} draws the sheet, then ${editor} matches it to your reference`+ : `Two steps: ${drawer} draws the sheet, then ${editor} dresses it in your clothing`,);return {steps: [diff --git a/src/lib/layers.ts b/src/lib/layers.tsindex eb5ff18f..387d973a 100644--- a/src/lib/layers.ts+++ b/src/lib/layers.ts@@ -224,28 +224,35 @@ export const TOOL_LABELS: Record<LayerTool, string> = {/*** Models each tool offers, per engine (the first is the default). Checked against the catalog in tests. On the open- * engine the owner's newest models come first: Qwen-Image 2.1 edits, inpaints, expands and makes a layer. Ideogram 4 comes- * second for a layer: its safety filter answers most lone objects on a plain background with a grey card.+ * engine the newest image models come first: Qwen-Image 2.1 (and its 8-step Turbo) edits, inpaints, expands, turns the+ * camera and makes a layer; Krea 2 and FIBO 2 edit after it. Ideogram 4 comes second for a layer: its safety filter+ * answers most lone objects on a plain background with a grey card. Every list holds only models whose route takes what+ * the tool sends (an edit of one picture, a mask, the margins to fill).*/export const TOOL_MODELS: Record<LayerTool, { cloud: string[]; open: string[] }> = {decompose: { cloud: ["seedream-5-layers", "seedream-5-flash-layers", "qwen-image-layered-cloud"], open: ["oss-qwen-layered"] },split: { cloud: ["seedream-5-layers", "seedream-5-flash-layers", "qwen-image-layered-cloud"], open: ["oss-qwen-layered", "oss-qwen-layered-control"] },- regenerate: { cloud: ["nano-banana-pro", "seedream-5-pro", "nano-banana-2"], open: ["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-qwen-edit", "oss-flux-kontext"] },- "generate-layer": { cloud: ["nano-banana-pro", "seedream-5-pro"], open: ["oss-qwen-image-21", "oss-ideogram-4", "oss-z-image-turbo", "oss-qwen-image"] },+ regenerate: { cloud: ["nano-banana-pro", "seedream-5-pro", "nano-banana-2-1"], open: ["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-krea2-edit", "oss-fibo2-edit-turbo"] },+ "generate-layer": { cloud: ["nano-banana-pro", "seedream-5-pro"], open: ["oss-qwen-image-21", "oss-ideogram-4", "oss-krea2-turbo", "oss-moss-image"] },// Ideogram ($0.09) also lifts the text off the picture, which the editor doesn't use; Florence-2 only// reads it (fal lists $0 per compute second, real cost unverified: the catalog's $0.001 is a placeholder)."text-detect": { cloud: ["ideogram-3-text-layers", "florence-2-ocr"], open: ["oss-ocr-lines"] },- "text-edit": { cloud: ["nano-banana-pro", "seedream-5-pro"], open: ["oss-qwen-image-21", "oss-qwen-edit"] },+ "text-edit": { cloud: ["nano-banana-pro", "seedream-5-pro"], open: ["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-krea2-edit"] },"bg-remove": { cloud: ["birefnet-cloud", "ideogram-remove-bg"], open: ["oss-rmbg"] },- regional: { cloud: ["seedream-5-pro", "nano-banana-pro"], open: ["oss-qwen-image-21", "oss-qwen-edit", "oss-flux-kontext"] },- upscale: { cloud: ["topaz-image", "seedvr-image", "recraft-crisp"], open: ["oss-upscale-image", "oss-seedvr2-image"] },- relight: { cloud: ["nano-banana-pro"], open: ["oss-qwen-relight"] },- angles: { cloud: ["qwen-multiple-angles", "nano-banana-pro"], open: ["oss-qwen-edit"] },- expand: { cloud: ["nano-banana-pro"], open: ["oss-qwen-image-21", "oss-flux-fill"] },- // Nano Banana Pro sees the painted area tinted red (Higgsfield's nano_banana_pro_inpaint); the others take the mask itself.- inpaint: { cloud: ["nano-banana-pro", "flux-fill-pro", "z-image-inpaint"], open: ["oss-qwen-image-21", "oss-flux-fill"] },+ regional: { cloud: ["seedream-5-pro", "nano-banana-pro"], open: ["oss-qwen-image-21", "oss-krea2-edit", "oss-fibo2-edit-turbo"] },+ // SeedVR2 restores detail as it enlarges; 4x ESRGAN is the quick choice.+ upscale: { cloud: ["topaz-image", "seedvr-image", "recraft-crisp"], open: ["oss-seedvr2-image", "oss-upscale-image"] },+ // Qwen-Image 2.1 Turbo and Krea 2 Edit relight from plain words; the Qwen-Image-Edit 2509 graph carries its Relight LoRA.+ relight: { cloud: ["nano-banana-pro", "nano-banana-2-1"], open: ["oss-qwen-image-21-turbo", "oss-krea2-edit", "oss-qwen-relight"] },+ // Qwen-Image 2.1 at 25 steps on plain camera words (its Turbo misses big camera turns).+ angles: { cloud: ["qwen-multiple-angles", "nano-banana-pro"], open: ["oss-qwen-image-21"] },+ // Both open graphs grow the canvas themselves from the pads; Krea 2 Inpaint needs its add-on (Ostris Edit).+ expand: { cloud: ["nano-banana-pro"], open: ["oss-qwen-image-21", "oss-krea2-inpaint"] },+ // Nano Banana Pro sees the painted area tinted red (Higgsfield's nano_banana_pro_inpaint); the others take the mask itself+ // (Bria FIBO 2's edit keeps a single picture's own shape).+ inpaint: { cloud: ["nano-banana-pro", "bria-fibo-2", "z-image-inpaint"], open: ["oss-qwen-image-21", "oss-krea2-inpaint"] },// The retouch looks; Detail runs on {@link ENHANCE_DETAIL_MODELS}.- enhance: { cloud: ["nano-banana-pro", "seedream-5-pro"], open: ["oss-qwen-image-21", "oss-qwen-edit"] },+ enhance: { cloud: ["nano-banana-pro", "seedream-5-pro"], open: ["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-krea2-edit"] },};// ---------------------------------------------------------------------------@@ -301,7 +308,7 @@ export function enhancePrompt(look: EnhanceLook | undefined, extra?: string): stconst keep =l.id === "sharpen"? "Keep the content, composition, colours and lighting exactly the same."- : "Make the skin look like a high-end editorial photograph shot on a sharp lens — real texture, no plastic smoothing, no makeup changes. Keep the face shape, identity, expression, hair, lighting and background exactly the same.";+ : "Make the skin look like a high-end editorial photograph shot on a sharp lens, with real, natural skin texture and the same makeup. Keep the face shape, identity, expression, hair, lighting and background exactly the same.";return [l.prompt, keep, extra?.trim()].filter(Boolean).join(" ");}@@ -326,6 +333,24 @@ export const RELIGHT_DIRECTIONS: [string, string][] = [["Behind", "coming from behind the subject as a rim light"],];+/** The Qwen-Image-Edit 2509 relight graph: it loads the Relight LoRA and puts the LoRA's trigger before the words itself. */+export const RELIGHT_LORA_MODEL = "oss-qwen-relight";+/** Qwen-Image 2.1's edit models: its text encoder names the pictures <image1>, <image2>… */+export const QWEN21_EDIT_MODELS: readonly string[] = ["oss-qwen-image-21", "oss-qwen-image-21-turbo"];++/**+ * A relight's words for an edit model: the light alone for the Relight LoRA graph, Qwen-Image 2.1's own picture tags+ * (the wording its relit preset covers were made with), and a plain instruction for every other model.+ */+export function relightPrompt(modelId: string, light: string, direction = ""): string {+ if (modelId === RELIGHT_LORA_MODEL) return `${light}${direction ? `, ${direction}` : ""}`;+ const lit = `${light}${direction ? ` ${direction}` : ""}`;+ if (QWEN21_EDIT_MODELS.includes(modelId)) {+ return `Relight <image1> with ${lit}. Keep every person, face, pose, object, the setting and the framing exactly as in <image1>; only the light, shadows, reflections and colour temperature change.`;+ }+ return `Relight the image with ${lit}. Keep the subject, composition and all details identical; only the light, shadows, reflections and color temperature change.`;+}+/** Camera angles (the Angles app's), as [label, prompt]. */export const ANGLES: [string, string][] = [["Left 45°", "rotated 45 degrees to the left around the subject"],diff --git a/src/server/evolution.ts b/src/server/evolution.tsindex 238ad98a..84f8a83d 100644--- a/src/server/evolution.ts+++ b/src/server/evolution.ts@@ -182,9 +182,10 @@ function planInput(body: z.infer<typeof EvolutionBodySchema>, info: Awaited<Retuconst name = getModel(EVOLUTION.model)?.name ?? "Fuobe Evolution";const n = body.references.length;if (engine === "open") {- notes.push(`Each ≤5 s segment: Qwen-Image-Edit takes its first frame toward the direction${n ? ` with your first ${Math.min(n, EVOLUTION.openReferences) === 1 ? "reference" : "two references"}` : ""}, then Wan 2.2 Fun VACE re-renders it from itself at 16 fps`);+ const k = Math.min(n, EVOLUTION.openReferences);+ notes.push(`Each ≤5 s segment: Qwen-Image 2.1 Turbo takes its first frame toward the direction${n ? ` with your first ${k === 1 ? "reference" : `${k} references`}` : ""}, then Wan 2.2 Fun VACE re-renders it from itself at 16 fps`);if (n > EVOLUTION.openReferences) notes.push(`The other ${n - EVOLUTION.openReferences} reference${n - EVOLUTION.openReferences > 1 ? "s" : ""} shape the direction only`);- notes.push("Needs a 24 GB GPU · Wan 2.2 Fun VACE and Qwen-Image-Edit are Apache-2.0");+ notes.push("Needs a 24 GB GPU · Wan 2.2 Fun VACE is Apache-2.0; Qwen-Image 2.1's weights are non-commercial");} else {notes.push(`${name} runs LTX-2.3 video to video on fal in your clip's shape (${nearestShape(source.width, source.height)}) at 24 fps`);if (n) notes.push(`LTX-2.3 takes no pictures: your ${n === 1 ? "reference shapes" : `${n} references shape`} the direction`);diff --git a/src/server/genjutsu.ts b/src/server/genjutsu.tsindex 9f561e82..d7e930cd 100644--- a/src/server/genjutsu.ts+++ b/src/server/genjutsu.ts@@ -107,7 +107,7 @@ const character = z.object({subject: z.string().max(120).optional(),maskGrow: z.number().int().min(0).max(256).optional(),anchor: z.boolean().optional(),- anchorModel: z.enum(["gpt-image-2-5-sunburst", "nano-banana-pro", "oss-qwen-image-21", "oss-qwen-edit"]).optional(),+ anchorModel: z.enum(["gpt-image-2-5-sunburst", "nano-banana-pro", "oss-qwen-image-21", "oss-krea2-identity-edit", "oss-qwen-edit"]).optional(),description: z.string().max(CHARACTER_SWAP.maxDescriptionChars).optional(),speech: z.enum(["character", "other", "offscreen", "none"]).optional(),dialogue: z.string().max(2000).optional(),diff --git a/src/server/layers.ts b/src/server/layers.tsindex 6356bb52..03f1929c 100644--- a/src/server/layers.ts+++ b/src/server/layers.ts@@ -18,6 +18,7 @@ import {MAX_NODES,RELIGHT_DIRECTIONS,RELIGHT_LIGHTS,+ relightPrompt,textChanges,textEditPrompt,TOOL_LABELS,@@ -266,7 +267,7 @@ export function jobSteps(input: LayerJobInput, opts: { batchTitle?: string } = {case "generate-layer": {if (!prompt) throw new LayersError("Describe the layer to generate", 400);const refs = input.refs ?? [];- const ask = `${prompt}. A single element, isolated and centred on a plain white background, nothing else in the frame.`;+ const ask = `${prompt}. A single element, isolated and centred on a plain white background, alone in the frame.`;if (refs.length) {const model = toolModel("regenerate", engine, undefined);add("make", base(model, { op: "edit", prompt: `${ask} Base it on image 1.`, inputs: { images: refs } }));@@ -310,12 +311,8 @@ export function jobSteps(input: LayerJobInput, opts: { batchTitle?: string } = {}case "relight": {const model = toolModel(tool, engine, input.modelId);- const light = pick(RELIGHT_LIGHTS, s.light);- const dir = pick(RELIGHT_DIRECTIONS, s.direction);- const p =- model.engine === "open"- ? `${light}${dir ? `, ${dir}` : ""}`- : `Relight the image with ${light}${dir ? ` ${dir}` : ""}. Keep the subject, composition and all details identical; only the light, shadows, reflections and color temperature change.`;+ // The Relight LoRA graph gets the light alone; Qwen-Image 2.1 its own picture tags; other models a plain instruction.+ const p = relightPrompt(model.id, pick(RELIGHT_LIGHTS, s.light), pick(RELIGHT_DIRECTIONS, s.direction));add("relight", base(model, { op: "edit", prompt: prompt ? `${p} ${prompt}` : p, inputs: { images: [needImage()] }, params: aspectFor(model) }));if (s.keepAlpha) cutout("relight");break;@@ -331,7 +328,8 @@ export function jobSteps(input: LayerJobInput, opts: { batchTitle?: string } = {inputs: { images: [needImage()] },params: { ...aspectFor(model), numOutputs: 1, extra: { horizontal_angle: Math.round(s.rotate ?? 45), vertical_angle: Math.round(s.tilt ?? 0), zoom: Math.round(s.zoom ?? 5) } },})- : base(model, { op: "edit", prompt: `Show the exact same subject from ${pick(ANGLES, s.angle)}, as if the camera physically moved. ${keep}${prompt ? ` ${prompt}` : ""}`, inputs: { images: [needImage()] }, params: aspectFor(model) });+ : // Edit models (Qwen-Image 2.1 at 25 steps on your GPU) turn the camera from plain words.+ base(model, { op: "edit", prompt: `Show the exact same subject from ${pick(ANGLES, s.angle)}, as if the camera physically moved. ${keep}${prompt ? ` ${prompt}` : ""}`, inputs: { images: [needImage()] }, params: aspectFor(model) });add("angle", request);if (s.keepAlpha) cutout("angle");break;@@ -368,7 +366,7 @@ export function jobSteps(input: LayerJobInput, opts: { batchTitle?: string } = {// The open graphs keep the picture as it is themselves, and read the words as what fills the margins: only that.add("expand", base(model, { op: "outpaint", prompt: prompt || fill, inputs: { images: [needImage()] }, params: { extra: { padLeft: pads.left, padTop: pads.top, padRight: pads.right, padBottom: pads.bottom } } }));} else {- add("expand", base(model, { op: "edit", prompt: `Fill the empty grey margins around the picture. ${fill} Keep the original picture untouched and add no new people or text.${prompt ? ` ${prompt}` : ""}`, inputs: { images: [needImage()] }, params: aspectFor(model) }));+ add("expand", base(model, { op: "edit", prompt: `Fill the empty grey margins around the picture. ${fill} Keep the original picture untouched, and fill the margins with more of the same surroundings.${prompt ? ` ${prompt}` : ""}`, inputs: { images: [needImage()] }, params: aspectFor(model) }));}break;}diff --git a/src/server/mixed-media.ts b/src/server/mixed-media.tsindex 6dec019a..810990c8 100644--- a/src/server/mixed-media.ts+++ b/src/server/mixed-media.ts@@ -125,7 +125,7 @@ async function planInput(body: MixedBody, opts: { probe: boolean }): Promise<{ iframes = s.frames;rate = s.fps;if (Math.abs(s.fps - fps) > 0.01) notes.push(`Frames are every ${s.interval === 1 ? "" : `${ordinal(s.interval)} `}frame of this ${+sourceFps.toFixed(2)} FPS clip: ${+s.fps.toFixed(2)} FPS, ${frames} frames`);- if (modelId === "seedream-5-flash") notes.push(`Seedream 5.0 Flash takes no seed, so frames vary a little more than with Nano Banana 2${body.resolution === "4K" ? "; it draws up to 2K" : ""}`);+ if (modelId === "seedream-5-flash") notes.push(`Seedream 5.0 Flash takes no seed, so frames vary a little more than with Nano Banana 2.1${body.resolution === "4K" ? "; it draws up to 2K" : ""}`);else if (original && body.resolution === "4K") notes.push(`${model?.name} draws frames at up to 2K (about 4 megapixels)`);else if (frames > FRAME_LIMITS.perClip && body.resolution !== "1K") {// merge-videos sizes the joined clips 512–2048 px a side.diff --git a/src/server/moodboards.ts b/src/server/moodboards.tsindex d9b08deb..60cccbb9 100644--- a/src/server/moodboards.ts+++ b/src/server/moodboards.ts@@ -15,7 +15,7 @@ import { demoTraining, describeTargets, startTraining, trainingBlocker } from ".** Making one starts a cover job, which is also what makes the board usable on the cloud: Recraft V4* Styles turns the 10 most representative images into a reusable style (its id comes back in- * meta.styleId) while drawing the cover; on the open engine Qwen-Image-Edit Style Reference draws+ * meta.styleId) while drawing the cover; on the open engine Krea 2 Style Reference draws* the cover from the board's collages. The status follows that job: In queue → In progress →* Preparing cover → Complete (or Failed, with Retry). A board can also be trained as a Z-Image Turbo style LoRA* (Fuobe Soul ID's style trainings, build plan O3: AI-Toolkit on the user's GPU or fal's Z-Image trainer in style@@ -38,8 +38,8 @@ interface Row {updated_at: number;}-/** The model that prepares a board (and draws its cover) on each engine. */-export const PREP_MODEL: Record<Engine, string> = { cloud: "recraft-4-style", open: "oss-style-qwen-edit" };+/** The model that prepares a board (and draws its cover) on each engine: on your GPU Krea 2 Style Reference (1–2 collages). */+export const PREP_MODEL: Record<Engine, string> = { cloud: "recraft-4-style", open: "oss-style-krea2" };function toMoodboard(r: Row): Moodboard {const images = JSON.parse(r.images_json) as string[];diff --git a/src/server/remove-object.ts b/src/server/remove-object.tsindex 35904fff..1de2205f 100644--- a/src/server/remove-object.ts+++ b/src/server/remove-object.ts@@ -206,7 +206,7 @@ async function planInput(body: RemovalBody, opts: { probe: boolean; preview?: bo}if (eraser.cleanFrame) {notes.push(- "Qwen-Image-Edit first makes a clean copy of the part's first frame with the person gone; MiniMax H3 with Akatz Labs' Person Remover LoRA then rebuilds what was behind them, 22 frames at a time from it, and the clip's sound goes back on",+ "Qwen-Image 2.1 first makes a clean copy of the part's first frame with the person gone; MiniMax H3 with Akatz Labs' Person Remover LoRA then rebuilds what was behind them, 22 frames at a time from it, and the clip's sound goes back on","People only — for an object, pick Wan 2.1 VACE + SAM 3.1","Needs the H3 Relay nodes on your ComfyUI (scripts/comfy/install-comfyui.sh with H3_RELAY=1) and 24 GB of VRAM with offloading (64–128 GB of RAM); the part runs at 24 fps",characterLicenceLine("open", "fuobe-character-swap").replace("nodes GPL-3.0", "H3 Relay nodes GPL-3.0"),diff --git a/tests/av-katana.test.ts b/tests/av-katana.test.tsindex 91741031..3d8c003d 100644--- a/tests/av-katana.test.ts+++ b/tests/av-katana.test.ts@@ -3,7 +3,7 @@ import os from "node:os";import path from "node:path";import { afterAll, beforeAll, describe, expect, it, vi } from "vitest";import type { Generation } from "@/lib/catalog/types";-import { detectCuts, finalKey, KEYFRAME_OFFSET, katanaStage, katanaSteps, nearestAspect, planSegments, refineCut, refineTimes, stepsToRedo } from "@/lib/av/katana";+import { detectCuts, finalKey, KEYFRAME_OFFSET, katanaStage, katanaSteps, nearestAspect, OPEN_KEYFRAME_PHOTOS, planSegments, refineCut, refineTimes, stepsToRedo } from "@/lib/av/katana";import { frameParams, frameRequest } from "@/lib/av/frames";vi.setConfig({ testTimeout: 150_000 });@@ -126,11 +126,11 @@ describe("katana steps", () => {expect(steps.map((s) => [s.key, s.request.modelId, s.request.op])).toEqual([["cut0", "oss-segment", "trim"],["frame0", "oss-extract-frame", "frame"],- ["key0", "oss-qwen-edit", "edit"],+ ["key0", "oss-qwen-image-21-turbo", "edit"],["move0", "fuobe-genjutsu-motion", "motion-transfer"],["cut1", "oss-segment", "trim"],["frame1", "oss-extract-frame", "frame"],- ["key1", "oss-qwen-edit", "edit"],+ ["key1", "oss-qwen-image-21-turbo", "edit"],["move1", "fuobe-genjutsu-motion", "motion-transfer"],["join", "oss-join-clips", "concat"],["final", "oss-mux", "mux"],@@ -140,8 +140,11 @@ describe("katana steps", () => {expect(steps[1].request.params).toEqual({ startTime: KEYFRAME_OFFSET, endTime: KEYFRAME_OFFSET + 0.5, extra: { frameIndex: 0 } });// The open motion model is told the segment's length (Fun Control would render its 81-frame default).expect(steps[3].request.params).toMatchObject({ duration: 4, resolution: "480p" });- // Qwen-Image-Edit gets the frame first, then two photos.- expect(steps[2]).toMatchObject({ after: "frame0", chain: [{ slot: "images", position: "first" }], request: { inputs: { images: ["/a.png", "/b.png"] } } });+ // Qwen-Image 2.1 Turbo gets the frame first, then three photos (its four images).+ expect(OPEN_KEYFRAME_PHOTOS).toBe(3);+ expect(steps[2]).toMatchObject({ after: "frame0", chain: [{ slot: "images", position: "first" }], request: { inputs: { images: ["/a.png", "/b.png", "/c.png"] } } });+ expect(steps[2].request.prompt).toMatch(/^Replace the main subject of image 1 with the subject shown in images 2 to 4, /);+ expect(katanaSteps({ engine: "open", reference: "/ref.mp4", photos: [...photos, "/d.png"], segments })[2].request.inputs?.images).toEqual(photos);expect(steps[3]).toMatchObject({ after: ["key0", "cut0"], chain: [{ slot: "images", position: "first" }, { slot: "video" }] });expect(steps[8]).toMatchObject({ after: ["move0", "move1"], chain: [{ slot: "videos" }, { slot: "videos" }] });expect(steps[9]).toMatchObject({ after: "join", chain: [{ slot: "video" }], request: { inputs: { audio: "/ref.mp4" } } });diff --git a/tests/character-swap.test.ts b/tests/character-swap.test.tsindex 008e854f..23e28ef2 100644--- a/tests/character-swap.test.ts+++ b/tests/character-swap.test.ts@@ -1,6 +1,7 @@import { describe, expect, it } from "vitest";import {alignFrames,+ ANCHOR_MODELS,anchorModel,anchorPrompt,CHARACTER_LICENCES,@@ -33,6 +34,7 @@ import {windowPlan,windowProblem,} from "@/lib/catalog/character-swap";+import { getModel } from "@/lib/catalog";import { licenceInfo, licenceTerms, NODE_PACKS } from "@/lib/licences";// Genjutsu's Character swap (docs/research/openjutsu-6.md): Openjutsu's prompt and limits, H3's windows and canvas,@@ -85,13 +87,16 @@ describe("Character swap: the prompt", () => {expect(brief).toMatch(/One full-aspect edited source frame\.$/);});- it("the anchor model per engine: GPT Image 2.5 Sunburst (low) or Nano Banana Pro in the cloud, Qwen-Image 2.1 (or Qwen-Image-Edit 2511) on your GPU", () => {+ it("the anchor model per engine: GPT Image 2.5 Sunburst (low) or Nano Banana Pro in the cloud, Qwen-Image 2.1 (or Krea 2 Identity Edit) on your GPU", () => {expect(anchorModel("cloud")).toMatchObject({ id: "gpt-image-2-5-sunburst", extra: { quality: "low" } });expect(anchorModel("cloud", "nano-banana-pro").id).toBe("nano-banana-pro");+ expect(ANCHOR_MODELS.open.map((m) => m.id)).toEqual(["oss-qwen-image-21", "oss-krea2-identity-edit"]);expect(anchorModel("open").id).toBe("oss-qwen-image-21");- expect(anchorModel("open", "oss-qwen-edit").id).toBe("oss-qwen-edit");- // Another engine's model falls back to the engine's own.+ expect(anchorModel("open", "oss-krea2-identity-edit")).toMatchObject({ id: "oss-krea2-identity-edit", label: "Krea 2 Identity Edit" });+ // A Qwen-Image-Edit 2511 pick saved before, or another engine's model, falls back to the engine's own.+ expect(anchorModel("open", "oss-qwen-edit").id).toBe("oss-qwen-image-21");expect(anchorModel("open", "nano-banana-pro").id).toBe("oss-qwen-image-21");+ for (const m of ANCHOR_MODELS.open) expect(getModel(m.id)?.engine, m.id).toBe("open");});});diff --git a/tests/default-prompts-positive.test.ts b/tests/default-prompts-positive.test.tsnew file mode 100644index 00000000..3ca60a11--- /dev/null+++ b/tests/default-prompts-positive.test.ts@@ -0,0 +1,77 @@+import { describe, expect, it } from "vitest";+import { COVER_PROMPT } from "@/components/moodboards/logic";+import { getPreset } from "@/lib/catalog";+import { anchorPrompt } from "@/lib/catalog/character-swap";+import { relightWords } from "@/lib/catalog/dop";+import { customPack, getPack, SHEET_PROMPT, shotPrompt } from "@/lib/catalog/packs";+import { SHEET_FRONT_PROMPT } from "@/lib/catalog/turnaround";+import type { Preset } from "@/lib/catalog/types";+import { ENHANCE_LOOKS, enhancePrompt, RELIGHT_DIRECTIONS, RELIGHT_LIGHTS, relightPrompt } from "@/lib/layers";++// Default prompts name only what is wanted: an unwanted thing, even negated ("no text", "without a cut"), tends to+// show up in the picture or the clip.+const NEGATION = /\b(no|not|never|nothing|none|without|don't|do not|doesn't|avoid)\b/i;++/** A preset's words with every choice of every option filled in. */+function everyWording(p: Preset): string[] {+ const base = p.promptTemplate.replace(/\{prompt\}/g, "");+ const options = p.options ?? [];+ if (!options.length) return [base];+ return options.flatMap((o) => o.choices.map((c) => base.replace(`{option:${o.key}}`, c.prompt)));+}++describe("default prompts name only what is wanted", () => {+ it("the apps' rewritten prompts: Expand Image, Outfit Swap, Hook Frame, Transitions, Skin Enhancer", () => {+ for (const id of ["app-expand-image", "app-outfit-swap", "app-hook-frame", "app-transitions", "app-skin-enhancer"]) {+ const p = getPreset(id);+ expect(p, id).toBeDefined();+ for (const words of everyWording(p!)) expect(words, id).not.toMatch(NEGATION);+ }+ expect(getPreset("app-transitions")!.promptTemplate).toMatch(/One continuous shot/);+ expect(getPreset("app-expand-image")!.promptTemplate).toMatch(/fill the new area with more of the same surroundings/);+ expect(getPreset("app-outfit-swap")!.promptTemplate).toMatch(/only the clothing comes from the second image/);+ });++ it("the motions and effects: Pedestal Down, Skate Cruise, One Take, Explosion", () => {+ for (const id of ["motion-pedestal-down", "motion-skate-cruise", "motion-one-take", "effect-explosion"]) {+ const p = getPreset(id);+ expect(p, id).toBeDefined();+ expect(p!.promptTemplate, id).not.toMatch(NEGATION);+ }+ expect(getPreset("motion-one-take")!.promptTemplate).toMatch(/one unbroken take/);+ });++ it("the Character Sheet, Turnaround's front view and Character Swap's anchor frame", () => {+ expect(SHEET_PROMPT).not.toMatch(NEGATION);+ expect(SHEET_FRONT_PROMPT).not.toMatch(NEGATION);+ expect(anchorPrompt({})).not.toMatch(NEGATION);+ expect(anchorPrompt({ description: "a ronin in black armour", who: "leftmost" })).not.toMatch(NEGATION);+ expect(anchorPrompt({})).toMatch(/every garment they wear comes from image 2/);+ });++ it("Photodump's photo words, a moodboard's cover and the Layers retouch and relight words", () => {+ const selfie = { kind: "selfie" as const, url: "/api/files/uploads/me.png" };+ const pack = getPack("winter-special")!;+ expect(shotPrompt(pack, pack.shots[0], selfie)).not.toMatch(NEGATION);+ const mine = customPack({ id: "user-1", name: "Mine", refs: ["/api/files/uploads/a.png"] });+ expect(shotPrompt(mine, mine.shots[0], selfie, 2)).not.toMatch(NEGATION);+ expect(COVER_PROMPT("Neon Haze")).not.toMatch(NEGATION);+ for (const look of ENHANCE_LOOKS) expect(enhancePrompt(look.id) ?? "", look.id).not.toMatch(NEGATION);+ for (const [, light] of RELIGHT_LIGHTS) {+ for (const [, direction] of RELIGHT_DIRECTIONS) {+ for (const model of ["oss-qwen-image-21-turbo", "oss-krea2-edit", "oss-qwen-relight"]) expect(relightPrompt(model, light, direction)).not.toMatch(NEGATION);+ }+ }+ });++ it("Fuobe DoP's relight effects: Qwen-Image 2.1 Turbo's start-frame words", () => {+ for (const id of ["effect-silhouette", "effect-practicals", "effect-window", "effect-overhead-fall", "effect-contre-jour", "effect-soft-cross"]) {+ const step = getPreset(id)!.prestep!.open;+ expect(step.prompt, id).not.toMatch(NEGATION);+ expect(step.prompt, id).toMatch(/^Relight <image1>: /);+ }+ expect(relightWords("soft natural window light")).toBe(+ "Relight <image1>: soft natural window light. Keep every person, face, pose, object, the setting and the framing exactly as in <image1>, same film grain.",+ );+ });+});diff --git a/tests/dop-originals.test.ts b/tests/dop-originals.test.tsindex de3d5b2e..45452159 100644--- a/tests/dop-originals.test.ts+++ b/tests/dop-originals.test.ts@@ -229,7 +229,8 @@ describe("effects as steps", () => {const req = { feature: "motion", modelId: "fuobe-dop", presetId: "effect-window", prompt: "a woman reading", inputs: { images: ["/api/files/uploads/a.png"] } };for (const engine of ["open", "cloud"] as const) {const [clip, relit] = createGenerations({ ...req, engine });- expect(relit.modelId).toBe(engine === "open" ? "oss-qwen-relight" : "qwen-image-edit-2509-cloud");+ expect(relit.modelId).toBe(engine === "open" ? "oss-qwen-image-21-turbo" : "qwen-image-edit-2509-cloud");+ if (engine === "open") expect(relit.prompt).toMatch(/^Relight <image1>: soft natural window light from the side/);expect(relit.op).toBe("edit");expect(clip.modelId).toBe("fuobe-dop");expect(clip.engine).toBe(engine);diff --git a/tests/evolution-api.test.ts b/tests/evolution-api.test.tsindex 1ba116d3..58c810fb 100644--- a/tests/evolution-api.test.ts+++ b/tests/evolution-api.test.ts@@ -61,7 +61,7 @@ describe("Evolution: estimates", () => {expect(cloud.notes.join(" ")).toMatch(/LTX-2.3 takes no pictures: your reference shapes the direction/);const open = await (await estimateRoute.POST(json(body({ engine: "open" })))).json();expect(open).toMatchObject({ engine: "open", resolution: "480p", pieces: 3, costUsd: 0 });- expect(open.notes.join(" ")).toMatch(/Qwen-Image-Edit takes its first frame toward the direction with your first reference/);+ expect(open.notes.join(" ")).toMatch(/Qwen-Image 2.1 Turbo takes its first frame toward the direction with your first reference/);});describe("with a fal key (estimates submit nothing)", () => {@@ -159,7 +159,7 @@ describe("Evolution: runs (demo)", () => {expect(direction).toBe("A paper-cut diorama world with layered card stock.");const rows = batchOf(final.id);expect(rows.filter((r) => r.model_id === "fuobe-evolution")).toHaveLength(3);- expect(rows.filter((r) => r.model_id === "oss-qwen-edit")).toHaveLength(3);+ expect(rows.filter((r) => r.model_id === "oss-qwen-image-21-turbo")).toHaveLength(3);const evolve = gens.getGeneration(rows.find((r) => r.model_id === "fuobe-evolution")!.id)!;expect(evolve.request).toMatchObject({ engine: "open", params: { extra: { denoise: 0.85 } } });const done = await settle(final.id);diff --git a/tests/evolution.test.ts b/tests/evolution.test.tsindex 7446c9a4..d6b6b229 100644--- a/tests/evolution.test.ts+++ b/tests/evolution.test.ts@@ -133,16 +133,21 @@ describe("Fuobe Evolution: the plan", () => {expect(step(plan({ source: { ...clip, width: 1080, height: 1920 } }), "evolve0").request.params?.aspectRatio).toBe("9:16");});- it("GPU: per ≤81-frame segment, cut at 16 fps, the direction frame with two references, the graph at the intensity's denoise", () => {+ it("GPU: per ≤81-frame segment, cut at 16 fps, the direction frame with three references, the graph at the intensity's denoise", () => {const p = plan({ engine: "open", intensity: "low" });// 12 s at 16 fps = 192 frames → 3 segments of 4n+1 frames.expect(p.pieces).toBe(3);- expect(p.referencesUsed).toBe(2);+ // Qwen-Image 2.1 Turbo takes four images: the frame and three references.+ expect(EVOLUTION.openReferences).toBe(3);+ expect(p.referencesUsed).toBe(3);expect(step(p, "cut0").request).toMatchObject({ modelId: "oss-segment", op: "trim", params: { fps: 16, aspectRatio: "auto", resolution: "480p" } });const frame = step(p, "frame0");- expect(frame.request).toMatchObject({ modelId: "oss-qwen-edit", op: "edit", inputs: { images: refs.slice(0, 2) } });+ expect(frame.request).toMatchObject({ modelId: "oss-qwen-image-21-turbo", op: "edit", inputs: { images: refs.slice(0, 3) } });expect(frame.request.prompt).toMatch(/^Refine image 1 gently toward this direction: A neon-lit night market in the rain\. Keep the composition, the people/);- expect(frame.request.prompt).toMatch(/images 2 and 3/);+ expect(frame.request.prompt).toMatch(/Use the characters, objects and style of images 2, 3 and 4 where they fit\.$/);+ expect(directionFramePrompt("x", "medium", 1)).toMatch(/of image 2 where they fit\.$/);+ expect(directionFramePrompt("x", "medium", 2)).toMatch(/of images 2 and 3 where they fit\.$/);+ expect(directionFramePrompt("x", "medium", 0)).not.toMatch(/image 2/);expect(frame).toMatchObject({ after: ["cut0"], chain: [{ slot: "images", position: "first" }] });const e = step(p, "evolve0");expect(e.request).toMatchObject({ modelId: "fuobe-evolution", engine: "open", op: "v2v", prompt: "A neon-lit night market in the rain.", params: { aspectRatio: "auto", resolution: "480p", extra: { denoise: 0.45 } } });diff --git a/tests/genjutsu.test.ts b/tests/genjutsu.test.tsindex 7af8ed79..8cf14c75 100644--- a/tests/genjutsu.test.ts+++ b/tests/genjutsu.test.ts@@ -255,7 +255,9 @@ describe("Genjutsu: plans", () => {it("open restyle on the Original: the Shorts chain on the Original's graph; a Soul look's frame on Fuobe Soul", () => {const open = plan({ mode: "restyle", maker: maker(ORIGINALS.restyle, "open"), look: { kind: "custom", images: [ref, "/api/files/b.png", "/api/files/c.png"] }, references: [] });expect(open.steps.find((s) => s.request.modelId === "oss-segment")!.request.params?.aspectRatio).toBe("auto");- expect(open.steps.find((s) => s.request.modelId === "oss-qwen-edit")!.request.inputs?.images).toEqual([ref, "/api/files/b.png"]);+ // The first frame in the look: Qwen-Image 2.1 Turbo on your GPU (hosted Qwen-Image-Edit 2511 in the cloud).+ expect(open.steps.find((s) => s.request.modelId === "oss-qwen-image-21-turbo")!.request.inputs?.images).toEqual([ref, "/api/files/b.png"]);+ expect(open.steps.some((s) => s.request.modelId === "oss-qwen-edit")).toBe(false);const look = open.steps.find((s) => s.request.modelId === ORIGINALS.restyle)!.request;expect(look).toMatchObject({ engine: "open", op: "v2v" });const soul = plan({ mode: "restyle", maker: maker(ORIGINALS.restyle, "open"), look: { kind: "soul", id: "v1-general" }, references: [], range: { start: 0, end: 5 } });@@ -377,9 +379,12 @@ describe("Genjutsu: Character swap", () => {const planned = planGeneration({ ...sunburst, inputs: { images: ["/api/files/f.png", ref] } }, getModel, getPreset);expect(planned.params.aspectRatio).toBe("16:9");// On your GPU the first frame keeps the frame's own size: Qwen-Image 2.1 gets the nearest ratio, which its edit graph- // doesn't read (the result follows image 1), and Qwen-Image-Edit 2511 is asked none.+ // doesn't read (the result follows image 1), and Krea 2 Identity Edit "auto" (its canvas in image 1's shape).expect(step(ch({ maker: maker(ORIGINALS.character, "open") }), "anchor").request.params?.aspectRatio).toBe("16:9");- expect(step(ch({ maker: maker(ORIGINALS.character, "open"), character: { anchorModel: "oss-qwen-edit" } }), "anchor").request.params?.aspectRatio).toBeUndefined();+ const krea = step(ch({ maker: maker(ORIGINALS.character, "open"), character: { anchorModel: "oss-krea2-identity-edit" } }), "anchor").request;+ expect(krea).toMatchObject({ modelId: "oss-krea2-identity-edit", op: "edit", params: { aspectRatio: "auto" } });+ // A Qwen-Image-Edit 2511 pick saved before falls back to the engine's default.+ expect(step(ch({ maker: maker(ORIGINALS.character, "open"), character: { anchorModel: "oss-qwen-edit" } }), "anchor").request.modelId).toBe("oss-qwen-image-21");});it("cloud: a silent clip's result is silent too (H3's own soundtrack is replaced with silence)", () => {diff --git a/tests/image-studios-api.test.ts b/tests/image-studios-api.test.tsindex 972be8a6..9c4ec59c 100644--- a/tests/image-studios-api.test.ts+++ b/tests/image-studios-api.test.ts@@ -146,7 +146,7 @@ describe("moodboards", () => {expect((await noName.json()).error).toBe("Please enter a moodboard name");});- it("builds a board through its cover job (open: collages on Qwen-Image-Edit Style Reference), then it's usable", async () => {+ it("builds a board through its cover job (open: collages on Krea 2 Style Reference), then it's usable", async () => {const images = Array.from({ length: 6 }, upload);const res = await moodboardsRoute.POST(json("POST", { name: "Neon Haze", images, collages: [upload()], engine: "open" }));expect(res.status).toBe(201);@@ -154,7 +154,9 @@ describe("moodboards", () => {expect(["queued", "running", "cover"]).toContain(m.status);expect(m.refs).toEqual(images);const g = gens.getGeneration(m.generationId)!;- expect(g.modelId).toBe("oss-style-qwen-edit");+ // Krea 2 Style Reference: trained for style reference, the same one or two collages as references.+ expect(g.modelId).toBe("oss-style-krea2");+ expect(g.prompt).toMatch(/^A moodboard cover for “Neon Haze”: one striking, purely visual image/);expect(g.feature).toBe("moodboard");expect(g.request.inputs?.images).toEqual(m.collages);await settle(m.generationId);@@ -304,8 +306,12 @@ describe("photodump, fashion factory and character sheet runs", () => {expect(preview.modelId).toBe("oss-qwen-image-21");expect(preview.fixedAspect).toBe(true);expect(preview.notes.join()).toMatch(/Qwen-Image 2.1 keeps the shape of your photo/);+ // A Qwen-Image-Edit 2511 pick saved before runs on Qwen-Image 2.1.const old = await (await photodumpRoute.POST(json("POST", { packId: "winter-special", engine: "open", selfie: upload(), aspectRatio: "16:9", modelId: "oss-qwen-edit" }, "http://x/api/photodump?preview=1"))).json();- expect(old).toMatchObject({ modelId: "oss-qwen-edit", fixedAspect: true });+ expect(old).toMatchObject({ modelId: "oss-qwen-image-21", fixedAspect: true });+ // Krea 2 Identity Edit draws on a canvas of the shape asked for.+ const krea = await (await photodumpRoute.POST(json("POST", { packId: "winter-special", engine: "open", selfie: upload(), aspectRatio: "16:9", modelId: "oss-krea2-identity-edit" }, "http://x/api/photodump?preview=1"))).json();+ expect(krea).toMatchObject({ modelId: "oss-krea2-identity-edit", fixedAspect: false });const cloud = await (await photodumpRoute.POST(json("POST", { packId: "winter-special", engine: "cloud", selfie: upload(), aspectRatio: "16:9" }, "http://x/api/photodump?preview=1"))).json();expect(cloud.fixedAspect).toBe(false);// Picking Fuobe Soul with a selfie says why it runs on Qwen-Image-Edit.diff --git a/tests/image-studios.test.ts b/tests/image-studios.test.tsindex 32024f30..561a7b9e 100644--- a/tests/image-studios.test.ts+++ b/tests/image-studios.test.ts@@ -14,6 +14,7 @@ import {coverTone,customPack,FASHION,+ FASHION_MODELS,FASHION_START,fashionBaseRequest,fashionBlocker,@@ -22,6 +23,7 @@ import {fashionReducer,getPack,PACKS,+ PHOTODUMP_MODELS,photodumpModel,planPhotodump,randomCast,@@ -169,10 +171,10 @@ describe("palettes: routing per model", () => {const listed = slice.models.map((m) => m.id);const known = new Set([...listed, ...(slice.lookup ?? []).map((m) => m.id)]);for (const id of Object.values(SIGNATURE_MODELS)) expect(known.has(id), id).toBe(true);- // Edit-only and hidden routing targets stay out of the picker list (Qwen-Image-Edit Style Reference is a- // text-to-image model, listed already); their field maps stay on the server.+ // Edit-only and hidden routing targets stay out of the picker list (Krea 2 Style Reference is a text-to-image+ // model, listed already); their field maps stay on the server.for (const id of ["recraft-4-style", "recraft-4-style-saved", "oss-palette-image"]) expect(listed, id).not.toContain(id);- expect(listed).toContain("oss-style-qwen-edit");+ expect(listed).toContain("oss-style-krea2");expect((slice.lookup ?? []).every((m) => m.routes.every((r) => !r.map))).toBe(true);});@@ -293,11 +295,13 @@ describe("moodboards: routing per model", () => {expect(plan(fresh.request).op).toBe("edit");});- it("open engine: collages on Qwen-Image-Edit Style Reference, single refs on FLUX.2 klein, the trained LoRA on Z-Image Turbo", () => {+ it("open engine: collages on Krea 2 Style Reference, single refs on FLUX.2 klein, the trained LoRA on Z-Image Turbo", () => {const def = applySignature(req("oss-z-image-turbo"), { moodboard: board }, ctx);- expect(def.modelId).toBe("oss-style-qwen-edit");+ expect(def.modelId).toBe("oss-style-krea2");expect(def.request.inputs?.images).toEqual(board.collages);expect(() => plan(def.request)).not.toThrow();+ // The 2511 style graph still runs a board when it is picked.+ expect(applySignature(req("oss-style-qwen-edit"), { moodboard: board }, ctx).modelId).toBe("oss-style-qwen-edit");const klein = applySignature(req("oss-style-flux2-klein"), { moodboard: board }, ctx);expect(klein.modelId).toBe("oss-style-flux2-klein");@@ -372,7 +376,7 @@ describe("moodboards: routing per model", () => {expect(applySignature(req("nano-banana-pro"), { moodboard: { ...board, status: "running" } }, ctx).blocker).toBe("This moodboard is still training. Try again once it is ready.");const both = applySignature(req("oss-z-image-turbo"), { moodboard: board, palette: PAL }, ctx);// The moodboard moves it to the style model, which then gets the palette in words (not the palette model).- expect(both.modelId).toBe("oss-style-qwen-edit");+ expect(both.modelId).toBe("oss-style-krea2");expect(said(both)).toMatch(/Color palette/);});});@@ -549,7 +553,15 @@ describe("Photodump: model choice and retries", () => {it("says why a pick that can't run ends up on another model", () => {expect(photodumpModel(selfie, "open", {}, "fuobe-soul")).toEqual({ modelId: "oss-qwen-image-21", note: "Fuobe Soul needs a character with a trained Soul ID — Qwen-Image 2.1 works from your photo" });- expect(photodumpModel(selfie, "open", {}, "oss-qwen-edit").modelId).toBe("oss-qwen-edit");+ // Your GPU's choices after Fuobe Soul: Qwen-Image 2.1, Krea 2 Identity Edit and Qwen-Image 2.1 Turbo.+ expect(PHOTODUMP_MODELS.open).toEqual(["fuobe-soul", "oss-qwen-image-21", "oss-krea2-identity-edit", "oss-qwen-image-21-turbo"]);+ expect(PHOTODUMP_MODELS.cloud).toEqual(["fuobe-soul", "qwen-image-edit-2511-cloud", "nano-banana-pro", "nano-banana-2-1", "seedream-5-pro"]);+ expect(photodumpModel(selfie, "open", {}, "oss-krea2-identity-edit").modelId).toBe("oss-krea2-identity-edit");+ expect(photodumpModel(selfie, "open", {}, "oss-qwen-image-21-turbo").modelId).toBe("oss-qwen-image-21-turbo");+ expect(photodumpModel(selfie, "cloud", {}, "nano-banana-2-1").modelId).toBe("nano-banana-2-1");+ // A pick of Qwen-Image-Edit 2511 saved before runs on Qwen-Image 2.1.+ expect(photodumpModel(selfie, "open", {}, "oss-qwen-edit").modelId).toBe("oss-qwen-image-21");+ expect(photodumpModel(selfie, "open", {}, "fuobe-soul", true).note).toBe("Your own packs recreate each reference photo — Qwen-Image 2.1 runs them");expect(photodumpModel(selfie, "cloud", {}, "fuobe-soul")).toEqual({ modelId: "qwen-image-edit-2511-cloud", note: "Fuobe Soul needs a character with a trained Soul ID — Qwen-Image-Edit 2511 works from your photo" });expect(photodumpModel(selfie, "cloud", {}, "nano-banana-pro").modelId).toBe("nano-banana-pro");expect(photodumpModel(selfie, "cloud", {}).modelId).toBe("qwen-image-edit-2511-cloud");@@ -608,7 +620,16 @@ describe("Fashion Factory", () => {expect(set[0]).toMatchObject({ modelId: "qwen-image-edit-2511-cloud", inputs: { images: ["/api/files/dressed.png"] }, step: { label: `Photoset 1 of ${t.shots}` } });expect(fashionPhotosetRequests(t, "/api/files/dressed.png", "cloud", "nano-banana-pro")[0].modelId).toBe("nano-banana-pro");expect(fashionPhotosetRequests(t, "/api/files/dressed.png", "open")[0].modelId).toBe("oss-qwen-image-21");- expect(fashionPhotosetRequests(t, "/api/files/dressed.png", "open", "oss-qwen-edit")[0].modelId).toBe("oss-qwen-edit");+ expect(fashionPhotosetRequests(t, "/api/files/dressed.png", "open", "oss-krea2-identity-edit")[0].modelId).toBe("oss-krea2-identity-edit");+ // A pick the step no longer lists falls back to its first model.+ expect(fashionPhotosetRequests(t, "/api/files/dressed.png", "open", "oss-qwen-edit")[0].modelId).toBe("oss-qwen-image-21");+ // When the try-on can't run on your GPU: Qwen-Image 2.1 Turbo, then Krea 2 Identity Edit, both dressing from image 2.+ expect(FASHION_MODELS.outfit.open).toEqual(["fuobe-tryon", "oss-qwen-image-21-turbo", "oss-krea2-identity-edit"]);+ expect(FASHION_MODELS.photoset.open).toEqual(["oss-qwen-image-21", "oss-krea2-identity-edit"]);+ expect(fashionOutfitRequest(t, "/api/files/base.png", "/api/files/shirt.png", "open", undefined, { has: (id) => id !== "fuobe-tryon" }).modelId).toBe("oss-qwen-image-21-turbo");+ const dressed = fashionOutfitRequest(t, "/api/files/base.png", "/api/files/shirt.png", "open", "oss-krea2-identity-edit");+ expect(dressed).toMatchObject({ modelId: "oss-krea2-identity-edit", op: "edit", inputs: { images: ["/api/files/base.png", "/api/files/shirt.png"] } });+ expect(() => plan(dressed)).not.toThrow();});it("walks the wizard with Higgsfield's validation messages", () => {@@ -647,8 +668,23 @@ describe("Fashion Factory", () => {});});+describe("apps on the newer tools", () => {+ it("Upscale on SeedVR2 (image) on your GPU, the avatar apps on Kling Avatar 2.0, and the sound note says which clips are silent", () => {+ expect(getPreset("app-upscale")!.open).toMatchObject({ modelId: "oss-seedvr2-image", op: "upscale-image" });+ for (const id of ["app-talking-photo", "app-asmr-host", "app-asmr-promo"]) {+ expect(getPreset(id)!.cloud, id).toMatchObject({ modelId: "kling-avatar-2", op: "avatar" });+ }+ // Kling Avatar 2.0 takes what Kling AI Avatar took: the portrait and the voice.+ const map = (id: string) => getModel(id)!.routes.find((r) => r.op === "avatar")!.map;+ expect(map("kling-avatar-2")).toEqual(map("kling-avatar"));+ expect(getPreset("app-asmr-classic")!.parity).toBe(+ "MiniMax H3 makes its own sound; Kling 2.5 Turbo and Wan 2.2 clips are silent — add sound to them with the Audio → Video to audio tool",+ );+ });+});+describe("Character Sheet", () => {- it("From Reference takes 1–5 photos (3 on the open route)", () => {+ it("From Reference takes 1–5 photos (4 on the open route, Qwen-Image 2.1)", () => {const imgs = Array.from({ length: 5 }, (_, i) => `/api/files/uploads/p${i}.png`);expect(() => sheetFromReference([], "cloud")).toThrow("Upload at least 1 image");expect(() => sheetFromReference([...imgs, "x"], "cloud")).toThrow("Maximum 5 images");@@ -656,9 +692,15 @@ describe("Character Sheet", () => {expect(cloud.request).toMatchObject({ modelId: "nano-banana-pro", op: "edit", inputs: { images: imgs } });expect(cloud.request.prompt).toMatch(/turnaround sheet.*freckles\.$/);const open = sheetFromReference(imgs, "open");- expect(open.request.inputs?.images).toHaveLength(3);- expect(open.notes[0]).toMatch(/first 3/);- expect(() => plan(open.request)).not.toThrow();+ // Qwen-Image 2.1 at 25 steps: a sheet is camera turns, which its Turbo misses.+ expect(open.request).toMatchObject({ modelId: "oss-qwen-image-21", op: "edit" });+ expect(open.request.inputs?.images).toEqual(imgs.slice(0, 4));+ expect(open.notes[0]).toBe("Qwen-Image 2.1 takes 4 photos — the first 4 are used");+ expect(open.notes[1]).toMatch(/^Qwen-Image 2.1 keeps the shape of your first photo/);+ expect(sheetFromReference(imgs.slice(0, 4), "open").notes).toHaveLength(1);+ const planned = plan(open.request);+ expect(planned.op).toBe("edit");+ expect(planned.model.routes.find((r) => r.op === "edit")!.endpoint).toBe("qwen-image-21-edit");});it("Build from scratch runs on Fuobe Soul (Nano Banana Pro when it is switched off) or the Soul Cast sheet workflow", () => {diff --git a/tests/influencer-api.test.ts b/tests/influencer-api.test.tsindex cc6a1e1a..f11a16da 100644--- a/tests/influencer-api.test.ts+++ b/tests/influencer-api.test.ts@@ -60,8 +60,8 @@ describe("/api/influencer", () => {it("prices the open sheet as free, in two steps with a face", async () => {const face = upload();const open = await (await post({ engine: "open", state, start: "face", photo: face }, true)).json();- expect(open).toMatchObject({ modelId: "oss-qwen-edit", count: 1, steps: 2 });- expect(open.notes).toEqual(["Two steps: Z-Image Turbo draws the sheet, then Qwen-Image-Edit 2511 puts your face on it"]);+ expect(open).toMatchObject({ modelId: "oss-qwen-image-21", count: 1, steps: 2 });+ expect(open.notes).toEqual(["Two steps: Z-Image Turbo draws the sheet, then Qwen-Image 2.1 puts your face on it"]);});it("makes the open sheet, then puts the face on it, as one batch (demo)", async () => {@@ -71,7 +71,7 @@ describe("/api/influencer", () => {const run = await res.json();expect(run.items.map((g: { feature: string; modelId: string }) => [g.feature, g.modelId])).toEqual([["influencer-step", "oss-zimage-soul-cast"],- ["influencer", "oss-qwen-edit"],+ ["influencer", "oss-qwen-image-21"],]);// The Soul Cast sheet graph runs in Fuobe Soul's casting look: its words and LoRAs around the compiled character.expect(run.items[0].prompt).toContain(compileCastPrompt({ state: state as never, direction: "A potter from Porto" }));@@ -97,7 +97,7 @@ describe("/api/influencer", () => {const again = retryPhoto(pass.id);expect(again.map((g) => [g.feature, g.modelId, g.batchId])).toEqual([["influencer-step", "oss-zimage-soul-cast", run.batchId],- ["influencer", "oss-qwen-edit", run.batchId],+ ["influencer", "oss-qwen-image-21", run.batchId],]);expect(gens.getGeneration(pass.id)).toBeNull();const redone = await settle(again[1].id);@@ -120,7 +120,7 @@ describe("/api/influencer", () => {expect(gens.getGeneration(pass.id)!.request.inputs?.images).toEqual([face]);// Only the pass runs again: it waits for the finished sheet, then gets it as image 1.const again = retryPhoto(pass.id);- expect(again.map((g) => [g.feature, g.modelId, g.batchId])).toEqual([["influencer", "oss-qwen-edit", run.batchId]]);+ expect(again.map((g) => [g.feature, g.modelId, g.batchId])).toEqual([["influencer", "oss-qwen-image-21", run.batchId]]);expect(gens.getGeneration(pass.id)).toBeNull();const redone = await settle(again[0].id);expect(redone.status).toBe("succeeded");diff --git a/tests/influencer-comfy.test.ts b/tests/influencer-comfy.test.tsindex 46642f7b..e48dbff7 100644--- a/tests/influencer-comfy.test.ts+++ b/tests/influencer-comfy.test.ts@@ -6,7 +6,7 @@ import type { GenInput, Operation } from "@/lib/catalog/types";import { compileCastPrompt, compileDressPrompt, planInfluencer, type InfluencerState } from "@/lib/influencer";// The comfyui provider driving the AI Influencer builder's open engine on the library graphs: the Soul Cast-// sheet (Z-Image Turbo) with the compiled character, then Qwen-Image-Edit 2511 with the sheet first.+// sheet (Z-Image Turbo) with the compiled character, then Qwen-Image 2.1 with the sheet first.const tmp = fs.mkdtempSync(path.join(os.tmpdir(), "fuobe-influencer-comfy-"));process.env.FUOBE_DATA_DIR = tmp;process.env.COMFYUI_URL = "http://comfy.test:8188";@@ -27,20 +27,22 @@ describe("the builder's open engine through the provider", () => {expect(at(wf, "24", "seed")).toBe(11);});- it("Qwen-Image-Edit 2511: the sheet is image 1, your face image 2, the clothing image 3", async () => {- const plan = planInfluencer({ engine: "open", state, start: "face", photo: "face.png", clothing: ["coat.png", "boots.png"] }, {});+ it("Qwen-Image 2.1: the sheet is image 1, your face image 2, the clothing images 3 and 4", async () => {+ const plan = planInfluencer({ engine: "open", state, start: "face", photo: "face.png", clothing: ["coat.png", "boots.png", "hat.png"] }, {});const dress = plan.steps[1].request;+ expect(dress.modelId).toBe("oss-qwen-image-21");// What the chain hands the step when the sheet is done (position "first").const images = ["sheet.png", ...(dress.inputs?.images ?? [])];- const { workflow: wf } = await prepare("qwen-image-edit-2511-multi", { prompt: dress.prompt, images, seed: 3 }, "edit");- expect([at(wf, "41", "image"), at(wf, "83", "image"), at(wf, "1201", "image")]).toEqual(["sheet.png", "face.png", "coat.png"]);- expect(at(wf, "170:151", "prompt")).toBe(compileDressPrompt({ state, start: "face", clothing: 1 }));+ expect(images).toEqual(["sheet.png", "face.png", "coat.png", "boots.png"]);+ const { workflow: wf } = await prepare("qwen-image-21-edit", { prompt: dress.prompt, images, seed: 3 }, "edit");+ expect([at(wf, "10", "image"), at(wf, "11", "image"), at(wf, "12", "image"), at(wf, "13", "image")]).toEqual(["sheet.png", "face.png", "coat.png", "boots.png"]);+ expect(at(wf, "30", "prompt")).toBe(compileDressPrompt({ state, start: "face", clothing: 2 }));});- it("with the face only, image 3 repeats the face (the graph's third slot is always wired)", async () => {+ it("with the face only, the sheet and the face reach the graph", async () => {const plan = planInfluencer({ engine: "open", state, start: "face", photo: "face.png" }, {});const dress = plan.steps[1].request;- const { workflow: wf } = await prepare("qwen-image-edit-2511-multi", { prompt: dress.prompt, images: ["sheet.png", ...(dress.inputs?.images ?? [])] }, "edit");- expect([at(wf, "41", "image"), at(wf, "83", "image"), at(wf, "1201", "image")]).toEqual(["sheet.png", "face.png", "face.png"]);+ const { workflow: wf } = await prepare("qwen-image-21-edit", { prompt: dress.prompt, images: ["sheet.png", ...(dress.inputs?.images ?? [])] }, "edit");+ expect([at(wf, "10", "image"), at(wf, "11", "image")]).toEqual(["sheet.png", "face.png"]);});});diff --git a/tests/influencer.test.ts b/tests/influencer.test.tsindex 7e4687c5..b8dfc6de 100644--- a/tests/influencer.test.ts+++ b/tests/influencer.test.ts@@ -24,6 +24,7 @@ import {influencerName,optionVisible,PHRASES,+ OPEN_EDIT_IMAGES,planInfluencer,RAIL_ORDER,resetPicks,@@ -521,21 +522,26 @@ describe("the plan per engine", () => {valid(p);});- it("open with your face: the sheet, then Qwen-Image-Edit 2511 puts the face (and one clothing reference) on it", () => {+ it("open with your face: the sheet, then Qwen-Image 2.1 puts the face (and two clothing references) on it", () => {+ expect(clothes).toHaveLength(3);+ expect(OPEN_EDIT_IMAGES).toBe(4);const p = planInfluencer(run({ engine: "open", start: "face", photo: face, clothing: clothes }), ALL);- expect(p.modelId).toBe("oss-qwen-edit");+ expect(p.modelId).toBe("oss-qwen-image-21");expect(p.steps.map((s) => [s.key, s.request.feature, s.request.modelId, s.after])).toEqual([["sheet", "influencer-step", "oss-zimage-soul-cast", undefined],- ["dress", "influencer", "oss-qwen-edit", "sheet"],+ ["dress", "influencer", "oss-qwen-image-21", "sheet"],]);expect(p.steps[1].chain).toEqual([{ slot: "images", position: "first" }]);- expect(p.steps[1].request.inputs?.images).toEqual([face, clothes[0]]);- expect(p.steps[1].request.prompt).toBe(compileDressPrompt({ state, start: "face", clothing: 1 }));- expect(p.notes[0]).toBe("Qwen-Image-Edit takes 3 images (the sheet, your photo and clothing) — the first clothing reference is used");+ // The sheet (chained in first), your face and two clothing references: Qwen-Image 2.1's four images.+ expect(p.steps[1].request.inputs?.images).toEqual([face, clothes[0], clothes[1]]);+ expect(p.steps[1].request.prompt).toBe(compileDressPrompt({ state, start: "face", clothing: 2 }));+ expect(p.notes[0]).toBe("Qwen-Image 2.1 takes 4 images (the sheet, your photo and clothing) — the first 2 clothing references are used");+ expect(p.notes[1]).toBe("Two steps: Z-Image Turbo draws the sheet, then Qwen-Image 2.1 puts your face on it");valid(p);+ // Without a photo, all three clothing references fit beside the sheet.const dressed = planInfluencer(run({ engine: "open", clothing: clothes }), ALL);- expect(dressed.steps[1].request.inputs?.images).toEqual(clothes.slice(0, 2));- expect(dressed.notes).toEqual(["Qwen-Image-Edit takes 3 images (the sheet and clothing) — the first 2 clothing references are used", "Two steps: Z-Image Turbo draws the sheet, then Qwen-Image-Edit 2511 dresses it in your clothing"]);+ expect(dressed.steps[1].request.inputs?.images).toEqual(clothes);+ expect(dressed.notes).toEqual(["Two steps: Z-Image Turbo draws the sheet, then Qwen-Image 2.1 dresses it in your clothing"]);// A photo only matters when the run starts from it.expect(planInfluencer(run({ engine: "open", start: "scratch", photo: face }), ALL).steps).toHaveLength(1);});diff --git a/tests/layers-api.test.ts b/tests/layers-api.test.tsindex 9f2212c3..fe846f5e 100644--- a/tests/layers-api.test.ts+++ b/tests/layers-api.test.ts@@ -157,7 +157,8 @@ describe("job steps", () => {prompt: "a vase of tulips. Blend it into the surroundings with matching light, perspective and grain.",inputs: { images: ["/api/files/a.png"], mask: "/api/files/m.png", sketch: "/api/files/s.png" },});- expect(steps({ ...paint, modelId: "flux-fill-pro" })[0].request).toMatchObject({ modelId: "flux-fill-pro", op: "inpaint" });+ expect(steps({ ...paint, modelId: "bria-fibo-2" })[0].request).toMatchObject({ modelId: "bria-fibo-2", op: "inpaint", inputs: { mask: "/api/files/m.png" } });+ expect(steps({ ...paint, engine: "open", modelId: "oss-krea2-inpaint" })[0].request).toMatchObject({ modelId: "oss-krea2-inpaint", op: "inpaint", inputs: { mask: "/api/files/m.png" } });const open = steps({ ...paint, engine: "open", settings: { keepAlpha: true } });expect(open.map((x) => [x.key, x.request.modelId, x.request.op])).toEqual([["inpaint", "oss-qwen-image-21", "inpaint"],@@ -191,18 +192,46 @@ describe("job steps", () => {});it("hands layers to the existing upscale, relight, angles, background and expand models", () => {- expect(steps({ tool: "upscale", engine: "open" })[0].request).toMatchObject({ modelId: "oss-upscale-image", op: "upscale-image" });+ // SeedVR2 restores detail as it enlarges (4x ESRGAN stays a choice).+ expect(steps({ tool: "upscale", engine: "open" })[0].request).toMatchObject({ modelId: "oss-seedvr2-image", op: "upscale-image" });+ expect(steps({ tool: "upscale", engine: "open", modelId: "oss-upscale-image" })[0].request).toMatchObject({ modelId: "oss-upscale-image", op: "upscale-image" });expect(steps({ tool: "bg-remove" })[0].request).toMatchObject({ modelId: "birefnet-cloud", op: "bg-remove" });+ // Relight: Qwen-Image 2.1 Turbo in its own picture tags; the Relight LoRA graph (a choice) gets the light alone.const relight = steps({ tool: "relight", engine: "open", settings: { light: "Neon night", direction: "Left" } })[0].request;- expect(relight).toMatchObject({ modelId: "oss-qwen-relight", op: "edit", prompt: "pink and blue neon lights at night, coming from the left" });+ expect(relight).toMatchObject({ modelId: "oss-qwen-image-21-turbo", op: "edit" });+ expect(relight.prompt).toMatch(/^Relight <image1> with pink and blue neon lights at night coming from the left\. Keep /);+ const lora = steps({ tool: "relight", engine: "open", modelId: "oss-qwen-relight", settings: { light: "Neon night", direction: "Left" } })[0].request;+ expect(lora).toMatchObject({ modelId: "oss-qwen-relight", op: "edit", prompt: "pink and blue neon lights at night, coming from the left" });+ const krea = steps({ tool: "relight", engine: "open", modelId: "oss-krea2-edit", settings: { light: "Neon night" } })[0].request;+ expect(krea.prompt).toMatch(/^Relight the image with pink and blue neon lights at night\. Keep the subject/);+ expect(steps({ tool: "relight", modelId: "nano-banana-2-1", settings: { light: "Neon night" } })[0].request).toMatchObject({ modelId: "nano-banana-2-1", op: "edit" });const angles = steps({ tool: "angles", settings: { rotate: 90, tilt: 10, zoom: 4 } })[0].request;expect(angles).toMatchObject({ modelId: "qwen-multiple-angles", params: { extra: { horizontal_angle: 90, vertical_angle: 10, zoom: 4 } } });- expect(steps({ tool: "angles", engine: "open", settings: { angle: "Back" } })[0].request.prompt).toContain("a view from directly behind");+ // On your GPU: Qwen-Image 2.1 (25 steps) on the same plain camera words, no LoRA.+ const turned = steps({ tool: "angles", engine: "open", settings: { angle: "Back" } })[0].request;+ expect(turned).toMatchObject({ modelId: "oss-qwen-image-21", op: "edit" });+ expect(turned.prompt).toMatch(/^Show the exact same subject from a view from directly behind, as if the camera physically moved\./);+ expect(turned.loras).toBeUndefined();const expand = steps({ tool: "expand", engine: "open", settings: { pads: { left: 64, top: 0, right: 64, bottom: 8 } } })[0].request;expect(expand).toMatchObject({ modelId: "oss-qwen-image-21", op: "outpaint", params: { extra: { padLeft: 64, padTop: 0, padRight: 64, padBottom: 8 } } });+ // Krea 2 Inpaint grows the canvas from the same pads.+ expect(steps({ tool: "expand", engine: "open", modelId: "oss-krea2-inpaint", settings: { pads: { left: 64, top: 0, right: 64, bottom: 8 } } })[0].request).toMatchObject({+ modelId: "oss-krea2-inpaint",+ op: "outpaint",+ params: { extra: { padLeft: 64 } },+ });expect(() => steps({ tool: "expand", engine: "open", settings: { pads: { left: 0, top: 0, right: 0, bottom: 0 } } })).toThrow(/Drag an edge/);expect(steps({ tool: "expand" })[0].request.prompt).toMatch(/^Fill the empty grey margins/);+ expect(steps({ tool: "expand" })[0].request.prompt).toMatch(/fill the margins with more of the same surroundings\.$/);expect(steps({ tool: "regional", prompt: "add a hat" })[0].request).toMatchObject({ modelId: "seedream-5-pro", op: "edit" });+ // Regional edit and Layer edit on your GPU: Qwen-Image 2.1 first, then Krea 2 Edit and FIBO 2 Edit Turbo, one picture each.+ expect(steps({ tool: "regional", engine: "open", prompt: "add a hat" })[0].request).toMatchObject({ modelId: "oss-qwen-image-21", op: "edit" });+ for (const modelId of ["oss-krea2-edit", "oss-fibo2-edit-turbo"]) {+ expect(steps({ tool: "regional", engine: "open", modelId, prompt: "add a hat" })[0].request).toMatchObject({ modelId, op: "edit", inputs: { images: ["/api/files/a.png"] } });+ expect(steps({ tool: "regenerate", engine: "open", modelId, prompt: "a red coat" })[0].request).toMatchObject({ modelId, op: "edit" });+ }+ expect(() => steps({ tool: "regional", engine: "open", modelId: "oss-qwen-edit", prompt: "add a hat" })).toThrow(/can't run this tool/);+ expect(steps({ tool: "generate-layer", engine: "open", modelId: "oss-moss-image", prompt: "a lamp" })[0].request).toMatchObject({ modelId: "oss-moss-image", op: "t2i" });});it("only sends a shape the model accepts", () => {@@ -299,7 +328,7 @@ describe("layers API", () => {expect(rows.length).toBeGreaterThan(1);expect(rows[0].box).toEqual([expect.closeTo(153.6, 1), expect.closeTo(108, 1), expect.closeTo(998.4, 1), expect.closeTo(97.2, 1)]);- // Inpaint: Nano Banana Pro is shown the painted area tinted red; FLUX Fill [pro] takes the mask itself.+ // Inpaint: Nano Banana Pro is shown the painted area tinted red; Bria FIBO 2 takes the mask itself.const mask = upload();const sketch = upload();const paint = { tool: "inpaint", engine: "cloud", image: source, mask, sketch, prompt: "a vase of tulips", frame, settings: { aspect: "16:9" } };@@ -309,9 +338,9 @@ describe("layers API", () => {expect(nano).toMatchObject({ modelId: "nano-banana-pro", op: "edit" });expect(nano.request.inputs).toMatchObject({ images: [source], sketch });expect(nano.prompt).toMatch(/Only change the region tinted red in image 2/);- res = await jobs.POST(req("POST", { ...paint, modelId: "flux-fill-pro" }), ctx({ id }));+ res = await jobs.POST(req("POST", { ...paint, modelId: "bria-fibo-2" }), ctx({ id }));const fill = gens.getGeneration(((await res.json()) as LayerJob).generationIds[0])!;- expect(fill).toMatchObject({ modelId: "flux-fill-pro", op: "inpaint" });+ expect(fill).toMatchObject({ modelId: "bria-fibo-2", op: "inpaint" });expect(fill.request.inputs).toMatchObject({ images: [source], mask });// Only stored files can be painted with.res = await jobs.POST(req("POST", { ...paint, mask: "http://evil.example/m.png" }), ctx({ id }));diff --git a/tests/layers-comfy.test.ts b/tests/layers-comfy.test.tsindex 17344329..a7f791a4 100644--- a/tests/layers-comfy.test.ts+++ b/tests/layers-comfy.test.ts@@ -66,19 +66,22 @@ describe("Layers on the open engine", () => {expect(at("numLayers")).toEqual([2]);});- it("expand: the padding reaches both of Qwen-Image 2.1's pad nodes, or FLUX Fill when picked", async () => {+ it("expand: the padding reaches both of Qwen-Image 2.1's pad nodes, or Krea 2 Inpaint's when picked", async () => {const pads = { pads: { left: 64, top: 0, right: 128, bottom: 8 } };const at = await bind(step({ tool: "expand", settings: pads }));expect([at("padLeft"), at("padTop"), at("padRight"), at("padBottom")]).toEqual([[64, 64], [0, 0], [128, 128], [8, 8]]);// The words only say what fills the margins: the graph keeps the picture itself.expect(at("prompt")).toEqual(["Continue the scene naturally beyond every edge with matching perspective, lighting, textures and grain."]);- const fill = await bind(step({ tool: "expand", modelId: "oss-flux-fill", settings: pads }));- expect([fill("padLeft"), fill("padTop"), fill("padRight"), fill("padBottom")]).toEqual([[64], [0], [128], [8]]);+ const krea = await bind(step({ tool: "expand", modelId: "oss-krea2-inpaint", settings: pads }));+ expect([krea("padLeft")[0], krea("padTop")[0], krea("padRight")[0], krea("padBottom")[0]]).toEqual([64, 0, 128, 8]);});it("relight and edit text: the instruction reaches the edit graphs", async () => {+ // Qwen-Image 2.1 Turbo in its own picture tags; the Relight LoRA graph (a choice) with the light alone.const relight = await bind(step({ tool: "relight", settings: { light: "Candlelight", direction: "Left" } }));- expect(String(relight("prompt")[0])).toContain("warm flickering candlelight, coming from the left");+ expect(String(relight("prompt")[0])).toMatch(/^Relight <image1> with warm flickering candlelight coming from the left\. /);+ const lora = await bind(step({ tool: "relight", modelId: "oss-qwen-relight", settings: { light: "Candlelight", direction: "Left" } }));+ expect(String(lora("prompt")[0])).toContain("warm flickering candlelight, coming from the left");const text = await bind(step({ tool: "text-edit", settings: { rows: [{ from: "SALE", to: "OPEN" }] } }));expect(text("prompt")).toEqual(["Preserve the original design and change only the requested text. Change “SALE” to “OPEN”."]);});diff --git a/tests/layers.test.ts b/tests/layers.test.tsindex 2e3b00fe..a4e88d06 100644--- a/tests/layers.test.ts+++ b/tests/layers.test.ts@@ -27,6 +27,7 @@ import {nodesFromOutputs,placeOutput,rectFrom,+ relightPrompt,reframeDoc,replaceNodes,resizeBox,@@ -563,6 +564,58 @@ describe("tools and prices", () => {}});+ it("puts the newest open image models first: Qwen-Image 2.1, its Turbo, Krea 2, FIBO 2, MOSS-Image and SeedVR2", () => {+ expect(TOOL_MODELS.regenerate.open).toEqual(["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-krea2-edit", "oss-fibo2-edit-turbo"]);+ expect(TOOL_MODELS.regenerate.cloud).toEqual(["nano-banana-pro", "seedream-5-pro", "nano-banana-2-1"]);+ expect(TOOL_MODELS["generate-layer"].open).toEqual(["oss-qwen-image-21", "oss-ideogram-4", "oss-krea2-turbo", "oss-moss-image"]);+ expect(TOOL_MODELS["text-edit"].open).toEqual(["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-krea2-edit"]);+ expect(TOOL_MODELS.enhance.open).toEqual(["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-krea2-edit"]);+ expect(TOOL_MODELS.regional.open).toEqual(["oss-qwen-image-21", "oss-krea2-edit", "oss-fibo2-edit-turbo"]);+ expect(TOOL_MODELS.upscale.open).toEqual(["oss-seedvr2-image", "oss-upscale-image"]);+ expect(TOOL_MODELS.relight).toEqual({ cloud: ["nano-banana-pro", "nano-banana-2-1"], open: ["oss-qwen-image-21-turbo", "oss-krea2-edit", "oss-qwen-relight"] });+ expect(TOOL_MODELS.angles.open).toEqual(["oss-qwen-image-21"]);+ expect(TOOL_MODELS.expand.open).toEqual(["oss-qwen-image-21", "oss-krea2-inpaint"]);+ expect(TOOL_MODELS.inpaint).toEqual({ cloud: ["nano-banana-pro", "bria-fibo-2", "z-image-inpaint"], open: ["oss-qwen-image-21", "oss-krea2-inpaint"] });+ // Qwen-Image-Edit 2511, FLUX.1 Kontext and Fill, Z-Image Turbo, Qwen-Image 2512 and Nano Banana 2 are in no tool list.+ const all = Object.values(TOOL_MODELS).flatMap((t) => [...t.cloud, ...t.open]);+ for (const id of ["oss-qwen-edit", "oss-flux-kontext", "oss-flux-fill", "flux-fill-pro", "oss-z-image-turbo", "oss-qwen-image", "nano-banana-2"]) expect(all, id).not.toContain(id);+ // The angle and the front of a turn need the 25-step model (its Turbo misses big camera turns).+ expect(getModel("oss-qwen-image-21")!.routes.find((r) => r.op === "edit")!.endpoint).toBe("qwen-image-21-edit");+ });++ it("only offers models whose route takes what the tool sends", () => {+ // Regional edit, edit text and the Enhancer send one picture to an edit route.+ for (const tool of ["regional", "text-edit", "enhance", "relight"] as const) {+ for (const id of TOOL_MODELS[tool].open) {+ const m = getModel(id)!;+ expect(supportsOp(m, "edit"), `${tool}: ${id}`).toBe(true);+ expect(m.options.maxImages ?? 1, `${tool}: ${id}`).toBeGreaterThanOrEqual(1);+ }+ }+ // Inpaint sends a mask: every model past Nano Banana Pro (the red-tinted copy) has an inpaint route with one.+ for (const engine of ["cloud", "open"] as const) {+ for (const id of TOOL_MODELS.inpaint[engine].filter((x) => x !== "nano-banana-pro")) {+ const m = getModel(id)!;+ const route = m.routes.find((r) => r.op === "inpaint");+ expect(route, id).toBeDefined();+ if (engine === "cloud") expect(route!.map?.mask, id).toBeTruthy();+ }+ }+ // Expand on your GPU sends the pads to an outpaint route.+ for (const id of TOOL_MODELS.expand.open) expect(supportsOp(getModel(id)!, "outpaint"), id).toBe(true);+ });++ it("words a relight for each kind of model", () => {+ // The Relight LoRA graph: the light alone (it adds the LoRA's trigger itself).+ expect(relightPrompt("oss-qwen-relight", "warm golden hour sunlight", "coming from the left")).toBe("warm golden hour sunlight, coming from the left");+ // Qwen-Image 2.1 and its Turbo: their own picture tags, as the relit covers were made.+ const qwen = relightPrompt("oss-qwen-image-21-turbo", "warm golden hour sunlight", "coming from the left");+ expect(qwen).toMatch(/^Relight <image1> with warm golden hour sunlight coming from the left\. Keep .* exactly as in <image1>/);+ // Krea 2 Edit and the cloud: a plain instruction.+ expect(relightPrompt("oss-krea2-edit", "soft overcast daylight")).toMatch(/^Relight the image with soft overcast daylight\. Keep the subject/);+ expect(relightPrompt("nano-banana-pro", "soft overcast daylight")).toBe(relightPrompt("oss-krea2-edit", "soft overcast daylight"));+ });+it("runs the Enhancer's Detail look on catalog upscalers", () => {for (const engine of ["cloud", "open"] as const) {for (const id of ENHANCE_DETAIL_MODELS[engine]) {@@ -575,7 +628,7 @@ describe("tools and prices", () => {}expect(enhancePrompt("detail")).toBeNull();expect(enhancePrompt("glow", " ")).toBe(- "Give the portrait a soft beauty retouch with a healthy dewy glow, still keeping real pore texture. Make the skin look like a high-end editorial photograph shot on a sharp lens — real texture, no plastic smoothing, no makeup changes. Keep the face shape, identity, expression, hair, lighting and background exactly the same.",+ "Give the portrait a soft beauty retouch with a healthy dewy glow, still keeping real pore texture. Make the skin look like a high-end editorial photograph shot on a sharp lens, with real, natural skin texture and the same makeup. Keep the face shape, identity, expression, hair, lighting and background exactly the same.",);// Every look but Detail has an instruction.expect(ENHANCE_LOOKS.filter((l) => !l.prompt).map((l) => l.id)).toEqual(["detail"]);diff --git a/tests/mixed-media.test.ts b/tests/mixed-media.test.tsindex 56b103b0..676dbc70 100644--- a/tests/mixed-media.test.ts+++ b/tests/mixed-media.test.ts@@ -70,7 +70,11 @@ describe("Mixed Media presets", () => {for (const id of [...MIXED_MODELS.cloud, ...MIXED_MODELS.open, ...MIXED_FRAME_MODELS, ...Object.values(MIXED_TOOLS.cloud), ...Object.values(MIXED_TOOLS.open)]) expect(getModel(id), id).toBeDefined();// Per frame redraws each frame with an image editor; the helpers are fal's FFmpeg tools.for (const id of MIXED_FRAME_MODELS) expect(getModel(id)!.routes.some((r) => r.op === "edit")).toBe(true);- expect(getModel("nano-banana-2")!.pricing?.byResolution).toMatchObject({ "1K": 0.08, "2K": 0.12, "4K": 0.16 });+ expect(getModel("nano-banana-2-1")!.routes.find((r) => r.op === "edit")!.map).toMatchObject({ seed: "seed", aspectRatio: "aspect_ratio", resolution: "resolution" });+ expect(getModel("nano-banana-2-1")!.options.resolutions).toEqual(expect.arrayContaining([...MIXED.resolutions]));+ // Nano Banana 2.1 is the partner frame editor (it takes a seed, so every frame starts from the same one).+ expect(MIXED_FRAME_MODELS).toEqual(["fuobe-mixed-media", "nano-banana-2-1", "seedream-5-flash"]);+ expect(MIXED_TOOLS.cloud.preview).toBe("nano-banana-2-1");expect(getModel("seedream-5-flash")!.pricing?.usd).toBe(0.027);});@@ -193,14 +197,14 @@ describe("Mixed Media pipeline shape", () => {const open = planMixedPreview(input());expect(open.request).toMatchObject({ feature: "mixed-media-preview", modelId: "oss-mixed-media", params: { startTime: 2, fps: 8, extra: { frames: 1 } } });const cloud = planMixedPreview({ ...input({ engine: "cloud", mode: "fast", modelId: "ltx-2-3-restyle" }), frameUrl: "/api/files/uploads/frame.png" });- expect(cloud.request).toMatchObject({ modelId: "nano-banana-2", op: "edit", inputs: { images: ["/api/files/uploads/frame.png"] } });+ expect(cloud.request).toMatchObject({ modelId: "nano-banana-2-1", op: "edit", inputs: { images: ["/api/files/uploads/frame.png"] } });expect(cloud.request.prompt).toMatch(/^Redraw this image as hand-drawn/);});});describe("Mixed Media per frame on the cloud", () => {const frames = (over: Partial<MixedPlanInput> = {}) =>- input({ engine: "cloud", modelId: "nano-banana-2", sourceFps: 24, range: { start: 2, end: 7 }, fps: 8, ...over });+ input({ engine: "cloud", modelId: "nano-banana-2-1", sourceFps: 24, range: { start: 2, end: 7 }, fps: 8, ...over });it("takes every Nth frame of the clip, the N closest to the rate asked for", () => {expect(frameSampling(5, 8, 24)).toEqual({ interval: 3, fps: 8, frames: 40 });@@ -229,7 +233,7 @@ describe("Mixed Media per frame on the cloud", () => {it("asks each editor for the frame's own shape, with a fixed seed where it takes one", () => {// JPEG back: every frame is downloaded and sent on twice (a 4K PNG is ten times the bytes).- expect(frameEditParams("nano-banana-2", "2K", 9)).toEqual({ aspectRatio: "auto", resolution: "2K", seed: 9, extra: { output_format: "jpeg" } });+ expect(frameEditParams("nano-banana-2-1", "2K", 9)).toEqual({ aspectRatio: "auto", resolution: "2K", seed: 9, extra: { output_format: "jpeg" } });expect(frameEditParams("seedream-5-flash", "1K", 9)).toEqual({ extra: { image_size: "auto_1K" } });expect(frameEditParams("seedream-5-flash", "4K", 9)).toEqual({ extra: { image_size: "auto_2K" } });});@@ -247,7 +251,7 @@ describe("Mixed Media per frame on the cloud", () => {// Each knows how many frames were planned (a list far short of it fails before anything is paid).expect(by.f0.chain).toEqual([{ slot: "images", index: 0, of: 40, position: "first" }]);expect(by.f0).toMatchObject({ after: ["frames1"] });- expect(by.f0.request).toMatchObject({ feature: "mixed-media-frame-step", modelId: "nano-banana-2", op: "edit", params: { aspectRatio: "auto", resolution: "1K", seed: FRAME_SEED, numOutputs: 1 } });+ expect(by.f0.request).toMatchObject({ feature: "mixed-media-frame-step", modelId: "nano-banana-2-1", op: "edit", params: { aspectRatio: "auto", resolution: "1K", seed: FRAME_SEED, numOutputs: 1 } });expect(by.f0.request.prompt).toMatch(/^Redraw this image as hand-drawn/);expect(by.f1).toMatchObject({ after: ["frames1", "f0"], chain: [{ slot: "images", index: 1, position: "first" }, { slot: "images" }] });expect(by.f1.request.prompt).toMatch(/^Redraw the first image as .*The second image is an earlier frame of the same clip already redrawn/);diff --git a/tests/mixed-shorts-originals.test.ts b/tests/mixed-shorts-originals.test.tsindex c90263a7..90efce4f 100644--- a/tests/mixed-shorts-originals.test.ts+++ b/tests/mixed-shorts-originals.test.ts@@ -100,7 +100,7 @@ describe("Fuobe Mixed Media and Fuobe Shorts in the catalog", () => {it("are the studios' defaults, with the partners kept as choices", () => {expect(mm.MIXED_FRAME_MODELS[0]).toBe("fuobe-mixed-media");- expect(mm.MIXED_FRAME_MODELS).toContain("nano-banana-2");+ expect(mm.MIXED_FRAME_MODELS).toContain("nano-banana-2-1");expect(mm.MIXED_MODELS.open).toEqual(["fuobe-mixed-media"]);expect(mm.MIXED_MODELS.cloud).toContain("gemini-omni-flash");expect(sh.SHORTS_MODELS.cloud[0]).toBe("fuobe-shorts");diff --git a/tests/model-access.test.ts b/tests/model-access.test.tsindex 6b64c371..ff79b0ed 100644--- a/tests/model-access.test.ts+++ b/tests/model-access.test.ts@@ -295,7 +295,7 @@ describe("chains and Originals refuse a switched-off step before anything is que// Without an engine asked for, it runs on the one still on, the relight step with it.const [clip, relit] = createGenerations(relight);expect(clip).toMatchObject({ modelId: "fuobe-dop", engine: "open" });- expect(relit.modelId).toBe("oss-qwen-relight");+ expect(relit.modelId).toBe("oss-qwen-image-21-turbo");});it("names the switch, not Engine mode, when cloud only meets an Original whose cloud half is off", () => {diff --git a/tests/open-sota-studios.test.ts b/tests/open-sota-studios.test.tsindex 2be62b3e..06d3037b 100644--- a/tests/open-sota-studios.test.ts+++ b/tests/open-sota-studios.test.ts@@ -116,14 +116,15 @@ describe("apps and tools pick the new models first", () => {expect(openRoute("app-relight").modelId).toBe("oss-qwen-relight");expect(openRoute("app-product-shot").modelId).toBe("oss-product-shot");expect(openRoute("app-virtual-try-on").modelId).toBe("oss-tryon-klein");- expect(TOOL_MODELS.angles.open).toEqual(["oss-qwen-edit"]);+ // Layers' Angles runs no LoRA: Qwen-Image 2.1 (25 steps) on the plain camera words.+ expect(TOOL_MODELS.angles.open).toEqual(["oss-qwen-image-21"]);expect(RECOMPOSE_MODELS.open).toEqual(["oss-qwen-edit", "oss-qwen-image-21"]);});it("Layers: Qwen-Image 2.1 edits, inpaints, expands and makes a layer first; Ideogram 4 is the next pick for a layer", () => {- expect(TOOL_MODELS.regenerate.open).toEqual(["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-qwen-edit", "oss-flux-kontext"]);+ expect(TOOL_MODELS.regenerate.open).toEqual(["oss-qwen-image-21", "oss-qwen-image-21-turbo", "oss-krea2-edit", "oss-fibo2-edit-turbo"]);// A lone object on a plain background is what Ideogram 4's safety filter answers with a grey card most often.- expect(TOOL_MODELS["generate-layer"].open).toEqual(["oss-qwen-image-21", "oss-ideogram-4", "oss-z-image-turbo", "oss-qwen-image"]);+ expect(TOOL_MODELS["generate-layer"].open).toEqual(["oss-qwen-image-21", "oss-ideogram-4", "oss-krea2-turbo", "oss-moss-image"]);for (const tool of ["text-edit", "regional", "expand", "inpaint", "enhance"] as const) expect(TOOL_MODELS[tool].open[0], tool).toBe("oss-qwen-image-21");// Each first model does what its tool asks of it.const does = (m: ModelDef, op: string) => m.routes.some((r) => r.op === op);@@ -149,14 +150,14 @@ describe("apps and tools pick the new models first", () => {expect(EFFECT_CHAIN_MODELS.edit).toEqual({ cloud: "qwen-image-edit-2511-cloud", open: "oss-qwen-image-21-turbo" });});- it("Photodump, Fashion Factory and Character swap offer Qwen-Image 2.1 before Qwen-Image-Edit 2511", () => {+ it("Photodump, Fashion Factory and Character swap offer Qwen-Image 2.1 first, then Krea 2 Identity Edit", () => {const selfie: PhotoSubject = { kind: "selfie", url: "/api/files/uploads/me.png" };- expect(PHOTODUMP_MODELS.open).toEqual(["fuobe-soul", "oss-qwen-image-21", "oss-qwen-edit"]);+ expect(PHOTODUMP_MODELS.open).toEqual(["fuobe-soul", "oss-qwen-image-21", "oss-krea2-identity-edit", "oss-qwen-image-21-turbo"]);expect(photodumpModel(selfie, "open", {}).modelId).toBe("oss-qwen-image-21");- expect(photodumpModel(selfie, "open", {}, "oss-qwen-edit").modelId).toBe("oss-qwen-edit");- expect(FASHION_MODELS.outfit.open).toEqual(["fuobe-tryon", "oss-qwen-image-21", "oss-qwen-edit"]);+ expect(photodumpModel(selfie, "open", {}, "oss-krea2-identity-edit").modelId).toBe("oss-krea2-identity-edit");+ expect(FASHION_MODELS.outfit.open).toEqual(["fuobe-tryon", "oss-qwen-image-21-turbo", "oss-krea2-identity-edit"]);expect(fashionModel("photoset", "open")).toBe("oss-qwen-image-21");- expect(ANCHOR_MODELS.open.map((m) => m.id)).toEqual(["oss-qwen-image-21", "oss-qwen-edit"]);+ expect(ANCHOR_MODELS.open.map((m) => m.id)).toEqual(["oss-qwen-image-21", "oss-krea2-identity-edit"]);expect(anchorModel("open").id).toBe("oss-qwen-image-21");// The cloud lists are untouched.expect(photodumpModel(selfie, "cloud", {}).modelId).toBe("qwen-image-edit-2511-cloud");diff --git a/tests/originals-marketing.test.ts b/tests/originals-marketing.test.tsindex 51139028..e2618147 100644--- a/tests/originals-marketing.test.ts+++ b/tests/originals-marketing.test.ts@@ -153,8 +153,8 @@ describe("Fuobe Try-On and its LoRA", () => {it("is Fashion Factory's outfit model on both engines, with Qwen-Image-Edit 2511 making the photoset in the cloud", () => {expect(FASHION_MODELS.outfit.open[0]).toBe(TRYON_MODEL);expect(FASHION_MODELS.outfit.cloud[0]).toBe(TRYON_MODEL);- expect(FASHION_MODELS.photoset).toEqual({ cloud: ["qwen-image-edit-2511-cloud", "nano-banana-pro"], open: ["oss-qwen-image-21", "oss-qwen-edit"] });- expect(PHOTODUMP_MODELS.cloud).toEqual(["fuobe-soul", "qwen-image-edit-2511-cloud", "nano-banana-pro", "seedream-5-pro"]);+ expect(FASHION_MODELS.photoset).toEqual({ cloud: ["qwen-image-edit-2511-cloud", "nano-banana-pro"], open: ["oss-qwen-image-21", "oss-krea2-identity-edit"] });+ expect(PHOTODUMP_MODELS.cloud).toEqual(["fuobe-soul", "qwen-image-edit-2511-cloud", "nano-banana-pro", "nano-banana-2-1", "seedream-5-pro"]);});});@@ -303,10 +303,10 @@ describe("Fuobe Try-On's LoRA is never left out of a run", () => {describe("Fashion Factory moves on when a model can't run", () => {const t = getTemplate("red-room")!;- it("offers Qwen-Image 2.1 and Qwen-Image-Edit 2511 after Fuobe Try-On on your GPU and takes the photoset's pick", () => {- expect(FASHION_MODELS.outfit.open).toEqual([TRYON_MODEL, "oss-qwen-image-21", "oss-qwen-edit"]);- const qwen = fashionOutfitRequest(t, "/b.png", "/g.png", "open", "oss-qwen-edit");- expect(qwen).toMatchObject({ modelId: "oss-qwen-edit", params: { aspectRatio: "3:4" } });+ it("offers Qwen-Image 2.1 Turbo and Krea 2 Identity Edit after Fuobe Try-On on your GPU and takes the photoset's pick", () => {+ expect(FASHION_MODELS.outfit.open).toEqual([TRYON_MODEL, "oss-qwen-image-21-turbo", "oss-krea2-identity-edit"]);+ const qwen = fashionOutfitRequest(t, "/b.png", "/g.png", "open", "oss-qwen-image-21-turbo");+ expect(qwen).toMatchObject({ modelId: "oss-qwen-image-21-turbo", params: { aspectRatio: "3:4" } });expect(qwen.prompt).toMatch(/^Dress the person in image 1/);expect(fashionPhotosetRequests(t, "/d.png", "cloud", "nano-banana-pro")[0].modelId).toBe("nano-banana-pro");expect(fashionModel("photoset", "open", "nano-banana-pro")).toBe("oss-qwen-image-21");@@ -323,7 +323,7 @@ describe("Fashion Factory moves on when a model can't run", () => {expect(offeredSummary()?.off).toEqual(expect.arrayContaining([TRYON_MODEL, "oss-tryon-klein"]));const base = { step: "outfit" as const, templateId: t.id, base: "/api/files/b.png", garment: "/api/files/g.png" };expect(previewFashion({ ...base, engine: "cloud" })).toMatchObject({ modelId: "fashn-tryon" });- expect(previewFashion({ ...base, engine: "open" })).toMatchObject({ modelId: "oss-qwen-image-21" });+ expect(previewFashion({ ...base, engine: "open" })).toMatchObject({ modelId: "oss-qwen-image-21-turbo" });// Picked anyway (the API): refused, naming the LoRA's switch.expect(previewFashion({ ...base, engine: "cloud", modelId: TRYON_MODEL })).toMatchObject({ error: expect.stringMatching(/switched off in Settings → Models & licences/) });});diff --git a/tests/oss-loras.test.ts b/tests/oss-loras.test.tsindex 846fa023..388574bd 100644--- a/tests/oss-loras.test.ts+++ b/tests/oss-loras.test.ts@@ -167,7 +167,7 @@ describe("every motion and effect on Fuobe DoP", () => {expect(pink.grade).toBe("candy-pink");expect(pink.open!.loras).toBeUndefined();const window = getPreset("effect-window")!;- expect(window.prestep?.open).toMatchObject({ modelId: "oss-qwen-relight", op: "edit" });+ expect(window.prestep?.open).toMatchObject({ modelId: "oss-qwen-image-21-turbo", op: "edit" });expect(window.prestep?.cloud).toMatchObject({ modelId: "qwen-image-edit-2509-cloud", op: "edit" });expect(window.prestep!.cloud.prompt.startsWith("重新照明, ")).toBe(true);expect(window.prestep!.cloud.loras!.map((l) => l.file)).toEqual(["Qwen-Image-Edit-2509-Relight.safetensors"]);diff --git a/tests/person-remove-h3.test.ts b/tests/person-remove-h3.test.tsindex 4c379a62..9bbbe133 100644--- a/tests/person-remove-h3.test.ts+++ b/tests/person-remove-h3.test.ts@@ -55,7 +55,7 @@ describe("H3 person removal: the plan", () => {expect(step("fit").request).toMatchObject({ modelId: "oss-fit-clip", op: "trim", inputs: { video: src.url }, params: { startTime: 2, endTime: 9, fps: PERSON_REMOVAL_FPS, extra: size } });expect(step("frame").request).toMatchObject({ modelId: "oss-extract-frame", op: "frame", params: { startTime: 0, extra: { frameIndex: 0 } } });expect(step("frame").chain).toEqual([{ slot: "video" }]);- expect(step("clean").request).toMatchObject({ modelId: "oss-qwen-edit", op: "edit", params: { seed: 7 } });+ expect(step("clean").request).toMatchObject({ modelId: "oss-qwen-image-21", op: "edit", params: { seed: 7 }, step: { label: "A clean first frame (Qwen-Image 2.1)" } });expect(step("clean").request.prompt).toBe(cleanFramePrompt("Remove the man in the grey shirt"));expect(step("clean").request.prompt).toMatch(/^Remove the man in the grey shirt from the picture completely/);// The removal reads the fitted part and the clean frame; SAM 3.1 gets the person's words.@@ -113,6 +113,19 @@ describe("H3 person removal: the graph", () => {await expect(prepare({ prompt: "" })).rejects.toThrow(/Say what to remove/);});+ it("the clean frame keeps the part's framing: Qwen-Image 2.1 follows image 1's shape, the relay centre-crops it back", () => {+ const qwen = JSON.parse(fs.readFileSync(path.join(__dirname, "../workflows/comfyui/qwen-image-21-edit.json"), "utf8")) as Graph;+ // Image 1 is scaled to 2048 px on its long side, and the latent is made on its own size (resolution 0), rounded to 32.+ expect(qwen["20"]).toMatchObject({ class_type: "ImageScaleToMaxDimension", inputs: { image: ["10", 0], largest_size: 2048 } });+ expect(qwen["30"]).toMatchObject({ class_type: "TextEncodeQwenImage21", inputs: { resolution: 0 } });+ // A 16:9 part: 1344×736 → 2048×1121.5 → 2048×1120, the same shape within a pixel at the part's size.+ const part = h3Canvas(1280, 720, "768p");+ const long = 2048;+ const short = Math.round(((part.height * long) / part.width) / 32) * 32;+ expect([long, short]).toEqual([2048, 1120]);+ expect(Math.abs(part.height - (short * part.width) / long)).toBeLessThanOrEqual(1);+ });+it("downloads the Person Remover LoRA before it runs", () => {expect(graphLoras(H3_REMOVAL_WORKFLOW, {})).toEqual([PERSON_REMOVER_LORA]);expect(PERSON_REMOVER_LORA.url).toBe("https://huggingface.co/akatz-ai/MiniMax-H3-Person-Remover-LoRA/resolve/fe136b3dc93aea993b9f194d48ea9859fdc2de14/H3-Person-Remover-V1.safetensors");diff --git a/tests/popcorn-looks.test.ts b/tests/popcorn-looks.test.tsindex bc8249c4..5aa28e58 100644--- a/tests/popcorn-looks.test.ts+++ b/tests/popcorn-looks.test.ts@@ -87,7 +87,7 @@ describe("Popcorn looks: the planner", () => {const wide = planStoryboard({ engine: "open", scenes, look: { id: look.id, words: look.look }, aspectRatio: "21:9" });expect(wide.every((f) => f.params?.aspectRatio === "16:9" && f.frame?.crop === "21:9")).toBe(true);const plain = planStoryboard({ engine: "open", scenes, aspectRatio: "21:9" });- expect(plain[0]).toMatchObject({ modelId: "oss-z-image-turbo", params: { aspectRatio: "21:9" } });+ expect(plain[0]).toMatchObject({ modelId: "oss-qwen-image-21", params: { aspectRatio: "21:9" } });expect(plain[1]).toMatchObject({ chainFrom: "first" });expect(plain[1].chain).toBeUndefined();expect(plain.every((f) => !f.frame?.look && !f.frame?.crop)).toBe(true);diff --git a/tests/remove-object-api.test.ts b/tests/remove-object-api.test.tsindex a03e3262..528221aa 100644--- a/tests/remove-object-api.test.ts+++ b/tests/remove-object-api.test.ts@@ -285,11 +285,11 @@ describe("Remove object: runs", () => {const out = (await res.json()) as { final: Generation; items: Generation[] };expect(res.status).toBe(201);const rows = batchOf(out.final.id);- expect(rows.map((r) => r.model_id)).toEqual(expect.arrayContaining(["oss-fit-clip", "oss-extract-frame", "oss-qwen-edit", "oss-h3-person-remove", "oss-trim", "oss-mux"]));+ expect(rows.map((r) => r.model_id)).toEqual(expect.arrayContaining(["oss-fit-clip", "oss-extract-frame", "oss-qwen-image-21", "oss-h3-person-remove", "oss-trim", "oss-mux"]));expect(out.final).toMatchObject({ modelId: "oss-mux", feature: REMOVE.feature });expect((await settle(out.final.id)).status).toBe("succeeded");const removal = gens.getGeneration(rows.find((r) => r.model_id === "oss-h3-person-remove")!.id)!;- const clean = gens.getGeneration(rows.find((r) => r.model_id === "oss-qwen-edit")!.id)!;+ const clean = gens.getGeneration(rows.find((r) => r.model_id === "oss-qwen-image-21")!.id)!;const fit = gens.getGeneration(rows.find((r) => r.model_id === "oss-fit-clip")!.id)!;// The removal read the fitted part and the clean first frame the steps before it made.expect(removal.request.inputs?.video).toBe(fit.outputs[0].url);diff --git a/tests/shorts-api.test.ts b/tests/shorts-api.test.tsindex 2f188917..bd618242 100644--- a/tests/shorts-api.test.ts+++ b/tests/shorts-api.test.ts@@ -17,6 +17,7 @@ const { saveFile } = await import("@/server/storage");const { db } = await import("@/server/db");const shorts = await import("@/server/shorts");const mixed = await import("@/server/mixed-media");+const { getModel } = await import("@/lib/catalog");const sessionsRoute = await import("@/app/api/shorts/sessions/route");const sessionRoute = await import("@/app/api/shorts/sessions/[id]/route");const regenRoute = await import("@/app/api/shorts/sessions/[id]/segments/[index]/route");@@ -254,7 +255,7 @@ describe("Shorts sessions", () => {expect(s.segments.map((g) => g.frames)).toEqual([65, 65, 61]);const take = s.segments[2].takes[0];expect(gens.getGeneration(take.cut)).toMatchObject({ modelId: "oss-segment", op: "trim" });- expect(gens.getGeneration(take.frame!)).toMatchObject({ modelId: "oss-qwen-edit", op: "edit" });+ expect(gens.getGeneration(take.frame!)).toMatchObject({ modelId: "oss-qwen-image-21-turbo", op: "edit" });expect(dependsOn(take.look)).toEqual([take.cut, take.frame]);const final = await settle(s.stitches[0].final);expect(final).toMatchObject({ status: "succeeded", modelId: "oss-mux" });@@ -381,7 +382,7 @@ describe("Shorts sessions", () => {});describe("Mixed Media renders", () => {- // The cloud's Per frame tests below are Nano Banana 2's lanes unless a test names another model; Fuobe Mixed Media, the+ // The cloud's Per frame tests below are Nano Banana 2.1's lanes unless a test names another model; Fuobe Mixed Media, the// default since build plan O9, has tests of its own (and tests/mixed-shorts-originals.test.ts).const mm = (over: Record<string, unknown> = {}) => ({engine: "open",@@ -391,7 +392,7 @@ describe("Mixed Media renders", () => {range: { start: 2, end: 7 },fps: 24,resolution: "1K",- ...(over.engine === "cloud" && !over.mode && !over.modelId ? { modelId: "nano-banana-2" } : {}),+ ...(over.engine === "cloud" && !over.mode && !over.modelId ? { modelId: "nano-banana-2-1" } : {}),...over,});@@ -420,7 +421,7 @@ describe("Mixed Media renders", () => {it("renders on the cloud (Fast): cut → restyle anchored on the preview still → the cut's sound", async () => {const preview = await (await mixedPreviewRoute.POST(json("POST", mm({ engine: "cloud", frameUrl: png })))).json();- expect(preview).toMatchObject({ modelId: "nano-banana-2", op: "edit", feature: "mixed-media-preview" });+ expect(preview).toMatchObject({ modelId: "nano-banana-2-1", op: "edit", feature: "mixed-media-preview" });const still = await settle(preview.id);const anchor = still.outputs[0].url;const { final, items } = await mixed.createMixed(mm({ engine: "cloud", mode: "fast", anchor }) as never);@@ -481,19 +482,21 @@ describe("Mixed Media renders", () => {setSetting("falKey", "fal-test-key");try {const est = await mixed.estimateMixed(mm({ engine: "cloud", source: { url: "/api/files/placeholder.mp4", duration: 12, fps: 30 }, range: { start: 0, end: 10 }, fps: 8 }) as never);- expect(est).toMatchObject({ mode: "frames", frames: 75, fps: 7.5, perFrameUsd: 0.08, demo: false, previewUsd: 0.08 });+ // Nano Banana 2.1: the catalog's one price an image (fal bills its tokens).+ const per = getModel("nano-banana-2-1")!.pricing!.usd;+ expect(est).toMatchObject({ mode: "frames", frames: 75, fps: 7.5, perFrameUsd: per, demo: false, previewUsd: per });expect(est.notes).toContain("Frames are every 4th frame of this 30 FPS clip: 7.5 FPS, 75 frames");- // 75 frames × $0.08, plus the cut, the extraction and the assembly (fal compute, about free).- expect(est.costUsd).toBeGreaterThanOrEqual(6);- expect(est.costUsd).toBeLessThan(6.01);+ // 75 frames × the frame price, plus the cut, the extraction and the assembly (fal compute, about free).+ expect(est.costUsd).toBeGreaterThanOrEqual(75 * per);+ expect(est.costUsd).toBeLessThan(75 * per + 0.01);const big = await mixed.estimateMixed(mm({ engine: "cloud", source: { url: "/api/files/placeholder.mp4", duration: 12, fps: 24 }, range: { start: 0, end: 5 }, fps: 24, resolution: "4K" }) as never);- expect(big).toMatchObject({ frames: 120, fps: 24, perFrameUsd: 0.16 });- expect(big.costUsd).toBeGreaterThanOrEqual(19.2);+ expect(big).toMatchObject({ frames: 120, fps: 24, perFrameUsd: per });+ expect(big.costUsd).toBeGreaterThanOrEqual(120 * per);// Over 200 frames the clips are joined at up to 2048 px: 4K frames would be paid for and shrunk, so they are drawn at 2K.const joined = await mixed.estimateMixed(mm({ engine: "cloud", source: { url: "/api/files/placeholder.mp4", duration: 12, fps: 24 }, range: { start: 0, end: 10 }, fps: 24, resolution: "4K" }) as never);- expect(joined).toMatchObject({ frames: 240, perFrameUsd: 0.12 });- expect(joined.costUsd).toBeGreaterThanOrEqual(28.8);- expect(joined.costUsd).toBeLessThan(28.9);+ expect(joined).toMatchObject({ frames: 240, perFrameUsd: per });+ expect(joined.costUsd).toBeGreaterThanOrEqual(240 * per);+ expect(joined.costUsd).toBeLessThan(240 * per + 0.1);expect(joined.notes).toContain("Over 200 frames are made as clips and joined at up to 2048 px, so frames are drawn at 2K");const flash = await mixed.estimateMixed(mm({ engine: "cloud", modelId: "seedream-5-flash", source: { url: "/api/files/placeholder.mp4", duration: 12, fps: 24 }, range: { start: 0, end: 5 }, fps: 8 }) as never);expect(flash).toMatchObject({ frames: 40, perFrameUsd: 0.027 });@@ -513,10 +516,10 @@ describe("Mixed Media renders", () => {expect(legacy.perFrameUsd).toBeUndefined();const wrong = await mixedEstimateRoute.POST(json("POST", mm({ engine: "cloud", mode: "frames", modelId: "ltx-2-3-restyle", source: { url: "/api/files/placeholder.mp4", duration: 12, fps: 24 } })));expect(wrong.status).toBe(422);- expect((await wrong.json()).error).toBe("LTX 2.3 Reference Restyle restyles the clip as video — pick Fast for it, or Fuobe Mixed Media or Nano Banana 2 or Seedream 5.0 Flash to redraw each frame");- const still = await mixedEstimateRoute.POST(json("POST", mm({ engine: "cloud", mode: "fast", modelId: "nano-banana-2", source: { url: "/api/files/placeholder.mp4", duration: 12, fps: 24 } })));+ expect((await wrong.json()).error).toBe("LTX 2.3 Reference Restyle restyles the clip as video — pick Fast for it, or Fuobe Mixed Media or Nano Banana 2.1 or Seedream 5.0 Flash to redraw each frame");+ const still = await mixedEstimateRoute.POST(json("POST", mm({ engine: "cloud", mode: "fast", modelId: "nano-banana-2-1", source: { url: "/api/files/placeholder.mp4", duration: 12, fps: 24 } })));expect(still.status).toBe(422);- expect((await still.json()).error).toMatch(/^Nano Banana 2 redraws single frames — pick Per frame/);+ expect((await still.json()).error).toMatch(/^Nano Banana 2.1 redraws single frames — pick Per frame/);} finally {setSetting("falKey", "");}@@ -605,7 +608,7 @@ describe("Mixed Media renders", () => {expect(est).toMatchObject({ mode: "smooth", demo: true, modelId: "fuobe-mixed-media" });expect(est.notes.join(" ")).toMatch(/Smooth draws the first frame in the look/);// Smooth is the Original's own; Fast is the cloud's.- expect((await mixedEstimateRoute.POST(json("POST", { ...noir, mode: "smooth", modelId: "nano-banana-2" }))).status).toBe(422);+ expect((await mixedEstimateRoute.POST(json("POST", { ...noir, mode: "smooth", modelId: "nano-banana-2-1" }))).status).toBe(422);expect((await mixedEstimateRoute.POST(json("POST", mm({ mode: "fast" })))).status).toBe(422);});diff --git a/tests/shorts.test.ts b/tests/shorts.test.tsindex 8364149f..81038010 100644--- a/tests/shorts.test.ts+++ b/tests/shorts.test.ts@@ -276,7 +276,7 @@ describe("Shorts pipeline shape", () => {expect(plan.segments).toHaveLength(6);const by = Object.fromEntries(plan.steps.map((s) => [s.key, s]));expect(by.cut0.request).toMatchObject({ modelId: "oss-segment", op: "trim", params: { startTime: 0, fps: 16, aspectRatio: "9:16", resolution: "480p" } });- expect(by.frame0).toMatchObject({ after: ["cut0"], chain: [{ slot: "images", position: "first" }], request: { modelId: "oss-qwen-edit", op: "edit", inputs: { images: refs.slice(0, 2) } } });+ expect(by.frame0).toMatchObject({ after: ["cut0"], chain: [{ slot: "images", position: "first" }], request: { modelId: "oss-qwen-image-21-turbo", op: "edit", inputs: { images: refs.slice(0, 2) } } });expect(by.look0).toMatchObject({ after: ["cut0", "frame0"], chain: [{ slot: "video" }, { slot: "images" }], request: { modelId: "oss-wan22-vace-restyle", op: "v2v" } });// The restyle runs exactly as many frames as its segment.for (const s of plan.segments) expect(Math.round((by[`look${s.index}`].request.params!.duration as number) * 16)).toBe(s.frames);diff --git a/tests/storyboard.test.ts b/tests/storyboard.test.tsindex 52683316..3b8b765b 100644--- a/tests/storyboard.test.ts+++ b/tests/storyboard.test.ts@@ -1,6 +1,11 @@import { describe, expect, it } from "vitest";-import { getModel } from "@/lib/catalog";-import { framePrompt, heuristicScenes, parseScenes, STORYBOARD_MODELS } from "@/lib/catalog/storyboard";+import { getModel, getPreset } from "@/lib/catalog";+import { planGeneration } from "@/lib/catalog/plan";+import type { GenerationRequest } from "@/lib/catalog/types";+import { framePrompt, heuristicScenes, parseScenes, planStoryboard, STORYBOARD_MODELS } from "@/lib/catalog/storyboard";++const plan = (r: GenerationRequest) => planGeneration(r, getModel, getPreset);+const graph = (r: GenerationRequest) => { const p = plan(r); return p.model.routes.find((x) => x.op === p.op)!.endpoint; };describe("storyboard", () => {it("parses LLM answers as a JSON array or a numbered list", () => {@@ -27,6 +32,22 @@ describe("storyboard", () => {for (const m of Object.values(STORYBOARD_MODELS)) {expect(getModel(m.next)?.routes.some((r) => r.op === "edit")).toBe(true);expect(getModel(m.first)?.routes.some((r) => r.op === "t2i")).toBe(true);+ expect(getModel(m.firstWithRefs)?.routes.some((r) => r.op === "edit")).toBe(true);}});++ it("makes frame 1 on Qwen-Image 2.1 on your GPU (text to image, or an edit of up to 4 references); the next frames and the cloud stay", () => {+ expect(STORYBOARD_MODELS.open).toMatchObject({ first: "oss-qwen-image-21", firstWithRefs: "oss-qwen-image-21", next: "oss-qwen-next-scene", chainFrom: "first" });+ expect(STORYBOARD_MODELS.cloud).toMatchObject({ first: "z-image-turbo-cloud", firstWithRefs: "qwen-image-edit-2511-cloud", next: "qwen-image-edit-2509-cloud" });+ const scenes = ["a girl waits at a bus stop", "the bus arrives"];+ const plain = planStoryboard({ engine: "open", scenes, aspectRatio: "21:9", resolution: "1K" });+ expect(plain[0]).toMatchObject({ modelId: "oss-qwen-image-21", params: { aspectRatio: "21:9", resolution: "1K" } });+ expect(plain[0].inputs).toBeUndefined();+ expect(graph(plain[0])).toBe("qwen-image-21-t2i");+ expect(plain[1].modelId).toBe("oss-qwen-next-scene");+ const refs = ["/api/files/a.png", "/api/files/b.png", "/api/files/c.png", "/api/files/d.png", "/api/files/e.png"];+ const withRefs = planStoryboard({ engine: "open", scenes, references: refs });+ expect(withRefs[0]).toMatchObject({ modelId: "oss-qwen-image-21", inputs: { images: refs.slice(0, 4) } });+ expect(graph(withRefs[0])).toBe("qwen-image-21-edit");+ });});diff --git a/tests/turnaround.test.ts b/tests/turnaround.test.tsindex b3f6332b..b2cfe767 100644--- a/tests/turnaround.test.ts+++ b/tests/turnaround.test.ts@@ -197,7 +197,7 @@ describe("the open engine: Frames mode's chain", () => {["fill-left", ["front"]],["main", ["front", "fill-right", "fill-back", "fill-left", "front"]],]);- expect(plan.steps[0].request).toMatchObject({ modelId: "oss-qwen-edit", op: "edit", inputs: { images: [SHEET] } });+ expect(plan.steps[0].request).toMatchObject({ modelId: "oss-qwen-image-21", op: "edit", inputs: { images: [SHEET] } });expect(plan.steps[1].request.chain).toEqual([{ slot: "images" }]);const main = plan.steps[4].request;expect(main.inputs).toBeUndefined();