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
Handoff: reports of the packages merged since the last checkpoint, and the queue's finished stages
Claude2d5b9eafd69b
diff --git a/docs/handoff/queue.json b/docs/handoff/queue.jsonindex 7312ffea..fd73bd98 100644--- a/docs/handoff/queue.json+++ b/docs/handoff/queue.json@@ -63,11 +63,40 @@},"wip": {"acc-3": "o/acc-3 on origin (head 3106848, one WIP commit for the old accounts lane) is dropped work: the owner's 10-30 decision drops the acc-* lane, so nothing builds on it. The owner may delete the branch (git push origin --delete o/acc-3). The next accounts work starts from a new plan around main's public sign-up.",- "idol-1": "Research 10 (2026-11-01): Idol is now hosted on fal (speridlabs/idol, since 2026-10-30), so this brief's \"no cloud half\" is out of date: check fal's endpoint and schema, and build the cloud route with what it supports (docs/research/new-models-10.md, section 5).",- "n7-3-regenerate-2k": "Research 10 (2026-11-01): ComfyUI core merged an H3 latent upscaler and a Sol-H3-VAE loader on 2026-10-28; check whether the installed ComfyUI has them before adding a latent-upscaler pack (docs/research/new-models-10.md, section 5).",- "blockout-film": "Research 10 (2026-11-01): fal hosts minimax/h3-max/3d-to-video, and SolarRenderer H3 LoRAs do the same task on the open engine; weigh them for both engines (docs/research/new-models-10.md, section 5)."+ "idol-1": "Research 10 (2026-11-01): Idol is now hosted on fal (speridlabs/idol, since 2026-10-30), so this brief's \"no cloud half\" is out of date: check fal's endpoint and schema, and build the cloud route with what it supports (docs/research/new-models-10.md, section 5)."+ },+ "done": {+ "nm10-qwen21-fast": {+ "impl": {+ "branch": "o/nm10-qwen21-fast",+ "summary": "Qwen-Image 2.1 on the open engine now has Options → Speed (Draft 2 steps with DMD2 v1.5, Fast 4 steps with LightX2V Lightning, 'Fast · writes the details' 6 steps with Pruna P-Q-Image v0.2 upsampled, Turbo 8 steps for edits only, Full 25 steps as the default), Options → GPU (Zen Image Edit's 0.8B encoder, chosen automatically below 24 GB of VRAM for text to image and edits), and Options → Decoder (Clean = Texture-Fix VAE, off by default). This works in the Image, Edit and Inpaint studios and on the Canvas node. On your GPU, Storyboard's next frames now run on a new qwen-image-21-next-scene graph with akhaliq's 2.1 Next-Scene LoRA, with a 'Classic' pill to go back to the 2509 graph; the cloud keeps 2509 because 2.1 isn't hosted. The /connect board has an 'Image on a 16 GB GPU' row. Each new LoRA, the small-GPU and next-scene models and the Zen pack has a licence row, switched on. All of this is open-engine only. No GPU was available, so speed and quality claims are the authors'.",+ "built": [+ "13 hand-built ComfyUI graphs, each the owner's base graph plus one LoRA and a ManualSigmas branch (LoraLoaderModelOnly → CFGGuider cfg 1 + euler + ManualSigmas + SamplerCustomAdvanced): qwen-image-21-{t2i,edit}-{draft,fast,details}, qwen-image-21-{inpaint,outpaint}-{draft,fast}; also qwen-image-21-next-scene (2.1 edit + Next-Scene step2500 LoRA at 0.7, ImageBlur 0.5 px on the previous panel, 28 steps) and qwen-image-21-{t2i,edit}-small (recoilme Zen nodes, int8 DiT, ModelSamplingAuraFlow shift 5). They are in library.spec.mjs (qwen21Tier helper), KNOWN_MODELS, model-pins.json (revision/size/sha256) and packs.json (zen-image-edit-comfyui @ 7a29e58c), and requirements.json was rebuilt. The t2i, edit and next-scene graphs (7) pass the live CPU ComfyUI /prompt check (validated:true). The inpaint/outpaint tiers and the Zen graphs stay unvalidated because the server lacks the AusBoss and Zen packs.",+ "Every Qwen-Image 2.1 graph (the owner's t2i/edit/turbo-edit/inpaint/outpaint and the new ones) gets a `vae` binding and lists Texture-Fix VAE @ 9a10df81 as an optional model. New binding keys: vae and sigmas. The owner's inpaint/outpaint spec entries now declare packs:['ausboss-nodes'] so they build on the CPU server.",+ "src/lib/qwen21-speed.ts (pure): the tier and small-GPU graph tables, QWEN21_SPEED/GPU/DECODER controls, smallGpu(<24 GB), qwen21Graph(), lightningSigmas(w,h) (the card's exponential dynamic shift per canvas; 1 MP = 1.0, 0.857192, 0.666756, 0.400096, 0) and speedLora(). resolveWorkflowId (comfy-variants.ts) applies it and takes vramGb. The provider passes VRAM from /system_stats (comfyVramGb, or the computer tab's vramBytes), binds Lightning sigmas for the canvas, strips the speed/gpu/decoder keys and drops unused Zen reference slots. The GPU gate passes the last snapshot's VRAM.",+ "Catalog: controls on oss-qwen-image-21 (Speed/GPU/Decoder) and oss-qwen-image-21-turbo (Decoder). New hidden ModelDefs oss-qwen-image-21-small (tagline: English prompts only, numbers on signs can be wrong) and oss-qwen-image-21-next-scene (options.loras = the Next-Scene LoRA, so its switch holds the model). Controls gained per-value `ops`; controlsFor() in src/lib/composer.ts filters by op (no Turbo for new pictures; no GPU choice on inpaint/expand). Composer and Canvas pass op. Edit and Inpaint studios get the 'Options' title. A control with long labels now takes its own row so the value reads in full at 390 px.",+ "A speed whose LoRA is switched off in Models & licences is refused in prepare. The owner sees the switch; accounts see a plain message.",+ "Storyboard: STORYBOARD_MODELS.open.next = oss-qwen-image-21-next-scene; STORYBOARD_NEXT_SCENE ('qwen-21' | 'classic') in the lib, StoryboardBodySchema.nextScene, and a 'Qwen-Image 2.1 / Classic' pill on the open engine (absent in the cloud).",+ "/connect: STUDIO_ROWS row '/image/small-gpu' ('Image on a 16 GB GPU', steps t2i+edit on the small model). Its page redirects to /image, because the plan route's REF regex takes no query string.",+ "Licences: 4 adapterLoras in docs/research/fuobe-originals-recipes-5.json, generated into the LoRA library (DMD2 v1.5 Qwen Research; Lightning 'not stated in the repository'; Pruna Qwen Research; Next-Scene Apache-2.0); NODE_PACKS row for zen-image-edit-comfyui (Apache-2.0).",+ "Research: new-models-10.md §6.7 now has a 'Checked at the sources' list, and the licence line was corrected.",+ "Tests: tests/qwen21-fast.test.ts (18) and the browser check tests/e2e/qwen21-fast.mjs."+ ],+ "tests": "Full Vitest suite after merging the moved base (--maxWorkers=2, FUOBE_ACCOUNT_DISK_FREE_GB=1): 4941 passed, 6 failed, 3 skipped. All 6 failures are the known failures from main: comfy-reuse, dop-originals, preset-featured, soul-runs ×2, split-soundtrack. New tests/qwen21-fast.test.ts (18) covers each tier's LoRA, strength, sigmas and unchanged base nodes, the pins and sizes, the requirements entries, the Lightning shift, resolveWorkflowId per op and speed, the VRAM chooser (16/23.6/24/undefined, large/small override, speed beats small), controls and op filtering, Decoder→vae via controlSets, prepareWorkflow (2K Lightning sigmas, clean VAE, the Zen edit dropping unused refs, chosen by VRAM), refusal when the speed LoRA is off, the Zen graphs, pack and firstRun notes, the board row, storyboard mapping incl. classic and cloud, the next-scene graph (blur, LoRA not doubled, prefix once, ref dropped), and the licence rows. Existing tests updated for the intended changes: storyboard and popcorn-looks (new next model), open-engine (speed/gpu pick the graph), model-access-listings (181 LoRAs), and comfy-library-4's unvalidated list (6 ids inserted in manifest order, as video-regenerate-h3 was). The ComfyUI /prompt check ran live on 127.0.0.1:8188 for 7 graphs (--shared). Browser check: tests/e2e/qwen21-fast.mjs on pnpm dev -p 3471 in demo mode, 1440 and 390 px, light and dark — Image and Edit Options (Speed list per op, GPU, Decoder), Storyboard pill on open and absent on cloud, no sideways scroll; all passed. Server stopped and .next deleted. tsc and eslint are clean on the changed files.",+ "left": [+ "Nothing ran on a GPU: no tier's speed or quality is measured, and the claims are the authors'. Each graph needs a real render, especially Lightning and Pruna on the int8 DiT, the speed LoRAs stacked on the outpaint LoRA, and Zen on the int8 DiT (the author's graphs load bf16) at 16 GB.",+ "Zen route: the adapter is a GitHub release asset read by path (models/adapter_v12.safetensors), and Qwen3.5-0.8B downloads by HF id on first run. Both appear only as firstRun notes in the pre-flight (not as tracked downloads). It needs the zen-image-edit-comfyui pack, which is not installed on the validation server, so it is unvalidated.",+ "The inpaint/outpaint speed graphs need ausboss-nodes, which is not on the validation server, so they are unvalidated.",+ "The owner's qwen-image-21-t2i/edit/turbo-edit pass the /prompt check, but they stay validated:false as the owner's tests/open-qwen-image-21 requires ('until it runs on the GPU').",+ "Cinema has no 'next scene' step at base, so only Storyboard moved. Cinema's still edits already run on oss-qwen-image-21. Whether Cinema's UI shows the model's Options was not checked.",+ "Not wired: Pruna's 6-step preservation adapter (only 'upsampled' is offered), a Lightning/Zen combination, and per-tier Zen graphs. Live edit still loads DMD2 v1 (main's area). An edit's Lightning schedule follows image 1 only when its header size is known; otherwise it uses the 1 MP schedule.",+ "CREDITS.md was not regenerated: scripts/credits.mjs crashes at base (preset-recipe-book.json needs an import attribute). It should be rerun once main fixes that."+ ],+ "docsNotes": "STATUS.md: Qwen-Image 2.1 on your GPU has Options → Speed (Draft/Fast/Fast·details/Turbo for edits/Full), GPU (small encoder automatically under 24 GB, English only), and Decoder (Clean, off). Storyboard's next frames on your GPU use Qwen-Image 2.1 + the 2.1 Next-Scene LoRA, with Classic = Qwen-Image-Edit 2509; the cloud is unchanged. ARCHITECTURE.md: src/lib/qwen21-speed.ts holds the tier and small-GPU tables that resolveWorkflowId reads (provider and gate alike). VariantRequest.vramGb comes from /system_stats (provider) or the pre-flight snapshot (gate). Controls can carry per-value `ops` (controlsFor in src/lib/composer.ts). The 'vae' and 'sigmas' binding keys are new. scripts/comfy/README.md could list the 13 nm10-qwen21-fast graphs and the zen-image-edit-comfyui pack (not on the validation server). Where the brief was out of date: the H3 tier chooser hadn't landed, so the chooser is local. 'Chosen by binding' became one graph per tier, picked like H3's Quality, so the pre-flight sees each tier's own files. Fun Acc is a PDD export, not a plain LoRA, so Fast uses Lightning. The Zen adapter isn't on HF. DMD2 has a v1.5, which is used. The Next-Scene card now reads apache-2.0. Cinema has no next-scene step.",+ "blocked": ""+ }+ }},- "done": {},"packages": {"n7-2-layout-mode": {"title": "N7 2: Layout mode in the Image studio, Edit layout on results, Import and Export",diff --git a/docs/handoff/reports/blockout-film.json b/docs/handoff/reports/blockout-film.jsonnew file mode 100644index 00000000..88752aae--- /dev/null+++ b/docs/handoff/reports/blockout-film.json@@ -0,0 +1,190 @@+{+ "key": "blockout-film",+ "impl": {+ "branch": "o/blockout-film",+ "summary": "Blockout to film is built and pushed (8 commits on claude/fuobe-parity-4 at 6bcb1e63). You can upload a grey-box render from any 3D app, build one in the browser, or use the 3D scene's fly path as a blockout. Beats come from markers. Reference stills each get a role. The prompt is compiled in the Horror-scene workflow's sections and can be edited. Cloud: Seedance 2.5 reference mode, or MiniMax H3 Max 3D to video under its own name; a blockout too long for one call is cut into shots at the markers, each shot gets the previous shot's last frame as a still, and the shots are joined. Open engine: a new Wan 2.2 Fun VACE graph driven by the blockout's own depth, starting from a first frame drawn from the stills, in 81-frame windows that are chained and joined. Also placed in the Cinema composer, the 3D scene viewer, a Canvas template, Assist/MCP and the GPU board.",+ "built": [+ "src/lib/blockout.ts (pure): the builder's scene (box, wall, floor, doorway, stairs, door on a hinge, mannequin, mesh), primitive keys, camera keys (eased moves, lens, deterministic handheld shake), timing markers, the corridor-and-door example (Fuobe's own), normalizeScene, beatsFrom / normalizeBeats, reference roles with role sentences, compileBlockoutPrompt (seedance: @Video1/@Image1… in Subject/Action 'a–b s — beat: …'/Camera/Style/Constraints/Audio/No; h3: no tags, capped at 2000 chars; open: a short Wan prompt), blockoutFramePrompt, beatsIn, splitShots (cut at markers within each model's limit), depthWindows (81 frames at 16 fps, each window starting on the previous one's last frame, 4n+1 frames).",+ "Catalog: Cinema action 'blockout' (CinemaGenerateInput.blockout, planBlockout, blockoutPrompt, blockoutTake, BLOCKOUT_MODELS / BLOCKOUT_SHOTS, feature cinema-blockout, take info), the server schema (BlockoutSchema: /api/files refs only, at most 60 s), recordTakes keeps the blockout facts.",+ "New hosted helper minimax-h3-max-3d (fal minimax/h3-max/3d-to-video, op v2v). Its research record was added to paid-model-apis-4.json from fal's OpenAPI read today, and generated by scripts/gen-cloud-models.py. Pricing gained perRequest and minSeconds ($0.50 processing fee per request, at least 5 s billed per shot).",+ "New ComfyUI graph video-blockout-wan22-fun-vace (hand-built; the restyle graph without Depth Anything 3, with the depth video as the control and silent output) and the open model oss-wan22-vace-blockout (v2v + ref2v). Validated against the CPU ComfyUI with --shared. Manifest header and object_info.subset.json were restored to their earlier values after the build/validate wrote the local ComfyUI 0.41's details over them, and requirements.json was rebuilt. No new node packs or model files.",+ "Browser: blockout-engine.ts (three.js: orbit view with a move/turn gizmo, shot-camera view letterboxed to the frame, walking mannequin, GLB meshes from the Library shown in grey, grey render and depth render with near = bright), blockout-builder.tsx (Build/Piece/Camera/Beats tabs, timeline with play, scrub, camera-key and marker ticks), blockout-panel.tsx (upload or build, optional depth pass, beats with words, stills from upload/Elements/Soul Cast/Soul Location/Library with a role each, style/sounds/No/rules, cloud model choice, quality, sound toggle, editable compiled prompt, notes, price, 'Film it', and a 'Sound for video' next step for silent results). A Blockout chip in the composer, 'Use as blockout' in the 3D scene viewer (renders the path at 24 fps), and /cinema/<id>?blockout=1 opens the panel.",+ "src/lib/mp4.ts: an MP4 (H.264) writer, because Seedance takes reference clips as MP4/MOV only. src/components/cinema/video-encode.ts: the fly path's VP8/WebM encoders moved here unchanged, plus encodeMp4 / encodeFrames.",+ "Canvas: a 'Blockout → film' template that builds per engine (cloud: Seedance 2.5 ref2v with the blockout in a new Clips port that ref2v models taking clips now show, three stills and the compiled beats; open: Qwen first frame, then the depth graph for one window). The Box icon is registered.",+ "Assist/MCP: a blockout_film tool that plans with Cinema's planBlockout and runs as a Library pipeline; it is named in Assist's system prompt.",+ "GPU pre-flight board: a 'Blockout to film' row (href /cinema?blockout=1) on video-blockout-wan22-fun-vace, qwen-image-edit-2511-multi, video-segment-resample, frame-extract, video-concat-encoded.",+ "Research: new-models-10.json marks H3 Max 3D to video as built (schema re-read) and records SolarRenderer as re-read at its primary sources."+ ],+ "tests": "FULL Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 288 files, 4596 passed, 3 skipped, 0 failed. tsc clean; eslint 0 errors (1 warning, already in scripts/comfy/library.spec.mjs). New tests: tests/blockout.test.ts (32 tests: scene maths, shake, lens, normalizeScene, beats, prompt sections and @ tags, H3 2000-character cap, roles, shot splitting, depth windows, cloud plans for one shot / many shots / H3, open plans with and without depth, pricing incl. the H3 fee and minimum, H3 and Seedance payloads, binding of the new graph, the Cinema API in demo, the schema refusing bad input, the Canvas template, the GPU row, Assist/MCP plan and run), tests/mp4.test.ts (box layout, plus ffmpeg decoding the writer's output frame for frame), a Board row in public-signup-tools, a blockout_film sample in assist-context; the template-covers tile count went from 228 to 229. ComfyUI: video-blockout-wan22-fun-vace validated on the live CPU ComfyUI (queued and removed, never run: no weights). Browser: tests/e2e/cinema-blockout.mjs passed in demo mode at 1440 light (built the example, rendered it in the browser to 192 H.264 frames at 1280x720 and a 128-frame 832x464 depth video, both checked with ffprobe; still + role; compiled prompt; filmed on Seedance), 1440 dark open engine (uploaded MP4, hand-made beats, Free, open steps queued), and 390 light/dark (panel and builder, no sideways scroll). Dev server stopped and .next deleted.",+ "left": [+ "Not verified on a GPU or with a fal key: the Seedance 2.5 and H3 Max 3D cloud runs and the Wan 2.2 Fun VACE blockout windows only ran in demo mode, and the new graph was validated, not run. On the real GPU run, check the near = bright depth convention against Fun VACE's control.",+ "SolarRenderer (the H3 grey-box route on the open engine) is recorded, not built. It needs smthemex/ComfyUI-SolarRenderer (Apache-2.0, git clone only, not in the Manager) plus the MiniMax-H3 Ref2VA base and its LoRAs (MiniMax H3 Community License, which excludes the EU, UK, Korea and the US). Next step: install it on a GPU box, pin it in packs.json and model-pins.json, and A/B it against the VACE windows.",+ "Long cloud blockouts carry continuity by handing the previous shot's last frame to the next shot as an extra still (extract-frame), then join-clips. Seedance's own extend op was not used: it can't take the blockout segment beside the clip it extends.",+ "On the open engine each window starts on the previous window's last frame, so the joined film repeats one frame (1/16 s) at each 5 s seam. The open engine renders at most 12 windows (about 60 s).",+ "The mannequin is Fuobe's own capsule figure in the browser. The Rig & animate rigged figure was not reused: it is made server-side, not a browser rig.",+ "GLB files can't be uploaded (the upload route doesn't take model/*), so 'Your 3D model' lists Library 3D models (Image to 3D outputs).",+ "Browsers without WebCodecs H.264 fall back to WebM, and the panel warns that the cloud may refuse it. The test's Chromium did encode H.264.",+ "The GPU board row links to /cinema?blockout=1. The projects list ignores the query (only /cinema/<id>?blockout=1 opens the panel). A Suspense-wrapped search-param read on /cinema would fix it.",+ "Seen, not caused here: a hydration mismatch in the app sidebar (ViewerRowPlaceholder) at desktop width with the engine set to open, on /cinema/<id> with or without the blockout query. The new e2e ignores 'Hydration failed'. The existing tests/e2e/cinema-path.mjs open-engine step will probably trip on it.",+ "The owner's Horror_Scene_SD2.5.json was not available; I worked from the brief. /home/user/ext/blockout is missing."+ ],+ "docsNotes": "STATUS/ARCHITECTURE were not edited (the brief didn't ask). For the docs pass: (1) ARCHITECTURE › Fuobe Originals / Cinema: Blockout to film (action 'blockout', src/lib/blockout.ts, planBlockout; cloud Seedance 2.5 ref2v or hidden minimax-h3-max-3d, shots cut at markers that hand over the previous shot's last frame, then joined; open: video-blockout-wan22-fun-vace with Qwen-Image-Edit first frame, 81-frame depth windows, oss-join-encoded; uploads without depth use oss-wan22-vace-restyle). (2) ARCHITECTURE › UI: blockout-builder / blockout-engine / blockout-panel, the Blockout chip, 'Use as blockout', ?blockout=1; video-encode.ts (VP8/WebM and H.264/MP4 via src/lib/mp4.ts). (3) Catalog: Pricing.perRequest and Pricing.minSeconds; the Canvas Clips port on ref2v models that take clips; the 'blockout-film' Canvas template. (4) Assist/MCP tool list: blockout_film. (5) GPU board: the 'Blockout to film' row. (6) STATUS: lane O's blockout-film is built (cloud and GPU runs not yet verified with a key or a GPU); SolarRenderer is queued as the next open route to test. (7) FEATURES/README (docs pass only): Blockout to film. (8) Research corrections already made: paid-model-apis-4.json gets the H3 Max 3D to video endpoint record; new-models-10.json notes H3 3D as built and SolarRenderer's re-read (the comfyui-wiki 'custom nodes + 3 workflows' is the community pack smthemex/ComfyUI-SolarRenderer, not Enderfga's release). Where the brief was out of date: Fuobe's Seedance 2.5 catalog lists durations [4,5,6,8,10,12,30], but fal's reference-to-video takes any whole number of seconds from 4 to 30 (plus 'auto') and reference clips of 1.8–30.2 s (30.2 s in all), so a blockout gets one call up to 30 s, not the workflow's 15. The brief's 'Cinema's extend chain' for long cloud takes became a last-frame handover (see left).",+ "blocked": ""+ },+ "review": {+ "findings": [+ {+ "severity": "medium",+ "title": "An edited prompt for H3 Max 3D goes to fal uncapped, but fal allows at most 2000 characters",+ "where": "src/lib/catalog/cinema.ts planBlockout (const prompt = !many && input.prompt.trim() ? input.prompt.trim() : compiled); src/components/cinema/blockout-panel.tsx Textarea (slice 0..60_000); src/server/assist/studio-tools.ts BlockoutInput.prompt max(60_000)",+ "detail": "Only the compiled prompt is capped (compileBlockoutPrompt caps h3 at H3_INTENT_MAX). Once the user edits the prompt in the composer, or Assist/MCP passes `prompt`, a single-shot H3 film sends it as written. fal's schema for minimax/h3-max/3d-to-video, re-read today, says prompt maxLength is 2000 and additionalProperties is false, so a longer prompt fails with 422 after the run has been accepted. No generic prompt-length guard exists in the catalog or payload layer.",+ "verified": "Ran planCinema with tsx (cloud, minimax-h3-max-3d, 10 s, prompt 'x'×5000): shot0.request.prompt.length = 5000. fal OpenAPI: prompt maxLength 2000.",+ "fix": "Cap or refuse with a clear message when the model is H3 (cap(prompt, H3_INTENT_MAX) or a blocker), and limit the textarea to 2000 for H3."+ },+ {+ "severity": "medium",+ "title": "Seedance 2.5 blockout prices ignore fal's billing for the input video and the resolution",+ "where": "src/lib/catalog/cloud-models.generated.ts seedance-2-5 pricing {unit: second, usd: 0.473} (from scripts/gen-cloud-models.py); priced by planBlockout / estimateCost",+ "detail": "fal's Seedance 2.5 reference-to-video page bills by tokens on input video seconds plus output seconds, times 0.6 when video references are present: tokens = h × w × (input + output) × 24 / 1024, at $0.0214 per 1K tokens (480p/720p) and $0.0234 (1080p). Every Blockout call sends a reference clip, yet the estimate is 0.473 × output seconds whatever the resolution. For a 10 s blockout the plan says $4.73 at 480p, 720p and 1080p alike. By fal's formula that is about $5.5 at 720p (15% low), about $13.6 at 1080p (2.9× low) and about $2.5 at 480p (too high). The catalog data was already wrong on the base, but this package depends on it, and the brief asks for the film to be 'priced before running'. Pricing.clipInput (used by Kling 4.0) already models input-plus-output billing. tests/blockout.test.ts asserts the wrong rule (cost ≥ 40 × 0.473).",+ "verified": "tsx probe: seedance-2-5, 10 s, at 480p / 720p / 1080p, all cost 4.73. Fetched fal.ai/models/bytedance/seedance-2.5/reference-to-video: 'input video duration is billed alongside output', ×0.6 with video references, the token formula and rates.",+ "fix": "Give seedance-2-5 a byResolution / clipInput pricing (or a token formula) in gen-cloud-models.py, with a test against fal's formula."+ },+ {+ "severity": "low",+ "title": "H3 shots can be cut down to 2 s, but each one is billed at least 5 s plus a $0.50 fee",+ "where": "src/lib/catalog/cinema.ts BLOCKOUT_SHOTS['minimax-h3-max-3d'].min = 2",+ "detail": "splitShots leaves at least `min` seconds for the last shot. With min 2, a 16 s H3 blockout becomes a 14 s shot and a 2 s shot. fal bills the 2 s shot as 5 s, plus another $0.50 fee. The plan prices this correctly at $2.52, but splitting 11 + 5 would give the same number of calls for about $2.28 and less waste. Using min 5 (H3's billing floor) avoids paying for seconds that are thrown away.",+ "verified": "tsx probe: 16 s H3 gives shot durations 14 and 2, cost 2.523."+ },+ {+ "severity": "low",+ "title": "The H3 price leaves out two of fal's charges: auto-generated references, and the 5 s minimum per cut inside an uploaded blockout",+ "where": "src/lib/catalog/cloud-models.generated.ts minimax-h3-max-3d pricing; planBlockout",+ "detail": "fal's page: references are generated automatically when none are supplied (max_generated_reference_images defaults to 2), at $0.10 per image (the page also says $0.02–0.04). Fuobe sends no references when the user adds no stills, and sends no max_generated_reference_images, so the first shot can cost up to $0.20 more than shown. fal also bills 'a minimum of 5 billed seconds per shot', where a shot is a cut inside the source video (up to 32). An uploaded Blender blockout with cuts is billed more than Fuobe's one-call minimum. The research record mentions both charges; the price and the UI note do not.",+ "verified": "fal model page and OpenAPI, read today; estimateCost has no such term."+ },+ {+ "severity": "low",+ "title": "GPU board row: its link doesn't open Blockout, and it leaves out the graph used for uploads without a depth pass",+ "where": "src/server/gpu/tools.ts STUDIO_ROWS 'Blockout to film'",+ "detail": "(1) href '/cinema?blockout=1' goes to the projects list, which ignores the query; only /cinema/<id>?blockout=1 opens the panel (workspace.tsx). The implementer also noted this. (2) The row's steps are BLOCKOUT_MODELS.open, oss-qwen-edit, oss-segment, oss-extract-frame and oss-join-encoded. An uploaded grey box without a depth pass is the common Blender case, and it runs BLOCKOUT_MODELS.openNoDepth (video-restyle-wan22-fun-vace). That graph needs DA3 nodes and geometry_estimation/depth_anything_3_mono_large.safetensors (requirements.json). The board can therefore say Ready while that path is missing its model file.",+ "verified": "Read src/app/(studio)/cinema/page.tsx (no query handling), workspace.tsx:219-221, and requirements.json for video-restyle-wan22-fun-vace."+ },+ {+ "severity": "low",+ "title": "An uploaded depth pass gets no guidance on its convention (near = bright), and a Blender mist pass is the opposite",+ "where": "src/components/cinema/blockout-panel.tsx 'Add a depth pass'; src/lib/catalog/cinema.ts BlockoutRun.depth doc ('Blender's mist / Z pass works too')",+ "detail": "The graph feeds the depth video to VACE as it is. Blender's mist pass is near = dark by default, and a raw Z pass is not normalised. The panel says nothing about this, so a user who follows the code comment gets an inverted control video with no warning. Assist's schema states near = bright; the UI does not.",+ "verified": "Code reading; grep found no 'near = bright' or invert option in the panel."+ },+ {+ "severity": "low",+ "title": "The blockout's length is the client's word; if an upload's duration can't be read, the panel silently assumes 8 s",+ "where": "blockout-panel.tsx uploadVideo (secs fallback 8); src/server/cinema-schemas.ts BlockoutSchema.seconds (not compared with the stored file)",+ "detail": "When mediaDuration fails (for example a MOV the browser can't decode), seconds becomes 8. The plan then sends the whole clip as @Video1 with duration 8 and no split, even if the clip is 40 s, and fal refuses clips over 30.2 s. The trims and windows are also timed to the wrong length. The server already has the upload's header (storedMedia, which Assist's blockout_film reads through videoLength) but doesn't use it for Cinema.",+ "verified": "Code reading."+ },+ {+ "severity": "low",+ "title": "WebM blockouts reach Seedance with no warning on two paths",+ "where": "scene-viewer.tsx takeAsBlockout; blockout-panel.tsx upload accept='video/mp4,video/quicktime,video/webm'",+ "detail": "Seedance's video_urls take MP4/MOV only. The builder warns when it falls back to WebM, but 'Use as blockout' in the 3D scene viewer (encodeFrames can fall back to VP8 or MediaRecorder WebM) and a WebM upload do not. A single-shot Seedance film sends the WebM unchanged, so the cloud refuses it after the run starts. Multi-shot films pass through trim-video first.",+ "verified": "Code reading; fal schema: 'Formats: MP4, MOV'."+ },+ {+ "severity": "low",+ "title": "Keyboard users can't frame camera keys or move pieces that have keys",+ "where": "src/components/cinema/blockout-builder.tsx / blockout-engine.ts",+ "detail": "Camera keys copy the orbit view. OrbitControls never calls listenToKeyEvents, and there are no numeric fields for camera position or target. Pieces with keys lose their Position and Turn fields (`!prim.keys?.length`), so adding a key needs the pointer gizmo. Static pieces, lens, shake, markers and the playhead do work from the keyboard. The brief asks for keyboard users to be covered.",+ "verified": "grep: no listenToKeyEvents or keydown handling in either file."+ },+ {+ "severity": "low",+ "title": "The new e2e ignores every 'Hydration failed' error",+ "where": "tests/e2e/cinema-blockout.mjs:74",+ "detail": "The sidebar mismatch is real and pre-existing (see checks), but a blanket filter would also hide hydration errors introduced by the Blockout panel or builder. A filter that matches only the known ViewerRowPlaceholder diff would be safer.",+ "verified": "Read the test; reproduced the pre-existing error separately."+ },+ {+ "severity": "info",+ "title": "For many-shot Seedance films, the composer's prompt preview numbers the stills differently from what each shot sends",+ "where": "cinema.ts blockoutPrompt vs planBlockout",+ "detail": "The preview compiles with up to 4 stills (@Image4 = the 4th still). A many-shot film sends 3 stills plus the hand-over frame as @Image4 in each shot. Only the preview is affected: an edited prompt is not used for many-shot films, and the notes say so."+ },+ {+ "severity": "info",+ "title": "mp4.ts is correct; memory use is fine but not minimal",+ "where": "src/lib/mp4.ts muxMp4, src/components/cinema/video-encode.ts encodeMp4",+ "detail": "Checked box by box against ISO BMFF: mvhd/tkhd/mdhd/hdlr/vmhd/dref/avc1 VisualSampleEntry/avcC/stts/stss/stsc/stsz/stco are all well formed; stco = ftyp + moov + 8; 90 kHz timescale. Frames are encoded as they are drawn (one reused ImageData; VideoFrame copies it), so raw frames are never held in memory. At the end the encoded data is copied about 3 times (box() concat of mdat, the box wrapper, the final concat), and once more into the Blob: about 4× the file size at peak, roughly 240 MB for 60 s at 8 Mbps. Acceptable. Handing the Blob [ftyp, moov, mdat header, ...frames] as BlobParts would avoid the copies. The writer assumes no B-frames: true for baseline (tried first) and for Chromium's encoders; a check that timestamps increase would make that safe."+ }+ ],+ "checks": [+ "Full Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2) on o/blockout-film 31f29558: 288 files, 4596 passed, 3 skipped, 0 failed",+ "tsc --noEmit: clean (run in a scratch copy of HEAD after `next typegen`; the worktree has no .next, so PageProps/LayoutProps are missing there, as on any clean checkout)",+ "eslint on the changed files: 0 errors, 1 warning (scripts/comfy/library.spec.mjs WAN_NEG_EN, from before this branch)",+ "fal OpenAPI for minimax/h3-max/3d-to-video, re-read: video_url (required, ≤15 s / 32 shots), prompt ≤2000, reference_image_urls ≤8, max_generated_reference_images, resolution 480P/768P/1080P, enable_safety_checker, additionalProperties false. The route map (video_url, reference_image_urls, prompt, resolution) sends nothing extra. Price page: $0.05/$0.08/$0.16 a second, rounded up, at least 5 s a shot, $0.50 a request. perRequest and minSeconds in estimateCost match (12 s at 768P = $1.46; 3 s = $0.90)",+ "fal OpenAPI for bytedance/seedance-2.5/reference-to-video: duration 'auto' or '4'..'30' (so ceil(len) values like 7, 9 or 13 are accepted), video_urls MP4/MOV 1.8–30.2 s and 24–60 fps, up to 10 videos, images referenced as @ImageN",+ "planCinema probes (tsx): Seedance 45 s → shots of 30 and 15 s with trim, hand-over and join; H3 16 s → 14 + 2; open 60 s → 12 windows / 38 steps; frame counts per window are 4n+1 (computeFrames(81/16) = 81, 45/16 → 45); the oss-segment trim of startTime/endTime binds startFrame/frames exactly",+ "The video-blockout-wan22-fun-vace graph against the live CPU ComfyUI /object_info (read only, nothing queued): all 33 nodes exist, every required input is set, no unknown inputs, all link output indexes are valid. The workflows/ and hand-built copies are identical. Manifest bindings (video 1.file, image 4.image, frames 30.value, fps 26, size on 3/5/34/35/15) match the graph. requirements.json has the graph with no packs. The manifest carries its licence, and Settings → Models & licences reads it (src/lib/licences.ts)",+ "Canvas ports: every ref2v model with maxVideos > 0 maps videos/videoArray, so the new Clips port never drops a clip silently (oss-wan22-vace-blockout is a ComfyUI route)",+ "Public sign-up: no new routes. The blockout goes through POST /api/cinema/projects/:id/generate, which answers own-gpu-tool for accounts (tests/public-signup.test.ts). Assist changes are owner-only and /api/mcp is OWNER_ALL, so blockout_film is owner-only. Canvas runs are own-gpu-tool and canvases are LIBRARY_CHANGES. The hidden models reached through POST /api/generations use the existing account-inputs and tenant checks. BlockoutSchema takes /api/files refs only (the test refuses an external URL, 61 s and a bad role). Large files arrive as upload references. The take info stores no URLs (the inputs live in generations.request_json, which is in ASSET_REFS)",+ "No binaries, LoRA files or Higgsfield references in the diff; no new node packs or model files",+ "Hydration: ran next dev in demo mode on scratch copies of the base (claude/fuobe-parity-4) and of the branch, and loaded /cinema/<id>, ?blockout=1, /image and /cinema at 1440 and 390, on both engines. The base shows the same intermittent desktop-only 'Hydration failed' error, including on /image, with either engine. The diff is in AppSidebar's Suspense > ViewerRowPlaceholder: the server renders the placeholder <script>/<li> and the client's first render does not. It comes from the base, not from this branch, and has nothing to do with the open engine. Phone width was clean on both",+ "tests/e2e/cinema-blockout.mjs against the branch copy's dev server (demo mode): passed. The grey box rendered in the browser as H.264 1280x720 with 192 frames, checked by ffprobe; depth 8 s at 16 fps; open engine upload; 390 light and dark with no sideways scroll",+ "Nothing in /home/user/Fuobe or the worktree was edited. Two throwaway probe test files were created in the worktree and removed at once; git status is clean"+ ],+ "verdict": "Merge after fixes. The package is solid: the MP4 writer is correct and verified by a real decoder in the browser, the shot and window maths and the new graph's bindings check out against the live ComfyUI, the H3 schema, fee and 5 s minimum match fal, and no sign-up rule is broken. Fix the two medium issues before relying on real cloud runs: cap or refuse an H3 prompt edited past 2000 characters (fal returns 422), and correct Seedance 2.5's reference-to-video price (input plus output seconds, per resolution), so the price shown before running is right. The low items (H3 shot minimum, unpriced H3 extras, the board row's link and missing restyle graph, depth-pass guidance, the trusted length, WebM warnings, keyboard framing, the e2e's hydration filter) can follow. The sidebar hydration error is on the base too and is not caused by this branch."+ },+ "fix": {+ "applied": [+ "Medium, H3 prompt: planBlockout refuses an edited one-shot prompt over 2000 characters for MiniMax H3 Max 3D to video with a clear blocker (BLOCKOUT_SHOTS[..].prompt = H3_INTENT_MAX), so neither the composer nor Assist/MCP can send it. The composer's prompt box is limited to 2000 for H3 (maxLength plus slice) and shows an 'n / 2000 characters' count; Assist's prompt field says so. Tests: 2000 passes, 5000 refused, Seedance and many-shot H3 not affected; e2e checks maxlength=2000.",+ "Medium, Seedance 2.5 price: I re-read fal's reference-to-video page and OpenAPI (2026-11-01). Tokens = h×w×(input + output seconds)×24/1024 at $0.0214 per 1K (480p/720p) or $0.0234 (1080p), ×0.6 with video references. fal's sidebar $0.473/s divides by 1000 where the formula says 1024. In gen-cloud-models.py, seedance-2-5 now has byResolution {480p 0.21494, 720p 0.46224, 1080p 1.13724} and clipInput {480p 0.12897, 720p 0.27734, 1080p 0.68234, plain: true}. Pricing.clipInput.plain bills input + output with no twice-output floor; a clip not yet read is taken as long as the output; the server reprices from the header (billsClips) as it already did for Kling. planBlockout sends clipSeconds = the shot's length (the blockout or its cut). A note says the blockout's seconds are billed with the film's. The composer's 'at least twice' wording only shows when the floor applies. Tests reproduce fal's own worked examples ($4.62, $4.99, $11.09) and the per-resolution formula. The wrong '≥ 40 × 0.473' assertion is replaced by the formula.",+ "Low, H3 shot minimum: BLOCKOUT_SHOTS H3 min is now 5, so 16 s is cut 11 + 5 instead of 14 + 2 (tested).",+ "Low, H3 extra charges: new Pricing.generatedRefs {usd 0.10, count 2} and GenParams.drawnRefs, set by planGeneration when a run sends no images and chains none. A run with no stills prices the up to 2 references fal draws (max_generated_reference_images has a minimum of 1 and is ignored when stills are given, so 0 can't be sent). Notes: the drawn references and their price, and that every camera cut inside an uploaded render bills at least 5 s. Tests for one shot, multi-shot (only the first shot draws) and estimateCost.",+ "Low, GPU board row: the row now also needs BLOCKOUT_MODELS.openNoDepth (video-restyle-wan22-fun-vace, DA3). /cinema?blockout=1 now works: a Suspense-wrapped useSearchParams child in the projects list shows 'Blockout to film: pick the project to film it in', and project cards and a new project carry ?blockout=1, which opens the panel (e2e step). Test updated.",+ "Low, depth convention: the panel says 'near is bright, far is dark' under the depth pass. A 'Near is dark (Blender's mist pass): invert it' switch sets BlockoutRun.depthInvert. The open plan sends params.extra.invertDepth to every window. The graph video-blockout-wan22-fun-vace gained PrimitiveBoolean → ComfySwitchNode(on_false raw, on_true ImageInvert) before the control batch, bound as invertDepth (added to BINDING_KEYS, with a validator sample of true). It was rebuilt and validated on the live CPU ComfyUI with --shared: inverted branch ✓; nothing queued ran. The manifest header and object_info.subset.json were kept at the base's values, and requirements.json was rebuilt. The BlockoutRun mist/Z comment is corrected. Assist takes depth_invert. Tests: plan extra, graph wiring, binding false/true; e2e uploads a mist pass, ticks invert, checks invertDepth on the run.",+ "Low, trusted length: new blockoutFromFile (src/server/cinema-generate.ts) reads the stored file's header with storedMedia (allContainers, header only, tenant-safe). Cinema's generate (plan and take) and Assist's blockout_film use the header's length (capped at 60 s) over the browser's, and mark WebM. The panel no longer silently shows 8 s: it says 'Length read from the file when you film'. Test: a 40 s MP4 sent as 8 s films as 2 shots and the take says 40; Assist plans 2 shots too.",+ "Low, WebM: BlockoutRun.webm is set by the panel (upload type or name, builder render type) and by 'Use as blockout' (scene-viewer now passes the render type), and the server sets it from the header. Seedance 2.5 refuses a WebM blockout with what to do instead (render in Chrome/Edge, export an MP4, or film on your GPU). Toasts appear for a WebM upload, a WebM builder render and a WebM scene render. Tests: plan blocker; API 422 on a real VP8 WebM; H3 and the open engine not blocked.",+ "Low, keyboard: the Camera tab has number fields (Camera x/y/z, Looks at x/y/z, Lens, Shake) that edit the key at the playhead or make one from the camera's unshaken pose there (new pure cameraKeyAt / withCameraKey in src/lib/blockout.ts, capped at 32 keys, lens kept in range). Pieces with keys show 'Position/Turn at t' fields that key them at the playhead (movePrim). Field keeps a draft while typing out of range and clamps on blur. OrbitControls listens to arrow keys on the focused canvas. Unit test for cameraKeyAt/withCameraKey; e2e types a camera value and gets a 4th key.",+ "Low, e2e hydration filter: it now ignores only a 'Hydration failed' whose diff names ViewerRowPlaceholder and not Blockout.",+ "Merged origin/claude/fuobe-parity-4 twice (fe47ece5, then 9aeca357 with origin/main). requirements.json was rebuilt with build-requirements.mjs both times. The build-library.mjs BINDING_KEYS conflict kept main's RE-USE keys plus invertDepth."+ ],+ "rejected": [+ "Info, the many-shot preview numbering (@Image4 = 4th still in the preview vs the hand-over frame per shot): left as is. Only the preview differs, an edited prompt is not used for many-shot films, and the notes say so.",+ "Info, mp4.ts memory copies: left as is. The reviewer found it correct and acceptable (about 4× file size at peak).",+ "Converting WebM to MP4 on the cloud: not done. fal's trim-video output format for a WebM input isn't documented, so Seedance refuses WebM with guidance instead of relying on it. The open engine reads WebM as before."+ ],+ "checks": [+ "pnpm typecheck (after npx next typegen): exit 0, before and after the final merge",+ "pnpm lint: exit 0, 0 errors, 1 warning (scripts/comfy/library.spec.mjs WAN_NEG_EN, from before this branch)",+ "FULL Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2) before the base gained main: 290 files, 4648 passed, 3 skipped, 0 failed, exit 0",+ "FULL Vitest after merging origin/claude/fuobe-parity-4 at 9aeca357 (main merged in): 308 files, 4874 passed, 6 failed, 3 skipped, exit 1. All 6 failures are the known ones that fail on clean origin/main (main-rules item 8): comfy-reuse (pack licence record), dop-originals (effect-acid), preset-featured (126 vs 127), soul-runs (2), split-soundtrack ('has no cloud route'). None are in this package's files.",+ "tests/blockout.test.ts: 32 tests pass (new: Seedance formula with fal's worked examples, H3 2000-character refusal, H3 drawn references, WebM refusal, invertDepth plan and graph binding, header length and WebM through the Cinema API and Assist, cameraKeyAt/withCameraKey, the GPU row with the restyle graph)",+ "ComfyUI: video-blockout-wan22-fun-vace rebuilt (build-library.mjs) and validated on the live CPU ComfyUI (validate-workflows.mjs --shared) with invertDepth=true: ✓, nothing run. The manifest header and object_info.subset.json are kept at the base's values; requirements.json lists ComfySwitchNode, ImageInvert and PrimitiveBoolean (core), with no packs",+ "fal re-read 2026-11-01: seedance-2.5/reference-to-video (formula, rates, 0.6×, resolutions 480p/720p/1080p, durations 4-30) and minimax/h3-max/3d-to-video (prompt maxLength 2000, max_generated_reference_images 1-8 default 2 and ignored with references, $0.10 per generated reference, 5 s minimum per shot, $0.50 a request)",+ "Browser e2e tests/e2e/cinema-blockout.mjs against next dev in demo mode, passed both before and after the final merge: 1440 light (builder, keyboard camera key, H.264 1280x720 192-frame render, depth 128 frames 832x464, H3 2000-character box, Seedance take), 1440 dark open engine (upload, mist depth pass inverted, invertDepth on the window run), /cinema?blockout=1 link, 390 light and dark with no sideways scroll. Dev servers stopped, .next and temporary data deleted",+ "Pushed o/blockout-film at 877aa4d0. git status clean. /home/user/Fuobe's checkout untouched"+ ],+ "finalSummary": "Blockout to film is fixed on both engines. Cloud: Seedance 2.5 reference mode is now priced by fal's own formula: blockout seconds plus film seconds, ×0.6 with the reference clip, per resolution (720p 8 s ≈ $4.44, 1080p ≈ $10.92). The server reprices from the clip's header. A WebM blockout is refused before anything is paid for. MiniMax H3 Max 3D to video refuses prompts over 2000 characters (the box stops at 2000), cuts no shot under its 5 s billing floor, and prices the references it draws when given no stills. Its note says each camera cut in an uploaded render bills at least 5 s. Every upload is filmed at the length its file's header says. Open engine (your GPU): Wan 2.2 Fun VACE depth windows as before, plus an invert switch for near = dark depth passes (Blender's mist), done in the graph with core nodes and validated on CPU ComfyUI. Uploads without depth still use the restyle graph, which the GPU board row now counts, and the board link opens Blockout to film in the project the person picks. The builder can be driven from the keyboard: typed camera keys, typed poses for moving pieces, arrow keys in the 3D view. Verified: unit and API tests, fal pages re-read, graph validation, and browser runs in demo mode. Not verified: real fal runs (no key) and real GPU runs (no GPU). Public sign-up is unchanged: no new routes. Guests browse read-only. Accounts get own-gpu-tool from Cinema's generate route; Assist/MCP and the Canvas stay owner-only. The new header read uses storedMedia, which answers only for the asker's own files inside a tenant.",+ "left": [+ "Real runs are still unverified: Seedance 2.5 and H3 Max 3D with a fal key, and the Wan 2.2 Fun VACE windows (including invertDepth) on a GPU. Whether VACE wants near = bright still needs checking on a real GPU.",+ "fal's H3 page gives both $0.02–0.04 and $0.10 for a generated reference; Fuobe prices the higher $0.10 × 2. fal doesn't say how it finds cuts inside an uploaded render, so that cost is only explained in a note, not priced.",+ "Seedance 2.5 Cinema takes with reference clips (outside Blockout) now price unread clips as long as the output until the server reads their headers. faceless.ts still has its own Seedance per-second table (the sidebar's $0.2205/$0.473/$1.164), which this package didn't touch.",+ "WebM blockouts are refused on Seedance rather than converted (no verified cloud conversion step).",+ "SolarRenderer (H3 grey-box on the open engine) is still recorded, not built (see the implementation report).",+ "Known failures from main (6 tests in 5 files, listed in checks) are main's to fix.",+ "The desktop sidebar hydration mismatch (ViewerRowPlaceholder) is still the base's; the e2e ignores only that diff."+ ],+ "blocked": ""+ },+ "merge": {+ "merged": [+ "o/blockout-film"+ ],+ "notMerged": [],+ "conflicts": "workflows/comfyui/requirements.json: took ours, rebuilt (191 workflows); the merged index passed its 216 KB / 27 KB budget, so fed664c5 raises it to 256 KB / 32 KB with a note",+ "checks": "typecheck 0, lint 0, vitest 4909 passed, 3 skipped, 7 failed: the 6 known failures that also fail on clean origin/main, plus the size budget fixed in fed664c5 (gpu-requirements 18/18 after)",+ "pushed": true,+ "head": "fed664c5"+ }+}diff --git a/docs/handoff/reports/dbs-d3.json b/docs/handoff/reports/dbs-d3.jsonnew file mode 100644index 00000000..adf545b8--- /dev/null+++ b/docs/handoff/reports/dbs-d3.json@@ -0,0 +1,128 @@+{+ "key": "dbs-d3",+ "impl": {+ "branch": "o/dbs-d3",+ "summary": "DBS D3, open engine only. Owner rule: samAudioCloud is false (docs/handoff/owner-decisions.json), so the brief's cloud SAM Audio pass, the 'Background split: SAM Audio / Demucs' setting and the SAM prices were left out. The cloud dub is unchanged: extract + Demucs, three beds, the voice-only fallback (OPTIONAL_PREPARE) and ElevenLabs isolation. On the open engine, Translate & dub has a new 'Voice split' setting. MelBand RoFormer stays the default until D4 reports. The other choice is DBS, which keeps the music, effects and singing in the background and does its split on a CPU. DBS runs through the new graph B dub-prepare-dbs-transcribe and the ModelDef oss-dbs-voice-separate 'DBS + Qwen3-ASR'. Graph B was validated on the live CPU ComfyUI and run for real on a 12 s clip.",+ "built": [+ "Graph B scripts/comfy/hand-built/dub-prepare-dbs-transcribe.json, with its spec entry next to dub-prepare-separate-transcribe. Nodes: LoadAudio, DBSLoader (separationModel), DBSSeparate (mono, input rate), and AudioMerge subtract to make the background. Voice and background are saved as FLAC. Node 7 is the MelBand graph's Qwen3-ASR node with its settings and bindings (sourceLanguage, asrModel, hints, maxChars). Same outputs as the MelBand graph: voice, background, cues, transcript, language. vramGb 8, the existing autoDownloads note and the licence text from the brief. Both DBS models are required, as in graph A. Built with npm run build, then manifest header restored and the BSRNN config size set to 0 like graph A. requirements.json rebuilt with both packs and the four DBS files. Both packs were already pinned in packs.json and the DBS files in model-pins.json, so neither file changed. validate-workflows --shared passed and set validated: true. object_info.subset.json restored because it already had every class.",+ "Provider (src/server/providers/comfyui.ts): a DBS graph with no channels binding still gets the surround rule. A source with more than 2 channels has node 4 rewired to music + effects (dbsSurroundBed). The host pick of DBS model and the refusal of a model that isn't installed apply to graph B as they do to graph A.",+ "Catalog: oss-dbs-voice-separate 'DBS + Qwen3-ASR' next to oss-voice-separate. Its licence row comes from the workflow licence.",+ "src/lib/av/dub.ts: VOICE_SPLITS (melband/dbs with model id, name and note), DEFAULT_VOICE_SPLIT 'melband', voiceSplitModel() and MUSIC_MODEL_NOTE. PrepareInput.voiceSplit picks the open first step's model; DUB_STEP_MODELS.open.stems stays the default. DubSession.voiceSplit is stored for open step dubs only.",+ "Server and API: CreateDubInput.voiceSplit goes through createDubSession and previewDub. The POST /api/dub schema takes voiceSplit (melband|dbs); anything else gets 400 'Check the dub settings'. No new route, and the public sign-up rules are unchanged: /api/dub was already in EMPTY_LISTS and PREVIEWS, and a visitor's run is still refused own-gpu-tool. The dub studio already showed visitors the SelfHostNote, 'Self-hosted only' in place of the price and an inert upload, the same pattern D2 used.",+ "Assist: dub_video takes voice_split (melband|dbs, open source only, described in the schema). Both the studio route (dubJob/prepareProblem) and the fallback pipeline (dubSteps) use it. Recipes keep a dub's voice_split (recipe-builder liftStudio).",+ "UI (src/components/dub/dub-studio.tsx): on the open engine in step mode, a 'Voice split' Select offers 'DBS: keeps music and effects, CPU-friendly' and 'MelBand RoFormer'. A choice switched off in Settings → Models & licences is left out. Under it is the note: DBS 'Keeps the music and sound effects of the original.', MelBand 'Music model: some sound effects may be lowered, and singing may be replaced.' The route line follows the choice. On the cloud: 'Music and effects: Demucs. Music model: some sound effects may be lowered, and singing may be replaced.' The price line is unchanged (Free on your GPU / Placeholder · free on the open engine).",+ "Docs: scripts/comfy/README.md has a graph B section; docs/research/dbs-separation-7.md has 'As built (D3)' notes in §4.4 graph B and §9 D3 (a research correction)."+ ],+ "tests": "New tests/comfy-dbs-dub.test.ts (9 tests): graph B's manifest outputs and bindings match dub-prepare-separate-transcribe's, plus separationModel; packs, models and licence; the requirement-index row; the graph matches graph A's split and keeps node 7's settings unchanged; the provider fills the host pick, the ASR model, the filename prefixes and the surround rewire, and refuses a missing model; output order. Extended tests/av-dub.test.ts: prepareSteps per engine and voice split; the cloud is unchanged with voiceSplit (Demucs, three loudnorm beds, OPTIONAL_PREPARE, no sam-audio-separate model); a demo DBS dub where the mock returns voice, background and cues, then reaches review and mixes over the bed; open prices are free with either split. Also extended: assist-context (fallback with voice_split), assist-studio-routes (dub_video with voice_split dbs; the /api/dub price check accepts dbs and refuses 'sam'), recipe-builder (voice_split kept). Typecheck clean. ESLint clean on the changed files apart from one existing warning in library.spec.mjs. Full Vitest (--maxWorkers=2): 283 files, 4517 passed, 3 skipped, 1 failed. The failure is tests/gpu-api.test.ts '409 gpu-setup', which got 503 because the shared disk had 17-18 GB free against the 20 GB account guard (FUOBE_ACCOUNT_DISK_FREE_GB). With FUOBE_ACCOUNT_DISK_FREE_GB=1 that file passes 12/12; this is the environment, not this change. Live ComfyUI: graph B validated with validate-workflows --shared, then run for real through Fuobe (pnpm dev, COMFYUI_URL=127.0.0.1:8188, POST /api/generations on oss-dbs-voice-separate, asrModel Qwen3-ASR 0.6B) on a 12 s H.264+AAC clip of LibriSpeech speech over sine chords and pink-noise bursts. It succeeded in 133 s on the CPU, including the ASR load. Voice + background equal the decoded source within 3.0e-5, the voice stem is about 17.9 dB SNR against the true speech, the bed about 11.2 dB, and the transcript and cues were right ('He hoped there would be stew for dinner, …'). Browser: new tests/e2e/dub-voice-split.mjs, demo mode, 1440 and 390 px, light and dark, all 41 checks passed. It covers the Voice split and its default, both notes, the route line, the price line, the cloud's Demucs note with no Voice split, no sideways scroll, and a DBS dub's first step running on 'DBS + Qwen3-ASR'. Dev server stopped and .next deleted.",+ "left": [+ "Cloud half (one SAM Audio 'speech' pass in place of extract + Demucs, the Background split setting, SAM prices): not built because samAudioCloud is false. It waits on the owner.",+ "Not run here: the 1.7B ASR default (only 0.6B, as the brief allowed); a whole open dub with DBS (local LLM translation, Chatterbox, InfiniteTalk); GPU timing; listening tests of dub quality.",+ "The default stays MelBand until D4's A/B; flipping it is a one-line change to DEFAULT_VOICE_SPLIT.",+ "No /connect board row for Translate & dub: no row existed before, and dubs don't run on an account's GPU (own-gpu-tool). Graph B is in requirements.json."+ ],+ "docsNotes": "Already there from earlier packages (D1/D2): ComfyUI-DBS pinned and the four DBS weight files on the ComfyUI; the mock already returned voice, background and cues for any separate-audio endpoint containing 'transcribe'; the dub studio's visitor pattern (SelfHostNote, 'Self-hosted only', inert upload). Brief out of date on line numbers: the spec entry is at library.spec.mjs about L2944 (not L2239-2262), oss-voice-separate at models.ts about L1396 (not L1113), Assist's open dub at studio-tools.ts about L234, which still holds. For the docs pass: ARCHITECTURE could say Translate & dub's open first step has a Voice split (MelBand default, DBS via dub-prepare-dbs-transcribe on oss-dbs-voice-separate) and that the provider's surround bed rule covers graph B. STATUS could count one more hand-built graph (182 workflows in the manifest; graph B validated). FEATURES/README could mention 'Keeps the music and sound effects of the original' on the open engine. In demo mode, e2e scripts must use http://localhost:<port>, not 127.0.0.1: Next 16 dev blocks /_next resources and the HMR socket from 127.0.0.1, so the page never hydrates.",+ "blocked": ""+ },+ "review": {+ "findings": [+ {+ "severity": "low",+ "title": "On the cloud engine, the studio never says that keeping the music and effects (DBS) runs on your GPU (open source)",+ "where": "src/components/dub/dub-studio.tsx (the cloud note, around L251: 'Music and effects: Demucs. Music model: ...'); tests/e2e/dub-voice-split.mjs L70-77",+ "detail": "The brief says that with samAudioCloud=false, 'the feature says it runs on your GPU, open source'. The owner's rule (10-30) also asks the UI to say plainly what each engine does. With the cloud picked, the dub studio shows only the Demucs caveat and no Voice split. Nothing tells the user that 'Keeps the music and sound effects of the original' (DBS) is offered on the open engine. Leaving out the cloud SAM route is correct. This is only a missing line of copy.",+ "verified": "Traced the JSX: the cloud branch renders only MUSIC_MODEL_NOTE. The e2e cloud checks assert the Demucs note and that no combobox is shown, nothing more.",+ "fix": "Add a short line under the cloud note, such as 'Keeping the music and sound effects of the original (DBS) runs on your GPU (open source).', and assert it in the e2e script."+ },+ {+ "severity": "low",+ "title": "The server's default voice split ignores Settings → Models & licences, unlike the studio",+ "where": "src/lib/av/dub.ts voiceSplitModel(); src/server/assist/studio-routes.ts dubJob/prepareProblem; src/server/assist/studio-tools.ts dubSteps",+ "detail": "The studio drops a split that is switched off with keepOffered/offered, so with MelBand RoFormer off it sends voiceSplit 'dbs'. On the server, voiceSplitModel() always falls back to DEFAULT_VOICE_SPLIT. So an Assist dub_video call without voice_split, or POST /api/dub without voiceSplit, plans oss-voice-separate even when it is off and DBS is on. prepareProblem only checks routes (chooseRoute), not access. The plan card looks fine, then generations.prepare refuses the run as switched off. This is not unsafe and not a regression (before D3 there was no alternative), but the two defaults now disagree.",+ "verified": "Read voiceSplitModel, dubJob/prepareProblem (route check only), keepOffered/offered in src/lib/model-access.ts, and the switched-off refusal in src/server/generations.ts prepare() at L646.",+ "fix": "Choose the server default with firstOffered/isOffered over [DEFAULT_VOICE_SPLIT, ...rest] for the open engine, in prepareSteps' callers or in voiceSplitModel with an access callback."+ },+ {+ "severity": "nit",+ "title": "VOICE_SPLITS' doc comment is stranded above MUSIC_MODEL_NOTE's",+ "where": "src/lib/av/dub.ts L63-72",+ "detail": "The /** The open engine's voice split ... */ block is followed straight away by a second /** */ block for MUSIC_MODEL_NOTE. Editors and TSDoc attach only the second one, so VOICE_SPLITS has no doc.",+ "verified": "Read the diff hunk.",+ "fix": "Move the VOICE_SPLITS comment down to the line above `export const VOICE_SPLITS`."+ },+ {+ "severity": "nit",+ "title": "The Voice split label points at a <p> when only one split is offered",+ "where": "src/components/dub/dub-studio.tsx L224-241",+ "detail": "When one split is switched off, <Label htmlFor=\"dub-split\"> points at a <p id=\"dub-split\">, which is not a labelable element. It does no harm and keyboard use is unaffected, but screen readers don't associate the two.",+ "verified": "Read the JSX.",+ "fix": "Drop htmlFor in the single-choice case, or use aria-labelledby."+ },+ {+ "severity": "info",+ "title": "No /connect pre-flight row for Translate & dub (already missing before this package)",+ "where": "src/server/gpu/tools.ts STUDIO_ROWS",+ "detail": "Graph B is in workflows/comfyui/requirements.json, so the requirement index sees it. The board still has no Translate & dub row for either split. This is not a new studio, and accounts can't run dubs (own-gpu-tool), so it is not a D3 regression. The implementer reported it.",+ "verified": "grep in src/server/gpu/tools.ts: only Split soundtrack and Remove dialogue rows use separate-audio.",+ "fix": "Optional follow-up: a Translate & dub row whose steps include the chosen split's model."+ }+ ],+ "checks": [+ "Owner rule: git show claude/fuobe-parity-4:docs/handoff/owner-decisions.json gives samAudioCloud=false. The cloud prepareSteps is unchanged (extract + Demucs, three loudnorm beds, OPTIONAL_PREPARE ['sound','background']). There is no sam-audio-separate model, no Background split setting and no SAM price. That is correct, not a gap.",+ "Graph B (workflows/comfyui/dub-prepare-dbs-transcribe.json) diffed against the MelBand graph and graph A. Nodes 2-4 are identical to separate-soundtrack-dbs. Node 7 Qwen3-ASR has the same settings as the MelBand graph's, with audio rewired to DBSSeparate speech [3,2]. Nodes 8/9/10 read 7:1, 7:0 and 7:2 as before. Stems 5 (voice, speech) and 6 (background = source minus speech) are saved as FLAC.",+ "Manifest bindings: audio, separationModel(2.model), sourceLanguage/asrModel/hints/maxChars on node 7, filenamePrefix on 5/6/8/9. Outputs voice, background, cues, transcript, language, identical to dub-prepare-separate-transcribe. Licence string as the brief gives it. Both packs are listed in customNodes, ComfyUI-DBS pinned at f656e53. All four DBS files are pinned by HF revision. The validation-state sha256 matches the built workflow file (bbb7b31a…).",+ "Live CPU ComfyUI at 127.0.0.1:8188: /object_info has DBSLoader (model options TIGER/BSRNN, device auto/cpu), DBSSeparate (channels mono, output_sample_rate input; outputs AUDIO×3 + STRING), AudioMerge subtract, SaveAudioAdvanced format flac, and AILab_Qwen3ASRSubtitle (1.7B/0.6B). Every input value in graph B is a valid option. I did not re-run a full CPU separation plus ASR on the shared server; the implementer reports a 12 s run.",+ "requirements.json gains a dub-prepare-dbs-transcribe row (core AudioMerge/LoadAudio/PreviewAny/SaveAudioAdvanced/SaveText; packs ComfyUI-DBS and ComfyUI-QwenASR; the four dbs/ files; vramGb 8; validated). The hash was updated.",+ "Provider: the surround rule now applies when b.channels || b.separationModel. Only separate-soundtrack-dbs and dub-prepare-dbs-transcribe have those bindings (checked against the manifest), so no other graph changes. dbsSurroundBed rewires the subtract merge to music+sfx add. The host model pick and the refusal of a model that isn't installed apply to graph B. The test covers this.",+ "Catalog: oss-dbs-voice-separate 'DBS + Qwen3-ASR' routes comfy separate-audio to dub-prepare-dbs-transcribe. Its licence row comes from the workflow licence. Its family 'dbs' matches oss-dbs-separate.",+ "API and sign-up: POST /api/dub adds only an optional enum voiceSplit (melband|dbs). Any other value gets 400 'Check the dub settings'. Price checks still go through priceAs, and the route was already in the public sign-up rules. No new route, body size, file read or chain. The input is unchanged (the dub video), so tenant and account-inputs coverage is as before. Accounts still get own-gpu-tool.",+ "createDubSession stores voiceSplit only for open steps dubs. previewDub and createDubSession pass it to prepareSteps. Assist dubJob passes it only on open, and dubSteps uses voiceSplitModel. recipe-builder keeps voice_split, which the DubInput schema accepts on replay. A replay on the cloud ignores it.",+ "Demo mock: endpoint.includes('transcribe') returns voice, background and cues for graph B. The av-dub test drives a DBS dub to review and mixes over its background.",+ "FLAC stems downstream: the Chatterbox voice reference and the mux background read FLAC. storage, sniff, media-probe, the comfyui MEDIA_EXT and the uploads allowlist all accept audio/flac.",+ "UI: keepOffered keeps both choices when both are off, so there is no undefined split crash. The Select is Radix (works from the keyboard) and is w-full at 390 px. voiceSplit is sent only on the open engine.",+ "Typecheck: npx tsc --noEmit is clean. ESLint on the changed files: 0 errors and 1 warning (WAN_NEG_EN in library.spec.mjs, there before this package).",+ "Targeted Vitest (comfy-dbs-dub, av-dub, assist-context, assist-studio-routes, recipe-builder, open-engine, comfy-provider, public-signup): 8 files, 264 passed.",+ "Full Vitest (--maxWorkers=2, FUOBE_ACCOUNT_DISK_FREE_GB=1): 283 files passed, 4518 tests passed, 3 skipped, 0 failed.",+ "No Higgsfield API or media, no LoRA files, and no new download URLs (the weights are pinned HF revisions from D1). /home/user/Fuobe was not touched, and no edits or commits were made.",+ "Not re-run here: the browser e2e (tests/e2e/dub-voice-split.mjs, 41 checks reported) and a whole open dub with DBS."+ ],+ "verdict": "pass-with-notes: D3's open half is correct and well tested. Graph B matches the MelBand graph's output and binding contract, is valid against the live ComfyUI's node schemas, and is in the requirement index with its licence recorded. Leaving out the cloud SAM route follows the owner's samAudioCloud=false. Typecheck, lint and the full Vitest run are clean. The remaining notes are minor: copy telling cloud users the DBS option runs on their GPU, the server's default split ignoring Settings → Models & licences, and two nits. None of them blocks merging."+ },+ "fix": {+ "applied": [+ "Merge: merged the latest claude/fuobe-parity-4 (f31680b6, archive-restore and the 11-01 handoff) into o/dbs-d3. The only conflict was the hash in workflows/comfyui/requirements.json. I took the base's version and rebuilt it with node scripts/comfy/build-requirements.mjs: 183 workflows, and the dub-prepare-dbs-transcribe row is kept. Commit 57cd912d.",+ "Low 1 (confirmed), the cloud now says DBS runs on your GPU. New DBS_OPEN_ONLY_NOTE in src/lib/av/dub.ts. When the cloud engine is picked in step mode, src/components/dub/dub-studio.tsx shows 'Keeping the music and sound effects of the original (DBS) runs on your GPU (open source).' under the Demucs note. tests/e2e/dub-voice-split.mjs checks the line at 1440 and 390 px, light and dark. A unit test pins the wording.",+ "Low 2 (confirmed), the server's default split follows Settings → Models & licences. New pickVoiceSplit(split, on) in src/lib/av/dub.ts: a split named in the request is kept. Otherwise it takes the default if it is on, then the next split that is on, then the default (whose run refuses and names the switch). This matches keepOffered in the studio. voiceSplitModel takes the same callback. src/server/dub.ts dubVoiceSplit() works this out with isOffered(id, 'open') for open step dubs only, and createDubSession (which stores it), previewDub and Assist's prepareProblem all use it. Assist's fallback dubSteps passes isOffered. Tests: a pickVoiceSplit unit test, and a test in av-dub where MelBand is switched off and no split is named, so dubVoiceSplit, previewDub and createDubSession run DBS (oss-dbs-voice-separate) and the cloud gets none. assist-studio-routes: dub_video with no voice_split and MelBand off plans and runs DBS. assist-context: the fallback plan uses DBS when MelBand is off.",+ "Nit 1: the VOICE_SPLITS doc comment now sits directly above export const VOICE_SPLITS. MUSIC_MODEL_NOTE keeps its own comment above it.",+ "Nit 2: the Voice split Label uses htmlFor='dub-split' only when the Select is shown. When only one split is offered, the name is plain text with no id, so the label no longer points at a <p>.",+ "Info (optional, done because it was small): /connect now has a 'Translate & dub' row (href /audio/translate, group Audio, STUDIO_ROWS in src/server/gpu/tools.ts). Its steps are the default voice split (DUB_STEP_MODELS.open.stems, dub-prepare-separate-transcribe), then Chatterbox tts, the audio timeline, InfiniteTalk lipsync and the mux. The translation runs on the local text model, not ComfyUI, so it has no step on the board. Test in av-dub: the row's workflows are all in the requirement index, graph B is indexed, and toolFor('studio:/audio/translate') matches."+ ],+ "rejected": [],+ "checks": [+ "Branch check: before the merge, claude/fuobe-parity-4..o/dbs-d3 listed only D3's own two commits, so the branch was not cut from an old base.",+ "npx next typegen: exit 0. pnpm typecheck: exit 0.",+ "pnpm lint: exit 0. 0 errors, 1 warning: WAN_NEG_EN in scripts/comfy/library.spec.mjs, which is already on the base.",+ "Targeted Vitest (av-dub, assist-studio-routes, assist-context, recipe-builder, comfy-dbs-dub): 5 files, 124 passed. Board-row tests in av-dub, public-signup-tools and remove-dialogue: passed.",+ "Full Vitest, FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 0. 287 files passed; 4583 tests passed, 3 skipped, 0 failed.",+ "Browser: node tests/e2e/dub-voice-split.mjs against next dev in demo mode (FUOBE_DEMO_MODE=on, ComfyUI and Ollama on closed ports, a throwaway FUOBE_DATA_DIR, http://localhost:3417). Exit 0, 45/45 checks passed, including the new 'the cloud says DBS runs on your GPU' at 1440 and 390 px, light and dark, and no sideways scroll. I looked at the 390 px dark cloud screenshot. The dev server is stopped, and .next and the temp data folder are deleted.",+ "git status is clean. Pushed o/dbs-d3 (749afc8b..aa4099f8). /home/user/Fuobe's checkout was not touched."+ ],+ "finalSummary": "D3 is finished with the review fixes. Open engine (ComfyUI): Translate & dub has a Voice split. MelBand RoFormer is the default. DBS keeps the music, effects and singing, and its split runs on a CPU. DBS runs through graph B (dub-prepare-dbs-transcribe, model oss-dbs-voice-separate). Graph B was validated on the live CPU ComfyUI and run for real on a 12 s clip in the implement stage. A whole open dub with DBS (local LLM, Chatterbox, InfiniteTalk) needs a GPU and was not run. The server now picks its default split the way Settings → Models & licences and the studio do: with MelBand switched off, POST /api/dub, Assist's dub_video and its fallback plan run DBS. /connect has a Translate & dub row for the default split's chain. Cloud engine: unchanged, because the owner set samAudioCloud=false. It still uses extract + Demucs, three beds, the voice-only fallback and ElevenLabs isolation, and it needs fal and ElevenLabs keys, so it was not run for real here. Its note now says plainly that keeping the music and sound effects of the original (DBS) runs on your GPU (open source). Public sign-up: nothing changed. Guests browse read-only and the studio shows them 'Self-hosted only' with an inert upload. Accounts' dub runs answer own-gpu-tool as before. /api/dub was already in the sign-up rules. No new route, file read or chain was added.",+ "left": [+ "Cloud SAM Audio route (the Background split setting and SAM prices): waits on the owner's samAudioCloud decision.",+ "Not verified here: a whole open dub with DBS on a GPU, the Qwen3-ASR 1.7B default, GPU timing, and listening tests.",+ "The default stays MelBand until D4's A/B. Changing it means editing DEFAULT_VOICE_SPLIT. The /connect row follows DUB_STEP_MODELS.open.stems, so it lists the MelBand graph. DBS's pack and weights show readiness on the Split soundtrack row.",+ "For the docs pass: ARCHITECTURE could say the server's default voice split follows Settings → Models & licences, and that /connect has a Translate & dub row. The implement stage's docs notes still apply."+ ],+ "blocked": ""+ },+ "merge": {+ "merged": [+ "o/dbs-d3"+ ],+ "notMerged": [],+ "conflicts": "none",+ "checks": "typecheck 0, lint 0; merged tree identical to origin/o/dbs-d3 aa4099f8, whose full vitest on this base passed (287 files / 4583 passed, 3 skipped)",+ "pushed": true,+ "head": "48900f7e"+ }+}diff --git a/docs/handoff/reports/n7-2-layout-mode.json b/docs/handoff/reports/n7-2-layout-mode.jsonindex 04225ed8..e912b716 100644--- a/docs/handoff/reports/n7-2-layout-mode.json+++ b/docs/handoff/reports/n7-2-layout-mode.json@@ -1,162 +1,5 @@{"key": "n7-2-layout-mode",- "impl": {- "branch": "o/n7-2-layout-mode",- "summary": "The Layout mode package is built, verified in demo mode and committed on o/n7-2-layout-mode, in /home/user/wt/o-n7-2-layout-mode. The tree is clean, all 5 commits are signed, and nothing was pushed then (the branch was later pushed to origin/o/n7-2-layout-mode at 492643b). I didn't verify real MOSS / FLUX.3 / Ideogram renders because there is no GPU and no fal key here.\n\nResuming the earlier attempt: its 3 commits were sound. But the working tree and index had the package's own changes to 15 files under src/ reverted and staged, dated 12:27, after the last commit. This looks like a check that was cut off mid-way. I restored those files from HEAD and kept the attempt's uncommitted test additions (a Reuse round trip in the unit tests and in the e2e script).\n\nThe base claude/fuobe-parity-4 had moved on since the branch was cut (cd9e5ff to f7c6d8e, which brings in acc-2 accounts and n7-6). I rebased the 3 commits onto it. The rebase had no conflicts and the commits were signed again. No pnpm-lock changes came with the new base.\n\nNew work in this session:\n- **Closing keeps your boxes:** the editor now keeps what was drawn when it is closed with Escape or by clicking outside it. Before, those boxes were lost, because the editor has no Cancel button.\n- **Shift (or Alt) drag draws over a box:** you can now draw a new box on top of another, such as a headline on a product. Before, any press on a box moved it, so you couldn't start a drag there.\n- **Nudges can be undone:** arrow-key nudges go into Undo; holding a key down counts as one step.\n- **Steady phone sheet:** the rows sheet at 390 px has a fixed height, so the canvas no longer shrinks under your finger when the first box is added.\n\nAlready on the base (from N7-1, reused, not rebuilt): src/lib/layout-prompt.ts (the neutral draft, the MOSS / FLUX.3 / Ideogram / VGL / plain-words compilers, decodeMoss, the Import parser, validateLayout, readsBoxes, carriesLayout). Also from N7-1: `options.layout` on the models and the `promptExpansion` setting. That setting switches the API's own prompt expansion off for moss-image, flux-3 and ideogram-4-5 whenever a request carries a layout.\n\nBuilt by the earlier attempt and checked now: everything the plan lists for N7-2.\n- **Composer:** `layout: true` in the Image studio and the StudioConfig flag; enterLayout / layoutRequest / leaveLayout plus withoutLayout for Reuse; the Layout chip, the strip and the Reuse path in the composer.\n- **Plan:** it compiles the draft at the size the model renders. On your GPU that is computeDimensions on a 16 px grid fitted to 2048, sent as width and height. On fal it is sizeValue clamped to 512-2048, sent as image_size. The browser's catalog keeps each route's size field so the composer prices the same canvas as the server.\n- **Server:** generations.ts never runs the prompt enhancer on a layout request.\n- **Edit layout:** fal outputs keep actual_prompt, seed and size, and ComfyUI pictures keep the seed they were drawn with. The Edit layout action and `/image?layout=<generation>` open the boxes with the same seed.\n- **Editor and picker:** the new layout-editor.tsx and its box maths in layout-edit.ts (built on layers.ts). The model list puts box-reading models first with a \"Reads boxes\" badge. Feed tiles say \"Layout · N boxes\".\n\nAccounts: the accounts core is on the base, but this package adds no routes, tables, jobs or paid calls. Edit layout reads results through the existing GET /api/generations/[id], which already goes through the accounts route handler. No migration was needed.",- "built": [- {- "feature": "Layout chip in the Image studio composer (StudioConfig.layout, IMAGE_STUDIO layout: true), strip above the prompt with box preview, Experimental badge, compiled-size line, Edit / Layout off with Undo; prompt becomes the summary caption; Enhance hidden",- "status": "done (earlier attempt), re-verified",- "verifiedHow": "tests/layout-mode.test.ts composer helper tests; tests/e2e/composer-flows.mjs section 7; my browser check at 1440/390, light and dark (screenshots)"- },- {- "feature": "Composer helpers enterLayout / layoutRequest / leaveLayout / withoutLayout, layoutShape, layoutModelNote, layoutSizeWarning, the 'Reads your boxes' group in groupModels",- "status": "done (earlier attempt)",- "verifiedHow": "vitest tests/layout-mode.test.ts"- },- {- "feature": "Plan compiles params.extra.layout at the exact render size: oss-moss-image on the 16 px grid with extra.width/height (fitted to 2048 as the ComfyUI provider fits it); fal moss-image image_size clamped to 512-2048 with the minimum respected; FLUX.3 / Ideogram 4.5 with their own compilers; other models get compileWords; a Text box without words is refused; enhancePrompt off",- "status": "done (earlier attempt)",- "verifiedHow": "vitest tests/layout-mode.test.ts (open 1360x768 and 2048x880; fal clamp 3000x300 -> 2048x512 and 300x300 -> 512x512; payload has enable_prompt_expansion false; the browser's catalog compiles the same)"- },- {- "feature": "Server never runs the prompt enhancer on a layout request (generations.ts submit)",- "status": "done (earlier attempt)",- "verifiedHow": "vitest tests/layout-mode-server.test.ts (demo mode, mock provider; enhancer mocked and never called for a layout, still called for a plain prompt)"- },- {- "feature": "Edit layout: an output action shown only when it can work (the request's own layout, or a fal MOSS actual_prompt decoded at the picture's own width and height); /image?layout=<id>[.<index>] opens Layout mode with the draft, caption, model and same seed; ComfyUI pictures keep the seed they were drawn with",- "status": "done (earlier attempt)",- "verifiedHow": "vitest tests/layout-mode.test.ts using the stored actual_prompt fixture tests/fixtures/moss-actual-prompt.json; e2e: Edit layout from a feed tile reopens the boxes (demo mode)"- },- {- "feature": "Reuse round trip (layout run comes back in Layout mode with boxes and caption, plans to the same prompt, size and seed)",- "status": "done; test changes committed this session",- "verifiedHow": "vitest Reuse test; e2e check 'Reuse brings the boxes and the caption back'"- },- {- "feature": "Layout editor (layout-editor.tsx): canvas in the chosen aspect ratio, drag to draw, numbered tabs, select / move / 8-handle resize, Delete, arrow-key nudge (Shift x10), the same spot cycles stacked boxes, Add box, Undo; rows with Object/Character/Text, what it looks like, exact words (inline error), optional colour; caption, canvas type Single/Panels/Collage, style tags; desktop rows beside the canvas, phone rows in a bottom sheet",- "status": "done (earlier attempt) plus fixes this session: closing keeps the boxes, Shift/Alt-drag draws over a box, nudges go into Undo, fixed-height phone sheet",- "verifiedHow": "My Playwright check (<the old session's scratch folder, gone>/layout-check.mjs): all checks pass at 1440 and 390 px, light and dark. Covered: drawing, moving and resizing by mouse and by touch; Shift-draw plus Undo; overlap cycling; nudge, Delete, Ctrl+Z; keyboard focus reaches every new control; the sheet folds; nothing scrolls sideways; labels fit; Escape keeps the boxes"- },- {- "feature": "Import / Export (browser only): import a Fuobe or LinXce draft, a compiled MOSS prompt read on the current canvas, a legacy scene prompt or CreateBoundingBoxes elements (paste or file); copy the compiled prompt, copy the draft JSON, download .json",- "status": "done (earlier attempt)",- "verifiedHow": "Browser check: CreateBoundingBoxes import (3 boxes), round trip through the copied compiled MOSS prompt (2 boxes, words kept), clipboard contents checked"- },- {- "feature": "Model list: box readers first with a 'Reads boxes' badge (cloud: FLUX.3, Ideogram 4.5, MOSS-Image; open: MOSS-Image); other models show 'This model reads the layout as words, not exact positions.' with a 'Use MOSS-Image' fix",- "status": "done (earlier attempt)",- "verifiedHow": "Browser: picker group contents on cloud and open; the words-model line on Nano Banana Pro"- },- {- "feature": "Warning past 2048 px a side or 4 MP, with the size the model renders instead; Experimental noted in the mode's hint, badge and strip; 'Free' price on the open engine",- "status": "done (earlier attempt)",- "verifiedHow": "Browser: oss-moss-image at 21:9 and 1.5K shows '2352 × 1008 is past 2048 px a side, so MOSS-Image renders 2048 × 880'; Generate shows Free"- },- {- "feature": "Feed tiles say 'Layout · N boxes'",- "status": "done (earlier attempt)",- "verifiedHow": "e2e 'the feed says it's a layout'"- }- ],- "tests": "- **Unit tests:** 64 test files that touch the changed modules (composer, plan, outputs, cloud catalog, comfy provider, moss-image, image studios, layout-mode and its server test, and others). 63 files and 1166 tests passed. The other file, tests/comfy-dbs.test.ts, failed to load: it imports scripts/comfy/build-library.mjs, which needs playwright-core, and scripts/comfy/node_modules is not installed in this worktree. That is a setup gap; this package doesn't touch that file.\n- **Typecheck:** `tsc --noEmit` is clean.\n- **Lint:** eslint is clean on every file the package changed.\n- **E2E:** `node tests/e2e/composer-flows.mjs` against `pnpm dev -p 3427` (FUOBE_DATA_DIR=/tmp/fuobe-o-n7-2-layout-mode-data, demo mode) passed fully, twice: all composer checks, including the 11 layout checks (draw, Text error, compiled-size strip, Generate sends the draft, feed label, compiled MOSS prompt, Reuse, Edit layout from a tile, touch draw at 390 px, sheet under the canvas, no sideways scroll).\n- **Browser check:** an extra Playwright check at 1440 and 390 px, light and dark, passed every check (about 70 checks and screenshots in <the old session's scratch folder, gone>/shots/: editor-*, strip-*, picker-*).\n- **Cleanup:** the dev server is stopped and .next is deleted.\n\nNo full suite and no pnpm build, as the stage rules say.",- "left": [- "Real MOSS-Image, FLUX.3 and Ideogram 4.5 renders, and how well they follow the boxes, are not verified: that needs a GPU (oss-moss-image on ComfyUI) or a fal key. Everything here was checked in demo mode with the mock provider.",- "Touch has no Shift key, so on phones a box can't be drawn starting on top of another one; the way round is 'Add box', then move and resize it. A long-press-to-draw gesture could be added later.",- "The size warning shows in the composer strip; the editor shows the canvas size but not the warning sentence itself.",- "On your GPU the canvas grid (16 px) and the 2048 limit come from constants in layout-prompt.ts that mirror the moss-image-t2i manifest limits; a test pins them to the manifest. A later change to the manifest limits would need those constants updated too.",- "Layouts in Canvas, Marketing, Ads and Assist (Plan layout) are package N7-8, not this one.",- "tests/comfy-dbs.test.ts can't load in this worktree until scripts/comfy dependencies (playwright-core 1.56.1) are installed. This is not about N7-2."- ],- "docsNotes": "For STATUS / ARCHITECTURE:\n- **The mode:** the Image studio has a Layout mode (chip next to Frames' place). Its draft rides as params.extra.layout. planGeneration compiles it once the render size is known: layoutCanvas, then the model's compiler (planLayout in src/lib/catalog/plan.ts).\n- **Sizes by engine:** on your GPU, exact width and height in extra on a 16 px grid, up to 2048 a side. On fal MOSS-Image, image_size equal to the canvas (512-2048) and enable_prompt_expansion false. FLUX.3 and Ideogram 4.5 use their own forms with expansion off; every other model gets plain sentences.\n- **No enhancer:** the server never runs Fuobe's prompt enhancer on a layout.\n- **Browser catalog:** slimModel now keeps a route's size field as route.preview.size, so the browser prices and compiles the same canvas as the server.\n- **Edit layout:** an output action, plus the /image?layout=<generation>[.<index>] hand-off. Its source is the request's own draft, or fal's actual_prompt decoded at the picture's size. fal MOSS outputs keep meta.actualPrompt, seed, width and height; ComfyUI image outputs keep meta.seed.\n- **Editor:** src/components/studio/layout-editor.tsx, with box maths in src/lib/layout-edit.ts (on layers.ts' rectFrom / resizeBox). Shift or Alt and drag draws over a box. Closing the editor keeps the boxes.\n- **No storage or route changes:** no migration, no new route, no new ComfyUI graph, no LoRA.\n- **Research:** no research corrections were needed."- },- "review": {- "findings": [- {- "file": "src/lib/catalog/payload.ts",- "line": 1003,- "severity": "major",- "summary": "Edit layout reopens cloud layout runs without the seed they were drawn with. extractOutputs records fal's `seed` only inside the `if (actualPrompt)` block. A layout run sends enable_prompt_expansion:false, and the research says fal returns actual_prompt only \"when expansion ran\". FLUX.3 and Ideogram 4.5 never return it. So no meta.seed is stored, and editableLayout falls back to the request's seed, which is normally unset. The plan says Edit layout opens \"with the draft and the same seed\". Separately, the fal provider sends seed+index per job, but the fallback hands every output the base seed.",- "failureScenario": "Image studio on the cloud (the default engine), MOSS-Image or FLUX.3, Layout mode, random seed, Generate, then Edit layout on the result. The toast says \"Layout opened\" with no seed, and the re-render uses a new random seed, so the whole picture changes instead of only the moved box. Verified with a scratch vitest probe: extractOutputs({images:[{url,width:1360,height:768}],seed:918273}) gives meta undefined, and editableLayout(...).seed is undefined. The repo's own test at tests/layout-mode.test.ts:239 asserts the same no-meta result.",- "verified": true- },- {- "file": "src/components/studio/studio-page.tsx",- "line": 473,- "severity": "major",- "summary": "Using Edit layout a second time on the same picture does nothing. LayoutHandoff keeps `opened.current = value` and never resets it, and it returns early when `opened.current === value`. `layout` is not in HANDOFF_PARAMS, so navigating to /image?layout=X does not bump the StudioProvider epoch, and the same LayoutHandoff instance (with its ref) survives. The early return also skips the `finally` cleanup, so ?layout=X stays in the address bar.",- "failureScenario": "In the Image studio: Edit layout on picture X, move boxes, Generate (result Y), then Edit layout on X again to try another variation from the original (or after turning Layout off). No fetch, no toast, nothing reopens until the page is reloaded. Opening a different picture in between makes X work again. Traced: handoffKey only keeps image/ref/video/audio/prompt/preset/model/format (composer.ts L720), and StudioProvider is keyed by start.epoch (studio-page.tsx L556).",- "verified": true- },- {- "file": "tests/e2e/composer-flows.mjs",- "line": 285,- "severity": "minor",- "summary": "The e2e check \"Edit layout reopens the boxes\" cannot fail. It runs right after the Reuse step, which already put the same 1-box layout in the strip. The `waitForFunction(() => !location.search.includes(\"layout=\"))` is already true before the menu click navigates, so it resolves at once. The check passes even if Edit layout does nothing, so it misses the second-click bug and does not check the seed. The ComfyUI change that copies meta.seed onto image outputs (comfyui.ts L1281 / L1495) has no test either.",- "failureScenario": "Break LayoutHandoff (for example, make it return early always). Section 7 still prints a pass for \"layout: Edit layout reopens the boxes\", because the strip shows \"1 box\" from Reuse. Verified by reading the sequence (Reuse check at L272-275, Edit layout check at L276-285). A grep of tests/ finds no test of comfyProvider.poll seed meta.",- "verified": true- },- {- "file": "src/components/studio/composer.tsx",- "line": 690,- "severity": "minor",- "summary": "The strip's \"Use MOSS-Image\" fix ignores Settings → Models & licences. boxModel comes from catalog.getModel(BOX_MODELS[engine]). getModel deliberately also finds models the admin switched off (catalog.tsx L85-L94), and the composer never checks catalog.offered() for it.",- "failureScenario": "An admin switches moss-image off. A user in Layout mode on Nano Banana Pro sees \"This model reads the layout as words… Use MOSS-Image\". Tapping it picks a model that is off, and the composer's offModel fallback (L331-332) moves straight back to the studio default. The suggested fix is a dead end. Traced in code.",- "verified": true- },- {- "file": "src/components/studio/layout-editor.tsx",- "line": 296,- "severity": "minor",- "summary": "Keyboard users cannot resize boxes. The 8 handles are aria-hidden spans driven only by pointer events, and onKeyDown handles only Ctrl+Z, Delete/Backspace and arrow-key nudges (nudgedBox). Add box always makes a box a third of each side, so a keyboard-only user is stuck at that size. Also, Delete on a focused box tab unmounts that tab and focus falls out of the canvas, so further arrow or Delete keys do nothing until the user tabs back in.",- "failureScenario": "Keyboard only: Tab to Add box and press Enter (a 1/3 × 1/3 box), Tab to its number tab, then try to make it a wide headline strip. There is no key that changes width or height. Verified by reading onKeyDown and the HANDLES markup (aria-hidden, no tabIndex).",- "verified": true- },- {- "file": "src/components/studio/layout-editor.tsx",- "line": 452,- "severity": "minor",- "summary": "Box number tabs (11 px) and row number chips (12 px) put white text on the kind colours: Text #ff9f0a about 2.1:1 and Character #34c759 about 2.2:1. Both fail WCAG AA in light and dark themes. Any colour the user picks (for example white or yellow) can make the number unreadable.",- "failureScenario": "Draw a box and set it to Text: its \"1\" tab is white on orange at 2.06:1 contrast. Computed from the sRGB relative luminance of the hex values in KIND_COLOR.",- "verified": true- },- {- "file": "src/lib/output-actions.ts",- "line": 250,- "severity": "nit",- "summary": "editableLayout returns the request's own layout even when it has zero boxes. A run made with Layout on but nothing drawn gets an Edit layout action that opens an empty canvas, while its feed tile has no \"Layout\" label.",- "failureScenario": "Turn Layout on, close the editor without drawing, type a prompt and Generate. The result menu offers Edit layout, which opens a blank layout. readLayout accepts items: [] and editableLayout has no items.length check on the `own` path.",- "verified": true- },- {- "file": "src/lib/catalog/plan.ts",- "line": 472,- "severity": "nit",- "summary": "The size line and warning for cloud models without a size field come from computeDimensions' tier table. FLUX.3's \"512sq\" and \"768sq\" are unknown tiers there and show as \"about 1360 × 768\". Words models also get the 2048/4 MP warning (\"Nano Banana Pro may place the boxes less exactly\") although they never place boxes by position.",- "failureScenario": "Probe: layoutCanvas(flux-3, 16:9, \"512sq\") returns 1360×768. With Nano Banana Pro at 2K the strip shows both the \"reads the layout as words\" line and the warning that it \"may place the boxes less exactly\".",- "verified": true- },- {- "file": "src/lib/layout-edit.ts",- "line": 14,- "severity": "nit",- "summary": "MIN_BOX_PX is measured in render pixels, not screen pixels. On a phone the canvas is drawn about 358 px wide, so for a 2048-wide render 16 px is about 2.8 screen px. A tap meant to deselect that drifts about 3 px in both directions draws a tiny box.",- "failureScenario": "390 px, oss-moss-image at 16:9 1.5K (2048×1152): tap empty canvas with slight finger drift, and a roughly 17×17 px box appears and is selected. rectFrom only rejects a side under `min` in render pixels.",- "verified": true- },- {- "file": "src/components/studio/layout-editor.tsx",- "line": 366,- "severity": "nit",- "summary": "The editor's aspect select drops \"auto\" from its options but keeps value=\"auto\". With Nano Banana Pro set to Auto, the select shows its first option (21:9) while the canvas is square (ratioOf(\"auto\") = 1).",- "failureScenario": "Nano Banana Pro, aspect Auto, Layout on: the header select reads 21:9 over a 1:1 canvas, and picking 21:9 fires no change because it already looks selected.",- "verified": true- }- ],- "checks": "Ran: vitest on tests/layout-mode.test.ts, tests/layout-mode-server.test.ts, tests/layout-prompt.test.ts and tests/moss-image.test.ts (4 files, 68 tests, all passed). `tsc --noEmit` reported no errors in package files. The only errors were Next's generated RouteContext/LayoutProps/PageProps globals, which are missing because .next was deleted, an environment gap. ESLint on every changed file: clean. Scratch vitest probes are in <the old session's scratch folder, gone>/n72review; nothing was written to the worktree. The probes covered: layout canvases for flux-3, ideogram-4-5, moss-image, oss-moss-image, nano-banana-pro and bria-fibo-2 at each tier; the Bria payload, which carries `vgl` as the research says; cloud MOSS with LoRAs keeping image_size; num_images=4 with expansion off; FLUX.3 and Ideogram edit routes with a layout; an empty caption with boxes; the Soul words path; and seed capture for fal responses without actual_prompt. Traced by reading: StudioProvider epoch and HANDOFF_PARAMS against LayoutHandoff; the engine-switch effect against the Edit layout engine change; the catalog access filter; ComfyUI seed meta; the server enhancer skip; stored request vs prompt column; and readLayout HEX colour sanitising (no CSS injection). No Higgsfield references, binaries, LoRA files or new models in the diff, so no licence data was needed. No new routes, tables or jobs, so nothing for the accounts core. All 5 commits carry gpgsig and the tree is clean.",- "verdict": "Most of the package is sound and does what the plan asks: the composer helpers, the plan compiling at the exact render size on both engines (16 px grid up to 2048 on the GPU, fal image_size kept within 512-2048), prompt expansion off and the server enhancer skipped for layouts, the browser catalog keeping the size field, Import / Export, the model list with box readers first, the feed label and the 390 px sheet. Fix two major Edit layout problems before merging. First, cloud layout runs (MOSS with expansion off, FLUX.3, Ideogram) never store fal's seed, so \"Edit layout with the same seed\" fails on the default engine whenever the seed was random. Second, reopening the same picture with Edit layout a second time in one Image studio session silently does nothing. The e2e check for Edit layout cannot fail as written, so it should be rewritten to start from a state with no layout. The rest are minor accessibility and polish items: no keyboard resize, low-contrast box numbers, and \"Use MOSS-Image\" offered when an admin has switched it off."- },"fix": {"applied": ["MAJOR payload.ts extractOutputs: fal's seed now stored on t2i/edit image outputs without actual_prompt; tests in tests/layout-mode.test.ts",diff --git a/docs/handoff/reports/n7-3-regenerate-2k.json b/docs/handoff/reports/n7-3-regenerate-2k.jsonnew file mode 100644index 00000000..f3559bd4--- /dev/null+++ b/docs/handoff/reports/n7-3-regenerate-2k.json@@ -0,0 +1,158 @@+{+ "key": "n7-3-regenerate-2k",+ "impl": {+ "branch": "o/n7-3-regenerate-2k",+ "summary": "Open-H3 Regenerate 2K is built as a finishing step that runs only on your GPU. The open engine runs a new graph, video-regenerate-h3, built from rdh9616's Draft Video example: no prompt server, curve branches off, the saved refined latent kept, and a Video Slice in front for 15 s windows. Both node packs are pinned and installed with the opt-in OPEN_H3_REGEN=1. The new model, oss-h3-regenerate, offers 1080p, 2K (the default) and 4K, with Creativity and Speed controls, and it needs words. A clip longer than 15 s is redrawn in equal parts and joined packet by packet, with a note about seams. The draft preset follows whatever made the clip, read from Fuobe's own files; an account only sees its own. Placements: Upscale → Video shows Restore · faithful (SeedVR2) and Regenerate · creative side by side, and UPSCALE_FIRST_STEPS has a Regenerate row. 'Regenerate in 2K' appears on video results and in next-step chips. A fal H3 result gets 'Re-render at 2K · a new render · $0.13/s'. Canvas has a 'Regenerate (creative)' entry. The GPU pre-flight board has a row, and Settings → Models & licences lists the licences. The cloud has no Regenerate, under the owner's 10-30 rule. Topaz Astra 2 is added under its own name.",+ "built": [+ "WIP point checked: the CPU ComfyUI's /object_info (0.41.0 @ fc04da91) has neither the core H3 latent upscaler nor the Sol-H3-VAE loader. rdh's OpenH3RegenUpscale also looks up LBH's MinimaxH3LatentUpscaler3D by class name. So the LBH pack stays, and I recorded this in new-models-10.md §5.",+ "scripts/comfy: install-comfyui.sh has an OPEN_H3_REGEN=1 block that clones rdh9616/ComfyUI-Open-H3-Regenerate @ 9b686c5 and LBH-123-AI/Comfyui_Minimax_h3_latent_Upscaler @ 40316cf; the union line is unchanged. hand-built/video-regenerate-h3.json, the library.spec.mjs entry and KNOWN_MODELS hold the LoRA, the fast VAE and the LBH upscaler, all at 5809c337. The FL2VA base was already pinned. Also added: CUSTOM_NODE_REPOS and PACK_CLASSES entries, three new LOADER_FOLDERS, the binding keys resolution / draftSize / startSigma, and a README section. The graph's curve_table is '(model's own table)' because curve_name is none, so the 21 GB ref2va file is not needed.",+ "workflows/comfyui: the manifest entry (vramGb 48, validated false, licence text, the measured-speed note), packs.json for both packs, model-pins.json with the three files' sizes and SHA-256, object_info.subset.json (BlockSparseAttention and the pack's classes as unknown), and the rebuilt requirements.json: 214.5 KB raw and 26.3 KB gzipped, inside the 216 / 27 KB budget.",+ "src/lib/catalog/regenerate.ts holds the pure parts: the tier → pack string map, the draft preset (768p for H3 sources, 576p for other models, keep for odd shapes), frames (round(s×24), at most 360), equal windows of at most 15 s, the copy, FINISH_CHOICES, the licences of the four files, regenerateHref, regenerateFamily, and the RERENDER prices with their request builder and label.",+ "models.ts: oss-h3-regenerate, with Creativity (Close 0.7, Balanced 0.8 by default, More detail = 0) and Speed (3 or 2 steps) through control sets, requires.prompt, and a promptPlaceholder (a new ModelOptions field).",+ "Server: src/server/regenerate.ts has clipMaker, which is tenant-safe and reads only through the assets → generations join, and createRegenerateRun (the preset, the windows and a copy join with oss-join-encoded), called from createGenerations. The comfyui provider fills resolution, draftSize and frames, refuses a run without words, and turns a missing_node_type error into the OPEN_H3_REGEN=1 message. The LoRA goes through graphLoras, so it downloads before a run and is part of an account's missing-file check.",+ "UI: StudioConfig.finishChoices and the new FinishChoices component, a keyboard radio group. The open engine shows both choices plus 'Free on your GPU · About 3 minutes…'. The cloud engine shows 'Regenerate · creative · Runs on your GPU (open source)' with a 'Use it on your GPU' button, and Paid APIs only shows nothing. showsPrompt shows the box for a model that needs words. The ?resolution= hand-off is added (HANDOFF_PARAMS, initialDraft). UPSCALE_FIRST_STEPS gets a 'regenerate' row with openOnly, filtered out in Paid APIs only.",+ "Result actions: 'Regenerate in 2K' for clips made on your GPU and for uploads (placed after 'Render this draft in 1080p'), and in next steps for H3 / LTX / Wan / SANA clips. It is hidden in Paid APIs only, using a new ActionContext.engineMode passed from the tile, viewer and feed. fal minimax-h3 and fuobe-character-swap results get 'rerender-2k', which re-sends the same model, operation, inputs, words and seed at resolution 2K. Other cloud results get neither action.",+ "Canvas: a palette entry 'Regenerate (creative)' (an Upscale node on oss-h3-regenerate). It is disabled with a reason on a cloud board or a cloud-only install (paletteItems now takes an optional engine). The node gets a prompt port because the model needs words, and convertEngine finds no cloud stand-in for it.",+ "GPU pre-flight: a STUDIO_ROWS row 'Regenerate in 2K' (the graph plus video-concat-encoded plus the LoRA). modelTool now counts a graph's own LoRA.",+ "Licences: NODE_PACKS entries for both packs (Apache-2.0 and MIT), a refiner LoRA row in Settings → Models & licences (MiniMax H3 Community, restricted regions, notes on the Turbo and LMS parts), and the per-file licences in REGEN_FILES and the workflow licence text. All are on by default.",+ "Cloud: topaz-astra (Topaz Astra 2) generated from the recorded topaz/upscale/video/creative schema: $0.30/s up to 1080p and $0.50/s at 4K at 30 fps, with a Creativity slider and optional words. fuobe-character-swap's price list gains 2K $0.1625/s and 4K $0.20/s, used by the re-render; Genjutsu's Quality still offers only 480p and 768p.",+ "Research: new-models-7.md §2.10 and §5.4 now note that the owner's 10-30 rule overrules their cloud column. new-models-10.md §5 notes that the installed ComfyUI has no core upscaler.",+ "Merged claude/fuobe-parity-4 (it gained nm10-flux3-klein during this work): the manifest and requirement index were rebuilt on top of the base's, and the provider's imports were joined."+ ],+ "tests": "Full Vitest after the merge: 289 files, 4637 passed, 3 skipped, 0 failed (--maxWorkers=2, FUOBE_ACCOUNT_DISK_FREE_GB=1). New file tests/regenerate-2k.test.ts, 26 tests: the graph's bindings (pack strings, frames on node 11 only, curve none, start sigma, steps, node 24 kept), pins and SHA-256, the install lines, the tier map, frames, windows for 5 / 15 / 20 / 40 s, the draft preset by source and shape, the ModelDef and its controls, the provider's values and refusals, a 40 s run in 3 parts plus a copy join with the seam note, clipMaker under account, other-account and guest tenants, actions per source and engine, the 2K re-render request / payload / price ($0.65 for 5 s), the Canvas entry, the board row, licences, and Astra's name. Updated tests: model-access-listings (177 LoRAs plus the packs) and comfy-library-4 (video-regenerate-h3 is unvalidated). tsc and eslint are clean. Browser: tests/e2e/regenerate-2k.mjs passed against pnpm dev in demo mode at 1440 and 390 px, light and dark. It covers both choices (picked with the arrow keys), the prompt box and placeholder, the price and GPU line, Creativity and Speed, the cloud line and its switch, the Regenerate row, a feed tile's menu (tapped at 390 px) opening Upscale → Video at 2K with the clip and its words, the next-step chip, the Library viewer (the phone's drawer), and the Canvas palette on both engines; no horizontal scroll anywhere. The script ignores a dev-only hydration warning from the sidebar's account row (ViewerRowPlaceholder). The graph was posted to the live CPU ComfyUI: missing_node_type, as expected, because the packs are not installed there.",+ "left": [+ "The prompt for uploads is not written automatically. The brief asks for a one-paragraph description from oss-reference-brief on the open engine, or the text LLM with frames in the cloud. That needs a new describe route (frames from the clip, the public sign-up rules, and a composer button). For now an upload opens with an empty box, its placeholder asks the person to describe the clip, and a run without words is refused in words. Results made by Fuobe arrive with their own prompt filled in.",+ "Not verifiable here: any GPU run; whether the rdh pack loads on the pinned ComfyUI 0.41.0-7 (its author tested 0.42.0); whether the ref2va base would do instead of FL2VA; VRAM below 72 GB; how seams look between 15 s parts; any fal call (the re-render and Astra 2). Validate on a disposable GPU ComfyUI with OPEN_H3_REGEN=1: node validate-workflows.mjs video-regenerate-h3.",+ "A graph-loaded LoRA that is switched off in Settings (the refiner LoRA row) is shown but not enforced at run time. The Character swap's graph LoRAs work the same way today.",+ "Re-render at 2K is offered only for fal H3 results whose request carries its own inputs (no chain). Genjutsu's chained cloud swaps therefore usually don't get it; n7-4 owns Character swap in 2K.",+ "Brief out of date: the line numbers (models.ts L423 is now ~L700, studios.ts L129 → L141, canvas.ts L230/L348 → PALETTE/PREFERRED by name, licences.ts L406 → NODE_PACKS ~L431, install-comfyui.sh L63-94 → ~L77-108). The brief's cloud fallback for the Canvas (topaz-starlight) was overruled by the owner's rule as the brief itself says. FL2VA was already pinned by the minimax-h3 graphs, and the ref2va file is not needed because the curve table is never read."+ ],+ "docsNotes": [+ "STATUS.md: Open-H3 Regenerate 2K (n7-3) is built but not validated. Upscale → Video's Regenerate · creative, 'Regenerate in 2K' on results, the Canvas 'Regenerate (creative)' entry and a GPU pre-flight row; GPU-only, opt-in OPEN_H3_REGEN=1 (about 40 GB of new files, 48 GB+ VRAM). Topaz Astra 2 added as a cloud upscaler.",+ "ARCHITECTURE.md: src/lib/catalog/regenerate.ts (pure: pack strings, draft preset, 15 s windows, copy, the cloud re-render) and src/server/regenerate.ts (clipMaker reads who made a stored clip, tenant-safe; createRegenerateRun splits and joins). StudioConfig.finishChoices, ActionContext.engineMode, ModelOptions.promptPlaceholder, paletteItems(mode, engine), UpscaleFirstStep.openOnly.",+ "FEATURES / SELF-HOSTING: the opt-in install line OPEN_H3_REGEN=1 and that the MiniMax H3 Community License territory applies (show 'MiniMax H3').",+ "Research corrections made in new-models-7.md (§2.10, §5.4) and new-models-10.md (§5)."+ ],+ "blocked": ""+ },+ "review": {+ "findings": [+ {+ "severity": "high",+ "title": "Clips that aren't 16:9 or 9:16 come out stretched: 'keep (snap to 32)' plus the pack's fixed 16:9 target",+ "where": "src/lib/catalog/regenerate.ts draftSizeFor; src/server/providers/comfyui.ts (values.draftSize); graph node 17 OpenH3RegenUpscale",+ "detail": "draftSizeFor returns 'keep (snap to 32)' for any shape more than 0.06 away from 16:9 (square, 4:3, 21:9). The pinned rdh pack's OpenH3RegenUpscale then always targets regen_core.output_size(), which is a fixed 2560x1440 (or 1440x2560 when height > width) whatever the draft's shape. LBH's MinimaxH3LatentUpscaler3D runs in TARGET_DIMENSIONS mode with an exact width and height and no crop (minimax_h3_latent_upscaler_3d.py L546-569). So a 1:1 or 4:3 draft is stretched non-uniformly to 16:9: a 1024x1024 clip comes out 2560x1440. A 'keep' draft from a large odd-shaped source can also be bigger than the target, and LBH raises 'only supports upscaling'. The preset sizes avoid this because Prepare Draft cover-crops to 16:9 first. tests/regenerate-2k.test.ts locks in 'keep' for square clips. Checked by reading the pinned code at 9b686c5 / 40316cf, read as data. Fix: use the preset (cover-crop) for every shape, or say in the UI that the result is 16:9 / 9:16."+ },+ {+ "severity": "medium",+ "title": "A client's sourceDuration decides the windows, so one request can create thousands of runs",+ "where": "src/server/regenerate.ts createRegenerateRun (seconds = original.params?.sourceDuration ?? clipSeconds(video))",+ "detail": "The window count comes from params.sourceDuration first. The request schema allows up to 36,000 s, and the stored file's own header is used only as a fallback. regenWindows(36000) returns 2400 windows (checked by running it), so one POST /api/generations, which an account can send for its own GPU, synchronously inserts 2400 part rows plus about 100 nested join rows. A wrong or stale sourceDuration also splits a real clip in the wrong places. Prefer the stored file's header (storedMedia, already tenant-safe), and cap the number of windows (for example, refuse more than N parts)."+ },+ {+ "severity": "medium",+ "title": "Clips over 15 s are cut to their first 15 s without a note on chained or Canvas runs, trimmed spans and links",+ "where": "src/server/regenerate.ts (windows = [] when deps.length or startTime/endTime set); comfyui.ts values.frames = regenFrames(length) capped at 360",+ "detail": "When the run waits on an earlier step (a Canvas Upscale 'Regenerate (creative)' node fed by a Join node or by a longer clip), when startTime/endTime are given, or when the length is unknown (a link), no windows are made. The provider then sets max_frames to at most 360, so Prepare Draft keeps only 15 s and the result is silently shorter than the input. The seam note only covers the split path. Split from the dependency's output length at launch time, or at least add a note or refuse when the span is over 15 s."+ },+ {+ "severity": "medium",+ "title": "Visitors see install jargon in Upscale → Video (rule 5)",+ "where": "src/components/studio/finish-choices.tsx (\"Free on your GPU · \" + REGEN_COPY.gpu); REGEN_COPY.missing in comfyui.ts promptRefusal",+ "detail": "The GPU line 'Needs about 40 GB of new files (OPEN_H3_REGEN=1 in install-comfyui.sh)' appears to every viewer on the open engine, guests and accounts included. It names a script file and an environment flag, which is jargon in visitor-facing text. The missing-nodes refusal also names scripts/comfy/install-comfyui.sh for accounts on their own ComfyUI. The route note 'MiniMax H3 with NVIDIA's refiner LoRA…' that the composer shows also says 'LoRA'. Show the install detail to the owner only (useIsOwner / useIsVisitor exist in src/lib/api.ts), and give visitors plain copy, for example 'Runs on your own GPU · about 3 minutes per 5 s at 2K'."+ },+ {+ "severity": "medium",+ "title": "Brief item missing: uploads get no written description",+ "where": "src/lib/output-actions.ts regenerateHref(o.url) for uploads; the composer",+ "detail": "The brief asks that uploads get a one-paragraph description from Fuobe's reading route (oss-reference-brief on the open engine), editable before the run. The implementer reports this as left: an upload opens with an empty box and a run without words is refused. Regenerate needs words, so 'Regenerate in 2K' on an upload always needs typing first. This is acknowledged in the report, not hidden."+ },+ {+ "severity": "low",+ "title": "The refiner LoRA's on/off switch in Settings → Models & licences does nothing",+ "where": "src/server/model-access.ts loraRows (REGEN_LORA row); src/server/generations.ts graphLoras",+ "detail": "The new row shows a switch, but graph-loaded LoRAs aren't checked against access.loras at run time, so switching it off doesn't stop a Regenerate run. The implementer says the Character swap's graph LoRAs work the same way today. Either enforce it (refuse a run of video-regenerate-h3 when the LoRA is off) or show it without a switch."+ },+ {+ "severity": "low",+ "title": "'Re-render at 2K' is offered where it can't help or can't run",+ "where": "src/lib/catalog/regenerate.ts canRerender; output-actions.ts",+ "detail": "canRerender doesn't look at the result's own resolution, so a fal H3 result already made at 2K or 4K still offers 'Re-render at 2K', which is a paid duplicate. It also ignores ctx.engineMode, so with Engine mode 'Open source only' the action shows and then the server refuses the paid run. Hide it when request.params.resolution is already 2K or 4K, and when engineMode is 'open'."+ },+ {+ "severity": "low",+ "title": "A hot file on main was edited: tests/comfy-library-4.test.ts",+ "where": "tests/comfy-library-4.test.ts (+2 lines: video-regenerate-h3 in the unvalidated list)",+ "detail": "Rule 2 lists this file as hot on main (do not edit; take main's version on a conflict). The one-line addition is needed to keep the test green while the packs aren't on the validation server. If main's version is taken in a merge, that test fails until the line is re-added. Flag this in the PR, or move the exception into tests/regenerate-2k.test.ts."+ },+ {+ "severity": "info",+ "title": "isH3Source matches oss-h3-regenerate and any 'hailuo' model",+ "where": "src/lib/catalog/regenerate.ts isH3Source",+ "detail": "Regenerating a clip that Regenerate already made (2K) or a Hailuo 02 clip picks the 768p H3 preset. This is harmless (Prepare Draft scales down), but it isn't the 'H3 draft' the comment describes."+ }+ ],+ "checks": [+ "Diff read in full against claude/fuobe-parity-4 (42 files). The worktree was not modified (git status clean).",+ "Graph vs pinned packs: rdh9616/ComfyUI-Open-H3-Regenerate @ 9b686c5 and LBH-123-AI/Comfyui_Minimax_h3_latent_Upscaler @ 40316cf, cloned to the scratchpad and read as data. Combo strings match INPUT_TYPES exactly: SIZES, RESOLUTION_NAMES ('1080p (1920x1080)', '2k (2560x1440)', '4k (3840x2160)'), audio 'silence (reference)', crop 'auto (1088 -> 1080, 2176 -> 2160)'. curve_name 'none' and curve_table '(model's own table)' are valid choices. max_frames applies after the 24 fps resample, so round(s×24) is right. Nodes 24 and 26 read 11's frame_count. The graph matches rdh's Draft Video example minus the note, the PreviewAny nodes and OpenH3VideoToPrompt. The upscaler bf16 .safetensors is accepted by LBH. The LBH class lookup by name is confirmed (rdh L415).",+ "Core nodes against the live CPU ComfyUI /object_info: Video Slice, BlockSparseAttention (selection.tau is a dynamic-combo sub-input), GetVideoComponents, CreateVideo, SaveVideo (format.codec), LoadVideo, RandomNoise and the loaders all exist, with valid inputs. Only the pack classes and model files are missing, as expected. Video Slice (start_time / duration, 0 = unlimited) does what the startTime / duration bindings expect.",+ "Pins: the HF tree API at Efficient-Large-Model/Open-H3-Regenerate-2K@5809c33 confirms the LoRA (12452449080 B, 8e36a091…), the fast VAE (6471256328 B, 8658f1e8…) and the latent upscaler (690592992 B, 4f57821f…). The FL2VA file exists at Comfy-Org/MiniMax-H3@1c41cfca (20970379616 B). model-pins.json, KNOWN_MODELS and REGEN_LORA.url agree.",+ "Install script: the OPEN_H3_REGEN=1 block clones both packs at the pinned SHAs, and the union line is unchanged. packs.json, CUSTOM_NODE_REPOS, PACK_CLASSES and LOADER_FOLDERS have entries. Pack licences are verified from the LICENSE files (Apache-2.0, and MIT with Copyright (c) 2026 LBH-123-AI). NODE_PACKS rows, the REGEN_FILES licences and the manifest licence text are recorded as data.",+ "Windows: regenWindows(20) gives 2×10, regenWindows(40) gives 3×13.333, and 15.04 s is one pass (360 frames). The part requests set startTime / endTime, and the provider turns them into Video Slice start / duration and frames = round(span×24). The parts are joined with joinClips copy=true (oss-join-encoded), and a part that fails to create cancels the earlier ones. regenWindows(36000) gives 2400 windows (finding 2).",+ "fal, re-checked through WebFetch and fal's OpenAPI: minimax/h3/image-to-video costs $0.05 / $0.06 / $0.13 / $0.16 per second (480p / 768p / 2K / 4K), with a resolution enum of 480P, 768P, 2K, 4K and a seed field. minimax/h3/reference-to-video/lora costs $0.0625 / $0.075 / $0.1625 / $0.20, with the same enum and a seed field. The labels and RERENDER prices match. A scratch probe (outside the repo) planned the cloud Character swap's re-render: resolution 2K is passed through ('accepts' includes 2K), the cost is $0.8125 for 5 s, and the payload carries resolution 2K and the seed.",+ "Topaz Astra 2: the fal endpoint topaz/upscale/video/creative exists. Its OpenAPI fields are video_url, upscale_factor 1-4, target_fps, creativity 0-1 (default 0.5), prompt, H264_output, sharp, realism. Prices are $3.00 / $5.00 per 10 s at 30 fps, so $0.30 / $0.50 per second, doubled at 60 fps. The generated model and pricing match, the Creativity slider reaches the payload through params.extra, and the model is named Topaz Astra 2, never Regenerate.",+ "Public sign-up: no new routes. clipMaker refuses another account's file under a tenant (fileAccount), and clipSeconds uses storedMedia, which is tenant-safe (ownsRef). stampTenant runs before createRegenerateRun (guests are refused, deps are checked as the account's own), and the route checks accountInputProblem before createGenerations. The re-render goes through POST /api/generations with the same input checks. Nothing reads an owner's record for a visitor.",+ "Rule 3: nothing in the diff links /status, /models, /workflows or /settings/about. There's no Higgsfield code, API or media, and no LoRA or media files are committed. Rule 5: see finding 4.",+ "Owner's 10-30 rule: the cloud has no Regenerate. FinishChoices shows the cloud engine 'Runs on your GPU (open source)' and returns null in Paid APIs only. UPSCALE_FIRST_STEPS openOnly is filtered. The output actions are hidden when engineMode is cloud. The Canvas entry is disabled with a reason on a cloud board or install, and counterpart() has no stand-in. Nothing routes to Starlight or H3 Max.",+ "GPU pre-flight: the STUDIO_ROWS row covers the graph, oss-join-encoded and the LoRA. requirements.json contains video-regenerate-h3, both packs and the LoRA. A rebuild with scripts/comfy/build-requirements.mjs reproduced the committed file byte for byte (git status stayed clean). The validation-state sha matches the generated graph.",+ "Full Vitest (--maxWorkers=2, FUOBE_ACCOUNT_DISK_FREE_GB=1): 289 files passed, 4637 tests passed, 3 skipped, 0 failed. tsc --noEmit: only the Next typegen names (LayoutProps / PageProps / RouteContext, because .next/types is absent) fail, and nothing in the changed code. eslint on the changed source files is clean.",+ "Not run here: the browser e2e (tests/e2e/regenerate-2k.mjs) and any GPU or fal call."+ ],+ "verdict": "changes requested: the graph, pins, licences, the GPU-only placement and the fal re-render prices check out, but clips that aren't 16:9 or 9:16 come out stretched (high), a client-supplied sourceDuration can fan one request into thousands of runs, chained or long clips are silently cut to 15 s, and visitor copy shows install jargon. Fix those before merge."+ },+ "fix": {+ "applied": [+ "Merged the local claude/fuobe-parity-4 (9aeca357, which includes origin/main) into the branch. Conflicts were resolved by keeping both sides: build-library LOADER_FOLDERS and BINDING_KEYS, library.spec CUSTOM_NODE_REPOS and PACK_CLASSES, licences NODE_PACKS, output-actions imports, generations.ts chains imports (createEndFrameClip + joinClips), and canvas paletteItems (the clean-voice filter plus the GPU-only disable). requirements.json was rebuilt with build-requirements.mjs (190 workflows, 218,272 B, inside the budget). Fetched again before the final checks: the base had not moved.",+ "(1, high) Results are no longer stretched. draftSizeFor now always returns the preset (768p for H3, 576p for others). The pinned pack's Prepare Draft cover-crops to it, and orient() turns it for a tall clip, so every result is 16:9 or 9:16 and 'keep (snap to 32)' is never sent. I checked this against rdh @ 9b686c5 regen_core.py orient / cover_crop_box. New regenShape and regenCrops functions. A run from a clip that isn't 16:9 now carries a note: 'Regenerate makes 16:9 video, so this W×H clip is cropped to 16:9 at the centre'. Upscale → Video shows 'Comes out 16:9, or 9:16 for a tall clip: other shapes are cropped to fit.' The test that locked in 'keep' now checks the preset for square and 4:3 clips. The comments in library.spec, the manifest notes and the README now say the same, and new-models-7.md §N7-4 has a correction for its 'keep' suggestion.",+ "(2) The stored file's header (storedMedia, tenant-safe) now decides the length before any client sourceDuration, which is used only for a link. More than 40 parts (10 minutes) is refused before any row is created: 'Regenerate takes up to 10 minutes of video in one run…'. Tests cover header vs sourceDuration 5 and 36000, a 36000 s link refused with no rows created, 601 s refused, and 600 s giving 40 parts.",+ "(3) Nothing is cut short without a word. A startTime/endTime span over 15 s is now split into 15 s windows inside that span (5-35 s gives 5-20 and 20-35). A run that waits for an earlier step, or a link of unknown length, gets the creation note 'This run redraws up to 15 s in one pass…'. At launch, the provider refuses a single pass over 15 s with steps to redraw it in parts, instead of capping max_frames. Splitting at launch from the dependency's output was not done (see left).",+ "(4) Visitor copy. FinishChoices shows the owner 'Free on your GPU · About 3 minutes … (OPEN_H3_REGEN=1 in install-comfyui.sh)' and guests and accounts 'Runs on your own GPU · about 3 minutes per 5 s at 2K' (useIsOwner). On an account's own ComfyUI (ownGpu) the missing-nodes refusal says 'Your ComfyUI doesn't have Open-H3 Regenerate yet. Add it with Fuobe's ComfyUI setup, then run this again.' The route note is now 'Built on MiniMax H3: redraws the clip at 24 fps, up to 15 s a pass, keeping its sound', with no LoRA mentioned.",+ "(5) Uploads get words. With Regenerate picked on the open engine, a clip attached and an empty prompt box, Upscale → Video shows 'Describe the clip for me'. It runs oss-reference-brief (Gemma 4, the existing validated reference-brief-gemma4 graph) through POST /api/generations, with a one-paragraph instruction in params.extra.instruction over the first 15 s. It waits for the result and fills the prompt box to edit. It never overwrites typed words, and shows a plain toast when nothing comes back. The pieces are regenDescribeRequest and regenDescription (pure, tested), plus a provider test that the instruction reaches node 3 and the frames cover 15 s. This adds no new route: it goes through POST /api/generations with its account checks.",+ "(6) The refiner LoRA switch is now enforced. With open_h3_regenerate_2k_lora switched off in Settings → Models & licences, a Regenerate run is refused when it is created. The owner is told where the switch is; a visitor gets 'Regenerate isn't available right now. Pick Restore · faithful…'. Tested for both.",+ "(7) 'Re-render at 2K' is hidden when the result's resolution is already 2K or 4K (also 1440p or 2160p, any case) and with Engine mode 'Open source only' (canRerender takes ctx.engineMode). Tested.",+ "(8, partly) The comfy-library-4 diff against the base is now a single added id line (the comment is moved out). tests/regenerate-2k.test.ts now holds the check that video-regenerate-h3 stays unvalidated and lists both packs. Main's Restore skip line kept by the merge is untouched.",+ "Browser: tests/e2e/regenerate-2k.mjs was extended (the shape line, the owner's GPU line, and Describe the clip for me reached by keyboard and filling the box) and re-run against pnpm dev in demo mode at 1440 and 390 px, light and dark: all checks pass and nothing scrolls sideways. I killed only this worktree's dev server and deleted .next."+ ],+ "rejected": [+ "(8) Restoring tests/comfy-library-4.test.ts byte for byte to the base's version can't be done while the full suite stays green. Its 'keeps the whole library validated' test compares the exact list of unvalidated workflow ids with toEqual. video-regenerate-h3 is validated:false, and must stay so until it runs on a GPU, because its packs aren't on the validation server. I confirmed it: with the base's file, that test fails. Another test file can't change it. So the hot file keeps one added line ('video-regenerate-h3' at the end of the list), and the same check also lives in tests/regenerate-2k.test.ts. On a conflict, take main's version and re-add that one line. Flag it in the PR.",+ "Review info: isH3Source matching oss-h3-regenerate and hailuo is harmless, as the reviewer says (Prepare Draft scales down). Not changed."+ ],+ "checks": [+ "npx next typegen, then pnpm typecheck: exit 0.",+ "pnpm lint: exit 0 (one warning, WAN_NEG_EN unused in library.spec.mjs, which comes from the base).",+ "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 1. 307 files, 4872 passed, 3 skipped, 6 failed. All 6 are the known failures from main (main-rules item 8): comfy-reuse (pack licence record), dop-originals (effect-acid), preset-featured (126 vs 127), soul-runs (2), split-soundtrack ('has no cloud route'). Nothing else fails.",+ "tests/regenerate-2k.test.ts: 35 tests pass (9 new).",+ "Browser e2e (tests/e2e/regenerate-2k.mjs) against pnpm dev in demo mode: every check passes at 1440 and 390 px in light and dark. The visitor view of the GPU line was not run in a browser (it needs a password and an account); the copy and the useIsOwner switch are covered by reading the code and by unit tests of the copy.",+ "Fetched origin again after the work: claude/fuobe-parity-4 is still 9aeca357, already merged. Pushed o/n7-3-regenerate-2k (372c2b90). git status is clean and .next is deleted."+ ],+ "finalSummary": "Open engine (your ComfyUI): Upscale → Video offers Restore · faithful (SeedVR2) and Regenerate · creative (Open-H3 Regenerate) side by side. Regenerate redraws at 1080p, 2K or 4K. Every shape comes out 16:9 or 9:16 by centre crop, never stretched, and the UI says so, with a note on runs from other shapes. A clip over 15 s is split by the stored file's own length into up to 40 parts (10 minutes) and joined with a seam note. A trimmed span is split inside the span. A single pass over 15 s (a Canvas or chained step) is refused with how to redraw it in parts, never cut short. An upload can have 'Describe the clip for me' (Gemma 4 on your GPU) fill its words. Switching the refiner LoRA off in Settings stops runs. All of this is built and unit-tested and the UI is browser-checked; no GPU run was possible here, so the graph stays unvalidated. It needs a GPU ComfyUI with OPEN_H3_REGEN=1, about 40 GB of files and 48 GB+ of VRAM; the describe step needs the Gemma 4 E4B reference-brief graph. Cloud engine: no Regenerate (GPU-only by the owner's rule). It says 'Runs on your GPU (open source)' and is hidden in Paid APIs only. A fal MiniMax H3 or Character swap result made below 2K offers 'Re-render at 2K · a new render · $0.13/s' ($0.1625/s on the LoRA route). This is hidden for results already at 2K or 4K and in Open source only. Topaz Astra 2 is a separately named upscaler. These need a fal key and are untested against fal here. Public sign-up: guests can browse; their runs are refused as before. Accounts run Regenerate and the describe step only on their own GPU, through POST /api/generations with the existing input checks. clipMaker and the header read are tenant-safe, so an account never learns about the owner's runs. Visitors see plain copy with no install flags, file names or 'LoRA'; the owner sees the install detail.",+ "left": [+ "Splitting a dependent (Canvas or chained) Regenerate into 15 s parts when it launches, using the dependency's output length, is not built: it would mean creating rows inside the launch path in generations.ts. Such a run now carries a one-pass note and is refused at launch when the clip is over 15 s; regenerating the finished clip from its result splits it.",+ "The 'Describe the clip for me' read appears as a text result (feature regenerate-describe) in the Library. It only runs where oss-reference-brief is offered, and the GPU pre-flight row for Regenerate doesn't list the Gemma 4 graph as an optional extra.",+ "The visitor view (account) of the Upscale → Video GPU line was not browser-checked: the demo dev server runs without a password.",+ "As before: any GPU run (validate on a disposable GPU ComfyUI with OPEN_H3_REGEN=1: node validate-workflows.mjs video-regenerate-h3), whether the rdh pack loads on ComfyUI 0.41.0-7, VRAM below 72 GB, how seams look, and any fal call. Re-render isn't offered on chained cloud swaps (n7-4).",+ "The PR should note the one-line exception in the hot file tests/comfy-library-4.test.ts."+ ],+ "blocked": ""+ },+ "merge": {+ "merged": [+ "o/n7-3-regenerate-2k"+ ],+ "notMerged": [],+ "conflicts": "none",+ "checks": "typecheck 0, lint 0; merged tree identical to origin/o/n7-3-regenerate-2k 372c2b90, whose full vitest on this base: 4872 passed, 3 skipped, 6 failed (the 6 known failures that also fail on clean origin/main d49e9b2)",+ "pushed": true,+ "head": "88f75ff4"+ }+}diff --git a/docs/handoff/reports/nm10-flux3-klein.json b/docs/handoff/reports/nm10-flux3-klein.jsonnew file mode 100644index 00000000..ca2fa40b--- /dev/null+++ b/docs/handoff/reports/nm10-flux3-klein.json@@ -0,0 +1,128 @@+{+ "key": "nm10-flux3-klein",+ "impl": {+ "branch": "o/nm10-flux3-klein",+ "summary": "FLUX 3 Image Klein now runs on both engines. Open engine: oss-flux3-klein does text to image (up to 4K) and edits with up to 10 references on two new core-node ComfyUI graphs; oss-flux3-klein-base runs Klein Base with LoRAs. All three graphs are validated on the CPU ComfyUI. Options → Prompt helper (BFL's upsampler) is on by default; when it is off, or a layout is attached, the provider takes it out. Cloud engine: flux-3-klein runs fal's text-to-image and edit routes, and a run with LoRAs goes to their /lora twins. flux-3-klein-base runs Klein Base's LoRA routes. A layout goes to fal's bounding_boxes with prompt expansion off. Soul ID gains a FLUX 3 Klein family, trained on fal's Klein Base trainer or on AI-Toolkit's flux3 model. Licences are recorded as information and stay switched on. Nothing became a default.",+ "built": [+ "Research: scripts/fetch-hosted-schemas.py --new10 read fal's six Klein endpoints into docs/research/new-models-10.json endpointRecords (all active) and the two Klein Base trainers into fuobe-originals-recipes-5.json trainers[]. Re-checked at the source on 2026-11-01: per-image prices $0.008 at 768² / $0.009 at 1K / $0.011 at 1.5K / $0.014 at 2K / $0.036 at 4K (fal calls them 'planned'); /lora $0.012/MP; Klein Base /lora $0.035/MP; trainer $0.0043 a step with at least 100 billed; loras ≤3 of {path, scale 0-4}; image_size 256-4096; num_images 1-4; bounding_boxes take {box {x_min,y_min,x_max,y_max} as fractions, label, description}, at most 32. HF revisions 337337621b85 and feef60b0 confirmed. The licence was read from the card.",+ "Cloud catalog (scripts/gen-cloud-models.py → cloud-models.generated.ts): model flux-3-klein. Its t2i and edit routes have loraEndpoint set to the /lora twins. tier_size reads 1K/1.5K/2K/4K from the price line, so image_size is the aspect ratio on the tier's square (FieldMap.size.bases). Pricing is per image byResolution, plus Pricing.withLorasPerMegapixel 0.012 for LoRA runs. Model flux-3-klein-base has LoRA routes only at $0.035/MP. FieldMap.boundingBoxes comes from the research keyFields.",+ "Layout: flux3Caption and flux3Boxes in src/lib/layout-prompt.ts share compileFlux3's rows. On fal, planLayout sends the boxes in bounding_boxes and the caption naming <obj_N> as the prompt. On the GPU the compileFlux3 table is the prompt. fal's limits (32 boxes, 500 characters a box) are checked before a run.",+ "ComfyUI graphs, hand-built from Comfy-Org's image_flux3_klein_* templates using core nodes only:",+ "flux3-klein-t2i: 16 steps, er_sde.",+ "flux3-klein-edit: ten LoadImage nodes feed ReferenceMultiLatent and the helper's BatchImagesNode; 16 steps, euler; the result takes reference 1's shape.",+ "flux3-klein-base-t2i-lora: 50 steps, CFG 3.5; LoRAs are injected after the loader.",+ "All three run TextGenerate on BFL's w4a8 upsampler with the pup repo's t2i/i2i system prompts (Apache-2.0) and the card's greedy decoding.",+ "Build, validation and the requirements index: build and validate-workflows passed 3/3 on the live CPU ComfyUI. Binding keys image5..image10 added. Files are pinned in model-pins.json (revision feef60b0, exact sizes) and marked gated. A gated optional file is now marked gated too. requirements.json is rebuilt. No new pack.",+ "Provider (src/server/providers/comfyui.ts): binds up to 10 reference slots. ReferenceMultiLatent and BatchImagesNode are optional-reference encoders, so unused references drop from the last. skipPromptHelper (src/lib/comfy.ts) runs for PROMPT_HELPER_GRAPHS when promptHelper is 'off' or a layout is attached. An 11th image is refused by the plan (route maxImages 10), not dropped.",+ "Open ModelDefs: oss-flux3-klein (t2i + edit, maxImages 10, layout flux3, Prompt helper control) and oss-flux3-klein-base. Placed after Qwen-Image 2.1 Turbo with the top badge, so the Image studio's Best list on your GPU is Ideogram 4, Qwen-Image 2.1, FLUX 3 Klein, Krea 2 Realism, and the Edit studio's includes Klein. The Image studio takes 10 references and the Edit studio 1 image + 9 references, each capped by the model.",+ "Training: TrainingFamily flux3-klein (lead oss-flux3-klein-base / flux-3-klein-base; also runs on the distilled models). Target fal-flux3-klein: 1,000 steps for $4.30, resolution 1024, trigger_phrase. Target aitk-flux3-klein: AI-Toolkit's flux3 arch on black-forest-labs/flux-3-image-klein-base with convrot8 and shift timesteps. Both say the licence is not blanket permission for commercial fine-tuning. gen-trainers reads 'per training step' and 'minimum N steps', and leaves the edit trainer's per-reference price unpriced rather than guess it.",+ "Licences (information only): KLEIN_LICENSE on the graphs; the FLUX Kommunity License reads as class 'conditions'; the cloud models carry ModelLicence. Settings → LoRAs names the 'FLUX 3 Klein' base. Assist's model summary now includes readsLayoutBoxes, the weights' licence and the per-megapixel LoRA price.",+ "Canvas image node: lists all four Klein models (catalog-driven, with a test). The GPU pre-flight picks up the models as tools automatically; no new studio row was needed.",+ "Research corrections are recorded in docs/research/new-models-10.md §7."+ ],+ "tests": "New file tests/flux3-klein.test.ts (19 tests) covers: the three graphs' bindings, limits, pins, sizes and gating; the provider's helper skip, reference dropping and LoRA injection; every fal route's payload (image_size per tier, LoRA list and /lora endpoint, bounding_boxes from compileFlux3's rows, prompt expansion off with a layout, the 32-box and 500-character limits); prices at 1024 and 2048 ($0.009/$0.014 per image; $0.012/$0.048 with LoRAs; Base $0.035/$0.14); the training target's pricing and request body; the AI-Toolkit job; the Best lists; the Canvas choices. Existing tests updated: open-sota-studios (Best lists), licences, gpu-readiness, gpu-requirements (size budget, merged with main's raised 216 KB/27 KB, plus Klein's gated repo), training, open-engine, cloud-catalog. Browser: tests/e2e/flux3-klein.mjs, 123 checks, all passed at 1440 and 390 px in light and dark, in demo mode and again with FAL_KEY=anything. It covers the Image studio picker on both engines, the Best list, the price before the run, the Prompt helper with its text not cut off, the Edit studio with an image and 9 references, the Train dialog's FLUX 3 Klein section ($4.30 / Free / licence) and both Settings rows switched on, with no sideways scroll. Full Vitest suite with --maxWorkers=2 after merging the latest claude/fuobe-parity-4: 4585 passed, 1 failed, 3 skipped. The one failure, tests/gpu-api.test.ts 'stops a run whose model is missing…', got 503 'The studio is short of space' because this machine has 18 GB free, below the account disk floor. It passes with FUOBE_ACCOUNT_DISK_FREE_GB=1, so it comes from the environment, not this package. tsc is clean.",+ "left": [+ "Needs a GPU (none here): a real Klein run on each graph; the edit with 10 references at about 1 MP each; the VRAM figure (vramGb 16 is an estimate from the 16-24 GB range); whether the w4a8 upsampler runs on every card (MOSS's w4a8 encoder once faulted a driver); whether a LoRA from fal's trainer or AI-Toolkit loads in ComfyUI's LoraLoaderModelOnly on Klein; AI-Toolkit training of flux3.",+ "Needs a fal key: real calls to the six routes and the trainer. fal still calls the per-image tiers 'planned'.",+ "Not done: an open-engine trainer for edit LoRAs (fal's /base/trainer/edit is recorded but unused); the cloud's plain /base/text-to-image and /base/edit-image endpoints (not in fal's catalog listing); the upsampler's *_bbox system prompts for layouts (a layout skips the helper on both engines instead).",+ "The model files' SHA-256 can't be read without an HF token (the gated tree hides them), so model-pins has revision and size only. Pin them with `node scripts/comfy/build-requirements.mjs --refresh-pins` and HF_TOKEN.",+ "Brief deviations: (1) no separate oss-flux3-klein-edit. oss-flux3-klein carries both t2i and edit, as the cloud flux-3-klein does, and a separate edit model would have appeared twice in the Edit picker. oss-flux3-klein-base and flux-3-klein-base were added for the Base LoRA graph and fal's Base LoRA routes. (2) Out-of-date details in the brief: the repack is black-forest-labs/flux-3-image-klein-comfy, not Comfy-Org; Fuobe's install pin is fc04da91 (v0.41.0-7) and already has every class, so no pin bump; compileFlux3 is no longer at L511.",+ "Owner call: Klein in the Edit studio's Best list pushes out FIBO 2 Edit Turbo, and MOSS-Image leaves the Image Best list. Arena note for the PR: 1043 Elo vs Qwen-Image 2.1's 1042 on Artificial Analysis' October arena (as cited by Freefield)."+ ],+ "docsNotes": "STATUS / FEATURES (for the docs pass): FLUX 3 Image Klein on both engines. Open engine: t2i up to 4K, edits with 10 references, a layout table, Prompt helper on by default, Klein Base with LoRAs. Cloud engine: fal, $0.009/image at 1K, $0.012/MP with LoRAs, Klein Base $0.035/MP, layout as bounding_boxes. Soul ID 'FLUX 3 Klein' trains on fal ($4.30 for 1,000 steps) or AI-Toolkit (flux3). ARCHITECTURE needs four notes: FieldMap.boundingBoxes and FieldMap.size.bases; Pricing.withLorasPerMegapixel; PROMPT_HELPER_GRAPHS / skipPromptHelper and params.extra.promptHelper; the provider binds image5..image10 and ReferenceMultiLatent/BatchImagesNode are optional-reference encoders. scripts/comfy/README.md could list the flux3-klein-* graphs, the gated BFL repack and the HF token. Research corrections are in new-models-10.md §7. The PR should cite the arena Elo.",+ "blocked": ""+ },+ "review": {+ "findings": [+ {+ "severity": "medium",+ "title": "Cloud FLUX 3 Klein edits always come out at the chosen aspect ratio (1:1 by default), not the photo's shape, while the GPU edit keeps reference 1's shape",+ "where": "scripts/gen-cloud-models.py tier_size branch (build_route) -> FieldMap.size on both edit routes of flux-3-klein and flux-3-klein-base in src/lib/catalog/cloud-models.generated.ts; src/lib/catalog/payload.ts L459-464 (always writes image_size); src/server/generations.ts sizedMixedFrame/SIZED_EDITS (the existing precedent, not applied here)",+ "detail": "planGeneration merges model.defaults {aspectRatio: '1:1', resolution: '1K'}, and buildPayload always writes image_size from it. A probe plan of an Edit studio run (feature edit, one image, no params) on flux-3-klein sends image_size {width:1024,height:1024}, so a 16:9 photo comes back as a 1024x1024 square. fal's schema makes image_size nullable: 'If not set, a single reference image's own size (scaled to at most 4 megapixels) is used, or the first reference image's size (at most 1 megapixel) when several are given'. The GPU route for the same model is `unsized` and follows reference 1. Klein's two edit routes are the only cloud edit routes in the catalog that always send a size object (probe over MODELS). The two engines behave differently and the UI does not say so. No test covers a default-sized cloud edit.",+ "fix": "Size the cloud edit from reference 1's shape at the chosen tier, as sizedMixedFrame does for MIXED_ORIGINAL/ANGLES_ORIGINAL (localHead -> imageSize -> fit on the tier's square). This keeps the price predictable. Or offer an 'auto' (keep shape) aspect that leaves image_size out. Add a payload test for the default edit."+ },+ {+ "severity": "low-medium",+ "title": "The cloud engine has no Prompt helper switch, although fal's endpoints accept enable_prompt_expansion",+ "where": "src/lib/catalog/models.ts KLEIN_PROMPT_HELPER (open models only); payload.ts L529 (promptExpansion is only ever set to false for a layout)",+ "detail": "On the GPU, Options -> Prompt helper on/off chooses between BFL's upsampler and the words as typed. On the cloud, flux-3-klein and flux-3-klein-base always run fal's expansion (default true) unless a layout is attached. All six fal routes take a boolean enable_prompt_expansion (re-read from fal's OpenAPI on 2026-11-01). Under the owner's rule (each engine does all the hosted endpoint supports, and says so), the cloud user should be able to send a full caption as typed. The UI currently shows the control only on one engine and gives no reason.",+ "fix": "Give the cloud models the same 'Prompt helper' control, mapped to enable_prompt_expansion (on = API default, off = false), and keep it false whenever a layout is attached."+ },+ {+ "severity": "low",+ "title": "Layout mode switches off BFL's prompt helper on both engines, even with zero boxes, and the UI never says so",+ "where": "src/server/providers/comfyui.ts (carriesLayout -> skipPromptHelper); payload.ts L529; composer enterLayout/layoutRequest attach an empty draft",+ "detail": "carriesLayout() is true for an empty draft. A probe of a cloud layout with no items sends enable_prompt_expansion:false, and on the GPU the helper branch is removed. BFL's -comfy card says its workflows run the upsampler 'including with reference images and bounding boxes', and the pup repo ships t2i_bbox/i2i_bbox system prompts for that case. The implementer recorded this choice under 'left'. Still, a user who sets Prompt helper to On has it silently overridden in Layout mode, and the label ('On · writes a full caption') does not mention it. On fal, turning expansion off with boxes is what the brief asked for.",+ "fix": "At least name the override in the control's label or in the Layout mode hint. Later, run the helper with the *_bbox system prompts on the GPU, and skip the override when the draft has no boxes."+ },+ {+ "severity": "low",+ "title": "fal does host plain Klein Base text-to-image and edit, so a Base run without LoRAs is priced on the /lora route",+ "where": "flux-3-klein-base in scripts/gen-cloud-models.py; implementer's 'left' note ('not in fal's catalog listing')",+ "detail": "fal.ai/models/blackforestlabs/flux-3/klein/base/text-to-image exists ('FLUX.3 Klein Base (Text to Image) API on fal', planned per-image pricing 768: $0.024, 1K: $0.027, 1.5K: $0.033, 2K: $0.042, 4K: $0.108), and its OpenAPI schema and base/edit-image's both resolve. flux-3-klein-base runs everything on /base/*/lora at $0.035/MP, LoRAs or not. A Base run without LoRAs costs $0.56 at 4K on the /lora route against the planned $0.108. The model's name ('with LoRAs') makes it an edge case, but the research note's statement is wrong.",+ "fix": "Record base/text-to-image and base/edit-image in new-models-10.json. Either add them as flux-3-klein-base's plain routes, with the /lora twins as loraEndpoint (the same pattern as flux-3-klein), or correct the note."+ },+ {+ "severity": "low (judgement / owner call)",+ "title": "Best lists: Image follows the brief; Edit goes beyond it and drops FIBO 2 Edit Turbo",+ "where": "src/lib/catalog/models.ts (oss-flux3-klein with the 'top' badge, placed after Qwen-Image 2.1 Turbo); tests/open-sota-studios.test.ts",+ "detail": "Measured with studioBest on base vs branch. Image (open): [Ideogram 4, Qwen-Image 2.1, Krea 2 Realism, MOSS-Image] -> [Ideogram 4, Qwen-Image 2.1, FLUX 3 Klein, Krea 2 Realism]. Edit (open): [Qwen-Image 2.1, Qwen-Image 2.1 Turbo, FIBO 2 Dev, FIBO 2 Edit Turbo] -> [Qwen-Image 2.1, Qwen-Image 2.1 Turbo, FLUX 3 Klein, FIBO 2 Dev]. Cloud lists are unchanged, and both defaults stay. The brief asks for Klein in the Image Best list 'beside Ideogram 4 and Qwen-Image 2.1', and third place does that. With four slots, one model has to go; MOSS-Image is a reasonable choice because Klein also places layout boxes, and Krea 2 Realism keeps the owner's order. The brief asks only for multi-reference in the Edit studio, not a Best-list place. Klein lands there because the 'top' badge applies to every operation, which pushes out the only light, fast FIBO edit. It is defensible (10 references, top arena model), but it is the owner's call, and the implementer flagged it as one. No owner decision in owner-decisions.json covers Best-list ranking.",+ "fix": "No code change needed. Put both drops in the PR's owner questions, as the implementer proposed."+ }+ ],+ "checks": [+ "Worktree /home/user/wt/o-nm10-flux3-klein at 5016615d = o/nm10-flux3-klein, which contains claude/fuobe-parity-4 (f31680b6). Read every source diff (models, cloud generator and catalog, payload, plan, types, comfy.ts, layout-prompt, licences, studios, assist, comfyui provider, training, trainers, library spec, the three graphs, manifest, pins, requirements, tests).",+ "fal at the source (OpenAPI queue schemas for all 10 Klein endpoint ids, and model pages): every input in new-models-10.json matches. image_size is 256-4096 a side, multiple of 16, max_area 4096^2, nullable on edits. num_images is 1-4. loras is at most 3 of {path (required), scale 0-4}, default []. image_urls is 1-10. bounding_boxes is at most 32, label maxLength 64, description maxLength 500 and required, box x/y_min/max as 0-1 fractions. enable_prompt_expansion defaults to true. Prices: t2i/edit per image $0.008 at 768, $0.009 at 1K, $0.011 at 1.5K, $0.014 at 2K, $0.036 at 4K ('planned'); /lora $0.012/MP; base /lora $0.035/MP; trainer $0.0043 a step, minimum 100 ($4.30 for 1,000), output lora_file; trainer/edit $0.002 a step times a per-reference factor, so leaving it unpriced is right.",+ "Hugging Face: black-forest-labs/flux-3-image-klein @ 337337621b85…, -comfy @ feef60b0aaf6… and -base @ 3f7fa5ee all exist, are gated 'auto' and carry licence 'flux-kommunity-license'. The repack is BFL's (Comfy-Org/flux-3-image-klein returns 401/none), so the implementer's correction of the brief is right. All 7 pinned sizes match the HF tree exactly. The shared qwen3vl_4b_int8_convrot (Comfy-Org/Fibo-2.0) is 4858559240 bytes, the same size as BFL's copy. The card's licence text matches the recorded note: non-commercial; commercial outputs for Qualifying Users under US$5M including affiliates; 'not blanket permission for commercial fine-tuning or distribution'; Qwen3-VL-4B encoder and the prompt upsampler Apache-2.0 (pup repo cardData apache-2.0).",+ "The graphs' system prompts are byte-identical to pup@3f3edb52's system_prompts.json t2i/i2i. Decoding: top_k 1 with temperature 1 equals the card's greedy; presence 1.5 for t2i and 0 for edit, as the card says. The graphs match Comfy-Org's image_flux3_klein_distilled_t2i (er_sde, w4a8 upsampler, the same TextGenerate widgets; the card's 16 steps against the template's 15) and _image_edit (16 steps, euler, ReferenceMultiLatent resize 1 MP, ConditioningZeroOut, BatchImagesNode).",+ "Live CPU ComfyUI (v0.41.0-7, fc04da91, the install pin) /object_info: TextGenerate (sampling_mode.* incl. optional presence_penalty, thinking, use_default_template, mtp, system_prompt, image), ReferenceMultiLatent (outputs positive/negative/empty_latent; images autogrow, optional), BatchImagesNode, EmptyFlux2LatentImage, CLIPLoader type 'flux3', LoraLoaderModelOnly and the er_sde sampler are all present, so no pin bump is needed. Nothing was posted or installed.",+ "AI-Toolkit (sparse clone of ostris/ai-toolkit main, HEAD e9c72b7, 2026-10-31) has extensions_built_in/diffusion_models/flux3 with arch 'flux3' and match_target_res. Fuobe pins no AI-Toolkit version, so the aitk-flux3-klein target is justified.",+ "Probes (scratch vitest outside the repo): cloud edit default payload is image_size 1024x1024 (finding 1). Prices: 1K $0.009, 2K $0.014, 4K $0.036; with LoRAs $0.012, $0.048, $0.192 (1:1); Base $0.035, $0.14, $0.56. These match fal's per-MP rule. Image studio with 10 refs on oss-flux3-klein plans an edit. A GPU edit with a layout gets compileFlux3's table as its prompt. A cloud edit with a layout sends bounding_boxes and enable_prompt_expansion:false and leaves `layout` out of the body. The composer's pickModel resets params, so the GPU-only promptHelper extra does not leak into fal payloads.",+ "Provider: the prompt helper is skipped only for PROMPT_HELPER_GRAPHS. The new `delete extra[LAYOUT_PARAM]` is safe because no manifest graph binds 'layout'. image5-image10 drop from the last. LoRAs are injected generically after UNETLoader, so the distilled graphs also take FLUX 3 Klein LoRAs, and no local capability is removed.",+ "Public sign-up: no new routes, pages or server paths. Account runs go through accountInputProblem, which checks every value in inputs (all 10 images). The GPU pre-flight picks up the open models automatically, and requirements.json lists the three graphs, with the gated files marked gated (the hf-licence need).",+ "Licences are data: KLEIN_LICENSE on the manifest graphs, ModelLicence on the cloud models (commercial null), and the 'FLUX Kommunity License' KNOWN row with class 'conditions'. All four models start on. No Higgsfield API, code, prompts or media; no LoRA files committed.",+ "Full Vitest suite (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 287 files, 4586 passed, 3 skipped, 0 failed. tsc --noEmit is clean. Both worktrees are unchanged (git status empty). The e2e browser script was read but not re-run."+ ],+ "verdict": "Approve with fixes. The package is correct and well verified at the source: schemas, prices, HF revisions, sizes, licence, system prompts, node classes and AI-Toolkit support all check out. Tests and types are green, and there are no sign-up, security or licence-as-gate problems. Before merge, fix finding 1: cloud Klein edits come out square by default, while the GPU keeps the photo's shape. Finding 2, a cloud Prompt helper on enable_prompt_expansion, is a small parity gap worth closing in the same pass. Findings 3 and 4 are notes. Finding 5, the MOSS-Image and FIBO 2 Edit Turbo drops, is an owner call: the Image Best list follows the brief, and the Edit Best list goes beyond it, which the PR should flag."+ },+ "fix": {+ "applied": [+ "Finding 1 (medium, confirmed: a default cloud edit plan sent image_size 1024x1024): cloud Klein edits (flux-3-klein, flux-3-klein-base) are now sized from reference 1's shape at the chosen tier. ModelRoute.followsImage is a new route flag that gen-cloud-models.py emits on both edit routes. sizedEdit in src/server/generations.ts runs beside sizedMixedFrame: it reads image 1's header (localHead -> imageSize) and puts the shape on the tier's square with sizeValue (16 px grid, 256-4096), so a 4000x2250 photo at 1K goes as 1360x768. A size the request gives itself wins, and a picture that isn't a file in Fuobe keeps the aspect ratio's size. The per-image tier price is unchanged, and the LoRA per-megapixel price reads the size sent. The composer (settingsShape) shows Resolution but no Aspect ratio for these edits, so the UI says what happens. Payload and run tests (createGenerations through the demo provider), plus a browser check.",+ "Finding 2 (low-medium, confirmed: all six fal routes take enable_prompt_expansion): the cloud Klein models get the same Options -> Prompt helper control (param promptHelper). 'off' sends enable_prompt_expansion false; 'on' leaves fal's default. promptHelper is never sent to fal: it is in each route's map.ignore and in payload.ts's ignore set. A layout with boxes still forces expansion off. Covered by payload tests for all four routes and a browser check on the cloud.",+ "Finding 3 (low, confirmed: an empty draft turned the helper off): the override now applies only when the draft places at least one box (carriesBoxes in src/lib/layout-prompt.ts). On your GPU this is skipPromptHelper in the comfyui provider; on fal it is the payload's promptExpansion for routes with boundingBoxes. Other models' expansion still goes off for any layout. The 'on' label names the override: 'On · full caption (not with boxes)', shortened because the first wording was cut off in the browser at 390 and 1440 px. Tests cover an empty draft keeping the helper on both engines.",+ "Finding 4 (low, confirmed: both endpoints are active and in fal's catalog): fal's plain blackforestlabs/flux-3/klein/base/text-to-image and base/edit-image were read with scripts/fetch-hosted-schemas.py --new10 <endpoint…>, which now takes endpoint ids and parses the '1K: $0.027' price form. They went into new-models-10.json endpointRecords and are now flux-3-klein-base's routes, with the /lora twins as loraEndpoint. Pricing is per image: $0.027 at 1K, $0.033 at 1.5K, $0.042 at 2K, $0.108 at 4K, plus withLorasPerMegapixel 0.035. The model is renamed 'FLUX 3 Klein Base'. The research note in new-models-10.md is corrected. The preview API on a fal-key server confirms 4K without LoRAs at $0.108 on the plain route, and 1K with a LoRA at $0.035 on /lora.",+ "Finding 5 / main-session call (5): ModelDef.bestOps restricts the operations whose Best lists may rank a model by its badges. oss-flux3-klein has bestOps ['t2i'], so the Edit studio's open Best list is back to the base [Qwen-Image 2.1, Qwen-Image 2.1 Turbo, FIBO 2 Dev, FIBO 2 Edit Turbo]. Klein is still offered in the Edit studio, and the Image Best list stays as built (Ideogram 4, Qwen-Image 2.1, FLUX 3 Klein, Krea 2 Realism). Tests in open-sota-studios and flux3-klein."+ ],+ "rejected": [+ "None of the findings were rejected. Finding 3's later suggestion (run the upsampler with BFL's *_bbox system prompts on the GPU, so the helper also runs with boxes) was not built; it stays under 'left'. The main session's call (3) asked only for the boxes-only override and the label."+ ],+ "checks": [+ "Worktree /home/user/wt/o-nm10-flux3-klein: claude/fuobe-parity-4..HEAD lists only this package's commits and a merge of the base. The base (f31680b6, unchanged after the fetch) is already an ancestor, so no merge was needed.",+ "pnpm typecheck (after npx next typegen): exit 0. pnpm lint: exit 0, with one existing warning in scripts/comfy/library.spec.mjs (WAN_NEG_EN, not this package's).",+ "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 0, 287 files, 4591 passed, 3 skipped, 0 failed. Run on the final tree after the label change, and also on the first fix commit with the same result. tests/flux3-klein.test.ts now has 24 tests.",+ "Production build: exit 0. Browser check tests/e2e/flux3-klein.mjs at 1440 and 390 px, light and dark: demo mode 146 checks passed, FAL_KEY=anything 147 checks passed. New checks cover the Prompt helper on both engines with its words not cut off, and the cloud Edit studio showing 'Settings: 1K, ×1' (no aspect ratio). Screenshots were reviewed. Only the servers this stage started were stopped (by PID), and .next was deleted afterwards.",+ "fal re-read at the source on 2026-11-01. The base/text-to-image and base/edit-image OpenAPI schemas have the same inputs as the /lora twins minus loras; edit's image_size is nullable. The llms.txt prices are planned at $0.024 (768²), $0.027, $0.033, $0.042 and $0.108. api.fal.ai/v1/models lists both endpoints.",+ "git status is clean. Pushed: origin/o/nm10-flux3-klein at 11cff448."+ ],+ "finalSummary": "FLUX 3 Image Klein on both engines, after the review fixes. OPEN ENGINE (your ComfyUI): oss-flux3-klein does text to image up to 4K and edits with up to 10 references; the edit follows reference 1 at about 1 MP. oss-flux3-klein-base runs Klein Base with your LoRAs. Three core-node graphs were validated earlier on the CPU ComfyUI. Options -> Prompt helper (BFL's w4a8 upsampler) is on by default; off sends your words as typed, and so does a layout once it places a box (an empty layout keeps the helper). This is built and validated on CPU; a real render waits for a GPU. CLOUD ENGINE (fal): flux-3-klein runs text to image and edit at $0.009 per image at 1K ($0.036 at 4K), and goes to the /lora twins with LoRAs at $0.012 per megapixel. flux-3-klein-base now runs fal's plain Base routes at $0.027 per image at 1K ($0.108 at 4K), and the /lora twins at $0.035 per megapixel with LoRAs. Cloud edits keep image 1's shape at the chosen Resolution tier, with no Aspect ratio shown, matching the GPU. Both cloud models have the same Prompt helper control, mapped to enable_prompt_expansion. A layout with boxes goes as bounding_boxes with expansion off. Payloads and prices are verified in tests and through the preview API with a fake key; real fal calls wait for a key, and fal still calls the per-image prices 'planned'. Best lists: the Image studio's open list is Ideogram 4, Qwen-Image 2.1, FLUX 3 Klein, Krea 2 Realism (MOSS-Image moves to More models; the PR should say so). The Edit studio offers Klein, but its Best list is unchanged. No defaults changed. Soul ID training (fal's Klein Base trainer for $4.30 / AI-Toolkit flux3) and the licences shown as information (switched on) are unchanged from the implement stage. PUBLIC SIGN-UP: no new routes, pages or server paths. Guests browse the studios and model menus read-only. Accounts run Klein only on their own ComfyUI, with every input checked by account-inputs. The new cloud edit sizing reads image 1's header only for cloud runs, which accounts can't make. Cloud models and keys stay the owner's.",+ "left": [+ "Needs a GPU: real Klein runs on all three graphs, the 10-reference edit, the VRAM figure (16 GB is a guess from the 16-24 GB range), the w4a8 upsampler on every card, whether fal- and AI-Toolkit-trained LoRAs load in LoraLoaderModelOnly, and AI-Toolkit flux3 training.",+ "Needs a fal key: real calls to the eight routes (now including Base's plain t2i and edit) and the trainer. The per-image tiers are still 'planned' on fal.",+ "Not built: running BFL's upsampler with its *_bbox system prompts when a layout has boxes (today boxes skip the helper on both engines); an open-engine trainer for edit LoRAs (fal's /base/trainer/edit is recorded but unused). SHA-256 pins for the gated HF files need HF_TOKEN (node scripts/comfy/build-requirements.mjs --refresh-pins).",+ "Known edge, existing behaviour: in Layout mode on an edit that follows image 1 (GPU unsized routes and now the cloud Klein edit), the layout canvas uses the aspect ratio rather than the photo's shape. Boxes are fractions, so they stretch with the photo.",+ "For the PR's owner questions: the Image Best list drops MOSS-Image for FLUX 3 Klein (as the brief asks). Arena note: 1043 Elo vs Qwen-Image 2.1's 1042 (Artificial Analysis, October, as cited by Freefield).",+ "Docs pass: ARCHITECTURE could add ModelRoute.followsImage / sizedEdit, ModelDef.bestOps, carriesBoxes, and the cloud promptHelper -> enable_prompt_expansion mapping, besides the implement stage's four notes."+ ],+ "blocked": ""+ },+ "merge": {+ "merged": [+ "o/nm10-flux3-klein"+ ],+ "notMerged": [],+ "conflicts": "workflows/comfyui/requirements.json: took ours, rebuilt with build-requirements.mjs (186 workflows)",+ "checks": "typecheck 0, lint 0, vitest 288 files / 4610 passed, 3 skipped (exit 0)",+ "pushed": true,+ "head": "fe47ece5"+ }+}