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
Originals O1: LoRAs on the cloud engine (generated FieldMaps, fal and Replicate payloads, hosted open models)
Claude1d1be6634861
diff --git a/docs/research/fuobe-originals-recipes-5.json b/docs/research/fuobe-originals-recipes-5.jsonindex 6b8eaf49..08985329 100644--- a/docs/research/fuobe-originals-recipes-5.json+++ b/docs/research/fuobe-originals-recipes-5.json@@ -98,7 +98,157 @@"image_size": "anyOf[object {height:integer default=512 maximum=14142; width:integer default=512 maximum=14142}, string enum=[\"square_hd\", \"square\", \"portrait_4_3\", \"portrait_"},"pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights.",- "criticNote": "Re-read 2026-10-23: loras max 3, scale 0-4, num_inference_steps 1-8 (default 8), num_images 1-4, acceleration none|regular|high (default regular); $0.0085 per megapixel."+ "criticNote": "Re-read 2026-10-23: loras max 3, scale 0-4, num_inference_steps 1-8 (default 8), num_images 1-4, acceleration none|regular|high (default regular); $0.0085 per megapixel.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate an image from.",+ "examples": [+ "A hyper-realistic, close-up portrait of a tribal elder from the Omo Valley, painted with intricate white chalk patterns and adorned with a headdress made of dried flowers, seed pods, and rusted bottle caps. The focus is razor-sharp on the texture of the skin, showing every pore, wrinkle, and scar that tells a story of survival. The background is a blurred, smoky hut interior, with the warm glow of a cooking fire reflecting in the subject's dark, soulful eyes. Shot on a Leica M6 with Kodak Portra 400 film grain aesthetic."+ ]+ },+ "image_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ },+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "landscape_4_3",+ "desc": "The size of the generated image."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 8,+ "minimum": 1,+ "maximum": 8,+ "desc": "The number of inference steps to perform."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "\n The same seed and the same prompt given to the same version of the model\n will output the same image every time.\n "+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "num_images": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 1,+ "maximum": 4,+ "desc": "The number of images to generate."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked, and images flagged as unsafe are returned as black images."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "jpeg",+ "png",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "png",+ "desc": "The format of the generated image."+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use."+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to enable prompt expansion. Note: this will increase the price by 0.0025 credits per request."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Scale factor for LoRA application (0.0 to 4.0)."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "List of LoRA weights to apply (maximum 3)."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "numOutputs": "num_images",+ "loras": "loras"+ },+ "output": "images[].url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -257,7 +407,166 @@"acceleration": "string default=\"regular\" enum=[\"none\", \"regular\", \"high\"]","image_size": "anyOf[object {height:integer default=512 maximum=14142; width:integer default=512 maximum=14142}, string enum=[\"square_hd\", \"square\", \"portrait_4_3\", \"portrait_"},- "pathAccepts": "URL or the path to the LoRA weights."+ "pathAccepts": "URL or the path to the LoRA weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate an image from.",+ "examples": [+ "Single red rose in a clear glass vase on white marble streaked with black and gold veins, harsh directional shadow, high contrast, editorial style, clean negative space."+ ]+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "",+ "desc": "The negative prompt to generate an image from."+ },+ "image_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "landscape_4_3",+ "desc": "The size of the generated image."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 28,+ "minimum": 1,+ "maximum": 50,+ "desc": "The number of inference steps to perform."+ },+ "guidance_scale": {+ "type": "number",+ "required": false,+ "default": 4,+ "minimum": 0,+ "maximum": 20,+ "desc": "The guidance scale to use for the image generation."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "\n The same seed and the same prompt given to the same version of the model\n will output the same image every time.\n "+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "num_images": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 1,+ "maximum": 4,+ "desc": "The number of images to generate."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked, and images flagged as unsafe are returned as black images."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "jpeg",+ "png",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "png",+ "desc": "The format of the generated image."+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "\n The scale of the LoRA weight. This is used to scale the LoRA weight\n before merging it with the base model.\n "+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL or the path to the LoRA weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "\n The LoRAs to use for the image generation. You can use up to 3 LoRAs\n and they will be merged together to generate the final image.\n "+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "numOutputs": "num_images",+ "loras": "loras"+ },+ "output": "images[].url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -320,7 +629,178 @@"acceleration": "string default=\"regular\" enum=[\"none\", \"regular\", \"high\"]","image_size": "anyOf[object {height:integer default=512 maximum=14142; width:integer default=512 maximum=14142}, string enum=[\"square_hd\", \"square\", \"portrait_4_3\", \"portrait_"},- "pathAccepts": "URL or the path to the LoRA weights."+ "pathAccepts": "URL or the path to the LoRA weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to edit the image with.",+ "examples": [+ "Change angle to front view"+ ]+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "",+ "desc": "The negative prompt to generate an image from."+ },+ "image_size": {+ "nullable": true,+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "desc": "The size of the generated image. If None, uses the input image dimensions."+ },+ "image_urls": {+ "type": "array",+ "items": "string",+ "required": true,+ "desc": "The URLs of the images to edit.",+ "examples": [+ [+ "https://v3b.fal.media/files/b/0a877afe/karyVuQ62j0V6ErYzyW-w_image_6.png"+ ]+ ]+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 28,+ "minimum": 1,+ "maximum": 50,+ "desc": "The number of inference steps to perform."+ },+ "guidance_scale": {+ "type": "number",+ "required": false,+ "default": 4.5,+ "minimum": 1,+ "maximum": 20,+ "desc": "The guidance scale to use for the image generation."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The same seed and the same prompt given to the same version of the model will output the same image every time."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI."+ },+ "num_images": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 1,+ "maximum": 4,+ "desc": "The number of images to generate."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "jpeg",+ "png",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "png",+ "desc": "The format of the generated image."+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "\n The scale of the LoRA weight. This is used to scale the LoRA weight\n before merging it with the base model.\n "+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL or the path to the LoRA weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "The LoRAs to use for the image generation. You can use up to 3 LoRAs and they will be merged together to generate the final image."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "numOutputs": "num_images",+ "loras": "loras",+ "images": "image_urls"+ },+ "output": "images[].url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -412,7 +892,139 @@"num_inference_steps": "integer default=4 minimum=4 maximum=8","image_size": "anyOf[object {height:integer default=512 maximum=14142; width:integer default=512 maximum=14142}, string enum=[\"square_hd\", \"square\", \"portrait_4_3\", \"portrait_"},- "pathAccepts": "URL, HuggingFace repo ID (owner/repo), or local path to LoRA weights."+ "pathAccepts": "URL, HuggingFace repo ID (owner/repo), or local path to LoRA weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate an image from.",+ "examples": [+ "Cheetah in pre-sprint crouch, muscles tensed, gazelle visible in distance, African savanna golden grass, dust particles in air, National Geographic wildlife photography"+ ]+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed to use for the generation. If not provided, a random seed will be used."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 4,+ "minimum": 4,+ "maximum": 8,+ "desc": "The number of inference steps to perform."+ },+ "image_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ },+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "landscape_4_3",+ "desc": "The size of the image to generate."+ },+ "num_images": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 1,+ "maximum": 4,+ "desc": "The number of images to generate."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI. Output is not stored when this is True."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked, and images flagged as unsafe are returned as black images."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "jpeg",+ "png",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "png",+ "desc": "The format of the generated image."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Scale factor for LoRA application (0.0 to 4.0)."+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL, HuggingFace repo ID (owner/repo), or local path to LoRA weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "List of LoRA weights to apply (maximum 3)."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "numOutputs": "num_images",+ "loras": "loras"+ },+ "output": "images[].url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -474,7 +1086,157 @@"num_inference_steps": "integer default=4 minimum=4 maximum=8","image_size": "anyOf[object {height:integer default=512 maximum=14142; width:integer default=512 maximum=14142}, string enum=[\"square_hd\", \"square\", \"portrait_4_3\", \"portrait_"},- "pathAccepts": "URL, HuggingFace repo ID (owner/repo), or local path to LoRA weights."+ "pathAccepts": "URL, HuggingFace repo ID (owner/repo), or local path to LoRA weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to edit the image.",+ "examples": [+ "Turn this into a realistic image"+ ]+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed to use for the generation. If not provided, a random seed will be used."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 4,+ "minimum": 4,+ "maximum": 8,+ "desc": "The number of inference steps to perform."+ },+ "image_size": {+ "nullable": true,+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ },+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "desc": "The size of the generated image. If not provided, uses the input image size.",+ "examples": [+ {+ "width": 2016,+ "height": 1152+ }+ ]+ },+ "num_images": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 1,+ "maximum": 4,+ "desc": "The number of images to generate."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI. Output is not stored when this is True."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked, and images flagged as unsafe are returned as black images."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "jpeg",+ "png",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "png",+ "desc": "The format of the generated image."+ },+ "image_urls": {+ "type": "array",+ "items": "string",+ "required": true,+ "desc": "The URLs of the images for editing. A maximum of 4 images are allowed.",+ "examples": [+ [+ "https://v3b.fal.media/files/b/0a8a69d5/kkXxFfj1QeVtw35kxy5Py_1a7e3511-bd2c-46be-923a-8e6be2496f12.png"+ ]+ ]+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Scale factor for LoRA application (0.0 to 4.0)."+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL, HuggingFace repo ID (owner/repo), or local path to LoRA weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "List of LoRA weights to apply (maximum 3)."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "numOutputs": "num_images",+ "loras": "loras",+ "images": "image_urls"+ },+ "output": "images[].url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -658,7 +1420,231 @@"acceleration": "string default=\"regular\" enum=[\"none\", \"regular\"]","image_size": "anyOf[object {height:integer default=512 maximum=14142; width:integer default=512 maximum=14142}, string enum=[\"square_hd\", \"square\", \"portrait_4_3\", \"portrait_"},- "pathAccepts": "URL or the path to the LoRA weights."+ "pathAccepts": "URL or the path to the LoRA weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The text prompt to guide image generation.",+ "examples": [+ "In this breathtaking wildlife documentary, we are drawn into an intimate close-up of a majestic lion's face, framed against the backdrop of a vast African savannah at dawn. The camera captures the raw power and nobility of the creature as it gazes intently into the distance, its golden-brown fur glistening under the soft, diffused light that bathes the scene in an ethereal glow. Harsh shadows dance across its features, accentuating the deep wrinkles around its eyes and the rugged texture of its fur, each strand a testament to its age and wisdom. The static camera angle invites viewers to immerse themselves in this moment of profound stillness, where the lion's intense focus hints at an unseen presence or a distant threat. As the sun ascends, the landscape transforms into a symphony of warm hues, enhancing the serene yet tense atmosphere that envelops this extraordinary encounter with nature's untamed beauty."+ ]+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "",+ "desc": "Negative prompt for video generation."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "Random seed for reproducibility. If None, a random seed is chosen."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 27,+ "minimum": 2,+ "maximum": 40,+ "desc": "Number of inference steps for sampling. Higher values give better quality but take longer.",+ "examples": [+ 27+ ]+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If set to true, input data will be checked for safety before processing. Disabling it requires account authorization; unauthorized requests are always checked.",+ "examples": [+ true+ ]+ },+ "enable_output_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If set to true, output video will be checked for safety after generation.",+ "examples": [+ false+ ]+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to enable prompt expansion. This will use a large language model to expand the prompt with additional details while maintaining the original meaning.",+ "examples": [+ false+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "Acceleration level to use. The more acceleration, the faster the generation, but with lower quality. The recommended value is 'regular'.",+ "examples": [+ "regular"+ ]+ },+ "guidance_scale": {+ "type": "number",+ "required": false,+ "default": 3.5,+ "minimum": 1,+ "maximum": 10,+ "desc": "Classifier-free guidance scale. Higher values give better adherence to the prompt but may decrease quality.",+ "examples": [+ 3.5+ ]+ },+ "guidance_scale_2": {+ "type": "number",+ "required": false,+ "default": 4,+ "minimum": 1,+ "maximum": 10,+ "desc": "Guidance scale for the second stage of the model. This is used to control the adherence to the prompt in the second stage of the model.",+ "examples": [+ 4+ ]+ },+ "shift": {+ "type": "number",+ "required": false,+ "default": 2,+ "minimum": 1,+ "maximum": 10,+ "desc": "Shift value for the image. Must be between 1.0 and 10.0.",+ "examples": [+ 2+ ]+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "transformer": {+ "type": "enum",+ "values": [+ "high",+ "low",+ "both"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "Specifies the transformer to load the lora weight into. 'high' loads into the high-noise transformer, 'low' loads it into the low-noise transformer, while 'both' loads the LoRA into both transformers."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "\n The scale of the LoRA weight. This is used to scale the LoRA weight\n before merging it with the base model.\n "+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL or the path to the LoRA weights."+ },+ "weight_name": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "Name of the LoRA weight. Used only if `path` is a Hugging Face repository, and required only if you have more than 1 safetensors file in the repo."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "LoRA weights to be used in the inference."+ },+ "reverse_video": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If true, the video will be reversed."+ },+ "image_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ },+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "square_hd",+ "desc": "The size of the generated image.",+ "examples": [+ "square_hd"+ ]+ },+ "image_format": {+ "type": "enum",+ "values": [+ "png",+ "jpeg"+ ],+ "valueType": "string",+ "required": false,+ "default": "jpeg",+ "desc": "The format of the output image.",+ "examples": [+ "jpeg"+ ]+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "loras": "loras"+ },+ "output": "images[].url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -754,7 +1740,307 @@"num_frames": "integer default=81 minimum=17 maximum=161"},"pathAccepts": "URL or the path to the LoRA weights.",- "criticNote": "Re-read 2026-10-23: frames_per_second defaults to 16, but interpolator_model defaults to 'film' with num_interpolated_frames 1 and adjust_fps_for_interpolation true, so a default request returns 32 fps. For DoP parity (49/81 frames at 16 fps) send interpolator_model 'none'. Defaults: num_frames 81 (17-161), 27 steps (2-40), shift 5, guidance_scale 3.5, guidance_scale_2 4, resolution 720p."+ "criticNote": "Re-read 2026-10-23: frames_per_second defaults to 16, but interpolator_model defaults to 'film' with num_interpolated_frames 1 and adjust_fps_for_interpolation true, so a default request returns 32 fps. For DoP parity (49/81 frames at 16 fps) send interpolator_model 'none'. Defaults: num_frames 81 (17-161), 27 steps (2-40), shift 5, guidance_scale 3.5, guidance_scale_2 4, resolution 720p.",+ "inputs": {+ "image_url": {+ "type": "string",+ "required": true,+ "desc": "URL of the input image. If the input image does not match the chosen aspect ratio, it is resized and center cropped.",+ "examples": [+ "https://storage.googleapis.com/falserverless/gallery/car_720p.png"+ ]+ },+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The text prompt to guide video generation.",+ "examples": [+ "Cars racing in slow motion"+ ]+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 81,+ "minimum": 17,+ "maximum": 161,+ "desc": "Number of frames to generate. Must be between 17 to 161 (inclusive).",+ "examples": [+ 81+ ]+ },+ "frames_per_second": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "default": 16,+ "minimum": 4,+ "maximum": 60,+ "desc": "Frames per second of the generated video. Must be between 4 to 60. When using interpolation and `adjust_fps_for_interpolation` is set to true (default true,) the final FPS will be multiplied by the number of interpolated frames plus one. For example, if the generated frames per second is 16 and the number of interpolated frames is 1, the final frames per second will be 32. If `adjust_fps_for_interpolation` is set to false, this value will be used as-is.",+ "examples": [+ 16+ ]+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "",+ "desc": "Negative prompt for video generation."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "Random seed for reproducibility. If None, a random seed is chosen."+ },+ "resolution": {+ "type": "enum",+ "values": [+ "480p",+ "580p",+ "720p"+ ],+ "valueType": "string",+ "required": false,+ "default": "720p",+ "desc": "Resolution of the generated video (480p, 580p, or 720p).",+ "examples": [+ "720p"+ ]+ },+ "aspect_ratio": {+ "type": "enum",+ "values": [+ "auto",+ "16:9",+ "9:16",+ "1:1"+ ],+ "valueType": "string",+ "required": false,+ "default": "auto",+ "desc": "Aspect ratio of the generated video. If 'auto', the aspect ratio will be determined automatically based on the input image."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 27,+ "minimum": 2,+ "maximum": 40,+ "desc": "Number of inference steps for sampling. Higher values give better quality but take longer.",+ "examples": [+ 27+ ]+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If set to true, input data will be checked for safety before processing. Disabling it requires account authorization; unauthorized requests are always checked.",+ "examples": [+ true+ ]+ },+ "enable_output_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If set to true, output video will be checked for safety after generation.",+ "examples": [+ false+ ]+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to enable prompt expansion. This will use a large language model to expand the prompt with additional details while maintaining the original meaning.",+ "examples": [+ false+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "Acceleration level to use. The more acceleration, the faster the generation, but with lower quality. The recommended value is 'regular'.",+ "examples": [+ "regular"+ ]+ },+ "guidance_scale": {+ "type": "number",+ "required": false,+ "default": 3.5,+ "minimum": 1,+ "maximum": 10,+ "desc": "Classifier-free guidance scale. Higher values give better adherence to the prompt but may decrease quality.",+ "examples": [+ 3.5+ ]+ },+ "guidance_scale_2": {+ "type": "number",+ "required": false,+ "default": 4,+ "minimum": 1,+ "maximum": 10,+ "desc": "Guidance scale for the second stage of the model. This is used to control the adherence to the prompt in the second stage of the model.",+ "examples": [+ 4+ ]+ },+ "shift": {+ "type": "number",+ "required": false,+ "default": 5,+ "minimum": 1,+ "maximum": 10,+ "desc": "Shift value for the video. Must be between 1.0 and 10.0.",+ "examples": [+ 5+ ]+ },+ "interpolator_model": {+ "type": "enum",+ "values": [+ "none",+ "film",+ "rife"+ ],+ "valueType": "string",+ "required": false,+ "default": "film",+ "desc": "The model to use for frame interpolation. If None, no interpolation is applied.",+ "examples": [+ "film"+ ]+ },+ "num_interpolated_frames": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Number of frames to interpolate between each pair of generated frames. Must be between 0 and 4.",+ "examples": [+ 1+ ]+ },+ "adjust_fps_for_interpolation": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If true, the number of frames per second will be multiplied by the number of interpolated frames plus one. For example, if the generated frames per second is 16 and the number of interpolated frames is 1, the final frames per second will be 32. If false, the passed frames per second will be used as-is.",+ "examples": [+ true+ ]+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the output video. Higher quality means better visual quality but larger file size.",+ "examples": [+ "high"+ ]+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the output video. Faster write mode means faster results but larger file size, balanced write mode is a good compromise between speed and quality, and small write mode is the slowest but produces the smallest file size.",+ "examples": [+ "balanced"+ ]+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "transformer": {+ "type": "enum",+ "values": [+ "high",+ "low",+ "both"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "Specifies the transformer to load the lora weight into. 'high' loads into the high-noise transformer, 'low' loads it into the low-noise transformer, while 'both' loads the LoRA into both transformers."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "\n The scale of the LoRA weight. This is used to scale the LoRA weight\n before merging it with the base model.\n "+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL or the path to the LoRA weights."+ },+ "weight_name": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "Name of the LoRA weight. Used only if `path` is a Hugging Face repository, and required only if you have more than 1 safetensors file in the repo."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "LoRA weights to be used in the inference."+ },+ "reverse_video": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If true, the video will be reversed."+ },+ "end_image_url": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "URL of the end image."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "image": "image_url",+ "endImage": "end_image_url",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "aspect_ratio",+ "resolution": "resolution",+ "numFrames": "num_frames",+ "seed": "seed",+ "loras": "loras"+ },+ "output": "video.url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -786,7 +2072,293 @@"resolution": "string default=\"720p\" enum=[\"480p\", \"580p\", \"720p\"]","num_frames": "integer default=81 minimum=17 maximum=161"},- "pathAccepts": "URL or the path to the LoRA weights."+ "pathAccepts": "URL or the path to the LoRA weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The text prompt to guide video generation.",+ "examples": [+ "A close-up of a young woman smiling gently in the rain, raindrops glistening on her face and eyelashes. The video captures the delicate details of her expression and the water droplets, with soft light reflecting off her skin in the rainy atmosphere."+ ]+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "",+ "desc": "Negative prompt for video generation."+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 81,+ "minimum": 17,+ "maximum": 161,+ "desc": "Number of frames to generate. Must be between 17 to 161 (inclusive).",+ "examples": [+ 81+ ]+ },+ "frames_per_second": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "default": 16,+ "minimum": 4,+ "maximum": 60,+ "desc": "Frames per second of the generated video. Must be between 4 to 60. When using interpolation and `adjust_fps_for_interpolation` is set to true (default true,) the final FPS will be multiplied by the number of interpolated frames plus one. For example, if the generated frames per second is 16 and the number of interpolated frames is 1, the final frames per second will be 32. If `adjust_fps_for_interpolation` is set to false, this value will be used as-is.",+ "examples": [+ 16+ ]+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "Random seed for reproducibility. If None, a random seed is chosen."+ },+ "resolution": {+ "type": "enum",+ "values": [+ "480p",+ "580p",+ "720p"+ ],+ "valueType": "string",+ "required": false,+ "default": "720p",+ "desc": "Resolution of the generated video (480p, 580p, or 720p).",+ "examples": [+ "720p"+ ]+ },+ "aspect_ratio": {+ "type": "enum",+ "values": [+ "16:9",+ "9:16",+ "1:1"+ ],+ "valueType": "string",+ "required": false,+ "default": "16:9",+ "desc": "Aspect ratio of the generated video (16:9 or 9:16).",+ "examples": [+ "16:9"+ ]+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 27,+ "minimum": 2,+ "maximum": 40,+ "desc": "Number of inference steps for sampling. Higher values give better quality but take longer.",+ "examples": [+ 27+ ]+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If set to true, input data will be checked for safety before processing. Disabling it requires account authorization; unauthorized requests are always checked.",+ "examples": [+ true+ ]+ },+ "enable_output_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If set to true, output video will be checked for safety after generation.",+ "examples": [+ false+ ]+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to enable prompt expansion. This will use a large language model to expand the prompt with additional details while maintaining the original meaning.",+ "examples": [+ false+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "Acceleration level to use. The more acceleration, the faster the generation, but with lower quality. The recommended value is 'regular'.",+ "examples": [+ "regular"+ ]+ },+ "guidance_scale": {+ "type": "number",+ "required": false,+ "default": 3.5,+ "minimum": 1,+ "maximum": 10,+ "desc": "Classifier-free guidance scale. Higher values give better adherence to the prompt but may decrease quality.",+ "examples": [+ 3.5+ ]+ },+ "guidance_scale_2": {+ "type": "number",+ "required": false,+ "default": 4,+ "minimum": 1,+ "maximum": 10,+ "desc": "Guidance scale for the second stage of the model. This is used to control the adherence to the prompt in the second stage of the model.",+ "examples": [+ 4+ ]+ },+ "shift": {+ "type": "number",+ "required": false,+ "default": 5,+ "minimum": 1,+ "maximum": 10,+ "desc": "Shift value for the video. Must be between 1.0 and 10.0.",+ "examples": [+ 5+ ]+ },+ "interpolator_model": {+ "type": "enum",+ "values": [+ "none",+ "film",+ "rife"+ ],+ "valueType": "string",+ "required": false,+ "default": "film",+ "desc": "The model to use for frame interpolation. If None, no interpolation is applied.",+ "examples": [+ "film"+ ]+ },+ "num_interpolated_frames": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Number of frames to interpolate between each pair of generated frames. Must be between 0 and 4.",+ "examples": [+ 1+ ]+ },+ "adjust_fps_for_interpolation": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If true, the number of frames per second will be multiplied by the number of interpolated frames plus one. For example, if the generated frames per second is 16 and the number of interpolated frames is 1, the final frames per second will be 32. If false, the passed frames per second will be used as-is.",+ "examples": [+ true+ ]+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the output video. Higher quality means better visual quality but larger file size.",+ "examples": [+ "high"+ ]+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the output video. Faster write mode means faster results but larger file size, balanced write mode is a good compromise between speed and quality, and small write mode is the slowest but produces the smallest file size.",+ "examples": [+ "balanced"+ ]+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "transformer": {+ "type": "enum",+ "values": [+ "high",+ "low",+ "both"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "Specifies the transformer to load the lora weight into. 'high' loads into the high-noise transformer, 'low' loads it into the low-noise transformer, while 'both' loads the LoRA into both transformers."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "\n The scale of the LoRA weight. This is used to scale the LoRA weight\n before merging it with the base model.\n "+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL or the path to the LoRA weights."+ },+ "weight_name": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "Name of the LoRA weight. Used only if `path` is a Hugging Face repository, and required only if you have more than 1 safetensors file in the repo."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": false,+ "default": [],+ "desc": "LoRA weights to be used in the inference."+ },+ "reverse_video": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If true, the video will be reversed."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "aspect_ratio",+ "resolution": "resolution",+ "numFrames": "num_frames",+ "seed": "seed",+ "loras": "loras"+ },+ "output": "video.url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -919,7 +2491,402 @@"num_frames": "integer default=121 minimum=9 maximum=481"},"pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights.",- "criticNote": "Re-read 2026-10-23: loras is required; camera_lora enum dolly_in|dolly_out|dolly_left|dolly_right|jib_up|jib_down|static|none, camera_lora_scale 0-1; fps default 24; num_frames 9-481 (default 121); 8-50 steps (default 40). enable_prompt_expansion and generate_audio both default to true; Originals must set them explicitly (prompt expansion off so the compiled Director prompt is kept)."+ "criticNote": "Re-read 2026-10-23: loras is required; camera_lora enum dolly_in|dolly_out|dolly_left|dolly_right|jib_up|jib_down|static|none, camera_lora_scale 0-1; fps default 24; num_frames 9-481 (default 121); 8-50 steps (default 40). enable_prompt_expansion and generate_audio both default to true; Originals must set them explicitly (prompt expansion off so the compiled Director prompt is kept).",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt used for the generation.",+ "examples": [+ "A woman stands still amid a busy neon-lit street at night. The camera slowly dollies in toward her face as people blur past, their motion emphasizing her calm presence. City lights flicker and reflections shift across her denim jacket."+ ]+ },+ "image_url": {+ "type": "string",+ "required": true,+ "desc": "The URL of the image to generate the video from.",+ "examples": [+ "https://storage.googleapis.com/falserverless/example_inputs/ltxv-2-i2v-input.jpg"+ ]+ },+ "end_image_url": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "The URL of the image to use as the end of the video."+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 121,+ "minimum": 9,+ "maximum": 481,+ "desc": "The number of frames to generate."+ },+ "video_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "auto",+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "auto",+ "desc": "The size of the generated video."+ },+ "generate_audio": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to generate audio for the video."+ },+ "use_multiscale": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to use multi-scale generation. If True, the model will generate the video at a smaller scale first, then use the smaller video to guide the generation of a video at or above your requested size. This results in better coherence and details."+ },+ "fps": {+ "type": "number",+ "required": false,+ "default": 24,+ "minimum": 1,+ "maximum": 60,+ "desc": "The frames per second of the generated video."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 40,+ "minimum": 8,+ "maximum": 50,+ "desc": "The number of inference steps to use."+ },+ "video_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the video. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "video_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the video. Controls the ratio between video and audio modalities."+ },+ "audio_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 7,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the audio. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "audio_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the audio. Controls the ratio between video and audio modalities."+ },+ "gradient_estimation_gamma": {+ "type": "number",+ "required": false,+ "default": 2,+ "minimum": 0,+ "maximum": 10,+ "desc": "The gamma of gradient estimation during denoising. Set to 0 to disable."+ },+ "use_restart_sampling": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to use restart sampling. This will inject a small amount of noise during each denoising step, which can help improve the quality of the generated video."+ },+ "scheduler": {+ "type": "enum",+ "values": [+ "ltx2",+ "linear_quadratic",+ "beta"+ ],+ "valueType": "string",+ "required": false,+ "default": "ltx2",+ "desc": "The scheduler to use.",+ "examples": [+ "ltx2"+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high",+ "full"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use.",+ "examples": [+ "regular"+ ]+ },+ "camera_lora": {+ "type": "enum",+ "values": [+ "dolly_in",+ "dolly_out",+ "dolly_left",+ "dolly_right",+ "jib_up",+ "jib_down",+ "static",+ "none"+ ],+ "valueType": "string",+ "required": false,+ "default": "none",+ "desc": "The camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera.",+ "examples": [+ "none"+ ]+ },+ "camera_lora_scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera."+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "news broadcast, 3d animation, computer graphics, pc game, console game, video game, cartoon, childish, watermark, logo, text, on screen text, subtitles, titles, signature, slowmo, static",+ "desc": "The negative prompt to generate the video from."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed for the random number generator."+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable prompt expansion."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable the safety checker."+ },+ "video_output_type": {+ "type": "enum",+ "values": [+ "X264 (.mp4)",+ "VP9 (.webm)",+ "PRORES4444 (.mov)",+ "GIF (.gif)"+ ],+ "valueType": "string",+ "required": false,+ "default": "X264 (.mp4)",+ "desc": "The output type of the generated video."+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the generated video."+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the generated video."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "weight_name": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "Name of the LoRA weight. Only used if `path` is a HuggingFace repository, and is only required when the repository contains multiple LoRA weights."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Scale factor for LoRA application (0.0 to 4.0)."+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": true,+ "desc": "The LoRAs to use for the generation."+ },+ "distill_lora_first_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.2,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the first pass. Set to 0 to disable."+ },+ "distill_lora_second_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.5,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the second and subsequent passes."+ },+ "interpolation_direction": {+ "type": "enum",+ "values": [+ "forward",+ "backward"+ ],+ "valueType": "string",+ "required": false,+ "default": "forward",+ "desc": "The direction to interpolate the image sequence in. 'Forward' goes from the start image to the end image, 'Backward' goes from the end image to the start image."+ },+ "image_strength": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The strength of the image to use for the video generation."+ },+ "end_image_strength": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The strength of the end image to use for the video generation."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "video_size",+ "seed": "seed",+ "generateAudio": "generate_audio",+ "numFrames": "num_frames",+ "fps": "fps",+ "loras": "loras",+ "image": "image_url",+ "endImage": "end_image_url"+ },+ "output": "video.url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -953,7 +2920,358 @@"acceleration": "string default=\"regular\" enum=[\"none\", \"regular\", \"high\", \"full\"]","num_frames": "integer default=121 minimum=9 maximum=481"},- "pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ "pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate the video from.",+ "examples": [+ "A cowboy walking through a dusty town at high noon, camera following from behind, cinematic depth, realistic lighting, western mood, 4K film grain."+ ]+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 121,+ "minimum": 9,+ "maximum": 481,+ "desc": "The number of frames to generate."+ },+ "video_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "landscape_16_9",+ "desc": "The size of the generated video."+ },+ "generate_audio": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to generate audio for the video."+ },+ "use_multiscale": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to use multi-scale generation. If True, the model will generate the video at a smaller scale first, then use the smaller video to guide the generation of a video at or above your requested size. This results in better coherence and details."+ },+ "fps": {+ "type": "number",+ "required": false,+ "default": 24,+ "minimum": 1,+ "maximum": 60,+ "desc": "The frames per second of the generated video."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 40,+ "minimum": 8,+ "maximum": 50,+ "desc": "The number of inference steps to use."+ },+ "video_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the video. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "video_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the video. Controls the ratio between video and audio modalities."+ },+ "audio_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 7,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the audio. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "audio_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the audio. Controls the ratio between video and audio modalities."+ },+ "gradient_estimation_gamma": {+ "type": "number",+ "required": false,+ "default": 2,+ "minimum": 0,+ "maximum": 10,+ "desc": "The gamma of gradient estimation during denoising. Set to 0 to disable."+ },+ "use_restart_sampling": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to use restart sampling. This will inject a small amount of noise during each denoising step, which can help improve the quality of the generated video."+ },+ "scheduler": {+ "type": "enum",+ "values": [+ "ltx2",+ "linear_quadratic",+ "beta"+ ],+ "valueType": "string",+ "required": false,+ "default": "ltx2",+ "desc": "The scheduler to use.",+ "examples": [+ "ltx2"+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high",+ "full"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use.",+ "examples": [+ "regular"+ ]+ },+ "camera_lora": {+ "type": "enum",+ "values": [+ "dolly_in",+ "dolly_out",+ "dolly_left",+ "dolly_right",+ "jib_up",+ "jib_down",+ "static",+ "none"+ ],+ "valueType": "string",+ "required": false,+ "default": "none",+ "desc": "The camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera.",+ "examples": [+ "none"+ ]+ },+ "camera_lora_scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera."+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "news broadcast, 3d animation, computer graphics, pc game, console game, video game, cartoon, childish, watermark, logo, text, on screen text, subtitles, titles, signature, slowmo, static",+ "desc": "The negative prompt to generate the video from."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed for the random number generator."+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable prompt expansion."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable the safety checker."+ },+ "video_output_type": {+ "type": "enum",+ "values": [+ "X264 (.mp4)",+ "VP9 (.webm)",+ "PRORES4444 (.mov)",+ "GIF (.gif)"+ ],+ "valueType": "string",+ "required": false,+ "default": "X264 (.mp4)",+ "desc": "The output type of the generated video."+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the generated video."+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the generated video."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "weight_name": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "Name of the LoRA weight. Only used if `path` is a HuggingFace repository, and is only required when the repository contains multiple LoRA weights."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Scale factor for LoRA application (0.0 to 4.0)."+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": true,+ "desc": "The LoRAs to use for the generation."+ },+ "distill_lora_first_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.2,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the first pass. Set to 0 to disable."+ },+ "distill_lora_second_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.5,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the second and subsequent passes."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "video_size",+ "seed": "seed",+ "generateAudio": "generate_audio",+ "numFrames": "num_frames",+ "fps": "fps",+ "loras": "loras"+ },+ "output": "video.url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -1001,28 +3319,417 @@"itemFields": "weight_name:string; scale:number default=1 minimum=0 maximum=4; path:string","maxCount": "not stated"},- "keyFieldsRequired": [- "loras",- "prompt",- "video_url"- ],- "price": "Your request will cost $0.001805 per megapixel of generated video data (width × height × frames), rounded up. For example, if you generate a video that is 121 frames long at 1280 × 720, your total generated video is ≈112 MP, and your request will cost $0.2013",- "baseLicence": "LTX-2 / LTX-2.x Community License",- "commercialWeights": true,- "licenceNote": "Free for companies under US$10M annual revenue; above that a paid licence (github.com/Lightricks/LTX-2 LICENSE-2, LICENSE-2_x, section 2.1)",- "falLicenseType": "commercial",- "status": "active",- "schemaUrl": "https://fal.ai/api/openapi/queue/openapi.json?endpoint_id=fal-ai/ltx-2.3-22b/video-to-video/lora",- "pageUrl": "https://fal.ai/models/fal-ai/ltx-2.3-22b/video-to-video/lora",- "checked": "2026-10-23",- "otherFields": {- "camera_lora": "string default=\"none\" enum=[\"dolly_in\", \"dolly_out\", \"dolly_left\", \"dolly_right\", \"jib_up\", \"jib_down\", \"static\", \"none\"]",- "camera_lora_scale": "number default=1 minimum=0 maximum=1",- "num_inference_steps": "integer default=40 minimum=8 maximum=50",- "acceleration": "string default=\"regular\" enum=[\"none\", \"regular\", \"high\", \"full\"]",- "num_frames": "integer default=121 minimum=9 maximum=481"+ "keyFieldsRequired": [+ "loras",+ "prompt",+ "video_url"+ ],+ "price": "Your request will cost $0.001805 per megapixel of generated video data (width × height × frames), rounded up. For example, if you generate a video that is 121 frames long at 1280 × 720, your total generated video is ≈112 MP, and your request will cost $0.2013",+ "baseLicence": "LTX-2 / LTX-2.x Community License",+ "commercialWeights": true,+ "licenceNote": "Free for companies under US$10M annual revenue; above that a paid licence (github.com/Lightricks/LTX-2 LICENSE-2, LICENSE-2_x, section 2.1)",+ "falLicenseType": "commercial",+ "status": "active",+ "schemaUrl": "https://fal.ai/api/openapi/queue/openapi.json?endpoint_id=fal-ai/ltx-2.3-22b/video-to-video/lora",+ "pageUrl": "https://fal.ai/models/fal-ai/ltx-2.3-22b/video-to-video/lora",+ "checked": "2026-10-23",+ "otherFields": {+ "camera_lora": "string default=\"none\" enum=[\"dolly_in\", \"dolly_out\", \"dolly_left\", \"dolly_right\", \"jib_up\", \"jib_down\", \"static\", \"none\"]",+ "camera_lora_scale": "number default=1 minimum=0 maximum=1",+ "num_inference_steps": "integer default=40 minimum=8 maximum=50",+ "acceleration": "string default=\"regular\" enum=[\"none\", \"regular\", \"high\", \"full\"]",+ "num_frames": "integer default=121 minimum=9 maximum=481"+ },+ "pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate the video from.",+ "examples": [+ "style: cinematic/realistic. A man wearing a baseball cap walks through a modern town. He holds a coffee cup."+ ]+ },+ "video_url": {+ "type": "string",+ "required": true,+ "desc": "The URL of the video to generate the video from.",+ "examples": [+ "https://v3b.fal.media/files/b/0a8824b1/sdm0KfmenrlywesfzY1Y1_if6euPp1.mp4"+ ]+ },+ "match_video_length": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "When enabled, the number of frames will be calculated based on the video duration and FPS. When disabled, use the specified num_frames."+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 121,+ "minimum": 9,+ "maximum": 481,+ "desc": "The number of frames to generate."+ },+ "video_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "auto",+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "auto",+ "desc": "The size of the generated video."+ },+ "generate_audio": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to generate audio for the video."+ },+ "use_multiscale": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to use multi-scale generation. If True, the model will generate the video at a smaller scale first, then use the smaller video to guide the generation of a video at or above your requested size. This results in better coherence and details."+ },+ "match_input_fps": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "When true, match the output FPS to the input video's FPS instead of using the default target FPS."+ },+ "fps": {+ "type": "number",+ "required": false,+ "default": 24,+ "minimum": 1,+ "maximum": 60,+ "desc": "The frames per second of the generated video."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 40,+ "minimum": 8,+ "maximum": 50,+ "desc": "The number of inference steps to use."+ },+ "video_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the video. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "video_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the video. Controls the ratio between video and audio modalities."+ },+ "audio_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 7,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the audio. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "audio_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the audio. Controls the ratio between video and audio modalities."+ },+ "gradient_estimation_gamma": {+ "type": "number",+ "required": false,+ "default": 2,+ "minimum": 0,+ "maximum": 10,+ "desc": "The gamma of gradient estimation during denoising. Set to 0 to disable."+ },+ "use_restart_sampling": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to use restart sampling. This will inject a small amount of noise during each denoising step, which can help improve the quality of the generated video."+ },+ "scheduler": {+ "type": "enum",+ "values": [+ "ltx2",+ "linear_quadratic",+ "beta"+ ],+ "valueType": "string",+ "required": false,+ "default": "ltx2",+ "desc": "The scheduler to use.",+ "examples": [+ "ltx2"+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high",+ "full"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use.",+ "examples": [+ "regular"+ ]+ },+ "camera_lora": {+ "type": "enum",+ "values": [+ "dolly_in",+ "dolly_out",+ "dolly_left",+ "dolly_right",+ "jib_up",+ "jib_down",+ "static",+ "none"+ ],+ "valueType": "string",+ "required": false,+ "default": "none",+ "desc": "The camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera.",+ "examples": [+ "none"+ ]+ },+ "camera_lora_scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera."+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "news broadcast, 3d animation, computer graphics, pc game, console game, video game, cartoon, childish, watermark, logo, text, on screen text, subtitles, titles, signature, slowmo, static",+ "desc": "The negative prompt to generate the video from."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed for the random number generator."+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable prompt expansion."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable the safety checker."+ },+ "video_output_type": {+ "type": "enum",+ "values": [+ "X264 (.mp4)",+ "VP9 (.webm)",+ "PRORES4444 (.mov)",+ "GIF (.gif)"+ ],+ "valueType": "string",+ "required": false,+ "default": "X264 (.mp4)",+ "desc": "The output type of the generated video."+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the generated video."+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the generated video."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "weight_name": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "Name of the LoRA weight. Only used if `path` is a HuggingFace repository, and is only required when the repository contains multiple LoRA weights."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Scale factor for LoRA application (0.0 to 4.0)."+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": true,+ "desc": "The LoRAs to use for the generation."+ },+ "distill_lora_first_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.2,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the first pass. Set to 0 to disable."+ },+ "distill_lora_second_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.5,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the second and subsequent passes."+ },+ "video_strength": {+ "type": "number",+ "required": false,+ "default": 0.01,+ "minimum": 0,+ "maximum": 1,+ "desc": "Video conditioning strength. Lower values represent more freedom given to the model to change the video content."+ },+ "audio_strength": {+ "type": "number",+ "required": false,+ "default": 0.01,+ "minimum": 0,+ "maximum": 1,+ "desc": "Audio conditioning strength. Lower values represent more freedom given to the model to change the audio content."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "video_size",+ "seed": "seed",+ "generateAudio": "generate_audio",+ "numFrames": "num_frames",+ "fps": "fps",+ "loras": "loras",+ "video": "video_url"},- "pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ "output": "video.url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -1093,7 +3800,424 @@"acceleration": "string default=\"regular\" enum=[\"none\", \"regular\", \"high\", \"full\"]","num_frames": "integer default=121 minimum=9 maximum=481"},- "pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ "pathAccepts": "URL, HuggingFace repo ID (owner/repo) to lora weights.",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate the video from.",+ "examples": [+ "Continue the scene naturally, maintaining the same style and motion."+ ]+ },+ "video_url": {+ "type": "string",+ "required": true,+ "desc": "The URL of the video to extend.",+ "examples": [+ "https://v3b.fal.media/files/b/0a8824b1/sdm0KfmenrlywesfzY1Y1_if6euPp1.mp4"+ ]+ },+ "end_image_url": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "The URL of the image to use as the end of the extended video."+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 121,+ "minimum": 9,+ "maximum": 481,+ "desc": "The number of frames to generate."+ },+ "video_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "auto",+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "auto",+ "desc": "The size of the generated video."+ },+ "generate_audio": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to generate audio for the video."+ },+ "use_multiscale": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to use multi-scale generation. If True, the model will generate the video at a smaller scale first, then use the smaller video to guide the generation of a video at or above your requested size. This results in better coherence and details."+ },+ "match_input_fps": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "When true, match the output FPS to the input video's FPS instead of using the default target FPS."+ },+ "fps": {+ "type": "number",+ "required": false,+ "default": 24,+ "minimum": 1,+ "maximum": 60,+ "desc": "The frames per second of the generated video."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 40,+ "minimum": 8,+ "maximum": 50,+ "desc": "The number of inference steps to use."+ },+ "video_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the video. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "video_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the video. Controls the ratio between video and audio modalities."+ },+ "audio_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 7,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the audio. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "audio_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the audio. Controls the ratio between video and audio modalities."+ },+ "gradient_estimation_gamma": {+ "type": "number",+ "required": false,+ "default": 2,+ "minimum": 0,+ "maximum": 10,+ "desc": "The gamma of gradient estimation during denoising. Set to 0 to disable."+ },+ "use_restart_sampling": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to use restart sampling. This will inject a small amount of noise during each denoising step, which can help improve the quality of the generated video."+ },+ "scheduler": {+ "type": "enum",+ "values": [+ "ltx2",+ "linear_quadratic",+ "beta"+ ],+ "valueType": "string",+ "required": false,+ "default": "ltx2",+ "desc": "The scheduler to use.",+ "examples": [+ "ltx2"+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high",+ "full"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use.",+ "examples": [+ "regular"+ ]+ },+ "camera_lora": {+ "type": "enum",+ "values": [+ "dolly_in",+ "dolly_out",+ "dolly_left",+ "dolly_right",+ "jib_up",+ "jib_down",+ "static",+ "none"+ ],+ "valueType": "string",+ "required": false,+ "default": "none",+ "desc": "The camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera.",+ "examples": [+ "none"+ ]+ },+ "camera_lora_scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera."+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "news broadcast, 3d animation, computer graphics, pc game, console game, video game, cartoon, childish, watermark, logo, text, on screen text, subtitles, titles, signature, slowmo, static",+ "desc": "The negative prompt to generate the video from."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed for the random number generator."+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable prompt expansion."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable the safety checker."+ },+ "video_output_type": {+ "type": "enum",+ "values": [+ "X264 (.mp4)",+ "VP9 (.webm)",+ "PRORES4444 (.mov)",+ "GIF (.gif)"+ ],+ "valueType": "string",+ "required": false,+ "default": "X264 (.mp4)",+ "desc": "The output type of the generated video."+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the generated video."+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the generated video."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "loras": {+ "type": "array",+ "items": "object",+ "itemSchema": {+ "weight_name": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "Name of the LoRA weight. Only used if `path` is a HuggingFace repository, and is only required when the repository contains multiple LoRA weights."+ },+ "scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 4,+ "desc": "Scale factor for LoRA application (0.0 to 4.0)."+ },+ "path": {+ "type": "string",+ "required": false,+ "desc": "URL, HuggingFace repo ID (owner/repo) to lora weights."+ }+ },+ "itemRequired": [+ "path"+ ],+ "required": true,+ "desc": "The LoRAs to use for the generation."+ },+ "distill_lora_first_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.2,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the first pass. Set to 0 to disable."+ },+ "distill_lora_second_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.5,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the second and subsequent passes."+ },+ "extend_direction": {+ "type": "enum",+ "values": [+ "forward",+ "backward"+ ],+ "valueType": "string",+ "required": false,+ "default": "forward",+ "desc": "Direction to extend the video. 'forward' extends from the end of the video, 'backward' extends from the beginning."+ },+ "num_context_frames": {+ "type": "integer",+ "required": false,+ "default": 25,+ "minimum": 0,+ "maximum": 121,+ "desc": "The number of frames to use as context for the extension."+ },+ "video_strength": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "Video conditioning strength. Lower values represent more freedom given to the model to change the video content."+ },+ "audio_strength": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "Audio conditioning strength. Lower values represent more freedom given to the model to change the audio content."+ },+ "end_image_strength": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The strength of the end image to use for the video generation."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "video_size",+ "seed": "seed",+ "generateAudio": "generate_audio",+ "numFrames": "num_frames",+ "fps": "fps",+ "loras": "loras",+ "video": "video_url",+ "endImage": "end_image_url"+ },+ "output": "video.url",+ "inputsChecked": "2026-10-24"},{"provider": "fal",@@ -1279,7 +4403,94 @@"version": "29c866f1269ef45b736fbcdff00d6da2a555ecf5f4e575c93ab38c2a2f2693a1","schemaUrl": "https://replicate.com/prunaai/z-image-turbo-lora/api/schema","pageUrl": "https://replicate.com/prunaai/z-image-turbo-lora",- "checked": "2026-10-23"+ "checked": "2026-10-23",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "Text prompt for image generation"+ },+ "height": {+ "type": "integer",+ "required": false,+ "default": 1024,+ "minimum": 64,+ "maximum": 1440,+ "desc": "Height of the generated image"+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 1024,+ "minimum": 64,+ "maximum": 1440,+ "desc": "Width of the generated image"+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 8,+ "minimum": 1,+ "maximum": 50,+ "desc": "Number of inference steps. This actually results in (num_inference_steps - 1) DiT forwards"+ },+ "guidance_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "Guidance scale. Should be 0 for Turbo models"+ },+ "seed": {+ "type": "integer",+ "required": false,+ "nullable": true,+ "desc": "Random seed. Set for reproducible generation"+ },+ "lora_weights": {+ "type": "array",+ "items": "string",+ "required": false,+ "nullable": true,+ "desc": "LoRA weights as an array of URLs. Supports .safetensors URLs, tar files, and zip files (e.g., ['https://example.com/lora1.safetensors', 'https://example.com/lora2.safetensors'])"+ },+ "lora_scales": {+ "type": "array",+ "items": "number",+ "required": false,+ "nullable": true,+ "desc": "Scales for each LoRA as an array of floats. Must match the number of lora_weights. Defaults to 1.0 for each if not provided."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "png",+ "jpg",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "jpg",+ "desc": "Format of the output images"+ },+ "output_quality": {+ "type": "integer",+ "required": false,+ "default": 80,+ "minimum": 0,+ "maximum": 100,+ "desc": "Quality when saving the output images, from 0 to 100. 100 is best quality, 0 is lowest quality. Not relevant for .png outputs"+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "width": "width",+ "height": "height",+ "seed": "seed"+ },+ "output": "output[]",+ "inputsChecked": "2026-10-24"},{"provider": "replicate",@@ -14014,5 +17225,957 @@"verifyOnFirstLiveRun": []}]- }+ },+ "hostedBaseEndpoints": [+ {+ "provider": "fal",+ "endpoint": "fal-ai/ltx-2.3-22b/image-to-video",+ "operation": "i2v",+ "status": "active",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt used for the generation.",+ "examples": [+ "A woman stands still amid a busy neon-lit street at night. The camera slowly dollies in toward her face as people blur past, their motion emphasizing her calm presence. City lights flicker and reflections shift across her denim jacket."+ ]+ },+ "image_url": {+ "type": "string",+ "required": true,+ "desc": "The URL of the image to generate the video from.",+ "examples": [+ "https://storage.googleapis.com/falserverless/example_inputs/ltxv-2-i2v-input.jpg"+ ]+ },+ "end_image_url": {+ "nullable": true,+ "type": "string",+ "required": false,+ "desc": "The URL of the image to use as the end of the video."+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 121,+ "minimum": 9,+ "maximum": 481,+ "desc": "The number of frames to generate."+ },+ "video_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "auto",+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "auto",+ "desc": "The size of the generated video."+ },+ "generate_audio": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to generate audio for the video."+ },+ "use_multiscale": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to use multi-scale generation. If True, the model will generate the video at a smaller scale first, then use the smaller video to guide the generation of a video at or above your requested size. This results in better coherence and details."+ },+ "fps": {+ "type": "number",+ "required": false,+ "default": 24,+ "minimum": 1,+ "maximum": 60,+ "desc": "The frames per second of the generated video."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 40,+ "minimum": 8,+ "maximum": 50,+ "desc": "The number of inference steps to use."+ },+ "video_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the video. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "video_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the video. Controls the ratio between video and audio modalities."+ },+ "audio_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 7,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the audio. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "audio_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the audio. Controls the ratio between video and audio modalities."+ },+ "gradient_estimation_gamma": {+ "type": "number",+ "required": false,+ "default": 2,+ "minimum": 0,+ "maximum": 10,+ "desc": "The gamma of gradient estimation during denoising. Set to 0 to disable."+ },+ "use_restart_sampling": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to use restart sampling. This will inject a small amount of noise during each denoising step, which can help improve the quality of the generated video."+ },+ "scheduler": {+ "type": "enum",+ "values": [+ "ltx2",+ "linear_quadratic",+ "beta"+ ],+ "valueType": "string",+ "required": false,+ "default": "ltx2",+ "desc": "The scheduler to use.",+ "examples": [+ "ltx2"+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high",+ "full"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use.",+ "examples": [+ "regular"+ ]+ },+ "camera_lora": {+ "type": "enum",+ "values": [+ "dolly_in",+ "dolly_out",+ "dolly_left",+ "dolly_right",+ "jib_up",+ "jib_down",+ "static",+ "none"+ ],+ "valueType": "string",+ "required": false,+ "default": "none",+ "desc": "The camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera.",+ "examples": [+ "none"+ ]+ },+ "camera_lora_scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera."+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "news broadcast, 3d animation, computer graphics, pc game, console game, video game, cartoon, childish, watermark, logo, text, on screen text, subtitles, titles, signature, slowmo, static",+ "desc": "The negative prompt to generate the video from."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed for the random number generator."+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable prompt expansion."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable the safety checker."+ },+ "video_output_type": {+ "type": "enum",+ "values": [+ "X264 (.mp4)",+ "VP9 (.webm)",+ "PRORES4444 (.mov)",+ "GIF (.gif)"+ ],+ "valueType": "string",+ "required": false,+ "default": "X264 (.mp4)",+ "desc": "The output type of the generated video."+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the generated video."+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the generated video."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "distill_lora_first_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.2,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the first pass. Set to 0 to disable."+ },+ "distill_lora_second_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.5,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the second and subsequent passes."+ },+ "interpolation_direction": {+ "type": "enum",+ "values": [+ "forward",+ "backward"+ ],+ "valueType": "string",+ "required": false,+ "default": "forward",+ "desc": "The direction to interpolate the image sequence in. 'Forward' goes from the start image to the end image, 'Backward' goes from the end image to the start image."+ },+ "image_strength": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The strength of the image to use for the video generation."+ },+ "end_image_strength": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The strength of the end image to use for the video generation."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "video_size",+ "seed": "seed",+ "generateAudio": "generate_audio",+ "numFrames": "num_frames",+ "fps": "fps",+ "image": "image_url",+ "endImage": "end_image_url"+ },+ "output": "video.url",+ "price": "Your request will cost $0.001605 per megapixel of generated video data (width × height × frames), rounded up. For example, if you generate a video that is 121 frames long at 1280 × 720, your total generated video is ≈112 MP, and your request will cost $0.179.",+ "verified": true,+ "schemaUrl": "https://fal.ai/api/openapi/queue/openapi.json?endpoint_id=fal-ai/ltx-2.3-22b/image-to-video",+ "checked": "2026-10-24"+ },+ {+ "provider": "fal",+ "endpoint": "fal-ai/ltx-2.3-22b/text-to-video",+ "operation": "t2v",+ "status": "active",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate the video from.",+ "examples": [+ "A cowboy walking through a dusty town at high noon, camera following from behind, cinematic depth, realistic lighting, western mood, 4K film grain."+ ]+ },+ "num_frames": {+ "type": "integer",+ "required": false,+ "default": 121,+ "minimum": 9,+ "maximum": 481,+ "desc": "The number of frames to generate."+ },+ "video_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ },+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "landscape_16_9",+ "desc": "The size of the generated video."+ },+ "generate_audio": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to generate audio for the video."+ },+ "use_multiscale": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to use multi-scale generation. If True, the model will generate the video at a smaller scale first, then use the smaller video to guide the generation of a video at or above your requested size. This results in better coherence and details."+ },+ "fps": {+ "type": "number",+ "required": false,+ "default": 24,+ "minimum": 1,+ "maximum": 60,+ "desc": "The frames per second of the generated video."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 40,+ "minimum": 8,+ "maximum": 50,+ "desc": "The number of inference steps to use."+ },+ "video_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the video. Higher values result in more consistent and focused video content."+ },+ "video_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the video. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "video_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the video. Controls the ratio between video and audio modalities."+ },+ "audio_cfg_scale": {+ "type": "number",+ "required": false,+ "default": 7,+ "minimum": 1,+ "maximum": 20,+ "desc": "The Classifier-Free Guidance (CFG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_stg_scale": {+ "type": "number",+ "required": false,+ "default": 0,+ "minimum": 0,+ "maximum": 20,+ "desc": "The Spatiotemporal Guidance (STG) scale for the audio. Higher values result in more consistent and focused audio content."+ },+ "audio_rescaling_scale": {+ "type": "number",+ "required": false,+ "default": 0.7,+ "minimum": 0,+ "maximum": 1,+ "desc": "The rescaling scale for the audio. Controls the ratio between classifier-free guidance and spatiotemporal guidance."+ },+ "audio_modality_scale": {+ "type": "number",+ "required": false,+ "default": 3,+ "minimum": 0,+ "maximum": 10,+ "desc": "The modality scale for the audio. Controls the ratio between video and audio modalities."+ },+ "gradient_estimation_gamma": {+ "type": "number",+ "required": false,+ "default": 2,+ "minimum": 0,+ "maximum": 10,+ "desc": "The gamma of gradient estimation during denoising. Set to 0 to disable."+ },+ "use_restart_sampling": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "Whether to use restart sampling. This will inject a small amount of noise during each denoising step, which can help improve the quality of the generated video."+ },+ "scheduler": {+ "type": "enum",+ "values": [+ "ltx2",+ "linear_quadratic",+ "beta"+ ],+ "valueType": "string",+ "required": false,+ "default": "ltx2",+ "desc": "The scheduler to use.",+ "examples": [+ "ltx2"+ ]+ },+ "acceleration": {+ "type": "enum",+ "values": [+ "none",+ "regular",+ "high",+ "full"+ ],+ "valueType": "string",+ "required": false,+ "default": "regular",+ "desc": "The acceleration level to use.",+ "examples": [+ "regular"+ ]+ },+ "camera_lora": {+ "type": "enum",+ "values": [+ "dolly_in",+ "dolly_out",+ "dolly_left",+ "dolly_right",+ "jib_up",+ "jib_down",+ "static",+ "none"+ ],+ "valueType": "string",+ "required": false,+ "default": "none",+ "desc": "The camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera.",+ "examples": [+ "none"+ ]+ },+ "camera_lora_scale": {+ "type": "number",+ "required": false,+ "default": 1,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the camera LoRA to use. This allows you to control the camera movement of the generated video more accurately than just prompting the model to move the camera."+ },+ "negative_prompt": {+ "type": "string",+ "required": false,+ "default": "news broadcast, 3d animation, computer graphics, pc game, console game, video game, cartoon, childish, watermark, logo, text, on screen text, subtitles, titles, signature, slowmo, static",+ "desc": "The negative prompt to generate the video from."+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed for the random number generator."+ },+ "enable_prompt_expansion": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable prompt expansion."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "Whether to enable the safety checker."+ },+ "video_output_type": {+ "type": "enum",+ "values": [+ "X264 (.mp4)",+ "VP9 (.webm)",+ "PRORES4444 (.mov)",+ "GIF (.gif)"+ ],+ "valueType": "string",+ "required": false,+ "default": "X264 (.mp4)",+ "desc": "The output type of the generated video."+ },+ "video_quality": {+ "type": "enum",+ "values": [+ "low",+ "medium",+ "high",+ "maximum"+ ],+ "valueType": "string",+ "required": false,+ "default": "high",+ "desc": "The quality of the generated video."+ },+ "video_write_mode": {+ "type": "enum",+ "values": [+ "fast",+ "balanced",+ "small"+ ],+ "valueType": "string",+ "required": false,+ "default": "balanced",+ "desc": "The write mode of the generated video."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI and the output data won't be available in the request history."+ },+ "distill_lora_first_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.2,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the first pass. Set to 0 to disable."+ },+ "distill_lora_second_pass_scale": {+ "type": "number",+ "required": false,+ "default": 0.5,+ "minimum": 0,+ "maximum": 1,+ "desc": "The scale of the distill LoRA to use for the second and subsequent passes."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "negativePrompt": "negative_prompt",+ "aspectRatio": "video_size",+ "seed": "seed",+ "generateAudio": "generate_audio",+ "numFrames": "num_frames",+ "fps": "fps"+ },+ "output": "video.url",+ "price": "Your request will cost $0.001605 per megapixel of generated video data (width × height × frames), rounded up. For example, if you generate a video that is 121 frames long at 1280 × 720, your total generated video is ≈112 MP, and your request will cost $0.179.",+ "verified": true,+ "schemaUrl": "https://fal.ai/api/openapi/queue/openapi.json?endpoint_id=fal-ai/ltx-2.3-22b/text-to-video",+ "checked": "2026-10-24"+ },+ {+ "provider": "fal",+ "endpoint": "fal-ai/flux-2/klein/4b",+ "operation": "t2i",+ "status": "active",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to generate an image from.",+ "examples": [+ "Cheetah in pre-sprint crouch, muscles tensed, gazelle visible in distance, African savanna golden grass, dust particles in air, National Geographic wildlife photography"+ ]+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed to use for the generation. If not provided, a random seed will be used."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 4,+ "minimum": 4,+ "maximum": 8,+ "desc": "The number of inference steps to perform."+ },+ "image_size": {+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ },+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "default": "landscape_4_3",+ "desc": "The size of the image to generate."+ },+ "num_images": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 1,+ "maximum": 4,+ "desc": "The number of images to generate."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI. Output is not stored when this is True."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked, and images flagged as unsafe are returned as black images."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "jpeg",+ "png",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "png",+ "desc": "The format of the generated image."+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "numOutputs": "num_images"+ },+ "output": "images[].url",+ "price": "$0.005 per megapixels",+ "verified": true,+ "schemaUrl": "https://fal.ai/api/openapi/queue/openapi.json?endpoint_id=fal-ai/flux-2/klein/4b",+ "checked": "2026-10-24"+ },+ {+ "provider": "fal",+ "endpoint": "fal-ai/flux-2/klein/4b/edit",+ "operation": "edit",+ "status": "active",+ "inputs": {+ "prompt": {+ "type": "string",+ "required": true,+ "desc": "The prompt to edit the image.",+ "examples": [+ "Turn this into a realistic image"+ ]+ },+ "seed": {+ "nullable": true,+ "type": "integer",+ "required": false,+ "desc": "The seed to use for the generation. If not provided, a random seed will be used."+ },+ "num_inference_steps": {+ "type": "integer",+ "required": false,+ "default": 4,+ "minimum": 4,+ "maximum": 8,+ "desc": "The number of inference steps to perform."+ },+ "image_size": {+ "nullable": true,+ "type": "union",+ "variants": [+ {+ "type": "object",+ "fields": {+ "width": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The width of the generated image."+ },+ "height": {+ "type": "integer",+ "required": false,+ "default": 512,+ "maximum": 14142,+ "minimumExclusive": 0,+ "desc": "The height of the generated image."+ }+ },+ "required": false+ },+ {+ "type": "enum",+ "values": [+ "square_hd",+ "square",+ "portrait_4_3",+ "portrait_16_9",+ "landscape_4_3",+ "landscape_16_9"+ ],+ "valueType": "string",+ "required": false+ }+ ],+ "desc": "The size of the generated image. If not provided, uses the input image size.",+ "examples": [+ {+ "width": 2016,+ "height": 1152+ }+ ]+ },+ "num_images": {+ "type": "integer",+ "required": false,+ "default": 1,+ "minimum": 1,+ "maximum": 4,+ "desc": "The number of images to generate."+ },+ "sync_mode": {+ "type": "boolean",+ "required": false,+ "default": false,+ "desc": "If `True`, the media will be returned as a data URI. Output is not stored when this is True."+ },+ "enable_safety_checker": {+ "type": "boolean",+ "required": false,+ "default": true,+ "desc": "If set to true, the safety checker will be enabled. Disabling it requires account authorization; unauthorized requests are always checked, and images flagged as unsafe are returned as black images."+ },+ "output_format": {+ "type": "enum",+ "values": [+ "jpeg",+ "png",+ "webp"+ ],+ "valueType": "string",+ "required": false,+ "default": "png",+ "desc": "The format of the generated image."+ },+ "image_urls": {+ "type": "array",+ "items": "string",+ "required": true,+ "desc": "The URLs of the images for editing. A maximum of 4 images are allowed.",+ "examples": [+ [+ "https://v3b.fal.media/files/b/0a8a69d5/kkXxFfj1QeVtw35kxy5Py_1a7e3511-bd2c-46be-923a-8e6be2496f12.png"+ ]+ ]+ }+ },+ "keyFields": {+ "prompt": "prompt",+ "aspectRatio": "image_size",+ "seed": "seed",+ "numOutputs": "num_images",+ "images": "image_urls"+ },+ "output": "images[].url",+ "price": "$0.01 per megapixels",+ "verified": true,+ "schemaUrl": "https://fal.ai/api/openapi/queue/openapi.json?endpoint_id=fal-ai/flux-2/klein/4b/edit",+ "checked": "2026-10-24"+ }+ ]}diff --git a/docs/research/fuobe-originals-recipes-5.md b/docs/research/fuobe-originals-recipes-5.mdindex 30942eae..5cded113 100644--- a/docs/research/fuobe-originals-recipes-5.md+++ b/docs/research/fuobe-originals-recipes-5.md@@ -104,6 +104,7 @@ Extra fields that matter:- **Wan 2.2 on fal** (`fal-ai/wan/v2.2-a14b/*/lora`): each LoRA item is `{path, scale 0–4, transformer: high|low|both (default high), weight_name}`. A high/low-noise pair is two items with the same scale and different `transformer`. 17–161 frames (default 81), 480p/580p/720p (default 720p), 2–40 steps (default 27), shift 1–10 (default 5), `guidance_scale` 3.5 and `guidance_scale_2` 4 by default. **Frame rate trap (critic re-check, fal OpenAPI 2026-10-23):** `frames_per_second` defaults to 16, but `interpolator_model` defaults to `film` with `num_interpolated_frames` 1 and `adjust_fps_for_interpolation` true, so a default request returns 32 fps with doubled frames. For DoP parity (49 or 81 frames at 16 fps) send `interpolator_model: "none"` (or `num_interpolated_frames: 0`). Higgsfield's DoP preset pages use 20 steps and guide scale 6.- **LTX-2.3 on fal** (`fal-ai/ltx-2.3-22b/*/lora`): `loras` is **required** (send at least one item), plus `camera_lora` = `dolly_in | dolly_out | dolly_left | dolly_right | jib_up | jib_down | static | none` with `camera_lora_scale` 0–1, `distill_lora_first/second_pass_scale` (defaults 0.2 / 0.5), 9–481 frames (default 121), `fps` (default 24), 8–50 steps (default 40). Two defaults must be overridden for Originals: `enable_prompt_expansion` defaults to **true** (it would rewrite Fuobe's compiled Director prompt) and `generate_audio` defaults to **true** (set it from the user's audio toggle). Price: $0.001805 per megapixel of generated video (121 frames at 1280×720 ≈ 111.5 MP ≈ $0.20); distilled $0.001405. The *quality* family (`fal-ai/ltx-2.3-quality/*/lora`) caps LoRAs at 3, scale 0–2, adds `transformer` high/low/both, $0.0027075/MP, and only accepts direct `.safetensors` URLs up to 3 GB.- **Replicate Wan 2.2 fast** takes exactly one LoRA per expert (`lora_weights_transformer` = high, `lora_weights_transformer_2` = low), so a motion and an effect cannot be stacked there.+- *Added 2026-10-24 (o/lora-plumbing):* the full input schemas of the endpoints Fuobe's catalog routes LoRAs to are now in the JSON (`hostedLoraEndpoints[].inputs` and `keyFields`, plus `hostedBaseEndpoints` for the plain LTX-2.3 22B and FLUX.2 [klein] 4B endpoints), read with `scripts/fetch-hosted-schemas.py` from fal's OpenAPI files and Replicate's schema page. Findings: the plain LTX-2.3 22B endpoints cost $0.001605 per megapixel of video (the `/lora` ones $0.001805); FLUX.2 [klein] 4B costs $0.005/MP plain and $0.01/MP with LoRAs and has no `negative_prompt`; Replicate's `prunaai/z-image-turbo-lora` takes `width` / `height` (no `aspect_ratio`, no `num_outputs`) and runs only by version (`usesVersionlessApi: false`).### 3.2 What has no hosted LoRA routediff --git a/scripts/fetch-hosted-schemas.py b/scripts/fetch-hosted-schemas.pynew file mode 100644index 00000000..9f55b931--- /dev/null+++ b/scripts/fetch-hosted-schemas.py@@ -0,0 +1,189 @@+#!/usr/bin/env python3+"""+Research helper (needs the network; not part of gen:catalog): read the input schemas of the hosted+open-weight endpoints the catalog routes LoRAs to, and store them in+docs/research/fuobe-originals-recipes-5.json in the same shape as paid-model-apis*.json `inputs`:++- hostedLoraEndpoints[<id>].inputs / keyFields / output for the LoRA endpoints in LORA (fal OpenAPI,+ or the schema embedded in a Replicate model page, pinned to the research's version);+- hostedBaseEndpoints[] for the plain endpoints of the same models that no earlier research file+ has (LTX-2.3 22B, FLUX.2 [klein] 4B), with their price from fal's llms.txt.++keyFields (which input is the prompt, the image, the clip…) are this script's curation, as in the+earlier research files. scripts/gen-cloud-models.py reads both lists.++Run: python3 scripts/fetch-hosted-schemas.py+"""+import datetime+import json+import re+import sys+import urllib.request+from pathlib import Path++ROOT = Path(__file__).resolve().parent.parent+FILE = ROOT / "docs/research/fuobe-originals-recipes-5.json"+TODAY = datetime.date.today().isoformat()++# Canonical slots → field names, per endpoint (Fuobe's names: see FieldMap in src/lib/catalog/types.ts).+T2I = {"prompt": "prompt", "negativePrompt": "negative_prompt", "aspectRatio": "image_size", "seed": "seed", "numOutputs": "num_images", "loras": "loras"}+EDIT = {**T2I, "images": "image_urls"}+LTX = {"prompt": "prompt", "negativePrompt": "negative_prompt", "aspectRatio": "video_size", "seed": "seed", "generateAudio": "generate_audio", "numFrames": "num_frames", "fps": "fps", "loras": "loras"}+KLEIN = {k: v for k, v in T2I.items() if k != "negativePrompt"}+LORA = {+ "fal-ai/qwen-image-edit-2511/lora": EDIT,+ "fal-ai/flux-2/klein/4b/lora": KLEIN,+ "fal-ai/flux-2/klein/4b/edit/lora": {**KLEIN, "images": "image_urls"},+ "fal-ai/ltx-2.3-22b/image-to-video/lora": {**LTX, "image": "image_url", "endImage": "end_image_url"},+ "fal-ai/ltx-2.3-22b/text-to-video/lora": LTX,+ "fal-ai/ltx-2.3-22b/video-to-video/lora": {**LTX, "video": "video_url"},+ "fal-ai/ltx-2.3-22b/extend-video/lora": {**LTX, "video": "video_url", "endImage": "end_image_url"},+ "fal-ai/wan/v2.2-a14b/image-to-video/lora": {"prompt": "prompt", "image": "image_url", "endImage": "end_image_url", "negativePrompt": "negative_prompt",+ "aspectRatio": "aspect_ratio", "resolution": "resolution", "numFrames": "num_frames", "seed": "seed", "loras": "loras"},+ "fal-ai/wan/v2.2-a14b/text-to-video/lora": {"prompt": "prompt", "negativePrompt": "negative_prompt", "aspectRatio": "aspect_ratio", "resolution": "resolution",+ "numFrames": "num_frames", "seed": "seed", "loras": "loras"},+ "fal-ai/wan/v2.2-a14b/text-to-image/lora": {"prompt": "prompt", "negativePrompt": "negative_prompt", "aspectRatio": "image_size", "seed": "seed", "loras": "loras"},+ "fal-ai/z-image/turbo/lora": {k: v for k, v in T2I.items() if k != "negativePrompt"},+ "fal-ai/qwen-image-2512/lora": T2I,+ "prunaai/z-image-turbo-lora": {"prompt": "prompt", "width": "width", "height": "height", "seed": "seed"},+}+BASE = {+ "fal-ai/ltx-2.3-22b/image-to-video": ("i2v", {**{k: v for k, v in LTX.items() if k != "loras"}, "image": "image_url", "endImage": "end_image_url"}),+ "fal-ai/ltx-2.3-22b/text-to-video": ("t2v", {k: v for k, v in LTX.items() if k != "loras"}),+ "fal-ai/flux-2/klein/4b": ("t2i", {k: v for k, v in KLEIN.items() if k != "loras"}),+ "fal-ai/flux-2/klein/4b/edit": ("edit", {**{k: v for k, v in KLEIN.items() if k != "loras"}, "images": "image_urls"}),+}+++def get(url):+ req = urllib.request.Request(url, headers={"User-Agent": "fuobe-research/1.0"})+ with urllib.request.urlopen(req, timeout=60) as r:+ return r.read().decode("utf-8")+++def resolve(schema, root):+ while isinstance(schema, dict) and "$ref" in schema:+ name = schema["$ref"].split("/")[-1]+ schema = root["components"]["schemas"][name]+ return schema+++def spec(p, root, required=False):+ """One OpenAPI property in the research files' shape (type, values, default, minimum…, desc)."""+ p = resolve(p, root)+ out = {}+ variants = p.get("anyOf") or p.get("oneOf")+ if variants:+ real = [resolve(v, root) for v in variants if resolve(v, root).get("type") != "null"]+ if len(real) < len(variants):+ out["nullable"] = True+ if len(real) == 1:+ out.update(spec({**real[0], **{k: v for k, v in p.items() if k not in ("anyOf", "oneOf")}}, root))+ else:+ out["type"] = "union"+ out["variants"] = [spec(v, root) for v in real]+ elif "enum" in p:+ out.update({"type": "enum", "values": p["enum"], "valueType": p.get("type", "string")})+ elif p.get("type") == "array":+ items = resolve(p.get("items") or {}, root)+ out["type"] = "array"+ if items.get("type") == "object" or "properties" in items:+ out["items"] = "object"+ out["itemSchema"] = {k: spec(v, root) for k, v in (items.get("properties") or {}).items()}+ if items.get("required"):+ out["itemRequired"] = items["required"]+ else:+ out["items"] = items.get("type", "string")+ for k in ("minItems", "maxItems"):+ if k in p:+ out[k] = p[k]+ elif p.get("type") == "object" or "properties" in p:+ out["type"] = "object"+ out["fields"] = {k: spec(v, root) for k, v in (p.get("properties") or {}).items()}+ else:+ out["type"] = p.get("type", "string") + (f"({p['format']})" if p.get("format") == "uri" else "")+ if required:+ out["required"] = True+ elif "type" in out and out["type"] not in ("union",) and "required" not in out:+ out["required"] = False+ for src, dst in (("default", "default"), ("minimum", "minimum"), ("maximum", "maximum"), ("exclusiveMinimum", "minimumExclusive"), ("exclusiveMaximum", "maximumExclusive")):+ if src in p:+ out[dst] = p[src]+ if p.get("nullable"):+ out["nullable"] = True+ if p.get("description"):+ out["desc"] = p["description"]+ if p.get("examples"):+ out["examples"] = p["examples"][:1]+ return out+++def inputs_of(root, schema):+ schema = resolve(schema, root)+ req = set(schema.get("required") or [])+ order = schema.get("x-fal-order-properties") or sorted(schema.get("properties") or {}, key=lambda k: (schema["properties"][k].get("x-order", 999), k))+ props = schema.get("properties") or {}+ return {k: spec(props[k], root, k in req) for k in order if k in props}+++def fal(endpoint):+ root = json.loads(get(f"https://fal.ai/api/openapi/queue/openapi.json?endpoint_id={endpoint}"))+ post = root["paths"][f"/{endpoint}"]["post"]+ schema = post["requestBody"]["content"]["application/json"]["schema"]+ return inputs_of(root, schema)+++def replicate(slug, version):+ page = get(f"https://replicate.com/{slug}/api/schema")+ for m in re.finditer(r'<script[^>]*type="application/json"[^>]*>(.*?)</script>', page, re.S):+ try:+ data = json.loads(m.group(1))+ except json.JSONDecodeError:+ continue+ v = data.get("version") if isinstance(data, dict) else None+ if isinstance(v, dict) and v.get("id") == version:+ root = v["_extras"]["dereferenced_openapi_schema"]+ return inputs_of(root, root["components"]["schemas"]["Input"])+ raise SystemExit(f"{slug}: version {version} not found on its schema page")+++def fal_price(endpoint):+ text = get(f"https://fal.ai/models/{endpoint}/llms.txt")+ m = re.search(r"(?im)^.*\$\d[^\n]*$", text)+ return re.sub(r"^(Price:\s*)", "", m.group(0).replace("**", "").strip(" -*")) if m else None+++def main():+ raw = FILE.read_text(encoding="utf-8")+ data = json.loads(raw)+ by_id = {e["id"]: e for e in data["hostedLoraEndpoints"]}+ for ep, kf in LORA.items():+ rec = by_id.get(ep)+ if not rec:+ sys.exit(f"{ep} is not in hostedLoraEndpoints")+ rec["inputs"] = replicate(ep, rec["version"]) if rec["provider"] == "replicate" else fal(ep)+ missing = [f for f in kf.values() if f not in rec["inputs"]]+ if missing:+ sys.exit(f"{ep}: keyFields {missing} are not inputs")+ rec["keyFields"] = kf+ rec["output"] = "images[].url" if rec["op"] in ("t2i", "edit") else "video.url"+ if rec["provider"] == "replicate":+ rec["output"] = "output[]"+ rec["inputsChecked"] = TODAY+ print(f"{ep}: {len(rec['inputs'])} inputs")+ base = []+ for ep, (op, kf) in BASE.items():+ inputs = fal(ep)+ missing = [f for f in kf.values() if f not in inputs]+ if missing:+ sys.exit(f"{ep}: keyFields {missing} are not inputs")+ base.append({"provider": "fal", "endpoint": ep, "operation": op, "status": "active", "inputs": inputs, "keyFields": kf,+ "output": "images[].url" if op in ("t2i", "edit") else "video.url", "price": fal_price(ep), "verified": True,+ "schemaUrl": f"https://fal.ai/api/openapi/queue/openapi.json?endpoint_id={ep}", "checked": TODAY})+ print(f"{ep}: {len(inputs)} inputs")+ data["hostedBaseEndpoints"] = base+ FILE.write_text(json.dumps(data, indent=1, ensure_ascii=False) + "\n", encoding="utf-8")+++if __name__ == "__main__":+ main()diff --git a/scripts/gen-cloud-models.py b/scripts/gen-cloud-models.pyindex 7caa8ea2..4521e355 100644--- a/scripts/gen-cloud-models.py+++ b/scripts/gen-cloud-models.py@@ -38,6 +38,18 @@ for e in RESEARCH_4["endpoints"]:prev = EPS.get((e["provider"], e["endpoint"]))EPS[(e["provider"], e["endpoint"])] = {**e, "keyFields": {**((prev or {}).get("keyFields") or {}), **(e.get("keyFields") or {})}}+# Originals (docs/research/fuobe-originals-recipes-5.json): the hosted open-weight endpoints that take LoRAs+# (hostedLoraEndpoints: the LoRA field's shape, maximum and whether it's required, plus the full inputs where+# scripts/fetch-hosted-schemas.py read them) and the plain endpoints of the same models (hostedBaseEndpoints).+ORIGINALS = json.loads((ROOT / "docs/research/fuobe-originals-recipes-5.json").read_text(encoding="utf-8"))+HOSTED_LORA = {(e["provider"], e["id"]): e for e in ORIGINALS["hostedLoraEndpoints"]}+for e in ORIGINALS["hostedLoraEndpoints"]:+ if e.get("inputs"):+ EPS[(e["provider"], e["id"])] = {"provider": e["provider"], "endpoint": e["id"], "operation": e["op"], "status": e["status"], "verified": True,+ "inputs": e["inputs"], "keyFields": e.get("keyFields") or {}, "output": e.get("output"), "price": e.get("price")}+for e in ORIGINALS.get("hostedBaseEndpoints") or []:+ EPS[(e["provider"], e["endpoint"])] = e+IMG_AR = ["1:1", "4:3", "3:4", "16:9", "9:16", "3:2", "2:3", "21:9", "5:4", "4:5"]IMAGE_SIZE_MAP = {"1:1": "square_hd", "4:3": "landscape_4_3", "3:4": "portrait_4_3", "16:9": "landscape_16_9",@@ -56,7 +68,8 @@ M = []def model(id, name, vendor, family, kind, tagline, routes, badges=None, pricing=None, defaults=None, options=None, fixed=None, hidden=False,- sliders=None, controls=None, api_defaults=None, formats=None, ranged_durations=False, fit_values=False, fps_targets=None, upscale_tiers=None):+ sliders=None, controls=None, api_defaults=None, formats=None, ranged_durations=False, fit_values=False, fps_targets=None, upscale_tiers=None,+ frame_step=None):"""sliders / controls: [(field, label)] read from each route's research inputs (dotted = nested field):numeric fields with minimum/maximum become sliders, enums become composer controls; both travel as params.extra.fixed: fields always sent. api_defaults: fields sent unless the request sets them (FieldMap.defaults).@@ -68,11 +81,14 @@ def model(id, name, vendor, family, kind, tagline, routes, badges=None, pricing=fps_targets: frame rates offered for the API's target_fps (params.targetFps; ModelOptions.fpsTargets).upscale_tiers: resolutions offered to an upscaler that takes a factor ("Original", "1080p", "4K"): FieldMap.upscaleFactorturns the tier into target ÷ the clip's shorter edge, within the factor field's limits.- A route's options dict may also set max_images (FieldMap.maxImages) and note."""+ frame_step: video models whose length is a frame count (Wan 2.2: 4n+1, LTX: 8n+1): FieldMap.numFrames.step.+ A route's options dict may also set max_images (FieldMap.maxImages), note, loraEndpoint (the same model with LoRAs:+ FieldMap.loras comes from its research record) and pin (a Replicate model run by version: the research's version)."""M.append(dict(id=id, name=name, vendor=vendor, family=family, kind=kind, tagline=tagline, routes=routes,badges=badges or [], pricing=pricing, defaults=defaults or {}, options=options or {}, fixed=fixed or {}, hidden=hidden,sliders=sliders or [], controls=controls or [], api_defaults=api_defaults or {}, formats=formats or {},- ranged_durations=ranged_durations, fit_values=fit_values, fps_targets=fps_targets or [], upscale_tiers=upscale_tiers or []))+ ranged_durations=ranged_durations, fit_values=fit_values, fps_targets=fps_targets or [], upscale_tiers=upscale_tiers or [],+ frame_step=frame_step))# ----- Image@@ -151,7 +167,27 @@ model("wan-2-7-image", "Wan 2.7 Image", "Alibaba Wan", "wan", "image",[("t2i", "fal-ai/wan/v2.7/pro/text-to-image"), ("edit", "fal-ai/wan/v2.7/pro/edit")], defaults={"aspectRatio": "16:9"})model("z-image-turbo-cloud", "Z-Image Turbo (hosted)", "Alibaba Tongyi", "z-image", "image","Sub-second photoreal images",- [("t2i", "fal-ai/z-image/turbo", "fal", {"loraEndpoint": "fal-ai/z-image/turbo/lora"})], badges=["fast"], defaults={"aspectRatio": "1:1"})+ [("t2i", "fal-ai/z-image/turbo", "fal", {"loraEndpoint": "fal-ai/z-image/turbo/lora"}),+ # Replicate's LoRA build of the same weights (lora_weights[] + lora_scales[]); one image per run.+ ("t2i", "prunaai/z-image-turbo-lora", "replicate", {"pin": True})], badges=["fast"], defaults={"aspectRatio": "1:1"})+# Originals (O1): open-weight models hosted on fal / Replicate that take LoRA URLs (docs/research/fuobe-originals-recipes-5.md §3).+# Apache-2.0 weights, so the same recipe runs on the user's GPU; a run with LoRAs switches to the /lora endpoint.+model("qwen-image-2512-cloud", "Qwen-Image 2512 (hosted)", "Alibaba Qwen", "qwen-image", "image",+ "Open-weights Qwen-Image: clean lettering and long prompts",+ [("t2i", "fal-ai/qwen-image-2512", "fal", {"loraEndpoint": "fal-ai/qwen-image-2512/lora"})],+ pricing=("megapixel", 0.02, "rounded up to whole megapixels"), defaults={"aspectRatio": "1:1"})+model("qwen-image-edit-2511-cloud", "Qwen-Image-Edit 2511 (hosted)", "Alibaba Qwen", "qwen-image", "image",+ "Open-weights instruction edits with several references",+ [("edit", "fal-ai/qwen-image-edit-2511", "fal", {"loraEndpoint": "fal-ai/qwen-image-edit-2511/lora"}),+ ("edit", "qwen/qwen-image-edit-2511", "replicate", {"keys": {"images": "image"}, "drop": ["image"]})], defaults={"aspectRatio": "1:1"})+model("flux-2-klein-4b-cloud", "FLUX.2 [klein] 4B (hosted)", "Black Forest Labs", "flux", "image",+ "The Apache-2.0 FLUX.2: cheapest drafts and edits",+ [("t2i", "fal-ai/flux-2/klein/4b", "fal", {"loraEndpoint": "fal-ai/flux-2/klein/4b/lora"}),+ ("edit", "fal-ai/flux-2/klein/4b/edit", "fal", {"loraEndpoint": "fal-ai/flux-2/klein/4b/edit/lora"})],+ badges=["fast"], defaults={"aspectRatio": "1:1"})+model("wan-2-2-a14b-image-cloud", "Wan 2.2 A14B Image (hosted)", "Alibaba Wan", "wan", "image",+ "Open-weights Wan 2.2 stills that take Wan LoRAs",+ [("t2i", "fal-ai/wan/v2.2-a14b/text-to-image/lora", "fal")], defaults={"aspectRatio": "16:9"})model("imagen-4", "Imagen 4", "Google", "imagen", "image", "Google's photoreal text-to-image",[("t2i", "google/imagen-4", "replicate")], defaults={"aspectRatio": "1:1"})@@ -349,6 +385,27 @@ model("flux-3-video", "FLUX.3 Video", "Black Forest Labs", "flux", "video", "BFL("flf2v", "blackforestlabs/flux-3/first-last-frame-to-video"), ("v2v", "blackforestlabs/flux-3/edit-video"),("extend", "blackforestlabs/flux-3/extend-video")],badges=["new"], defaults={"aspectRatio": "16:9"})+# Originals (O1): Wan 2.2 A14B and LTX-2.3 22B open weights on fal / Replicate, with camera and effect LoRAs.+# fal's Wan 2.2 interpolates to 32 fps by default (doubled frames): interpolator_model none keeps 16 fps (research §3.1).+WAN22_FAL = {"interpolator_model": "none"}+model("wan-2-2-a14b-cloud", "Wan 2.2 A14B (hosted)", "Alibaba Wan", "wan", "video", "Open-weights Wan 2.2 that takes camera and effect LoRAs",+ [("t2v", "fal-ai/wan/v2.2-a14b/text-to-video", "fal", {"loraEndpoint": "fal-ai/wan/v2.2-a14b/text-to-video/lora", "defaults": WAN22_FAL}),+ ("i2v", "fal-ai/wan/v2.2-a14b/image-to-video", "fal", {"loraEndpoint": "fal-ai/wan/v2.2-a14b/image-to-video/lora", "defaults": WAN22_FAL}),+ # One LoRA per expert (lora_weights_transformer = high noise, _2 = low noise): a Mix runs on fal.+ ("t2v", "wan-video/wan-2.2-t2v-fast", "replicate"), ("i2v", "wan-video/wan-2.2-i2v-fast", "replicate")],+ pricing=("second", 0.08, "720p on fal; 580p $0.06/s, 480p $0.04/s; with LoRAs $0.10/s",+ {"byResolution": {"720p": 0.08, "580p": 0.06, "480p": 0.04}, "withLoras": 0.1}),+ defaults={"aspectRatio": "16:9", "duration": 5, "resolution": "720p"}, frame_step=4)+# LTX-2.3 22B (LTX-2 Community licence: free under US$10M annual revenue). Prompt expansion is on by default and would+# rewrite a compiled Director prompt, so it is off; sound follows the audio toggle.+model("ltx-2-3-22b-cloud", "LTX-2.3 22B (hosted)", "Lightricks", "ltx", "video", "Open-weights LTX-2.3 with sound, camera and motion LoRAs",+ [("t2v", "fal-ai/ltx-2.3-22b/text-to-video", "fal", {"loraEndpoint": "fal-ai/ltx-2.3-22b/text-to-video/lora"}),+ ("i2v", "fal-ai/ltx-2.3-22b/image-to-video", "fal", {"loraEndpoint": "fal-ai/ltx-2.3-22b/image-to-video/lora"}),+ ("extend", "fal-ai/ltx-2.3-22b/extend-video", "fal", {"loraEndpoint": "fal-ai/ltx-2.3-22b/extend-video/lora"}),+ ("v2v", "fal-ai/ltx-2.3-22b/video-to-video", "fal", {"loraEndpoint": "fal-ai/ltx-2.3-22b/video-to-video/lora"})],+ badges=["audio"], api_defaults={"enable_prompt_expansion": False},+ pricing=("second", 0.036, "$0.001605 per megapixel of video: about $0.18 for 5 s at 720p ($0.20 with LoRAs)", {"withLoras": 0.04}),+ defaults={"aspectRatio": "16:9", "duration": 5}, frame_step=8)model("ltx-2-5", "LTX 2.5 Pro", "Lightricks", "ltx", "video", "Fast 4K-capable video with audio",[("t2v", "lightricks/ltx-2.5/text-to-video/pro"), ("i2v", "lightricks/ltx-2.5/image-to-video/pro")],badges=["audio"], defaults={"aspectRatio": "16:9"})@@ -972,6 +1029,10 @@ def map_fields(fmap):for k, v in fmap.items():if k in ("fixed", "defaults"):out += list(v)+ elif k == "loras":+ out += lora_field_names(v)+ elif k == "size":+ out += [v["width"], v["height"]]elif k in ("seedRange", "maskFormat", "ranges", "ignore", "maxImages", "omitEmptyPrompt"):continueelif isinstance(v, str):@@ -983,6 +1044,63 @@ def map_fields(fmap):return [f.split(".")[0] for f in out]+def lora_field_names(f):+ """The payload fields a FieldMap.loras writes."""+ if f["shape"] == "items":+ return [f["key"]]+ if f["shape"] == "arrays":+ return [f["weights"], f["scales"]]+ if f["shape"] == "single":+ return [f["weights"], f["scale"]]+ return [f[x][y] for x in ("high", "low") for y in ("weights", "scale")]+++def scale_range(spec):+ lo, hi = num((spec or {}).get("minimum")), num((spec or {}).get("maximum"))+ return {"min": lo, "max": hi} if lo is not None and hi is not None else None+++def lora_field(provider, ep):+ """FieldMap.loras for an endpoint that takes LoRAs, from its research inputs and its hostedLoraEndpoints record."""+ inputs = (EPS.get((provider, ep)) or {}).get("inputs") or {}+ summary = (HOSTED_LORA.get((provider, ep)) or {}).get("lora") or {}+ if provider == "replicate":+ expert = ("lora_weights_transformer", "lora_scale_transformer", "lora_weights_transformer_2", "lora_scale_transformer_2")+ if set(expert) <= set(inputs):+ f = {"shape": "experts", "high": {"weights": expert[0], "scale": expert[1]}, "low": {"weights": expert[2], "scale": expert[3]}}+ rng = scale_range(inputs[expert[1]])+ elif (inputs.get("lora_weights") or {}).get("type") == "array" and "lora_scales" in inputs:+ f = {"shape": "arrays", "weights": "lora_weights", "scales": "lora_scales"}+ rng = None+ elif "lora_weights" in inputs and "lora_scale" in inputs:+ f = {"shape": "single", "weights": "lora_weights", "scale": "lora_scale"}+ rng = scale_range(inputs["lora_scale"])+ else:+ return None+ if rng:+ f["range"] = rng+ return f+ key = summary.get("field") or "loras"+ spec = inputs.get(key)+ if not spec or spec.get("type") != "array":+ return None+ item = spec.get("itemSchema") or {}+ f = {"shape": "items", "key": key}+ mx = summary.get("maxCount") if isinstance(summary.get("maxCount"), int) else num((re.search(r"maximum (\d+)", spec.get("desc") or "") or [None, None])[1])+ if mx:+ f["max"] = mx+ if spec.get("required") or summary.get("required"):+ f["required"] = True+ rng = scale_range(item.get("scale"))+ if rng:+ f["range"] = rng+ if item.get("transformer"):+ f["transformer"] = item["transformer"].get("default") or "both"+ if "weight_name" in item:+ f["weightName"] = True+ return f++def mask_format(ep):"""Ideogram paints black = change; OpenAI's GPT Image uses transparent = change; others white."""return "black" if "ideogram" in ep else "alpha" if ("gpt-image" in ep or ep.startswith("openai/")) else None@@ -1124,6 +1242,12 @@ def part4_ranges(op, inputs, fmap):def build_route(op, ep, provider, m, opts, ropts=None):ropts = ropts or {}+ # A Replicate model run by version ("owner/name:<version>") is researched under its name.+ if ropts.get("pin"):+ version = (HOSTED_LORA.get((provider, ep)) or {}).get("version")+ if not version:+ warn(f"{m['id']}: {ep} has no researched version to pin")+ return Nonee = EPS.get((provider, ep))if not e:warn(f"{m['id']}: endpoint {provider}:{ep} not in research")@@ -1270,6 +1394,26 @@ def build_route(op, ep, provider, m, opts, ropts=None):fmap["styleId"] = kf["styleId"]if "numLayers" in kf:fmap["numLayers"] = kf["numLayers"]+ # Video models whose length is a frame count (Wan 2.2 num_frames at 16 fps, LTX-2.3 at 24): the duration picked+ # becomes frames (FieldMap.numFrames, 4n+1 / 8n+1 by model), and the durations offered are the ones that fit.+ nf = kf.get("numFrames") or (kf.get("duration") if kf.get("duration") in ("num_frames", "frames") else None)+ if nf and op in ("t2v", "i2v", "flf2v", "extend", "v2v") and (inputs.get(nf) or {}).get("type") == "integer":+ kf.pop("duration", None)+ kf.pop("numFrames", None)+ spec = inputs.get(nf) or {}+ fps_key = kf.get("fps") or next((k for k in ("fps", "frames_per_second") if k in inputs), None)+ fps = num((inputs.get(fps_key) or {}).get("default")) or 16+ lo, hi = num(spec.get("minimum")), num(spec.get("maximum"))+ fmap["numFrames"] = {"key": nf, "fps": fps, **({"min": lo} if lo is not None else {}), **({"max": hi} if hi is not None else {}),+ **({"step": m["frame_step"]} if m.get("frame_step") else {})}+ opts["durations"] = union(opts.get("durations", []), [d for d in NICE_DURATIONS if (lo is None or d * fps >= lo) and (hi is None or d * fps <= hi + (m.get("frame_step") or 0))])+ # Width and height fields (Replicate's Z-Image LoRA model): computed from the aspect ratio (FieldMap.size).+ if "width" in kf and "height" in kf and "aspectRatio" not in kf:+ w, h = inputs.get(kf["width"]) or {}, inputs.get(kf["height"]) or {}+ mx = [x for x in (num(w.get("maximum")), num(h.get("maximum"))) if x is not None]+ fmap["size"] = {"width": kf["width"], "height": kf["height"], "multiple": 16, **({"max": min(mx)} if mx else {}),+ **({"base": num(w.get("default"))} if num(w.get("default")) else {})}+ opts["aspectRatios"] = union(opts.get("aspectRatios", []), IMG_AR)part4_slots(op, kf, inputs, m, opts, fmap)# Frame rates an upscaler (or FPS Boost) can reach: params.targetFps -> its target_fps field.if m.get("fps_targets") and op in ("interpolate", "upscale-video"):@@ -1424,13 +1568,29 @@ def build_route(op, ep, provider, m, opts, ropts=None):# Inpaint routes say what the mask's paint means (edit routes get theirs when the inpaint route is derived).if op == "inpaint" and "mask" in fmap and mask_format(ep):fmap["maskFormat"] = mask_format(ep)- route = {"op": op, "provider": provider, "endpoint": ep, "map": fmap}+ # LoRAs (O1): the field the route's LoRA endpoint (or the endpoint itself) takes them in, from the research.+ lora_ep = ropts.get("loraEndpoint")+ lf = lora_field(provider, lora_ep or ep)+ if lf:+ fmap["loras"] = lf+ elif lora_ep:+ warn(f"{m['id']}: LoRA endpoint {lora_ep} has no researched LoRA field")+ route = {"op": op, "provider": provider, "endpoint": f"{ep}:{version}" if ropts.get("pin") else ep, "map": fmap}if ropts.get("note"):route["note"] = ropts["note"]- if ropts.get("loraEndpoint"):- if (provider, ropts["loraEndpoint"]) not in EPS:- warn(f"{m['id']}: LoRA endpoint {ropts['loraEndpoint']} not in research")- route["loraEndpoint"] = ropts["loraEndpoint"]+ if lora_ep:+ le = EPS.get((provider, lora_ep))+ if not le:+ warn(f"{m['id']}: LoRA endpoint {lora_ep} not in research")+ else:+ # The same payload goes to both endpoints: every field the route sends must be one the LoRA endpoint takes.+ missing = [f for f in map_fields(fmap) if f not in (le.get("inputs") or {})]+ if missing:+ warn(f"{m['id']}: {lora_ep} has no {missing} (sent by {ep})")+ rec = HOSTED_LORA.get((provider, lora_ep)) or {}+ if rec.get("commercialWeights") is False:+ warn(f"{m['id']}: {lora_ep} runs non-commercial weights ({rec.get('baseLicence')}): never an Original's default")+ route["loraEndpoint"] = lora_epreturn route, e@@ -1497,6 +1657,12 @@ for m in M:pricing = {"unit": u, "usd": usd, **({"note": note[0]} if note else {}), **extra}elif first_e:pricing = parse_price(first_e)+ # What a run costs on the route's LoRA endpoint, when its price is in the same unit (fal's /lora variants cost more).+ lora_eps = [r["loraEndpoint"] for r in routes if r.get("loraEndpoint")]+ if pricing and lora_eps and "withLoras" not in pricing:+ lp = parse_price(EPS.get((routes[0]["provider"], lora_eps[0])) or {})+ if lp and lp["unit"] == pricing["unit"]:+ pricing["withLoras"] = lp["usd"]d = {"id": m["id"], "name": m["name"], "vendor": m["vendor"], "family": m["family"], "engine": "cloud","kind": m["kind"], "tagline": m["tagline"], "routes": routes, "options": opts,diff --git a/src/lib/catalog/cloud-models.generated.ts b/src/lib/catalog/cloud-models.generated.tsindex a505b272..27c67e35 100644--- a/src/lib/catalog/cloud-models.generated.ts+++ b/src/lib/catalog/cloud-models.generated.ts@@ -1687,9 +1687,38 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4": "landscape_4_3","4:5": "portrait_4_3"}+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "max": 3,+ "range": {+ "min": 0,+ "max": 4+ }}},"loraEndpoint": "fal-ai/z-image/turbo/lora"+ },+ {+ "op": "t2i",+ "provider": "replicate",+ "endpoint": "prunaai/z-image-turbo-lora:29c866f1269ef45b736fbcdff00d6da2a555ecf5f4e575c93ab38c2a2f2693a1",+ "map": {+ "seed": "seed",+ "size": {+ "width": "width",+ "height": "height",+ "multiple": 16,+ "max": 1440,+ "base": 1024+ },+ "loras": {+ "shape": "arrays",+ "weights": "lora_weights",+ "scales": "lora_scales"+ }+ }}],"options": {@@ -1716,63 +1745,27 @@ export const CLOUD_MODELS: ModelDef[] = [},"pricing": {"unit": "megapixel",- "usd": 0.005- }- },- {- "id": "imagen-4",- "name": "Imagen 4",- "vendor": "Google",- "family": "imagen",- "engine": "cloud",- "kind": "image",- "tagline": "Google's photoreal text-to-image",- "routes": [- {- "op": "t2i",- "provider": "replicate",- "endpoint": "google/imagen-4",- "map": {- "aspectRatio": "aspect_ratio"- }- }- ],- "options": {- "aspectRatios": [- "1:1",- "9:16",- "16:9",- "3:4",- "4:3"- ]- },- "defaults": {- "aspectRatio": "1:1"- },- "pricing": {- "unit": "image",- "usd": 0.04+ "usd": 0.005,+ "withLoras": 0.0085}},{- "id": "recraft-4-1-pro",- "name": "Recraft V4.1 Pro",- "vendor": "Recraft",- "family": "recraft",+ "id": "qwen-image-2512-cloud",+ "name": "Qwen-Image 2512 (hosted)",+ "vendor": "Alibaba Qwen",+ "family": "qwen-image","engine": "cloud","kind": "image",- "tagline": "Recraft's top tier \u2014 2K design-grade images in your exact palette",+ "tagline": "Open-weights Qwen-Image: clean lettering and long prompts","routes": [{"op": "t2i","provider": "fal",- "endpoint": "fal-ai/recraft/v4.1/pro/text-to-image",+ "endpoint": "fal-ai/qwen-image-2512","map": {- "palette": {- "key": "colors",- "format": "rgb-object",- "background": "background_color"- },+ "negativePrompt": "negative_prompt",+ "numOutputs": "num_images",+ "seed": "seed","aspectRatio": {"key": "image_size","values": {@@ -1787,11 +1780,23 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4": "landscape_4_3","4:5": "portrait_4_3"}+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "max": 3,+ "range": {+ "min": 0,+ "max": 4+ }}- }+ },+ "loraEndpoint": "fal-ai/qwen-image-2512/lora"}],"options": {+ "negativePrompt": true,+ "seed": true,"aspectRatios": ["1:1","4:3",@@ -1803,40 +1808,37 @@ export const CLOUD_MODELS: ModelDef[] = ["21:9","5:4","4:5"- ]+ ],+ "maxOutputs": 4},- "badges": [- "pro"- ],"defaults": {"aspectRatio": "1:1"},"pricing": {- "unit": "image",- "usd": 0.21+ "unit": "megapixel",+ "usd": 0.02,+ "note": "rounded up to whole megapixels",+ "withLoras": 0.035}},{- "id": "recraft-4-style",- "name": "Recraft V4 Styles",- "vendor": "Recraft",- "family": "recraft",+ "id": "qwen-image-edit-2511-cloud",+ "name": "Qwen-Image-Edit 2511 (hosted)",+ "vendor": "Alibaba Qwen",+ "family": "qwen-image","engine": "cloud","kind": "image",- "tagline": "A new picture in the style of 1\u201310 reference images",+ "tagline": "Open-weights instruction edits with several references","routes": [{"op": "edit","provider": "fal",- "endpoint": "recraft/v4/style/text-to-image",+ "endpoint": "fal-ai/qwen-image-edit-2511","map": {+ "negativePrompt": "negative_prompt","images": "image_urls",- "styleId": "style_id",- "palette": {- "key": "colors",- "format": "rgb-object",- "background": "background_color"- },+ "numOutputs": "num_images",+ "seed": "seed","aspectRatio": {"key": "image_size","values": {@@ -1851,21 +1853,42 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4": "landscape_4_3","4:5": "portrait_4_3"}+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "max": 3,+ "range": {+ "min": 0,+ "max": 4+ }+ }+ },+ "loraEndpoint": "fal-ai/qwen-image-edit-2511/lora"+ },+ {+ "op": "edit",+ "provider": "replicate",+ "endpoint": "qwen/qwen-image-edit-2511",+ "map": {+ "images": "image",+ "seed": "seed",+ "aspectRatio": "aspect_ratio",+ "loras": {+ "shape": "single",+ "weights": "lora_weights",+ "scale": "lora_scale",+ "range": {+ "min": 0,+ "max": 4+ }}}}],"options": {- "controls": [- {- "param": "style_match",- "label": "Style match",- "values": [- "precise",- "flexible"- ]- }- ],+ "negativePrompt": true,+ "seed": true,"aspectRatios": ["1:1","4:3",@@ -1878,38 +1901,69 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4","4:5"],+ "maxOutputs": 4,"maxImages": 10},"defaults": {"aspectRatio": "1:1"},"pricing": {- "unit": "image",- "usd": 0.035,- "note": "+$0.005 when a new style is made from references"+ "unit": "megapixel",+ "usd": 0.03,+ "withLoras": 0.035}},{- "id": "recraft-4-style-pro",- "name": "Recraft V4 Styles Pro",- "vendor": "Recraft",- "family": "recraft",+ "id": "flux-2-klein-4b-cloud",+ "name": "FLUX.2 [klein] 4B (hosted)",+ "vendor": "Black Forest Labs",+ "family": "flux","engine": "cloud","kind": "image",- "tagline": "Recraft styles from your references, at Pro quality",+ "tagline": "The Apache-2.0 FLUX.2: cheapest drafts and edits","routes": [+ {+ "op": "t2i",+ "provider": "fal",+ "endpoint": "fal-ai/flux-2/klein/4b",+ "map": {+ "numOutputs": "num_images",+ "seed": "seed",+ "aspectRatio": {+ "key": "image_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "max": 3,+ "range": {+ "min": 0,+ "max": 4+ }+ }+ },+ "loraEndpoint": "fal-ai/flux-2/klein/4b/lora"+ },{"op": "edit","provider": "fal",- "endpoint": "recraft/v4/style/pro/text-to-image",+ "endpoint": "fal-ai/flux-2/klein/4b/edit","map": {"images": "image_urls",- "styleId": "style_id",- "palette": {- "key": "colors",- "format": "rgb-object",- "background": "background_color"- },+ "numOutputs": "num_images",+ "seed": "seed","aspectRatio": {"key": "image_size","values": {@@ -1924,21 +1978,22 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4": "landscape_4_3","4:5": "portrait_4_3"}+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "max": 3,+ "range": {+ "min": 0,+ "max": 4+ }}- }+ },+ "loraEndpoint": "fal-ai/flux-2/klein/4b/edit/lora"}],"options": {- "controls": [- {- "param": "style_match",- "label": "Style match",- "values": [- "precise",- "flexible"- ]- }- ],+ "seed": true,"aspectRatios": ["1:1","4:3",@@ -1951,40 +2006,37 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4","4:5"],+ "maxOutputs": 4,"maxImages": 10},"badges": [- "pro"+ "fast"],"defaults": {"aspectRatio": "1:1"},"pricing": {- "unit": "image",- "usd": 0.1,- "note": "+$0.005 when a new style is made from references"+ "unit": "megapixel",+ "usd": 0.005,+ "withLoras": 0.01}},{- "id": "recraft-4-style-saved",- "name": "Recraft V4 Styles \u00b7 saved style",- "vendor": "Recraft",- "family": "recraft",+ "id": "wan-2-2-a14b-image-cloud",+ "name": "Wan 2.2 A14B Image (hosted)",+ "vendor": "Alibaba Wan",+ "family": "wan","engine": "cloud","kind": "image",- "tagline": "A new picture in a style saved from your moodboard",+ "tagline": "Open-weights Wan 2.2 stills that take Wan LoRAs","routes": [{"op": "t2i","provider": "fal",- "endpoint": "recraft/v4/style/text-to-image",+ "endpoint": "fal-ai/wan/v2.2-a14b/text-to-image/lora","map": {- "styleId": "style_id",- "palette": {- "key": "colors",- "format": "rgb-object",- "background": "background_color"- },+ "negativePrompt": "negative_prompt",+ "seed": "seed","aspectRatio": {"key": "image_size","values": {@@ -1999,21 +2051,23 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4": "landscape_4_3","4:5": "portrait_4_3"}+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "range": {+ "min": 0,+ "max": 4+ },+ "transformer": "high",+ "weightName": true}}}],"options": {- "controls": [- {- "param": "style_match",- "label": "Style match",- "values": [- "precise",- "flexible"- ]- }- ],+ "negativePrompt": true,+ "seed": true,"aspectRatios": ["1:1","4:3",@@ -2028,68 +2082,66 @@ export const CLOUD_MODELS: ModelDef[] = []},"defaults": {- "aspectRatio": "1:1"+ "aspectRatio": "16:9"},"pricing": {"unit": "image",- "usd": 0.035- },- "hidden": true+ "usd": 0.05+ }},{- "id": "ideogram-3",- "name": "Ideogram 3.0",- "vendor": "Ideogram",- "family": "ideogram",+ "id": "imagen-4",+ "name": "Imagen 4",+ "vendor": "Google",+ "family": "imagen","engine": "cloud","kind": "image",- "tagline": "Posters and type in your exact brand colours, with 60+ style presets and style references",+ "tagline": "Google's photoreal text-to-image","routes": [{"op": "t2i",- "provider": "fal",- "endpoint": "fal-ai/ideogram/v3",+ "provider": "replicate",+ "endpoint": "google/imagen-4","map": {- "negativePrompt": "negative_prompt",- "images": "image_urls",- "numOutputs": "num_images",- "seed": "seed",- "palette": {- "key": "color_palette",- "format": "ideogram"- },- "aspectRatio": {- "key": "image_size",- "values": {- "1:1": "square_hd",- "4:3": "landscape_4_3",- "3:4": "portrait_4_3",- "16:9": "landscape_16_9",- "9:16": "portrait_16_9",- "3:2": "landscape_4_3",- "2:3": "portrait_4_3",- "21:9": "landscape_16_9",- "5:4": "landscape_4_3",- "4:5": "portrait_4_3"- }- },- "ignore": [- "strength"- ]+ "aspectRatio": "aspect_ratio"}- },+ }+ ],+ "options": {+ "aspectRatios": [+ "1:1",+ "9:16",+ "16:9",+ "3:4",+ "4:3"+ ]+ },+ "defaults": {+ "aspectRatio": "1:1"+ },+ "pricing": {+ "unit": "image",+ "usd": 0.04+ }+ },+ {+ "id": "recraft-4-1-pro",+ "name": "Recraft V4.1 Pro",+ "vendor": "Recraft",+ "family": "recraft",+ "engine": "cloud",+ "kind": "image",+ "tagline": "Recraft's top tier \u2014 2K design-grade images in your exact palette",+ "routes": [{- "op": "edit",+ "op": "t2i","provider": "fal",- "endpoint": "fal-ai/ideogram/v3/remix",+ "endpoint": "fal-ai/recraft/v4.1/pro/text-to-image","map": {- "negativePrompt": "negative_prompt",- "image": "image_url",- "numOutputs": "num_images",- "seed": "seed","palette": {- "key": "color_palette",- "format": "ideogram"+ "key": "colors",+ "format": "rgb-object",+ "background": "background_color"},"aspectRatio": {"key": "image_size",@@ -2105,121 +2157,11 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4": "landscape_4_3","4:5": "portrait_4_3"}- },- "ignore": [- "style_preset"- ]- }- },- {- "op": "inpaint",- "provider": "fal",- "endpoint": "fal-ai/ideogram/v3/edit",- "map": {- "image": "image_url",- "mask": "mask_url",- "numOutputs": "num_images",- "seed": "seed",- "maskFormat": "black",- "ignore": [- "style",- "strength"- ]+ }}}],"options": {- "controls": [- {- "param": "rendering_speed",- "label": "Speed",- "values": [- "TURBO",- "BALANCED",- "QUALITY"- ],- "default": "BALANCED"- },- {- "param": "style",- "label": "Style",- "values": [- "GENERAL",- "REALISTIC",- "DESIGN"- ]- },- {- "param": "style_preset",- "label": "Preset",- "values": [- "80S_ILLUSTRATION",- "90S_NOSTALGIA",- "ABSTRACT_ORGANIC",- "ANALOG_NOSTALGIA",- "ART_BRUT",- "ART_DECO",- "ART_POSTER",- "AURA",- "AVANT_GARDE",- "BAUHAUS",- "BLUEPRINT",- "BLURRY_MOTION",- "BRIGHT_ART",- "C4D_CARTOON",- "CHILDRENS_BOOK",- "COLLAGE",- "COLORING_BOOK_I",- "COLORING_BOOK_II",- "CUBISM",- "DARK_AURA",- "DOODLE",- "DOUBLE_EXPOSURE",- "DRAMATIC_CINEMA",- "EDITORIAL",- "EMOTIONAL_MINIMAL",- "ETHEREAL_PARTY",- "EXPIRED_FILM",- "FLAT_ART",- "FLAT_VECTOR",- "FOREST_REVERIE",- "GEO_MINIMALIST",- "GLASS_PRISM",- "GOLDEN_HOUR",- "GRAFFITI_I",- "GRAFFITI_II",- "HALFTONE_PRINT",- "HIGH_CONTRAST",- "HIPPIE_ERA",- "ICONIC",- "JAPANDI_FUSION",- "JAZZY",- "LONG_EXPOSURE",- "MAGAZINE_EDITORIAL",- "MINIMAL_ILLUSTRATION",- "MIXED_MEDIA",- "MONOCHROME",- "NIGHTLIFE",- "OIL_PAINTING",- "OLD_CARTOONS",- "PAINT_GESTURE",- "POP_ART",- "RETRO_ETCHING",- "RIVIERA_POP",- "SPOTLIGHT_80S",- "STYLIZED_RED",- "SURREAL_COLLAGE",- "TRAVEL_POSTER",- "VINTAGE_GEO",- "VINTAGE_POSTER",- "WATERCOLOR",- "WEIRD",- "WOODBLOCK_PRINT"- ]- }- ],- "negativePrompt": true,- "seed": true,"aspectRatios": ["1:1","4:3",@@ -2231,46 +2173,40 @@ export const CLOUD_MODELS: ModelDef[] = ["21:9","5:4","4:5"- ],- "maxOutputs": 4,- "maxImages": 4,- "sliders": [- {- "param": "strength",- "label": "Remix strength",- "min": 0.01,- "max": 1,- "step": 0.05,- "default": 0.8- }]},+ "badges": [+ "pro"+ ],"defaults": {"aspectRatio": "1:1"},"pricing": {"unit": "image",- "usd": 0.06,- "note": "Balanced; Turbo $0.03, Quality $0.09"+ "usd": 0.21}},{- "id": "krea-2-style",- "name": "Krea 2 Style Reference",- "vendor": "Krea",- "family": "krea",+ "id": "recraft-4-style",+ "name": "Recraft V4 Styles",+ "vendor": "Recraft",+ "family": "recraft","engine": "cloud","kind": "image",- "tagline": "Match the look of 1\u20133 reference images in a new picture, zero-shot",+ "tagline": "A new picture in the style of 1\u201310 reference images","routes": [{"op": "edit","provider": "fal",- "endpoint": "fal-ai/krea-2/turbo/style",+ "endpoint": "recraft/v4/style/text-to-image","map": {- "images": "reference_image_urls",- "numOutputs": "num_images",- "seed": "seed",+ "images": "image_urls",+ "styleId": "style_id",+ "palette": {+ "key": "colors",+ "format": "rgb-object",+ "background": "background_color"+ },"aspectRatio": {"key": "image_size","values": {@@ -2290,17 +2226,16 @@ export const CLOUD_MODELS: ModelDef[] = [}],"options": {- "sliders": [+ "controls": [{- "param": "style_scale",- "label": "Style strength",- "min": 0,- "max": 4,- "step": 0.05,- "default": 1+ "param": "style_match",+ "label": "Style match",+ "values": [+ "precise",+ "flexible"+ ]}],- "seed": true,"aspectRatios": ["1:1","4:3",@@ -2313,93 +2248,38 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4","4:5"],- "maxOutputs": 4,- "maxImages": 3+ "maxImages": 10},- "badges": [- "new",- "fast"- ],"defaults": {"aspectRatio": "1:1"},"pricing": {- "unit": "megapixel",- "usd": 0.01+ "unit": "image",+ "usd": 0.035,+ "note": "+$0.005 when a new style is made from references"}},{- "id": "flux-redux-ultra",- "name": "FLUX1.1 [pro] Ultra Redux",- "vendor": "Black Forest Labs",- "family": "flux",+ "id": "recraft-4-style-pro",+ "name": "Recraft V4 Styles Pro",+ "vendor": "Recraft",+ "family": "recraft","engine": "cloud","kind": "image",- "tagline": "Variations and remixes of an image, steered by a prompt, up to 4MP",+ "tagline": "Recraft styles from your references, at Pro quality","routes": [{"op": "edit","provider": "fal",- "endpoint": "fal-ai/flux-pro/v1.1-ultra/redux",+ "endpoint": "recraft/v4/style/pro/text-to-image","map": {- "image": "image_url",- "numOutputs": "num_images",- "seed": "seed",- "aspectRatio": "aspect_ratio"- }- }- ],- "options": {- "sliders": [- {- "param": "image_prompt_strength",- "label": "Reference strength",- "min": 0,- "max": 1,- "step": 0.05,- "default": 0.1- }- ],- "seed": true,- "aspectRatios": [- "21:9",- "16:9",- "4:3",- "3:2",- "1:1",- "2:3",- "3:4",- "9:16",- "9:21"- ],- "maxOutputs": 4,- "maxImages": 1- },- "defaults": {- "aspectRatio": "1:1"- },- "pricing": {- "unit": "megapixel",- "usd": 0.05- }- },- {- "id": "flux-redux-pro",- "name": "FLUX1.1 [pro] Redux",- "vendor": "Black Forest Labs",- "family": "flux",- "engine": "cloud",- "kind": "image",- "tagline": "Image-prompted FLUX: keeps the reference's look while you change the scene",- "routes": [- {- "op": "edit",- "provider": "fal",- "endpoint": "fal-ai/flux-pro/v1.1/redux",- "map": {- "image": "image_url",- "numOutputs": "num_images",- "seed": "seed",+ "images": "image_urls",+ "styleId": "style_id",+ "palette": {+ "key": "colors",+ "format": "rgb-object",+ "background": "background_color"+ },"aspectRatio": {"key": "image_size","values": {@@ -2419,7 +2299,16 @@ export const CLOUD_MODELS: ModelDef[] = [}],"options": {- "seed": true,+ "controls": [+ {+ "param": "style_match",+ "label": "Style match",+ "values": [+ "precise",+ "flexible"+ ]+ }+ ],"aspectRatios": ["1:1","4:3",@@ -2432,35 +2321,40 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4","4:5"],- "maxOutputs": 4,- "maxImages": 1+ "maxImages": 10},+ "badges": [+ "pro"+ ],"defaults": {"aspectRatio": "1:1"},"pricing": {- "unit": "megapixel",- "usd": 0.05+ "unit": "image",+ "usd": 0.1,+ "note": "+$0.005 when a new style is made from references"}},{- "id": "instant-character",- "name": "Instant Character",- "vendor": "Tencent Hunyuan",- "family": "instant-character",+ "id": "recraft-4-style-saved",+ "name": "Recraft V4 Styles \u00b7 saved style",+ "vendor": "Recraft",+ "family": "recraft","engine": "cloud","kind": "image",- "tagline": "One photo of a character, any new scene \u2014 no training",+ "tagline": "A new picture in a style saved from your moodboard","routes": [{- "op": "edit",+ "op": "t2i","provider": "fal",- "endpoint": "fal-ai/instant-character",+ "endpoint": "recraft/v4/style/text-to-image","map": {- "negativePrompt": "negative_prompt",- "image": "image_url",- "numOutputs": "num_images",- "seed": "seed",+ "styleId": "style_id",+ "palette": {+ "key": "colors",+ "format": "rgb-object",+ "background": "background_color"+ },"aspectRatio": {"key": "image_size","values": {@@ -2480,18 +2374,16 @@ export const CLOUD_MODELS: ModelDef[] = [}],"options": {- "sliders": [+ "controls": [{- "param": "scale",- "label": "Character strength",- "min": 0,- "max": 2,- "step": 0.05,- "default": 1+ "param": "style_match",+ "label": "Style match",+ "values": [+ "precise",+ "flexible"+ ]}],- "negativePrompt": true,- "seed": true,"aspectRatios": ["1:1","4:3",@@ -2503,37 +2395,39 @@ export const CLOUD_MODELS: ModelDef[] = ["21:9","5:4","4:5"- ],- "maxOutputs": 4,- "maxImages": 1+ ]},"defaults": {"aspectRatio": "1:1"},"pricing": {- "unit": "megapixel",- "usd": 0.1- }+ "unit": "image",+ "usd": 0.035+ },+ "hidden": true},{- "id": "qwen-multiple-angles",- "name": "Qwen Multiple Angles",- "vendor": "Alibaba Qwen",- "family": "qwen-image",+ "id": "ideogram-3",+ "name": "Ideogram 3.0",+ "vendor": "Ideogram",+ "family": "ideogram","engine": "cloud","kind": "image",- "tagline": "See the same shot from another angle: rotate, tilt and zoom the camera",+ "tagline": "Posters and type in your exact brand colours, with 60+ style presets and style references","routes": [{- "op": "edit",+ "op": "t2i","provider": "fal",- "endpoint": "fal-ai/qwen-image-edit-2511-multiple-angles",+ "endpoint": "fal-ai/ideogram/v3","map": {- "prompt": "additional_prompt","negativePrompt": "negative_prompt","images": "image_urls","numOutputs": "num_images","seed": "seed",+ "palette": {+ "key": "color_palette",+ "format": "ideogram"+ },"aspectRatio": {"key": "image_size","values": {@@ -2548,49 +2442,525 @@ export const CLOUD_MODELS: ModelDef[] = ["5:4": "landscape_4_3","4:5": "portrait_4_3"}- }+ },+ "ignore": [+ "strength"+ ]+ }+ },+ {+ "op": "edit",+ "provider": "fal",+ "endpoint": "fal-ai/ideogram/v3/remix",+ "map": {+ "negativePrompt": "negative_prompt",+ "image": "image_url",+ "numOutputs": "num_images",+ "seed": "seed",+ "palette": {+ "key": "color_palette",+ "format": "ideogram"+ },+ "aspectRatio": {+ "key": "image_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ },+ "ignore": [+ "style_preset"+ ]+ }+ },+ {+ "op": "inpaint",+ "provider": "fal",+ "endpoint": "fal-ai/ideogram/v3/edit",+ "map": {+ "image": "image_url",+ "mask": "mask_url",+ "numOutputs": "num_images",+ "seed": "seed",+ "maskFormat": "black",+ "ignore": [+ "style",+ "strength"+ ]}}],"options": {- "sliders": [+ "controls": [{- "param": "horizontal_angle",- "label": "Rotate (\u00b0)",- "min": 0,- "max": 360,- "step": 1,- "default": 0+ "param": "rendering_speed",+ "label": "Speed",+ "values": [+ "TURBO",+ "BALANCED",+ "QUALITY"+ ],+ "default": "BALANCED"},{- "param": "vertical_angle",- "label": "Tilt (\u00b0)",- "min": -30,- "max": 90,- "step": 1,- "default": 0+ "param": "style",+ "label": "Style",+ "values": [+ "GENERAL",+ "REALISTIC",+ "DESIGN"+ ]},{- "param": "zoom",- "label": "Zoom",- "min": 0,- "max": 10,- "step": 1,- "default": 5- }- ],- "negativePrompt": true,- "seed": true,- "aspectRatios": [- "1:1",- "4:3",- "3:4",- "16:9",- "9:16",- "3:2",- "2:3",- "21:9",- "5:4",+ "param": "style_preset",+ "label": "Preset",+ "values": [+ "80S_ILLUSTRATION",+ "90S_NOSTALGIA",+ "ABSTRACT_ORGANIC",+ "ANALOG_NOSTALGIA",+ "ART_BRUT",+ "ART_DECO",+ "ART_POSTER",+ "AURA",+ "AVANT_GARDE",+ "BAUHAUS",+ "BLUEPRINT",+ "BLURRY_MOTION",+ "BRIGHT_ART",+ "C4D_CARTOON",+ "CHILDRENS_BOOK",+ "COLLAGE",+ "COLORING_BOOK_I",+ "COLORING_BOOK_II",+ "CUBISM",+ "DARK_AURA",+ "DOODLE",+ "DOUBLE_EXPOSURE",+ "DRAMATIC_CINEMA",+ "EDITORIAL",+ "EMOTIONAL_MINIMAL",+ "ETHEREAL_PARTY",+ "EXPIRED_FILM",+ "FLAT_ART",+ "FLAT_VECTOR",+ "FOREST_REVERIE",+ "GEO_MINIMALIST",+ "GLASS_PRISM",+ "GOLDEN_HOUR",+ "GRAFFITI_I",+ "GRAFFITI_II",+ "HALFTONE_PRINT",+ "HIGH_CONTRAST",+ "HIPPIE_ERA",+ "ICONIC",+ "JAPANDI_FUSION",+ "JAZZY",+ "LONG_EXPOSURE",+ "MAGAZINE_EDITORIAL",+ "MINIMAL_ILLUSTRATION",+ "MIXED_MEDIA",+ "MONOCHROME",+ "NIGHTLIFE",+ "OIL_PAINTING",+ "OLD_CARTOONS",+ "PAINT_GESTURE",+ "POP_ART",+ "RETRO_ETCHING",+ "RIVIERA_POP",+ "SPOTLIGHT_80S",+ "STYLIZED_RED",+ "SURREAL_COLLAGE",+ "TRAVEL_POSTER",+ "VINTAGE_GEO",+ "VINTAGE_POSTER",+ "WATERCOLOR",+ "WEIRD",+ "WOODBLOCK_PRINT"+ ]+ }+ ],+ "negativePrompt": true,+ "seed": true,+ "aspectRatios": [+ "1:1",+ "4:3",+ "3:4",+ "16:9",+ "9:16",+ "3:2",+ "2:3",+ "21:9",+ "5:4",+ "4:5"+ ],+ "maxOutputs": 4,+ "maxImages": 4,+ "sliders": [+ {+ "param": "strength",+ "label": "Remix strength",+ "min": 0.01,+ "max": 1,+ "step": 0.05,+ "default": 0.8+ }+ ]+ },+ "defaults": {+ "aspectRatio": "1:1"+ },+ "pricing": {+ "unit": "image",+ "usd": 0.06,+ "note": "Balanced; Turbo $0.03, Quality $0.09"+ }+ },+ {+ "id": "krea-2-style",+ "name": "Krea 2 Style Reference",+ "vendor": "Krea",+ "family": "krea",+ "engine": "cloud",+ "kind": "image",+ "tagline": "Match the look of 1\u20133 reference images in a new picture, zero-shot",+ "routes": [+ {+ "op": "edit",+ "provider": "fal",+ "endpoint": "fal-ai/krea-2/turbo/style",+ "map": {+ "images": "reference_image_urls",+ "numOutputs": "num_images",+ "seed": "seed",+ "aspectRatio": {+ "key": "image_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ }+ }+ }+ ],+ "options": {+ "sliders": [+ {+ "param": "style_scale",+ "label": "Style strength",+ "min": 0,+ "max": 4,+ "step": 0.05,+ "default": 1+ }+ ],+ "seed": true,+ "aspectRatios": [+ "1:1",+ "4:3",+ "3:4",+ "16:9",+ "9:16",+ "3:2",+ "2:3",+ "21:9",+ "5:4",+ "4:5"+ ],+ "maxOutputs": 4,+ "maxImages": 3+ },+ "badges": [+ "new",+ "fast"+ ],+ "defaults": {+ "aspectRatio": "1:1"+ },+ "pricing": {+ "unit": "megapixel",+ "usd": 0.01+ }+ },+ {+ "id": "flux-redux-ultra",+ "name": "FLUX1.1 [pro] Ultra Redux",+ "vendor": "Black Forest Labs",+ "family": "flux",+ "engine": "cloud",+ "kind": "image",+ "tagline": "Variations and remixes of an image, steered by a prompt, up to 4MP",+ "routes": [+ {+ "op": "edit",+ "provider": "fal",+ "endpoint": "fal-ai/flux-pro/v1.1-ultra/redux",+ "map": {+ "image": "image_url",+ "numOutputs": "num_images",+ "seed": "seed",+ "aspectRatio": "aspect_ratio"+ }+ }+ ],+ "options": {+ "sliders": [+ {+ "param": "image_prompt_strength",+ "label": "Reference strength",+ "min": 0,+ "max": 1,+ "step": 0.05,+ "default": 0.1+ }+ ],+ "seed": true,+ "aspectRatios": [+ "21:9",+ "16:9",+ "4:3",+ "3:2",+ "1:1",+ "2:3",+ "3:4",+ "9:16",+ "9:21"+ ],+ "maxOutputs": 4,+ "maxImages": 1+ },+ "defaults": {+ "aspectRatio": "1:1"+ },+ "pricing": {+ "unit": "megapixel",+ "usd": 0.05+ }+ },+ {+ "id": "flux-redux-pro",+ "name": "FLUX1.1 [pro] Redux",+ "vendor": "Black Forest Labs",+ "family": "flux",+ "engine": "cloud",+ "kind": "image",+ "tagline": "Image-prompted FLUX: keeps the reference's look while you change the scene",+ "routes": [+ {+ "op": "edit",+ "provider": "fal",+ "endpoint": "fal-ai/flux-pro/v1.1/redux",+ "map": {+ "image": "image_url",+ "numOutputs": "num_images",+ "seed": "seed",+ "aspectRatio": {+ "key": "image_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ }+ }+ }+ ],+ "options": {+ "seed": true,+ "aspectRatios": [+ "1:1",+ "4:3",+ "3:4",+ "16:9",+ "9:16",+ "3:2",+ "2:3",+ "21:9",+ "5:4",+ "4:5"+ ],+ "maxOutputs": 4,+ "maxImages": 1+ },+ "defaults": {+ "aspectRatio": "1:1"+ },+ "pricing": {+ "unit": "megapixel",+ "usd": 0.05+ }+ },+ {+ "id": "instant-character",+ "name": "Instant Character",+ "vendor": "Tencent Hunyuan",+ "family": "instant-character",+ "engine": "cloud",+ "kind": "image",+ "tagline": "One photo of a character, any new scene \u2014 no training",+ "routes": [+ {+ "op": "edit",+ "provider": "fal",+ "endpoint": "fal-ai/instant-character",+ "map": {+ "negativePrompt": "negative_prompt",+ "image": "image_url",+ "numOutputs": "num_images",+ "seed": "seed",+ "aspectRatio": {+ "key": "image_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ }+ }+ }+ ],+ "options": {+ "sliders": [+ {+ "param": "scale",+ "label": "Character strength",+ "min": 0,+ "max": 2,+ "step": 0.05,+ "default": 1+ }+ ],+ "negativePrompt": true,+ "seed": true,+ "aspectRatios": [+ "1:1",+ "4:3",+ "3:4",+ "16:9",+ "9:16",+ "3:2",+ "2:3",+ "21:9",+ "5:4",+ "4:5"+ ],+ "maxOutputs": 4,+ "maxImages": 1+ },+ "defaults": {+ "aspectRatio": "1:1"+ },+ "pricing": {+ "unit": "megapixel",+ "usd": 0.1+ }+ },+ {+ "id": "qwen-multiple-angles",+ "name": "Qwen Multiple Angles",+ "vendor": "Alibaba Qwen",+ "family": "qwen-image",+ "engine": "cloud",+ "kind": "image",+ "tagline": "See the same shot from another angle: rotate, tilt and zoom the camera",+ "routes": [+ {+ "op": "edit",+ "provider": "fal",+ "endpoint": "fal-ai/qwen-image-edit-2511-multiple-angles",+ "map": {+ "prompt": "additional_prompt",+ "negativePrompt": "negative_prompt",+ "images": "image_urls",+ "numOutputs": "num_images",+ "seed": "seed",+ "aspectRatio": {+ "key": "image_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ }+ }+ }+ ],+ "options": {+ "sliders": [+ {+ "param": "horizontal_angle",+ "label": "Rotate (\u00b0)",+ "min": 0,+ "max": 360,+ "step": 1,+ "default": 0+ },+ {+ "param": "vertical_angle",+ "label": "Tilt (\u00b0)",+ "min": -30,+ "max": 90,+ "step": 1,+ "default": 0+ },+ {+ "param": "zoom",+ "label": "Zoom",+ "min": 0,+ "max": 10,+ "step": 1,+ "default": 5+ }+ ],+ "negativePrompt": true,+ "seed": true,+ "aspectRatios": [+ "1:1",+ "4:3",+ "3:4",+ "16:9",+ "9:16",+ "3:2",+ "2:3",+ "21:9",+ "5:4","4:5"],"maxOutputs": 4,@@ -5417,161 +5787,531 @@ export const CLOUD_MODELS: ModelDef[] = ["fixed": {"prompt_optimizer": true}- }+ }+ },+ {+ "op": "i2v",+ "provider": "fal",+ "endpoint": "fal-ai/minimax/hailuo-02/standard/image-to-video",+ "map": {+ "image": "image_url",+ "endImage": "end_image_url",+ "resolution": "resolution",+ "duration": {+ "key": "duration",+ "type": "string"+ },+ "fixed": {+ "prompt_optimizer": true+ }+ }+ },+ {+ "op": "flf2v",+ "provider": "fal",+ "endpoint": "fal-ai/minimax/hailuo-02/standard/image-to-video",+ "map": {+ "image": "image_url",+ "endImage": "end_image_url",+ "resolution": "resolution",+ "duration": {+ "key": "duration",+ "type": "string"+ },+ "fixed": {+ "prompt_optimizer": true+ }+ }+ }+ ],+ "options": {+ "durations": [+ 6,+ 10+ ],+ "endFrame": true,+ "resolutions": [+ "512P",+ "768P"+ ],+ "maxImages": 1+ },+ "defaults": {+ "duration": 6,+ "resolution": "768P"+ },+ "pricing": {+ "unit": "second",+ "usd": 0.045+ }+ },+ {+ "id": "flux-3-video",+ "name": "FLUX.3 Video",+ "vendor": "Black Forest Labs",+ "family": "flux",+ "engine": "cloud",+ "kind": "video",+ "tagline": "BFL's video model with keyframes and edits",+ "routes": [+ {+ "op": "t2v",+ "provider": "fal",+ "endpoint": "blackforestlabs/flux-3/text-to-video",+ "map": {+ "generateAudio": "generate_audio",+ "aspectRatio": "aspect_ratio",+ "resolution": "resolution",+ "duration": {+ "key": "duration",+ "type": "string"+ }+ }+ },+ {+ "op": "i2v",+ "provider": "fal",+ "endpoint": "blackforestlabs/flux-3/image-to-video",+ "map": {+ "image": "image_url",+ "generateAudio": "generate_audio",+ "aspectRatio": "aspect_ratio",+ "resolution": "resolution",+ "duration": {+ "key": "duration",+ "type": "string"+ }+ }+ },+ {+ "op": "flf2v",+ "provider": "fal",+ "endpoint": "blackforestlabs/flux-3/first-last-frame-to-video",+ "map": {+ "image": "start_image_url",+ "endImage": "end_image_url",+ "generateAudio": "generate_audio",+ "aspectRatio": "aspect_ratio",+ "resolution": "resolution",+ "duration": {+ "key": "duration",+ "type": "number"+ }+ }+ },+ {+ "op": "v2v",+ "provider": "fal",+ "endpoint": "blackforestlabs/flux-3/edit-video",+ "map": {+ "video": "video_url"+ }+ },+ {+ "op": "extend",+ "provider": "fal",+ "endpoint": "blackforestlabs/flux-3/extend-video",+ "map": {+ "video": "video_url",+ "generateAudio": "generate_audio",+ "aspectRatio": "aspect_ratio",+ "resolution": "resolution",+ "duration": {+ "key": "duration",+ "type": "string"+ }+ }+ }+ ],+ "options": {+ "audio": true,+ "aspectRatios": [+ "auto",+ "21:9",+ "2:1",+ "16:9",+ "4:3",+ "1:1",+ "3:4",+ "9:16"+ ],+ "resolutions": [+ "720p",+ "1080p",+ "1440p",+ "2160p"+ ],+ "durations": [+ 5,+ 6,+ 8,+ 10,+ 12,+ 15,+ 20+ ],+ "maxImages": 1,+ "endFrame": true+ },+ "badges": [+ "new"+ ],+ "defaults": {+ "aspectRatio": "16:9",+ "generateAudio": true+ }+ },+ {+ "id": "wan-2-2-a14b-cloud",+ "name": "Wan 2.2 A14B (hosted)",+ "vendor": "Alibaba Wan",+ "family": "wan",+ "engine": "cloud",+ "kind": "video",+ "tagline": "Open-weights Wan 2.2 that takes camera and effect LoRAs",+ "routes": [+ {+ "op": "t2v",+ "provider": "fal",+ "endpoint": "fal-ai/wan/v2.2-a14b/text-to-video",+ "map": {+ "negativePrompt": "negative_prompt",+ "seed": "seed",+ "numFrames": {+ "key": "num_frames",+ "fps": 16,+ "min": 17,+ "max": 161,+ "step": 4+ },+ "aspectRatio": "aspect_ratio",+ "resolution": "resolution",+ "defaults": {+ "interpolator_model": "none"+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "range": {+ "min": 0,+ "max": 4+ },+ "transformer": "high",+ "weightName": true+ }+ },+ "loraEndpoint": "fal-ai/wan/v2.2-a14b/text-to-video/lora"},{"op": "i2v","provider": "fal",- "endpoint": "fal-ai/minimax/hailuo-02/standard/image-to-video",+ "endpoint": "fal-ai/wan/v2.2-a14b/image-to-video","map": {+ "negativePrompt": "negative_prompt","image": "image_url","endImage": "end_image_url",+ "seed": "seed",+ "numFrames": {+ "key": "num_frames",+ "fps": 16,+ "min": 17,+ "max": 161,+ "step": 4+ },+ "aspectRatio": "aspect_ratio","resolution": "resolution",- "duration": {- "key": "duration",- "type": "string"+ "defaults": {+ "interpolator_model": "none"},- "fixed": {- "prompt_optimizer": true+ "loras": {+ "shape": "items",+ "key": "loras",+ "range": {+ "min": 0,+ "max": 4+ },+ "transformer": "high",+ "weightName": true}- }+ },+ "loraEndpoint": "fal-ai/wan/v2.2-a14b/image-to-video/lora"},{- "op": "flf2v",- "provider": "fal",- "endpoint": "fal-ai/minimax/hailuo-02/standard/image-to-video",+ "op": "t2v",+ "provider": "replicate",+ "endpoint": "wan-video/wan-2.2-t2v-fast","map": {- "image": "image_url",- "endImage": "end_image_url",+ "seed": "seed",+ "numFrames": {+ "key": "num_frames",+ "fps": 16,+ "min": 81,+ "max": 121,+ "step": 4+ },+ "aspectRatio": "aspect_ratio","resolution": "resolution",- "duration": {- "key": "duration",- "type": "string"+ "loras": {+ "shape": "experts",+ "high": {+ "weights": "lora_weights_transformer",+ "scale": "lora_scale_transformer"+ },+ "low": {+ "weights": "lora_weights_transformer_2",+ "scale": "lora_scale_transformer_2"+ }+ }+ }+ },+ {+ "op": "i2v",+ "provider": "replicate",+ "endpoint": "wan-video/wan-2.2-i2v-fast",+ "map": {+ "image": "image",+ "endImage": "last_image",+ "seed": "seed",+ "numFrames": {+ "key": "num_frames",+ "fps": 16,+ "min": 81,+ "max": 121,+ "step": 4},- "fixed": {- "prompt_optimizer": true+ "resolution": "resolution",+ "loras": {+ "shape": "experts",+ "high": {+ "weights": "lora_weights_transformer",+ "scale": "lora_scale_transformer"+ },+ "low": {+ "weights": "lora_weights_transformer_2",+ "scale": "lora_scale_transformer_2"+ }}}}],"options": {"durations": [+ 3,+ 4,+ 5,6,+ 8,10],- "endFrame": true,+ "negativePrompt": true,+ "seed": true,+ "aspectRatios": [+ "16:9",+ "9:16",+ "1:1",+ "auto"+ ],"resolutions": [- "512P",- "768P"+ "480p",+ "580p",+ "720p"],+ "endFrame": true,"maxImages": 1},"defaults": {- "duration": 6,- "resolution": "768P"+ "aspectRatio": "16:9",+ "duration": 5,+ "resolution": "720p"},"pricing": {"unit": "second",- "usd": 0.045+ "usd": 0.08,+ "note": "720p on fal; 580p $0.06/s, 480p $0.04/s; with LoRAs $0.10/s",+ "byResolution": {+ "720p": 0.08,+ "580p": 0.06,+ "480p": 0.04+ },+ "withLoras": 0.1}},{- "id": "flux-3-video",- "name": "FLUX.3 Video",- "vendor": "Black Forest Labs",- "family": "flux",+ "id": "ltx-2-3-22b-cloud",+ "name": "LTX-2.3 22B (hosted)",+ "vendor": "Lightricks",+ "family": "ltx","engine": "cloud","kind": "video",- "tagline": "BFL's video model with keyframes and edits",+ "tagline": "Open-weights LTX-2.3 with sound, camera and motion LoRAs","routes": [{"op": "t2v","provider": "fal",- "endpoint": "blackforestlabs/flux-3/text-to-video",+ "endpoint": "fal-ai/ltx-2.3-22b/text-to-video","map": {+ "negativePrompt": "negative_prompt",+ "seed": "seed","generateAudio": "generate_audio",- "aspectRatio": "aspect_ratio",- "resolution": "resolution",- "duration": {- "key": "duration",- "type": "string"+ "fps": "fps",+ "numFrames": {+ "key": "num_frames",+ "fps": 24,+ "min": 9,+ "max": 481,+ "step": 8+ },+ "aspectRatio": {+ "key": "video_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ },+ "defaults": {+ "enable_prompt_expansion": false+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "required": true,+ "range": {+ "min": 0,+ "max": 4+ },+ "weightName": true}- }+ },+ "loraEndpoint": "fal-ai/ltx-2.3-22b/text-to-video/lora"},{"op": "i2v","provider": "fal",- "endpoint": "blackforestlabs/flux-3/image-to-video",+ "endpoint": "fal-ai/ltx-2.3-22b/image-to-video","map": {+ "negativePrompt": "negative_prompt","image": "image_url",+ "endImage": "end_image_url",+ "seed": "seed","generateAudio": "generate_audio",- "aspectRatio": "aspect_ratio",- "resolution": "resolution",- "duration": {- "key": "duration",- "type": "string"+ "fps": "fps",+ "numFrames": {+ "key": "num_frames",+ "fps": 24,+ "min": 9,+ "max": 481,+ "step": 8+ },+ "aspectRatio": {+ "key": "video_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ },+ "defaults": {+ "enable_prompt_expansion": false+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "required": true,+ "range": {+ "min": 0,+ "max": 4+ },+ "weightName": true}- }+ },+ "loraEndpoint": "fal-ai/ltx-2.3-22b/image-to-video/lora"},{- "op": "flf2v",+ "op": "extend","provider": "fal",- "endpoint": "blackforestlabs/flux-3/first-last-frame-to-video",+ "endpoint": "fal-ai/ltx-2.3-22b/extend-video","map": {- "image": "start_image_url",+ "negativePrompt": "negative_prompt","endImage": "end_image_url",+ "video": "video_url",+ "seed": "seed","generateAudio": "generate_audio",- "aspectRatio": "aspect_ratio",- "resolution": "resolution",- "duration": {- "key": "duration",- "type": "number"+ "defaults": {+ "enable_prompt_expansion": false+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "required": true,+ "range": {+ "min": 0,+ "max": 4+ },+ "weightName": true}- }+ },+ "loraEndpoint": "fal-ai/ltx-2.3-22b/extend-video/lora"},{"op": "v2v","provider": "fal",- "endpoint": "blackforestlabs/flux-3/edit-video",- "map": {- "video": "video_url"- }- },- {- "op": "extend",- "provider": "fal",- "endpoint": "blackforestlabs/flux-3/extend-video",+ "endpoint": "fal-ai/ltx-2.3-22b/video-to-video","map": {+ "negativePrompt": "negative_prompt","video": "video_url",+ "seed": "seed","generateAudio": "generate_audio",- "aspectRatio": "aspect_ratio",- "resolution": "resolution",- "duration": {- "key": "duration",- "type": "string"+ "aspectRatio": {+ "key": "video_size",+ "values": {+ "1:1": "square_hd",+ "4:3": "landscape_4_3",+ "3:4": "portrait_4_3",+ "16:9": "landscape_16_9",+ "9:16": "portrait_16_9",+ "3:2": "landscape_4_3",+ "2:3": "portrait_4_3",+ "21:9": "landscape_16_9",+ "5:4": "landscape_4_3",+ "4:5": "portrait_4_3"+ }+ },+ "defaults": {+ "enable_prompt_expansion": false+ },+ "loras": {+ "shape": "items",+ "key": "loras",+ "required": true,+ "range": {+ "min": 0,+ "max": 4+ },+ "weightName": true}- }+ },+ "loraEndpoint": "fal-ai/ltx-2.3-22b/video-to-video/lora"}],"options": {- "audio": true,- "aspectRatios": [- "auto",- "21:9",- "2:1",- "16:9",- "4:3",- "1:1",- "3:4",- "9:16"- ],- "resolutions": [- "720p",- "1080p",- "1440p",- "2160p"- ],"durations": [+ 3,+ 4,5,6,8,@@ -5580,15 +6320,37 @@ export const CLOUD_MODELS: ModelDef[] = [15,20],- "maxImages": 1,- "endFrame": true+ "negativePrompt": true,+ "seed": true,+ "audio": true,+ "aspectRatios": [+ "1:1",+ "4:3",+ "3:4",+ "16:9",+ "9:16",+ "3:2",+ "2:3",+ "21:9",+ "5:4",+ "4:5"+ ],+ "endFrame": true,+ "maxImages": 1},"badges": [- "new"+ "audio"],"defaults": {"aspectRatio": "16:9",+ "duration": 5,"generateAudio": true+ },+ "pricing": {+ "unit": "second",+ "usd": 0.036,+ "note": "$0.001605 per megapixel of video: about $0.18 for 5 s at 720p ($0.20 with LoRAs)",+ "withLoras": 0.04}},{diff --git a/src/lib/catalog/payload.ts b/src/lib/catalog/payload.tsindex a0e05dc8..e29666d9 100644--- a/src/lib/catalog/payload.ts+++ b/src/lib/catalog/payload.ts@@ -1,5 +1,6 @@import { readTimeline, timelineTracks } from "@/lib/av/timeline";import { upscaleFactorFor } from "@/lib/av/upscale";+import { loraFields } from "./loras";import { OPERATION_OUTPUT, type DurationField, type EnumField, type FieldMap, type GenInput, type MatteOutput, type MediaKind, type Operation, type PixelPoint } from "./types";function enumValue(field: string | EnumField, value: string): [string, unknown] {@@ -65,9 +66,33 @@ export function numFramesValue(f: NonNullable<FieldMap["numFrames"]>, input: Picconst seconds = input.sourceDuration ?? input.duration;if (seconds === undefined || !Number.isFinite(seconds) || seconds <= 0) return undefined;const fps = input.fps !== undefined && input.fps > 0 ? input.fps : f.fps;+ // Wan wants 4n+1 frames and LTX 8n+1: the nearest count of that form that fits.+ if (f.step) {+ const step = f.step;+ const fit = (n: number) => Math.round((n - 1) / step) * step + 1;+ let n = fit(seconds * fps);+ while (f.max !== undefined && n > f.max) n -= step;+ while (f.min !== undefined && n < f.min) n += step;+ return n;+ }return inRange(seconds * fps, { min: f.min, max: f.max, integer: true });}+/** Width and height for an aspect ratio on a `base`×`base` pixel budget (FieldMap.size). */+export function sizeValue(f: NonNullable<FieldMap["size"]>, aspectRatio: string | undefined): { width: number; height: number } {+ const base = f.base ?? 1024;+ const ratio = (aspectRatio && ratioOf(aspectRatio)) || 1;+ const round = (v: number) => Math.max(f.multiple, Math.round(v / f.multiple) * f.multiple);+ let width = round(base * Math.sqrt(ratio));+ let height = round(base / Math.sqrt(ratio));+ if (f.max !== undefined && Math.max(width, height) > f.max) {+ const k = f.max / Math.max(width, height);+ width = Math.min(f.max, round(width * k));+ height = Math.min(f.max, round(height * k));+ }+ return { width, height };+}+/** Path segments that would reach Object.prototype (or a constructor) instead of the payload. */const UNSAFE_KEYS = new Set(["__proto__", "constructor", "prototype"]);@@ -303,6 +328,13 @@ export function buildPayload(map: FieldMap, input: GenInput): Record<string, unkif (map.styleId && input.styleId) out[map.styleId] = input.styleId;if (map.numLayers && input.numLayers !== undefined) out[map.numLayers] = input.numLayers;if (map.palette && input.palette?.length) out[map.palette.key] = paletteValue(map.palette.format, input.palette);+ if (map.size) {+ const { width, height } = sizeValue(map.size, input.aspectRatio);+ out[map.size.width] = width;+ out[map.size.height] = height;+ }+ // LoRAs (a look, a motion, a trained identity) in the API's shape; the provider calls the route's LoRA endpoint then.+ if (map.loras && input.loras?.length) Object.assign(out, loraFields(map.loras, input.loras));// Round 4: clicked points, keyframes, formats, Ken Burns, overlays, retiming, frames and 3D (research part 4).if (map.points && input.points?.length) out[map.points.key] = pointsValue(map.points.format, input.points);diff --git a/src/lib/catalog/plan.ts b/src/lib/catalog/plan.tsindex 46f2b694..6c152b31 100644--- a/src/lib/catalog/plan.ts+++ b/src/lib/catalog/plan.ts@@ -458,12 +458,13 @@ export function pricingAt(p: Pricing, now = Date.now()): Pricing {const CLIP_LENGTH_OPS = new Set<Operation>(["upscale-video", "interpolate", "sdr-to-hdr", "export-video"]);/** Rough USD estimate for a plan (BYO-key cloud runs). Open-source runs are free. */-export function estimateCost(model: ModelDef, params: GenParams, jobs = 1, op?: Operation): number | null {+export function estimateCost(model: ModelDef, params: GenParams, jobs = 1, op?: Operation, withLoras = false): number | null {if (model.engine === "open" || !model.pricing) return model.engine === "open" ? 0 : null;const p = model.pricing;const n = params.numOutputs ?? 1;const res = params.resolution ?? model.defaults?.resolution;- const usd = (res && p.byResolution && (p.byResolution[res] ?? p.byResolution[res.toLowerCase()])) || p.usd;+ // A run with LoRAs goes to the LoRA endpoint, which has its own price.+ const usd = withLoras && p.withLoras !== undefined ? p.withLoras : (res && p.byResolution && (p.byResolution[res] ?? p.byResolution[res.toLowerCase()])) || p.usd;let per = usd;const clip = op && CLIP_LENGTH_OPS.has(op) && params.sourceDuration && params.sourceDuration > 0 ? params.sourceDuration * (op === "interpolate" ? Math.max(1, params.slowdown ?? 1) : 1) : undefined;if (p.unit === "image") per = usd * n;diff --git a/src/lib/catalog/types.ts b/src/lib/catalog/types.tsindex b3b19d4d..e75c105d 100644--- a/src/lib/catalog/types.ts+++ b/src/lib/catalog/types.ts@@ -415,8 +415,15 @@ export interface FieldMap {* A frame count for routes that render only as many frames as asked (LTX 2.3 clean plate and HDR, VOID):* the clip's length (params.sourceDuration, else params.duration) × the frame rate (params.fps, else* `fps`), kept within min–max. Nothing is sent when the length is unknown (the API's default applies).+ * Also video models whose length is a frame count (Wan 2.2, LTX-2.3 22B), where `step` keeps the count at+ * step·n + 1 (Wan 4n+1, LTX 8n+1).*/- numFrames?: { key: string; fps: number; min?: number; max?: number };+ numFrames?: { key: string; fps: number; min?: number; max?: number; step?: number };+ /**+ * Width and height fields (Replicate's Z-Image LoRA model): the aspect ratio's shape with the area of a+ * `base`×`base` square (1024 when unset), in multiples of `multiple`, neither side above `max`.+ */+ size?: { width: string; height: string; multiple: number; max?: number; base?: number };/*** Limits the API checks on numeric fields Fuobe fills (round 4: target fps, slow motion, frame interval,* overlay position and scale, Ken Burns length…): a value is rounded when the field takes whole numbers@@ -551,6 +558,8 @@ export interface Pricing {* `param` is "targetFps" or a params.extra key (its control's default when unset); `values` maps a value to its factor.*/factors?: { param: string; values: Record<string, number> }[];+ /** The price per unit when the run carries LoRAs and goes to the route's LoRA endpoint (fal's /lora variants cost more). */+ withLoras?: number;}export interface ModelDef {diff --git a/src/server/generations.ts b/src/server/generations.tsindex 48eb52f1..3ad07319 100644--- a/src/server/generations.ts+++ b/src/server/generations.ts@@ -12,6 +12,7 @@ import { upscaleTier } from "@/lib/av/upscale";import { chainedWaitMessage, keyframeChain } from "@/lib/catalog/keyframes";import { estimateCost, inferOperation, planGeneration, routesFor } from "@/lib/catalog/plan";import { keepMatte } from "@/lib/catalog/payload";+import { fitLoras, lorasFit } from "@/lib/catalog/loras";import {LAST_FRAME_CHAIN,OPERATION_OUTPUT,@@ -20,6 +21,7 @@ import {type GenerationRequest,type MediaKind,type GenInput,+ type LoraRef,type ModelRoute,type OutputFile,type ProviderId,@@ -358,14 +360,16 @@ export function deleteGeneration(id: string): void {* `images` is how many images the run sends: a route whose list takes fewer (FieldMap.maxImages: Grok* Imagine Image takes 5 on fal, 10 on Higgsfield) gives way to one that takes them all, or says so.*/-export function chooseRoute(candidates: ModelRoute[], images = 0): { route: ModelRoute; demo: boolean } {+export function chooseRoute(candidates: ModelRoute[], images = 0, loras: LoraRef[] = []): { route: ModelRoute; demo: boolean } {// Honour the preferred cloud aggregator (Settings → API configuration) when a model is on several.const preferred = getSetting("cloudProvider");const routes = preferred === "auto" ? candidates : [...candidates].sort((a, b) => Number(b.provider === preferred) - Number(a.provider === preferred));const demo = getSetting("demoMode");if (demo === "on") return { route: routes[0], demo: true };const takes = (r: ModelRoute) => !r.map?.maxImages || images <= r.map.maxImages;- const real = routes.find((r) => routeReady(r) && takes(r));+ // A route that carries every LoRA wins (Replicate's Wan 2.2 takes one per expert, fal's takes a Mix);+ // otherwise the first ready one runs and fitLoras says which LoRAs it leaves out.+ const real = routes.find((r) => routeReady(r) && takes(r) && lorasFit(r, loras)) ?? routes.find((r) => routeReady(r) && takes(r));if (real) return { route: real, demo: false };const short = routes.find(routeReady);if (short) {@@ -422,7 +426,11 @@ function prepare(original: GenerationRequest) {// Checks planGeneration can't make without knowing the model's kind or the text ops' needs.if (plan.op === "color-match" && plan.model.kind === "video" && !req.inputs?.video) throw new Error("Add the video and a reference image");if (plan.op === "translate" && !plan.params.targetLanguage) throw new Error("Pick a language to translate into");- const { route, demo } = chooseRoute(routesFor(plan.model, plan.op), req.inputs?.images?.length ?? 0);+ const { route, demo } = chooseRoute(routesFor(plan.model, plan.op), req.inputs?.images?.length ?? 0, plan.loras);+ // What the cloud run can carry: a LoRA whose licence doesn't allow hosting stays on the GPU, and an API+ // takes at most so many (the plan's notes say which were left out). Open runs carry them all.+ const fitted = fitLoras(plan.loras, route);+ plan = { ...plan, loras: fitted.loras };// A route that can't batch (Higgsfield's Grok Imagine Image beside fal's num_images) runs one job per output.if (!demo && route.map && !route.map.numOutputs && plan.perJobOutputs > 1) {plan = { ...plan, jobs: plan.jobs * plan.perJobOutputs, perJobOutputs: 1, params: { ...plan.params, numOutputs: 1 } };@@ -430,14 +438,24 @@ function prepare(original: GenerationRequest) {const providerId: ProviderId = demo ? "mock" : route.provider;// A text step that runs on Ollama is free; only Claude costs money.const free = demo || (route.provider === "llm" && !llmUsesClaude(route));- return { req, plan, route, demo, providerId, cost: free ? 0 : estimateCost(plan.model, plan.params, 1, plan.op) };+ const withLoras = fitted.loras.length > 0 && !!route.loraEndpoint;+ return { req, plan, route, demo, providerId, notes: fitted.notes, cost: free ? 0 : estimateCost(plan.model, plan.params, 1, plan.op, withLoras) };}/** What a request would run as — model, operation, job count and cost — without starting it. */export function previewGeneration(req: GenerationRequest) {- const { plan, demo, providerId, cost } = prepare(req);- return { model: plan.model, op: plan.op, jobs: plan.jobs, outputs: plan.jobs * plan.perJobOutputs, demo, providerId, costUsd: cost === null ? null : cost * plan.jobs };+ const { plan, demo, providerId, cost, notes } = prepare(req);+ return {+ model: plan.model,+ op: plan.op,+ jobs: plan.jobs,+ outputs: plan.jobs * plan.perJobOutputs,+ demo,+ providerId,+ costUsd: cost === null ? null : cost * plan.jobs,+ ...(notes.length && { notes }),+ };}/** Preview a step that will wait for `deps` earlier steps: validated with placeholders in its chain slots, as createGenerations does. */diff --git a/src/server/providers/fal.ts b/src/server/providers/fal.tsindex 6d3ce6e7..3d0d3f72 100644--- a/src/server/providers/fal.ts+++ b/src/server/providers/fal.ts@@ -1,5 +1,6 @@import "server-only";import { createFalClient } from "@fal-ai/client";+import { loraEndpointFor, routeLoraField } from "@/lib/catalog/loras";import { buildPayload, extractOutputs, noOutputsError } from "@/lib/catalog/payload";import { getSetting } from "../settings";import { ProviderError, type ProviderAdapter } from "./types";@@ -58,11 +59,16 @@ export const falProvider: ProviderAdapter = {},async submit({ route, input }) {- const payload = buildPayload(route.map ?? {}, input);- // Trained identities (fal LoRA URLs) switch to the model's LoRA endpoint.- const loras = (input.loras ?? []).filter((l) => l.url);- const endpoint = loras.length && route.loraEndpoint ? route.loraEndpoint : route.endpoint;- if (endpoint !== route.endpoint) payload.loras = loras.map((l) => ({ path: l.url, scale: l.strength ?? 1 }));+ // LoRAs (trained identities, a recipe's looks and motions) go in the route's LoRA field (FieldMap.loras:+ // `transformer` per file on Wan 2.2, `weight_name`, at most the API's maximum) and switch to its LoRA endpoint.+ const map = { ...route.map, loras: routeLoraField(route) };+ const payload = buildPayload(map, input);+ let endpoint: string;+ try {+ endpoint = loraEndpointFor({ ...route, map }, input.loras);+ } catch (e) {+ throw new ProviderError((e as Error).message);+ }const res = (await falFetch(`${QUEUE}/${endpoint}`, {method: "POST",body: JSON.stringify(payload),diff --git a/src/server/providers/replicate.ts b/src/server/providers/replicate.tsindex 9482d84c..80fe229c 100644--- a/src/server/providers/replicate.ts+++ b/src/server/providers/replicate.ts@@ -1,4 +1,5 @@import "server-only";+import { loraEndpointFor } from "@/lib/catalog/loras";import { buildPayload, extractOutputs, noOutputsError } from "@/lib/catalog/payload";import { getSetting } from "../settings";import { toDataUri } from "../storage";@@ -49,7 +50,14 @@ export const replicateProvider: ProviderAdapter = {async submit({ route, input }) {const payload = buildPayload(route.map ?? {}, input);- const [slug, version] = route.endpoint.split(":");+ // LoRAs go in the route's own fields (lora_weights[] / one per Wan 2.2 expert) or its LoRA model.+ let endpoint: string;+ try {+ endpoint = loraEndpointFor(route, input.loras);+ } catch (e) {+ throw new ProviderError((e as Error).message);+ }+ const [slug, version] = endpoint.split(":");const res = (await (version? rFetch(`${API}/predictions`, { method: "POST", body: JSON.stringify({ version, input: payload }) }): rFetch(`${API}/models/${slug}/predictions`, { method: "POST", body: JSON.stringify({ input: payload }) }))) as {diff --git a/tests/cloud-catalog.test.ts b/tests/cloud-catalog.test.tsindex c97817b5..9944a6cb 100644--- a/tests/cloud-catalog.test.ts+++ b/tests/cloud-catalog.test.ts@@ -11,12 +11,25 @@ const research = ["paid-model-apis.json", "paid-model-apis-2.json", "paid-model-);const byId = new Map<string, Endpoint>();for (const e of research) byId.set(`${e.provider}:${e.endpoint}`, { ...byId.get(`${e.provider}:${e.endpoint}`), ...e });+// Originals (O1): the hosted open-weight endpoints that take LoRAs, and the plain endpoints of the same models.+const originals = JSON.parse(fs.readFileSync("docs/research/fuobe-originals-recipes-5.json", "utf8")) as {+ hostedLoraEndpoints: (Endpoint & { id: string })[];+ hostedBaseEndpoints: Endpoint[];+};+for (const e of originals.hostedLoraEndpoints) if (e.inputs) byId.set(`${e.provider}:${e.id}`, { ...e, endpoint: e.id, verified: true });+for (const e of originals.hostedBaseEndpoints) byId.set(`${e.provider}:${e.endpoint}`, e);+/** A Replicate model run by version ("owner/name:<version>") is researched under its name. */+const researched = (r: ModelRoute, endpoint = r.endpoint) => byId.get(`${r.provider}:${endpoint}`) ?? byId.get(`${r.provider}:${endpoint.split(":")[0]}`);/** Every provider field a FieldMap names (top-level part of dotted paths). */function fieldsOf(map: FieldMap): string[] {const out: string[] = [];for (const [k, v] of Object.entries(map)) {- if (k === "fixed" || k === "defaults" || k === "seedRange" || k === "maskFormat") continue;+ if (k === "fixed" || k === "defaults" || k === "seedRange" || k === "maskFormat" || k === "loras") continue;+ if (k === "size") {+ out.push(map.size!.width, map.size!.height);+ continue;+ }if (typeof v === "string") out.push(v);else if (v && typeof v === "object") {const o = v as Record<string, unknown>;@@ -114,7 +127,7 @@ describe("round-3 cloud models", () => {const bad: string[] = [];for (const { m, r } of routes) {if (r.endpoint.startsWith("chain:")) continue;- const e = byId.get(`${r.provider}:${r.endpoint}`);+ const e = researched(r);if (!e) {bad.push(`${m.id}: ${r.provider}:${r.endpoint} not in research`);continue;@@ -122,6 +135,19 @@ describe("round-3 cloud models", () => {if (ROUND3[m.id] && !e.verified) bad.push(`${m.id}: ${r.endpoint} unverified`);const inputs = Object.keys(e.inputs ?? {});for (const f of fieldsOf(r.map ?? {})) if (!inputs.includes(f)) bad.push(`${m.id}: ${r.endpoint} has no field ${f}`);+ // A run with LoRAs sends the same payload to the LoRA endpoint, plus its LoRA fields.+ if (r.loraEndpoint || r.map?.loras) {+ const le = researched(r, r.loraEndpoint ?? r.endpoint);+ if (!le) {+ bad.push(`${m.id}: LoRA endpoint ${r.loraEndpoint} not in research`);+ continue;+ }+ const loraInputs = Object.keys(le.inputs ?? {});+ const l = r.map?.loras;+ const loraFields = !l ? [] : l.shape === "items" ? [l.key] : l.shape === "arrays" ? [l.weights, l.scales] : l.shape === "single" ? [l.weights, l.scale] : [l.high.weights, l.high.scale, l.low.weights, l.low.scale];+ if (!l) bad.push(`${m.id}: ${r.endpoint} has a LoRA endpoint but no LoRA field`);+ for (const f of [...fieldsOf(r.map ?? {}), ...loraFields]) if (!loraInputs.includes(f)) bad.push(`${m.id}: ${r.loraEndpoint ?? r.endpoint} has no field ${f}`);+ }}expect(bad).toEqual([]);});diff --git a/tests/fal-lora.test.ts b/tests/fal-lora.test.tsnew file mode 100644index 00000000..c14ed414--- /dev/null+++ b/tests/fal-lora.test.ts@@ -0,0 +1,155 @@+import fs from "node:fs";+import os from "node:os";+import path from "node:path";+import { afterAll, describe, expect, it } from "vitest";+import { getModel } from "@/lib/catalog";+import { loraEntry, loraRef, fitLoras, loraFields, cloudPath, lorasFit } from "@/lib/catalog/loras";+import { buildPayload, numFramesValue } from "@/lib/catalog/payload";+import { estimateCost } from "@/lib/catalog/plan";+import type { GenInput, LoraRef, ModelRoute } from "@/lib/catalog/types";++// The fal adapter reads its key from the settings table: a throwaway database.+const dir = fs.mkdtempSync(path.join(os.tmpdir(), "fuobe-fal-lora-"));+process.env.FUOBE_DATA_DIR = dir;+const { falProvider } = await import("@/server/providers/fal");+afterAll(() => fs.rmSync(dir, { recursive: true, force: true }));++/** Submit through the fal adapter and return the URL and JSON body it posted. */+async function submit(route: ModelRoute, input: GenInput): Promise<{ url: string; body: Record<string, unknown> }> {+ const real = globalThis.fetch;+ let seen: { url: string; body: Record<string, unknown> } | undefined;+ globalThis.fetch = (async (url: string, init?: RequestInit) => {+ seen = { url: String(url), body: JSON.parse(String(init?.body ?? "{}")) };+ return new Response(JSON.stringify({ request_id: "r1", status_url: "s", response_url: "r", cancel_url: "c" }), { status: 200 });+ }) as typeof fetch;+ try {+ await falProvider.submit({ generationId: "g", model: getModel("wan-2-2-a14b-cloud")!, route, input });+ } finally {+ globalThis.fetch = real;+ }+ return seen!;+}++const route = (modelId: string, op: string, provider = "fal") => {+ const r = getModel(modelId)?.routes.find((x) => x.op === op && x.provider === provider);+ if (!r) throw new Error(`${modelId} has no ${provider} ${op} route`);+ return r;+};++const hf = (file: string, extra: Partial<LoraRef> = {}): LoraRef => ({ file, url: `https://huggingface.co/a/b/resolve/main/${file}`, strength: 1, ...extra });++describe("fal LoRA payloads (generated FieldMap.loras)", () => {+ it("sends transformer per file on Wan 2.2: the high/low pair on its experts, Wan 2.1 and single-file LoRAs on both", async () => {+ // The Overhead motion: a civitai high/low-noise pair, mirrored for the cloud.+ const overhead = ["civitai-2126493-camera-tilt-up-overhead", "civitai-2126538-camera-tilt-up-overhead"].map((k) => {+ const e = loraEntry(k)!;+ return { ...loraRef(e), hostedUrl: `https://v3.fal.media/files/${e.version}.safetensors` };+ });+ const wan21 = hf("squish_18.safetensors", { target: "both", strength: 0.8 });+ const trained = { file: "", url: "https://v3.fal.media/files/me.safetensors", strength: 6, weightName: "me.safetensors" };+ const r = route("wan-2-2-a14b-cloud", "i2v");+ const { url, body } = await submit(r, { prompt: "a cat", images: ["https://x/cat.png"], duration: 5, loras: [...overhead, wan21, trained] });+ expect(url).toBe("https://queue.fal.run/fal-ai/wan/v2.2-a14b/image-to-video/lora");+ expect(body.loras).toEqual([+ { path: overhead[0].hostedUrl, scale: 1, transformer: "high" },+ { path: overhead[1].hostedUrl, scale: 1, transformer: "low" },+ { path: wan21.url, scale: 0.8, transformer: "both" },+ // Scales stay inside the API's 0–4; weight_name goes with the item.+ { path: trained.url, scale: 4, transformer: "both", weight_name: "me.safetensors" },+ ]);+ // 16 fps, no doubled frames (fal interpolates to 32 fps by default), and 5 s = 81 frames (4n+1).+ expect(body.interpolator_model).toBe("none");+ expect(body.num_frames).toBe(81);+ });++ it("keeps the base endpoint and sends no loras when the run has none", async () => {+ const { url, body } = await submit(route("wan-2-2-a14b-cloud", "t2v"), { prompt: "a cat", duration: 10 });+ expect(url).toBe("https://queue.fal.run/fal-ai/wan/v2.2-a14b/text-to-video");+ expect(body.loras).toBeUndefined();+ expect(body.num_frames).toBe(161);+ });++ it("cuts to the API's maximum (3 on Z-Image) and says which LoRA it left out", async () => {+ const r = route("z-image-turbo-cloud", "t2i");+ expect(r.map?.loras).toMatchObject({ shape: "items", key: "loras", max: 3 });+ const four = ["awportrait", "lenovo", "grainscape", "realism"].map((k) => loraRef(loraEntry(k)!));+ const fitted = fitLoras(four, r);+ expect(fitted.loras.map((l) => l.file)).toEqual(four.slice(0, 3).map((l) => l.file));+ expect(fitted.notes).toEqual(["This API takes up to 3 LoRAs, so suayptalha Z-Image-Turbo Realism is left out"]);+ const { url, body } = await submit(r, { prompt: "portrait", loras: fitted.loras });+ expect(url).toBe("https://queue.fal.run/fal-ai/z-image/turbo/lora");+ expect(body.loras).toEqual(four.slice(0, 3).map((l) => ({ path: l.url, scale: l.strength })));+ // Even unfitted, the payload never carries more than the API takes.+ expect((loraFields(r.map!.loras!, four).loras as unknown[]).length).toBe(3);+ });++ it("drops LoRAs whose licence doesn't allow hosting and says so (they run only on the GPU)", () => {+ const r = route("wan-2-2-a14b-cloud", "i2v");+ const wiggle = loraRef(loraEntry("civitai-2490836-wiggle-redmond")!);+ expect(wiggle.licence?.hostedOk).toBe(false);+ const keep = hf("squish_18.safetensors", { target: "both" });+ const fitted = fitLoras([wiggle, keep], r);+ expect(fitted.loras).toEqual([keep]);+ expect(fitted.notes[0]).toMatch(/^Wiggle Redmond runs only on your GPU/);+ // Defensively, the payload drops it too.+ expect(loraFields(r.map!.loras!, [{ ...wiggle, hostedUrl: "https://v3.fal.media/x" }])).toEqual({});+ // The open engine carries every LoRA.+ expect(fitLoras([wiggle, keep], { provider: "comfyui" }).loras).toHaveLength(2);+ });++ it("never sends a civitai URL (the user's key stays home): only its mirror", () => {+ const y2k = loraRef(loraEntry("y2k")!);+ expect(cloudPath(y2k)).toBeUndefined();+ expect(cloudPath({ ...y2k, hostedUrl: "https://v3.fal.media/files/y2k.safetensors" })).toBe("https://v3.fal.media/files/y2k.safetensors");+ const map = route("z-image-turbo-cloud", "t2i").map!;+ expect(buildPayload(map, { prompt: "p", loras: [y2k] }).loras).toBeUndefined();+ // A gated Hugging Face file can't be fetched by fal either.+ expect(cloudPath(loraRef(loraEntry("ltx-2-3-22b-ic-lora-relight-1-0")!))).toBeUndefined();+ });++ it("always sends at least one LoRA to LTX-2.3's /lora endpoints, which require the list", async () => {+ const r = route("ltx-2-3-22b-cloud", "i2v");+ expect(r.map?.loras).toMatchObject({ shape: "items", required: true });+ const fpv = loraRef(loraEntry("ltx2-3-fpv-motion")!);+ expect(fpv.url).toMatch(/^https:\/\/huggingface\.co\//);+ const withOne = await submit(r, { prompt: "fly", images: ["https://x/a.png"], duration: 5, loras: [{ ...fpv, hostedUrl: fpv.url }] });+ expect(withOne.url).toBe("https://queue.fal.run/fal-ai/ltx-2.3-22b/image-to-video/lora");+ expect((withOne.body.loras as unknown[]).length).toBeGreaterThanOrEqual(1);+ // Prompt expansion would rewrite the prompt; 5 s at 24 fps = 121 frames (8n+1).+ expect(withOne.body.enable_prompt_expansion).toBe(false);+ expect(withOne.body.num_frames).toBe(121);+ // No LoRA left (all local-only): the plain endpoint, never an empty required list.+ const none = await submit(r, { prompt: "fly", images: ["https://x/a.png"], loras: [{ ...fpv, licence: { ...fpv.licence!, hostedOk: false } }] });+ expect(none.url).toBe("https://queue.fal.run/fal-ai/ltx-2.3-22b/image-to-video");+ expect(none.body.loras).toBeUndefined();+ // A route that is only the /lora endpoint refuses to run without one.+ const bare = { ...r, endpoint: "fal-ai/ltx-2.3-22b/image-to-video/lora", loraEndpoint: undefined };+ await expect(submit(bare, { prompt: "fly", images: ["https://x/a.png"] })).rejects.toThrow(/needs at least one LoRA/);+ });++ it("prices a run with LoRAs at the LoRA endpoint's rate", () => {+ const z = getModel("z-image-turbo-cloud")!;+ expect(z.pricing).toMatchObject({ unit: "megapixel", usd: 0.005, withLoras: 0.0085 });+ expect(estimateCost(z, {}, 1, "t2i")).toBe(0.005);+ expect(estimateCost(z, {}, 1, "t2i", true)).toBe(0.009);+ const wan = getModel("wan-2-2-a14b-cloud")!;+ expect(estimateCost(wan, { duration: 5, resolution: "480p" }, 1, "i2v")).toBe(0.2);+ expect(estimateCost(wan, { duration: 5, resolution: "480p" }, 1, "i2v", true)).toBe(0.5);+ });++ it("keeps frame counts in the 4n+1 / 8n+1 form inside the API's limits", () => {+ const f = { key: "num_frames", fps: 16, min: 17, max: 161, step: 4 };+ expect(numFramesValue(f, { duration: 5 })).toBe(81);+ expect(numFramesValue(f, { duration: 0.5 })).toBe(17);+ expect(numFramesValue(f, { duration: 30 })).toBe(161);+ expect(numFramesValue({ key: "num_frames", fps: 24, min: 9, max: 481, step: 8 }, { duration: 3 })).toBe(73);+ });++ it("fits a Mix on fal's Wan 2.2 but not on Replicate's one LoRA per expert", () => {+ const two = [hf("a.safetensors", { target: "high" }), hf("b.safetensors", { target: "high" })];+ expect(lorasFit(route("wan-2-2-a14b-cloud", "i2v"), two)).toBe(true);+ expect(lorasFit(route("wan-2-2-a14b-cloud", "i2v", "replicate"), two)).toBe(false);+ expect(lorasFit(route("wan-2-2-a14b-cloud", "i2v", "replicate"), [two[0], hf("c.safetensors", { target: "low" })])).toBe(true);+ });+});+diff --git a/tests/replicate-lora.test.ts b/tests/replicate-lora.test.tsnew file mode 100644index 00000000..026338a9--- /dev/null+++ b/tests/replicate-lora.test.ts@@ -0,0 +1,99 @@+import fs from "node:fs";+import os from "node:os";+import path from "node:path";+import { afterAll, describe, expect, it } from "vitest";+import { getModel } from "@/lib/catalog";+import { fitLoras, loraEntry, loraRef } from "@/lib/catalog/loras";+import type { GenInput, LoraRef, ModelRoute } from "@/lib/catalog/types";++// Providers and route choice read keys and preferences from the settings table: a throwaway database.+const dir = fs.mkdtempSync(path.join(os.tmpdir(), "fuobe-replicate-lora-"));+process.env.FUOBE_DATA_DIR = dir;+const { replicateProvider } = await import("@/server/providers/replicate");+const { setSetting } = await import("@/server/settings");+const { chooseRoute } = await import("@/server/generations");+afterAll(() => fs.rmSync(dir, { recursive: true, force: true }));++async function submit(route: ModelRoute, input: GenInput): Promise<{ url: string; body: Record<string, unknown> }> {+ const real = globalThis.fetch;+ let seen: { url: string; body: Record<string, unknown> } | undefined;+ globalThis.fetch = (async (url: string, init?: RequestInit) => {+ seen = { url: String(url), body: JSON.parse(String(init?.body ?? "{}")) };+ return new Response(JSON.stringify({ id: "p1" }), { status: 201 });+ }) as typeof fetch;+ try {+ await replicateProvider.submit({ generationId: "g", model: getModel("z-image-turbo-cloud")!, route, input });+ } finally {+ globalThis.fetch = real;+ }+ return seen!;+}++const route = (modelId: string, op: string, provider = "replicate") => {+ const r = getModel(modelId)?.routes.find((x) => x.op === op && x.provider === provider);+ if (!r) throw new Error(`${modelId} has no ${provider} ${op} route`);+ return r;+};+const hf = (file: string, extra: Partial<LoraRef> = {}): LoraRef => ({ file, url: `https://huggingface.co/a/b/resolve/main/${file}`, strength: 1, ...extra });++describe("Replicate LoRA payloads", () => {+ it("prunaai/z-image-turbo-lora: lora_weights[] and lora_scales[], run by its pinned version, size from the aspect ratio", async () => {+ const r = route("z-image-turbo-cloud", "t2i");+ expect(r.endpoint).toMatch(/^prunaai\/z-image-turbo-lora:[0-9a-f]{64}$/);+ const looks = ["awportrait", "grainscape"].map((k) => loraRef(loraEntry(k)!));+ const { url, body } = await submit(r, { prompt: "a portrait", aspectRatio: "16:9", seed: 7, loras: looks });+ // A community model: POST /v1/predictions with the version.+ expect(url).toBe("https://api.replicate.com/v1/predictions");+ expect(body.version).toBe(r.endpoint.split(":")[1]);+ const input = body.input as Record<string, unknown>;+ expect(input.lora_weights).toEqual(looks.map((l) => l.url));+ expect(input.lora_scales).toEqual([0.6, 0.5]);+ expect(input).toMatchObject({ prompt: "a portrait", seed: 7, width: 1360, height: 768 });+ });++ it("wan-2.2 fast: one LoRA per expert (lora_weights_transformer = high, _2 = low), a both-LoRA fills the two", async () => {+ const r = route("wan-2-2-a14b-cloud", "i2v");+ const pair = ["civitai-2126493-camera-tilt-up-overhead", "civitai-2126538-camera-tilt-up-overhead"].map((k) => ({ ...loraRef(loraEntry(k)!), hostedUrl: `https://replicate.delivery/${k}.safetensors` }));+ const { url, body } = await submit(r, { prompt: "rise", images: ["https://x/a.png"], duration: 5, loras: pair });+ expect(url).toBe("https://api.replicate.com/v1/models/wan-video/wan-2.2-i2v-fast/predictions");+ expect(body.input).toMatchObject({+ lora_weights_transformer: pair[0].hostedUrl,+ lora_scale_transformer: 1,+ lora_weights_transformer_2: pair[1].hostedUrl,+ lora_scale_transformer_2: 1,+ num_frames: 81,+ });+ const both = await submit(r, { prompt: "squish", images: ["https://x/a.png"], loras: [hf("squish_18.safetensors", { target: "both", strength: 0.7 })] });+ expect(both.body.input).toMatchObject({ lora_weights_transformer: expect.stringContaining("squish"), lora_weights_transformer_2: expect.stringContaining("squish"), lora_scale_transformer_2: 0.7 });+ });++ it("leaves out what doesn't fit one LoRA per expert, with a note", () => {+ const r = route("wan-2-2-a14b-cloud", "i2v");+ const motion = hf("motion_high.safetensors", { target: "high" });+ const effect = hf("effect_high.safetensors", { target: "high" });+ const fitted = fitLoras([motion, effect], r);+ expect(fitted.loras).toEqual([motion]);+ expect(fitted.notes).toEqual(["This API takes one LoRA per expert, so the effect_high LoRA is left out"]);+ });++ it("qwen-image-edit-2511: a single LoRA in lora_weights / lora_scale", async () => {+ const r = route("qwen-image-edit-2511-cloud", "edit");+ const { body } = await submit(r, { prompt: "relight", images: ["https://x/a.png"], loras: [hf("relight.safetensors", { strength: 0.9 })] });+ expect(body.input).toMatchObject({ image: ["https://x/a.png"], lora_weights: expect.stringContaining("relight"), lora_scale: 0.9 });+ });++ it("runs a Mix on fal when Replicate's one-per-expert model can't carry it, even with Replicate preferred", () => {+ setSetting("falKey", "id:secret");+ setSetting("replicateToken", "r8_test");+ setSetting("cloudProvider", "replicate");+ setSetting("demoMode", "auto");+ const routes = getModel("wan-2-2-a14b-cloud")!.routes.filter((r) => r.op === "i2v");+ const one = [hf("motion_high.safetensors", { target: "high" })];+ const mix = [...one, hf("effect_high.safetensors", { target: "high" })];+ expect(chooseRoute(routes, 1, one).route.provider).toBe("replicate");+ expect(chooseRoute(routes, 1, mix).route.provider).toBe("fal");+ // Local-only LoRAs don't count: they never go to the cloud.+ const wiggle = loraRef(loraEntry("civitai-2490836-wiggle-redmond")!);+ expect(chooseRoute(routes, 1, [...one, wiggle]).route.provider).toBe("replicate");+ });+});