The all-in-one local AI studio for your desktop: chat, image and video generation and a coding agent in one free, open source app. Windows and Linux. No Docker, no terminal, no cloud required.
TypeScript agentai-chatai-studioall-in-onecoding-agentdesktop-appfluximage-generationlinuxllmlocal-ailocal-llmopen-sourceprivacyself-hostedstable-diffusionuncensoreduncensored-aivideo-generationwindows
fix(create): picker, starter card and submit share one video-lane rule
purple7a5fb0df5765
diff --git a/src/api/__tests__/video-lane-models.test.ts b/src/api/__tests__/video-lane-models.test.tsnew file mode 100644index 00000000..a9162d37--- /dev/null+++ b/src/api/__tests__/video-lane-models.test.ts@@ -0,0 +1,44 @@+/** Picker (ModelChip) and the missing-models gate (Stage) share+ * videoLaneModels(). Before they did, a box whose only video model was SVD+ * showed "No matches" in the T2V picker while the gate counted "1 video+ * model" and withheld the starter-bundle card (David 2026-08-01). */+import { describe, it, expect } from 'vitest'+import { canRunVideoIntent, videoLaneModels, type ClassifiedModel } from '../comfyui'++const m = (name: string): ClassifiedModel => ({ name, type: 'unknown', source: 'checkpoint' })++const SVD_ONLY = [m('svd_xt_1_1.safetensors')]+const NSFW_GGUF = m('nsfw_wan_14b_e15_q4_k.gguf')+const RAPID_AIO = m('wan2.2-i2v-rapid-aio-v10-nsfw-Q4_K_M.gguf')++describe('videoLaneModels', () => {+ it('the T2V lane drops i2v-only models, so SVD alone means an empty lane', () => {+ expect(videoLaneModels(SVD_ONLY, 'video')).toEqual([])+ })++ it('the T2V lane keeps a t2v finetune like the NSFW Wan GGUF', () => {+ expect(videoLaneModels([...SVD_ONLY, NSFW_GGUF], 'video')).toEqual([NSFW_GGUF])+ })++ it('Animate keeps SVD and the rapid AIO i2v merge, drops the pure t2v', () => {+ const got = videoLaneModels([...SVD_ONLY, NSFW_GGUF, RAPID_AIO], 'animate')+ expect(got).toEqual([...SVD_ONLY, RAPID_AIO])+ })++ it('Extend gates like Animate (i2v-capable)', () => {+ expect(videoLaneModels([NSFW_GGUF], 'extend')).toEqual([])+ expect(videoLaneModels([RAPID_AIO], 'extend')).toEqual([RAPID_AIO])+ })+})++describe('canRunVideoIntent (submit uses this before the model list arrives)', () => {+ it('a persisted SVD pick must not reach a T2V build, but may Animate', () => {+ expect(canRunVideoIntent('svd_xt_1_1.safetensors', 'video')).toBe(false)+ expect(canRunVideoIntent('svd_xt_1_1.safetensors', 'animate')).toBe(true)+ })++ it('the NSFW Wan GGUF is the mirror image: T2V yes, Animate no', () => {+ expect(canRunVideoIntent(NSFW_GGUF.name, 'video')).toBe(true)+ expect(canRunVideoIntent(NSFW_GGUF.name, 'animate')).toBe(false)+ })+})diff --git a/src/api/comfyui.ts b/src/api/comfyui.tsindex f0e99e5d..1e9be2d8 100644--- a/src/api/comfyui.ts+++ b/src/api/comfyui.ts@@ -270,6 +270,22 @@ export function isT2VCapable(name: string): boolean {return true}+/** Can this model run the given video intent? Animate/Extend feed a start+ * image (i2v), everything else on the video lane is a text-to-video run.+ * ONE rule for the picker, the starter-bundle gate and submit: whenever two+ * of them disagreed a real user hit a wall. SVD-only boxes showed+ * "No matches" yet never offered the starter bundle, and a fresh boot+ * submitted a persisted SVD pick into the T2V lane, which builds SVD's+ * LoadImage graph and dies on "Custom validation failed" (David 2026-08-01). */+export function canRunVideoIntent(name: string, intent: string): boolean {+ return intent === 'animate' || intent === 'extend' ? isI2VModel(name) : isT2VCapable(name)+}++/** The video models the CURRENT intent can actually run (see canRunVideoIntent). */+export function videoLaneModels(list: ClassifiedModel[], intent: string): ClassifiedModel[] {+ return list.filter((m) => canRunVideoIntent(m.name, intent))+}+// ─── Default generation parameters per model type ───export interface ModelTypeDefaults {diff --git a/src/components/create/experimental/ModelChip.tsx b/src/components/create/experimental/ModelChip.tsxindex 4f211d44..6d588833 100644--- a/src/components/create/experimental/ModelChip.tsx+++ b/src/components/create/experimental/ModelChip.tsx@@ -4,7 +4,7 @@ import { useSettingsStore } from '../../../stores/settingsStore'import { useUIStore } from '../../../stores/uiStore'import { Select, type SelectOption } from '../ui/Select'import { TYPE_BADGE } from './badges'-import { isI2VModel, isT2VCapable, resolveLocalOpPick } from '../../../api/comfyui'+import { resolveLocalOpPick, videoLaneModels } from '../../../api/comfyui'const CLOUD_BADGE = { label: 'Cloud', color: 'bg-violet-500/15 text-violet-500 dark:text-violet-200' }@@ -113,12 +113,9 @@ function LocalModelChip() {// Mirror the cloud picker's op-gating (David 2026-07-17: "only offer models// that can actually do it"): Animate/Extend list i2v-capable local models,// Video lists t2v-capable ones (SVD/FramePack are i2v-only and drop there).+ // Shared with Stage's missing-models gate so card and picker cannot drift.const rawList = isVideo ? videoModelList : imageModelList- const list = laneList ?? (!isVideo- ? rawList- : intent === 'animate' || intent === 'extend'- ? rawList.filter((m) => isI2VModel(m.name))- : rawList.filter((m) => isT2VCapable(m.name)))+ const list = laneList ?? (!isVideo ? rawList : videoLaneModels(rawList, intent))const stored = laneList ? localOpModel : (isVideo ? videoModel : imageModel)// Reflect the model the run will really use — a leftover pick the current// op can't perform must not show as "selected". Lanes share the submit-sidediff --git a/src/components/create/experimental/Stage.tsx b/src/components/create/experimental/Stage.tsxindex ddef9482..9a1de73e 100644--- a/src/components/create/experimental/Stage.tsx+++ b/src/components/create/experimental/Stage.tsx@@ -12,6 +12,7 @@ import { loadImageRef } from './loadImage'import { galleryItemUrl, fetchGalleryItemBlob, recoverGalleryUrl } from './galleryUrl'import { InstallCancelled } from '../../../lib/bundle-install'import { isMlxImageHost } from '../../../api/mlx-image'+import { videoLaneModels } from '../../../api/comfyui'interface Props {displayed?: GalleryItem@@ -49,9 +50,14 @@ export function Stage({ displayed, onOpenMaskEditor, onEditResult, onFullscreen// one-click starter-bundle card. connected === false also gates — the same// button installs ComfyUI itself first. connected === null (still probing)// gates nothing, so the card never flashes during startup.+ // "Missing" for the video lane must use the same op-gating as the picker:+ // SVD and FramePack are i2v-only, so a box whose only video model was SVD+ // passed a bare length check and never offered the starter bundle, while+ // the T2V picker showed "No matches" (David 2026-08-01).+ const videoLaneList = videoLaneModels(videoModelList, intent)const listForKind: Record<NonNullable<typeof meta.requiresModels>, unknown[]> = {image: imageModelList,- video: videoModelList,+ video: videoLaneList,audio: audioModelList,lipsync: lipsyncModelList,motion: motionModelList,diff --git a/src/hooks/useCreate.ts b/src/hooks/useCreate.tsindex 3f2f3d29..7262a92a 100644--- a/src/hooks/useCreate.ts+++ b/src/hooks/useCreate.ts@@ -19,9 +19,10 @@ import {isPromptQueued,buildTxt2ImgWorkflow,buildTxt2VidWorkflow,+ canRunVideoIntent,classifyModel,isI2VModel,- isT2VCapable,+ videoLaneModels,extractComfyOutputFiles,galleryTypeForFile,MODEL_TYPE_DEFAULTS as COMFY_MODEL_DEFAULTS,@@ -650,12 +651,19 @@ export function useCreate() {// user never saw. Apply the picker's coercion here too (same one-rule// philosophy as the cloud op resolver after take-01).if (!localOp && mode === 'video' && state.videoModelList.length > 0) {- const capable = intent === 'animate' || intent === 'extend'- ? state.videoModelList.filter((m) => isI2VModel(m.name))- : state.videoModelList.filter((m) => isT2VCapable(m.name))+ const capable = videoLaneModels(state.videoModelList, intent)if (capable.length > 0 && !capable.some((m) => m.name === activeModel)) {activeModel = capable[0].name}+ } else if (!localOp && mode === 'video' && !canRunVideoIntent(activeModel, intent)) {+ // The list has not arrived yet (fresh boot, ComfyUI still waking). The+ // coercion above cannot run, and a persisted pick the lane cannot use+ // must not reach the builder: that is how a T2V run right after app+ // start went out as SVD's LoadImage graph and ComfyUI answered+ // "Node 2 (LoadImage): Custom validation failed" while the chip already+ // showed a capable model (David 2026-08-02).+ setError('Video models are still loading. Give it a few seconds and hit Create again.')+ return}// Always re-classify from model name to avoid stale typeconst imageModelType = classifyModel(activeModel)