Skip to content

armgit / fuobe

Public Imported from GitHub
0

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.

Handoff: the stage reports stay on the integration branch

Claude5785cad5b82b
diff --git a/docs/handoff/reports/dbs-d4.json b/docs/handoff/reports/dbs-d4.json
deleted file mode 100644
index 5807702f..00000000
--- a/docs/handoff/reports/dbs-d4.json
+++ /dev/null
@@ -1,172 +0,0 @@
-{
- "key": "dbs-d4",
- "impl": {
- "branch": "o/dbs-d4",
- "summary": "DBS D4 separation evaluation is built and was measured for real on this host's CPU ComfyUI through a running Fuobe (30 jobs across 2 runs). DBS-TIGER beats DBS-BSRNN on every mix (dialogue +1.2 to +2.1 dB SI-SDR) but is 2.4x slower here (0.10x vs 0.25x real time), so BSRNN stays the CPU default. The fast stereo bed (mono split) holds for centred dialogue (stereo gap 0.03-0.04, level within 0.6 dB) but fails for dialogue panned off-centre (bed SI-SDR 1 dB against 11 dB with each channel), so mono stays the default. On these synthetic mixes, which have no singing, MelBand RoFormer scored above DBS for the dub's voice split, so the dub default stays MelBand until real clips are rated blind. Steady hum goes mostly to music (BSRNN) or effects (TIGER); 20-31% of tape hiss stays in the dialogue. Split soundtrack's time estimate now uses the measured speeds (0.25x / 0.10x).",
- "built": [
- "scripts/eval/metrics/fuobe_metrics/separation.py: SI-SDR and SDR per stem (a mono stem is scored against the reference's mono mean), whether the stems add up to the input, the bed's level and peak against the reference (catches AudioMerge's peak scaling), a stereo check (L/R correlation, width, per-channel level), where a known noise ends up, auto-alignment of the stems (AAC priming), WER on words, and speed from ComfyUI-DBS's report",
- "Two new families in score.py and registry.py: 'separation' (voiceSiSdr, musicSiSdr, effectsSiSdr, backgroundSiSdr, voiceSdr, backgroundSdr, mixError, bedLevel, bedPeak, stereoCorrGap, noiseInVoice, speedX) and 'wer' (wer = the voice stem through Whisper base.en; werInput = the input as it is, i.e. without cleaning the voice first; werTranscript = the job's own Qwen3-ASR transcript). Whisper base.en is pinned at revision 911407f4 (MIT; the HF card says Apache-2.0). It is optional: requirements-asr.in/.txt (transformers 5.22.1), installed with pnpm eval:setup --asr",
- "The runner records each output's stem name and the role of text outputs. The report shows one named audio player per stem. The blind review compares dialogue with dialogue and music & effects with music & effects as separate questions, with audio players, and serves audio file types",
- "scripts/eval/fixtures/make-separation.py: builds 12 s 44.1 kHz stereo test mixes with known stems into local/separation/: centre, off-centre (panned left), 50 Hz hum, tape hiss, a loud master at -0.1 dBFS, and the centre mix inside an H.264+AAC video. Each mix gets a meta.json with the words, the levels and every source's licence. Music, effects, hum and hiss are synthesized from fixed seeds (CC0)",
- "scripts/eval/cases/separation.json is generated by gen-cases.mjs; the DBS licences are read from the research JSON. Variants: bsrnn-mono, bsrnn-stereo, tiger-mono, tiger-stereo, dbs-dub (oss-dbs-voice-separate), melband (oss-voice-separate), demucs (cloud). A 'real' case takes your own clip for the blind A/B. A 'decides' rule is attached. SAM Audio is left out because samAudioCloud is false",
- "src/lib/av/split.ts DBS_SPEED cpu changed from 0.27/0.09 to the measured 0.25/0.10, with tests/split-soundtrack.test.ts updated. The src/lib/av/dub.ts comment records why MelBand stays the default",
- "docs/research/dbs-separation-7.md: §2.4 has the measured speed table, §9 D4 has an 'As built' with the results and the defaults chosen, and §11 is updated (speed measured; where the noise goes)",
- "scripts/eval/README.md: a row in the suites table, rows in the metrics table, and a section on the separation suite"
- ],
- "tests": [
- "pytest scripts/eval/metrics/tests: 31 passed, 5 skipped. New in test_separation.py: known SI-SDR and SDR on constructed signals, mixture error, bed level under peak scaling, stereo check, noise share, offset, WER on fixed strings, report speed",
- "vitest eval-harness, eval-metrics, eval-api, split-soundtrack, comfy-dbs, dub*: 111 passed, 1 failed. The failure is split-soundtrack 'has no cloud route', a known failure from main (rule 8). New harness test: a demo run of separation/centre records the stem names; the open and cloud plans list each variant's model, DBS model and channels",
- "pnpm eval:validate: all suites valid, generated files up to date. pnpm typecheck clean. eslint clean on the changed files",
- "Real runs on the CPU ComfyUI (127.0.0.1:8188) through pnpm dev + pnpm eval:run --engine open. Run 20261102-111016-separation-open-ae7e: 24/24 jobs (6 mixes x BSRNN/TIGER x mono/each channel). Run 20261102-150312-separation-open-32a4: 6/6 jobs (dbs-dub vs melband on centre, hum and video, Qwen3-ASR 0.6B). All scored with Whisper",
- "Browser check of the report and the blind review (run A) at 1440 px and 390 px, light and dark: no sideways scroll, audio players render. The only console errors are 404s from the review page's own fetches when no ratings.json exists yet; this predates this change"
- ],
- "left": [
- "The test speech is LibriSpeech dev-clean, speaker 1272 (CC BY 4.0, from hf-internal-testing/librispeech_asr_dummy@5be91486), not Fuobe TTS: no Chatterbox weights were on this host. LibriSpeech is the same family as DBS's DnR training speech, which may flatter DBS. Rerun with Chatterbox lines when a GPU is available. The test mixes are not committed: make-separation.py rebuilds them from --speech",
- "The music and effects are synthesized (tones, noise bursts); there is no singing and no recorded effects, which is where DBS should beat a vocals model. The dub voice-split comparison favoured MelBand on these mixes and is not a verdict on films. The owner needs to put a real clip in local/separation/real/clip.mp4 and rate it blind (pnpm eval:review)",
- "AudioMerge's peak scaling was not triggered: the loud master's bed peaked at -7 dBFS. The metric is in place for real clips",
- "Cloud: the Demucs variant was planned only (tests); no key and no paid call. SAM Audio is not built (samAudioCloud false)",
- "D6 'Clean the voice first' is not on the base, so no D6 setting was written. The doc records the evidence: Whisper WER without separating 0.117, with separating 0.105-0.154; separating helped only for hiss with BSRNN. That supports defaulting it off for audio-only speech",
- "D5 (clean up dialogue) was not on origin/claude/fuobe-parity-4 when merged (0bd4a907), so it is not in the suite",
- "No GPU measurements. CUDA defaults (TIGER) are unchanged and unmeasured",
- "The off-centre finding (the fast bed leaves panned speech in Music & effects) suggests a hint in Split soundtrack / Remove dialogue to use Stereo stems; this was not built",
- "This session started ComfyUI with scripts/comfy/start-comfyui.sh once, after a container reboot left it down, as docs/HANDOFF.md says. No packs were installed. Weights downloaded into the CPU ComfyUI: MelBandRoformer_fp16.safetensors (pinned revision, sha256 checked) and Qwen3-ASR-0.6B + ForcedAligner-0.6B (auto-downloaded by the node on first run)",
- "Merged origin/claude/fuobe-parity-4 (3afb3bce). Conflicts with the base's new 'background' metric family (schema, registry, metric-info, score.py imports) were resolved by keeping both sides"
- ],
- "docsNotes": [
- "docs/STATUS.md (docs pass): DBS D4 separation evaluation is done. Suite 'separation', metric families separation and wer, pnpm eval:setup --asr. Measured CPU speed: DBS-BSRNN 0.25x, DBS-TIGER 0.10x real time per pass. Defaults kept: BSRNN on CPU, TIGER on CUDA, mono, dub voice split MelBand",
- "CREDITS.md may want: Whisper base.en (OpenAI, MIT) as an evaluation-only model; LibriSpeech (CC BY 4.0) as evaluation test speech (not shipped)",
- "The brief was out of date in places: D6 'Clean the voice first' is not built on the base, so there were no D6 settings to write. ComfyUI-DBS's report key is times_real_time, and in each-channel mode it counts every channel's audio. The research JSON plan brief still says to use an isolated worker; the shared CPU ComfyUI now has the pack"
- ],
- "blocked": null
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "title": "D5 (Clean up dialogue) is now on the base: the merge conflicts in the research doc, D5's own measurements disagree with D4's, and D5 isn't in the suite",
- "where": "docs/research/dbs-separation-7.md §11 (and §2.4, §9 D4); scripts/eval/gen-cases.mjs separationSuite()",
- "detail": "origin/claude/fuobe-parity-4 is now 85be87db, with o/dbs-d5 merged (eb930d90). `git merge-tree HEAD origin/claude/fuobe-parity-4` shows one conflict, docs/research/dbs-separation-7.md at the §11 'where steady noise lands' line: the base says '*Partly measured (D5):* ... broadband hiss mostly stayed with the speech', and the branch says hiss splits across effects 49-59 %, with 20-31 % in the dialogue. The base's D5 'As built' also measured DBS-BSRNN at 0.36-0.42x real time through graph C (15 s mono clips), while D4's §2.4 and DBS_SPEED say 0.25x; the merged doc has to explain the gap (mono 15 s clips against stereo 12 s at 44.1 kHz, graph C against graph A) or the two sections contradict each other. Is D5 covered by this brief? Rule 14 says to include D5 if the brief covers it. The brief doesn't name D5, but it asks for §11's 'where does noise go', which the base's §11 says 'matters for Clean up dialogue'. It also asks for bed level against the reference and for WER of the cleaned voice, and those metrics measure D5's output directly. D5's open route is the ModelDef oss-dbs-remix (op separate-audio, graph soundtrack-remix-dbs, controls separationModel and channels, plus a bed level), so the suite's existing open target can run it. Its cloud cleaners (veed-clean-audio, deepfilternet3, ElevenLabs isolation) fit dry-run cloud variants, like demucs.",
- "fix": "Merge origin/claude/fuobe-parity-4. In §11, keep both measurements and say how they differ (D5: one mono Mandarin clip through graph C; D4: six stereo English mixes, by projection share). In §2.4, note D5's 0.36-0.42x and why it is higher. Add a 'clean-dialogue' variant on oss-dbs-remix at the −18 dB preset (one FLAC output: score the dialogue against voice + bed·10^(−18/20) and the bed level at −18 dB, noiseInVoice for hum and hiss, and Whisper WER against werInput). Add dry-run cloud variants for veed-clean-audio and deepfilternet3, then regenerate and validate.",
- "verified": "git merge-tree --write-tree HEAD origin/claude/fuobe-parity-4 → CONFLICT in docs/research/dbs-separation-7.md (one hunk, merged line 472); base models.ts L1673 oss-dbs-remix op separate-audio"
- },
- {
- "severity": "medium",
- "title": "`pnpm eval:setup --asr --download` fails: fuobe_metrics.download has no --asr flag",
- "where": "scripts/eval/eval.mjs setup() (passes --asr to `python -m fuobe_metrics.download`); scripts/eval/metrics/fuobe_metrics/download.py (unchanged)",
- "detail": "eval.mjs now adds `--asr` to the download step when both flags are given, and the HELP line advertises `[--asr] [--download ...]`, but download.py's argparse only knows --identity, --scrfd, --no-aesthetic and --dinov2. The step exits 2 and setup throws 'python -m failed (exit 2)', after the ASR requirements were already installed. The Whisper weights are never pre-fetched.",
- "fix": "Add --asr to download.py so it fetches MODELS['whisper-base-en'] files at the pinned revision (the way --dinov2 does), and add a test of the flag.",
- "verified": ".venv/bin/python -m fuobe_metrics.download --asr --no-aesthetic → 'error: unrecognized arguments: --asr', exit 2"
- },
- {
- "severity": "medium",
- "title": "The 'loud' fixture never triggers AudioMerge's peak scaling, so the check §2.1 hands to D4 is still unanswered",
- "where": "scripts/eval/fixtures/make-separation.py MIXES['loud']",
- "detail": "Research §2.1 says AudioMerge divides the fast stereo bed by its peak when it goes over 1.0, and that '§9 D4 checks it'. The brief asks for the bed's level and peak 'to catch AudioMerge's peak scaling'. The 'loud' mix normalises the whole mix to −0.1 dBFS with the music at −18 dBFS RMS, so the bed (mix − voice) peaks at about −7 dBFS on every run (bedPeak −7.0 to −7.3). The scaling path is never reached, and the doc can only say 'not triggered'. The metric is unit-tested, but the fixture doesn't exercise it.",
- "fix": "Add or change a mix so the bed itself peaks at about −0.1 dBFS: music and effects dominant, loud transients, or the master normalised on the bed's peak. Rerun bsrnn-mono on it (about 50 s on the CPU ComfyUI) and record bedLevel and bedPeak in §9 D4.",
- "verified": "metrics.json of run 20261102-111016-separation-open-ae7e: loud bedPeak −7.02/−7.04/−7.22/−7.27, bedLevel −0.04 to −0.12"
- },
- {
- "severity": "low",
- "title": "The blind review gives the model away by file extension on the dub comparison (DBS .flac against MelBand .mp3)",
- "where": "scripts/eval/lib/review.mjs writeReview() place() keeps path.extname(file)",
- "detail": "In run 20261102-150312-separation-open-32a4, every pair is one .flac (DBS) and one .mp3 (MelBand). A reviewer sees which is which in the audio element's download name or src. The DBS-vs-MelBand dub split is the one comparison the doc asks the owner to settle by rating real clips blind. This is new with audio pairs: the image and video suites rarely mix formats this way.",
- "fix": "For audio pairs, transcode both sides to one format (for example FLAC or WAV through ffmpeg into review/media), or at least give both the same extension and serve them by sniffed type.",
- "verified": "ls review/media → *.flac and *.mp3; index.html pairs each flac with an mp3"
- },
- {
- "severity": "low",
- "title": "Without the optional ASR install, the wer family drops werTranscript too, though it needs no ASR",
- "where": "scripts/eval/metrics/fuobe_metrics/score.py m_wer",
- "detail": "m_wer computes werTranscript (the job's own Qwen3-ASR text against the known words), then calls self.asr(), which raises Missing when transformers isn't installed. The main loop catches Missing, drops the family's result, and marks 'wer' skipped for every later job. So the dub comparison loses its Qwen3 transcript WER unless `--asr` is installed, even though that score needs no model.",
- "fix": "Call self.asr() only when there's a voice stem or input to transcribe, and catch Missing inside m_wer so werTranscript is kept, with a _note.",
- "verified": "traced: m_wer → self.asr() → Asr.__init__ raises Missing → main loop `except Missing: scorer.skipped[fam]...; continue` (res discarded)"
- },
- {
- "severity": "low",
- "title": "The speech licence defaults to LibriSpeech whatever speech is given, and the case file doesn't record it",
- "where": "scripts/eval/fixtures/make-separation.py --speech-licence default; scripts/eval/cases/separation.json description",
- "detail": "The brief asks for 'the licence of every fixture source in the case files'. The suite only points to each mix's meta.json, which is git-ignored and written locally. The speech's licence there comes from --speech-licence, which defaults to the LibriSpeech CC BY 4.0 string. A rerun with Fuobe TTS lines, the source the script's own docstring intends, records the wrong licence unless the user remembers to override it.",
- "fix": "Make --speech-licence required, or read it from the speech folder (index.json or a licence.txt). Name the speech source of the measured runs (LibriSpeech dev-clean, CC BY 4.0) in the generated suite description next to the synthesized sources' CC0.",
- "verified": "read make-separation.py L232 and the generated separation.json description"
- },
- {
- "severity": "low",
- "title": "The doc's dub timing leaves out DBS's slow first run",
- "where": "docs/research/dbs-separation-7.md §9 D4, 'The dub's voice split' bullet",
- "detail": "The doc says MelBand 'took 128-190 s against 47-49 s for 12 s (DBS: 0.26x real time with the ASR)'. In run 32a4, dbs-dub on centre took 127 s (execMs 125674, speedX 0.095): the first job, which loaded and downloaded Qwen3-ASR. MelBand's 190 s is the same first-run case. The two ranges aren't measured the same way, and the centre run is missing from DBS's range.",
- "fix": "Say that the first job of each variant included loading Qwen3-ASR (DBS 127 s, MelBand 190 s), and compare the warm runs: DBS 47-49 s against MelBand 128-133 s.",
- "verified": "jobs.jsonl + metrics.json of run 20261102-150312-separation-open-32a4"
- },
- {
- "severity": "low",
- "title": "Tests don't cover the scorer code between the maths and the runs",
- "where": "scripts/eval/metrics/tests/test_separation.py",
- "detail": "The pytest file covers only the numpy maths in separation.py. Nothing tests audio_outputs (stem names folded from vocals and residual, an unnamed first output, Demucs's drums, bass and other summed into a background), references_of and meta.json, m_separation's alignment and mono-against-stereo mixError, or m_wer. That code produced every number in the doc.",
- "fix": "Add one test that writes a tiny run folder (a jobs row with FLAC stems named voice/background and Demucs-style vocals/drums/bass/other, references and meta.json) and checks m_separation and m_wer's keys and rough values, with a fake Asr.",
- "verified": "read tests/test_separation.py (separation.py functions only)"
- }
- ],
- "checks": [
- "Branch o/dbs-d4 = origin/o/dbs-d4 = 0bd4a907, tree clean. The base has moved to 85be87db (D5 merged, eb930d90). A trial merge (git merge-tree) has one conflict, in docs/research/dbs-separation-7.md §11. split.ts and split-soundtrack.test.ts merge automatically (D5 adds a clean-dialogue preset next to DBS_SPEED).",
- "owner-decisions.json: samAudioCloud false. There's no SAM Audio route or variant, and the cloud keeps Demucs. That's correct.",
- "D6 'Clean the voice first' is not on the base (git grep for cleanVoiceFirst or 'Clean the voice first' in src finds nothing), so no D6 setting could be written. werInput stands in for 'off', which is reasonable.",
- "pytest scripts/eval/metrics/tests: 31 passed, 5 skipped. The skips are CLIP, DINOv2 and insightface weights or modules that aren't present; none are separation tests.",
- "pnpm eval:validate: all suites valid. node scripts/eval/gen-cases.mjs --check: generated files up to date (separation: 7 mixes).",
- "vitest eval-harness, eval-metrics, eval-api, split-soundtrack, comfy-dbs: 111 passed, 1 failed. The failure is split-soundtrack 'has no cloud route', a known failure from main (rule 8). There are no tests/dub*.test.ts files at this path.",
- "Recomputed means from metrics.json of runs ae7e (24 jobs) and 32a4 (6 jobs). They match the §9 D4 table and bullets: dialogue SI-SDR 14.7/14.4/16.1/15.7, stereo gap 0.146/0.027/0.138/0.017, WER, the hum and hiss shares, off-centre bed 0.95 and 1.27 against 11.2 and 12.3, speedX 0.25 and 0.10. The 'decides' rule matches the defaults kept: TIGER is better by more than 1 dB but slower than 5 minutes per minute, the centred bed gap is under 0.1, and DBS loses the dub voice comparison.",
- "The venv imports transformers 5.22.1 with torch 2.14.1+cpu. requirements-asr.txt is compiled against requirements.txt.",
- "`python -m fuobe_metrics.download --asr` fails with 'unrecognized arguments' (finding 2).",
- "Browser (headless Chrome, file://) on report.html and review/index.html of run ae7e at 1440 and 390 px, light and dark: no sideways scroll (scrollWidth = clientWidth), 96 or 2 audio players, the body background set in both themes, no console errors. Screenshot of the 390 px dark review checked by eye. No Next dev server was started, so there was no .next to delete.",
- "No new routes, pages, ComfyUI graphs, node packs or ModelDefs, so the public sign-up, tenant and input checks, pre-flight board, ASSET_REFS and licence-as-data rules aren't affected. src changes are only DBS_SPEED's numbers and a comment in dub.ts. No hot or off-limits files changed. No Higgsfield code or media. The results and local folders are git-ignored.",
- "score.py's new step that moves underscore keys: the existing families only return _note and _refs, which are popped first, so no earlier family's output changes."
- ],
- "verdict": "needs-fixes: the metrics, suite, runs and doc numbers are sound and verified. Before merging: merge the new base and resolve the doc conflict, reconciling D5's measurements and judging D5 for the suite (finding 1); fix `eval:setup --asr --download` (finding 2); make the loud fixture actually test AudioMerge's peak scaling (finding 3). The rest are low."
- },
- "fix": {
- "applied": [
- "Merged origin/claude/fuobe-parity-4 (85be87db, with DBS D5) into o/dbs-d4 (625d7476). The one conflict was docs/research/dbs-separation-7.md §11; I kept both measurements and said how they differ (D5: one mono Mandarin clip through graph C, the level drop at the noise's frequencies; D4: six stereo English mixes through graph A, the projection share). Both agree on hum. Both say an audible part of the hiss stays in the dialogue. No generated files or migrations conflicted.",
- "§2.4: added a note on D5's 0.36–0.42x. I ran graph C on this host myself and measured 0.23–0.29x, against 0.26–0.30x for graph A on the same mixes that day. So graph C is not faster. The gap isn't explained by clip length or sample rate either: the pack resamples to 44.1 kHz and uses the same 3 s windows. DBS_SPEED stays at 0.25x.",
- "Finding 1 (D5 in the suite): new variant 'clean-dialogue' on oss-dbs-remix (graph C, DBS-BSRNN mono, music and effects at −18 dB). New dry-run cloud variants 'clean-veed' (veed-clean-audio) and 'clean-deepfilternet' (deepfilternet3), both on op enhance-voice. To make this possible, the case schema and plan.mjs now accept a per-variant op. The scorer reads graph C's levels from the job's extra (remix_levels). It scores the one output file against the voice plus the known bed at the requested level (new key remixSiSdr). bedLevel is the bed's least-squares gain in the file (separation.remix_gains). noiseInVoice and WER are kept. Ran it for real on the CPU ComfyUI (run 20261102-154635-separation-open-8fec, 8/8 jobs) and wrote the results into §9 D4.",
- "Finding 2: fuobe_metrics.download now has --asr, which fetches every Whisper base.en file at the pinned revision. A pytest covers it.",
- "Finding 3: new mix 'loud-bed' (music −12, effects −16 dBFS RMS, normalised to −0.1 dBFS). Its known bed peaks at +0.1 dBFS. A reference that goes over full scale is written as float WAV so it isn't clipped, and meta.json records bedPeakDbfs and fastBedPeakDbfs. New metric bedScale: the bed's gain against input − voice, so 0 means not scaled. Ran bsrnn-mono on it for real: the bed peaked at −0.07 dBFS and bedScale was 0.00 dB, so nothing was scaled. §9 D4 now explains that on an input under full scale, the fast bed can only go over by what the dialogue takes away (about 0.1 dB here). An input that is itself over full scale is not measured.",
- "Finding 4: the blind review now re-encodes both sides of an audio pair to FLAC with ffmpeg, under one extension. A harness test pairs FLAC with MP3 and checks that every file served is FLAC and that the page names neither model.",
- "Finding 5: m_wer keeps werTranscript when Whisper isn't installed. The reason is recorded as skipped['wer (Whisper)'], so the wer family still runs for later jobs. Tested with a fake and a missing ASR.",
- "Finding 6: make-separation.py has no default speech licence any more. It takes --speech-licence or a licence.txt in the speech folder, and stops if neither is given. The generated suite description names the measured runs' speech (LibriSpeech dev-clean speaker 1272, CC BY 4.0) and the DeepFilterNet 3 / VEED licences.",
- "Finding 7: the doc's dub timing now separates the first jobs, which also loaded Qwen3-ASR (DBS 127 s, MelBand 190 s), from the warm runs (DBS 47–49 s, MelBand 128–133 s). Checked against jobs.jsonl of run 32a4.",
- "Finding 8: new scripts/eval/metrics/tests/test_separation_scorer.py with 10 tests over real FLAC files in a temporary run folder. It covers stem-name folding (an unnamed first output, residual, no_vocals, sfx), references_of and meta.json, m_separation on a clean split, a bed scaled by 1/1.25 (bedScale −1.94 dB), Demucs stems summed and a stem 300 samples late lined up, Clean up dialogue at −18 dB, m_wer with a fake and a missing ASR, download --asr, and bed_scale / remix_gains on plain arrays.",
- "README for the suite: the variants, loud-bed, --speech-licence, the new metrics and the FLAC review."
- ],
- "rejected": [],
- "checks": [
- "pytest scripts/eval/metrics/tests: 40 passed, 5 skipped. The skips are CLIP, DINOv2 and insightface weights that aren't present.",
- "node scripts/eval/gen-cases.mjs --check: up to date (separation: 8 mixes). pnpm eval:validate: all suites valid.",
- "npx next typegen: exit 0. pnpm typecheck: exit 0. It needed NODE_OPTIONS=--max-old-space-size=6144; the default heap ran out of memory. pnpm lint: exit 0, with 3 warnings in files this package didn't touch (library.spec.mjs, src/server/elements.ts).",
- "Full FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 1. 323 test files, 316 passed and 7 failed. 5170 tests: 5158 passed, 8 failed, 4 skipped. Six failures are rule 8's known ones: comfy-reuse, dop-originals, preset-featured, soul-runs x2, and split-soundtrack 'has no cloud route'. The other two, picker-covers and preset-covers, are rule 13 timeouts. Rerun alone, they passed 36/36 (exit 0).",
- "eval-harness tests: the Clean up dialogue open plan (oss-dbs-remix, separate-audio, −18 dB extra). The cloud dry run with fal connected: VEED planned and priced on centre and video. DeepFilterNet 3 and Demucs priced on audio and refused on the video case (audio only).",
- "ComfyUI 127.0.0.1:8188 has DBSLoader, DBSSeparate and AudioAdjustVolume. validate-workflows soundtrack-remix-dbs --shared passed. The validation-state.json timestamp and the object_info.subset.json changes it made were reverted.",
- "Real CPU run 20261102-154635-separation-open-8fec through a Fuobe dev server on port 3460: 8/8 succeeded, 43–56 s each. clean-dialogue: remixSiSdr 15.2–16.6 dB (9.4 on loud-bed). The bed's gain in the file was −12.5 to −12.7 dB, not −18. The cause: graph A's voice stem already carries the bed at −18.0 to −18.3 dB (checked by the same projection), and graph C adds the bed back in phase. Whisper WER on hiss dropped from 0.138 to 0.000; the other mixes matched the input. noiseInVoice: hum 0.25, hiss 0.33. Speed 0.23–0.29x. loud-bed bsrnn-mono: bedPeak −0.07 dBFS, bedScale 0.00.",
- "The dev server was stopped by its own PIDs, .next was deleted, and git status is clean. o/dbs-d4 = origin/o/dbs-d4 = ffb141f9."
- ],
- "finalSummary": "DBS D4 is merged with the base that includes D5, and all eight review findings are fixed. The separation suite now covers Clean up dialogue on both engines. Open engine (your ComfyUI, CPU or GPU): DBS-BSRNN and DBS-TIGER, mono and each channel, the dub's DBS and MelBand voice splits, and Clean up dialogue through graph C. All of these were measured for real on this host's CPU ComfyUI. TIGER and the CUDA defaults still need a GPU. Cloud engine: Demucs and the D5 cleaners (VEED Clean Audio, DeepFilterNet 3) are built and tested as dry runs only. They need a fal key and a budget to measure; no paid call was made. SAM Audio is still absent (samAudioCloud false). New results: a loud master whose music reaches full scale does not trigger AudioMerge's peak scaling, because the bed went only to −0.07 dBFS (bedScale 0.00). Clean up dialogue's '−18 dB' preset actually leaves the music and effects at about −12.6 dB in the file, because DBS's dialogue stem already leaks the bed at about −18 dB. I recorded that in §9 D4 for the owner to judge by ear and did not change the preset. No defaults changed; DBS_SPEED stays 0.25x / 0.10x. Public sign-up is not affected: this package adds no routes, pages, graphs, ModelDefs or node packs. Its changes are evaluation tooling and docs. Guests and accounts get exactly what the base gives them for Split soundtrack and Clean up dialogue, including D5's own-GPU and own-files rules.",
- "left": [
- "Clean up dialogue's bed comes out at about −12.6 dB with the −18 dB preset, because the dialogue stem leaks the bed at about −18 dB. Whether to lower the presets or change their labels is the owner's call after listening. The −14.5 dB figure for a −24 dB preset in the doc is arithmetic, not measured.",
- "AudioMerge's scaling on an input that is itself over full scale was not measured: a float WAV, or an AAC decode of a loud master that overshoots.",
- "The D5 speed gap (0.36–0.42x in D5's runs against 0.23–0.29x here, same graph and host) is unexplained. It is not the graph, the clip length or the sample rate.",
- "The cloud cleaners and Demucs are dry runs only: no key and no paid call.",
- "Still from the impl: speech is LibriSpeech, not Fuobe TTS (no Chatterbox weights on this host); music and effects are synthesized; no GPU measurements; the owner's real clip for the blind A/B is not there yet; the off-centre 'use Stereo stems' hint is not built; D6 is not on the base.",
- "pnpm typecheck needs NODE_OPTIONS=--max-old-space-size=6144 on this container; with the default heap it runs out of memory.",
- "The merge commit 625d7476 also carries the D4 doc updates written during conflict resolution (§2.4 D5 note, §9 D4 bullets)."
- ],
- "blocked": null
- },
- "merge": {
- "merged": [
- "o/dbs-d4"
- ],
- "notMerged": [],
- "conflicts": "none; its separation/video dry-run check only passed where scripts/eval/local held the clip, so the test now lends it the fixture clip (03e49f2d)",
- "checks": "pair (dbs-d6, dbs-d4): typecheck 0, lint 0, vitest 5475 passed, 7 failed (6 main known + eval-harness separation video check, which needed the private clip; fixed in 03e49f2d)",
- "pushed": true,
- "head": "03e49f2d"
- }
-}
diff --git a/docs/handoff/reports/dbs-d6.json b/docs/handoff/reports/dbs-d6.json
deleted file mode 100644
index d0413ee6..00000000
--- a/docs/handoff/reports/dbs-d6.json
+++ /dev/null
@@ -1,124 +0,0 @@
-{
- "key": "dbs-d6",
- "impl": {
- "branch": "o/dbs-d6 (worktree /home/user/wt/o-dbs-d6, 5 commits on claude/fuobe-parity-4 at 85be87db, not pushed)",
- "summary": "Clean the voice first. Requests take a new voiceFirst flag. createGenerations turns it into one batch of steps, so every caller gets it. Open engine: DBS (oss-dbs-separate) runs first, then Qwen3-ASR, InfiniteTalk or LatentSync reads its voice stem. For a lip re-sync of a clip that has sound, the clip is split too, and oss-mux puts the clean voice over the clip's background at 0 dB, with the picture copied. Cloud: ElevenLabs Voice Isolation runs before Scribe v2 or the lip sync model, with no put-back because samAudioCloud is false, and the switch says so. previewGeneration adds the step's price and checks it. The Transcribe, Lipsync & avatars, Captions, Genjutsu 'Use the clip's words' and Character Swap Studio transcript screens each have a switch. It shows the time it adds on your GPU or its price in the cloud. It is on by default for video sources and off for audio-only ones. Already there before this package: DBS graph A, oss-dbs-separate, the STEM_ALIASES voice/background, the oss-mux two-track mux (D2), and elevenlabs-voice-isolation in the catalog. No new graph, model, migration or route was needed.",
- "built": [
- "src/lib/av/voice-first.ts (pure): planVoiceFirst gives voice → main → (open lip re-sync of a clip with sound) bed + film steps. Also voiceSource, voiceFirstApplies, voiceFirstDefault (on when the speech comes with a video), putsBedBack, voiceFirstCost (catalog price, or ISOLATION_USD_PER_MINUTE = 0.10 for pages without the catalog; a test keeps the two equal), voiceFirstTime (splitTime, the host's DBS pick, mono; doubled plus the mux with the put-back), voiceFirstLine, and the hint and BED_NOTES copy per engine",
- "src/server/voice-first.ts: voiceFirstPlanFor reads the speech's and the clip's headers through storedMedia, so an account's run sees only its own files. It skips the put-back for a silent clip and the step for a silent recording. createVoiceFirstRun builds a createPipeline batch, puts the result first, keeps the asked request through withAsked (now exported from chains.ts) so Reuse and skills rerun it, and rewords a failing step as 'Clean the voice first can't run (…): …. Turn it off to run without it'",
- "generations.ts: createGenerations expands voiceFirst when nothing waits on it (it also works as a pipeline step, which Swap Studio uses). previewGeneration adds the extra steps' cost and notes and refuses in the switch's words",
- "GenerationRequest.voiceFirst in types.ts, request-schema.ts (zod) and the recipe-builder KEEP list",
- "UI: VoiceFirstSwitch (src/components/studio/voice-first-switch.tsx) has the switch, a hint per engine, the time or price line (under the words on a phone), and for a lip re-sync of a clip what happens to its music and effects. Composer: StudioConfig.voiceFirst on TRANSCRIBE_STUDIO and LIPSYNC_STUDIO. A pick holds per speech file. The probe gives the length and whether the clip has sound. The client cost estimate includes the step, and submit sends voiceFirst",
- "Captions: transcribeRequest({ voiceFirst, seconds }) and the switch under 'Transcribe the speech'. Genjutsu: TranscribeSchema.voiceFirst, the switch under 'Use the clip's words', and the cached transcript is keyed by the switch. Character Swap Studio: planTranscribe(clip, engine, voiceFirst), the route takes voiceFirst, StudioEstimate.cleanVoice holds the added price per clip, and the button's price follows the switch",
- "Live on the CPU ComfyUI (DBSLoader present, both DBS models on disk) through a dev server, POST /api/generations with voiceFirst on an 11 s H.264+AAC clip (JFK's public-domain speech over sine chords and pink-noise bursts): DBS-BSRNN mono took 41 s with the load and gave voice, music, effects and background. Qwen3-ASR 0.6B on the voice stem took 68 s and its transcript was word-perfect. Without the switch the transcript was also word-perfect (17 s), so this clip shows no gain; measuring one is D4's job",
- "docs/research/dbs-separation-7.md §9 D6: 'As built (D6)' note with the live numbers (a research correction)"
- ],
- "tests": "New: tests/voice-first.test.ts (22) covers where the switch applies and its defaults; the plans per engine and studio (stems, chain slots, inputs removed, step indexes, the put-back mux at 0 dB from the right steps, a silent clip, avatar, cloud); the prices ($0.05 for 30 s, $0.10 a minute, list price = catalog) and times; and in demo mode createGenerations for transcript, lipsync with put-back (run to success), cloud, without the switch, as a pipeline step, and with DBS switched off; previewGeneration price and notes; Genjutsu transcribeClip; Swap planTranscribe. New: tests/account-voice-first.test.ts (2): an account is refused the owner's recording with input-not-yours before anything is queued, and its own run stamps every step with the account and the open engine. Targeted runs passed: voice-first, account-voice-first, recipe-builder, swap-studio, swap-studio-api, genjutsu-api, remove-dialogue, chains, composer, public-signup, hosted-runs, assist-skill-tools, account-tenant. Typecheck passes (tsc needs NODE_OPTIONS=--max-old-space-size=8192 here) and eslint is clean on every changed file. Browser: tests/e2e/voice-first.mjs on a demo dev server covers Transcribe (video on, recording off), Lipsync (re-sync models via ?model=, on, with the bed note per engine) and Captions, at 1440 and 390 px, light and dark, on both engines. All good: toggling moves nothing, no horizontal scroll, no console errors. Server stopped, .next deleted. Not run as instructed: the full vitest suite and pnpm build.",
- "left": [
- "Not verifiable here: a lip sync with the put-back on a GPU (InfiniteTalk or LatentSync need one; the mux is the one D2 verified on the CPU), and paid ElevenLabs Voice Isolation calls",
- "The GPU pre-flight board (STUDIO_ROWS) still lists only the Transcribe and Lipsync defaults. The DBS step's pack and weights are already covered by the Split soundtrack and Remove dialogue rows, so a missing ComfyUI-DBS shows up when the run fails, not as a badge on those studios",
- "The switch's default (on for video, off for audio) is a guess until D4 measures WER with and without it. On the synthetic clip both transcripts were identical",
- "The time line uses the CPU estimate unless the viewer's GPU device is known (ownGpuOf(status).device)",
- "Genjutsu and Character Swap Studio switches were type- and unit-checked but not browser-checked (the brief asks for Transcribe, Captions and Lipsync)",
- "Hosted runs: no new model or op, so poolQuote is unchanged. A voiceFirst pool run plans and prices its main step there, and the DBS step is free"
- ],
- "docsNotes": "STATUS/ARCHITECTURE (left for the docs pass): 'Clean the voice first' (DBS D6). A voiceFirst flag on a generation request runs the speech alone through the transcript or lip sync: DBS voice stem on your GPU, ElevenLabs Voice Isolation ($0.10/min) in the cloud. A lip re-sync of a clip on your GPU gets the clip's music and effects back through oss-mux at 0 dB; the cloud keeps the clean voice only, because samAudioCloud is false. Switches in Transcribe, Lipsync & avatars, Captions, Genjutsu 'Use the clip's words' and Character Swap Studio's transcript. On by default for video, off for audio. Code: src/lib/av/voice-first.ts and src/server/voice-first.ts (expanded inside createGenerations), src/components/studio/voice-first-switch.tsx. Brief out of date: the line numbers (TRANSCRIBE_STUDIO is now ~L283, LIPSYNC_STUDIO ~L113, STEM_ALIASES ~L1039, swap transcribe ~L731); STEM_ALIASES already had music and effects from D1. The Lipsync studio opens on talking-avatar models (InfiniteTalk, Kling Avatar 2), so the put-back applies only when a re-sync model (InfiniteTalk Lip Re-sync, LatentSync, Sync Lipsync) is picked; the switch is on by default whenever a clip is attached. No migration, no new route, no new graph or node pack.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "title": "Hosted runs: Clean the voice first's extra steps run on the install's GPUs unpriced and past the pool policy",
- "where": "src/server/generations.ts createGenerations (voiceFirst branch) + src/server/hosted-run.ts decidePlace/poolQuote + src/server/hosted.ts runFacts/poolAllows",
- "detail": "decidePlace and poolQuote check poolAllows only for planned.model.id (the transcriber or lip sync model), and runFacts sends the billing service only that model, op, jobs and seconds. With voiceFirst the run then queues oss-dbs-separate (and, for a lip re-sync of a clip with sound, a second DBS pass over the clip plus oss-mux) on the same pool. The billing service never sees those steps, and a policy that denies oss-dbs-separate or oss-mux on the pool cannot stop them. The brief says a model or op on that path 'plans and prices there too (poolQuote; test it in the style of tests/hosted-runs.test.ts)'. The implementer's 'left' says 'the DBS step is free', but no hosted-runs test covers voiceFirst. This only happens with FUOBE_HOSTED_RUNS=1 and a policy that allows audio or video uploads (off by default).",
- "verified": "Traced: previewGeneration's voiceFirstExtra adds only a USD cost, which is 0 on the open engine. runFacts (hosted.ts:139-165) carries no step list or voiceFirst. poolAllows (hosted.ts:55) is called with planned.model.id only.",
- "fix": "In decidePlace and poolQuote, when req.voiceFirst applies, check poolAllows for every voiceFirstPlanFor step model and add the steps to the facts sent for billing (or keep voiceFirst runs on the account's own GPU). Add a hosted-runs test."
- },
- {
- "severity": "medium",
- "title": "Lipsync default turns on cleaning of an uploaded voice file, against the brief's 'off for audio-only speech uploads'. In the cloud this costs money by default.",
- "where": "src/lib/av/voice-first.ts voiceFirstDefault (return !!req.inputs?.video for lipsync/avatar)",
- "detail": "For lipsync the file that gets cleaned is always inputs.audio, which is an audio upload (voiceSource). The default still turns on whenever a clip is attached. On the cloud engine there is no put-back, so the default adds paid ElevenLabs Voice Isolation ($0.10/min) to a voice that is usually already clean (a recording or TTS), and gives no benefit. On the open engine the default also adds two DBS passes. The brief's rule is 'on for video sources, off for audio-only speech uploads'. The bed put-back is a separate benefit that could be decided apart from cleaning the voice. The implementer flagged the choice in docsNotes but did not raise it as a deviation from the brief.",
- "verified": "Read voiceFirstDefault, and the composer's voiceFirstOn = vfApplies && (pick ?? voiceFirstDefault). tests/voice-first.test.ts asserts the on-by-default behaviour for a lip sync clip.",
- "fix": "Default off for a lipsync voice upload, at least on the cloud engine. Or make the put-back on the open engine its own default-on choice, and keep 'clean the voice' off for an uploaded voice."
- },
- {
- "severity": "minor",
- "title": "Two overlapping voice-cleaning switches in Lipsync & avatars and Transcribe",
- "where": "src/components/studio/composer.tsx: D5's CleanVoiceSwitch (hasCleanVoice, ~L1254/L1289; the slots in studios.ts L124 and L263 have cleanVoice: true) and the new VoiceFirstSwitch block",
- "detail": "Both studios now show D5's 'Clean up voice' (RE-USE on upload, remembered in the browser) next to 'Clean the voice first' (DBS or ElevenLabs at run time). Nothing explains how the two relate or stops both running, so a voice can be cleaned twice: RE-USE, then DBS. In the cloud, it would also pay for isolation of a file that was already cleaned. The e2e script does not look at the two switches together.",
- "verified": "Code trace. Not browser-checked by the reviewer.",
- "fix": "When the slot's file is already a clean-voice result, hide or default off the run-time switch. Or explain the difference in one line."
- },
- {
- "severity": "minor",
- "title": "Preview price understated when the clean-voice step's price is unknown",
- "where": "src/server/generations.ts previewGeneration: post = cost === null || voiced.costUsd === null ? post : post + voiced.costUsd",
- "detail": "When the voice step's cost is null (unknown), the preview returns the main step's price as if it were the total, instead of null or 'unknown'. Today this is unlikely in the cloud because isolation has a catalog price, but it hides the unknown.",
- "verified": "Read the code path.",
- "fix": "If voiced.costUsd is null, make costUsd null."
- },
- {
- "severity": "minor",
- "title": "GPU pre-flight board does not show the DBS requirement for Transcribe and Lipsync with the switch on",
- "where": "src/server/gpu/tools.ts STUDIO_ROWS",
- "detail": "The switch is on by default for video, but if ComfyUI-DBS is missing the run fails at queue time, and the Transcribe or Lipsync rows show no badge. The implementer acknowledged this in 'left'.",
- "verified": "Acknowledged by the implementer, and STUDIO_ROWS is unchanged in the diff.",
- "fix": "Add the DBS pack and weights to those rows' requirements, or say so as a soft requirement."
- }
- ],
- "checks": [
- "Read the stage prompt, binding rules and implementer report. Diff claude/fuobe-parity-4...o/dbs-d6: 27 files, 5 commits. The worktree is clean.",
- "Hot file src/lib/av/clean-voice.ts is not touched. No migrations, routes, graphs, node packs or models were added, so no new licence data is needed. No Higgsfield use. No SAM Audio in the cloud (samAudioCloud false is respected).",
- "Plan traced: open = oss-dbs-separate (mono) -> main with chain {audio, stem voice} (STEM_ALIASES resolves voice/vocals/speech) -> for a lip re-sync, a DBS pass over the clip -> oss-mux with video/audio(voice)/audio2(background) and backgroundVolumeDb 0, which matches the manifest's video-mux-audio params. Cloud = elevenlabs-voice-isolation (fal-ai/elevenlabs/audio-isolation, which maps video_url and audio_url, $0.10/min in the catalog) -> scribe-v2 or the lip sync model.",
- "createGenerations expands voiceFirst only when there is no dependsOn. The nested createPipeline drops voiceFirst from the main step, so there is no recursion. Swap Studio's outer pipeline takes made[0] = the result, because createVoiceFirstRun puts the result first through withAsked.",
- "Accounts: storedMedia header reads run inside the tenant. The inputs are the same URLs the route checked through account-inputs. tests/account-voice-first.test.ts covers input-not-yours and the account and open-engine stamp on every step.",
- "Targeted vitest: voice-first, account-voice-first, chains, swap-studio, genjutsu-api, remove-dialogue, recipe-builder: 7 files, 149 tests, all passed.",
- "eslint on the changed files: clean. npx next typegen, then tsc --noEmit (8 GB heap): exit 0. The .next directory was removed afterwards.",
- "CPU ComfyUI at 127.0.0.1:8188 is up and /object_info lists DBSLoader. The implementer's live DBS->Qwen3-ASR run was not repeated.",
- "Not done by the reviewer: browser checks (the implementer's tests/e2e/voice-first.mjs covers Transcribe, Lipsync and Captions at 1440 and 390 px, light and dark), the full vitest suite, and the GPU lipsync."
- ],
- "verdict": "approve-with-fixes: the core plan, the chain bindings, the account isolation and the tests are sound, and typecheck, lint and the targeted tests pass. Fix the hosted-runs pricing and policy gap (or keep voiceFirst runs off the pool), and revisit the Lipsync default (cloud especially) before merging. The rest are minor."
- },
- "fix": {
- "applied": [
- "Hosted runs (medium, confirmed): previewGeneration now returns steps [{model, op}] for the steps Clean the voice first adds (oss-dbs-separate, plus a second DBS pass and oss-mux for an open lip re-sync with its music put back). A new poolAllowsRun (src/server/hosted.ts) checks the main model and every step against the pool policy. decidePlace and poolQuote use it, so a policy that denies oss-dbs-separate or oss-mux keeps the whole run off the pool. runFacts sends the steps to the billing service as an optional RunFacts.steps field (src/server/billing.ts, documented in docs/billing-hook.md). New test in tests/hosted-runs.test.ts: the steps are planned, sent in the /v1/quote facts and left out without the switch, and a deny on oss-dbs-separate turns poolQuote to null and decidePlace to refuse.",
- "Lipsync default (medium, confirmed): voiceFirstDefault is now on only when the speech is a video's soundtrack (Transcribe with a video, which also covers Captions, Genjutsu and Swap Studio). It is off for any audio upload, including a lip sync's or avatar's voice. The open-engine put-back is unchanged: turning the switch on for a lip re-sync of a clip with sound still splits the clip and muxes its music and effects back at 0 dB. With the switch off on the open engine, the note under it says 'Turn it on to put the clip's music and effects back under it.' (BED_OFF_NOTE). The cloud note is unchanged. Tests and tests/e2e/voice-first.mjs were updated: Lipsync starts off with the off note, then turns on and shows the on note.",
- "Two overlapping switches (minor, confirmed): when the voice slot's file is already a 'Clean up voice' (D5) result (its slot value carries original), the composer starts Clean the voice first off and replaces its hint with 'Your voice was already cleaned when you added it'. The voice is then cleaned twice only if the person asks.",
- "Preview price (minor, confirmed): when the clean-voice step's price is unknown, previewGeneration's costUsd is now null instead of the main step's price. Tested in tests/voice-first.test.ts with demo mode off, a test fal key, and the isolation model's pricing removed for the test. The test fails on the old code.",
- "GPU pre-flight board (minor, confirmed): two new STUDIO_ROWS in src/server/gpu/tools.ts. 'Captions' (/video-tools/captions): DBS, Qwen3-ASR, captions burn-in. 'Lip re-sync, voice cleaned' (/lipsync?model=oss-infinitetalk-v2v): DBS, InfiniteTalk lip re-sync, oss-mux. A missing ComfyUI-DBS now shows on those rows. A test in tests/voice-first.test.ts checks their graphs are in the requirement index, that toolFor resolves them, and that hrefs stay unique."
- ],
- "rejected": [
- "Nothing was rejected. Partly left: Transcribe's own row stays the single-model config row. Its switch is on only for a video, and there is no Transcribe URL that opens with the switch on, so the DBS requirement is shown through the Captions row (same DBS + Qwen3-ASR steps) rather than a second Transcribe row."
- ],
- "checks": [
- "Worktree /home/user/wt/o-dbs-d6 on o/dbs-d6: only this package's commits, base is an ancestor. Base not merged in, as instructed.",
- "npx next typegen, then pnpm typecheck (tsc --noEmit, 8 GB heap): no errors.",
- "eslint on every changed file: exit 0.",
- "Targeted vitest (--maxWorkers=2, FUOBE_ACCOUNT_DISK_FREE_GB=1): voice-first, account-voice-first, hosted-runs, public-signup-tools, remove-dialogue, billing-hook, moderation-hook, composer, av-dub, clean-dialogue, chains, swap-studio, genjutsu-api. 277/278 passed. The one failure was moderation-hook's output-check test timing out under load (known flaky, rule 8). It passed 9/9 when rerun alone.",
- "Full vitest suite, pnpm build and the browser script were not run, as instructed. tests/e2e/voice-first.mjs was updated but not re-run. The CPU ComfyUI was not touched.",
- ".next deleted. git status is clean. Two commits (0a78966b, 677a0567), not pushed."
- ],
- "finalSummary": "Open engine (ComfyUI + ComfyUI-DBS): Clean the voice first runs DBS before Qwen3-ASR, InfiniteTalk or LatentSync, which read its voice stem. With the switch on, a lip re-sync of a clip with sound gets the clip's music and effects back through oss-mux at 0 dB. Verified live on the CPU ComfyUI by the implementer: DBS then Qwen3-ASR, word-perfect. Needs a GPU, not verified: the lip sync with the put-back. The switch is on by default for a video's soundtrack and off for audio uploads, now including the Lipsync voice. A voice already cleaned on upload starts off and says so. Cloud engine: ElevenLabs Voice Isolation ($0.10/min) runs before Scribe v2 or the lip sync model. There is no put-back, because samAudioCloud is false, and the switch says so. Built and unit-tested; the paid calls need a fal key. Unknown step prices now show as unknown. Public sign-up: guests browse the switch read-only. An account's clean-voice run reads only its own files and runs on its own GPU (tests/account-voice-first.test.ts). With hosted runs on, the extra steps are now checked against the pool policy and sent to the billing service as RunFacts.steps, so a denied DBS or mux keeps the run off the install's GPUs. The GPU pre-flight board shows the DBS graph on the new Captions and 'Lip re-sync, voice cleaned' rows.",
- "left": [
- "RunFacts.steps is a new optional field in the billing contract (docs/billing-hook.md). A billing service that ignores it prices only the main model, as before.",
- "Still needs a GPU: a lip re-sync with the put-back. Still needs a fal key: paid ElevenLabs isolation.",
- "The default (on for a video, off for audio) is still a guess until D4 measures WER with and without the switch.",
- "Browser check: tests/e2e/voice-first.mjs was updated for the Lipsync off-by-default flow and the off note, but not re-run here. The off note was kept about as long as the on note so the line count doesn't change when toggling. The cleaned-voice hint is not browser-checked.",
- "Transcribe keeps its single-model pre-flight row. The DBS requirement shows on the Captions row.",
- "Docs pass: mention RunFacts.steps, the Lipsync default (off for an uploaded voice), and the two new pre-flight rows in STATUS/ARCHITECTURE."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/dbs-d6"
- ],
- "notMerged": [],
- "conflicts": "none",
- "checks": "pair (dbs-d6, dbs-d4): typecheck 0, lint 0, vitest 5475 passed, 7 failed (6 main known + eval-harness separation video check, which needed the private clip; fixed in 03e49f2d)",
- "pushed": true,
- "head": "03e49f2d"
- }
-}
diff --git a/docs/handoff/reports/dbs-d7.json b/docs/handoff/reports/dbs-d7.json
deleted file mode 100644
index 6b30cd67..00000000
--- a/docs/handoff/reports/dbs-d7.json
+++ /dev/null
@@ -1,125 +0,0 @@
-{
- "key": "dbs-d7",
- "impl": {
- "branch": "o/dbs-d7 (worktree /home/user/wt/o-dbs-d7, cut from claude/fuobe-parity-4 at fdad177c; commits 0e18c80c WIP, 77540a9e, 68eff96e, a2c30834; a2c30834 not yet pushed by me — coordinator pushes)",
- "summary": "DBS D7 on the open engine only (samAudioCloud false). Shorts, Mixed Media, Genjutsu, Remove object and Character Swap Studio get an 'Original sound' setting: Everything / Music & effects only / Dialogue only / Lower the music (−30…0 dB slider, default −12). On your GPU, graph A (separate-soundtrack-dbs on oss-dbs-separate) splits the working clip (the selection's cut, the upload when it is the whole clip, Swap Studio's 24 fps copy), then the studio's existing stream-copy mux (oss-mux) takes the chosen stem(s). Everything plans exactly as before on both engines. The cloud offers Everything only; the other choices are listed turned off with 'run on your GPU (open source)', and the servers answer 422 in words if asked. 'Remove only this person's voice' (SAM visual-separate) is not built. Music & effects only is suggested for Character Swap Studio, Genjutsu's Character swap and Remove object's person removal (open engine). Faceless gets 'Use a clip's soundtrack as the bed' (open engine): DBS background stem -> oss-audio-loop (when the clip is shorter than the film) -> oss-mux at the existing -14 dB; the cloud says it runs on your GPU and keeps its generated bed.",
- "built": [
- "src/lib/av/original-sound.ts: choices, labels, soundBack() (adds the split step and returns the mux's after/chain/inputs/extra), withSoundExtra, originalSoundProblem, defaultSound, sameSound, soundSummary/soundLine, CLOUD_SOUND_NOTE",
- "src/components/studio/original-sound-field.tsx: shared shadcn Select + level Slider field, soundBody()",
- "Shorts: planStitch takes sound (ShortsPlanInput.sound, session settings.sound); API body + zod SoundChoiceSchema (src/server/shorts-schemas.ts); Stitch again takes an optional new choice and saves it (saveSession now writes settings_json); estimate note; studio field; session view shows the Sound line",
- "Mixed Media: open per-frame render (whose graph keeps the sound) becomes a step, then oss-trim cut -> split -> oss-mux when a choice is made; Smooth passes the choice through the Shorts chain; cloud paths refuse a non-Everything choice; API + UI",
- "Remove object / Genjutsu: joinWithSound takes the choice (shared); 'sound' now also true when a keeps-sound maker/eraser gets a split choice; Genjutsu's open H3 Character swap muxes over the swap when a choice is made; planFuobeRestyle passes it to Shorts; APIs + UIs (suggested default for person removal / Character swap)",
- "Character Swap Studio: planAssembly takes sound; assemble route body takes it; assembly stores it (assembly.sound) and 'current' compares it; field in the Assemble stage (stage-review.tsx, not stage-words.tsx as the brief said) defaulting to Music & effects only on the open engine",
- "Faceless: EpisodeSettings.musicClip {url,name,duration}; resolveModels/buildEpisodeGraph build the split -> loop -> mix chain; SettingsSchema validates it (min 8 s); settings-form MusicClipPicker (MediaSlot, reads the length in the browser)",
- "docs/research/dbs-separation-7.md §9 D7: as-built note with the CPU verification (research correction)",
- "tests/original-sound.test.ts (25 tests: every studio x choice x engine, Everything regression, Faceless bed chain, prices free), 2 new API tests in tests/shorts-api.test.ts (Shorts session + Stitch again with sound, Mixed Media render with sound, cloud 422s), tests/e2e/original-sound.mjs browser check"
- ],
- "tests": "Verified: pnpm typecheck clean (after next typegen); pnpm lint 0 errors (1 pre-existing warning in scripts/comfy/library.spec.mjs); targeted suites (shorts, shorts-api, shorts-pricing, mixed-media, mixed-shorts-originals, genjutsu, genjutsu-api, remove-object, remove-object-api, swap-studio, swap-studio-api, faceless, faceless-api, original-sound) all pass. One full Vitest on a2c30834: 4974 passed, 7 failed in 6 files — all pre-existing per rule 8 (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack 'has no cloud route') plus preset-covers, which timed out under load and passes alone (11/11, rule 14). Live CPU ComfyUI (127.0.0.1:8188, DBSLoader present, BSRNN mono) through the repo's workflow JSONs: Shorts case (20 s synthetic H.264+AAC stereo clip, 12 s selection cut, split, background muxed via video-mux-audio-replace onto a stand-in restyled picture) and Remove object case (whole 20 s clip, Lower the music at −18 dB via video-mux-audio): video packets hash identical to the picture given (framemd5), voice + background = source per channel within 3.1e-5, result soundtrack correlates 0.999 with the intended stem/mix (0.65 with the original for Music & effects only), split 0.35–0.4x real time warm (30 s for 12 s, 56 s for 20 s), each mux ~2 s. The Fuobe server-side chain itself ran in demo mode (mock) in the API tests, not against the live ComfyUI. Browser (demo mode, dev on :3417, then stopped and .next deleted): tests/e2e/original-sound.mjs — all checks passed at 1440 and 390 px, light and dark, open and cloud, for Shorts, Mixed Media, Genjutsu (incl. Character swap suggestion), Remove object, Character Swap Studio Assemble, and Faceless's clip bed; no horizontal scroll, no console errors.",
- "left": [
- "Cloud routes (SAM Audio 'speech', and 'Remove only this person's voice' via fal-ai/sam-audio/visual-separate) not built: owner's samAudioCloud is false",
- "Shorts session view shows the sound choice but has no control to change it for Stitch again (the API accepts one)",
- "Faceless channel defaults (ChannelSettings) don't carry musicClip; it is per episode only. The clip length comes from the browser (no server-side probe)",
- "Genjutsu's setup code (encodeSetup) doesn't carry the sound choice",
- "No time estimate for the extra split step is shown in the studios (it's free; the note says the GPU splits the sound first)",
- "Not verifiable here: GPU video steps, paid fal calls; the real full-studio chains on a GPU",
- "No GPU board (STUDIO_ROWS) change: the split is optional per run, so studios don't list DBS as required; no new workflow, pack or model pin"
- ],
- "docsNotes": "STATUS/ARCHITECTURE not edited. For the docs pass: the studios' 'Original sound' setting (Everything / Music & effects only / Dialogue only / Lower the music) runs on your GPU via DBS before each studio's stream-copy mux (src/lib/av/original-sound.ts); the cloud puts back everything; Faceless 'Use a clip's soundtrack as the bed' (open engine). Brief line numbers were stale (pre-10-30): the Swap Studio UI lives in stage-review.tsx's AssembleStage, not stage-words.tsx; Remove object's sound step is joinWithSound (shared with Genjutsu). Research §9 D7 has an as-built note.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "low",
- "area": "Faceless clip bed (src/components/faceless/settings-form.tsx MusicClipPicker)",
- "issue": "If a valid bed clip is replaced by one that is too short (<8 s) or whose length can't be read, the picker shows the new clip and a warning but never clears settings.musicClip, so the episode still renders with the OLD clip's soundtrack. The slot and the value disagree.",
- "evidence": "The useEffect only calls onChange on success; the slot's onChange calls onChange(undefined) only when the slot is emptied (v falsy). The value line is hidden while `problem` is set, so the stale value is invisible.",
- "fix": "Call onChange(undefined) when the length check fails (or when a new upload starts)."
- },
- {
- "severity": "low",
- "area": "Notes about the split (src/server/shorts.ts notesFor, src/server/mixed-media.ts planInput)",
- "issue": "The 'Original sound: … your GPU splits the clip's sound first (free)' note can show when no split is planned. Shorts' notesFor checks only separates(engine, sound), not source.hasAudio (planStitch returns early for a silent clip). Mixed Media uses info.hasAudio !== false while planMixed splits only when source.hasAudio is truthy, so an unknown hasAudio gives the note with no split. Genjutsu and Remove object check hasAudio correctly.",
- "evidence": "Traced by reading the code. In the UIs the field is disabled for a silent clip, but a choice made before switching to a silent clip stays in state and soundBody still sends it."
- },
- {
- "severity": "low",
- "area": "Faceless clip bed planning (src/lib/catalog/faceless.ts buildEpisodeGraph; src/server/faceless.ts notesFor)",
- "issue": "The whole bed clip is split even when it is much longer than the film (a 10-minute clip for a 1-minute episode runs DBS on all 10 minutes; there is no trim before the split). The estimate notes run musicPlan on oss-dbs-separate, so they never say the clip is looped with a crossfade.",
- "evidence": "The music step has inputs.video = clip.url and sourceDuration = clip.duration. notesFor calls musicPlan(getModel(m.music)…) and m.music is SPLIT_MODEL, which has no MUSIC_MAX or durations, so bed = ceil(seconds) and no loop note is made."
- },
- {
- "severity": "low",
- "area": "Tests",
- "issue": "API coverage only exists for Shorts and Mixed Media (cloud 422, and the open plan with sound). There are no route tests for Genjutsu, Remove object or Swap Studio assemble with `sound` (the cloud 422, and Swap Studio's 409 'already assembled' being skipped when only the sound choice changes), and none for the Faceless SettingsSchema musicClip (8 s minimum). The 'Everything regression' tests in tests/original-sound.test.ts compare the new code with itself (undefined vs everything). The real regression guard is that the existing exact-plan suites (shorts, mixed-media, genjutsu, remove-object, swap-studio, faceless) pass unchanged, and they do."
- },
- {
- "severity": "info",
- "area": "Defaults change the open-engine plan for person replacement",
- "issue": "As the brief asks, Genjutsu Character swap, Remove object's person removal and Swap Studio Assemble now default to Music & effects only on the open engine, which adds a DBS split and a mux by default. The /connect board rows for these studios don't list ComfyUI-DBS. A missing pack is still caught per run by the GPU gate (src/server/gpu/gate.ts), and DBS readiness shows on the Split soundtrack row. Acceptable, but worth a line in the docs pass."
- },
- {
- "severity": "info",
- "area": "Genjutsu H3 Character swap with a split (src/lib/catalog/genjutsu.ts planCharacterSwap)",
- "issue": "The swap step becomes a genjutsu-step but keeps its `title` (Mixed Media strips it in the same situation). This is harmless because step features are hidden from the Library. It is a small inconsistency only."
- }
- ],
- "checks": [
- "Read the review prompt and binding rules. The base is claude/fuobe-parity-4 at fdad177c, the merge base of o/dbs-d7 (a2c30834). The diff is 34 files, +1245/-50.",
- "Owner rule samAudioCloud=false holds. There is no SAM Audio and no visual-separate in src. The cloud offers Everything only (the choices are listed disabled with 'On your GPU (open source)'). originalSoundProblem gives a 422 in plain words on every server path: Shorts create/estimate, Stitch again, Mixed Media (per frame, frames, smooth), Genjutsu, Remove object, Swap Studio assemble. 'Remove only this person's voice' is not built. Today's cloud behaviour is unchanged.",
- "Plan wiring traced. soundBack pushes separate-audio (oss-dbs-separate) on the working clip: the trim key when it is a selection, the upload/24 fps copy URL when it is the whole clip. The mux after/chain stay index-aligned ([picture, split] with stem background/voice; [picture, split, split] with voice + audio2 background and backgroundVolumeDb for Lower the music), matching remove-dialogue's muxChain and the dub precedent in chains.ts. There are no step-key collisions (split / split-sN).",
- "Mux graphs checked. video-mux-audio and video-mux-audio-replace both replace the video's own soundtrack (ConcatenateVideo complete_audio), so makers that keep their sound (Mixed Media's per-frame render, Genjutsu H3, keepsSound erasers) don't leak the original audio into the result.",
- "Live CPU ComfyUI at 127.0.0.1:8188 has DBSLoader (DBS-TIGER-DnR / DBS-BSRNN-DnR). node scripts/comfy/validate-workflows.mjs separate-soundtrack-dbs video-mux-audio video-mux-audio-replace audio-loop-crossfade video-trim --shared: 5/5 validated. The files the validator rewrote (validation-state.json, object_info.subset.json) were reverted, and the tree is clean. I did not rerun a full CPU separation; the implementer's numbers are in the research note.",
- "Public sign-up: no new routes. The Shorts stitch, Swap Studio assemble, Faceless, Genjutsu and Remove object run routes were already refused to accounts. The estimate routes already sit in ESTIMATES, and their schemas extend the body schemas (sound included). There is no new file read, fetch or chain path outside the existing pipeline, and no licence data was needed (no new model, pack or workflow; DBS licences come from D1).",
- "npx next typegen + pnpm typecheck: clean.",
- "eslint on the changed files: 0 problems.",
- "Targeted Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): original-sound, shorts, shorts-api, shorts-pricing, mixed-media, mixed-shorts-originals, genjutsu, genjutsu-api, remove-object, remove-object-api, swap-studio, swap-studio-api, faceless, faceless-api, public-signup, remove-dialogue*: 16 files, 399 tests passed.",
- "Browser check: next dev in demo mode on localhost:3471, then node tests/e2e/original-sound.mjs. All checks passed (Shorts, Mixed Media, Genjutsu including the Character swap suggestion, Remove object, Swap Studio Assemble, Faceless clip bed; open and cloud; 1440 and 390 px; light and dark; no horizontal scroll; no console errors). Server stopped with fuser -k -n tcp 3471, and .next deleted.",
- "I did not run a full Vitest. The implementer reports 7 failures, all listed as pre-existing under rule 8 plus a preset-covers timeout under rule 14. Not re-verified."
- ],
- "verdict": "approve — no blocking issues. The open-engine Original sound choice and the Faceless clip bed are wired correctly and kept on the open engine as the owner's samAudioCloud=false rule requires. Four low findings: the Faceless picker can keep a stale bed clip; split notes can show with no split; long bed clips are split whole; API tests are missing for the Genjutsu, Remove object and Swap Studio routes. They can be fixed in a follow-up."
- },
- "fix": {
- "applied": [
- "3b37dccd Faceless clip-bed picker (review low #1, confirmed): when a new clip is picked, the old bed is cleared at once (emptied, uploading, or a different file), and a clip whose length can't be read or is under 8 s now clears settings.musicClip too. Before, the episode kept rendering with the clip it replaced (src/components/faceless/settings-form.tsx).",
- "e7c37064 Split notes (review low #2, confirmed for the case where the header was read): the Shorts note now needs the clip to have sound when its header was read. estimateWith(body, info, read = true); estimateShorts passes read=false because the browser estimate never reads the header, so a split is still forecast there. In Mixed Media the split (note and input.sound) needs hasAudio === true once probed and is forecast when not probed. Test: tests/shorts-api.test.ts 'a clip read as silent gets no split, and no note about one'.",
- "5ebe3be3 Faceless long bed clip (review low #3, confirmed): a clip longer than the film plus 2 s is first cut on your GPU to ceil(film)+1 s (oss-trim 'music-cut', CPU, free). The DBS split then chains on the cut ([{slot:'video'}], sourceDuration = the cut), so only the part that plays is split. Shorter clips plan as before. The estimate notes now describe the clip bed: 'Your clip's music and effects (N s) loop with a 3-second crossfade…', or 'Only the first X of your clip's sound is used', plus the 600 s loop cap note. The old note read musicPlan on the split model and never mentioned the loop. Tests: tests/original-sound.test.ts (cut step, chain, no cut for a short clip, free), tests/faceless-api.test.ts (loop note, cut note, music part 0, a 5 s clip refused with 400 '8 s or more' by SettingsSchema).",
- "6136ad83 Route tests (review low #4): Genjutsu POST /api/genjutsu (cloud 422 in words; open object swap with Dialogue only gives one oss-dbs-separate step and an oss-mux final whose chain ends with the voice stem). Remove object POST /api/remove-object (cloud Bria 422; open Paint it with Lower the music at -18 dB gives a split and an oss-mux with backgroundVolumeDb -18). Character Swap Studio assemble, cloud: same takes give 409, a split choice gives 422, an explicit Everything gives 409. Open engine: the 24 fps copy is split, the final takes the background stem, assembly.sound is stored, the same choice again gives 409, and Dialogue only assembles again with the voice stem (the 409 is skipped when only the sound choice changes)."
- ],
- "rejected": [
- "Review info: the person-replacement defaults (Music & effects only) add a DBS step that the /connect board rows don't list. Not changed: the split is optional per run, the GPU gate catches a missing pack per run, and the brief asked for these defaults. It is left as a line for the docs pass.",
- "Review info: the Genjutsu H3 Character swap step keeps its title once it becomes a genjutsu-step. Harmless (step features are hidden from the Library); left as is.",
- "Review low #2, unread-header part: when the header hasn't been read (the browser estimate), the note is kept as a forecast, because the real run reads the header and plans the split only when there is sound. Removing it would hide the note on every estimate."
- ],
- "checks": [
- "Branch o/dbs-d7 lists only this package's commits over claude/fuobe-parity-4. Per the coordinator, the base was not merged in this stage, and nothing was pushed.",
- "npx next typegen + pnpm typecheck: exit 0.",
- "pnpm lint: exit 0 (0 errors; 1 warning that was already there, in scripts/comfy/library.spec.mjs).",
- "Targeted Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): original-sound, faceless, faceless-api, genjutsu-api, remove-object-api, swap-studio-api, assist-studio-routes, shorts, shorts-api, mixed-media. 237/238 passed on the first run. The one failure was my own test edit landing in the cloud Swap Studio test instead of the open one. I moved it and reran swap-studio-api alone: 9/9 passed.",
- "No full Vitest in this stage (the coordinator runs it at FINISH). No browser check: the only UI change is the picker's onChange logic, with no layout change.",
- "Owner rule samAudioCloud=false still holds: no SAM Audio and no visual-separate; the cloud offers Everything only.",
- ".next deleted; git status clean."
- ],
- "finalSummary": "Open engine (your ComfyUI): Shorts, Mixed Media, Genjutsu, Remove object and Character Swap Studio offer Original sound: Everything, Music & effects only, Dialogue only, or Lower the music. DBS splits the working clip, then the existing stream-copy mux puts back the chosen stem(s). Faceless can use a clip's soundtrack as its music bed: the clip is cut to the film when it is longer, split, looped with a crossfade when it is shorter, and mixed at -14 dB. Its estimate now says which of these happens. Verified: plans and route chains in demo mode (Vitest), and DBS plus the mux on the CPU ComfyUI (implementer's run: Shorts and Remove object cases). Not verified here: the GPU video steps and the full studio chains on a real GPU. Built but not run live: the new Faceless bed-cut step (oss-trim, an existing validated graph). Cloud engine: Everything only, as today. The other choices are listed turned off with 'runs on your GPU (open source)', and every server path answers 422 in words. SAM Audio and 'Remove only this person's voice' are not built (samAudioCloud=false). It needs no key. Public sign-up: no new routes; the run routes were already refused to accounts or run on their own GPU, and the estimates stay in ESTIMATES through priceAs. Guests browse read-only; accounts get the open-engine choices on their own ComfyUI.",
- "left": [
- "SAM Audio cloud routes and 'Remove only this person's voice' (samAudioCloud is false)",
- "The Shorts session view has no control to change the sound choice for Stitch again (the API accepts one)",
- "Faceless channel defaults don't carry musicClip; the clip length comes from the browser",
- "The Faceless picker's '· loops with a soft crossfade' hint uses a fixed 60 s threshold rather than the film's length (the estimate notes are exact)",
- "Genjutsu's setup code doesn't carry the sound choice",
- "Docs pass: the person-replacement defaults add a DBS step that the /connect board rows don't list",
- "Needs a GPU: the real full-studio chains"
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/dbs-d7"
- ],
- "notMerged": [],
- "conflicts": "none",
- "checks": "batch of 7 (dbs-d7, idol-5, idol-2, idol-6, n7-9, kandinsky6, n7-10): typecheck 0, lint 0, vitest 5788 passed, 6 failed (main known); each merge checked by an independent verifier; n7-10 + Pika Flex interaction fixed in 64900624",
- "pushed": true,
- "head": "64900624"
- }
-}
diff --git a/docs/handoff/reports/dbs-d8.json b/docs/handoff/reports/dbs-d8.json
deleted file mode 100644
index 36ddca2e..00000000
--- a/docs/handoff/reports/dbs-d8.json
+++ /dev/null
@@ -1,105 +0,0 @@
-{
- "key": "dbs-d8",
- "impl": {
- "branch": "o/dbs-d8",
- "summary": "Canvas has a new Split soundtrack node. It has four labelled outputs (Dialogue, Music, Effects, Music & effects), and each one carries its stem (ChainSlot.stem voice/music/effects/background) into the next node's chain. Dialogue is the usual OUT handle, so edges saved with OUT, with no handle or as 'voice' all read as Dialogue, and old one-OUT boards load as before. The node runs only on the open engine with DBS (oss-dbs-separate), because samAudioCloud is false. On a cloud board it is disabled with CLOUD_SPLIT_PROBLEM, and on a cloud-only install with CLOUD_ONLY_PROBLEM; its handles are disabled with the same reasons. Demucs or another separator never stands in for DBS. The DBS step ran for real on the CPU ComfyUI and passed.",
- "built": [
- "src/lib/catalog/canvas.ts: new node type 'split-soundtrack' (Utilities, op separate-audio) with a palette entry. New exports: OutputPortDef, outputPorts() (OUT, or the four stem handles with disabled reasons), SPLIT_HANDLES, SPLIT_STEMS (the model to stems map, which a SAM Audio entry can join later), splitHandle(), edgeStem(), splitProblem(), stemOutput(). Changes to existing functions: connectionError checks the source handle and accepts an optional engine mode for disabled handles. buildRequest/sourceOf carry the edge's stem into chain slots, including through Clone voice's Sample. defaultModelForNode and modelChoices offer only DBS (none on the cloud). describeNode gives the cloud reasons, and tells a board saved on another open separator to pick DBS. cleanGraph rewrites 'voice' to OUT and removes duplicate OUT/null edges. paletteItems disables the node on a cloud board or install, with the reason. All changes add to the existing code.",
- "src/components/canvas/nodes.tsx: StemPorts rows, each with a stem label, a player for that stem once the node has run, and its own source handle (greyed out with the reason when disabled). 'Connect output to…' lists each stem ('Music → Node · Port'). The Output node previews the stem that was wired in and captions it.",
- "src/components/canvas/canvas-editor.tsx: a drag from a stem handle onto empty board keeps that handle. Connection checks pass the engine mode. Taking over connections from a split node moves only its Dialogue edges.",
- "src/components/canvas/canvas-context.tsx: Split icon.",
- "src/server/canvas.ts: GraphSchema node types gain 'split-soundtrack' and also 'restore'. 'restore' was missing before, so a board with a Restore & colourise node could not be saved (fixed, with a test that every node type parses).",
- "tests/canvas-split.test.ts (17 tests), tests/e2e/comfyui-canvas-split.mjs (live end-to-end check against ComfyUI)"
- ],
- "tests": "Verified with tests: tests/canvas-split.test.ts covers the handles, edges carrying stems (including what the server's pickOutput reads), plans per engine, disabled handles and palette entries on cloud and cloud-only, convertEngine keeping the node on the open engine, the storage round trip through parseGraph and cleanGraph with old single-OUT and 'voice' edges, and that every node type can be saved. The canvas suites (canvas, canvas-plus, canvas-api, canvas-editor-state, canvas-models, canvas-comfy) and restore pass. tsc (needs NODE_OPTIONS=--max-old-space-size=6144) and eslint are clean. Full vitest: 5072 passed, 8 failed. 6 of the failures are the known pre-existing ones (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack 'has no cloud route'). moderation-hook and preset-covers timed out under full-suite load and pass when run alone (rule 12). Verified live: node scripts/comfy/validate-workflows.mjs separate-soundtrack-dbs --shared passes on the CPU ComfyUI (DBSLoader present). tests/e2e/comfyui-canvas-split.mjs ran a real board through /api/canvases on a 12 s synthetic clip: Video → Split soundtrack (DBS-BSRNN, CPU, 131.6 s) → Music & effects → Add soundtrack (oss-mux, real CPU mux). It saved all 5 stem edges and ran split then mux at a price of 0. It produced four FLAC stems tagged voice/music/effects/background, and the muxed clip's sound correlates 0.996 with Music & effects and -0.553 with Dialogue. Dialogue → Qwen3-ASR was plan-only (no ASR weights on this host). Browser check (demo mode) at 1440 and 390 px, light and dark: the node shows 4 labelled handles with stem players after a run, and Dialogue → Transcribe and Music & effects → Add soundtrack are drawn. No console or page errors and no sideways scroll. Afterwards the server was stopped and .next deleted.",
- "left": [
- "The SAM Audio cloud route is not built (samAudioCloud is false). If the owner says yes, add 'sam-audio-separate' to SPLIT_STEMS (all four stems for two passes, or voice and background for one pass); the per-handle disabled reasons are already in place.",
- "The node has no 'Put back on the video' shortcut or template. The board wires to Add soundtrack (oss-mux) by hand. A Canvas template could be added later.",
- "Brief out of date: line numbers have moved (CanvasNodeType ~L44, PALETTE ~L265, OUT ~L490, OP_PORTS 'separate-audio' ~L536). CLOUD_SPLIT_PROBLEM and CLOUD_ONLY_PROBLEM already existed in split.ts from D1. None of D8 existed before. Only the Model node could run DBS, with a single OUT that gave the dialogue."
- ],
- "docsNotes": "FEATURES/Canvas: a 'Split soundtrack' utility node with four outputs (Dialogue, Music, Effects, Music & effects), each wiring its own stem into the next node (Transcribe, Change voice, Add soundtrack…). It runs on your GPU (DBS, open source) and is disabled on the cloud with the reason. ARCHITECTURE: Canvas output handles now come from outputPorts(). Every node has OUT except split-soundtrack, whose handles map to ChainSlot.stem; Dialogue is OUT, so boards from before stem handles keep working. Research §9 D8: done as above, cloud left out by the owner's decision. Note for the integrator: GraphSchema now also accepts 'restore' (Restore & colourise boards could not be saved before).",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "low",
- "file": "src/lib/catalog/canvas.ts",
- "line": 456,
- "title": "A Split soundtrack node with no model loses all its stem edges on save",
- "detail": "splitProblem() returns CLOUD_SPLIT_PROBLEM whenever nodeModel() is undefined, so outputPorts() marks all four handles disabled, connectionError() rejects them, and cleanGraph() (used by parseGraph, the server's save path and the editor's pruneEdges) quietly drops every edge out of the node. A Model node with no model keeps its edges, because outputType() falls back to mediaKind. Verified with a scratch script: video -> split(data {}) -> Music -> Output keeps 1 of 2 edges after cleanGraph. In normal use this does not happen, because addNode always sets DBS on an open or both install. It would happen if a node arrives without a modelId (a template, the API, or a model id that later leaves the catalog). The error message ('Switch to Open source') is also wrong on an open board. Suggest: in cleanGraph, check split edges by handle id only (no engine or model gating), or default to SPLIT_MODEL when modelId is missing.",
- "verified": "tsx probe against the worktree: cleanGraph(no-model split).edges.length === 1 (the stem edge was dropped)"
- },
- {
- "severity": "low",
- "file": "src/components/canvas/canvas-editor.tsx",
- "line": 800,
- "title": "'Use result as an input' on a split node can't pick a stem, and the new takeOver branch is never used",
- "detail": "toInput() takes the first output (whichever stem comes first) and labels it 'From Split soundtrack' with no stem name. The new 'moves only Dialogue edges' logic in addInput only runs when takeOver is true, and only the Translate node's dub chip passes that, so for split it never runs. This is a UX gap, not a regression."
- },
- {
- "severity": "low",
- "file": "src/components/canvas/nodes.tsx",
- "line": 952,
- "title": "After a successful split the stem rows replace Results, so the node has no thumbnail/open path",
- "detail": "Results is hidden once the run succeeds, and the inline <audio> players are the only view, so the node itself loses the click-to-open viewer that other generators have (and its download path through it). Also, in SourcePreview, when an Output is wired to a stem the result doesn't have, it falls through to the compact Results grid of every stem instead of saying that stem is missing. Minor."
- },
- {
- "severity": "info",
- "file": "src/lib/catalog/canvas.ts",
- "line": 1424,
- "title": "A split node holding a cloud separator (e.g. demucs) is told 'Switch to Open source', even on an open board",
- "detail": "splitProblem runs before the SPLIT_STEMS check, so a cloud model gets CLOUD_SPLIT_PROBLEM instead of 'pick DBS'. The tests pin this on purpose. It can only happen with a hand-edited or legacy board."
- }
- ],
- "checks": [
- "Read the full diff claude/fuobe-parity-4...o/dbs-d8 (7 files, +568/-42): canvas.ts, nodes.tsx, canvas-editor.tsx, canvas-context.tsx, server/canvas.ts, tests/canvas-split.test.ts, tests/e2e/comfyui-canvas-split.mjs. All changes are additive. No hot files, admin, db migrations, deploy or preview media touched.",
- "Owner rule samAudioCloud=false is respected: SPLIT_STEMS has only oss-dbs-separate. defaultModelForNode(split, cloud) is undefined, and Demucs never stands in. The palette disables the node on a cloud board (CLOUD_SPLIT_PROBLEM) and on a cloud-only install (CLOUD_ONLY_PROBLEM). addNode refuses disabled items. convertEngine keeps the node on DBS (listed as missing).",
- "Stem chaining traced end to end: buildRequest/sourceOf put ChainSlot.stem on the slot. runCanvas passes the request to createGenerations with dependsOn. pickOutput (generations.ts:1039) matches meta.stem through STEM_ALIASES. recipe ChainSlotSchema already allows stem. A duplicate dependsOn (two stems of one split into one node) is accepted by chains.ts and the JSON depends_on.",
- "Backward compatibility: OUT, null and 'voice' all read as Dialogue. cleanGraph rewrites 'voice' to OUT, and its dedupe now treats OUT and null as one edge for every node type, which is harmless. Non-split nodes keep the same connectionError semantics.",
- "server/canvas.ts NODE_TYPES gains split-soundtrack and the missing 'restore'. The test that every node type can be saved covers it.",
- "No new route, model, LoRA, node pack or workflow, so no public sign-up, ESTIMATES/PREVIEWS, tenant/account-inputs, licence-data or pre-flight changes are needed. The existing separate-soundtrack-dbs graph is used.",
- "Targeted vitest (--maxWorkers=2): canvas-split, canvas, canvas-plus, canvas-api, canvas-editor-state, canvas-models, canvas-comfy, split-soundtrack: 180/181 passed. The 1 failure is the known pre-existing split-soundtrack 'has no cloud route' (rule 8). soul-fixes, restore, public-signup: 87/87 passed.",
- "npx next typegen + tsc --noEmit (6 GB heap): clean. eslint on all changed files: clean.",
- "Live ComfyUI at 127.0.0.1:8188: /object_info/DBSLoader is present (DBS-TIGER-DnR, DBS-BSRNN-DnR). node scripts/comfy/validate-workflows.mjs separate-soundtrack-dbs --shared passes. The validator rewrote validation-state.json and object_info.subset.json, and I restored both with git checkout, so the worktree is clean. I did not re-run the 130 s CPU separation e2e; I relied on the implementer's report.",
- "Edge-case probe (tsx scratch script): a split with no modelId drops its stem edges in cleanGraph (finding 1). DBS with data.engine 'cloud' still keeps all edges and plans cleanly on open and both installs.",
- "UI review: StemPorts handles have aria-labels and titles. Disabled handles are not connectable. Keyboard users get a Connect menu with every stem ('Music → Node · Port'). Visitor copy has no jargon. I did not repeat the browser check; the implementer reported 1440/390 px in light and dark with no console errors."
- ],
- "verdict": "approve: the Split soundtrack node does what the brief asks on the open engine, follows the owner's samAudioCloud=false decision, keeps old boards working, and is well tested. The findings are low severity: an edge-loss case that needs a modelId-less node, and UX gaps. None blocks the merge."
- },
- "fix": {
- "applied": [
- "Finding 1 (low, confirmed with a test): a Split soundtrack node with no model, or with a model the catalog no longer has, lost every stem edge in cleanGraph/parseGraph. Changes in src/lib/catalog/canvas.ts: outputPorts() now disables a split node's handles only on a cloud-only install (CLOUD_ONLY_PROBLEM), or for a stem that a SPLIT_STEMS separator doesn't make. A node with no model keeps all its edges, and describeNode says 'Pick a model' or 'That model is no longer in the catalog — pick another'. Tests: cleanGraph and parseGraph keep every edge of a model-less split.",
- "Finding 4 (info, confirmed): a split node on another separator (Demucs, or the two-stem oss-voice-separate) was told 'Switch to Open source' even on an open board. splitProblem() now returns CLOUD_ONLY_PROBLEM on a cloud-only install, '<model> can't split a soundtrack into its stems — pick DBS' for any separator not in SPLIT_STEMS, and null otherwise. The node's edges are kept, and Demucs still never runs in DBS's place. The test that pinned the old message is updated. The palette still disables the node on a cloud board (CLOUD_SPLIT_PROBLEM) and on a cloud-only install (CLOUD_ONLY_PROBLEM).",
- "Finding 2 (low, confirmed): 'Use result as an input' on a split node took whichever stem came first and didn't name it. The node menu now lists one item per stem the node made ('Use music as an input'). toInput(id, stem?) picks that stem with stemOutput and labels the new input 'Music from Split soundtrack'. I also reverted the takeOver logic for 'only Dialogue edges move' in addInput, because nothing used it. canvas-context's toInput type changed to match.",
- "Finding 3 (low, confirmed): after a successful split the node had no way to open a result. Each stem row in StemPorts now has an Open button (Maximize2, aria-label 'Open music stem') that opens the viewer at that output, and the download path goes through the viewer. When an Output node is wired to a stem the result doesn't have, SourcePreview now says 'No music in this result' instead of showing every stem."
- ],
- "rejected": [],
- "checks": [
- "Worktree /home/user/wt/o-dbs-d8 on o/dbs-d8. git log claude/fuobe-parity-4..HEAD lists only this package's commits and one earlier merge of the base, so nothing needed blocking. The current base is not an ancestor of the branch, but I did not merge it because the parent session's instructions say the parent merges it afterwards.",
- "Targeted vitest (--maxWorkers=2, FUOBE_ACCOUNT_DISK_FREE_GB=1): canvas-split, canvas, canvas-plus, canvas-editor-state, canvas-models, canvas-api, canvas-comfy: 7 files, 144/144 passed.",
- "npx next typegen, then pnpm typecheck (NODE_OPTIONS=--max-old-space-size=6144): exit 0.",
- "pnpm lint: exit 0, with 0 errors and 3 warnings, all in files this package doesn't touch (scripts/comfy/library.spec.mjs, src/server/elements.ts).",
- "Full vitest (--maxWorkers=2): the run was killed (background task terminated) before it printed its summary, so I don't have a complete pass count. Every failing file it reported is on the known pre-existing list (rule 8): soul-runs (2), dop-originals (1), preset-featured (1), comfy-reuse (1), split-soundtrack 'has no cloud route' (1). I did not re-run it because the stage allows one full run.",
- "No browser check after these small UI additions (the Open buttons on stem rows, the per-stem menu items, and the missing-stem note). The implementer's browser check at 1440 and 390 px, light and dark, covers the node layout. I deleted .next, git status is clean, and o/dbs-d8 is pushed at 0a3d84c1."
- ],
- "finalSummary": "Split soundtrack is a Canvas utility node with Dialogue, Music, Effects and Music & effects outputs. Each output wires its stem (ChainSlot.stem) into the next node, and Dialogue stays as OUT, so old boards load unchanged. Open engine: runs with DBS (oss-dbs-separate) on your ComfyUI. The implementer verified it live on the CPU ComfyUI: a real DBS separation, then a mux of Music & effects. Downstream GPU steps such as Qwen3-ASR were planned only. Cloud engine: nothing, because samAudioCloud is false. The node is disabled with a reason on a cloud board or a cloud-only install, and Demucs never stands in for DBS. This fix keeps a node's stem edges when it has no model or an unknown one, tells a node on another separator to pick DBS, lets each stem open in the viewer or become a named input, and makes an Output say when its stem is missing. Public sign-up: there is no new route. Canvas runs follow the existing rules: guests browse read-only, and accounts run the node on their own GPU through the existing generations path, with the tenant and account-inputs checks. No keys are involved and no paid calls.",
- "left": [
- "The full vitest run did not finish in this session (it was killed before its summary). The integrator's full run after merging the base will confirm it. All failures it showed were the known pre-existing ones.",
- "SAM Audio cloud route: not built (samAudioCloud is false). If the owner allows it, add 'sam-audio-separate' to SPLIT_STEMS; the per-stem disabled reasons are already in place.",
- "There is no 'put back on the video' template; you connect it to Add soundtrack (oss-mux) by hand.",
- "The branch needs the current claude/fuobe-parity-4 merged in, which the parent does."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/dbs-d8"
- ],
- "notMerged": [],
- "conflicts": "none",
- "checks": "pair (dbs-d8, hi3d-refine): typecheck 0, lint 0, vitest 5447 passed, 6 failed (main known)",
- "pushed": true,
- "head": "11e187bf"
- }
-}
diff --git a/docs/handoff/reports/dbs-d9.json b/docs/handoff/reports/dbs-d9.json
deleted file mode 100644
index 80193ef7..00000000
--- a/docs/handoff/reports/dbs-d9.json
+++ /dev/null
@@ -1,122 +0,0 @@
-{
- "key": "dbs-d9",
- "impl": {
- "branch": "o/dbs-d9",
- "summary": "Assist and MCP gain split_soundtrack and remove_dialogue (DBS D9). Both run the Audio hub's and Video tools' own plans (planSplit / planRemoveDialogue through a now-exported, synchronous planAudioTool in src/server/audio-tools.ts), so a call reads the file's header, picks stems, the mux and the time estimate exactly as the pages do; they are gated, priced first (estimate_job / the approval card: Free on the open engine, with a time estimate), open engine only (owner decision samAudioCloud false: no SAM Audio route, today's cloud dub unchanged). split_soundtrack returns all four stems, one stem (music + effects = the background stem) or one remix at given levels through the new graph C soundtrack-remix-dbs. Offline planner suggestions for 'remove the dialogue', 'just the dialogue', 'just the music', 'lower the music', 'split the soundtrack'. MCP version 1.3.0 -> 1.4.0 with a separate instructions sentence.",
- "built": [
- "Graph C scripts/comfy/hand-built/soundtrack-remix-dbs.json (LoadAudio, DBSLoader, DBSSeparate, 3x core AudioAdjustVolume, 2x AudioMerge add, SaveAudioAdvanced FLAC) with its library.spec.mjs entry, binding keys voiceDb/musicDb/effectsDb (build-library.mjs BINDING_KEYS + spec header), built into workflows/comfyui (manifest sizes kept, no \\u escapes), validated on the live CPU ComfyUI (validate-workflows --shared: separate-soundtrack-dbs and soundtrack-remix-dbs pass); requirements.json rebuilt (no new pack or model: ComfyUI-DBS and the 4 DBS files already pinned)",
- "Real CPU runs of graph C on a 12 s stereo clip (speech over tones + noise): dialogue-only remix ('each channel') took 61 s including model load, 12 s stereo FLAC out, correlation 0.997 with the clean speech (source mix 0.978); a second remix with levels -6/-12/0 ran in 3 s from ComfyUI's cache",
- "src/lib/comfy-variants.ts DBS_REMIX_GRAPH: separate-soundtrack-dbs runs soundtrack-remix-dbs for params.extra.remix (so the GPU pre-flight gate checks the graph that runs); mock provider returns one audio for a remix",
- "src/lib/av/split.ts: KeepStem / splitOutcome / remixWords / REMIX_* and SplitInput.remix (a remix splits every channel of a stereo source unless told otherwise; title 'Mix (…)')",
- "src/server/audio-tools.ts: planAudioTool exported (sync), optional remix field on the split body (also accepted by POST /api/audio-tools; owner-only Assist/MCP use it today)",
- "src/server/assist/studio-tools.ts: own block with split_soundtrack and remove_dialogue (schemas, splitSoundtrackBody / removeDialogueBody, plan with time note from comfyDeviceSeen, run = previewAudioTool check then runAudioTool), exported as SOUNDTRACK_TOOLS and registered by its own TOOLS.push line in tools.ts (STUDIO_TOOLS and run_skill's lists untouched); estimate_job lists them automatically",
- "src/server/providers/comfyui.ts comfyDeviceSeen(): the last device read without asking (Assist cards are planned synchronously)",
- "tools.ts: stems documented on search_models' task (separate-audio: voice/background, DBS music/effects) and on background_audio; agent.ts: one system-prompt line, offlineSoundtrack() used by offlinePlan and, for a request with no file attached, a question asking for the file",
- "mcp.ts: version 1.4.0 and its own instructions sentence (tests/mcp.test.ts and tests/assist-studio-routes.test.ts version assertions updated to 1.4.0)"
- ],
- "tests": "New tests/assist-soundtrack-tools.test.ts (20 tests: splitOutcome, remix plan, graph C variant and bindings via prepareWorkflow, manifest/requirements entry, tool schemas, MCP listing + estimate_job + version, price-first plans, cloud and paid-only refusals with nothing queued, page refusals (silent video, image, keep bed + music_db, gone file), demo runs of a split, a remix and Remove dialogue, offline planner suggestions, public sign-up: Assist changes and /api/mcp are owner-only). tsc clean (after next typegen), pnpm lint 0 errors (3 pre-existing warnings). Full vitest (one run, --maxWorkers=2): 9 failures in 8 files, all pre-existing or flaky except gpu-requirements (mine: requirements.json was stale after the output change; rebuilt, passes): pre-existing per rule 8 split-soundtrack ('has no cloud route'), dop-originals, soul-runs x2, comfy-reuse, preset-featured; flaky per rule 12 preset-covers and moderation-hook (pass alone). Browser: Assist 'Remove the dialogue from this video' with a sounded video attached, demo mode, at 1440 and 390 px in light and dark: card shows the two steps priced 'Placeholder run · free', Run starts both steps, no console errors, no sideways scroll; the demo sample video (no sound) correctly gets 'This clip has no sound' on the card. Dev server stopped and .next deleted.",
- "left": [
- "Cloud routes (SAM Audio passes + loudnorm + compose) not built: samAudioCloud is false; both tools refuse on the cloud engine",
- "remove_dialogue refuses on the cloud with D2's CLOUD_REMOVE_PROBLEM (the brief said CLOUD_SPLIT_PROBLEM for both; that text names Split soundtrack, so the planner's own message was kept); split_soundtrack uses CLOUD_SPLIT_PROBLEM",
- "Engine choice: the tools default to the open engine when the call doesn't name one (MCP's context is 'cloud' whenever Engine mode is both); an explicit engine 'cloud' is refused",
- "Graph C's mix can't keep a remix's levels exact on a loud master (AudioMerge scales the whole sum under 1.0); said in the plan's notes and the tool description",
- "No new Audio hub UI for remixes (the page's own live mixer exports mixes); the API body accepts remix but no page sends it",
- "GPU timings not measured (CPU only here); paid calls not applicable"
- ],
- "docsNotes": [
- "docs/research/dbs-separation-7.md §4.4 graph C / §9 D9: 'As built (D9)': graph C built and validated as described (output has no 'mix' role: comfy-library-4 checks roles against a fixed list, so it is a plain audio output); it runs as separate-soundtrack-dbs's variant for params.extra.remix; a remix splits each channel of a stereo source; measured 61 s for 12 s stereo on the CPU host including model load. D9 open half only (samAudioCloud false).",
- "STATUS/ARCHITECTURE: Assist and MCP have split_soundtrack and remove_dialogue (open engine only); MCP server version 1.4.0.",
- "Brief line refs out of date: studio-tools open dub is now dubSteps ~L278; tools.ts 'L93' is search_models' task description (~L102), background_audio note ~L269; agent.ts offlinePlan ~L1000."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "file": "src/server/assist/agent.ts",
- "line": 1088,
- "title": "The offline soundtrack matcher runs before every other offline intent and takes over unrelated requests, sometimes doing the opposite of what was asked",
- "detail": "offlineSoundtrack() runs at the top of offlinePlan (right after 'remember'), before translations, captions, lipsync and generate. Its regexes are loose: ONLY includes 'keep', REMOVE_SPEECH matches any 'remove/drop/... <anything> voice' and 'no vocals', and LOWER_MUSIC matches 'turn down ... background'. Verified by calling offlinePlan with a video or audio file attached (scratch vitest, no repo edits): 'Remove the background noise from my voice' + audio -> split_soundtrack keep [music, effects] (keeps the noise and drops the voice, the opposite of what was asked); 'Translate this video to French and keep the voice' -> remove_dialogue keep dialogue (on the base this reached the translate branch at L1170); 'Dub this video into Spanish but keep the music' -> split_soundtrack keep [music]; 'Extend this video and keep the music' -> split_soundtrack; 'Upscale this video, no voice changes' -> remove_dialogue; 'Add captions to this video, keep the voice' and 'Lip sync this video to the audio, keep the voice' -> remove_dialogue keep dialogue; 'Make a music video for this song with no vocals' / 'Write a song like this, no vocals' / 'Generate a video with this audio, no talking' + audio -> split_soundtrack. The make/create/write guard only applies when no file is attached. The tests in tests/assist-soundtrack-tools.test.ts cover only the positive phrases, so none of these false positives is tested.",
- "fix": "Either move the soundtrack check after the existing intents (translate/dub/captions/lipsync/generate), or require the soundtrack words to be the request's main verb (e.g. anchor at the start, '^(?:please )?(remove|take out|...)'), drop 'keep' from ONLY unless the sentence names no other operation, skip a remove/lower match when the sentence also names 'noise|echo|hiss|hum' (Clean up voice's job) or another op verb (translate, dub, caption, lip ?sync, extend, upscale, animate, make, create, generate, write), and apply the make/create guard when a file is attached too. Add negative tests for these phrases."
- },
- {
- "severity": "low",
- "file": "src/server/assist/studio-tools.ts",
- "line": 878,
- "title": "The card's time estimate assumes a CPU until something else has read the device, and always says 'on your GPU'",
- "detail": "soundtrackTime uses comfyDeviceSeen(), which only reads the cache that comfyDevice() fills. In a fresh server process (or after the one-minute cache entry, which is still read since 'at' isn't checked), a CUDA host's first Assist/MCP card is priced at CPU speed (DBS_SPEED cpu 0.27x vs cuda 22.4x; hostPick(undefined) = fast), so the time is about 80x too long. The wording is always '… on your GPU', even when the device is a CPU. The run's own reply uses previewAudioTool's live device, so only the card is off.",
- "fix": "Fire comfyDevice() without awaiting it when planning (so the next card is right), or leave the time out when the device is unknown; say 'on your computer' or 'on your ComfyUI' when the device is a CPU."
- },
- {
- "severity": "nit",
- "file": "src/server/providers/comfyui.ts",
- "line": 721,
- "title": "comfyDeviceSeen was inserted between comfyDevice's JSDoc and comfyDevice",
- "detail": "comfyDevice's doc block (L721-724) now sits right above comfyDeviceSeen's own doc block, so comfyDevice has no JSDoc and the orphaned block reads as part of comfyDeviceSeen.",
- "fix": "Move comfyDeviceSeen above the existing comment, or below comfyDevice."
- },
- {
- "severity": "nit",
- "file": "tests/assist-soundtrack-tools.test.ts",
- "line": 304,
- "title": "There is no test for the new remix field on POST /api/audio-tools for accounts",
- "detail": "The new remix field is accepted on the public route (src/server/audio-tools.ts L59), but no test runs it as an account (own GPU / tenant). It adds no new file input, so the existing account-inputs checks still cover media. The risk is low, but nothing tests that a remix body from an account stays on its own GPU.",
- "fix": "Add an account-style remix case beside the existing audio-tools account tests."
- }
- ],
- "checks": [
- "Read the review prompt and binding rules. owner-decisions.json on claude/fuobe-parity-4 has samAudioCloud false: the diff adds no SAM Audio or cloud route, and cloud dub is untouched (no diff in the dub or cloud catalog).",
- "The branch contains the current claude/fuobe-parity-4 (85be87db). 19 files changed. No hot files, admin, deploy, public/previews, LoRA, Higgsfield media or Higgsfield API use.",
- "Graph C scripts/comfy/hand-built/soundtrack-remix-dbs.json matches the manifest bindings (audio 1.audio, separationModel 2.model, channels 3.channels, voiceDb/musicDb/effectsDb 4/5/6.volume, filenamePrefix 9). DBSSeparate output indexes 0 music / 1 sfx / 2 speech are wired correctly. The licence is recorded as data (DBS Apache-2.0, DnR CC BY 4.0, ComfyUI-DBS MIT). requirements.json has the graph with its pack and the 4 DBS files. No new pack or model.",
- "dbsSurroundBed only rewires a subtract AudioMerge, so a >2-channel remix is left alone. The extra.remix flag routes to graph C through resolveWorkflowId, which the GPU pre-flight gate (src/server/gpu/gate.ts) also uses.",
- "Live CPU ComfyUI at 127.0.0.1:8188 (before the restart): object_info has DBSLoader, DBSSeparate, AudioAdjustVolume (INT dB -100..100), AudioMerge, SaveAudioAdvanced. Ran workflows/comfyui/soundtrack-remix-dbs.json on a 5 s stereo clip (voice -100, music -6, effects 0, each channel): success, 5.0 s stereo FLAC. The input and output files were then deleted. After the coordinator's restart the server was not answering yet, and nothing further needed it.",
- "Core AudioAdjustVolume read from ComfyUI's source: gain = 10^(dB/20), so -100 dB is effectively silent, as the code assumes.",
- "Read studio-tools, split.ts, audio-tools.ts, mcp.ts, tools.ts and agent.ts. The new tools are additive (own SOUNDTRACK_TOOLS push; STUDIO_TOOLS and run_skill untouched). MCP is 1.4.0 everywhere with its own instructions sentence. Paid-only installs and an explicit cloud engine are refused in words before anything is queued.",
- "Public sign-up: Assist changes (isAssistChange) and /api/mcp (ownerOnly) are owner-only, so visitors can't run the tools. POST /api/audio-tools's remix adds no new file input.",
- "Probed offlinePlan / offlineSoundtrack with 19 phrases through a scratch vitest config outside the repo (finding 1).",
- "Targeted tests: assist-soundtrack-tools, mcp, assist-studio-routes, split-soundtrack, comfy-library-4, gpu-requirements, public-signup-tools, remove-dialogue*, comfy-variants*: 207/208 pass. The one failure is split-soundtrack 'has no cloud route' (pre-existing, rule 8).",
- "tsc --noEmit clean after next typegen. pnpm lint: 0 errors, 3 pre-existing warnings. .next deleted afterwards.",
- "Full vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1 --maxWorkers=2; the first run was killed by the worker restart, so it ran once more): 9 failed / 5075 passed in 8 files. comfy-reuse, dop-originals, preset-featured, soul-runs x2 and split-soundtrack are pre-existing (rule 8). moderation-hook, picker-covers and preset-covers failed under load and pass when run alone (rule 12). gpu-requirements passes. Nothing new fails.",
- "No browser re-check by the reviewer: the implementer reported Assist 'Remove the dialogue from this video' in demo mode at 1440/390, light/dark. The demo paths are covered by the new tests. No dev server was started. The worktree is clean and .next is absent."
- ],
- "verdict": "changes-requested: the tools, graph C, routing, pricing-first, engine refusals and public sign-up handling are correct and verified (graph C runs on the live CPU ComfyUI; no new test failures). Before merging, fix the offline planner's soundtrack matcher: it runs ahead of every other offline intent and takes over translate/dub/caption/lipsync/extend/upscale requests that mention 'keep the voice/music' or 'no vocals', and turns 'remove the background noise from my voice' into a split that drops the voice. Add negative tests for it. The other findings are minor."
- },
- "fix": {
- "applied": [
- "medium (agent.ts offline soundtrack matcher hijacking other intents): confirmed. Added OTHER_JOB guard in offlineSoundtrack: a request naming another job (translat*, dub*, captions/subtitles, lip sync, extend, upscale, animate, make (except 'make it/the/this/that ...'), create, generate, write, compose, record, restyle, enhance, clean up) or noise/echo/hiss/hum/reverb/denoise (Clean up voice's job) returns null, with or without a file attached (the make/create guard now applies when a file is attached too). Dropped bare 'keep' from ONLY ('keep only/just the X' still reads through only/just). New negative test covering all 10 reviewer phrases plus 'Keep the voice and make it 9:16': offlineSoundtrack is null and offlinePlan never picks split_soundtrack/remove_dialogue; positives 'keep only the music', 'make it just the music', 'turn down the music under the dialogue' still route.",
- "low (studio-tools.ts card time assumes CPU and always says 'on your GPU'): confirmed. soundtrackTime (now exported for tests) leaves the time out when no device has been read yet and fires comfyDevice() in the background so the next card has it; says 'on your computer' when the device is a CPU, 'on your GPU' otherwise. Test: null with no device, CPU wording, CUDA wording.",
- "nit (comfyui.ts comfyDeviceSeen between comfyDevice's JSDoc and comfyDevice): moved comfyDeviceSeen above the comment so comfyDevice keeps its doc.",
- "nit (no account test for the remix field on POST /api/audio-tools): added to tests/public-signup-tools.test.ts's Split soundtrack price-check case: an account's remix body is priced on its own GPU (costUsd 0, not a demo), and the owner's file answers it as gone (422). Accounts' runs on /api/audio-tools already answer own-gpu-tool (existing test)."
- ],
- "rejected": [],
- "checks": [
- "Worktree /home/user/wt/o-dbs-d9 on o/dbs-d9: only this package's commits plus a merge of claude/fuobe-parity-4; base not re-merged in this stage per coordinator.",
- "Targeted: tests/assist-soundtrack-tools.test.ts (22) and tests/public-signup-tools.test.ts pass (38/38); assist-studio-routes and mcp pass.",
- "npx next typegen; tsc --noEmit exit 0 (pnpm typecheck OOMed at default heap; reran with NODE_OPTIONS=--max-old-space-size=8192, clean).",
- "pnpm lint: 0 errors, 3 pre-existing warnings.",
- "Full vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1 --maxWorkers=2, one run): 7 failed / 5079 passed in 6 files. Pre-existing per rule 8: comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack 'has no cloud route'. computer-relay ('finds ComfyUI on another port') failed under load and passes alone (18/18); untouched by this change.",
- "No browser check needed (planner/server-only changes); .next deleted; git status clean. Committed c1927a0b, not pushed."
- ],
- "finalSummary": "Open engine: Assist and MCP split_soundtrack and remove_dialogue run the Audio hub's and Video tools' own plans on the user's ComfyUI (graph C soundtrack-remix-dbs for remixes), priced first (free, with a time estimate once the GPU's device is known; 'on your computer' on a CPU); verified on the CPU ComfyUI in impl/review, needs a GPU for real speed. Cloud engine: both tools refuse in words (samAudioCloud false: no hosted DBS, no SAM Audio stand-in); today's cloud dub unchanged. Offline planner now suggests the soundtrack tools only when the request is about the soundtrack itself, leaving translate/dub/captions/lip sync/extend/upscale/generate/noise clean-up requests to their own plans. Public sign-up: guests and accounts cannot run the tools (Assist changes and /api/mcp are owner-only); an account's POST /api/audio-tools?preview=1, remix included, is priced for its own GPU on its own files, and its runs answer own-gpu-tool. No key needed.",
- "left": [
- "Cloud routes (SAM Audio) not built while samAudioCloud is false; both tools refuse on the cloud engine.",
- "remove_dialogue refuses on the cloud with D2's CLOUD_REMOVE_PROBLEM (brief said CLOUD_SPLIT_PROBLEM for both).",
- "Graph C's AudioMerge scales the sum under 1.0, so remix levels aren't exact on a loud master (stated in notes).",
- "No Audio hub UI sends a remix; the run reply's 'takes … on your GPU' still uses that wording on a CPU (the card is fixed).",
- "GPU timings not measured (CPU host only).",
- "Base merge of origin/claude/fuobe-parity-4 left to the coordinator at FINISH."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/dbs-d9"
- ],
- "notMerged": [],
- "conflicts": "assist/agent.ts STABLE_SYSTEM line (both kept)",
- "checks": "batch of 6 (dbs-d9, idol-7, w2s-w5, w2s-w6, w2s-w7, idol-4): typecheck 0, lint 0, vitest 5907 passed, 8 failed (6 main known + preset-covers and reuse-pack-pin load timeouts, 13/13 alone); each merge but idol-4 checked by an independent verifier (idol-4 merged by hand after: one conflict, its tests 99/99); W5/W6/W7 joined by follow-ups 642a167e, bef8778e, 22378b4b, 739a0c1d",
- "pushed": true,
- "head": "148f2459"
- }
-}
diff --git a/docs/handoff/reports/hi3d-refine.json b/docs/handoff/reports/hi3d-refine.json
deleted file mode 100644
index 3305effa..00000000
--- a/docs/handoff/reports/hi3d-refine.json
+++ /dev/null
@@ -1,136 +0,0 @@
-{
- "key": "hi3d-refine",
- "impl": {
- "branch": "o/hi3d-refine (6 signed commits on claude/fuobe-parity-4 at cb1d3b3a, not pushed; worktree /home/user/wt/o-hi3d-refine)",
- "summary": "Image to 3D now has a 'Refine detail · Hi3D 1.0' switch with a 512 / 1024 / 1536 choice. It is open-engine only. When it is on, the server runs two steps: the open model the user picked (Pixal3D, TRELLIS.2, Hunyuan3D 2.1 or TRELLIS.2 multi-view) builds the mesh, then Hi3D refines that mesh's geometry from the same photo (chain slot model3d). Both models are kept. A finished mesh also gets 'Refine this mesh' (with its price) and a 'Print-ready' export. The export writes an STL or 3MF in the browser, scaled to a height the user sets, Z up and standing on the bed, after a watertight check. Refined results say they are geometry only and show 'Powered by Hi3D 1.0' linked to http://hi3d.ai/, as the licence asks. The cloud engine says Refine runs on your GPU only (nobody hosts the open Hi3D; fal's hitem3d/hi3d/* endpoints are Hitem3D's closed product and none takes a mesh; Replicate has nothing). 'Paid APIs only' hides it. Accounts are refused with own-gpu-tool, like every 3D model. The open route uses T8star's community ComfyUI pack (Comfyui-Hi3d-T8 v0.5.1, MIT, in the ComfyUI Registry) with core SaveGLB, so the server's GLB finish takes the result as it does for other 3D models. No Fuobe pack or sidecar was needed: four community packs appeared after comfyui-oss-4 said there was none.",
- "built": [
- "Research: docs/research/hi3d-refine.json, checked at the primary sources. HF revision d502e938 with exact sizes and SHA-256: 3.68 + 3.68 + 0.38 GB of Hi3D weights, plus the DINOv2-L (1.22 GB) and CLIP ViT-L/14 (1.71 GB) encoders Hi3D needs, 10.66 GB in all. Also: licence terms, hardware, the community packs, hosting, and the texture verdict. Corrections in new-models-10.json/.md: the release date is 10-23, not 10-16, and the pack is T8mars/Comfyui-Hi3d-T8 (t8star/Hi3d-Comfy is its weights repo).",
- "New operation refine-3d (3D model + photo -> model3d) in types.ts and plan.ts (inference, promptless, required inputs), a mock demo output, the 3D finish (modelToFinish), and Assist/MCP: the generate job gains model3d and mesh_resolution, and mesh_resolution on an open image-to-3D model adds the refine step.",
- "src/lib/av/hi3d.ts: resolutions, refineRequest, withRefine, chainedRefine, canRefine, plus the notice, hardware and geometry-only copy.",
- "Catalog: model oss-hi3d-refine (open, kind model3d, hidden from pickers, engineNote 'your GPU only'). A 'Refine detail · Hi3D 1.0' control (off / 512 / 1024 / 1536) on oss-pixal3d, oss-trellis2, oss-hunyuan3d-21 and oss-trellis2-multi, so the Canvas 3D node and the composer offer the refine step through the same server chain.",
- "Server: createRefinedModel in chains.ts and its dispatch in createGenerations. It refuses a cloud model and needs a photo. The ComfyUI provider binds inputs.model3d (uploaded to ComfyUI's input folder like any input) and refuses a resolution other than 512/1024/1536 or a missing mesh.",
- "Graph: scripts/comfy/hand-built/mesh-refine-hi3d.json. Hi3DModelLoader (models/Hi3D, CPU offload, flash attention) + LoadImage -> core BiRefNet RemoveBackground mask -> Hi3DLoadMesh -> Hi3DRefine -> SaveGLB. Added to library.spec.mjs (packs, PACK_CLASSES, KNOWN_MODELS for models/Hi3D/{hi3d,dino,clip}, requiredModels, new binding keys model3d/meshResolution/cpuOffload, Hi3DLoadMesh as a file input). Built into the manifest; the pack is pinned in packs.json; 12 model files are pinned with SHA-256 in model-pins.json; requirements.json is rebuilt; the GPU board gets a row 'Image to 3D, refined' (Pixal3D -> Hi3D).",
- "Install: opt-in HI3D=1 block in scripts/comfy/install-comfyui.sh. It clones the pack at its pinned commit, installs its requirements, and downloads the weights at pinned revisions with sha256sum -c. A Hi3D section in scripts/comfy/README.md covers hardware, install steps, weights, licence, texture and not-run status.",
- "Licences: the Hi3D Open License Agreement 1.0 is recorded with class 'conditions', and its notice 'Powered by Hi3D 1.0' is read from the workflow licence. The pack is recorded in NODE_PACKS. Settings -> Models & licences lists the model with its on/off switch like any catalog model.",
- "UI (additive, new files beside the Image to 3D studio): refine-option.tsx (switch, resolution, hardware note, the cloud-engine note with 'Use your GPU', RefineDialog with price, PoweredByHi3d link), print-dialog.tsx and glb-triangles.ts (three.js loaded only when the dialog opens), src/lib/print3d.ts (weld, watertight check, Z-up scale to height, binary STL, 3MF in a stored zip with no new dependency). Small hooks into model3d-studio.tsx, model-card.tsx and page.tsx."
- ],
- "tests": [
- "New tests/hi3d-refine.test.ts: 25 pass. Covers the parameters, the request shape, the chain per engine (open from one image and from several, off, a cloud model refused, Paid APIs only refused, accounts own-gpu-tool), the price check (Free), the finish, the graph bindings, pins, pack and install script, the provider binding and its refusals, the licence class and notice, the STL/3MF output (sizes, scaling, CRC, zip structure, watertight on a seamed cube and an open one), and Assist/MCP planning and starting.",
- "Targeted existing suites: 33 files, 764 tests pass (gpu-api/readiness/requirements, hosted-runs, glb-finish-safety, chains, account-tenant/inputs/tools, public-signup x3, assist-runtime/context, canvas x3, cloud-catalog, licences, model3d x2, open-engine, comfy-provider, catalog, plan, demo-ops, comfy-library-4/7/notes, model-access x3, mcp). Two test edits: tests/comfy-library-4.test.ts gains 'mesh-refine-hi3d' in its unvalidated list (the allowed edit), and tests/open-engine.test.ts gains 'hi3dRefine' in PROVIDER_PARAMS (a server-side param, not a graph binding). No full suite was run, per the stage rules.",
- "tsc --noEmit is clean and eslint is clean on the changed files.",
- "Live ComfyUI (CPU, 0.41.0): npm run build -- mesh-refine-hi3d works. validate-workflows gives the expected missing_node_type (the pack needs a CUDA GPU and was not installed). object_info.subset.json was left at the base's version. The live object_info was used to check the texture question.",
- "Browser (pnpm dev, FUOBE_DEMO_MODE=on, port 3461): Image to 3D at 1440 and 390 px, light and dark. Checked: the Refine switch and resolutions with the Powered-by link, the cloud-engine note, a real demo chain (Pixal3D -> Hi3D refine, both succeeded), 'Refine this mesh' and its price, 'Print-ready' with the watertight check and a real STL download, and no sideways scroll. All checks passed on 3 runs. The very first run (during first compile) logged one hydration warning about caret-color on MediaDrop's hidden file input; it did not repeat, and is most likely Playwright's screenshot caret styling racing hydration. The server was stopped and .next deleted.",
- "Nothing ran Hi3D for real (no GPU here). The refine graph is unvalidated until a GPU ComfyUI with the pack runs it."
- ],
- "left": [
- "Run the graph on an Ampere+ GPU with HI3D=1: node validate-workflows.mjs mesh-refine-hi3d, then a real Pixal3D -> Hi3D chain. Confirm VRAM at 1536 (vramGb 24 is an estimate) and whether the default attention 'flash' should become 'sdpa' where flash-attn isn't built.",
- "'Texture it' isn't possible on this base, so the refined mesh ships as geometry only. Core BakeTextureFromVoxel/PaintMesh can bake TRELLIS.2's texture voxels onto another mesh, but only inside the run that made them and in their frame. Hi3D's output is recentred at unit radius, and no core node can move a mesh back. Owner step: either (a) a few-line node that fits the refined mesh to the coarse mesh's bounding box, so one graph can run Pixal3D/TRELLIS.2 -> Hi3D -> fit -> UnwrapMesh -> BakeTextureFromVoxel -> ApplyTextureToMesh, or (b) a Hunyuan3D-Paint 2.1 pack, whose licence excludes the EU, UK and South Korea.",
- "The GPU pre-flight reads the Hi3D weight files as 'unknown' rather than present: ComfyUI doesn't list the models/Hi3D folder unless extra_model_paths.yaml registers it.",
- "The refine toggle is offered in From an image and From several images. From text gets 'Refine this mesh' on its card (it uses the drawn still) rather than the switch.",
- "The tests/comfy-library-4.test.ts unvalidated list gained 'mesh-refine-hi3d' (the allowed edit)."
- ],
- "docsNotes": [
- "docs/FEATURES.md / STATUS.md: Image to 3D 'Refine detail · Hi3D 1.0' (open engine only, 512/1024/1536, geometry only, 'Powered by Hi3D 1.0'), 'Refine this mesh' on any finished mesh, 'Print-ready' STL/3MF with real height and watertight check, the Canvas 3D node's Refine control, and Assist/MCP refine-3d / mesh_resolution. Remove hi3d-refine from the queued list in STATUS.md item 5.",
- "docs/ARCHITECTURE.md: op refine-3d; createRefinedModel in src/server/chains.ts (chain slot model3d); the comfy binding key model3d (inputs.model3d uploaded to ComfyUI's input folder); src/lib/print3d.ts (browser-side export).",
- "docs/SELF-HOSTING.md: HI3D=1 (and HI3D_WEIGHTS=0) in install-comfyui.sh, 10.66 GB of weights, an Ampere+ NVIDIA GPU with CUDA 12, no CPU path.",
- "CREDITS.md / licences page: Hi3D v1.0 by OCEANO HK HOLDING LIMITED under the Hi3D Open License 1.0. The scale rule: above 200,000 MAU or USD 1M monthly revenue, apply for a separate licence. T8star's Comfyui-Hi3d-T8 (MIT).",
- "Brief out of date: Hi3D was released 10-23, not 10-16. Total weights are 10.66 GB with the encoders (7.73 GB Hi3D alone). Community ComfyUI packs now exist (T8mars/Comfyui-Hi3d-T8, wadi-k/ComfyUI-Hi3D-Refinement, Rizzlord and thatname ComfyUI-Hi3D), so no Fuobe pack or sidecar was needed. The n7-9 WorldCast worker is not on the base."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "high",
- "title": "Refine graph gives Hi3D the subject's mask the wrong way round, so the subject is cut out and the background is kept",
- "where": "scripts/comfy/hand-built/mesh-refine-hi3d.json (and workflows/comfyui/mesh-refine-hi3d.json): node 4 RemoveBackground -> node 6 Hi3DRefine.mask",
- "detail": "Core RemoveBackground returns a foreground mask where 1 means the subject (comfy_extras/nodes_bg_removal.py: 'Generated foreground mask'; comfy/bg_removal_model.py returns sigmoid(BiRefNet)). T8's Hi3DRefine reads its optional MASK with 1 meaning transparent: image_to_pil sets alpha = (1 - mask) in comfy_nodes.py at the pinned commit 73848490, and docs/COMFYUI.md line 23 says 'MASK 的 1 表示透明'. Fuobe's own bg-remove-birefnet graph adds an InvertMask between RemoveBackground and JoinImageWithAlpha for this reason. As wired, every refine makes the object transparent and keeps the background as Hi3D's reference image. Hi3D uses the alpha to frame the subject (README line 157), so it is conditioned on the wrong pixels. tests/hi3d-refine.test.ts checks only the binding keys, not what the mask means.",
- "fix": "Put core InvertMask between node 4 and Hi3DRefine.mask, or leave the mask out and feed an RGBA cut-out. Add a test that the mask passes through an InvertMask, or that it is absent."
- },
- {
- "severity": "high",
- "title": "Graph always uses flash attention, but nothing installs flash-attn, so every run on a fresh HI3D=1 install fails",
- "where": "mesh-refine-hi3d.json node 1 Hi3DModelLoader attention: 'flash'; scripts/comfy/install-comfyui.sh HI3D block",
- "detail": "The HI3D=1 block installs only the pack's requirements.txt. At the pinned commit that file has numpy, trimesh, spconv-cu126, triton and others, but no flash-attn. At run time hi3d_native/runtime.py attention('flash') does 'import flash_attn' and otherwise raises RuntimeError('缺少 FlashAttention,请在 Hi3D 加载器选择 sdpa'). The pack's docs make sdpa the default and say flash is only for an existing compatible FlashAttention. So following Fuobe's own install steps gives a refine that always fails, with a raw Chinese error. attention also isn't a binding, so the server can't change it. The implementer raised this in 'left' but shipped the setting that fails.",
- "fix": "Set attention to 'sdpa' in the graph, or add a binding that defaults to sdpa. Alternatively, install a pinned flash-attn in the HI3D block and say so in scripts/comfy/README.md."
- },
- {
- "severity": "medium",
- "title": "Refine detail is silently dropped when the image-to-3D step waits on an earlier step (Canvas 3D node fed by an image node; Assist plan text-to-image then image-to-3d)",
- "where": "src/server/generations.ts createGenerations: the createRefinedModel branch requires !opts.dependsOn; src/server/canvas.ts ~628-631 passes dependsOn for upstream nodes in the same run",
- "detail": "Two common flows hit this. One is a Canvas 3D node with the new 'Refine detail · Hi3D 1.0' control, wired from an image node that runs in the same pass. The other is an Assist or MCP plan where a still feeds an open image-to-3d job that sets mesh_resolution. In both, the 3D step is created with dependsOn, so the refine branch is skipped and only the coarse model is made. hi3dRefine stays in params.extra and goes into the coarse graph's values, where nothing reads it. There is no refine and no error, and the toast and the control both say a refine will run. Tests cover the no-dependency case only (tests/hi3d-refine.test.ts 'open:' and the Assist 'set the refine step…' case starts from a ready photo).",
- "fix": "When dependsOn is set, chain the Hi3D step after the coarse step with two slots: model3d from the coarse step, and the photo from the upstream image step. Or refuse with a clear message. Add a test for each of the two flows."
- },
- {
- "severity": "low",
- "title": "The GPU pre-flight can't see the Hi3D weights it lists",
- "where": "workflows/comfyui/requirements.json files Hi3D/* (presence 'list' for the safetensors, 'unobservable' for the JSON files)",
- "detail": "models/Hi3D is not a folder ComfyUI registers: the pack reads it directly through folder_paths.models_dir, and folder_names_and_paths has a 'hi3d' entry only when extra_model_paths.yaml adds one. So a 'list' presence check never finds the files, and the board can't show 'Image to 3D, refined' as Ready even when everything is installed. The implementer noted this in 'left'.",
- "fix": "Mark these files 'unobservable' (or 'loader') so they don't read as missing. Or have install-comfyui.sh register a hi3d folder in extra_model_paths.yaml."
- },
- {
- "severity": "low",
- "title": "'Powered by Hi3D 1.0' appears only on Image to 3D's result card",
- "where": "src/components/model3d/model-card.tsx; Canvas 3D node output; CREDITS.md",
- "detail": "Hi3D's results made through the Canvas 3D node, Assist or MCP show no notice. Licence Section 7 is also met by an About page or acknowledgements. But CREDITS.md is not updated on the branch (it is only in docsNotes), so no acknowledgement covers the other surfaces yet. The brief asks for the notice wherever its output is shown.",
- "fix": "Add the Hi3D credit with its http://hi3d.ai/ link to CREDITS.md in this package, or show the notice on the Canvas node's result."
- }
- ],
- "checks": [
- "Read review-prompt.txt and main-rules.md (both rewritten after the restart; their content is unchanged). Branch o/hi3d-refine at 527e0a10, 6 commits on claude/fuobe-parity-4, clean tree. No hot files edited apart from the allowed comfy-library-4 unvalidated-list line and the validation-state.json rebuild. No Higgsfield API or media, no analytics, no deploy files.",
- "Read the whole diff: hi3d.ts, refine-option.tsx, print-dialog.tsx, glb-triangles.ts, print3d.ts, model-card/studio/page hooks, catalog (model plus controls on 4 open 3D models), plan.ts, types.ts, chains.ts createRefinedModel, generations.ts dispatch, comfyui.ts binding and refusals, mock.ts, model3d-finish.ts, assist/tools.ts, gpu/tools.ts row, licences.ts (KNOWN entry plus NODE_PACKS), library spec, packs.json, model-pins, requirements.json, install script.",
- "Fetched the pinned pack T8mars/Comfyui-Hi3d-T8@73848490 into the scratchpad and read it as data only (nothing run). Node and input names (model_root, cpu_offload, attention, keep_model_loaded, download_missing; mesh_file; resolution 512/1024/1536, steps, seed, optional mask) and the models/Hi3D/{hi3d,dino,clip} file list match the graph and KNOWN_MODELS. Found the mask polarity and flash-attn problems there.",
- "Live ComfyUI object_info and source: RemoveBackground outputs MASK 'foreground mask'. SaveGLB takes MESH. /upload/image stores any file type under its own name, so the .glb keeps its extension and passes Hi3DLoadMesh's suffix check (readRef keeps the asset's basename).",
- "Chain trace: chainValue passes the coarse step's raw GLB url (not the meshopt web GLB), which trimesh can read. The finish runs on refine-3d output. model3dView.glb is the raw mesh for 'Refine this mesh'.",
- "Public sign-up: createGenerations refuses any model3d model for an account (generations.ts:913), which covers oss-hi3d-refine and the chain. The UI hides refine from visitors (refineAllowed = !visitor). Previews go through the existing run preview. ASSET_REFS covers request_json. No new route.",
- "Cloud and Paid APIs only: no cloud route. The cloud engine shows the note with 'Use your GPU'. engineMode 'cloud' hides the option. createRefinedModel refuses a non-open model. The Models & licences list shows hidden models ('a helper step studios run'), and the licence class is conditions with the notice parsed from the workflow licence.",
- "Checked README and LICENSE in /home/user/ext/hi3d: pass ladder 512/1024/1536 = 1/2/3 passes and 25 steps (matches the UI copy). The Section 7 link target is http://hi3d.ai/ (matches HI3D_URL). Section 7 also allows an About page or acknowledgements.",
- "print3d.ts review: Y-up to Z-up rotation (x,-z,y) has determinant +1, so winding is kept. Bed placement and centring are correct. Binary STL layout is correct and the header doesn't start with 'solid'. Stored-zip offsets and CRC are correct. The watertight edge key fits in 2^53. No defects found.",
- "Vitest (targeted): hi3d-refine, open-engine, comfy-library-4, chains, public-signup, licences, gpu-requirements, model3d*, glb-finish-safety: 12 files, 274 tests, all pass.",
- "npx next typegen && tsc --noEmit: clean. eslint on src/components/model3d, hi3d.ts, print3d.ts, chains.ts: clean.",
- "Browser (next dev on port 3471, FUOBE_DEMO_MODE=on, http://localhost): Image to 3D at 1440 light and dark and 390 light and dark. The cloud note appears. 'Use your GPU' works with the keyboard (Enter), the Refine switch toggles with Space (aria-checked true), and the resolutions, hardware note and 'Powered by Hi3D 1.0' link (http://hi3d.ai/) show. No sideways scroll, no console errors. Server stopped with fuser -k and .next deleted.",
- "Nothing here can run Hi3D (CPU-only ComfyUI, pack not installed): the graph problems were found by reading the pinned pack source, not by running it."
- ],
- "verdict": "changes-requested: the open route as shipped can't produce a correct refine. The mask is inverted, so Hi3D is conditioned on the background, and the 'flash' attention setting fails on any install made with Fuobe's own HI3D=1 steps. Both are one-node or one-value fixes in mesh-refine-hi3d.json. Also fix or refuse the silent refine drop when the 3D step depends on an earlier step (Canvas and Assist). The rest is sound: UI, print export, licence data, the engine rules, public sign-up and the pre-flight wiring."
- },
- "fix": {
- "applied": [
- "HIGH, mask polarity (confirmed: the pinned pack's comfy_nodes.py image_to_pil sets alpha = 1 - mask, and core RemoveBackground's MASK is the foreground). mesh-refine-hi3d gains core InvertMask (node 8) between RemoveBackground and Hi3DRefine.mask, so Hi3D keeps the subject and drops the background. Updated in the hand-built graph, the built workflow, the manifest notes, scripts/comfy/README.md and docs/research/hi3d-refine.json. New test: the mask goes RemoveBackground -> InvertMask -> Hi3DRefine in both the hand-built and the served graph.",
- "HIGH, flash attention (confirmed: the pinned requirements.txt has no flash-attn, and runtime.py raises 'missing FlashAttention' for 'flash'). Hi3DModelLoader attention is now 'sdpa' (the pack's own SDPA adapter). README says no flash-attn build is needed and 'flash' is only for installs that already have one. New test: the graph uses sdpa, and install-comfyui.sh doesn't claim to install flash-attn.",
- "MEDIUM, refine silently dropped when the 3D step depends on an earlier step (confirmed: createGenerations skipped createRefinedModel whenever dependsOn was set). createRefinedModel now takes {batchId, dependsOn}. The coarse model waits for the upstream steps. Hi3D waits for both the coarse model (slot model3d) and the step that feeds the photo (slot images), unless the request carries its own first photo. The Canvas batchId is kept too. New tests: a direct dependent chain run through in demo mode (all three steps succeed; Hi3D gets the coarse step's GLB and the still's image), an own-photo case, and an Assist plan (still, then oss-pixal3d with mesh_resolution and after: 0) that now queues the refine with depends_on [model, still].",
- "LOW, pre-flight can't see the Hi3D weights (confirmed: GET /models doesn't list Hi3D, so gather marks the folder folderMissing and filePresence reads the .safetensors as 'missing'). build-requirements.mjs gains UNLISTED_FOLDERS (Hi3D), whose files are 'unobservable'. requirements.json is rebuilt (all 12 Hi3D files unobservable). New test added.",
- "LOW, Powered by Hi3D 1.0 only on Image to 3D's card. CREDITS.md now has the 'Powered by Hi3D 1.0' notice, the Hi3D 1.0 licence row (with the http://hi3d.ai/ link terms) and the Comfyui-Hi3d-T8 pack row, as generated by scripts/credits.mjs. Only these three lines were inserted: the base's CREDITS.md is out of date for other packages, and a full regeneration would pull their rows into this branch."
- ],
- "rejected": [
- "Showing the notice on the Canvas node result as well: not done. The licence (Section 7) accepts an acknowledgements page, and CREDITS.md now covers every surface (Canvas, Assist, MCP). The Image to 3D card keeps its linked notice."
- ],
- "checks": [
- "Worktree /home/user/wt/o-hi3d-refine, branch o/hi3d-refine. Only this package's commits are on it, and claude/fuobe-parity-4 is an ancestor. Three fix commits on top of 527e0a10: 9e8f1e4f (graph and pre-flight), the dependsOn chain commit, and a8a62e3d (credits).",
- "Re-fetched T8mars/Comfyui-Hi3d-T8 at 73848490 into the scratchpad and read it as data only. Confirmed mask alpha = 1 - mask (comfy_nodes.py L58), flash-attn missing from requirements.txt, and 'flash' raising in hi3d_native/runtime.py L45-47. The pack reads models_dir/Hi3D and registers no folder.",
- "Live ComfyUI object_info: RemoveBackground outputs a single MASK, and InvertMask takes and returns a MASK. npm run build -- mesh-refine-hi3d gives 8 nodes; size lookups for three tiny config.json files came back empty this time, so their sizeGb was set back to the previous 0. validate-workflows gives the expected missing_node_type (pack not installed). validation-state.json was rebuilt and object_info.subset.json left at the base's version.",
- "Targeted vitest: hi3d-refine (30 tests), gpu-requirements, comfy-library-4: pass.",
- "pnpm typecheck: exit 0 (after npx next typegen). pnpm lint: exit 0 (3 existing warnings, none in changed files).",
- "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: 5060 passed, 9 failed in 8 files. All 9 are known: comfy-reuse, dop-originals, preset-featured, soul-runs (2) and split-soundtrack are the listed failures that also fail on main. picker-covers, preset-covers and worker-program timed out under load and pass when rerun alone (25, 11 and 12 tests).",
- "No browser recheck: these fixes touch no UI (graph, server chain, requirement index, CREDITS). The reviewer's browser pass at 1440 and 390 px, light and dark, still holds. .next deleted and git status clean."
- ],
- "finalSummary": "All five review findings are fixed with tests. Open engine (your ComfyUI with HI3D=1): Image to 3D's 'Refine detail · Hi3D 1.0' (512/1024/1536), 'Refine this mesh', the Canvas 3D node's refine control and Assist/MCP mesh_resolution all queue coarse model -> Hi3D refine. The refine now also runs when the photo comes from an earlier Canvas or Assist step. The graph hands Hi3D the right mask and uses SDPA attention, so an install made with Fuobe's own steps can run it. All of this is built and checked by tests and in demo mode, but not run on a GPU: no GPU here. Print-ready STL/3MF export runs in the browser and is verified by tests. Cloud engine: no Hi3D route (nobody hosts the open model). The UI says it runs on your GPU, and 'Paid APIs only' hides it. GPU pre-flight: the 'Image to 3D, refined' row lists the pack and treats the Hi3D weights as unobservable, so they no longer read as missing. Public sign-up: guests browse only. Accounts are refused with own-gpu-tool like every 3D model, and the UI hides refine from visitors. Licence: Hi3D Open License 1.0 is recorded as 'conditions' with its switch in Models & licences, 'Powered by Hi3D 1.0' links to http://hi3d.ai/ on the result card, and CREDITS.md now carries the notice, licence row and pack row.",
- "left": [
- "Run on an Ampere-or-newer NVIDIA GPU with HI3D=1: node scripts/comfy/validate-workflows.mjs mesh-refine-hi3d, then a real Pixal3D -> Hi3D chain. Check that the InvertMask'd mask frames the subject, and confirm VRAM at 1536 (vramGb 24 is an estimate).",
- "'Texture it' needs an owner step (a mesh-fit node or a Hunyuan3D-Paint 2.1 pack); the refined mesh ships as geometry only.",
- "scripts/credits.mjs fails on the base with ERR_IMPORT_ATTRIBUTE_MISSING (a JSON import without the type: json attribute), and the base's CREDITS.md is out of date for other packages. Only the Hi3D lines were added here. A full regeneration belongs to the integrator.",
- "tests/comfy-library-4.test.ts unvalidated list includes 'mesh-refine-hi3d' (the allowed edit, from the impl stage).",
- "From text gets 'Refine this mesh' on its card rather than the switch (unchanged from impl)."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/hi3d-refine"
- ],
- "notMerged": [],
- "conflicts": "none",
- "checks": "pair (dbs-d8, hi3d-refine): typecheck 0, lint 0, vitest 5447 passed, 6 failed (main known)",
- "pushed": true,
- "head": "11e187bf"
- }
-}
diff --git a/docs/handoff/reports/idol-2.json b/docs/handoff/reports/idol-2.json
deleted file mode 100644
index 0d5aad0a..00000000
--- a/docs/handoff/reports/idol-2.json
+++ /dev/null
@@ -1,139 +0,0 @@
-{
- "key": "idol-2",
- "impl": {
- "branch": "o/idol-2 (worktree /home/user/wt/o-idol-2; 3 commits on claude/fuobe-parity-4 @ f5b4776b, pushed to origin/o/idol-2)",
- "summary": "Idol 3D can now save cleaned splat files and use Idol's own crop through the ComfyUI-Idol pack (Nynxz, pinned at 4d3a4f67, Apache-2.0). The pack is pinned in CUSTOM_NODE_REPOS, PACK_CLASSES, install-comfyui.sh NODES, packs.json and requirements.json, and it has a NODE_PACKS licence row. A new graph, image-to-splat-idol-clean, does three things: IdolPreprocessImage replaces TripoSplatPreprocessImage and the core photo crop (cropMode synthetic or real, using Fuobe's cut-out mask); IdolPruneSplat after the decoder feeds both the saved file and the orbit video; and IdolCamera with a 1-frame RenderSplat saves the input-view still, which becomes the card's poster. A PreviewAny reports how many Gaussians were kept. The provider asks GET /object_info/IdolPruneSplat on that worker. The answer is cached for a minute per address. If the server can't be reached, nothing is cached. The cache is cleared when /prompt refuses the clean graph. When the class is there and the pack isn't switched off in Settings → Models & licences, the clean graph runs. Otherwise idol-1's core graph runs, unchanged, and its splat is marked meta.pruned false. 'It's a photo' maps to cropMode real. A new Advanced → 'Trim spikes' switch (open engine only) sends maxScale 0.05. The result card shows 'Cleaned: N Gaussians kept'. Only the owner sees 'Not cleaned: install ComfyUI-Idol…'. Verified: unit tests, the build, and the browser. Not verified here: a /prompt check of the clean graph with the pack installed, which is the owner's step. No splat was run (no GPU, no weights).",
- "built": [
- "scripts/comfy/hand-built/image-to-splat-idol-clean.json: a copy of image-to-splat-idol. 88:2 and 88:101-104 are removed. New nodes: 88:110 IdolPreprocessImage {image [99,0], mode 'synthetic', mask [88:35,0], erode_radius 1, size 1024}; 88:111 IdolPruneSplat {splat [88:55,0], min_opacity 0.05, max_scale 0}; 88:112 IdolCamera {samples [88:6,0]}; 88:113 RenderSplat (1 frame, 1024, #000000, opacity_threshold 0, from the pruned splat and IdolCamera's camera); 93 SaveImage; 94 PreviewAny {source [88:111,1]}. 88:24 now takes its image from 88:110, and 92 and 75 take the pruned splat. Everything else is identical to idol-1's graph (tested).",
- "library.spec.mjs: CUSTOM_NODE_REPOS 'ComfyUI-Idol' at the pin. PACK_CLASSES /^Idol(PreprocessImage|Camera|PruneSplat)$/. Header comment for the new keys. A spec entry 'image-to-splat-idol-clean' with packs ['ComfyUI-Idol'], idol-1's bindings minus photoCrop plus cropMode (88:110.mode), minOpacity and maxScale (88:111), outputs 51 splat / 42 turntable / 93 image role 'preview' / 94 text role 'report', defaults {spz, cutout true, cropMode synthetic, minOpacity 0.05, maxScale 0}, and idol-1's licence string plus '; ComfyUI-Idol nodes Apache-2.0'. build-library.mjs BINDING_KEYS gains cropMode, minOpacity and maxScale.",
- "Build: npm run build for both Idol ids. The manifest gains only the new entry: same 5 models and sizes, customNodes ComfyUI-Idol, validated false. idol-1's entry is byte-identical. requirements.json lists the workflow with packs {ComfyUI-Idol: 3 classes} and the pack pin. packs.json pins ComfyUI-Idol with registry null and requirementsTxt false (the repository has no requirements.txt, only a pyproject with dependencies []). model-pins.json needed no change (no new files). The validator's object_info.subset.json and validation-state.json rewrites were reverted, as for the other pack entries. scripts/comfy/README.md has a new row.",
- "install-comfyui.sh NODES: [ComfyUI-Idol] at the pin, with the comment the brief asked for (Apache-2.0, no Python dependencies, no model code, 3 AI-assisted commits on 2026-10-30, not in the Comfy Registry, main ComfyUI only, core fallback).",
- "src/lib/licences.ts NODE_PACKS: a ComfyUI-Idol row (Apache-2.0, commercial) after ComfyUI-DBS, with the brief's note.",
- "src/lib/av/model3d.ts: IDOL_WORKFLOWS, IDOL_PACK, IDOL_PACK_CLASS, IDOL_TRIM_SPIKES (0.05). idolExtra(engine, quality, photoCrop, trimSpikes) sends maxScale on the open engine only; fal has no pruning. idolGraphValues(extra, has) maps photoCrop to cropMode real or synthetic for the clean graph, maps cropMode to the photo switch for the core graph, clamps minOpacity and maxScale to 0-1, and drops keys the graph doesn't bind. idolKept() reads the count. idolCleanLine() gives the card's line. Model3dInput.trimSpikes and Model3dView.clean are new.",
- "src/server/providers/comfyui.ts: comfyHasClass(cls, worker, maxAgeMs=60s) uses the same oneAsk and per-address cache as comfyDevice and comfyDbsModels. It returns undefined on someone's computer or when the server can't be reached, and forgetComfyClass() clears the answer. PrepareContext.idolPack is new. prepareWorkflow swaps image-to-splat-idol to -clean when idolPack() returns true and maps the Idol values. In submit, idolPack returns false when Settings switches the ComfyUI-Idol pack off; otherwise it asks /object_info (model-access is imported dynamically to avoid an import cycle). A refused /prompt for the clean graph clears the cached answer. collectOutputs does three new things: the clean graph's PreviewAny count goes on the splat as meta.kept, with pruned true and no separate text output; the core Idol graph's splat gets pruned false; TripoSplat is unchanged.",
- "UI: model3d-studio.tsx IdolSettings has an Advanced disclosure with a labelled 'Trim spikes' Switch and a hint. It appears on the open engine only and is kept in page state. model-card.tsx shows 'Cleaned: N Gaussians kept' for a clean splat, and 'Not cleaned: install ComfyUI-Idol on your ComfyUI for cleaner splat files.' for a core one, the latter to the owner only (useIsOwner). The input-view still becomes the poster through model3dView's existing image fallback.",
- "Research correction: idol-9.md §5.2 and idol-9.json now say that api.comfy.org/nodes/comfyui-idol answers with a different author's pack (PedroMarinhoDev/ComfyUI-Idol 1.0.0, flagged, ComfyUI >= 0.43.0). Nynxz's pack is still not in the Registry, so Fuobe pins its repository by commit."
- ],
- "tests": [
- "New: tests/idol-clean.test.ts, 17 tests. They cover: the spec, PACK_CLASSES, CUSTOM_NODE_REPOS and BINDING_KEYS; the manifest entry (customNodes, models equal to idol-1's, defaults, bindings, outputs); the requirements and packs.json pins; the install-comfyui.sh NODES grep; the NODE_PACKS row and the workflow licence (idol-1's plus the pack's, the DINOv3 notice, the same flags); the graph wiring, with the pack nodes' inputs checked against the inputs the pack declares (idol-9.md §5.1) and every other node equal to idol-1's; the provider picking the clean graph on true and the core graph on false, undefined, a rejection or no ctx; the photoCrop -> cropMode, Trim spikes -> max_scale and clamping mappings; idolGraphValues; comfyHasClass against a stand-in HTTP ComfyUI (cache, forget, maxAge); collectOutputs for clean, core and TripoSplat; model3dView.clean and the poster; Trim spikes on the open engine only.",
- "Changed: tests/model3d.test.ts. The Idol collectOutputs expectation now includes pruned:false on the core graph's splat. tests/comfy-library-4.test.ts: added image-to-splat-idol-clean to the unvalidated list, the only edit allowed there.",
- "Targeted runs pass (17 files, 538 tests): idol-clean, idol, model3d, account-idol, comfy-library-4/7/notes, gpu-requirements, licences, model-access(-listings/-studios), comfy-install, comfy-dbs, outputs, canvas, model3d-runner.",
- "tsc --noEmit is clean. pnpm typecheck OOMs at the default heap, so I ran tsc with --max-old-space-size=6144. eslint on the changed files: 0 errors, 1 warning that was already on the base (WAN_NEG_EN).",
- "Full vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2): 6 failed | 5396 passed | 4 skipped. All 6 are the known failures from main: comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack.",
- "ComfyUI (shared CPU server 0.41.0, nothing installed or restarted): npm run build validated both entries' graphs. The build expects the pack classes through PACK_CLASSES. node validate-workflows.mjs image-to-splat-idol-clean --shared answered 'missing_node_type Idol Preprocess Image', as expected without the pack. GET /object_info/IdolPruneSplat on the server returns {}.",
- "Browser (FUOBE_DEMO_MODE=on, pnpm dev -p 3462, Playwright, 1440 light and 390 dark): /image-to-3d?model=oss-idol shows Advanced · edges -> Trim spikes; the switch toggles and the summary reads 'trimming spikes'. ?model=idol-3d has no Advanced and no Trim spikes, but keeps the photo switch. Two seeded splat results show 'Cleaned: 131,072 Gaussians kept' with the input-view poster, and 'Not cleaned: install ComfyUI-Idol…' (the demo viewer is the owner). No horizontal overflow and no console errors. The server was stopped, .next and the data dir deleted, and typegen re-run."
- ],
- "left": [
- "The owner's step: install ComfyUI-Idol at 4d3a4f67 on a ComfyUI and /prompt-check image-to-splat-idol-clean there, then mark it validated. Also compare the core photo crop with IdolPreprocessImage 'real'. Nothing here installed or ran the pack, by the owner's rule.",
- "No real run (no GPU, no Idol weights). The kept count, the pruned file size, the still from IdolCamera and Trim spikes' effect are all unmeasured.",
- "tests/comfy-library-4.test.ts: added 'image-to-splat-idol-clean' to its exact list of unvalidated ids (the allowed edit).",
- "Deviation from the brief: the still's output role is 'preview', not 'poster', and the count's role is 'report'. ManifestOutput's role union and comfy-library-4's ROLES list (a hot file) have no 'poster', and every role must be in that list. model3dView already uses any image output as the poster.",
- "Pack detection on someone's computer (Fuobe tab relay) returns undefined, so those runs use the core graph. Accounts can't run 3D models anyway.",
- "When the pack has gone, a refused /prompt for the clean graph only clears the cache: that one run fails with ComfyUI's missing-node message, and the next run uses the core graph. There is no automatic retry.",
- "Settings → Models & licences: oss-idol's route facts list only the core workflow, so the ComfyUI-Idol pack row counts 0 models. Switching the pack off makes Idol use the core graph instead of turning oss-idol off. This is deliberate, so the fallback keeps working.",
- "TripoSplat has no pruning, as the brief asked: wait for idol-3."
- ],
- "docsNotes": [
- "STATUS / FEATURES: Image to 3D -> Splat -> Idol 3D on your GPU saves a cleaned splat (about half the Gaussians, the near-transparent haze, dropped) and uses Idol's own crop for photos when the ComfyUI has the ComfyUI-Idol nodes. Otherwise it runs the core-node graph as before. Advanced -> Trim spikes (open engine only). The card shows 'Cleaned: N Gaussians kept' and the view the model saw as its poster.",
- "Models & licences / self-hosting: the ComfyUI-Idol pack (Nynxz, Apache-2.0, no Python dependencies) is pinned at 4d3a4f67 in install-comfyui.sh. Do not install 'comfyui-idol' from the Comfy Registry: that id is a different author's flagged pack.",
- "Brief out of date: the line numbers predate main's 10-30 work. CUSTOM_NODE_REPOS ends near L210 and PACK_CLASSES near L235. The ComfyUI-DBS NODE_PACKS row is at ~L494. install-comfyui.sh NODES runs to L51. The 'L776-787 pattern' is comfyDevice / comfyDbsModels / comfyReuseModels at ~L728-850, and the swap happens in prepareWorkflow after resolveWorkflowId. model3dView's poster is at model3d.ts ~L315. The brief's CLOUD RULE 'Idol is not hosted' was already superseded by idol-1: fal hosts speridlabs/idol, but it has no pruning or max_scale field, so Trim spikes stays open-only.",
- "Research corrections: idol-9.md §5.2 and idol-9.json (the Registry id comfyui-idol now belongs to PedroMarinhoDev's pack)."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "low",
- "file": "src/components/model3d/model3d-studio.tsx",
- "line": 171,
- "title": "Trim spikes does nothing when the ComfyUI lacks ComfyUI-Idol, and nothing says so",
- "detail": "The Advanced -> Trim spikes switch appears on the open engine whatever the server has. idolExtra sends maxScale 0.05. When prepareWorkflow falls back to image-to-splat-idol (no pack, the pack switched off in Settings, or a run on someone's computer, where comfyHasClass returns undefined), idolGraphValues drops maxScale because the core graph doesn't bind it. The run goes ahead without trimming while the summary still reads 'trimming spikes'. The owner only learns about it afterwards from the card's 'Not cleaned' line. Traced in src/lib/av/model3d.ts idolGraphValues (the has(k) guard) and prepareWorkflow L1757-1762; the test 'runs the core graph without the pack...' covers the fallback.",
- "verified": "traced",
- "suggestion": "Add a short hint under the switch, such as 'Needs the ComfyUI-Idol nodes on your ComfyUI' (owner only), or hide the switch when the server has said it lacks the class."
- },
- {
- "severity": "low",
- "file": "src/components/model3d/model-card.tsx",
- "line": 132,
- "title": "'Not cleaned: install ComfyUI-Idol' also shows when the pack is installed but was not used",
- "detail": "collectOutputs marks every core-graph splat pruned:false. The core graph also runs when the owner switched ComfyUI-Idol off in Settings -> Models & licences, and when the run went through the Fuobe tab relay (computerScope -> comfyHasClass undefined). In both cases the owner is told to install a pack they already have. This is owner-only status text, so no visitor rule is broken.",
- "verified": "traced",
- "suggestion": "Word it so it fits every case ('Not cleaned: this run used the core nodes; ComfyUI-Idol makes cleaner files'), or record why on meta (no-pack, switched-off, computer)."
- },
- {
- "severity": "low",
- "file": "src/server/providers/comfyui.ts",
- "line": 2346,
- "title": "The submit-time wiring of idolPack has no test",
- "detail": "tests/idol-clean.test.ts injects idolPack straight into prepareWorkflow and tests comfyHasClass on its own. Nothing tests the submit closure: Settings pack-off returns false before /object_info is asked, and a refused /prompt for the clean graph calls forgetComfyClass. Both are short and read correctly, but a regression there would go unnoticed.",
- "verified": "read tests/idol-clean.test.ts (L61, L177-245)",
- "suggestion": "Add one comfyProvider.submit test with a stand-in ComfyUI. Pack switched off: assert the core graph is posted and no /object_info request is made. /prompt answers 400: assert the next comfyHasClass asks again."
- },
- {
- "severity": "nit",
- "file": "src/components/model3d/model3d-studio.tsx",
- "line": 174,
- "title": "With the switch off, the Advanced summary reads 'Advanced · edges'",
- "detail": "With Trim spikes off, the disclosure summary is 'Advanced · edges', which doesn't tell the reader anything. 'Advanced' alone, or '· spikes kept', would read better.",
- "verified": "read",
- "suggestion": "Show the state only when the switch is on."
- }
- ],
- "checks": [
- "Read the diff claude/fuobe-parity-4...o/idol-2 (19 files, 3 commits). The branch is on the base tip f5b4776b and origin/o/idol-2 = 2651353d. The worktree is clean.",
- "Hand-built graphs compared node by node: the clean graph removes 88:2 and 88:101-104 and adds 88:110-113, 93 and 94. 88:24, 92 and 75 are rewired to 88:110 / 88:111. Everything else is identical to image-to-splat-idol.json. The inputs match idol-9.md §5.1: IdolPreprocessImage mode / mask / erode_radius / size; IdolPruneSplat min_opacity / max_scale and count at output 1; IdolCamera samples -> LOAD3D_CAMERA.",
- "Live CPU ComfyUI (read only): PreviewAny's input is 'source' (output_node true). RenderSplat takes an optional camera_info of type LOAD3D_CAMERA, and frames 1 gives a still. GET /object_info/IdolPruneSplat returns {}, which confirms comfyHasClass's 'absent' case.",
- "Manifest: the bindings of image-to-splat-idol-clean match the spec (cropMode 88:110.mode, minOpacity / maxScale 88:111, filenamePrefix 51/42/93). Its defaults and outputs (splat / turntable / preview / report) are right. idol-1's entry is unchanged. requirements.json and packs.json pin ComfyUI-Idol at 4d3a4f67 with the 3 classes. The NODE_PACKS row is present (Apache-2.0, commercial), and the workflow licence adds the pack.",
- "Provider: the swap happens before the manifest loads. meta.workflowId = manifest.id, so poll's collectOutputs gets the clean manifest: kept and pruned go on the splat, the report text is not a file, and the still becomes the poster through model3dView. prepareWorkflow has a single caller (submit). fal: idolExtra sends no maxScale, and the cloud card shows no clean line. A client can only send cropMode real or synthetic, and minOpacity / maxScale are clamped to 0-1.",
- "Public sign-up: no new route or file-reading path. 3D is still closed to accounts (own-gpu-tool). The owner-only 'Not cleaned' line is gated by useIsOwner. Visitors see only 'Cleaned: N Gaussians kept'. No Higgsfield code, media or API in the diff; the research doc's mentions predate this branch. Hot files: only tests/comfy-library-4.test.ts, with the allowed edit (the id added to the unvalidated list).",
- "bash -n scripts/comfy/install-comfyui.sh: OK.",
- "Targeted Vitest (idol-clean, idol, model3d, comfy-library-4, licences, gpu-requirements, account-idol, comfy-install): 8 files, 165 tests, all pass.",
- "eslint on the changed src and test files: clean. tsc --noEmit (6 GB heap): exit 0.",
- "No dev server started, no packs installed and ComfyUI not restarted. I left the worktree's existing .next in place, since this review didn't create it."
- ],
- "verdict": "pass: no correctness, security or sign-up-rule problems found. The clean graph's wiring, the fallback to idol-1's graph, the licence data and the pins all check out. The four findings are low or nit (UX copy and one test gap) and can be fixed later."
- },
- "fix": {
- "applied": [
- "Merged origin/claude/fuobe-parity-4 (23bfafd5, o12-training-kit) into o/idol-2 with no conflicts; merge commit amended to carry the trailer; build-requirements.mjs re-run with no diff.",
- "Review finding 1 (low, confirmed): Trim spikes did nothing on a ComfyUI without the pack and nothing said so. IdolSettings now shows the owner only (useIsOwner) the line 'Needs the ComfyUI-Idol nodes on your ComfyUI; without them the file is saved untrimmed.' Visitors see the plain product hint only.",
- "Review finding 2 (low, confirmed): the owner-only card line said 'install ComfyUI-Idol' even when the pack was switched off in Settings or the run went through the tab relay. It now reads 'Not cleaned: this run used the core nodes. With ComfyUI-Idol installed and switched on, splat files come out cleaner.', which is true in every case.",
- "Review finding 3 (low, confirmed): added two comfyProvider.submit tests in tests/idol-clean.test.ts against the stand-in ComfyUI, which now also takes or refuses POST /prompt. (a) With ComfyUI-Idol switched off via changeAccess, the core graph is posted and /object_info is never asked. (b) With the pack there, the clean graph is posted with max_scale 0.05. A 400 from /prompt for the clean graph drops the cached answer, so the next run asks again and falls back to the core graph.",
- "Review finding 4 (nit, confirmed): the Advanced summary now reads 'Advanced' alone when the switch is off and 'Advanced · trimming spikes' when it is on (it used to say '· edges').",
- "Commit 31ee72e0 'Image to 3D: Trim spikes says what it needs on your ComfyUI, and the uncleaned card line fits every case'."
- ],
- "rejected": [],
- "checks": {
- "typegen": "npx next typegen: exit 0",
- "typecheck": "NODE_OPTIONS=--max-old-space-size=6144 pnpm typecheck: exit 0",
- "lint": "pnpm lint: exit 0 (0 errors, 5 warnings, none from this package's changes)",
- "vitestTargeted": "tests/idol-clean.test.ts: 19/19 pass",
- "vitestFull": "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 1. Test files: 5 failed, 337 passed (342). Tests: 6 failed, 5417 passed, 4 skipped (5427). All 6 failures are the known ones in RULES item 8: comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack. A first attempt at this run was killed by the background time limit before it finished. It was restarted, and that is the one complete run reported here.",
- "browser": "None in this stage. The copy changes are owner-only text and a summary tweak, and the card is unchanged otherwise. .next was deleted.",
- "gitStatus": "clean",
- "pushedSha": "31ee72e0c5ebe84660e505a7488425244c1d0757 (origin/o/idol-2)",
- "finalMerge": "Merged origin/claude/fuobe-parity-4 at 11e187bf (conflicts in model3d-studio.tsx kept both sides: Refine option and Idol settings with Trim spikes; manifest.json generatedAt only; requirements.json taken from the base and regenerated), then at 03e49f2d (no conflicts, requirements.json regenerated with no diff). After the last merge: typegen 0, typecheck 0, lint 0; full vitest 7 failed | 5494 passed | 4 skipped. Six are the known failures from main (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack). preset-covers timed out under load and passes alone (11/11)."
- },
- "finalSummary": "Idol 3D on the open engine (your ComfyUI) runs image-to-splat-idol-clean when the server reports IdolPruneSplat and the ComfyUI-Idol pack is not switched off in Settings → Models & licences. That gives Idol's own crop (synthetic, or real for 'It's a photo'), a pruned splat, an input-view poster and a 'Cleaned: N Gaussians kept' line. Otherwise idol-1's core graph runs unchanged, and the owner sees a 'Not cleaned' hint. Advanced → Trim spikes (max_scale 0.05) is open-engine only. The owner is now told it needs the pack. Cloud engine: fal's speridlabs/idol is unchanged, with no pruning and no Trim spikes. Verified: unit tests, including the new submit-path tests (Settings off, cache dropped on a refused /prompt), plus typecheck and lint. Built but not verified: the clean graph with the pack installed (/prompt check), the kept count, the trimming effect and the still. These need a GPU, Idol weights and ComfyUI-Idol at 4d3a4f67, which is the owner's step. No keys are needed. Public sign-up: guests browse the studio read-only and see only plain copy. Accounts still can't run any 3D model (403 own-gpu-tool). The pack hints are owner-only, and no new route or file-reading path was added.",
- "left": [
- "Owner step: install ComfyUI-Idol at 4d3a4f67 on a GPU ComfyUI, /prompt-check image-to-splat-idol-clean and mark it validated. Compare the core photo crop with IdolPreprocessImage 'real'.",
- "No real splat run. The kept count, the pruned file size, the IdolCamera still and Trim spikes' effect are unmeasured.",
- "tests/comfy-library-4.test.ts: image-to-splat-idol-clean was added to its exact unvalidated list (the allowed hot-file edit, from the implement stage).",
- "When the pack disappears after being cached, that one run fails with ComfyUI's missing-node message, and the next run uses the core graph. There is no automatic retry.",
- "Runs through the Fuobe tab relay always use the core graph, because pack detection there returns undefined.",
- "Output roles are 'preview' and 'report', not 'poster', because ManifestOutput has no 'poster' role. model3dView already uses the image as the poster."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/idol-2"
- ],
- "notMerged": [],
- "conflicts": "install-comfyui.sh and library.spec.mjs (both kept), model3d-studio.tsx (Idol settings + Make it 3D hint); requirements regenerated",
- "checks": "batch of 7 (dbs-d7, idol-5, idol-2, idol-6, n7-9, kandinsky6, n7-10): typecheck 0, lint 0, vitest 5788 passed, 6 failed (main known); each merge checked by an independent verifier; n7-10 + Pika Flex interaction fixed in 64900624",
- "pushed": true,
- "head": "64900624"
- }
-}
diff --git a/docs/handoff/reports/idol-3.json b/docs/handoff/reports/idol-3.json
deleted file mode 100644
index bec67390..00000000
--- a/docs/handoff/reports/idol-3.json
+++ /dev/null
@@ -1,125 +0,0 @@
-{
- "key": "idol-3",
- "impl": {
- "branch": "o/idol-3",
- "summary": "The evaluation harness has a splat suite (scripts/eval/cases/splat.json, kind video) that compares Idol 3D Best and Quick against TripoSplat as it ships, plus Idol with the photo crop on the 3 photo cases. It scores the orbit video with DINOv2 style against the input picture, temporal and aesthetic, and adds an optional cheap 'splat' metric that reads the .spz or .ply for the share of Gaussians under opacity 0.05 (haze). A fal TripoSplat reference variant, labelled TripoSplat and cloud-only, is included. The harness gained variant 'tags' (run only on tagged cases) and the suite default 'styleModel' (kept in run.json and used when --style-model isn't given). docs/research/idol-9.md has a 'Results (pending a GPU run)' section with the commands, what each number decides and an empty results table. §3 and §7.2 are untouched, and no default (MODELS_3D.splat.open, IDOL_PRESETS) was changed.",
- "built": [
- "scripts/eval/cases/splat.json: 11 cases (bottle, sneaker, headphones renders; mug, handbag, figurine photos tagged photo; stylised character; person; chair; plant; glass-chrome), 3 seeds, inputs local/splat/*, demoInputs from fixtures/, references = the input picture. Variants: idol-best (candidate; 50 euler cfg 4 262144), idol-quick (20 dpmpp_2m cfg 4 65536), triposplat-today (graph defaults), idol-photo-crop (best + photoCrop true + cropMode real, tags photo), triposplat-cloud (fal triposplat, cloud only). defaults.styleModel dinov2; 'decides' field holds the three rules.",
- "scripts/eval/lib/schema.mjs: METRICS gains 'splat'; Variant.tags (refused when no case carries the tag); defaults.styleModel (clip|dinov2). case.schema.json regenerated by gen-cases.mjs (no other generated file changed).",
- "scripts/eval/lib/plan.mjs: a variant with tags skips cases without them, and says so in the skip reason. run.mjs writes styleModel into run.json; eval.mjs scoring uses --style-model, else run.json's styleModel.",
- "scripts/eval/metrics/fuobe_metrics/splat.py (numpy only): opacities from .spz v1-3 and binary 3DGS .ply, detected by content; haze share and count. score.py: m_splat family, 3D files counted in the fingerprint, and a 'preview' still beside a clip is no longer scored (Idol's clean graph renders the input view, which would inflate style). registry.py and metric-info.mjs: haze (lower is better, tie 0.01) and gaussians.",
- "scripts/eval/README.md: suites table row, local/splat inputs, variant tags and defaults.styleModel, the splat metric row, and a 'The splat suite' section with the commands.",
- "docs/research/idol-9.md: 'Results (pending a GPU run)' section before §10."
- ],
- "tests": {
- "verified": [
- "pnpm eval:validate: all suites pass, splat.json has 11 cases",
- "Demo dry run (pnpm eval:run --suite splat --engine demo --dry-run): 33 jobs for the default variant. With --variants all: 66 jobs per seed, with the photo crop skipped on the 8 non-photo cases and the cloud variant skipped on demo",
- "Demo run, --variants all --seeds 1001, on a fresh demo server: 36/36 succeeded, 19 skipped as intended",
- "Scoring a demo run with a numpy-only venv: run.json's styleModel reaches the scorer (config.style = dinov2), and the splat metric notes that the demo GLB isn't a splat. DINOv2, CLIP and aesthetic didn't run here because uv can't resolve torch==2.14.1+cpu in this container, which affects every suite",
- "pytest scripts/eval/metrics/tests: 47 passed, 5 skipped (new tests/test_splat.py: 7 tests)",
- "tests/eval-harness.test.ts: 46 passed, including a new splat-suite test (demo run, run.json candidate and styleModel, per-variant extras matching IDOL_PRESETS, photo-only skip, cloud has no Idol, tags refused when no case has them)",
- "tests/demo-ops, model3d, eval-api, eval-metrics, idol, idol-clean, licences, comfy-library-notes: pass",
- "pnpm typecheck clean (after next typegen); eslint on the changed files clean",
- "Full vitest (--maxWorkers=2): 7 failures in 6 files, all known from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack, and preset-covers, which timed out under load and passes alone (11/11)",
- "Browser: tests/e2e/idol-final.mjs on a fresh demo server: desktop and phone, light and dark, all good. The final branch changes no page; .next was deleted afterwards"
- ],
- "notVerified": "There are no GPU numbers, since this machine has no GPU and no weights. No style, temporal or aesthetic scores either, because torch doesn't install through uv here. Nothing ran on the cloud."
- },
- "left": [
- "TripoSplat at Idol's sampler (the brief's 'triposplat-50'): skipped as the brief allows. Binding 'sampler' on image-to-splat-triposplat was built and /prompt-validated on the live CPU ComfyUI (only a binding, manifest diff clean). It was reverted because tests/comfy-library-4.test.ts, a hot file, pins that workflow's exact binding list, and adding to it isn't an allowed edit. To add it: the sampler binding in library.spec.mjs, rebuild and validate image-to-splat-triposplat, add 'sampler' to that test's expected bindings, then a 'triposplat-50' variant (oss-triposplat, extra {steps 50, sampler euler, cfg 4, numGaussians 262144}). The Results section says to run it before Idol goes first.",
- "The GPU run itself, on an 8-16 GB GPU with both models' weights and the metrics venv with torch plus DINOv2 (pnpm eval:setup --download --dinov2). Commands are in idol-9.md Results and the eval README. Record the GPU, driver and ComfyUI version with --label and in the results table.",
- "Defaults change (MODELS_3D.splat.open order, IDOL_PRESETS.quick, photo-crop default) only after that run, in a separate commit a person reviews.",
- "Demo runs give the splat as a GLB alone: the mock's open splat has no orbit video, so a demo run has no review pairs or scores. I tried adding a demo orbit and reverted it, because it changed Image to 3D's demo cards and broke tests/e2e/idol-final.mjs.",
- "Not re-checked at the primary source: fal TripoSplat's ~$0.05 per job is the catalog's figure. The harness prices each cloud job on the server before it runs."
- ],
- "docsNotes": [
- "docs/STATUS.md and ARCHITECTURE.md were not edited. For the docs pass: the evaluation harness has a 'splat' suite (Idol 3D vs TripoSplat; decides Splat mode's open default, Idol's Quick look and the photo crop) and a 'splat' metric (haze share in .spz/.ply). Results are pending a GPU run.",
- "The harness case format gained variant 'tags' and suite 'defaults.styleModel' (documented in scripts/eval/README.md).",
- "Brief out of date: review.mjs and covers.mjs pick the main output at L28 and L216 (mainOutput), not L19 and L66. idol-2 is merged, so photoCrop maps to cropMode real on the clean graph through idolGraphValues. The clean graph's preview still is now excluded from scoring. The clean graph prunes the saved file at 0.05, so Idol's haze is near 0 where the pack is installed (said in the docs)."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "low",
- "category": "decision-rule",
- "file": "scripts/eval/cases/splat.json",
- "line": 8,
- "summary": "Rule (1) in `decides` (repeated in docs/research/idol-9.md Results, item 1) asks for 'at least 6 [blind ratings] per case' for idol-best against triposplat-today. With 3 seeds, the review page offers only 3 such pairs per case.",
- "failure_scenario": "buildPairs (scripts/eval/lib/review.mjs L62-75) pairs the candidate with each alternative once per key (case and seed). With seeds [1001, 2002, 3003], one reviewer gets 3 idol-best vs triposplat-today pairs per case, so the rule's '6 per case' can't be met unless a second person rates or the 6 counts every alternative (the promote rule's reading: Quick and the photo crop as well). The rule as written is ambiguous or can't be met for one reviewer. Suggested fix: say '6 per case across the alternatives (every pair offered)', or ask for two reviewers."
- },
- {
- "severity": "low",
- "category": "docs",
- "file": "docs/research/idol-9.md",
- "line": 372,
- "summary": "The command list includes `pnpm eval:promote latest`. That judges idol-best against every alternative (idol-quick and idol-photo-crop too), so its per-case verdict is not decision (1) in `decides`.",
- "failure_scenario": "promote() (scripts/eval/lib/compare.mjs L187) uses every other variant when --against isn't given. A case where idol-photo-crop beats idol-best on style is put 'on hold' even if Idol beats TripoSplat there, and someone reading that output as the Splat-default verdict would decide wrongly. `pnpm eval:promote latest --against triposplat-today` is the command that matches rule (1). Docs only; no code is affected."
- },
- {
- "severity": "info",
- "category": "not-verified",
- "file": "scripts/eval/cases/splat.json",
- "line": 177,
- "summary": "The triposplat-cloud variant hasn't been run (no fal key here), and fal's ~$0.05 per job is the catalog's figure, not re-checked at the source. At 33 jobs that is about $1.65, under DEFAULT_CLOUD_CAP of $5.",
- "failure_scenario": "None seen. The request has no `op`, but inferOperation (src/lib/catalog/plan.ts L37-76) falls through to routes[0].op = 'splat'. The fal .ply comes back as kind model3d, and splat.py reads it by its content."
- }
- ],
- "checks": [
- "Read the prompt, the binding rules and the implementer's report. Branch origin/o/idol-3 = 335acf19, worktree clean, base claude/fuobe-parity-4 is an ancestor. Diff: 14 files, all under scripts/eval, tests/eval-harness.test.ts and docs/research/idol-9.md. No src/, route, page, workflow, hot file, licence or migration change, so the public sign-up, tenant/account-inputs, pre-flight and ASSET_REFS rules don't apply.",
- "§3 and §7.2 of idol-9.md are unchanged (only a new section was added). IDOL_PRESETS and MODELS_3D are unchanged. Commit messages are neutral 'Area: result'.",
- "Variants against the manifest: image-to-splat-idol binds steps/cfg/sampler/numGaussians/photoCrop. The clean graph binds cropMode/minOpacity/maxScale. image-to-splat-triposplat binds steps and cfg but not sampler, so skipping triposplat-50 is what the brief allows. idolGraphValues and the comfy provider (L1873-1877) map photoCrop and cropMode correctly on both graphs. Without photoCrop, the core switch 88:104 defaults to false and the clean graph's crop to synthetic, so idol-best is a clean no-crop baseline.",
- "The plan matches what was asked: open and demo expand idol-best/quick/photo-crop to oss-idol with the IDOL_PRESETS extras and triposplat-today to oss-triposplat with no extra. Photo-crop is skipped on cases without the photo tag. On cloud only triposplat-cloud runs, as 'triposplat'; the Idol variants are skipped (no Idol on the cloud).",
- "media_outputs now drops a preview still that sits beside a clip. Of all the manifest graphs, only image-to-splat-idol-clean outputs an image preview next to a video, and no src/ code emits role 'preview', so other suites are unaffected. The review/covers mainOutput still picks the turntable (manifest output order: splat, turntable, preview).",
- "splat.py checked against ComfyUI's own writers: I fed _gaussian_spz_bytes and _gaussian_ply_bytes (from /home/user/ComfyUI/comfy_extras/nodes_gaussian_splat.py, CPU torch) 1000 random Gaussians. Read back: spz haze 0.052 and ply 0.054, true value 0.054. The small gap is the 8-bit alpha quantisation near 0.05. Its parser layout matches ComfyUI's _parse_spz_gaussian and _parse_ply_gaussian.",
- "eval.mjs: --style-model has no parseArgs default, so run.json's styleModel is actually used.",
- "pnpm eval:validate: all suites pass (splat.json: 11 cases). node scripts/eval/gen-cases.mjs --check: generated files current.",
- "pytest scripts/eval/metrics/tests (numpy + pillow venv): 47 passed, 5 skipped.",
- "Targeted vitest: tests/eval-harness, eval-metrics, eval-api, model3d, idol: 5 files, 111 tests passed. Full vitest not rerun: the change is harness and docs only, and the implementer reported the full run with only known failures.",
- "npx next typegen, then tsc --noEmit (8 GB heap; pnpm typecheck OOMed at the default heap): clean. eslint on the changed .mjs files and the test: clean.",
- "No browser check (no page changed), so there was no .next to delete."
- ],
- "verdict": "approve: the suite, schema additions, plan tags, styleModel plumbing and splat metric are correct and well tested; only low-severity wording issues in the decision rules/docs remain"
- },
- "fix": {
- "applied": [
- "Review finding 1 (low, decision rule), confirmed: buildPairs pairs idol-best with each alternative once per case and seed, so at 3 seeds one reviewer gets only 3 idol-best vs triposplat-today pairs per case and the rule's '6 per case' could not be met. The rule in scripts/eval/cases/splat.json (decides) and in docs/research/idol-9.md (Results table and decision 1) now reads 'at least 6 per case, or every such pair the review offered when it offered fewer (3 per case for one reviewer at 3 seeds)', which is what promote() already applies (want = min(minRatings, offered)).",
- "Review finding 2 (low, docs), confirmed: promote() without --against weighs every other variant (idol-quick, idol-photo-crop too). The idol-9.md command list now has 'pnpm eval:promote latest --against triposplat-today' (decision 1 only) and decision 1 says why; scripts/eval/README.md 'The splat suite' commands gained the same line. Commit a31422da, pushed to origin/o/idol-3."
- ],
- "rejected": [
- "Review finding 3 (info, not verified: triposplat-cloud unrun, fal price is the catalog's figure): nothing to fix here; no fal key on this machine. Kept in 'left'."
- ],
- "checks": [
- "Worktree /home/user/wt/o-idol-3 on o/idol-3: only this package's 3 commits on top of claude/fuobe-parity-4, base is an ancestor, tree clean at start. Base not merged (per instructions).",
- "pnpm install --frozen-lockfile --prefer-offline: ok; npx next typegen: ok.",
- "pnpm eval:validate: all suites pass (splat.json 11 cases). node scripts/eval/gen-cases.mjs --check: generated files current.",
- "Targeted vitest tests/eval-harness.test.ts + tests/eval-metrics.test.ts: 47/47 passed.",
- "pnpm typecheck (after typegen, 8 GB heap): exit 0.",
- "pnpm lint: exit 0 (0 errors, 5 pre-existing warnings).",
- "Full vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): the run was killed before finishing (the background job ended as [killed]), so it gives no full count. Before it stopped, the only failures were the known ones from main: soul-runs (2), dop-originals, preset-featured, comfy-reuse, split-soundtrack. Not rerun (one full run allowed). The fix changes only docs and one JSON string, which eval:validate and the eval-harness test cover. The implementer's full run showed only known failures.",
- "No browser check (no page changed). .next (typegen types only) deleted; git status clean.",
- "Finish: base claude/fuobe-parity-4 unchanged since the branch was cut (already up to date). npx next typegen, pnpm typecheck (8 GB heap) and pnpm lint exit 0. Full vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 5788 passed, 6 failed, 4 skipped; the failures are only the known ones from main (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack)."
- ],
- "finalSummary": "idol-3 adds a 'splat' evaluation suite: Idol 3D Best and Quick against TripoSplat as it ships, plus Idol with the photo crop on the 3 photo cases. It scores the orbit video on DINOv2 style against the input picture, temporal and aesthetic, and adds a numpy 'splat' haze metric read from the .spz or .ply. There is also a cloud-only fal TripoSplat reference variant labelled TripoSplat. This fix makes the decision rules ask for blind ratings one reviewer can actually give, and names the promote command that checks decision 1 (--against triposplat-today). Open engine: built and checked by schema validation, a demo dry run, a demo run and pytest. Real numbers need an 8-16 GB GPU with both models' weights and the metrics venv with torch and DINOv2. Cloud engine: only the triposplat-cloud reference variant (fal's hosted TripoSplat; no Idol on the cloud because it isn't hosted). It is priced under the harness spend cap and has not run because there's no fal key here. Demo: the suite runs end to end, but demo numbers decide nothing. Public sign-up: unaffected. This is a developer harness under scripts/eval plus docs, with no route, page or run path, so guests and accounts see nothing new. Accounts still can't start any 3D model (own-gpu-tool). No defaults changed (MODELS_3D.splat.open, IDOL_PRESETS), and §3 and §7.2 of idol-9.md are untouched.",
- "left": [
- "The GPU run itself (8-16 GB GPU, both models' weights, pnpm eval:setup --download --dinov2). The commands are in idol-9.md Results and the scripts/eval/README.md splat section. Record the GPU, driver and ComfyUI version.",
- "TripoSplat at Idol's sampler (triposplat-50) was skipped as the brief allows. It needs a 'sampler' binding on image-to-splat-triposplat, and tests/comfy-library-4.test.ts pins that binding list (a hot file).",
- "Default changes (MODELS_3D.splat.open order, IDOL_PRESETS.quick, the photo-crop default) come only after that run, in a separate commit a person reviews.",
- "triposplat-cloud is unrun (no fal key). Its ~$0.05/job is the catalog's figure and hasn't been checked at fal's own pricing.",
- "Demo runs have no orbit video for the open splat, so they produce no review pairs or scores."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/idol-3"
- ],
- "notMerged": [],
- "conflicts": "scripts/eval/README.md suite rows (mesh and splat); follow-up fb8e099e",
- "checks": "batch of 3 (idol-8, idol-3, nm10-hy-nomas-world): typecheck 0, lint 0, vitest 5972 passed, 6 failed (main known); idol-8 and hy-nomas each checked by an independent verifier; idol-3 merged by hand (README rows) with follow-up fb8e099e (demo splat now comes with idol-4's turntable)",
- "pushed": true,
- "head": "b97c9762"
- }
-}
diff --git a/docs/handoff/reports/idol-4.json b/docs/handoff/reports/idol-4.json
deleted file mode 100644
index 06b28695..00000000
--- a/docs/handoff/reports/idol-4.json
+++ /dev/null
@@ -1,148 +0,0 @@
-{
- "key": "idol-4",
- "impl": {
- "branch": "o/idol-4 (worktree /home/user/wt/o-idol-4, cut from claude/fuobe-parity-4 at 03e49f2d; 2 commits, cd7af656 and cff844dd, pushed to origin/o/idol-4; commits SSH-signed)",
- "summary": "People can now look around Gaussian splats inside Fuobe. They no longer have to download them to SuperSplat. I chose Spark 2.3.1 (@sparkjsdev/spark, MIT, World Labs) as the renderer and load it only through a dynamic import. The new SplatViewer works on result cards ('View in 3D' plus a '3D' choice in the card's radio row). It also works in the full-screen viewer, which the Library's 3D tab and the 'View in 3D' output action both open through ModelViewer and the new SplatPanel. It has drag to orbit, pinch and wheel zoom, keyboard controls, Reset view, Turn it over, a light / grey / dark background, the 'Hide faint haze' opacity cut-off (0.05 for Idol 3D on both engines, 0 for TripoSplat) and 'Save a still', which saves a PNG to Library Uploads (hidden for guests). The orbit video or picture stays as the poster while loading. It is also the fallback when there is no WebGL2, when the file is over the size limit (48 MB on touch screens, 160 MB elsewhere), and in the full-screen viewer under prefers-reduced-motion until the user picks 'Look around in 3D'. The download buttons are kept. Demo mode now returns real splats: an .spz with the orbit video on the open engine and a .ply on the cloud. Nothing existed for this before; the plan's pieces were all gaps. What was already there and reused: splatFormatOf, model3dView's splat field, the storage MIME types for ply/spz/ksplat, and the card's splat radio row.",
- "built": [
- {
- "feature": "src/lib/av/splat-view.ts (pure)",
- "status": "built",
- "verifiedHow": "src/lib/av/splat-view.ts (pure): viewerFor (splat vs GLB), hazeCutoffFor / IDOL_HAZE_CUTOFF 0.05, SPLAT_BACKGROUNDS, SPLAT_MAX_BYTES / splatTooBig, splatFallback (no-webgl2 / too-big / reduced-motion), FALLBACK_TEXT, stillFileName"
- },
- {
- "feature": "src/components/model3d/splat-engine.ts",
- "status": "built",
- "verifiedHow": "src/components/model3d/splat-engine.ts: three.js scene + OrbitControls + Spark SparkRenderer/SplatMesh. Fetches the file itself (abortable, refuses past maxBytes using Content-Length and the streamed byte count), frames the camera to the splat's bounds, applies the haze cut-off as a live dyno objectModifier, has orbit and zoom for keys, reset, flip, and capture (PNG). Draws only on demand, and keeps drawing for a moment after a change so Spark can finish sorting."
- },
- {
- "feature": "src/components/model3d/splat-viewer.tsx",
- "status": "built",
- "verifiedHow": "src/components/model3d/splat-viewer.tsx: the SplatViewer component (role=application with a screen-reader description, arrow keys / + / - / 0 / Home, a labelled toolbar, a background radiogroup, the haze slider in a popover on cards and inline on the panel, Save a still, the poster plus a progress badge while loading, touch events kept from the studio viewer's swipe-to-next, useReducedMotion and hasWebgl2 exported)"
- },
- {
- "feature": "src/components/model3d/model-card.tsx",
- "status": "built",
- "verifiedHow": "src/components/model3d/model-card.tsx: 'View in 3D' and the '3D' radio choice open the splat viewer in place. The 'Fuobe doesn't draw splats yet' note is gone; only a fallback note shows when the viewer can't open. useReducedMotion moved to splat-viewer.tsx. The GLB / model-viewer path is unchanged."
- },
- {
- "feature": "src/components/studio/result-media.tsx",
- "status": "built",
- "verifiedHow": "src/components/studio/result-media.tsx: SplatPanel replaces SplatPreview (the viewer, the download, and the fallback with 'Look around in 3D' under reduced motion)"
- },
- {
- "feature": "src/server/providers/mock.ts",
- "status": "built",
- "verifiedHow": "src/server/providers/mock.ts: a demo splat on the open engine (comfyui route, meta.openSplat) returns sample:demo-splat.spz plus demo-turntable.mp4; on the cloud it returns sample:demo-splat.ply"
- },
- {
- "feature": "scripts/gen-demo-splat.mjs plus public/samples/demo-splat.ply (279 KB) and demo-splat.spz (50 KB)",
- "status": "built",
- "verifiedHow": "scripts/gen-demo-splat.mjs plus public/samples/demo-splat.ply (279 KB) and demo-splat.spz (50 KB): the demo crystal as 4,096 Gaussians, 1,280 of them haze under 0.05. The script is deterministic; --gaussians=N --out=dir writes bigger ones for timing (not committed)."
- },
- {
- "feature": "package.json / pnpm-lock.yaml",
- "status": "built",
- "verifiedHow": "package.json / pnpm-lock.yaml: @sparkjsdev/spark 2.3.1 (exact; published 2026-10-01; 2.4.0 was only 14 days old)"
- },
- {
- "feature": "docs/research/idol-9.md §9 idol-4 (plus notes in §7.1, §10, §11) and idol-9.json splatViewer",
- "status": "built",
- "verifiedHow": "docs/research/idol-9.md §9 idol-4 (plus notes in §7.1, §10, §11) and idol-9.json splatViewer: the renderer decision table and the measured numbers"
- }
- ],
- "tests": "Verified by unit tests (tests/splat-view.test.ts, new): which viewer opens which format; the haze default per model; the fallback rules; size limits at 262,144 and 1,048,576 Gaussians; the still's file name; the fixture's .ply and .spz structure. Spark's own decoder (transcodeSpz, in Node) reads both fixtures as 4,096 Gaussians and keeps the 2,816 solid ones at opacityThreshold 0.05. A source scan checks that only splat-engine.ts imports Spark, and only through import(). tests/demo-ops.test.ts was updated: a cloud demo splat is now a real model/ply. Targeted Vitest run passed (13 files): splat-view, model3d, demo-ops, idol, account-idol, outputs, hi3d-refine, fly-around, licences, canvas, cloud-catalog-4, comfy-library-notes, comfy-library-4. No full suite and no pnpm build, as the stage prompt says. tsc --noEmit is clean (needs NODE_OPTIONS=--max-old-space-size=8192 here; the default heap ran out of memory). eslint is clean on every touched file. Verified in the browser with the new script tests/e2e/splat-viewer.mjs in demo mode (pnpm dev -p 3412, Chromium with SwiftShader WebGL2), at 1440 and 390 px, light and dark; it passed. On the cards it opened open-engine Idol 3D (.spz, haze starts at 5%) and cloud TripoSplat (.ply, haze starts Off), confirmed from a screenshot that the splat is drawn, and checked focus, keyboard, toolbar labels, background radios, the slider, and Save a still (a new upload appears). It opened the Library's 3D tab in the full-screen panel (inline slider, download, splat drawn) and checked that nothing scrolls sideways. Bundle check: /image and the cards fetch no Spark until a splat opens, and a GLB result opens model-viewer without fetching Spark. The detection matches the WASM glue's module name, so it holds for production chunks too. Reduced motion: the panel keeps the orbit video until 'Look around in 3D'. No page errors or console errors were seen. tests/e2e/exact-orbits.mjs still passes (the GLB card path, Film it photoreal) Measured: the 262,144-Gaussian .ply is 17.8 MB and the .spz 2.77 MB. Loading it at 390 px takes 1.6 s. SwiftShader takes about 8 s per frame at that size, which says nothing about a phone's GPU; phone frame time was not measured. The dev server was stopped with fuser -k and .next was deleted",
- "left": [
- "Phone frame time on a real phone with a 262,144-Gaussian splat. There is no device here, and SwiftShader is not a proxy.",
- "Real Idol 3D and TripoSplat outputs (GPU or fal key) were never opened in the viewer. Only the synthetic demo splats were. Orientation is the open question: Idol's .ply is documented y-up, but the orientation of ComfyUI SplatToFile3D's .spz and fal's .ply is unverified. 'Turn it over' is there in case either shows upside down.",
- "The viewer flips to visible as soon as Spark has initialised. On slow (software) GPUs the canvas can stay empty for a moment before the first sorted frame. The e2e waits until the splat is drawn.",
- "Share pages still show splats only as a download (not changed; the viewer could go there later).",
- "Idea, not built: Spark's transcodeSpz takes opacityThreshold. A 'Download without haze' (.spz) button could be built in the browser with no ComfyUI pack. That overlaps idol-2.",
- "Brief out of date. Line numbers: model-card's note was at L324, result-media's panel at L246, splatFormatOf at L281, mock's splat case at L324, and the 'View in 3D' action at output-actions L199. Two other points: 'There is no Idol cloud route' no longer holds, because idol-1 added fal speridlabs/idol (idol-3d), so the 0.05 default covers both engines. And the Library's 3D tab has no viewer of its own: it opens the studio Viewer, so the change in ModelViewer covers it and 'View in 3D'."
- ],
- "docsNotes": "ARCHITECTURE.md line ~148 (mock provider): the sentence 'Splat and rig jobs get the demo GLB too (meta.format glb), so a demo run never shows the splat card' is now wrong for splats. A demo splat is a real .spz with demo-turntable.mp4 on the open engine (meta.openSplat: route op splat on comfyui) and a real .ply on the cloud (scripts/gen-demo-splat.mjs). Rig jobs still get the GLB. ARCHITECTURE.md (Studios → Image to 3D / UI): add the splat viewer. SplatViewer (src/components/model3d/splat-viewer.tsx) loads splat-engine.ts (Spark 2.3.1 on three.js) by dynamic import only. Rules in src/lib/av/splat-view.ts: the haze cut-off starts at 0.05 for Idol 3D and 0 otherwise; the size limit is 48 MB on touch screens and 160 MB elsewhere; the fallback is the orbit video or picture with no WebGL2, over the limit, or under reduced motion in the full-screen viewer. Save a still uploads a PNG to Uploads (hidden for guests). STATUS.md / DEVELOPMENT.md generators list: node scripts/gen-demo-splat.mjs regenerates public/samples/demo-splat.ply and .spz (--gaussians=N --out=dir for timing files). STATUS.md: Image to 3D splat results open in the 3D splat viewer on cards, in the full-screen viewer and in the Library. Phone performance is unmeasured. CREDITS.md 'Elsewhere' could list Spark (@sparkjsdev/spark, MIT, World Labs) if it lists front-end libraries. It doesn't list three or model-viewer today, so I left it alone. Research correction made: docs/research/idol-9.md §9 idol-4 now holds the renderer decision and numbers. §7.1, §10 and §11 have dated notes. idol-9.json has a splatViewer entry."
- },
- "review": {
- "findings": [
- {
- "file": "src/components/studio/result-media.tsx",
- "line": 270,
- "severity": "minor",
- "summary": "The full-screen SplatPanel always passes autoFocus, so keyboard browsing through results (ArrowLeft/ArrowRight in the studio Viewer) stops at every splat. The focused splat stage takes the arrows and calls preventDefault, and the Viewer's window handler ignores events that were already handled (ignoreKey: e.defaultPrevented). The GLB model-viewer path never takes focus, so this is new behaviour.",
- "failureScenario": "In the Library's 3D tab, open a splat and press ArrowRight. Focus is on 'Look around the splat' (role=application), and the key orbits the splat instead of going to the next result. Browsing to another splat grabs focus again. I checked this in demo mode with Chromium/SwiftShader: after ArrowRight the same .ply was still open. Blurring and pressing ArrowRight moved to the next result (the .spz). Fix: drop autoFocus in the panel, or only auto-focus when the panel was opened by 'View in 3D' / 'Look around in 3D'. Another option is to let ArrowLeft/Right through when the stage was focused programmatically and the user hasn't interacted with it yet.",
- "verified": true
- },
- {
- "file": "src/components/model3d/splat-engine.ts",
- "line": 180,
- "severity": "minor",
- "summary": "dispose() calls renderer.dispose() but not renderer.forceContextLoss(). Every card that opens and closes the splat viewer leaves a live WebGL2 context until GC, and nothing handles webglcontextlost.",
- "failureScenario": "On the Image to 3D feed, someone opens '3D' on many splat cards one after another (the canvas is recreated on each toggle). Chrome's limit of about 16 contexts makes it drop the oldest with 'Too many active WebGL contexts', and the viewer that is open can then go blank with no fallback note. I traced this from the code but did not reproduce the exhaustion. Fix: call this.renderer.forceContextLoss() in dispose(), and optionally show the fallback note on webglcontextlost.",
- "verified": false
- },
- {
- "file": "tests/demo-ops.test.ts",
- "line": 212,
- "severity": "minor",
- "summary": "The demo-ops test covers only the cloud demo splat (.ply). The open-engine branch (meta.openSplat: sample:demo-splat.spz plus demo-turntable.mp4, route op splat on comfyui) has no unit test. Only the e2e and a hand-built model3dView object cover it, so a regression in the new mock condition would go unnoticed in CI.",
- "failureScenario": "If someone changes openSplat's condition (route.op / route.provider) or renames the sample, open-engine demo runs go back to a .ply with no orbit video and Vitest stays green. Add a case that runs a demo splat on oss-triposplat / the Idol open graph and asserts model/x-spz, meta.format spz and a turntable video.",
- "verified": true
- },
- {
- "file": "src/components/model3d/splat-viewer.tsx",
- "line": 296,
- "severity": "nit",
- "summary": "'Save a still' is hidden with useIsGuest(), which is false until the viewer query has loaded (`!!v && ...`). A guest who opens a splat before /api/viewer answers sees the button for a moment, and clicking it gives a 401 error toast.",
- "failureScenario": "On a public sign-up install with a slow first viewer fetch, a guest opens a splat on a card and clicks Save a still before the viewer data arrives. The upload is refused with 401 and shows an error toast. Low impact because the server refuses it, but the button could stay hidden until the viewer is known.",
- "verified": true
- },
- {
- "file": "src/lib/av/model3d.ts",
- "line": 257,
- "severity": "nit",
- "summary": "Two doc comments are stale. L257 still says the splat is a format 'which the page doesn't draw', and L279 says 'the demo's \"splat\" is a GLB the viewer shows'. Both stopped being true with this package.",
- "failureScenario": "A later builder reads these comments, believes splats aren't drawn and the demo splat is a GLB, and builds on that.",
- "verified": true
- },
- {
- "file": "docs/ARCHITECTURE.md",
- "line": 148,
- "severity": "nit",
- "summary": "The mock provider's description still says 'Splat and rig jobs get the demo GLB too (meta.format glb), so a demo run never shows the splat card'. The implementer flagged this for the docs stage. It is listed here so it isn't missed.",
- "failureScenario": "The docs describe demo behaviour that no longer matches (a demo splat is now a real .spz with an orbit video on the open engine, or a .ply on the cloud).",
- "verified": true
- }
- ],
- "checks": "Read the review prompt and binding rules, then the whole diff claude/fuobe-parity-4...o/idol-4 (16 files) with the code around it: studio viewer.tsx key and swipe handling, ModelCard choices and radio row, persistOutput's sample: handling, splatFormatOf / model3dView, storage MIME map, the CSP in next.config.ts, useIsGuest, and Cinema's capture for comparison. Verified Spark at npm: 2.3.1 is MIT, published 2026-10-01 (more than two weeks old; 2.4.0 is 2026-10-20), peer three >=0.180.0. The WASM and workers are inlined (data:/blob: workers, no import.meta.url asset), and the CSP sets no script-src or worker-src, so they are not blocked. Spark is imported only by splat-engine.ts through import() from splat-viewer.tsx. The Spark API used (objectModifier, updateGenerator, updateVersion, getBoundingBox) exists in its types. No new route, table, server file path, ComfyUI graph, model or LoRA, so public sign-up, tenant/account-inputs, ASSET_REFS, pre-flight and licence data are not affected. Accounts can't start 3D models, and Save a still is an ordinary own upload through POST /api/uploads. No hot files touched, no Higgsfield code, media or API. The visitor copy is plain. scripts/gen-demo-splat.mjs is deterministic: regenerating byte-for-byte matches the committed .ply (278,942 B) and .spz (49,745 B). npx next typegen plus tsc --noEmit (8 GB heap): clean. eslint on all touched files: clean. Full Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 340/346 files and 5483/5494 tests passed. All 7 failures are known from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack, plus moderation-hook, which timed out under load and passes alone. splat-view, demo-ops, model3d and moderation-hook rerun alone: 66/66 passed. Browser check in demo mode (FUOBE_DEMO_MODE=on, pnpm dev -p 3471, Chromium/SwiftShader): the implementer's tests/e2e/splat-viewer.mjs passed in all 14 steps (1440 and 390 px, light and dark, cards, the Library panel, the bundle check, the GLB path, reduced motion). A separate script confirmed the arrow-key trap in the full-screen viewer. Server stopped with fuser -k, .next deleted, worktree clean. Nothing edited, committed or pushed.",
- "verdict": "Approve with minor fixes. The splat viewer works on cards, in the full-screen viewer and in the Library on both engines' demo outputs. The GLB/model-viewer path, Cinema and turntables are untouched, and typecheck, lint and tests are clean apart from failures already known on main. No blocker or major issue. Worth fixing before merge: the full-screen panel's autoFocus stops arrow-key browsing at every splat (verified in the browser). Cheap hardening: forceContextLoss on dispose, and a unit test for the open-engine demo splat. Stale comments and ARCHITECTURE.md L148 go to the docs stage."
- },
- "fix": {
- "applied": [
- "result-media.tsx:270 (minor, confirmed in the browser): arrow-key browsing no longer stops at every splat. Dropping autoFocus was not enough on its own. The browser check showed the full-screen dialog focuses the stage itself on open, because it is the first tabbable element. So SplatViewer now takes ArrowLeft/ArrowRight only after the user has reached for the stage: tabbed to it, pressed on it, used one of its keys, or opened it on purpose (autoFocus). The panel passes autoFocus={asked}, so it takes focus only after 'Look around in 3D'. ArrowUp/Down, +/-, 0 and Home still work at once. A unit source check was added in tests/splat-view.test.ts. tests/e2e/splat-viewer.mjs now checks that ArrowRight moves to the next result after the panel opens, that it turns the splat once the user presses on it, and that the viewer takes focus after 'Look around in 3D' under reduced motion.",
- "splat-engine.ts:180 (minor, from reading the code): dispose() now calls renderer.forceContextLoss() and removes its listener. The engine also listens for webglcontextlost. If the browser takes the context away while the viewer is showing, SplatViewer shows the fallback note through onUnavailable: the card goes back to its preview and the panel to its fallback. A unit source check was added.",
- "tests/demo-ops.test.ts (minor): new test. An open-engine demo splat on oss-triposplat and on oss-idol (routed to comfyui, so meta.openSplat) returns model/x-spz with format spz and role splat, plus a demo-turntable.mp4 with turntable:true, and the served .spz is gzip.",
- "splat-viewer.tsx:296 (nit): 'Save a still' now shows only after the viewer query has loaded and the viewer is not a guest. It no longer appears for a moment for a guest before /api/auth/me answers.",
- "src/lib/av/model3d.ts L257/L279 (nit): corrected two out-of-date comments. Splats are drawn by the splat viewer, and today's demo splat is a real .spz/.ply; a GLB marked as a splat (older demo results) stays a GLB.",
- "docs/ARCHITECTURE.md L148 (nit): the mock provider sentence now says a demo splat is a real .spz with demo-turntable.mp4 on the open engine and a .ply on the cloud. Rig jobs still get the GLB."
- ],
- "rejected": [],
- "checks": "Worktree case (1). The branch held only idol-4's own commits, and the local claude/fuobe-parity-4 (03e49f2d) is its ancestor, so no merge was needed. origin/claude/fuobe-parity-4 is newer (a150159e) and the integrator will bring that in. Ran pnpm install --frozen-lockfile and npx next typegen. Typecheck (NODE_OPTIONS=--max-old-space-size=8192 pnpm typecheck) exited 0, and was re-run after the last edit. pnpm lint exited 0 (5 old warnings in files this package doesn't touch). eslint on the touched files is clean. Targeted Vitest: demo-ops 5/5, splat-view and model3d 55/55. One full Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 341/346 files and 5487/5497 tests passed, 4 skipped. The 6 failures are all known from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2) and split-soundtrack. Browser: demo mode (FUOBE_DEMO_MODE=on pnpm dev -p 3473, Chromium/SwiftShader), node tests/e2e/splat-viewer.mjs. The first run showed that the dialog focuses the stage on open even without autoFocus. After the fix, all checks passed at 1440 and 390 px, light and dark: cards, the Library panel (ArrowRight browses), the bundle check, the GLB path and reduced motion. No console or page errors. The server was stopped with fuser -k, .next deleted, git status clean. Commit 54249e70 pushed to origin/o/idol-4. After merging origin/claude/fuobe-parity-4 into o/idol-4 (clean, no conflicts): next typegen, typecheck (8 GB heap) and lint exit 0; full Vitest 5624 passed, 7 failed, 4 skipped. All failures are known from main (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack) plus moderation-hook, a load timeout that passes alone (9/9).",
- "finalSummary": "idol-4 is ready for docs and merge. People can look around Gaussian splats on result cards, in the full-screen viewer and in the Library's 3D tab, with Spark 2.3.1 (MIT) loaded only by dynamic import. The fixes in this stage: the arrow keys keep browsing results in the full-screen viewer until the user engages the splat, closed viewers give their WebGL context back and a lost context shows the fallback, 'Save a still' stays hidden until the viewer is known, there is a unit test for the open-engine demo splat, and stale comments and the ARCHITECTURE.md mock sentence are corrected. Open engine (ComfyUI): Idol 3D and TripoSplat .spz results open in the viewer with the orbit video as poster and fallback; haze starts at 0.05 for Idol and Off for TripoSplat. Verified only with the demo .spz; a real run needs a GPU. Cloud: fal's TripoSplat and Idol .ply open in the same viewer, verified only with the demo .ply; a real run needs a fal key. Public sign-up: guests can look around any splat they can see but get no 'Save a still', and the server would refuse it anyway. Accounts can look around and save stills as their own uploads, but they can't start 3D models yet (403 own-gpu-tool, unchanged). No new routes, server file paths or graphs.",
- "left": [
- "Phone frame time on a real phone with a 262,144-Gaussian splat: there is no device here.",
- "Real Idol 3D and TripoSplat outputs (GPU or fal key) were never opened. The orientation of ComfyUI's .spz and fal's .ply is still unverified; 'Turn it over' is there in case either shows upside down.",
- "Exhausting WebGL contexts was not reproduced in the browser. The forceContextLoss fix and the fallback when the context is lost are checked by reading the code and a source test, not by a browser run.",
- "Share pages still offer splats only as a download.",
- "Docs stage: STATUS.md / DEVELOPMENT.md should mention scripts/gen-demo-splat.mjs and the splat viewer, and ARCHITECTURE.md's Image to 3D UI section should mention SplatViewer (see the implementer's docsNotes)."
- ]
- },
- "merge": {
- "merged": [
- "o/idol-4"
- ],
- "notMerged": [],
- "conflicts": "model-card.tsx doc comment and splat note (viewer replaces the old note; Idol clean lines kept); new dependency @sparkjsdev/spark 2.3.1",
- "checks": "batch of 6 (dbs-d9, idol-7, w2s-w5, w2s-w6, w2s-w7, idol-4): typecheck 0, lint 0, vitest 5907 passed, 8 failed (6 main known + preset-covers and reuse-pack-pin load timeouts, 13/13 alone); each merge but idol-4 checked by an independent verifier (idol-4 merged by hand after: one conflict, its tests 99/99); W5/W6/W7 joined by follow-ups 642a167e, bef8778e, 22378b4b, 739a0c1d",
- "pushed": true,
- "head": "148f2459"
- }
-}
diff --git a/docs/handoff/reports/idol-5.json b/docs/handoff/reports/idol-5.json
deleted file mode 100644
index 1e7920de..00000000
--- a/docs/handoff/reports/idol-5.json
+++ /dev/null
@@ -1,111 +0,0 @@
-{
- "key": "idol-5",
- "impl": {
- "branch": "o/idol-5",
- "summary": "Image results get a 'Make it 3D (quick)' menu action (after 'Animate with Genjutsu'). It opens /image-to-3d?mode=splat&model=oss-idol&quality=quick&image=<file>, and the studio fills the photo slot, picks Idol 3D on Quick look with the photo crop off, and shows the brief's line (tens of seconds on a consumer GPU). The action only shows when the open engine can run for the owner, so it is hidden on cloud-only installs and for guests and accounts. NEXT_STEPS.image is unchanged. Two commits, pushed to origin/o/idol-5 (base claude/fuobe-parity-4 @ 03e49f2d).",
- "built": [
- "src/lib/output-actions.ts: new OutputActionId 'make-3d', ActionContext.openEngine, make3dHref(url, photo). In case 'image' the action is a menu link shown only when ctx.openEngine is set and engineMode is not 'cloud'. Vector pictures, deleted results, videos, audio, text and 3D never get it. An upload opens with &photo=1 so the looser photo crop starts on.",
- "src/lib/connections.ts: openEngineReady(status). It is true when Engine mode is not cloud, the viewer is not a guest or account, and either ComfyUI is configured, the owner's computer GPU is set up, or placeholder results are on.",
- "src/lib/api.ts: useOpenEngine() hook. It combines openEngineReady with hydration and checks that oss-idol is switched on (open) in Settings → Models & licences.",
- "src/components/studio/result-actions.tsx (used by feed tiles and the Library) and viewer.tsx pass openEngine. The action's icon is Rotate3d.",
- "src/lib/av/model3d.ts: readModel3dLink(sp) (pure) reads model, mode, rig, quality and image. Only /api/files/ or https:// images up to 2048 characters are accepted. ?photo=1 is also read. The file also holds MAKE_3D_HINT, the brief's copy.",
- "src/components/model3d/model3d-studio.tsx: UrlModel now uses readModel3dLink. ?quality= sets Idol's Best/Quick look for that mode and engine. ?image= fills the slot as a 'generation' source with the photo switch off (on with photo=1). The hint shows under the Idol settings while the handed-over picture is in the slot on the open engine.",
- "Already there from idol-1 and later work, reused: oss-idol in MODELS_3D.splat.open, the Idol Best/Quick presets and photo crop (idolExtra, IdolSettings, idolPhotoFor), the result landing in /image-to-3d's feed and the Library like any splat job, and model3dView(g).photo linking the source picture.",
- "Not built (optional in the brief): a one-click go=<token> auto-run. The user presses 'Make the splat' once."
- ],
- "tests": [
- "tests/make-3d.test.ts (new, 15 tests). Unit-tested: the action's href, label and placement; it is hidden without openEngine and on cloud-only installs; the other image actions keep their order, with make-3d right after genjutsu; it never appears on video, audio, text, model3d, SVG or deleted results; uploads get photo=1; nextSteps for images stays animate, upscale, edit. readModel3dLink is tested on the Make-it-3D link, ⌘K ?model=, the rig link, ?mode=, a bad quality, and unsafe or oversized image URLs. openEngineReady is tested for engine modes, ComfyUI, the owner's GPU, demo mode, and guests/accounts.",
- "Targeted vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): make-3d, library-pure, ux-flows, model3d and idol: 116/116 passed. Full suite not run (the stage says no full suite).",
- "pnpm typecheck: clean. It needed NODE_OPTIONS=--max-old-space-size=6144 because the default heap ran out of memory. eslint on the changed files: clean.",
- "Browser check, demo mode (tests/e2e/make-3d.mjs, new; pnpm dev -p 3471, FUOBE_DEMO_MODE=on) at 1440 and 390 px, light and dark: passed. The demo picture's ⋯ menu shows 'Make it 3D (quick)' after Genjutsu. Clicking it opens the prefilled studio: Idol 3D, Quick look on, photo switch off, the picture in the slot, the hint shown, the price resolved, no sideways scroll, no console or page errors. At 1440 light, pressing 'Make the splat' once creates an oss-idol image-to-3d job with inputs.images[0] = the picture, photoCrop false and steps 20. Server stopped and .next deleted afterwards."
- ],
- "left": [
- "Optional one-click go=<token> hand-off for /image-to-3d is not built.",
- "Not checked live: a real Idol run on a GPU. Only demo mode was verified, as the brief says; no ComfyUI graph was added or changed.",
- "No new API route, migration, ComfyUI graph or node pack, so there are no public-signup route rows, request-body-limit rows or pre-flight changes. Visitors never see the action: openEngineReady is false when status.viewer is set, which matches '3D models are closed to accounts'.",
- "Brief out of date: line numbers in output-actions.ts (case 'image' and ActionContext) and model3d-studio.tsx (UrlModel) have moved, so the code was found by name. useEngine alone does not say whether ComfyUI is connected, so the new useOpenEngine/openEngineReady reads status.providers.comfyui, ownerGpu and demoMode."
- ],
- "docsNotes": [
- "FEATURES / STATUS: image results have a 'Make it 3D (quick)' menu action (open engine only). It opens Image to 3D → Splat on Idol 3D's Quick look with the picture in and the photo crop off (on for uploads). It is hidden on 'Paid APIs only' installs, for guests and accounts, and when Idol 3D is switched off. A picture's next-step chips are unchanged.",
- "ARCHITECTURE: ActionContext.openEngine is supplied by the useOpenEngine() hook (src/lib/api.ts), built on openEngineReady (src/lib/connections.ts). Image to 3D links are parsed by readModel3dLink (src/lib/av/model3d.ts): model, mode, quality, image, photo.",
- "New e2e script tests/e2e/make-3d.mjs: node tests/e2e/make-3d.mjs http://localhost:<port> [--shots=dir], with the app in demo mode."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "low",
- "category": "brief-vs-owner-rule",
- "file": "src/lib/output-actions.ts",
- "line": 144,
- "summary": "Make it 3D is hidden whenever the open engine can't run, including on 'Paid APIs only' installs and on 'both' installs without ComfyUI, even though fal hosts Idol (idol-3d, MODELS_3D.splat.cloud; docs/research/idol-9.md line 280: 'since 2026-10-30 fal hosts Idol, so a package may add what speridlabs/idol supports on the cloud').",
- "detail": "The brief's CLOUD RULE says 'Idol is not hosted', which is out of date; the implementer followed the brief as written, and the package is scoped 'open engine only', so this is not a defect in the build. Under 'each engine does all it can' a later package could offer the action on the cloud as model=idol-3d (hosted, no substitute). Open question for the owner, not a blocker.",
- "verified": "Traced: IDOL_MODELS.cloud = 'idol-3d' in src/lib/av/model3d.ts:84 and cloud-models.generated.ts has idol-3d; outputActions requires ctx.openEngine && engineMode !== 'cloud'."
- },
- {
- "severity": "low",
- "category": "test-coverage",
- "file": "src/lib/api.ts",
- "line": 1057,
- "summary": "useOpenEngine's 'Idol 3D switched off in Settings → Models & licences' gate (offered(status.access, 'oss-idol', 'open')) and the studio's handling of ?image=/?quality= (fromUrl/fromImage) have no unit or component test; only the demo-mode e2e covers the studio side.",
- "detail": "The pure parts (outputActions, readModel3dLink, openEngineReady, idolPhotoFor) are well tested. The hook and the component wiring rely on tests/e2e/make-3d.mjs, which I ran and which passed.",
- "verified": "Read tests/make-3d.test.ts; grep shows no test referencing useOpenEngine or offered with oss-idol."
- },
- {
- "severity": "nit",
- "category": "docs",
- "file": "src/lib/av/model3d.ts",
- "line": 481,
- "summary": "readModel3dLink's JSDoc block sits above MAKE_3D_HINT's own JSDoc, so it is orphaned: the function has no attached doc and the constant has two stacked comment blocks.",
- "detail": "Move the first block down to sit directly above `export function readModel3dLink`.",
- "verified": "Read the diff hunk at model3d.ts:480-497."
- }
- ],
- "checks": [
- "Mapped the diff (claude/fuobe-parity-4...o/idol-5, base 03e49f2d, 2 commits, 9 files) against the brief: menu action 'Make it 3D (quick)' after Genjutsu with href /image-to-3d?mode=splat&model=oss-idol&quality=quick&image=…, new OutputActionId and ActionContext.openEngine, NEXT_STEPS.image unchanged, UrlModel learns ?image= and ?quality=, brief copy shown in the studio. Optional go=<token> one-click not built (allowed by the brief).",
- "Callers: outputActions is only called from TileActions (feed tiles and Library asset cards) and Viewer; both now pass openEngine from useOpenEngine(). ACTION_ICONS has make-3d.",
- "Visitors: openEngineReady returns false when status.viewer is set; confirmed /api/status returns visitorStatus with viewer for guests and accounts (src/server/account-gpu.ts). No new route, migration, graph or node pack, so no public-signup/ESTIMATES/request-body/pre-flight rows needed; 3D stays closed to accounts server-side.",
- "Security: readModel3dLink accepts only /api/files/ or https:// up to 2048 chars (stricter than other studios' ?image=). An https input is fetched server-side only through fetchRemote (public links only) in src/server/storage.ts, and guardRef refuses links inside a tenant. No SSRF or path-traversal regression.",
- "Studio state: modeOf('oss-idol') resolves to splat/open; quality is stored under the same `${mode}:${engine}` key idolQuality reads; fromImage sets the slot with source 'generation' (photo crop off) or 'upload' with ?photo=1. UrlModel's effect now depends on params instead of id/mode strings; useSearchParams is stable for an unchanged URL and setEngine only changes with the engine mode, so it does not re-fill the slot after the user changes it. pickMode's router.replace drops ?image=, so no re-fill on a mode change.",
- "Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): make-3d, model3d*, idol*, library-pure, ux-flows, public-signup: 9 files, 177/177 passed. Other output-action suites (remove-dialogue, clean-voice, composer-fixes, audio-tools, video-finish, layout-mode, clean-dialogue, music3-cloud, regenerate-2k, vectorize, layers, model3d-finish, dop-originals): 332/333; the one failure is tests/dop-originals, a known pre-existing failure from main.",
- "npx next typegen, then NODE_OPTIONS=--max-old-space-size=8192 tsc --noEmit: clean. eslint on all changed files: clean.",
- "Browser check, demo mode (FUOBE_DEMO_MODE=on pnpm dev -p 3487, node tests/e2e/make-3d.mjs): passed at 1440 and 390 px, light and dark. The menu shows the action after Genjutsu; the studio opens on Splat with Idol 3D, Quick look, photo switch off, the picture in the slot, the hint shown; no sideways scroll, no console or page errors (Hydration errors not filtered); one press of 'Make the splat' creates an oss-idol job with inputs.images[0] = the picture, photoCrop false, steps 20. Inspected the 390 px dark screenshot: layout intact. Server stopped by port and .next deleted.",
- "No Higgsfield API, code or media; no LoRA files; no hot files or off-limits files touched; commit messages follow 'Area: the visible result'."
- ],
- "verdict": "pass: the package does what the brief asks and breaks nothing I could find. Three minor items: a cloud Idol question for the owner, thin hook and component test coverage, and an orphaned doc comment. None blocks merge."
- },
- "fix": {
- "applied": [
- "Low (test-coverage): the hook's 'Idol 3D switched on' gate now lives in a pure make3dOffered(status) in src/lib/connections.ts (openEngineReady plus offered(access, 'oss-idol', 'open')). useOpenEngine in src/lib/api.ts calls it, and the now-unused offered import is gone. The studio's ?image=/?quality= handling now goes through pure linkedPicture(url, asPhoto) and linkedIdolQuality(prev, mode, engine, id, quality) in src/lib/av/model3d.ts, and model3d-studio.tsx uses them with the same behaviour. tests/make-3d.test.ts has 6 new tests: Idol off, Idol on for the cloud only, Idol on for open, another model off, cloud mode, an account viewer, the slot's source and photo crop for a result and for an upload, the quality set only for Idol and only under its mode and engine key, and a Make it 3D href read back into exactly that state.",
- "Nit (docs): readModel3dLink's JSDoc moved from above MAKE_3D_HINT to directly above the function.",
- "Commit a7bc5faa 'Image to 3D: Make it 3D's Idol switch and link hand-over checked in tests', pushed to origin/o/idol-5."
- ],
- "rejected": [
- "Low (brief-vs-owner-rule), offering Make it 3D on the cloud as idol-3d through fal: not built. The package goal is 'a turning 3D preview made on the user's GPU', and the brief scopes it to the open engine. Hosted Idol is already reachable from the Image to 3D studio's Splat mode on the cloud. A cloud variant of the action needs its own copy (not 'on your GPU'), pricing on the menu, and a decision from the owner. The reviewer also called it an open question, not a defect. Recorded under 'left'."
- ],
- "checks": [
- "Branch check: claude/fuobe-parity-4..o/idol-5 lists only this package's own commits, and the base is an ancestor. Worked in the existing worktree /home/user/wt/o-idol-5.",
- "Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): make-3d, library-pure and ux-flows: 67/67 passed. idol, model3d, model3d-finish, model3d-runner, model3d-webm and public-signup: 115/115 passed. The full suite was not run (the coordinator runs it).",
- "npx next typegen, then NODE_OPTIONS=--max-old-space-size=8192 pnpm typecheck: exit 0. eslint on the 5 changed files: exit 0.",
- "Browser check in demo mode (FUOBE_DEMO_MODE=on pnpm dev -p 3491, node tests/e2e/make-3d.mjs): all checks passed at 1440 and 390 px, light and dark. That covers the menu, the prefilled studio and one press creating the oss-idol splat job. Server stopped by port, .next deleted, git status clean."
- ],
- "finalSummary": "idol-5 is finished. Image results have a 'Make it 3D (quick)' menu action right after Genjutsu. It opens Image to 3D, Splat, on Idol 3D (oss-idol), Quick look, with the picture in the slot, the photo crop off (on for uploads) and the brief's copy shown. One press of 'Make the splat' runs it. Open engine: built, and verified in demo mode only. A real Idol run needs the owner's ComfyUI or GPU with Idol installed (from idol-1); nothing here was run on a GPU. Cloud engine: the action is hidden on 'Paid APIs only' installs and whenever the open engine can't run, as the brief says. Hosted Idol (idol-3d on fal) stays available in the studio itself and needs a fal key. The action also hides when Idol 3D is switched off for open in Settings → Models & licences. Guests and accounts never see the action (openEngineReady is false for any viewer), and 3D runs stay closed to accounts on the server (own-gpu-tool). No new route, migration, graph or node pack. This fix stage moved the Idol switch and the studio's link hand-over into pure, tested helpers and fixed a misplaced doc comment.",
- "left": [
- "Owner question: should Make it 3D also appear on cloud-capable installs as hosted Idol (idol-3d on fal)? The brief's 'Idol is not hosted' is out of date (docs/research/idol-9.md: fal has hosted Idol since 2026-10-30).",
- "The optional one-click go=<token> auto-run for /image-to-3d is not built. The user presses 'Make the splat' once.",
- "No real GPU run of Idol was checked; only demo mode was verified."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/idol-5"
- ],
- "notMerged": [],
- "conflicts": "none",
- "checks": "batch of 7 (dbs-d7, idol-5, idol-2, idol-6, n7-9, kandinsky6, n7-10): typecheck 0, lint 0, vitest 5788 passed, 6 failed (main known); each merge checked by an independent verifier; n7-10 + Pika Flex interaction fixed in 64900624",
- "pushed": true,
- "head": "64900624"
- }
-}
diff --git a/docs/handoff/reports/idol-6.json b/docs/handoff/reports/idol-6.json
deleted file mode 100644
index d7aaecdd..00000000
--- a/docs/handoff/reports/idol-6.json
+++ /dev/null
@@ -1,118 +0,0 @@
-{
- "key": "idol-6",
- "impl": {
- "branch": "o/idol-6",
- "summary": "Idol 3D results from your own GPU (request.modelId 'oss-idol') with a source picture now have a 'Build the final with TRELLIS.2' button, with 'A textured, riggable .glb · 16 GB GPU' under it. The button links to /image-to-3d?mode=image&model=oss-trellis2&image=<the result's picture>. Image to 3D now reads ?image= and fills the photo from it. The button is hidden when TRELLIS.2 is switched off in Settings → Models & licences (offered(), the same check the studio's picker uses), when engine mode is Paid APIs only, and for visitors. fal Idol results ('idol-3d') never get it. Two signed commits on o/idol-6 (9ed6da4f, de535d63); not pushed.",
- "built": [
- "src/lib/av/model3d.ts: new FINAL_3D constant (model oss-trellis2, the label and the note) and a pure finalBuildHref(g, view, allowed) that returns the link only for oss-idol results with a photo when allowed is true",
- "src/components/model3d/model-card.tsx: new finalAllowed prop. The outline button links to the final build, with the note under it, below the action row. The other buttons (Rig & animate, Animate the spin, Film it photoreal, Refine, Print-ready, Retexture) are unchanged",
- "src/components/model3d/model3d-studio.tsx: UrlModel now reads ?image= and calls a stable fromImage callback. It fills the photo slot and turns Idol's photo crop off, since the picture comes from a Fuobe result. finalAllowed = !visitor && engineMode !== 'cloud' && offered(access, 'oss-trellis2', 'open'), passed through ResultCard to ModelCard",
- "Plan items already there: oss-idol and oss-trellis2 in MODELS_3D, model3dView().photo, offered()/useModelAccess, and ?model= / ?mode= handling. The ?image= support (idol-5's, not built yet; there is no o/idol-5 branch) was added here in a general form that idol-5 can reuse (e.g. ?mode=splat&model=oss-idol&image=…)"
- ],
- "tests": [
- "tests/idol-final.test.ts (new, 6 tests): the exact href and that it parses back to mode=image / model=oss-trellis2 / the same picture, and that modeOf maps it to image on the open engine. No link for: an oss-idol result without a picture, fal idol-3d, oss-triposplat, oss-trellis2, oss-pixal3d, triposplat, trellis-2, or when not allowed. Model access: offered() with oss-trellis2 off hides the link, another model off does not. FINAL_3D names a real open model in MODELS_3D whose tagline says 16 GB GPU. A source check that the card and studio are wired",
- "Targeted run: tests/idol-final, idol, model3d, account-idol — 62/62 pass",
- "tsc --noEmit clean (needed NODE_OPTIONS=--max-old-space-size=8192; the default heap ran out of memory). eslint clean on the changed files",
- "Browser check, demo mode (FUOBE_DEMO_MODE=on, port 3462): new script tests/e2e/idol-final.mjs, run at 1440 and 390 px in light and dark, all passing. Only the Idol card shows the button (the TRELLIS.2 card does not). The note is visible. Clicking opens From an image with TRELLIS.2 picked and the same picture filled in. No sideways scroll, no page or console errors. Server stopped and .next deleted afterwards",
- "No full vitest suite run, as this stage says"
- ],
- "left": [
- "Model access was not toggled live in the browser; only the unit test covers it",
- "No GPU run: the final TRELLIS.2 build itself is the existing oss-trellis2 route (16 GB GPU), unchanged and not exercised here",
- "Accounts still can't start 3D (own-gpu-tool). The button is hidden for visitors, so nothing changes on the server",
- "The changed files were already failing prettier --check before this package (the repo has no prettier config), so I did not reformat them"
- ],
- "docsNotes": [
- "The brief was out of date in two places. The oss-trellis2 note in MODELS_3D now reads 'A dependable second choice, with a turntable video' (Pixal3D is the first choice), so the card uses the brief's 'A textured, riggable .glb · 16 GB GPU' from FINAL_3D rather than the catalog note. model3d.ts L39 no longer holds that line",
- "Image to 3D now accepts ?image=<url> to fill the photo (alongside ?model= and ?mode=). This is worth a line in ARCHITECTURE/STATUS where the Image to 3D link parameters are listed, and idol-5 can use it",
- "STATUS: idol-6 is done (Draft then final on Idol 3D results from your own GPU; open engine only; no Idol draft on the cloud)"
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "low",
- "file": "src/components/model3d/model3d-studio.tsx",
- "line": 98,
- "title": "Clicking 'Build the final with TRELLIS.2' a second time with the same link does nothing",
- "detail": "UrlModel only acts when the values in the URL change: the ?image= effect depends on [image, onImage] and the ?model= effect on [id, mode, ...]. The button sits on the same /image-to-3d page. Say the user clicks it on result A, then changes the photo or the mode by hand, then clicks the same card again. The URL is the same, so neither effect runs and the form keeps what the user changed, so the click looks like it did nothing. Clicking a different Idol card works, because its image changes. ?model= links already behaved this way before this package, so this is not a regression of existing behaviour, but it is the main repeat flow of this new button. Found by reading the code; not reproduced in a browser.",
- "verified": "Traced: fromImage and fromUrl are stable useCallbacks, and the effects' deps are strings taken from useSearchParams."
- },
- {
- "severity": "low",
- "file": "src/components/model3d/model3d-studio.tsx",
- "line": 244,
- "title": "?image= turns Idol's photo crop off on the wrong premise",
- "detail": "fromImage calls setIdolPhoto(false), with the comment 'a Fuobe result's, so Idol's photo crop stays off'. But model3dView(g).photo is request.inputs.images[0], the Idol run's source picture. That is normally the user's own upload: the e2e script uses /api/uploads, and idolPhotoFor counts uploads as photos. This has no effect on the TRELLIS.2 final, since the crop only applies in Splat mode. It is wrong if the user then switches to Splat with Idol, or if idol-5 reuses ?image= as the report suggests (?mode=splat&model=oss-idol&image=...): an uploaded photo would get the synthetic crop. A better choice is to leave the switch as it is, or to set it with idolPhotoFor.",
- "verified": "Read model3dView (photo: g.request.inputs?.images?.[0]) and idolPhotoFor in src/lib/av/model3d.ts."
- },
- {
- "severity": "info",
- "file": "tests/idol-final.test.ts",
- "line": 57,
- "title": "The card and studio wiring is tested only by matching source text",
- "detail": "The access, visitor and Paid-APIs-only gating in the studio is checked by an exact source-text match of the finalAllowed line. The pure finalBuildHref and offered() are unit-tested properly, and the browser script covers the visible flow in demo mode. A refactor that keeps behaviour would break the string test, and a behaviour change that keeps the text would pass it. The engineMode 'cloud' case and the visitor case have no behavioural test. This is acceptable for a P2 small package."
- },
- {
- "severity": "info",
- "file": "src/components/model3d/model3d-studio.tsx",
- "line": 92,
- "title": "?image= is taken as given (no /api/files check)",
- "detail": "Any value of ?image= becomes the photo's ref and preview. Main's studio-page and color-grade already do the same; only live-edit-app checks with fileParam (/api/files/ only). Only the owner can run 3D: visitors are blocked in the UI, and the server answers own-gpu-tool for accounts. An <img src> does not run javascript: URLs. So this is not exploitable here and is not a new class of problem. Checking with a fileParam-style pattern would be tidier."
- }
- ],
- "checks": [
- "Read the stage prompt, main-rules.md, the implementer report, the full diff claude/fuobe-parity-4...o/idol-6 (2 commits, 5 files) and the code around it: model3dView().photo, idolPhotoFor, modeOf, the studio's photo state, the UrlModel effects, and the single ModelCard caller (ResultCard).",
- "Brief coverage: the button and its note show only for oss-idol results with a source picture; the href is /image-to-3d?mode=image&model=oss-trellis2&image=<photo>; ?image= support was added; the button hides when oss-trellis2 is off through offered(access, 'oss-trellis2', 'open'), the same check the picker uses; it also hides for visitors and in Paid APIs only. No Idol draft on the cloud: fal idol-3d never gets it. Rig & animate, Animate the spin and the other buttons are untouched (the new block is added after the action row).",
- "Checked against idol-9.md §7.2 / §9 idol-6: it matches ('oss-trellis2 on the same picture ... not an Idol substitute'). The implementer's note is right that the catalog's oss-trellis2 note changed, so FINAL_3D carries the brief's text.",
- "Public sign-up: no new route, server path or price check. The button is hidden for visitors, and accounts still get own-gpu-tool for 3D, so there is no new path to the install's GPU or keys. No new model, LoRA, node pack or graph, so no licence data, pre-flight or ASSET_REFS work is needed. No Higgsfield code or media, no analytics. The visible copy is owner-only.",
- "npx vitest run tests/idol-final.test.ts tests/model3d.test.ts tests/idol.test.ts: 3 files, 60/60 pass.",
- "eslint on the 3 changed source files and the new test: clean.",
- "npx next typegen, then tsc --noEmit with an 8 GB heap: clean (exit 0). Before typegen, tsc showed only LayoutProps/PageProps/RouteContext errors, which typegen fixes. Removed the .next folder typegen made; git status is clean.",
- "Did not re-run the browser script (tests/e2e/idol-final.mjs). Read it: it covers 1440/390 px, light and dark, console errors, sideways scroll, and the link landing on TRELLIS.2 with the picture.",
- "Made no edits, commits or pushes."
- ],
- "verdict": "approve: the brief is met, typecheck, lint and targeted tests are clean, and nothing regresses. There are two low findings (a second click on an unchanged link does nothing; ?image= turns Idol's photo crop off on a wrong premise), worth fixing before idol-5 reuses ?image=, but neither blocks."
- },
- "fix": {
- "applied": [
- "Review finding 1 (low, confirmed): clicking 'Build the final with TRELLIS.2' a second time with the same link did nothing, because UrlModel only reacts when the URL changes. ModelCard now takes an onFinal callback; the link's onClick calls it with the result's picture, and the studio's toFinal picks From an image / open engine / oss-trellis2 (via modeOf(FINAL_3D.model)) and fills the photo on every click. The link still navigates, so a new tab or a reload works as before. Wired through ResultCard.",
- "Review finding 2 (low, confirmed): ?image= turned Idol's 'It's a photo' crop off on a wrong premise (model3dView().photo is the Idol run's source picture, usually the user's own upload). fromImage now fills the photo only and leaves the switch as it is.",
- "tests/idol-final.test.ts: wiring checks for onClick/onFinal/toFinal and that fromImage no longer touches setIdolPhoto (they pass in the full vitest run).",
- "tests/e2e/idol-final.mjs: removes the photo by hand and clicks the same link again, then checks the photo slot refills; checks the photo slot itself (the Idol card shows the same picture, so the old img-count check passed on the card alone); counts Idol cards rather than assuming one, so reruns against the same demo data pass; the note check is scoped to the card.",
- "Commit e16347ea 'Image to 3D: Build the final with TRELLIS.2 fills the form on every click' on o/idol-6 (on top of 9ed6da4f, de535d63). Not pushed."
- ],
- "rejected": [
- "Finding 3 (info, source-text wiring test): kept. finalBuildHref and offered() have behavioural unit tests and the browser script covers the visible flow. A component-render test would need a React test harness this suite doesn't use for these studios. I added to the source checks; I didn't replace them.",
- "Finding 4 (info, ?image= not checked against /api/files): no change. Only the owner can start 3D (visitors are hidden in the UI, and accounts get 403 own-gpu-tool on the server). An <img src> doesn't run javascript: URLs, and main's studio-page and color-grade take ?image= the same way. So it isn't exploitable here, and it isn't a new class of problem."
- ],
- "checks": [
- "Branch check: claude/fuobe-parity-4..o/idol-6 lists only this package's commits. The base is an ancestor, so no merge was needed.",
- "pnpm install --frozen-lockfile --prefer-offline: exit 0. npx next typegen: exit 0.",
- "pnpm typecheck (NODE_OPTIONS=--max-old-space-size=8192): exit 0.",
- "pnpm lint: exit 0 (0 errors; 5 warnings, all in files this package doesn't touch: scripts/comfy/library.spec.mjs, src/components/studio/composer.tsx, src/server/elements.ts).",
- "Targeted: npx vitest run tests/idol-final.test.ts tests/model3d.test.ts tests/idol.test.ts: 60/60 pass, run before I added the new wiring assertions to an existing test case.",
- "Full: FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 1, 5481 passed, 6 failed in 5 files: comfy-reuse (1), dop-originals (1), preset-featured (1), soul-runs (2), split-soundtrack (1). This is exactly the known pre-existing list in main-rules.md and has nothing to do with this package. idol-final passed in this run.",
- "Browser, demo mode (FUOBE_DEMO_MODE=on, http://localhost:3462): node tests/e2e/idol-final.mjs passes at 1440 and 390 px in light and dark. Only Idol drafts show the button, with the note on the card. A click opens From an image on TRELLIS.2 with the photo slot filled. After the photo is removed by hand, a second click on the same link fills it again. No sideways scroll, no page or console errors (Hydration errors not filtered). Server stopped, .next deleted, git status clean."
- ],
- "finalSummary": "idol-6 is complete. On a finished Idol 3D result from your own GPU (oss-idol) that has a source picture, the card offers 'Build the final with TRELLIS.2', with 'A textured, riggable .glb · 16 GB GPU' under it. It opens Image to 3D → From an image on TRELLIS.2 with the same picture, and it now does that on every click, including a repeat click on the same link. ?image= fills the picture and no longer flips Idol's photo crop. Open engine (your ComfyUI): the button and the hand-off are built and checked in demo mode. The TRELLIS.2 build itself is the existing oss-trellis2 route (16 GB GPU) and was not run on a GPU here. Cloud engine: there is no Idol draft on the cloud, so the fal idol-3d result never shows the button, and Paid APIs only hides it. The button is also hidden when TRELLIS.2 is switched off in Settings → Models & licences. No key is needed. Public sign-up: guests and other visitors don't see the button. Accounts still can't start 3D (403 own-gpu-tool), and no server path was added. Commits on o/idol-6: 9ed6da4f, de535d63, e16347ea (not pushed).",
- "left": [
- "No GPU run of the TRELLIS.2 final (existing oss-trellis2 route, 16 GB GPU).",
- "Model access was not switched off live in the browser; only the unit test covers that.",
- "Docs follow-ups from the implementation stage still stand. Image to 3D accepts ?image=<url> (alongside ?model= and ?mode=), and ARCHITECTURE/STATUS should say so. STATUS should mark idol-6 done. idol-5 can reuse ?image=.",
- "Full vitest has 6 failures, all on the known pre-existing list (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack)."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/idol-6"
- ],
- "notMerged": [],
- "conflicts": "model-card imports; model3d-studio ?image= handling unified with idol-5's (fromImage(url, asPhoto)); follow-up 2f7d3db2 (linkedPhoto)",
- "checks": "batch of 7 (dbs-d7, idol-5, idol-2, idol-6, n7-9, kandinsky6, n7-10): typecheck 0, lint 0, vitest 5788 passed, 6 failed (main known); each merge checked by an independent verifier; n7-10 + Pika Flex interaction fixed in 64900624",
- "pushed": true,
- "head": "64900624"
- }
-}
diff --git a/docs/handoff/reports/idol-7.json b/docs/handoff/reports/idol-7.json
deleted file mode 100644
index 3dbb222d..00000000
--- a/docs/handoff/reports/idol-7.json
+++ /dev/null
@@ -1,122 +0,0 @@
-{
- "key": "idol-7",
- "impl": {
- "branch": "o/idol-7",
- "summary": "Idol 3D quick mesh is built. The new graph image-to-mesh-idol is idol-1's Idol graph with the splat file (SplatToFile3D 92) replaced by core SplatToMesh 93 (resolution 384, min_opacity 0.02, kernel 5, level 0.4, min_component 500, colour sharpen 2), then SaveGLB 51 'fuobe/idol-mesh'. The orbit video (42) is kept. It is on core nodes only and passed /prompt validation on the shared CPU ComfyUI 0.41.0 (fc04da91). The catalog has oss-idol-mesh ('Idol 3D quick mesh', open engine only), last in From an image's open list with the brief's note. Its .glb opens in model-viewer and offers Rig & animate, Refine this mesh (with the source picture) and Refine detail · Hi3D, all through the existing paths. It has a licence row and a row on the GPU pre-flight board, and accounts get 403 own-gpu-tool. A 'mesh' eval suite was added and runs end to end in demo mode. No GPU run.",
- "built": [
- {
- "feature": "Graph scripts/comfy/hand-built/image-to-mesh-idol.json plus its library.spec.mjs entry: capability image-to-3d, vramGb 8, the same licence string as image-to-splat-idol. Bindings are idol-1's minus splatFormat, plus meshResolution -> 93.resolution. Outputs: 51 model3d and 42 video role turntable. Defaults cutout true, photoCrop false; the rest are Best from the graph. Built, /prompt-validated (validation-state.json), and node scripts/comfy/build-requirements.mjs run: requirements.json gets the workflow with Idol's same 5 files and no packs. No new model pins or packs were needed. object_info.subset.json only gains SplatToMesh: I reverted the validator's other rewrites, which came from this server's own custom nodes.",
- "status": "built",
- "verifiedHow": "tests/idol-mesh.test.ts and targeted runs; graph /prompt-validated on CPU ComfyUI 0.41.0; browser check in demo mode"
- },
- {
- "feature": "oss-idol-mesh in src/lib/catalog/models.ts after oss-idol: vendor Speridlabs, family idol, the brief's tagline, route comfy('image-to-3d','image-to-mesh-idol'), seed, maxImages 1, a 'Mesh detail' slider (meshResolution 128-768, default 384, for Canvas), HI3D_REFINE_CONTROL like the other open image-to-3D models, and engineNote 'Runs on your GPU only: no cloud service makes this mesh.'",
- "status": "built",
- "verifiedHow": "tests/idol-mesh.test.ts and targeted runs; graph /prompt-validated on CPU ComfyUI 0.41.0; browser check in demo mode"
- },
- {
- "feature": "MODELS_3D.image.open in src/lib/av/model3d.ts: oss-idol-mesh comes after oss-hunyuan3d-21 with the note 'Rough mesh, vertex colours, no textures · 8 GB GPU'. ⌘K and ?model= links pick it up through ALL_MODELS_3D and modeOf.",
- "status": "built",
- "verifiedHow": "tests/idol-mesh.test.ts and targeted runs; graph /prompt-validated on CPU ComfyUI 0.41.0; browser check in demo mode"
- },
- {
- "feature": "src/server/providers/comfyui.ts: Hi3D's 512/1024/1536 check on meshResolution now applies only to graphs that also bind model3d (Hi3D's), so Idol's grid isn't refused. On other graphs meshResolution is kept to SplatToMesh's range (64-768, steps of 16), and a non-number is dropped.",
- "status": "built",
- "verifiedHow": "tests/idol-mesh.test.ts and targeted runs; graph /prompt-validated on CPU ComfyUI 0.41.0; browser check in demo mode"
- },
- {
- "feature": "src/server/gpu/tools.ts STUDIO_ROWS: a new row 'Image to 3D, quick mesh' (/image-to-3d?model=oss-idol-mesh) with the step oss-idol-mesh#image-to-3d.",
- "status": "built",
- "verifiedHow": "tests/idol-mesh.test.ts and targeted runs; graph /prompt-validated on CPU ComfyUI 0.41.0; browser check in demo mode"
- },
- {
- "feature": "Eval first: scripts/eval/cases/mesh.json. It is kind video, open and demo targets, with variants idol-mesh (the candidate), fine-grid (512) and trellis2 (reference). There are 4 cases: product render, product photo and figurine (photo crop on), and a generated character, with inputs in local/mesh/ and the input picture as the style reference. It has a 'decides' rule and a row in scripts/eval/README.md. It passes pnpm eval:validate, and a demo run against a dev server did 8/8 jobs.",
- "status": "built",
- "verifiedHow": "tests/idol-mesh.test.ts and targeted runs; graph /prompt-validated on CPU ComfyUI 0.41.0; browser check in demo mode"
- },
- {
- "feature": "Docs: a row in scripts/comfy/README.md's workflow table, and a dated 'idol-7 as built' note in docs/research/idol-9.md §9 (a research correction).",
- "status": "built",
- "verifiedHow": "tests/idol-mesh.test.ts and targeted runs; graph /prompt-validated on CPU ComfyUI 0.41.0; browser check in demo mode"
- }
- ],
- "tests": "New tests/idol-mesh.test.ts (16 tests). It covers the manifest entry, bindings, outputs, files and requirements index; that the licence matches Idol's and carries the DINOv3 notice; the graph (SplatToMesh defaults and wiring, no SplatToFile3D, every other node identical to image-to-splat-idol); prepareWorkflow binding of seed, crop and grid, the grid clamp, and Hi3D still refusing 384; the route and the open-only engine; MODELS_3D order (Pixal3D's default unchanged, splat list unchanged); model3dRequest and plan; the Canvas 3D node; collectOutputs (the GLB comes back as model3d / model/gltf-binary with no splat format, model3dView gives glb and no splat, and the server finish picks it up); canRefine, refineRequest and withRefine on its results; the licence row and notice list; and the pre-flight row. Extended tests/account-idol.test.ts: oss-idol-mesh from From an image answers 403 own-gpu-tool and nothing reaches the account's GPU. Extended tests/hi3d-refine.test.ts: the Hi3D switch is on oss-idol-mesh too. Targeted runs, all passing: idol-mesh, idol, model3d, model3d-finish, hi3d-refine, licences, account-idol, comfy-provider, comfy-library-4, comfy-library-notes, open-engine, public-signup, public-signup-tools, account-tenant, hosted-runs, hosted-catchup, request-body-limits, eval-harness, gpu-api/readiness/requirements, assist*, catalog*, cloud-catalog*, canvas, command-palette, demo-ops, glb-finish-safety, outputs, pipeline and others (~1,700 tests). No full suite, per the stage. tsc --noEmit passes (with NODE_OPTIONS=--max-old-space-size=8192; the default heap ran out of memory here). pnpm lint: 0 errors (5 warnings already on the base). Live: build plus node validate-workflows.mjs image-to-mesh-idol --shared against http://127.0.0.1:8188 (CPU, ComfyUI 0.41.0) passed. It printed 'no sample for: sampler, meshResolution', as idol-1's graph does for sampler. finish-glb.mjs on a synthetic vertex-coloured, unlit, self-contained GLB (built with gltf-transform to match SaveGLB's COLOR_0 + KHR_materials_unlit output) exits 0, with and without --limits account. It keeps COLOR_0 and the unlit extension and moves the pivot to the bottom. Browser (pnpm dev on port 3471, FUOBE_DEMO_MODE=on, Playwright): /image-to-3d?model=oss-idol-mesh at 1440 and 390 px, light and dark. The model picker shows Idol 3D quick mesh with its note and 'Built with DINOv3'. An upload plus 'Make it 3D' gives a demo result card with Rig & animate and Refine this mesh. No horizontal overflow and no console errors. The server was stopped and .next and the data dir deleted.",
- "left": [
- "A GPU run (8 GB+): run pnpm eval:run --suite mesh --engine open with pictures in local/mesh/, on a Fuobe server with Chromium and ffmpeg so the scored turntable shows the mesh and not the splat orbit. Then look at the GLBs (holes, inner double wall, floaters, smeared colour, thin parts) before the model is kept. Mesh quality, SplatToMesh's memory peak at 384/512 and run time are all unmeasured.",
- "Hi3D on these results: 'Refine this mesh' and 'Refine detail · Hi3D 1.0' show and use the source picture (model3dView.photo), through the existing hi3d-refine path. Whether Hi3D's refine works well on an Idol mesh is unverified (CUDA/Ampere only), and its result drops the vertex colours, as it does for every model.",
- "From an image doesn't offer Idol's Best/Quick look or 'It's a photo' switch for the mesh model: it runs the graph's Best defaults with the synthetic crop. The bindings exist (photoCrop, steps, sampler, numGaussians, meshResolution), so a later change can expose them.",
- "The output has no 'mesh' role, which differs from the brief; docsNotes says why.",
- "No GPU here: mesh quality and memory are unmeasured."
- ],
- "docsNotes": "Brief out of date: From an image's open list is now Pixal3D, TRELLIS.2, Hunyuan3D 2.1 (Pixal3D is the default since main's 10-30 work), so 'oss-trellis2 and oss-hunyuan3d-21 stay first' now reads as 'Pixal3D, TRELLIS.2 and Hunyuan3D 2.1 stay first'. They do, and oss-idol-mesh is fourth. Output role: the brief asked for 'output role mesh'. ManifestOutput's role type has no 'mesh', and tests/comfy-library-4.test.ts (a hot file whose only allowed edit is adding unvalidated ids) checks every role against its list. Also, modelToFinish skips any GLB with a role, so a role would have cost the server's web GLB and mesh turntable. The GLB is therefore the plain model output, as every image-to-3D graph's is. The SaveGLB filename_prefix in the hand-built graph is 'fuobe/idol-mesh'. The build rewrites the library copy to 'fuobe/image-to-mesh-idol', as it does for every graph, and each job sets its own prefix through filenamePrefix. There is no idol-3 'splat' suite on this base, so the eval cases are a new 'mesh' suite (scripts/eval/cases/mesh.json). idol-3 can merge it or keep it beside its own. The binding key meshResolution is shared with Hi3D's graph. The provider now tells them apart (Hi3D's graph also binds model3d). Assist's mesh_resolution on a non-Hi3D model still means a Hi3D refine step after the build (unchanged). For docs/STATUS.md and docs/FEATURES.md (the docs pass): Image to 3D → From an image gains 'Idol 3D quick mesh' (open engine only, 8 GB GPU, Apache-2.0, Built with DINOv3). It makes a rough vertex-coloured GLB, no textures, from Idol's splat through core Extract Mesh from Splat, with the same finish and turntable as the other open models, and it can be rigged or refined. No cloud route, because fal's speridlabs/idol gives a splat only. The GPU pre-flight board has an 'Image to 3D, quick mesh' row."
- },
- "review": {
- "findings": [
- {
- "file": "src/components/model3d/model3d-studio.tsx",
- "line": 415,
- "severity": "minor",
- "summary": "From an image runs oss-idol-mesh without Idol's photo crop or Best/Quick look. isIdol() only matches oss-idol and idol-3d, so IdolSettings is hidden and model3dRequest sends no params.extra. Every upload runs with photoCrop false (the synthetic crop), even though the graph binds photoCrop and the splat page turns it on for uploads (idolPhotoFor).",
- "failureScenario": "A person uploads a phone photo of a product in From an image with Idol 3D quick mesh. The request carries no photoCrop, so 88:104 stays on the synthetic crop, which the splat page would not use for that same photo. The capability is in the graph but the page never uses it. The implementer lists this under 'left'.",
- "verified": true
- },
- {
- "file": "scripts/comfy/hand-built/image-to-mesh-idol.json",
- "line": 1,
- "severity": "minor",
- "summary": "The only turntable the graph makes (42, role turntable) is Idol's splat orbit, not the mesh. The mesh only shows up in the video when the server's finish renders its own turntable (Chromium and ffmpeg). Without them, the result card shows the smooth splat while the downloaded GLB is the rough mesh.",
- "failureScenario": "The owner's server has no Chromium or ffmpeg, so the finish reports turntable 'skipped'. model3dView.turntable then falls back to the role-turntable video, which is the RenderSplat orbit of the Gaussians, and the card shows a quality the .glb doesn't have. This is documented in the notes and in the eval suite, but nothing in the UI says so.",
- "verified": true
- },
- {
- "file": "src/components/model3d/model3d-studio.tsx",
- "line": 65,
- "severity": "nit",
- "summary": "From an image's hint still promises 'a textured 3D model (.glb)', but the new model's note says 'vertex colours, no textures'. The two lines contradict each other when oss-idol-mesh is picked. Hunyuan3D's shape-only choice already has the same mismatch.",
- "failureScenario": "Pick Idol 3D quick mesh: the hint says 'textured' and the picker note says 'no textures'.",
- "verified": true
- },
- {
- "file": "src/server/assist/tools.ts",
- "line": 373,
- "severity": "nit",
- "summary": "meshResolution now means two things. On oss-idol-mesh it is the SplatToMesh grid (64-768), but Assist's mesh_resolution on that model still becomes a Hi3D refine chain (512/1024/1536, geometry only, colours lost), so Assist can't set the Idol grid. This is unchanged and the implementer documented it, but it is easy to misread.",
- "failureScenario": "Assist is asked for 'a finer Idol mesh at 512'. It sends mesh_resolution 512, which queues a Hi3D refine that drops the vertex colours instead of a 512 SplatToMesh grid.",
- "verified": true
- }
- ],
- "checks": "Read the stage prompt, the main rules and the implementer report. Reviewed git diff claude/fuobe-parity-4...o/idol-7 (4 commits, 18 files) with the code around it: comfyui.ts prepareWorkflow (the Hi3D strict check now needs b.model3d; I confirmed in the manifest that mesh-refine-hi3d is the only other graph binding meshResolution and that it binds model3d, so Hi3D behaves as before), chains.ts createRefinedModel and hi3d.ts (the refine step gets its own meshResolution and drops hi3dRefine, so the Idol grid doesn't leak into it), assist tools, model3d.ts (model3dRequest, modeOf, model3dView, isIdol), the model3d-studio page, model3d-finish.ts (modelToFinish picks the GLB with no role, and the turntable replaces the role-turntable video), gpu/tools.ts STUDIO_ROWS. Graph: diffed the hand-built image-to-mesh-idol against image-to-splat-idol. The only differences are 92 SplatToFile3D replaced by 93 SplatToMesh and the SaveGLB/SaveVideo prefixes. Every library graph node and required input was checked against the live object_info at 127.0.0.1:8188. All 24 classes are present, no input is missing, SplatToMesh's values are within range and match its defaults (384, 5, 0, 0.4, 500, 0.02, 2.0), and SaveGLB takes MESH. The only combo mismatches are model file names, which aren't on the CPU box. In the ComfyUI source, SplatToMesh returns pack_variable_mesh_batch(colors, unlit=True). The manifest bindings match the graph node ids, and the validation-state sha256 matches the library file. requirements.json has the workflow with Idol's 5 files and no packs. object_info.subset only gains SplatToMesh. The licence string matches image-to-splat-idol's, with the DINOv3 notice. I didn't re-run /prompt validation (validate-workflows writes manifest and state files, and I don't edit as a reviewer). Tests: 263 passed across 10 files (idol-mesh, account-idol, hi3d-refine, idol, model3d, comfy-library-4, licences, gpu-requirements, comfy-provider, model3d-finish), and 637 passed across 22 files (canvas*, catalog, cloud-catalog*, comfy-library-7/notes, command-palette, demo-ops, eval-harness, gpu-api, gpu-readiness, open-engine, outputs, public-signup*, hosted-runs, assist-tools, account-tenant). pnpm eval:validate passes (mesh.json, 4 cases), and the demo fixtures exist. eslint on the changed source and test files is clean. No hot or off-limits files were touched, and the commit messages are neutral. Public sign-up: accounts get 403 own-gpu-tool for oss-idol-mesh (test), and there is no new route or server file path, so tenant, account-inputs and ESTIMATES don't apply. No Higgsfield code or media, and no new model pins or packs. I didn't run tsc or a browser check myself.",
- "verdict": "Approve. Nothing blocks it. The graph is core-only and its bindings match the manifest and the live server's node schemas. The model is open-engine only and comes after Pixal3D, TRELLIS.2 and Hunyuan3D 2.1, with its licence and pre-flight row. Hi3D's resolution check is unchanged for Hi3D, accounts stay closed, and the targeted tests pass. The remaining items are minor: From an image doesn't expose Idol's photo crop for the mesh model, and the splat orbit stands in as the turntable when the server can't render one. There are two copy and semantics nits. Mesh quality on a GPU is unmeasured, which the eval suite is there to settle."
- },
- "fix": {
- "applied": [
- "Minor (model3d-studio.tsx:415, confirmed): From an image now shows Idol's Best / Quick look and 'It's a photo (looser crop)' settings for oss-idol-mesh on the open engine, next to Refine detail · Hi3D (still offered). model3dRequest sends idolExtra('open', quality, photoCrop) as params.extra for oss-idol-mesh, so uploads get Idol's photo crop through the existing idolPhotoFor logic. New IDOL_MESH_MODEL / isIdolMesh in src/lib/av/model3d.ts. The Hi3D refine step still drops these extras (createRefinedModel only passes its own meshResolution). Tests: the request carries the presets and crop, prepareWorkflow binds them to 88:6, 88:55 and 88:104, other models get no extras, and withRefine keeps them with hi3dRefine.",
- "Minor (graph turntable is the splat orbit, confirmed): model3dView no longer uses the graph's role-turntable video as the turntable for oss-idol-mesh unless the mesh's finish.turntable is 'done', meaning the server rendered the mesh's own turntable and replaced the orbit. Without that, the card shows the poster or photo and the browser can record a turntable, as accounts already do. The demo's meta.turntable clip is unaffected. Other models' turntables are unchanged (tested with oss-trellis2). Tests cover no finish, a 'skipped' finish and a 'done' finish.",
- "Nit (From an image hint, confirmed): the hero subtitle now reads 'a 3D model (.glb)' instead of 'a textured 3D model (.glb)', so it no longer contradicts Idol quick mesh's 'no textures' or Hunyuan3D 2.1's shape-only result.",
- "Nit (Assist mesh_resolution, confirmed): the tool field's description now says it is Hi3D's refine step on oss-idol-mesh too, that colours are lost, and to leave it out to keep the vertex colours. Behaviour is unchanged. It still can't set the SplatToMesh grid (see rejected)."
- ],
- "rejected": [
- "Letting Assist set Idol's SplatToMesh grid through mesh_resolution: the field only takes Hi3D's 512/1024/1536 and means the refine chain on every image-to-3D model, so giving it a second meaning on one model would make it harder to read. Canvas already has the 'Mesh detail' slider (meshResolution 128-768). The description now makes this clear instead."
- ],
- "checks": "Confirmed each finding in the code first: isIdol only matches oss-idol and idol-3d; model3dView fell back to the role-turntable video; the HINTS string; the asRequest mapping. Targeted Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1): idol-mesh, hi3d-refine, model3d, account-idol, idol, model3d-finish: 117 passed. Then av-tools, assist-runtime, assist-skill-tools, assist-model-pick, comfy-provider, licences, canvas, public-signup, public-signup-tools: 273 passed. npx next typegen, then NODE_OPTIONS=--max-old-space-size=8192 pnpm typecheck: exit 0. pnpm lint: exit 0, 0 errors, the base's 5 warnings. The full suite and the merge of claude/fuobe-parity-4 were left to the coordinator, as instructed. No browser check this stage. No ComfyUI run needed (no graph change). Committed 857891db on o/idol-7, not pushed. The tests/node_modules Vite cache and .next were removed and git status is clean. Coordinator after the fix: origin/claude/fuobe-parity-4 already contained in o/idol-7 (no merge needed); npx next typegen, typecheck, lint exit 0; full Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 5491 passed, 6 failed, 4 skipped; the 6 failures are only the known pre-existing ones (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack).",
- "finalSummary": "Idol 3D quick mesh (oss-idol-mesh) is built, open engine only. Graph image-to-mesh-idol is idol-1's Idol graph with core SplatToMesh (384 grid, min_opacity 0.02) and SaveGLB, keeping the orbit video. It is /prompt-validated on the shared CPU ComfyUI 0.41.0 (verified). It needs no GPU run here and has none. In From an image it comes after Pixal3D, TRELLIS.2 and Hunyuan3D 2.1. After this fix it also takes Idol's Best / Quick look and photo crop (built and unit-tested; mesh quality is unmeasured and needs an 8 GB+ GPU run of the 'mesh' eval suite). Its result is a vertex-coloured GLB that opens in model-viewer, goes to Rig & animate (Meshy rigging on the cloud, as for any GLB) and offers Refine this mesh / Refine detail · Hi3D with the source picture (Hi3D needs an Ampere+ CUDA GPU and drops the colours). The card's turntable is the server's render of the mesh when Chromium and ffmpeg are present. Otherwise it shows the poster and offers in-browser recording, never the splat orbit. Cloud engine: there is no route, because fal's speridlabs/idol returns only a splat. The picker lists it under the open engine only, and its engine note says it runs on your GPU. Guests browse the page read-only. Accounts get 403 own-gpu-tool for it (tested), like every 3D model for now. It has a licence row (Apache-2.0, Built with DINOv3) and a row on the GPU pre-flight board.",
- "left": [
- "A GPU run (8 GB+): pnpm eval:run --suite mesh --engine open with pictures in local/mesh/, on a server with Chromium and ffmpeg. Then inspect the GLBs (holes, double walls, floaters, smeared colour) before the model ships. Mesh quality, SplatToMesh's memory peak at 384/512 and run time are unmeasured.",
- "Whether Hi3D's refine works well on an Idol mesh is unverified (CUDA/Ampere only). Its result drops the vertex colours, as it does for every model.",
- "The output has no 'mesh' role, unlike the brief: ManifestOutput has no such role, and modelToFinish only finishes a GLB with no role.",
- "Assist can't set Idol's mesh grid (mesh_resolution stays Hi3D's refine). Canvas's Mesh detail slider can.",
- "Full Vitest suite and the merge of claude/fuobe-parity-4: left to the coordinator.",
- "No browser check of the new Idol settings in From an image this stage. Worth one in demo mode at 1440/390 px, light and dark."
- ]
- },
- "merge": {
- "merged": [
- "o/idol-7"
- ],
- "notMerged": [],
- "conflicts": "README rows, library.spec SPEC entries, model3d-studio (base's unified links + quick mesh), gpu/tools rows, manifest union; requirements regenerated",
- "checks": "batch of 6 (dbs-d9, idol-7, w2s-w5, w2s-w6, w2s-w7, idol-4): typecheck 0, lint 0, vitest 5907 passed, 8 failed (6 main known + preset-covers and reuse-pack-pin load timeouts, 13/13 alone); each merge but idol-4 checked by an independent verifier (idol-4 merged by hand after: one conflict, its tests 99/99); W5/W6/W7 joined by follow-ups 642a167e, bef8778e, 22378b4b, 739a0c1d",
- "pushed": true,
- "head": "148f2459"
- }
-}
diff --git a/docs/handoff/reports/idol-8.json b/docs/handoff/reports/idol-8.json
deleted file mode 100644
index 4a8e5faa..00000000
--- a/docs/handoff/reports/idol-8.json
+++ /dev/null
@@ -1,123 +0,0 @@
-{
- "key": "idol-8",
- "impl": {
- "branch": "o/idol-8 (worktree /home/user/wt/o-idol-8, cut from claude/fuobe-parity-4 @ 64900624; 5 signed commits, not pushed)",
- "summary": "Idol 3D can now make the other sides of an object from one picture. A new graph, image-to-views-idol, renders Idol's pruned splat from IdolCamera's predicted camera four times, 90 degrees apart: index 0 is the front (the input view), then the object's left, back and right. A request asks for the views with params.extra.idolViews on oss-idol. The variant resolver (and so the GPU pre-flight gate) then swaps in the view graph. The provider names each picture's side, and the run says plainly when the ComfyUI lacks ComfyUI-Idol or the pack is switched off in Settings. Demo mode answers with four labelled pictures. Image to 3D -> From several images, on your GPU with only the front filled, offers 'Make the other sides from the front (Idol 3D)', which fills the empty left, back and right slots for oss-trellis2-multi. A new character or prop element offers 'Add side and back views'. Both show the price first and say the views are renders of a 3D guess and can look soft, and the note stays once the views are in. Neither shows for guests or accounts, on a paid-APIs-only install, or with Idol 3D switched off. The orbit direction was checked: an asymmetric splat rendered through ComfyUI 0.41.0's own RenderSplat code confirmed that frames +4 puts the object's left at index 1. The shared server in this container had ComfyUI-Idol at the pin (put there by the repo's install-comfyui.sh), and the /prompt check of image-to-views-idol passed. No GPU run.",
- "built": [
- "scripts/comfy/hand-built/image-to-views-idol.json: image-to-splat-idol-clean up to the pruned splat (99, 88:35, 88:110 IdolPreprocessImage, 88:24, 88:6, 88:55, 88:111 IdolPruneSplat, 88:112 IdolCamera, same ids and values). It drops the splat file, the orbit video, the still and the count (41, 42, 51, 75, 79, 92, 93, 94, 88:113). New: 88:120 RenderSplat {splat [88:111,0], camera_info [88:112,0], frames +4, 1024x1024, opacity_threshold 0.05, background #FFFFFF} and 96 SaveImage 'fuobe/idol-views', one batch of four.",
- "library.spec.mjs entry 'image-to-views-idol' (capability splat, packs ['ComfyUI-Idol'], the clean graph's bindings without the file and orbit keys, output 96 image role 'tiles', the defaults, vramGb 8, the clean graph's licence, notes with the side order and the sign check). npm run build added only that entry: the same 5 models and sizes, no \\u escapes. requirements.json lists it with the pack's 3 classes (packs.json and model-pins.json needed nothing new). scripts/comfy/README.md has a row.",
- "src/lib/av/idol-views.ts (pure): IDOL_VIEWS_WORKFLOW, IDOL_VIEWS_PARAM 'idolViews', IDOL_VIEWS_FEATURE 'image-to-3d-views-step' (a helper job kept out of the Library), IDOL_VIEW_ORDER = VIEW_SIDES with the sign reasoning, sideOfIndex, idolViewMeta, idolViewsRequest (oss-idol, op splat, Best settings, the photo crop for uploads), wantsIdolViews, idolViewsGraph, idolViewsOf (meta.side, else meta.index, else order), canMakeOtherSides (only the front filled), fillOtherSides (never replaces a slot already filled), elementViews, IDOL_VIEWS_NOTE, IDOL_VIEWS_NEEDS_PACK.",
- "src/lib/comfy-variants.ts resolveWorkflowId ends with idolViewsGraph, so the GPU pre-flight gate checks the view graph's pack for such a run. src/server/providers/comfyui.ts: prepareWorkflow refuses the view graph with 'Making the other sides needs the ComfyUI-Idol nodes on your ComfyUI' when idolPack() is false. When idolPack() is unknown it lets the run go. It drops idolViews, applies idolGraphValues to the view graph too, and forgets the pack answer when /prompt refuses it. collectOutputs adds meta.index and meta.side to the view batch.",
- "src/server/providers/mock.ts: a splat run with idolViews returns four demo SVGs with index, side and role tiles. Ordinary splat runs are unchanged.",
- "src/server/gpu/tools.ts: StudioRowDef.kind (optional; a workflow row's kind was always 'video'). New board row '/image-to-3d?mode=multi', 'Other sides from one picture' (Images, kind image, workflows [image-to-views-idol]).",
- "UI: src/components/model3d/other-sides.tsx. useOtherSidesOffered() is true only when the viewer isn't a visitor, the engine mode isn't 'cloud' and oss-idol is offered on the open engine. OtherSides is the button: it shows the price, the note, a spinner while working and the run's error; it watches the run through useGenerations and hands the views over once. model3d-studio.tsx shows it in From several images on the open engine with only the front filled, keeps it while a run is going, and fills the empty slots as 'generation' pictures. A 'Made by Idol 3D: rendered from a 3D guess...' note stays while those pictures are in. elements-view.tsx: character and prop only, from the first photo, when there's room for 3 more. It adds the left, back and right views once per dialog, with a note that stays.",
- "scripts/eval/cases/idol-views.json: a new suite. idol-3's splat suite doesn't exist yet, so this one stands alone and is meant to join it. It has 6 cases from local/idol-views/: figurine, generated character, a consenting person's photo, product, a mug with its handle on its own left (the side check) and glass. Variants: best (the candidate) and quick. Metrics: identity, clip, aesthetic. scripts/eval/README.md has its row and the local inputs. It validates and expands (24 open jobs, 12 demo)."
- ],
- "tests": [
- "New tests/idol-views.test.ts (19 tests). Spec entry and pack; manifest bindings, outputs, defaults, models and licence; requirements index; graph wiring (identical to the clean graph up to the pruned splat, RenderSplat +4 from IdolCamera, one SaveImage); index -> side; collectOutputs naming the batch; idolViewsOf. resolveWorkflowId swaps only when asked and when the library has the graph. prepareWorkflow: Best settings, photo crop -> real, a generated picture -> synthetic; refused without the pack, run when unknown; plain Idol runs unchanged. comfyProvider.submit: the view graph sent with the pack; refused before /prompt with the pack switched off in Settings. The request is a helper feature. The button only with the front alone. Slot filling that never replaces a brought photo. The chain into oss-trellis2-multi (images in VIEW_SIDES order, extra.views named; real photos unchanged). Element views. The demo's four labelled pictures. The board row.",
- "tests/account-idol.test.ts: an account's idolViewsRequest through POST /api/generations answers 403 own-gpu-tool and nothing reaches its GPU. tests/comfy-library-4.test.ts: image-to-views-idol added to the exact unvalidated list (the one allowed edit).",
- "Targeted runs pass. Idol, model3d, comfy library, licences, model access, GPU requirements, readiness and API, connect board, public-signup and public-signup-tools, eval-harness: 22 files, 392 tests, plus 61 and 45 more. Every test file that uses resolveWorkflowId, demoOutputs, studioTool or STUDIO_ROWS (24 files, 500 tests) passes except the known tests/comfy-reuse failure. tsc --noEmit (6 GB heap, after next typegen) is clean. eslint on the changed files: 0 errors, 1 warning that was already there (WAN_NEG_EN).",
- "Orbit direction: a script imported ComfyUI 0.41.0's nodes_gaussian_splat in its own venv (read-only, nothing installed). It rendered a splat with coloured blobs on the object's left, right, front and back from three input cameras (yaw 0, 35 and -70). With frames +4, index 1 shows the front blob at the image's left and the back blob at its right, which is the object's left side, and index 2 is the back. With -4 the order flips. IdolCamera's camera.py (read) uses the same three.js Y-up world and lookAt, so the result holds for its camera.",
- "ComfyUI (shared CPU server 0.41.0, not restarted, nothing installed by me): npm run build validated the graph. node validate-workflows.mjs image-to-views-idol --shared passed. GET /object_info/IdolCamera answers, and ComfyUI-Idol sits at 4d3a4f67 in custom_nodes, put there by this container's setup (install-comfyui.sh NODES). The validator rewrote validation-state.json and object_info.subset.json, both hot files. I reverted both and rebuilt so the manifest says validated false, as idol-2 did.",
- "Browser: tests/e2e/idol-views.mjs, FUOBE_DEMO_MODE=on, pnpm dev -p 3481, Playwright at 1440 and 390 px in light and dark, all four pass. Checked: no button before the front; button, price and note once the front is in; pressing it fills left, back and right (4 of 4, 'Make it 3D' ready, the note stays); a side the person brought hides the button; the cloud engine hides it; Elements -> New element -> Character with one photo -> 'Add side and back views' adds three pictures, once, with the note. No sideways scroll, no page or console errors. Screenshots looked right. The server was stopped, .next and the data dir deleted, and typegen re-run."
- ],
- "left": [
- "Owner step: on a GPU ComfyUI with ComfyUI-Idol at 4d3a4f67 and the Idol weights, run image-to-views-idol and look at the four views. Then mark it validated, which the integrator can do by rebuilding validation-state; the /prompt check already passed on this container's CPU server, which had the pack. No real run was made: no GPU, no weights.",
- "EVAL FIRST is not done. The idol-views suite is written and validates, but it needs your pictures in scripts/eval/local/idol-views/ and a GPU. Look at every case's sheets, the person.png case above all, and the mug side check (view 1 must show the handle) before you rely on the buttons for characters. Nothing here gates the buttons on that result.",
- "tests/comfy-library-4.test.ts: I added 'image-to-views-idol' to its exact list of unvalidated ids (the one allowed edit).",
- "Engine: Elements has no engine switch, so its button shows on an install that runs open models whatever the app's engine switch says, and its price line says what the run costs. From several images shows the button only on the open engine.",
- "On someone's computer (the Fuobe tab relay) the provider can't tell whether the pack is there, so the run goes ahead and fails with ComfyUI's missing-node message if it isn't. Accounts can't run 3D models anyway.",
- "The views come back on white at 1024 px. TRELLIS.2 multi-view cuts the background out itself. The studio's grey (#848484) was the other option in the brief; switching would need a binding key.",
- "A run's helper generation (feature image-to-3d-views-step) stays in the database like other '-step' jobs. The element and the slots point at its files."
- ],
- "docsNotes": [
- "STATUS / FEATURES: Image to 3D -> From several images, on your GPU: with only the front in, 'Make the other sides from the front (Idol 3D)' renders the left, back and right from an Idol 3D splat of the front (needs the ComfyUI-Idol nodes) and fills the slots for TRELLIS.2 multi-view. Elements: a new character or product with a photo offers 'Add side and back views'. The views are renders of a 3D guess and can look soft; open engine only (Idol's fal endpoint has no views).",
- "ARCHITECTURE: a request asks for Idol's views with params.extra.idolViews on oss-idol (op splat). resolveWorkflowId swaps image-to-splat-idol to image-to-views-idol, which needs ComfyUI-Idol; there is no core fallback. Outputs carry meta.index 0-3 and meta.side front/left/back/right. RenderSplat's frames +4 turns toward the object's left. The GPU board has an 'Other sides from one picture' row.",
- "Brief out of date: (1) 'VERIFY HERE: the shared server lacks ComfyUI-Idol'. Since idol-2, install-comfyui.sh installs it at the pin, so this container's fresh CPU server had it and the /prompt check passed. (2) CLOUD RULE 'Idol is not hosted': fal hosts speridlabs/idol since idol-1, but it returns a splat, not views, so this feature stays open only. (3) SIDES_HINT is at src/lib/av/model3d.ts ~L219, not L80-88. (4) 'Add cases to idol-3's suite': idol-3 isn't built (no scripts/eval/cases/splat.json), so the cases are their own idol-views suite. (5) nodes_gaussian_splat.py L1004-1006 is right for 0.41.0 (fc04da91).",
- "Plan items already there from earlier packages: the ComfyUI-Idol pin, PACK_CLASSES, packs.json and NODE_PACKS licence row (idol-2); IdolCamera already wired in image-to-splat-idol-clean (88:112); comfyHasClass and the Settings pack switch (idol-2); VIEW_SIDES, SIDE_LABELS and SIDES_HINT, and model3dRequest's multi request with extra.views for oss-trellis2-multi; the 3D refusal for accounts (403 own-gpu-tool)."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "high",
- "title": "tests/comfy-library-notes.test.ts fails: the new graph's public notes say 'untested'",
- "where": "scripts/comfy/library.spec.mjs (image-to-views-idol notes) and so workflows/comfyui/manifest.json",
- "detail": "The notes end with 'The views are renders of a 3D guess: soft, and untested on realistic people.' The library notes test bans /\\b(untested|inferred|plausible|unverified)\\b/i because notes are shown word for word as public notes. Two tests fail: 'image-to-views-idol reads as a public note' and 'the spec's notes are as clean as the manifest's'. This test is on the base and passes there (the base has no image-to-views-idol entry), so this is a new failure, not one of the known ones. The report says the comfy library tests pass, but this file was not among those run.",
- "verified": "npx vitest run tests/comfy-library-notes.test.ts gives 2 failed out of 244, with the AssertionError on the 'untested' match.",
- "fix": "Reword the notes without 'untested' (for example 'they can be soft; check people's faces before use'), then run npm run build so the manifest matches."
- },
- {
- "severity": "low",
- "title": "A view run is lost if its button goes away mid-run",
- "where": "src/components/model3d/other-sides.tsx, model3d-studio.tsx, elements-view.tsx",
- "detail": "OtherSides holds runId in its own state and hands the views over only while it is mounted. In Image to 3D, switching away from From several images (or changing the engine) unmounts it, and the GPU run finishes with nothing handed over. In Elements the same happens when the dialog closes or the kind changes to location or style. Coming back offers the button again, so a second paid or GPU run gets started. Also, if the front photo is replaced mid-run, the views of the old front fill the slots next to the new front. The pictures stay in the helper job, so nothing is corrupted.",
- "verified": "Traced from the code: runId is local state, the parent's onBusy cleanup sets busy to false, and nothing re-attaches to a running IDOL_VIEWS_FEATURE job."
- },
- {
- "severity": "low",
- "title": "Elements offers the button when editing an existing element too, not only for a new one",
- "where": "src/components/elements-view.tsx offerSides",
- "detail": "The report says 'A new character or prop element offers...'. offerSides has no !element check, so editing a saved character or prop with photos offers it again, including one whose views were made in an earlier session. This is harmless and arguably useful, but it differs from the report and is not covered by the e2e test."
- },
- {
- "severity": "info",
- "title": "The asymmetric orbit-direction check isn't kept as a test",
- "where": "tests/idol-views.test.ts",
- "detail": "The unit tests only assert frames: 4 and the index -> side table. The asymmetric-splat render that set the sign was an ad-hoc script and is not committed. I checked the sign by hand: _orbit_camera_info_yaw rotates the camera about world +Y with Ry = [[c,0,s],[0,1,0],[-s,0,c]]. That takes a camera at +Z to +X, the viewer's right, which is the object's left. IdolCamera's camera.py puts the camera in three.js Y-up world, aimed at the object at the origin, and the splat frame map (x,-y,-z) is a rotation, not a mirror. So +4 giving front, left, back, right is correct."
- }
- ],
- "checks": [
- "Read the full diff claude/fuobe-parity-4...o/idol-8 (5 commits; the worktree is clean and nothing was edited).",
- "Graph: workflows/comfyui/image-to-views-idol.json matches image-to-splat-idol-clean node for node up to the pruned splat (no changed nodes; it drops 41, 42, 51, 75, 79, 88:113, 92, 93 and 94). It adds 88:120 RenderSplat (splat 88:111, camera_info 88:112 IdolCamera, frames 4, 1024x1024, opacity 0.05, #FFFFFF) and 96 SaveImage. Every input was checked against the live /object_info/RenderSplat on the restarted CPU server (0.41.0 fc04da91). IdolCamera answers there and ComfyUI-Idol is at 4d3a4f6. SaveImage's prefix is 'fuobe/image-to-views-idol', not 'fuobe/idol-views' as the report says (no effect).",
- "Orbit sign checked independently from ComfyUI's _orbit_camera_info_yaw and ComfyUI-Idol's camera.py (Y-up, lookAt the origin): +4 makes index 1 the object's left, which matches SIDES_HINT and VIEW_SIDES.",
- "Manifest and spec bindings match the graph's node ids. The licence is recorded as data (same weights and pack as the clean graph). requirements.json has the new entry with the pack's three classes. validation-state.json is untouched, and the manifest entry carries no validated flag. The tests/comfy-library-4 edit is only the allowed id-list addition.",
- "resolveWorkflowId -> idolViewsGraph swaps core or clean to the view graph only when idolViews is true and the graph exists, so the GPU pre-flight gate sees the view graph. prepareWorkflow refuses with a plain owner-facing message when idolPack() is false, drops idolViews, and applies idolGraphValues. collectOutputs adds meta index and side only for this manifest's 'tiles' output. The 'tiles' role is used elsewhere only by turnaround.ts and doesn't collide. modelToFinish ignores op splat, so the image outputs don't hit the GLB finish.",
- "Public sign-up: the account test (POST idolViewsRequest gives 403 own-gpu-tool, nothing sent to /prompt) passes. The UI hides the button for visitors, on a cloud-only install, and when oss-idol is off. Previews use the existing useRunPreview path. No new routes.",
- "Helper feature 'image-to-3d-views-step' ends with -step, so it stays out of the Library. useGenerations with an explicit features filter still lists it (the listGenerations and feedMatches logic).",
- "STUDIO_ROWS: the new '/image-to-3d?mode=multi' row with kind image. Tool.kind is an optional string, so the change is type-safe.",
- "Eval suite: the cases set photoCrop for photos, and the variants match IDOL_PRESETS best and quick. Local inputs are gitignored (/scripts/eval/local/). No media committed.",
- "vitest: idol-views, account-idol, comfy-library-4/7, gpu-requirements, idol, idol-clean, idol-final, model3d, public-signup (passes when run alone; timed out under load), public-signup-tools and open-tools all pass. Across 36 files that touch STUDIO_ROWS, studioTool, resolveWorkflowId, demoOutputs or collectOutputs, and 58 files that read the manifest, requirements, spec or eval cases, the only failures are comfy-library-notes (2, new) and comfy-reuse (known).",
- "npx tsc --noEmit (6 GB) passes clean. eslint on the changed source and test files gives 0 problems.",
- "Browser e2e was not re-run (the report says it covered 1440 and 390 px in light and dark). The UI code uses real buttons with aria-live status text."
- ],
- "verdict": "changes-requested: one blocking issue. The new graph's library notes contain 'untested', so tests/comfy-library-notes.test.ts fails 2 tests (a new failure that the report missed). Reword the notes and rebuild the manifest. Everything else holds up: the graph wiring, the orbit sign (checked independently), the variant swap and pack refusal, the public sign-up refusal, the pre-flight row, typecheck and lint. The other findings are low-severity UX follow-ups."
- },
- "fix": {
- "applied": [
- "HIGH (confirmed: tests/comfy-library-notes.test.ts failed 2 of 244 on 'untested'): image-to-views-idol's notes now end 'The views are renders of a 3D reconstruction and can look soft; faces of real people are the hardest case, so check them before use.' Same text in scripts/comfy/library.spec.mjs and workflows/comfyui/manifest.json (commit 451a60fc). The text was edited in both files directly. A full `npm run build` in scripts/comfy reads the live CPU server and rewrote unrelated entries (selftest-image/video, video-character-swap-h3, about 8k manifest lines), so that output was reverted. The diff is one line in each file. comfy-library-notes, comfy-library-4 and idol-views pass.",
- "LOW (confirmed by reading the code: runId was local state in OtherSides): src/lib/av/idol-views.ts keeps a tab-wide record of view runs, keyed by front picture (viewRunFor, rememberViewRun, forgetViewRun). OtherSides in src/components/model3d/other-sides.tsx reads its run from that record instead of local state. If the button unmounts mid-run (mode or engine switch in Image to 3D, dialog closed or kind changed in Elements) and comes back for the same picture, it shows the spinner again and hands the views over when they are ready. It no longer offers a second paid or GPU run. Because a run belongs to its picture, a replaced front never gets the old front's views. After hand-over the run is forgotten, and an older run's hand-over never clears a newer one. New unit test in tests/idol-views.test.ts (commit 18816166)."
- ],
- "rejected": [
- "LOW 'Elements offers the button when editing an existing element': kept on purpose. The brief says 'Elements (character and product references): Add side and back views' and does not limit it to new elements. Adding views to a saved character or product is useful. The button already needs room for 3 more photos, so an element that already has its added views (4 or more photos) is not offered it again. This is visible to the owner only (hidden for guests, accounts, paid-APIs-only installs and when Idol 3D is off). The impl report's wording ('a new character or prop') was too narrow; the behaviour stays.",
- "INFO 'the asymmetric orbit check isn't kept as a test': no change. The reviewer checked the sign independently from ComfyUI's _orbit_camera_info_yaw and IdolCamera's camera.py. The unit tests pin frames +4 and the index-to-side table. A committed render test would need ComfyUI's Python modules, which the vitest suite doesn't have."
- ],
- "checks": [
- "Worktree /home/user/wt/o-idol-8 on o/idol-8: only this package's 5 commits on claude/fuobe-parity-4, and the base is an ancestor (no merge needed). pnpm install --frozen-lockfile --prefer-offline and npx next typegen: ok.",
- "pnpm typecheck (6 GB heap): exit 0. pnpm lint: exit 0 (0 errors, 5 existing warnings).",
- "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: 360 of 367 files pass, 5807 tests pass, 8 fail. The failures are the known ones from main: comfy-reuse (1), dop-originals (1), preset-featured (1), soul-runs (2), split-soundtrack (1), plus picker-covers and preset-covers, which timed out under load and pass alone (36 of 36). comfy-library-notes now passes.",
- "Browser: FUOBE_DEMO_MODE=on pnpm dev -p 3481 with a scratch data dir, then node tests/e2e/idol-views.mjs at 1440 and 390 px, light and dark: all 4 pass with no console or page errors. The dev server was stopped by its own pids, and .next and the scratch data were deleted.",
- "CPU ComfyUI at 127.0.0.1:8188 was not restarted. validation-state.json and the other hot files are untouched. git status is clean, and nothing was pushed."
- ],
- "finalSummary": "idol-8 lets Idol 3D make the other sides of an object from one picture. image-to-views-idol is the clean Idol graph up to the pruned splat, then RenderSplat from IdolCamera with frames +4 and SaveImage. It returns front, left, back and right, each with meta.index and meta.side. Open engine (your ComfyUI): built and unit-tested, and the /prompt check passed on this container's CPU server, which has ComfyUI-Idol at the pin. Not run on a GPU: it needs a GPU and Idol's weights. Without the pack, the run is refused with a plain message. Image to 3D -> From several images, on your GPU with only the front in, offers 'Make the other sides from the front (Idol 3D)' and fills left, back and right for TRELLIS.2 multi-view. Elements offers 'Add side and back views' for characters and products. Both show the price and say the views are soft renders of a 3D guess. The run is now kept for its picture, so leaving and coming back mid-run picks it up instead of paying twice. Cloud engine: no route. Idol's fal endpoint returns a splat, not views, so the button is hidden on the cloud engine and on paid-APIs-only installs. Demo mode returns four labelled placeholders. Public sign-up: guests don't see the button. Accounts don't either, and POST /api/generations answers 403 own-gpu-tool for their view request (tested), as for every 3D model. Fixed in this stage: the library notes no longer say 'untested' (comfy-library-notes passes), and a view run survives its button unmounting.",
- "left": [
- "Owner step: on a GPU ComfyUI with ComfyUI-Idol at 4d3a4f67 and Idol's weights, run image-to-views-idol, look at the four views, then mark it validated (rebuild validation-state).",
- "EVAL FIRST is not done: the idol-views suite needs the owner's pictures in scripts/eval/local/idol-views/ and a GPU. Check the person.png case and the mug side check (view 1 must show the handle) before relying on the buttons for characters.",
- "tests/comfy-library-4.test.ts: 'image-to-views-idol' was added to its exact list of unvalidated ids (the one allowed edit, made in impl).",
- "A view run is kept for the browser tab only. After a page reload mid-run, the button is offered again (the earlier run's pictures stay in its helper job).",
- "scripts/comfy `npm run build` on this container rewrites unrelated entries from the live CPU server, so the note fix was applied to the spec and the manifest by hand. A later full rebuild on the integrator's server should give the same text."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/idol-8"
- ],
- "notMerged": [],
- "conflicts": "README rows, library.spec entries rebuilt in order, gpu/tools rows, mock splat (views + openSplat), account-idol comment, manifest union; requirements regenerated",
- "checks": "batch of 3 (idol-8, idol-3, nm10-hy-nomas-world): typecheck 0, lint 0, vitest 5972 passed, 6 failed (main known); idol-8 and hy-nomas each checked by an independent verifier; idol-3 merged by hand (README rows) with follow-up fb8e099e (demo splat now comes with idol-4's turntable)",
- "pushed": true,
- "head": "b97c9762"
- }
-}
diff --git a/docs/handoff/reports/idol-9.json b/docs/handoff/reports/idol-9.json
deleted file mode 100644
index d92107ad..00000000
--- a/docs/handoff/reports/idol-9.json
+++ /dev/null
@@ -1,156 +0,0 @@
-{
- "key": "idol-9",
- "impl": {
- "branch": "o/idol-9",
- "summary": "Cinema Studio's 3D scene gets props. 'Add a prop' places a splat in the MoGe scene or point cloud: either an existing Idol 3D or TripoSplat result from the Library (on either engine, cloud TripoSplat .ply included) or a picture made into one with Idol 3D (oss-idol) on your GPU. Idol 4's Spark renderer draws the props inside the scene's own three.js graph, depth-tested and sorted with the mesh, and they have move, turn and size handles. Because the props are part of the scene's render, captures, blockouts and the open Fly path render that guides Uni3C all show them. A pixel test on the recorded path confirms this. Commits: 4a8090b8 (already pushed) and 9cb3318b (not pushed).",
- "built": [
- "src/lib/scene-props.ts (new, pure): SceneProp and SceneState types; propCandidate (a finished splat result from the Library); placeProp (0.7 x pivotDepth ahead of the camera, longest side 0.35 x pivotDepth, its +z facing the camera, later props set off to the side, Idol 3D's starting haze cut-off 0.05 from idol-4); bringToCamera, turnOver, sizeRange, wrapDeg; serializeSceneState and parseSceneState (bad entries are dropped, values stay finite and in range, at most MAX_PROPS = 4); sceneStateKey; propMakerBlocker (the same rule as make3dOffered, with plain-language reasons for visitors, Paid APIs only, Idol 3D switched off, and no GPU).",
- "src/components/model3d/splat-engine.ts: SplatEngine.load now uses two shared helpers, fetchSplat and buildSplatMesh (behaviour unchanged). New SceneSplats class: one SparkRenderer with depthWrite:true and minAlpha 1/16, so the scene's post pass doesn't treat splats as holes. Each prop sits in a group with the splat centred and fitted to size 1. It also has a live per-prop cut-off and settle(), which waits for Spark's sort for a given camera. Spark is still imported only by this file.",
- "src/components/cinema/scene-engine.ts: addProp, updateProp, removeProp, pickProp and handleActive. Spark comes in through a dynamic import of ../model3d/splat-engine when the first prop is added. The handle is three's TransformControls, drawn over the finished frame on screen only, so it never appears in captures or path renders. Sizes stay uniform, and the handle reports changes through onPropChange. recordPath sorts the splats for each frame's camera before drawing it. A new readPixels unbinds PIXEL_PACK_BUFFER before a synchronous read: Spark's async readback had left one bound, which made frame 0 of the path render black (the e2e pixel test caught this). dispose() cleans up the handle and the splats.",
- "src/components/cinema/video-encode.ts: the draw callbacks may return a promise, so a frame can wait for the sort. The blockout builder's synchronous callers still work.",
- "src/components/cinema/scene-props.tsx (new): AddPropDialog has two sections. 'From your Library' is a grid of splat results. 'From a picture' has a MediaSlot, Best / Quick look, and 'Make the prop · <price>', priced through the existing POST /api/generations?preview=1 (useRunPreview / priceLine); it uses the photo crop for uploads. MakingWatch places the run's splat in the scene when it lands. PropsPanel lists the props and has the Move / Turn / Size handle modes, Size (log) and Turn sliders, 'In front of the camera', 'Turn over' and Remove, plus a note on what each engine films.",
- "src/components/cinema/scene-viewer.tsx: the props state is kept per scene take in localStorage (fuobe.cinema.scene.<generationId>) and synced into the engine. Drag-to-look waits while the handle has the pointer. The header shows '· N props'. The desktop aside has a Props section; phones get a Props button with a count badge and a Props sheet. The note under the props says plainly: on the cloud, filming follows the still itself, so props don't show (cloud path = H3 Max on the still); WorldCast films from depth, so props don't show there either; open Uni3C shows them.",
- "No server, route, DB, graph, pack or manifest changes. Making a prop goes through the existing POST /api/generations with model3dRequest (oss-idol). Accounts and guests get the same server refusals as before (403 own-gpu-tool for 3D), and the UI shows propMakerBlocker's visitor copy."
- ],
- "tests": [
- "tests/scene-props.test.ts (new, 16 tests): Library candidates (spz and ply, never GLB, unfinished or failed runs); placement and facing; second and third props set to the side; bring to camera; turn over and angle wrapping; size range; scene state round trip with a moved, turned and sized prop; malformed entries dropped (including a javascript: URL, NaN and a GLB); clamping and MAX_PROPS; propMakerBlocker for owner, demo, own GPU, visitor, cloud-only, Idol off and no GPU, with a check that visitor copy has no jargon; source checks that recordPath settles the splats, that the handle is drawn only on screen, that splats write depth, and that the single synchronous pixel read unbinds the pack buffer. Passes.",
- "tests/splat-view.test.ts updated: Spark is still imported only by splat-engine.ts, and only through dynamic imports. The engine's users are now splat-viewer.tsx and cinema/scene-engine.ts. Passes.",
- "Regression: tests/cinema-scene, cinema-path, camera-path, scene3d, splat-view, scene-props: 113 passed. Full vitest suite not run (stage rule).",
- "tests/e2e/cinema-props.mjs (new), run against pnpm dev in demo mode on port 3412 with SwiftShader WebGL: all checks passed. At 1440 px dark on the open engine: the path filmed without a prop doesn't fetch Spark; adding the demo Idol 3D splat from the Library fetches Spark and the view changes; dragging the handle moves the prop right; the Size slider sizes it; the path filmed again with the prop has a first frame (832x464) where 13,310 px (3.4%) differ from the plain render, 12,843 of them the splat's violet and 0 in the handle's colours; the prop is still there after a reload. At 1440 px light on cloud: the panel note says the cloud films the still. At 390 px light and dark: the Props sheet and the Add a prop dialog fit the phone, the handle modes and the turn slider work, nothing scrolls sideways, and there were no page or console errors.",
- "npx tsc --noEmit (after next typegen) and eslint on the changed files: clean."
- ],
- "left": [
- "Idol's predicted camera (IdolCamera) does not set the first orientation yet. No graph or route saves its yaw and pitch: image-to-splat-idol-clean uses IdolCamera only to render the preview still, and nothing in the fal idol-3d mapping keeps the camera. Props start facing the camera, with 'Turn over' and the Turn slider to fix them. To use the prediction, the clean graph would need to output IdolCamera's yaw and pitch (for example as a PreviewAny 'report', like the kept-count) into the splat's meta.camera, and placeProp would then read it. That needs a validated graph change, which belongs in its own package.",
- "Props are saved in the viewer's browser storage per scene, not on the server, so they don't follow the user to another device. Saving them with the take, for example in the cinema item's take data, would need a server change and an account-scoped check.",
- "The cloud Fly path (H3 Max camera-controls) and WorldCast film the still or its depth on the server, so they can't include props. The UI says so. Capture (recompose) and Use as blockout do include them on both engines.",
- "Speed: on SwiftShader each frame of a path render with a prop waits for Spark's sort readback, so an 81-frame render took about 3-4 minutes here (without props it takes seconds). Frame time on a real GPU and on a phone is not measured.",
- "Gaussians fainter than minAlpha 1/16 are dropped, so faint edges don't mark holes as seen. That makes props' edges slightly crisper than in the splat viewer. Not tuned on a real Idol splat (needs a GPU run).",
- "Not verified with a real Idol 3D run from a picture: the local ComfyUI is CPU-only with no 3D weights. The demo run (the mock's demo-splat.spz) covers the flow. Clicking a prop in the view to pick it isn't built; props are picked from the list.",
- "The brief's line numbers ('object' layout at L633) predate idol-4 and main's 10-30 work. The '3D model' label is now in the viewer header's ternary. idol-2's IdolCamera exists only inside the clean graph (library.spec.mjs), not as data. /home/user/ext (idol-sdk, ComfyUI-Idol) was missing in this container, so I worked from the research doc."
- ],
- "docsNotes": "docs/ARCHITECTURE.md (Cinema 3D scene): props are splats placed in the scene viewer (src/lib/scene-props.ts pure state; src/components/cinema/scene-props.tsx UI; SceneSplats in src/components/model3d/splat-engine.ts, loaded through a dynamic import from scene-engine.ts when the first prop is added). They write depth so the post pass doesn't treat them as holes, are sorted per frame in recordPath, and their TransformControls handle is drawn on screen only. They are kept per scene in localStorage (fuobe.cinema.scene.<sceneGenerationId>). docs/STATUS.md: idol-9 built; 'Idol's predicted camera sets the first orientation' is still open. FEATURES (docs pass): Cinema 3D scene, 'Add a prop' (from the Library or from a picture with Idol 3D on your GPU); props show in captures, blockouts and open-engine path films, not in cloud path films. docs/research/idol-9.md §9 idol-9 could note: built 2026-11-03; Spark's readRenderTargetPixelsAsync leaves PIXEL_PACK_BUFFER bound, so any synchronous read in the same renderer must unbind it first.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "verdict": "PLAUSIBLE (traced through Spark 2.3.1 and three 0.183.2 source; not reproduced in a browser)",
- "file": "src/components/cinema/scene-engine.ts",
- "line": 739,
- "title": "Path frames with a prop can be drawn with the on-screen camera's sort order",
- "detail": "recordPath's frame() calls splats.settle(path camera), which awaits SparkRenderer.update(). That call's generate() calls setDirty(), and SceneSplats wires onDirty to engine.dirty = true. step() draws the screen whenever dirty is set and does not check `playing`. While the path sort is running (readPause setTimeout, an async GPU readback polled every 4 ms, then the sort worker), the next requestAnimationFrame tick therefore draws the screen with the user's pose. Spark's onBeforeRender (preUpdate: true by default) then calls updateInternal for the screen camera: current becomes the screen's accumulator and sortDirty is set. When the path sort finishes, driveSort() starts a sort for the screen camera straight away. settle()'s second wait loop sees sorting=true and waits for that sort, so the path frame is drawn with ordering sorted by distance from the screen camera. With depthWrite:true, out-of-order Gaussians fail the depth test instead of blending, so the prop looks harsh or patchy in path frames far from the user's pose. That covers the Uni3C guide render and Use as blockout. The race happens on most frames whenever the sort takes longer than a frame, as it does on SwiftShader and on a phone. Each frame also runs a second, wasted sort. The e2e pixel test checks only frame 0, where the path pose is close to the screen pose, so it can't catch this.",
- "fix": "Don't draw the screen while recording: in step(), skip the draw while `playing` (or while a recordPath is active). Another option is to set the SceneSplats' SparkRenderer autoUpdate to false for the length of recordPath, or to make onDirty a no-op while recording. Then add a check on a late path frame, for example that the prop's pixels in the last frame match a still capture taken from that frame's pose."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED (code trace)",
- "file": "src/components/cinema/scene-viewer.tsx",
- "line": 330,
- "title": "A prop made from a picture can be dropped while the toast says it is in the scene",
- "detail": "madeProp() always shows the success toast 'Your prop is in the scene'. placeCandidate() returns early when the engine or info isn't ready (for example while the scene is reloading), and setProps leaves the list unchanged when it already holds MAX_PROPS. The second case can happen because Add a prop is disabled only while the scene is full, not while a prop is being made. In both cases the prop is not added, but setPickedProp(id) still picks an id that doesn't exist and the success toast still shows. The run's splat stays in the Library, so nothing is lost, but the message is wrong.",
- "fix": "Have placeCandidate report whether it placed the prop, and show a 'scene is full' or 'try again from Add a prop' message when it didn't. You could also count `making` towards MAX_PROPS."
- },
- {
- "severity": "low",
- "verdict": "PLAUSIBLE",
- "file": "src/components/cinema/scene-viewer.tsx",
- "line": 140,
- "title": "Props state isn't reloaded when the open take changes without the viewer remounting",
- "detail": "`props` is read from localStorage only in the useState initialiser, but stateKey follows take.generation.id. workspace.tsx renders <SceneViewer take={openScene}> without a key, and setOpenScene(t) can run while a viewer is open (the 'Your 3D scene is ready → Open' toast action). If that happens, the persist effect writes the previous scene's props under the new scene's key, and the new scene shows the old scene's props. Other viewer state has the same pattern already, so the impact is small.",
- "fix": "Add key={openScene.generation.id} on <SceneViewer> in workspace.tsx, or reset props when stateKey changes."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED (code trace)",
- "file": "src/components/cinema/scene-engine.ts",
- "line": 574,
- "title": "Spark can be created on an engine that has already been disposed",
- "detail": "addProp's dynamic-import .then() builds a SceneSplats (which creates a SparkRenderer) and adds it to this.scene without checking this.disposed. The check comes after the await. If the viewer closes while the chunk is loading, a SparkRenderer is created for a disposed engine and never disposed. No sort worker starts, because nothing renders, so this is a small GPU and memory leak.",
- "fix": "Check this.disposed inside .then() before constructing SceneSplats, or dispose it there."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED (code trace)",
- "file": "src/components/cinema/scene-props.tsx",
- "line": 200,
- "title": "Keyboard users can't move a prop to an exact place",
- "detail": "Move uses three's TransformControls, which works only with a pointer. The panel gives keyboard users Size and Turn sliders and 'In front of the camera', so a keyboard user can only place a prop by flying the camera and then bringing the prop to it. The Move / Turn / Size radiogroup also has no arrow-key handling. That matches other radiogroups in the app.",
- "fix": "Optional: add nudge buttons, or arrow keys while the handle mode is Move, or note it as a follow-up."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/components/cinema/scene-props.tsx",
- "line": 128,
- "title": "Price line reads 'Free' before any price is known",
- "detail": "`priceLine(preview.data) ?? \"Free\"` shows 'Free' while the preview is loading, when no picture has been picked, and when the preview request fails. In demo mode the loaded preview says 'Placeholder · nothing is charged', so the label changes once it loads. The Idol run on the open engine is free anyway, so this is only a wording issue.",
- "fix": "Show '…' or no price until the preview has loaded."
- },
- {
- "severity": "info",
- "verdict": "CONFIRMED",
- "file": "src/lib/scene-props.ts",
- "line": 157,
- "title": "The URL check in parseSceneState accepts protocol-relative URLs",
- "detail": "The pattern ^(\\/|https?:\\/\\/) accepts '//host/x.spz'. The data comes only from this origin's own localStorage, so this isn't exploitable. Rejecting '//' would match what the test says it guards against.",
- "fix": "Use ^(\\/(?!\\/)|https?:\\/\\/)."
- }
- ],
- "checks": [
- "Scope: git diff 61d8074e..HEAD (commits 4a8090b8 and 9cb3318b), 9 files. No server, route, DB, graph, pack, manifest, migration or hot-file changes. No Higgsfield code or media, no new model, LoRA or node pack (so no licence data was needed), no analytics.",
- "Public sign-up: no new route. Making a prop goes through the existing POST /api/generations (oss-idol, open engine), and its price through the existing POST /api/generations?preview=1. Both are already covered by PREVIEWS, priceAs and the 403 own-gpu-tool rule for 3D. propMakerBlocker mirrors make3dOffered (viewer, Paid APIs only, Idol off, no GPU), and its visitor copy has no jargon. Library candidates come from useGenerations, so visitors get EMPTY_LISTS. Props are kept only in this browser's localStorage.",
- "Engines: the cloud note says plainly that cloud filming (H3 Max on the still) and WorldCast don't show props, and that the open Uni3C path does. No local capability was removed. A cloud TripoSplat .ply from the Library can be placed, as the brief asks.",
- "Traced Spark 2.3.1 (SparkRenderer.onBeforeRender preUpdate, updateInternal, driveSort, setDirty→onDirty) against SceneEngine.step and recordPath. Result: finding 1.",
- "Verified three 0.183.2 readRenderTargetPixelsAsync: it binds PIXEL_PACK_BUFFER and leaves it bound while it polls, then binds it again before getBufferSubData. readPixels() unbinding it first is correct and safe. The other synchronous read, in blockout-engine.ts, uses its own renderer, so it isn't affected.",
- "Checked the placement maths (forward and right vectors for the YXZ yaw, so +z faces the camera), turnOver, wrapDeg, parseSceneState clamping and MAX_PROPS, TransformControls uniform scale and the Euler read-back, the removal-while-loading path in the props effect, the overlay drawn only for the screen (!out && !shot), and dispose order.",
- "npx vitest run tests/scene-props, splat-view, cinema-scene, cinema-path, camera-path, scene3d, blockout: 7 files, 146 tests passed.",
- "npx next typegen, then npx tsc --noEmit: clean. eslint on the 7 changed source and test files: clean. The worktree was left unchanged (git status clean).",
- "The e2e (tests/e2e/cinema-props.mjs) was not re-run: the path render with a prop takes several minutes on SwiftShader. I relied on the implementer's run. Its pixel check covers only frame 0 (see finding 1)."
- ],
- "verdict": "approve-with-fixes: the feature is complete against the brief, and IdolCamera orientation is reasonably left open. It follows the sign-up and engine rules, and tests and typecheck pass. Fix finding 1 before merge, because the filmed path and the blockout are this package's main output. The low findings are optional."
- },
- "fix": {
- "applied": [
- "Finding 1 (medium, path frames sorted for the on-screen camera): confirmed by reading the code. playPath relies on step() drawing, so `playing` couldn't be reused. A new `recording` flag is set for the whole of recordPath and cleared in its finally, and step() doesn't draw the screen while it is set, so Spark never starts a sort for the screen camera while a path frame waits for its own (scene-engine.ts). Covered by a source test in tests/scene-props.test.ts. tests/e2e/cinema-props.mjs now also compares the LAST frame of the path with and without the prop. Measured: 150,135 px changed (38.9%), 147,574 of them the splat's violet, 0 in the handle's colours. The first frame is unchanged: 13,310 px, 12,843 violet, 0 handle.",
- "Finding 2 (low, success toast when the prop wasn't placed): confirmed. placeCandidate now returns 'placed' | 'not-ready' | 'full'. It checks the count synchronously against propsRef and updates the ref straight away. madeProp shows the success toast only for 'placed'. Otherwise it says the prop is ready in the Library: either remove a prop and add it from Add a prop, or add it from Add a prop. Add a prop counts props being made towards MAX_PROPS (full = props + making), and the full-scene copy says so. Source test added.",
- "Finding 3 (low, props not reloaded when the take changes): confirmed. Added key={openScene.generation.id} on <SceneViewer> in workspace.tsx, so a scene opened in place of another remounts with its own props. Source test added.",
- "Finding 4 (low, Spark created on a disposed engine): confirmed. addProp's dynamic-import .then() checks this.disposed before constructing SceneSplats and rejects with AbortError, which the existing catch handles. Source test added.",
- "Finding 6 (low, 'Free' before a price is known): confirmed. The button reads 'Make the prop' until the preview returns a price, then 'Make the prop · <price>'. The e2e now asserts there is no price before a picture is picked. Source test added.",
- "Finding 7 (info, protocol-relative URLs): parseSceneState's URL check is now ^(\\/(?!\\/)|https?:\\/\\/). A '//elsewhere.example/x.spz' entry was added to the malformed-entries test."
- ],
- "rejected": [
- "Finding 5 (low, keyboard users can't move a prop to an exact place): not built, and the reviewer marked it optional. Keyboard users already have the Size and Turn sliders and 'In front of the camera' (fly the camera with the keys, then bring the prop to it). The Move / Turn / Size radiogroup behaves like the app's other radiogroups. Nudge buttons or arrow-key moves would be new UI beyond this package's fixes, so this is listed in 'left'."
- ],
- "checks": [
- "Worktree /home/user/wt/o-idol-9 on o/idol-9. Only idol-4 and idol-9 commits after the base, as expected, and claude/fuobe-parity-4 is an ancestor. pnpm install --frozen-lockfile --prefer-offline and npx next typegen: ok.",
- "pnpm typecheck: exit 0. pnpm lint: exit 0 (5 warnings, 0 errors, none in changed files).",
- "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 1. 361/368 files and 5817 tests passed, 8 tests failed, all on the known pre-existing list in main-rules: comfy-reuse (1), dop-originals (1), preset-featured (1), soul-runs (2), split-soundtrack (1), plus picker-covers (1) and preset-covers (1), which time out under load. Rerun alone, picker-covers and preset-covers pass (36/36).",
- "Targeted: tests/scene-props, splat-view, cinema-scene, cinema-path, camera-path, scene3d and blockout: 8 files, 161 tests passed. tests/scene-props has 20 tests (16 before, 4 added).",
- "e2e: node tests/e2e/cinema-props.mjs against pnpm dev in demo mode (FUOBE_DEMO_MODE=on, port 3412, SwiftShader). 'All props checks passed', including the new last-frame check, 1440 dark/light and 390 light/dark, with no page or console errors. The first run failed only because the e2e still expected 'Make the prop · …' with no picture picked; the e2e was updated for the finding-6 change.",
- "Dev server stopped by PID, .next deleted, git status clean after commit f8cb42df. Not pushed. docs/handoff/reports/idol-4.json untouched.",
- "FINISH on o/idol-9 after merging the latest origin/claude/fuobe-parity-4 (clean merge): next typegen 0; pnpm typecheck 0; pnpm lint 0 (5 warnings, none in changed files); FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: 375 files, 5928 passed, 6 failed, 4 skipped. All failures are the known pre-existing ones: comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack."
- ],
- "finalSummary": "idol-9 (props in Cinema Studio's 3D scene) is finished on o/idol-9. The fix commit is f8cb42df, on top of 4a8090b8 and 9cb3318b. Open engine (your ComfyUI): 'Add a prop' places a Library splat (Idol 3D .spz, or TripoSplat .ply from either engine) or makes one from a picture with Idol 3D (oss-idol). Props render inside the scene's three.js graph with move/turn/size handles, and they show in captures, blockouts and the open Fly path render that feeds Uni3C. Every path frame is now sorted for its own camera, because the screen isn't drawn while a path records. Verified in demo mode on SwiftShader with the mock's demo splat, including pixel checks on the first and last frames. A real Idol 3D run from a picture needs a GPU with the Idol weights and wasn't run here. Cloud engine: Library splats, including cloud TripoSplat .ply, can be placed, and captures and blockouts show them. The cloud Fly path (H3 Max on the still) and WorldCast film the still or its depth, so props don't show there, and the panel says so. Idol 3D isn't hosted, so making a prop from a picture is open-engine only (no cloud substitute), and 'Paid APIs only' refuses it with plain copy. Cloud filming needs a fal/Replicate key as before. Public sign-up: no new routes. Guests see empty Library lists and the plain-language reason why they can't make a prop. Accounts get the existing 403 own-gpu-tool for any 3D run (POST /api/generations), so they can't make props yet. Props are kept per scene only in the viewer's browser storage.",
- "left": [
- "Idol's predicted camera (IdolCamera) doesn't set the first orientation yet. The clean graph would need to output its yaw and pitch into the splat's meta (a validated graph change for its own package).",
- "Props live in browser localStorage per scene, not on the server, so they don't follow the user to another device. Saving them with the take needs a server change with an account-scoped check.",
- "Keyboard placement (review finding 5): there are no nudge buttons or arrow-key moves for Move. Keyboard users place a prop by flying the camera and using 'In front of the camera', Size and Turn.",
- "Path render speed with props on a real GPU and on phones is not measured. On SwiftShader each frame waits for Spark's sort, which takes minutes per path.",
- "minAlpha 1/16 has not been tuned on a real Idol splat. Picking a prop by clicking it in the view isn't built; props are picked from the list.",
- "The e2e checks that the prop is present and correctly coloured in the first and last path frames. It does not measure whether the sort order is visually right on a real GPU.",
- "No graphs were added, so workflows/comfyui/requirements.json and its budget are unchanged."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/idol-9"
- ],
- "notMerged": [],
- "conflicts": "none (branched from o/idol-4; the base's idol-4 report kept)",
- "checks": "idol-9 alone: typecheck 0, lint 0, vitest 5992 passed, 6 failed (main known); checked by an independent verifier",
- "pushed": true,
- "head": "94d56bb4"
- }
-}
diff --git a/docs/handoff/reports/n7-10-regenerate-more.json b/docs/handoff/reports/n7-10-regenerate-more.json
deleted file mode 100644
index cbf47849..00000000
--- a/docs/handoff/reports/n7-10-regenerate-more.json
+++ /dev/null
@@ -1,175 +0,0 @@
-{
- "key": "n7-10-regenerate-more",
- "impl": {
- "branch": "o/n7-10-regenerate-more",
- "summary": "Open-H3 Regenerate (n7-3) now finishes soft clips in three more places, on your GPU only, plus a 2K tier for MiniMax H3. (1) Faceless: an open-engine episode's menu has 'Regenerate to 1080p'. Its line reads 'Sharper, may redraw · Runs on your GPU · about N min · Free'. Each clip is redrawn at 1080p with the 576p preset and start sigma 0.8, from the scene's own words (its picture prompt plus its motion). Wan's 16 fps clips go through RIFE to 24 fps first. The clips are then joined the way the episode joins them, at 1080p, and the episode's own narration, bed and subtitles go back on. The download switches to the newer 1080p film. The cloud keeps SeedVR and shows no Regenerate. (2) Shorts: on an open-source short, each segment of up to 15 s has 'Enhance (H3 regenerate) · 1080p · Free'. It runs RIFE 16→24 fps, then Regenerate at 1080p (576p preset, sigma 0.8, the segment's restyle prompt), and the result is a new take to pick, marked HD. 'Stitch again' with an enhanced take brings the other takes to 24 fps and joins at 1080p, keeping each clip in its place. A cloud short says Enhance runs on your GPU. (3) Edit video: a result of up to 15 s has 'Enhance (H3 regenerate) · 1080p' in its menu. The server adds RIFE first whenever the stored clip's own header (tenant-safe) is under 24 fps, so Upscale → Video's Regenerate gets this too. (4) Cinema and the Video studio: MiniMax H3 models get a 2K tier. Cinema's Resolution chip shows 2K only for H3 models, with '768p draft, then redrawn at 2K on your GPU' on the open engine. On the cloud, fal's minimax-h3 at 2K is $0.13/s (already in its catalog). The open oss-minimax-h3 at 2K runs a 768p draft and then Open-H3 Regenerate at 2K. Text to video drafts on the new graph video-h3-t2v-2k, which saves its 768p latent as fuobe_h3_<draft id>_00001.safetensors. The finish runs on the new graph video-regenerate-h3-latent, which loads that file and upscales the latent directly, with no decode and re-encode. A take from a start frame is finished from its clip. Cinema takes get 'Finish in 2K' in their menu: Free on your GPU (from the saved latent when the draft kept one), or $0.13/s as a fal re-render. The 2K take lands in the same folder, within the project's cost limit. Engine mode 'Paid APIs only' hides every GPU-only control. Accounts get own-gpu-tool on the new studio routes, the same as those studios' other run routes.",
- "built": [
- "Shared pure pieces in src/lib/catalog/regenerate.ts (n7-3's module, extended, not duplicated): REGEN_FINISH_SIGMA 0.8, REGEN_FINISH_TIER 1080p, REGEN_SMOOTH_MODEL oss-rife, needsSmoothing / sixteenFpsModel, finishLengthProblem (one pass ≤ 15 s), regenFinishSteps (optional RIFE → Regenerate as plan steps), canEnhance / enhanceRequest / ENHANCE_LABEL, H3_OPEN_MODEL, wantsH3TwoK, h3TwoKRequests, latentPrefixFor / latentFileFor, canFinishOpen and finishIn2k (fal re-render via n7-3's rerenderRequest, or a free redraw on your GPU).",
- "Faceless: ENGINE_MODELS.open.regenerate (the cloud has none), regeneratePlan(graph, {engine, joinMax, lookup}) and regenerateReuses in src/lib/catalog/faceless.ts. EpisodePlan.regenerated {ids, final} and EpisodeView.regenerated / regenerating / regenerate. regenerateEpisode in src/server/faceless.ts uses createPipeline with existing ids for the clips, narration, words and bed. The new 'regenerate' action is on POST /api/faceless/episodes/[id]/[action]. A change or an undo clears the regenerated film, and stopping or deleting an episode cancels it. UI: a menu item in the episode's actions (menu width fixed at w-64), a status line in the header, and polling.",
- "Shorts: ShortsTake.enhance {from, smooth}, ENHANCE_COPY, segmentSeconds, enhanceProblem, planEnhance and planFinishedStitch in src/lib/catalog/shorts.ts. planStitch takes opts.resolution, and a join group that mixes files and chained clips places each chained clip with ChainSlot.at so the order is kept. takeSteps knows enhanced takes. enhanceSegment is in src/server/shorts.ts (open shorts only, the chosen take finished, not already enhanced). The new route POST /api/shorts/sessions/[id]/segments/[index]/enhance uses the same once() nonce as Regenerate. UI: the segment card's button, the HD mark and accessible name on the take, the '(enhanced, 1080p)' line, and a one-line note on cloud shorts.",
- "Edit video: the output action 'enhance-h3' (src/lib/output-actions.ts, result-actions.tsx) creates the run through POST /api/generations. createRegenerateRun (src/server/regenerate.ts) now reads fps from the stored file's header and runs oss-rife (targetFps 24) first for a clip under 24 fps; the passes chain from RIFE's clip, and both are canceled together on an error.",
- "Cinema / Video studio: H3_2K_TIER, videoResolutionsFor(model) and H3_2K_OPEN_NOTE in src/lib/catalog/cinema.ts (VIDEO_RESOLUTIONS is unchanged). The prompt bar's Resolution chip uses the model's tiers and describes the 2K option. oss-minimax-h3 has resolutions ['768p', '2K']. createH3TwoKRun (src/server/regenerate.ts) is hooked into createGenerations: each take becomes draft + finish, and finished takes come first. finishTake is in src/server/cinema.ts, with the route POST /api/cinema/projects/[id]/items/[generationId]/finish. The tile menu's 'Finish in 2K' shows its price (Free, or ≈ $ at $0.13/s for the take's length).",
- "Graphs (scripts/comfy, hand-built from rdh9616's 'Prompt to 2K' and 'Decode Saved Latent' examples at 9b686c5). video-h3-t2v-2k: FL2VA pruned int8 + LoraLoaderModelOnly minimax_h3_fl2v_turbo_4step_v1.2_768p_comfyui_bf16 (lightx2v/Minimax-h3-Turbo @ 3ec17a3, 1,956,193,000 B, sha256 c8168ebc…), MiniMaxH3ImageToVideo, BasicScheduler simple 6, er_sde, and OpenH3SaveRefinedLatent between the sampler and the decoder, with the soundtrack. video-regenerate-h3-latent: OpenH3LoadRefinedLatent → OpenH3RegenUpscale → RefineLatent → 3 Euler steps → save → fast VAE decode → Finish with the latent's frame count and sound. Also added: library.spec entries with licences (Turbo v1.2 Apache-2.0 per its card at 3ec17a3), BINDING_KEYS latentPrefix / latent, a KNOWN_MODELS pin and model-pins.json (size + SHA-256), the manifest entries, and requirements.json rebuilt (259,811 B after the last base merge). Variants in src/lib/comfy-variants.ts (H3_LATENT_DRAFT_GRAPH on extra.latentDraft, REGEN_LATENT_GRAPH on extra.latentFrom), so the GPU gate checks the graph that runs. The provider binds latentPrefix from the run's id and the latent file from latentFrom, refuses a finish with no words or no saved draft, and gives these graphs n7-3's missing-pack message. isH3Graph covers the draft graph, so it gets H3's canvas and 17n+5 frame grid. regenerateGraphLoras covers the latent graph.",
- "GPU pre-flight: a 'MiniMax H3 in 2K' row (both graphs + the refiner LoRA). Rows with workflows now also list the LoRAs those graphs load themselves.",
- "Validation: the CPU ComfyUI at 8188 was down when I built, so `npm run build -- video-h3-t2v-2k video-regenerate-h3-latent` ran against a local stub serving the committed object_info.subset.json. The manifest diff was exactly the two new entries, and I reset the header's generatedAt to the base's. After ComfyUI came back, `node validate-workflows.mjs video-h3-t2v-2k video-regenerate-h3-latent --shared` gave missing_node_type on the rdh pack nodes (OpenH3SaveRefinedLatent / OpenH3LoadRefinedLatent), as expected: the pack is opt-in (OPEN_H3_REGEN=1) and isn't on the CPU server. Both stay validated:false. The subset churn from the restarted server was reverted, because no new core class is used."
- ],
- "tests": "Final full Vitest on the branch merged with claude/fuobe-parity-4 at 23bfafd5 (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 343 files, 5419 passed, 3 skipped, 6 failed. All six failures are the known ones 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'). An earlier full run's timeouts in blockout and preset-covers pass alone. The base then moved to 11e187bf (hi3d-refine). After merging it, the type check is clean and 23 affected files of both sides pass (520 tests): my tests, regenerate-2k, comfy-library-4, open-minimax-h3, character-swap-2k, cinema-models, public-signup, faceless, shorts, h3-any-gpu, h3-tier, canvas-split, the hi3d / model3d tests, and gpu-requirements (the requirement index is 259,811 B). tsc and pnpm lint are clean (only warnings from the base). New tests/regenerate-more.test.ts (5): the shared finishing steps (RIFE only under 24 fps, the 15 s refusal), and the Faceless plan per engine: the cloud refuses; on the open engine each scene is redrawn from its own words at 1080p with the 576p preset and sigma 0.8; RIFE for Wan; joins folded at 1080p; the mix and subtitles reuse the narration, words and bed; one scene goes unjoined. New tests/regenerate-more-api.test.ts (13): the two graphs' shapes; the saved-latent hand-off bindings through prepareWorkflow (latent_file fuobe_h3_<draft>_00001.safetensors, the prefix from the run's id, refusal without a draft); the variant choice; the pins; the board row; the 2K run (t2v draft with latentDraft → finish with latentFrom; i2v finished from the clip; 2 takes → 2 pairs; 768p stays single); Cinema's 2K tier only for H3 models (oss-minimax-h3, minimax-h3, minimax-h3-max) with the open note, $0.65 for 5 s on fal, LTX at 2K → 1080p; finishIn2k per source and engine mode; the Cinema finish route in demo mode (201, the take recorded, 422 for a 2K take, 404); Edit video's Enhance offer (≤ 15 s, hidden in Paid APIs only); RIFE before a 16 fps clip; and tenant safety (an account reads only its own clip's frame rate). Extended: faceless-api (Regenerate end to end in demo mode: 6 redraws, the mix reuses the narration, 422 on the cloud, a second click starts nothing), shorts-api (Enhance: RIFE → Regenerate, the nonce, 409 when already enhanced, the stitch with RIFE on the other takes at 1080p and the enhanced clip in its place, 422 on a cloud short), public-signup (the three new routes answer own-gpu-tool for accounts; guests get the same as those studios' other run routes). Browser: tests/e2e/regenerate-more.mjs passed every check against pnpm dev (FUOBE_DEMO_MODE=on) at 1440 and 390 px in light and dark: Faceless's item (text, Free, fits, reached by arrow keys, tapped at 390), Shorts' Enhance (fits, reached by Tab, a tap adds an enhanced take), the Edit video result menu item, Cinema's 2K tier (4 tiers, the GPU description, in the Settings popover at 390) and Finish in 2K · Free in a take's menu. No sideways scroll and no page errors. The dev server is stopped and .next is deleted. GPU: none; the two graphs were posted to the CPU ComfyUI and stop at missing_node_type for the opt-in rdh pack, as expected.",
- "left": [
- "Not verifiable here: any GPU run of the two new graphs, whether OpenH3RegenUpscale accepts the H3 sampler's AV latent loaded back from a file (rdh's 'Prompt to 2K' hands it over in memory), quality of 576p-preset redraws of Faceless scenes / Shorts segments, and any fal call (2K re-render). Validate on a GPU ComfyUI with OPEN_H3_REGEN=1: node validate-workflows.mjs video-h3-t2v-2k video-regenerate-h3-latent.",
- "The latent hand-off needs the finish to run on the ComfyUI that made the draft (the file lives in its output/open_h3_latents/). With several workers, a finish placed elsewhere fails ComfyUI's check of the file name. There is no fallback to finishing from the clip yet.",
- "Shorts Enhance is offered on open-source shorts only (their stitch is joined by Fuobe's open join, which concatenates frames without retiming). Cloud shorts show a one-line note.",
- "Hosted runs (FUOBE_HOSTED_RUNS): the 2K tier creates two runs inside createGenerations, like n7-3's Regenerate. poolQuote for oss-minimax-h3 at 2K wasn't tested in the style of tests/hosted-runs.test.ts.",
- "Faceless Regenerate's GPU time (about 1.5 min per clip) and Cinema's 'about 5 minutes per 5 s' come from rdh's README measurements on a 72 GB card, not measured here.",
- "Brief out of date: faceless.ts L599-654 is now the ENGINE_MODELS block (~L630-700), and the existing 'Upscale to 1080p' upscales the finished film (src/server/faceless.ts upscaleEpisode), so per-scene Regenerate rebuilds the join, mix and subtitles from the episode graph. cinema.ts L559 is VIDEO_RESOLUTIONS at ~L614. Edit video has no segment selection, so 'Enhance' is a result action on Edit video results ≤ 15 s; per-segment Enhance lives in Shorts. There is no segment-level cloud upscale to keep; results keep their Upscale hand-off. Already there from n7-3: 'Regenerate in 2K' on open results and 'Re-render at 2K' ($0.13/s) on fal H3 results in the Video studio, and cloud minimax-h3 listing 2K/4K with prices. The draft preset follows the brief (576p) for Faceless and segments; 'Finish in 2K' on an H3 take uses n7-3's rule (768p for H3)."
- ],
- "docsNotes": [
- "STATUS.md: n7-10 is built and browser-checked, not GPU-run. Faceless 'Regenerate to 1080p' (open engine); Shorts 'Enhance (H3 regenerate)' per segment (open shorts) and the 1080p 24 fps stitch; Edit video 'Enhance (H3 regenerate) · 1080p'; RIFE first for clips under 24 fps; MiniMax H3's 2K tier in Cinema and the Video studio (fal 2K; on your GPU, a 768p draft that keeps its latent + the 2K finish from it); 'Finish in 2K' on Cinema takes; a GPU pre-flight row 'MiniMax H3 in 2K'. New graphs video-h3-t2v-2k and video-regenerate-h3-latent (need OPEN_H3_REGEN=1).",
- "ARCHITECTURE.md: regenerate.ts gains regenFinishSteps, canEnhance / enhanceRequest, wantsH3TwoK / h3TwoKRequests, latentPrefixFor / latentFileFor, finishIn2k. server/regenerate.ts gains createH3TwoKRun and RIFE-first in createRegenerateRun. faceless.ts gains regeneratePlan / regenerateReuses and EpisodePlan.regenerated. shorts.ts gains planEnhance / planFinishedStitch, ShortsTake.enhance, planStitch opts.resolution, and ChainSlot.at placement. cinema.ts gains videoResolutionsFor / H3_2K_TIER. comfy-variants.ts gains H3_LATENT_DRAFT_GRAPH / REGEN_LATENT_GRAPH. New routes: POST /api/faceless/episodes/[id]/regenerate (action), POST /api/shorts/sessions/[id]/segments/[index]/enhance, POST /api/cinema/projects/[id]/items/[generationId]/finish (all own-gpu-tool for accounts).",
- "PR note: the hot file tests/comfy-library-4.test.ts gets two lines ('video-h3-t2v-2k', 'video-regenerate-h3-latent' after 'video-regenerate-h3' in the unvalidated list), the same exception n7-3 made. On a conflict, take main's version and re-add those lines. tests/open-minimax-h3.test.ts now expects resolutions ['768p', '2K'].",
- "PR note: requirements.json is 259,811 B after this package and the base at 11e187bf (budget 256 KiB = 262,144 B raw; tests/gpu-requirements.test.ts passes). The next package that adds graphs is close to the raw budget.",
- "PR note: the browser check is tests/e2e/regenerate-more.mjs (run against `pnpm dev` with FUOBE_DEMO_MODE=on)."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "id": 1,
- "severity": "high",
- "title": "Ad Multiplier on the open engine now asks MiniMax H3 for 2K: every new hook and CTA becomes a 768p draft plus an Open-H3 Regenerate pass",
- "where": "src/lib/catalog/models.ts (oss-minimax-h3 resolutions ['768p','2K']) + src/server/marketing.ts:1111 nearestRes, used at :1045",
- "detail": "nearestRes ranks tiers with parseInt, so parseInt('2K') is 2, which is below every wanted tier, and .pop() picks it. Ad Multiplier asks for 480p or 720p on the open engine (1080p is mapped to 720p), neither of which is in the list, so the hook and CTA clips now get resolution '2K'. On the base they got '768p'. createGenerations then routes them through createH3TwoKRun: a 768p draft (video-h3-t2v-2k for t2v), then oss-h3-regenerate at 1440p. That second pass needs the opt-in OPEN_H3_REGEN pack, the 12 GB refiner LoRA and about 48 GB of VRAM, and it is refused when the refiner LoRA is switched off. So hook and CTA runs that worked before now fail or cost GPU minutes, and the 2K clip is joined at 720p anyway. The same ModelDef change also puts '2K' into other places that list the model's tiers: Faceless's 'Quality' segmented control (settings-form.tsx:260 shows it once there are 2 tiers), Canvas and Assist. In Faceless, createPipeline keeps only made[0] in byKey, so the 768p drafts are never in plan.ids. Stop and Delete cancel the finish but leave the draft running. marketing-api.test.ts doesn't assert the resolution, so this isn't caught.",
- "evidence": "Scratch probe (vitest, scratch config outside the worktree): planMultiplier({engine:'open', mode:'sections', hook, quality:'480p'|'720p'|'1080p'}) gives a hook step with oss-minimax-h3 params {duration:5, generateAudio:true, resolution:'2K'} for all three.",
- "fix": "Offer 2K only where it is meant to be (Cinema / Video studio via videoResolutionsFor, keyed off the model), or rank tiers by height (cinema.ts tierHeight) in nearestRes and in any other picker. Add a regression test that Ad Multiplier's open hook stays at 768p. Either keep 2K out of the Faceless Quality control or track the draft ids in the plan."
- },
- {
- "id": 2,
- "severity": "medium",
- "title": "Saved-latent hand-off: the finish neither refuses plainly nor falls back to the clip, and Cinema's retry points the finish at the old draft",
- "where": "src/lib/comfy-variants.ts REGEN_LATENT_GRAPH choice, src/server/providers/comfyui.ts:1414-1420, src/lib/catalog/regenerate.ts finishIn2k / h3TwoKRequests, src/server/cinema.ts retryItem",
- "detail": "(a) The owner's workers (comfyWhere=workers): bin/lib/worker/checks.mjs cleanJob empties the worker's output/ after every job, so the draft's output/open_h3_latents file is gone before the finish runs, even on the same worker. vetGraph also refuses latent_file 'fuobe_h3_<id>_00001.safetensors' as model-unverified (the MODEL regex matches .safetensors). Every open 2K text-to-video run on workers therefore fails at the finish with 'The GPU that took this run refused it: it needs a model file that GPU couldn't verify.' (b) Any other mismatch: a different ComfyUI, comfyWhere changed before Cinema's later 'Finish in 2K', or a cleaned output folder. OpenH3LoadRefinedLatent.latent_file is a combo ([(newest)] + files on disk at 9b686c5), so ComfyUI's value_not_in_list goes through explainComfyError as 'ComfyUI can't find \"fuobe_h3_…_00001.safetensors\" (OpenH3LoadRefinedLatent.latent_file)'. That message is a raw file and node name, which is jargon if an account sees it (rule 5). Meanwhile the draft's own clip is chained into the same finish and could be redrawn instead. (c) Cinema retry: retryItem re-makes a failed draft under a new id, but the finish's stored request keeps extra.latentFrom = the failed draft's id. The retried finish then looks for a latent that was never written, or finishes the failed attempt's latent if it got past the save node.",
- "evidence": "Pack source at 9b686c5 (scratchpad clone): Save writes output/open_h3_latents/<basename(prefix)>_{index:05d}.safetensors with index = 1 + the highest existing, and Load's latent_file is a COMBO. Worker code: checks.mjs cleanJob/vetGraph, relay.ts tabFailureWords. Probe: in a Cinema project, a failed 2K t2v draft YzI69Z6KF4QZ is retried as ys7E6oSD3eGT, while the new finish has extra.latentFrom = YzI69Z6KF4QZ.",
- "fix": "Choose the latent graph only when the draft ran on the ComfyUI the finish will use (not on workers), else finish from the chained clip (REGEN_WORKFLOW). Take latentFrom from the dependency at launch, not from an id baked in at creation. Give a missing latent plain words, or fall back."
- },
- {
- "id": 3,
- "severity": "medium",
- "title": "latentFrom is client-controlled and unchecked: an account's run can name another run's saved latent",
- "where": "src/server/request-schema.ts:109 (params.extra = z.record(unknown)), src/lib/comfy-variants.ts:95-96, src/server/providers/comfyui.ts:1414-1420",
- "detail": "POST /api/generations passes params.extra through. A request for oss-h3-regenerate with extra.latentFrom = X switches to video-regenerate-h3-latent and binds fuobe_h3_X_00001.safetensors. Nothing checks that X is the asker's own run or a latentDraft run. tenant.ts and account-inputs.ts only see inputs.video, which can be the attacker's own clip. On an account's own GPU this is harmless. With hosted runs (FUOBE_HOSTED_RUNS=1), the account's run goes to the install's own ComfyUI, which also holds the owner's draft latents and other accounts' pooled ones. The run would then render someone else's private draft in 2K for the attacker (it needs the run id). The brief's rule says a new server path that reads a file for a run goes through tenant/account-inputs, with a test.",
- "evidence": "Probe: inside runAsTenant({kind:'account', id:'acct-x'}), prepareWorkflow('video-regenerate-h3', {video: <acct-x's own clip>, extra:{latentFrom:'OWNERSdraft01', draftFrom:'h3'}}) gave node 1 OpenH3LoadRefinedLatent with latent_file 'fuobe_h3_OWNERSdraft01_00001.safetensors'. No refusal.",
- "fix": "Treat latentDraft/latentFrom as server-only (strip them from client requests the way STAMP_FIELDS are stripped), or check generationAccount(latentFrom) === tenantAccount() and that the run kept a latent. Add a tests/account-*.test.ts case."
- },
- {
- "id": 4,
- "severity": "medium",
- "title": "The new LightX2V FL2V Turbo 4-step v1.2 LoRA isn't in Settings → Models & licences and has no switch",
- "where": "src/server/model-access.ts loraRows (CHARACTER_LORAS and REGEN_LORA are listed, the 4-step isn't); scripts/comfy/library.spec.mjs",
- "detail": "The LoRA's licence is recorded only inside the manifest licence string of the variant graph video-h3-t2v-2k. No route endpoint names that graph, so modelLicence(oss-minimax-h3) never shows it, and accessList has no LoRA row for it. That breaks the owner's rule: every LoRA's licence is shown as data where the admin turns it on or off. The 8-step Turbo (CHARACTER_LORAS) and the refiner LoRA (REGEN_LORA) each have a row. The draft run also doesn't check a switch for it, and it isn't downloaded the way regenerateGraphLoras downloads the refiner.",
- "evidence": "Probe: JSON.stringify(accessList()) includes '8step_v1.0': true, 'open_h3_regenerate_2k_lora': true, '4step_v1.2': false. modelLicence(oss-minimax-h3) doesn't mention v1.2.",
- "fix": "Add a row (Apache-2.0 per its card at 3ec17a3, 'the current card no longer states a licence'), like the 8-step entry, and honour its switch for the 2K draft."
- },
- {
- "id": 5,
- "severity": "low",
- "title": "A 2K H3 run whose words come from an earlier step finishes from the literal '{text}'",
- "where": "src/lib/catalog/regenerate.ts h3TwoKRequests",
- "detail": "The finish copies original.prompt but only chains the video slot. For a Canvas or Assist text → video step at 2K (prompt '{text}', chain [{slot:'prompt'}]), the draft gets the real words, but the finish is created with prompt '{text}' and chain [{slot:'video'}]. Regenerate then redraws at 2K from the placeholder.",
- "evidence": "Probe: createGenerations({modelId:'oss-minimax-h3', op:'t2v', prompt:'{text}', chain:[{slot:'prompt'}], params:{resolution:'2K'}}, {dependsOn: <write step>}) gives oss-h3-regenerate with prompt '{text}' and chain [{slot:'video'}].",
- "fix": "Also chain the text step into the finish (a prompt slot from the same dependency), or refuse 2K when the words are chained."
- },
- {
- "id": 6,
- "severity": "low",
- "title": "Previews and hosted runs plan and price a 2K H3 run as only the H3 jobs",
- "where": "src/server/generations.ts previewGeneration vs createGenerations (createH3TwoKRun); src/server/hosted-run.ts decidePlace/poolQuote",
- "detail": "?preview=1 (and the pool's plan and billing quote) shows N oss-minimax-h3 jobs and says nothing about the N Open-H3 Regenerate passes that createGenerations then adds. With hosted runs on, poolAllows only checks oss-minimax-h3. The finish then runs oss-h3-regenerate (48 GB, ~3 min per 5 s) on the install's GPUs under the same stamp and hold, even if the policy denies that model. The implementer flagged this as untested.",
- "evidence": "Probe: previewGeneration(oss-minimax-h3, t2v, 2K, numOutputs 2) gives jobs 2, outputs 2, no notes. createGenerations makes 4 rows (2 × oss-h3-regenerate 1440p + 2 × oss-minimax-h3 768p latentDraft).",
- "fix": "Plan and price the finish in previewGeneration for wantsH3TwoK, check poolAllows for REGEN_MODEL too, and add a test in the style of tests/hosted-runs.test.ts."
- },
- {
- "id": 7,
- "severity": "low",
- "title": "Finish in 2K can be repeated without limit, including on a 2K run's own draft",
- "where": "src/server/cinema.ts finishTake, src/app/api/cinema/projects/[id]/items/[generationId]/finish/route.ts, cinema-feed.tsx",
- "detail": "No once() nonce (Shorts' Enhance has one) and no check for a 2K finish the take already has. Each click on a fal take is another paid 2K render (the cap check still applies). The 768p draft of a 2K run also offers 'Finish in 2K' even though its finished take already exists.",
- "fix": "Take a requestId nonce like Shorts' Enhance, and hide or refuse the action when the take already has a 2K finish."
- },
- {
- "id": 8,
- "severity": "low",
- "title": "Edit video's menu item doesn't say it runs on your GPU",
- "where": "src/lib/catalog/regenerate.ts ENHANCE_LABEL, src/lib/output-actions.ts",
- "detail": "'Enhance (H3 regenerate) · 1080p' also shows on cloud Edit video results when the Engine mode is Both, but only the toast mentions the GPU. The owner's rule asks the UI to say plainly what each engine does. Shorts' button title and the Faceless line do say it.",
- "fix": "Add 'on your GPU' to the label or a hint, as in Shorts and Faceless."
- },
- {
- "id": 9,
- "severity": "info",
- "title": "Hot-file edit to tests/comfy-library-4.test.ts (rule 2)",
- "where": "tests/comfy-library-4.test.ts:156-157",
- "detail": "It adds two lines to the exact unvalidated list. The edit can't be avoided because the test pins the whole list with toEqual, and both graphs must stay validated:false. It is the same exception as n7-3, whose 'video-regenerate-h3' line is already on origin/main (65dd7f9d, line 158). The PR note says to take main's version on a conflict and re-add the two lines. That is acceptable if the PR says so."
- }
- ],
- "checks": [
- "Turbo LoRA pin at source (HF API tree @ 3ec17a324ced54151364f24f8b5fb6bf7e26414f): minimax_h3_fl2v_turbo_4step_v1.2_768p_comfyui_bf16.safetensors is 1,956,193,000 B, lfs sha256 c8168ebc17bbacc4296103dda2fec1ba85b24392fa08cf2bfbcef0cff0dc3cc8. This matches model-pins.json and the manifest URL.",
- "rdh pack source at 9b686c5 (raw __init__.py): Save writes <basename(prefix)>_{index:05d}.safetensors under output/open_h3_latents, so a fresh prefix gives _00001 and latentFileFor matches. Load's latent_file is a COMBO ([(newest)] + files on disk). frame_count 0 means all frames in Finish. Graph shapes match the 'Prompt to 2K' and 'Decode Saved Latent' examples (latent saved between sampler and decoder; the finish upscales the loaded latent; CLIPTextEncode as in n7-3's Draft Video graph). latentPrefixFor sanitises ids, so no path traversal and no '(newest)' are possible.",
- "Three new routes: accounts get 403 own-gpu-tool (tests/public-signup.test.ts) and guests 401 as a change. No estimate or ?preview route was added, so there is no priceAs gap. Bodies are empty or a nonce, so no proxy or direct-gate rows are needed. All are owner-only, so Faceless, Shorts and Cinema take no account file reads.",
- "Tenant-safe read in createRegenerateRun: fps comes from storedMedia (tenant-scoped), with a test. The RIFE pre-pass reuses the route-checked inputs.video. The new hole is latentFrom (finding 3), not the clip.",
- "Faceless rebuilt film vs buildEpisodeGraph, traced: same join model and foldJoins(joinMax), 1080p only when the join takes it (oss-join-clips yes; the copy join oss-join-encoded gets clips that are all 1080p at 24 fps). Mix after/chain are identical with the film swapped. Captions follow mix → regen-mix and reuse words. Narration, words and bed are reused and must have succeeded. Aspect is only 16:9 or 9:16, so there is no crop. Change, undo, stop and delete clear or cancel the regenerated film. The cloud shows no Regenerate and the base Upscale stays.",
- "Shorts' reordered join: ChainSlot.at exists on the base (withChainInputs inserts by at; unfilledRequest removes by at). planStitch's mixed groups give each chained clip its index within the group and keep chain order equal to after order, so [k0,url1,k2] becomes [k0,url1,k2]. Key-only groups are unchanged. planFinishedStitch runs RIFE on the other takes and joins at 1080p.",
- "Cinema 'Finish in 2K' cost limit: finishTake prices with previewGeneration (rerenderRequest: $0.13/s × duration on fal; free on your GPU) and refuses spent + cost > cap with 422. The take must be in the project (404 otherwise). In 'Paid APIs only' mode finishIn2k returns null, so the open finish is refused.",
- "Visitor copy (rule 5): the new strings are plain ('Runs on your GPU', 'Free', '768p draft, then redrawn at 2K on your GPU'). The missing-pack message uses REGEN_COPY.missingVisitor for the new graphs. The exception is the raw 'can't find fuobe_h3_… (OpenH3LoadRefinedLatent.latent_file)' path in finding 2. The e2e test doesn't filter hydration errors.",
- "GPU pre-flight: a 'MiniMax H3 in 2K' row with both graphs and the refiner LoRA. requirements.json lists both graphs, the pack classes and the 4-step LoRA file. The size budget passes (gpu-requirements test).",
- "Validation-state entries come from a validate-workflows run (missing_node_type for the opt-in pack), not a hand-merge. Both graphs are validated:false.",
- "Targeted Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): regenerate-more, regenerate-more-api, public-signup, comfy-library-4, open-minimax-h3, gpu-requirements, regenerate-2k, marketing-api: 8 files, 208 tests passed. shorts-api, faceless-api, faceless, shorts, cinema-models, h3-tier, request-body-limits: 7 files, 172 tests passed. No full run was needed.",
- "Probes ran from a scratch vitest config and *.probe.ts files in the scratchpad (root set to the worktree). No file in the worktree or /home/user/Fuobe was changed. The CPU ComfyUI was not touched."
- ],
- "verdict": "changes requested: fix 1 (Ad Multiplier and other surfaces silently switched to the 2K two-pass run, a regression of working open runs), 2 (the latent hand-off fails on workers, after a retry, or on another ComfyUI, with no fallback to the clip) and 3 (an unchecked client latentFrom, a cross-tenant read under hosted runs) before merge. 4 to 8 are smaller follow-ups, and 9 must be called out in the PR."
- },
- "fix": {
- "applied": [
- "Finding 1 (high): 2K left oss-minimax-h3's own resolutions (back to ['768p'], so tests/open-minimax-h3.test.ts is the base's again) and moved to a new ModelOptions.finishTiers ['2K'], read only through studioResolutions() in src/lib/catalog/regenerate.ts by the Video studio (lib/composer.ts settingsShape, studio-page ?resolution=) and Cinema (videoResolutionsFor, fitParams). Ad Multiplier, UGC, Faceless's Quality control, Canvas and Assist read resolutions alone, so they keep 768p. marketing.ts nearestRes now ranks tiers by the height they name (targetShortEdge: 2K = 1440), so a K tier can never rank as 2. Tests: Ad Multiplier's open hook and CTA stay at 768p for 480p/720p/1080p, Faceless pickerData offers no open 2K, the studio shape shows 768p + 2K.",
- "Finding 2 (medium): the hand-off is decided when each run starts, on the ComfyUI it goes to. comfyPlace() (providers/comfyui.ts) names it: an account's link or computer, the owner's computer, or this install's server; null on the owner's workers, which empty output/ after every job. The draft keeps its latent only where a place exists and its LoRA is on, and records meta.latentAt. advanceDependents sets the finish's latentFrom from the draft it waits for (latentFromDependency), never from an id baked in at creation, so a Cinema retry loads the new draft's latent. createH3TwoKRun no longer stores latentFrom. submitNow's latentHandOff keeps latentFrom only for a succeeded latent-keeping run of the same account on the same place that no earlier finish found gone; otherwise the finish redraws its chained clip (REGEN_WORKFLOW). When ComfyUI's /prompt refuses the Load Refined Latent node (file gone), the provider submits the clip graph in the same run. On someone's computer (where the tab reports the refusal later), promptRefusal gives REGEN_COPY.latentGone in plain words, and the next finish or a Retry redraws the clip. The tests are tests/regenerate-latent.test.ts against a fake ComfyUI (the draft saves under its id with latentAt; the finish loads that file; fallback in one run; Cinema retry loads the new draft; places; the workers / other ComfyUI / another's run / LoRA-off cases; the plain words).",
- "Finding 3 (medium): latentDraft and latentFrom are server-only. LATENT_EXTRA is dropped from params.extra by GenerationRequestSchema (POST /api/generations and recipes, via ClientExtra), the palette-lock route and Canvas node params. The new GenerationRequest.finishOf isn't in the schema, so it's server-only too. The launch check (latentHandOff → keptLatent) needs the same account (or the owner's own) and the same place. tests/account-latent.test.ts covers three cases with an account on a linked fake GPU. A client's latentFrom/latentDraft is dropped and the clip graph is sent. Inside the server, a finish naming the owner's or another account's draft on the same ComfyUI redraws the clip, while its own draft's latent loads. And an account's own 2K run keeps its latent on its link and the finish loads it.",
- "Finding 4 (medium): H3_TURBO_4STEP_LORA (pinned at 3ec17a3) has a row in Settings → Models & licences: 'MiniMax H3 FL2V Turbo 4-step v1.2 (lightx2v)', adapter, Apache-2.0, with a card link at 3ec17a3 and the note 'the current card no longer states a licence'. knownSwitch and loraLicence know it. With it switched off, the 2K draft runs on H3's own graph (no latentDraft, both at creation and at launch), and the finish redraws the clip. regenerateGraphLoras(endpoint, extra) lists it for the draft (video-h3-t2v-2k, or minimax-h3-t2v with latentDraft), so the owner's run downloads it, an account's GPU is checked for it, and the pre-flight row lists it.",
- "Finding 5 (low): createH3TwoKRun chains the steps that write the words (prompt slots) into the finish as well: chain [{video},{prompt}…], dependsOn [draft, …word steps], so '{text}' is filled from the same step.",
- "Finding 6 (low): previewGeneration plans each take's finish (h3TwoKExtra: the refiner switch, previewChained of the finish, its price, the note H3_2K_STEPS_NOTE) and lists them in `steps`, the mechanism Clean the voice first added on the base. decidePlace/poolQuote's poolAllowsRun and the billing quote's run.steps therefore see oss-h3-regenerate. tests/regenerate-more-hosted.test.ts (in the style of hosted-runs) checks that the pool plans and quotes 2 finishes for 2 takes, and that a policy denying oss-h3-regenerate keeps the 2K run off (refuse / no quote) while 768p still pools.",
- "Finding 7 (low): POST …/items/[generationId]/finish takes an optional requestId and goes through Shorts' once(), so a repeat gets the first answer. finishTake answers 409 'This take already has a 2K finish' while a run with request.finishOf = that take isn't failed, canceled or trashed. createH3TwoKRun marks its finish finishOf = draft, so a 2K run's own 768p draft counts. A retried finish follows its new draft (withFinishOf). Cinema's tile menu hides Finish in 2K on takes in finishedTakes(items) and sends the nonce through useSubmitGuard.",
- "Finding 8 (low): ENHANCE_LABEL is now 'Enhance (H3 regenerate) · 1080p · on your GPU'.",
- "Finding 9 (info): the two lines in tests/comfy-library-4.test.ts are kept, and noted under left for the PR.",
- "The full run found one more expected change: tests/model-access-listings.test.ts counts the LoRA rows, which went from 184 to 185 with the new Turbo 4-step row, and now also checks that row (separate commit 9d841ac4).",
- "Merged claude/fuobe-parity-4 (ad4615e1, DBS D4/D6) into the branch. The one conflict was the import block of src/server/generations.ts, and both sides were kept. 03e49f2d is already an ancestor of the branch."
- ],
- "rejected": [],
- "checks": [
- "pnpm typecheck: exit 0 (with NODE_OPTIONS=--max-old-space-size=6144; the default 2 GB heap runs out of memory on this tree).",
- "pnpm lint: exit 0, 0 errors and 5 warnings, all in base files (library.spec.mjs, composer.tsx, elements.ts).",
- "Full Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2) on the branch merged with claude/fuobe-parity-4 at ad4615e1: 350 files, 5516 passed, 3 skipped, 8 failed (exit 1). One failure was this stage's: model-access-listings counted 184 LoRA rows and the new Turbo 4-step row makes 185. It is fixed and the file passes alone (7/7). The other 7 also fail on the base at ad4615e1, checked in a temporary detached worktree in the scratchpad, since removed. Six are the known ones from main: comfy-reuse (pack licence record), dop-originals (DoP move), preset-featured, soul-runs x2 and split-soundtrack ('has no cloud route'). The seventh is eval-harness 'runs each Genjutsu mode's own partner model on fal': its separation/video dry run plans DeepFilterNet 3 and Demucs instead of refusing them. That came in with dbs-d4 and is already fixed on the current base a150159e, where the test passes. The coordinator said not to merge the newer base.",
- "Targeted runs: tests/regenerate-more-api.test.ts (23), tests/regenerate-latent.test.ts (6), tests/account-latent.test.ts (3) and tests/regenerate-more-hosted.test.ts (2) all pass.",
- "Browser: tests/e2e/regenerate-more.mjs against pnpm dev (FUOBE_DEMO_MODE=on, data in the scratchpad) passed every check at 1440 and 390 px in light and dark. That covers Faceless Regenerate, Shorts Enhance (Tab, tap), the Edit video item with the longer label (it wraps to 3 lines in the 390 px menu and fits), Cinema's 4 tiers with the 2K line, and Finish in 2K · Free. There was no sideways scroll. The dev server was stopped and .next deleted.",
- "requirements.json is unchanged by this stage (259,811 B; gpu-requirements passes in the full run)."
- ],
- "finalSummary": "Open engine (your ComfyUI). These pieces are built and checked against fake ComfyUIs and in the browser, but not run on a GPU. Faceless 'Regenerate to 1080p', Shorts 'Enhance (H3 regenerate)', Edit video's 'Enhance (H3 regenerate) · 1080p · on your GPU' with RIFE first under 24 fps, and MiniMax H3's 2K tier in the Video studio and Cinema. The 2K tier is a 768p draft plus an Open-H3 Regenerate finish, and is now offered only there: Ad Multiplier, UGC, Faceless, Canvas and Assist stay at 768p. The draft keeps its latent only on a ComfyUI that keeps files (not the owner's workers) and while the Turbo 4-step LoRA is on. The finish loads it only from the same account's draft on the same ComfyUI, named from the draft it waits for when it starts, and otherwise redraws the draft's clip. Cinema's 'Finish in 2K' happens once per take, with a request id. It is Free on your GPU, from the saved latent when that latent is usable. Cloud engine: fal's minimax-h3 at 2K ($0.13/s) for Cinema and Video studio H3 takes, and Finish in 2K re-renders on the same hosted model. Faceless keeps SeedVR. Regenerate, Enhance and the 2K finish are GPU-only and hidden in 'Paid APIs only'. These need a fal key, and no fal call was made here. Public sign-up. Guests get 401 on the three new routes. Accounts get 403 own-gpu-tool on the Faceless, Shorts and Cinema routes, as before. Through POST /api/generations an account runs the 2K tier on its own GPU, or on the install's GPUs with hosted runs, where the finish is planned, priced and policy-checked. A client can never name or keep a latent, and an account never loads the owner's or another account's latent.",
- "left": [
- "tests/model-access-listings.test.ts (a base test) now expects 185 LoRA rows. On a conflict, take main's count + 1 for the Turbo 4-step v1.2 row.",
- "PR must call out the hot-file edit to tests/comfy-library-4.test.ts: two lines ('video-h3-t2v-2k', 'video-regenerate-h3-latent') in the unvalidated list, the same exception as n7-3. On a conflict, take main's version and re-add the two lines.",
- "requirements.json is 259,811 B raw against the 262,144 B budget (tests/gpu-requirements.test.ts). The next package that adds graphs is close to the limit.",
- "Not verifiable here: any GPU run of video-h3-t2v-2k / video-regenerate-h3-latent (both validated:false, need OPEN_H3_REGEN=1), whether OpenH3RegenUpscale accepts the H3 sampler's AV latent loaded back from a file, quality of the 576p-preset redraws, the fal 2K re-render, and the GPU-time figures (taken from rdh's README).",
- "On someone's computer (an account's tab, or the owner's computer) a missing latent is only known after the tab reports the refusal: that finish fails with plain words, and Retry or the next Finish in 2K redraws the clip. On a direct ComfyUI the fallback happens in the same run.",
- "A 2K run's draft on a card under 32 GB still runs the full FL2VA int8 draft graph: the latent draft wins over FastH3/Trim, as before this stage. Not re-examined.",
- "Shorts Enhance stays on open-source shorts only, as built."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/n7-10-regenerate-more"
- ],
- "notMerged": [],
- "conflicts": "shorts session-view imports, comfy-variants (latent draft + flex graphs), generations, gpu/tools, model-access, comfyui provider, comfy-library-4, model-access-listings count; follow-up 64900624 (2K with Pika Flex)",
- "checks": "batch of 7 (dbs-d7, idol-5, idol-2, idol-6, n7-9, kandinsky6, n7-10): typecheck 0, lint 0, vitest 5788 passed, 6 failed (main known); each merge checked by an independent verifier; n7-10 + Pika Flex interaction fixed in 64900624",
- "pushed": true,
- "head": "64900624"
- }
-}
diff --git a/docs/handoff/reports/n7-11-moss-sheets-control.json b/docs/handoff/reports/n7-11-moss-sheets-control.json
deleted file mode 100644
index 9b23a562..00000000
--- a/docs/handoff/reports/n7-11-moss-sheets-control.json
+++ /dev/null
@@ -1,131 +0,0 @@
-{
- "key": "n7-11-moss-sheets-control",
- "impl": {
- "branch": "o/n7-11-moss-sheets-control",
- "summary": "N7-11 built on top of N7-1/N7-2's layout library and plan (nothing duplicated). Storyboard gets a 'One sheet' option: the whole board is drawn as one MOSS-Image page (multi_panel layout, one object box per panel with its shot), on oss-moss-image (your GPU) or moss-image (fal). The browser shows each panel from the sheet and cuts it out (canvas crop, then upload) when you Animate or Edit it. Following the brief's 'gate behind a GPU test result', the option is shown only to the owner, marked as not yet tested on a GPU, until a result is recorded in ONE_SHEET_GPU_TEST; after that everyone gets it, up to the panel count that result records. Layers gets a new 'Re-render from layers' tool. Each visible layer's rotation-aware bounds, clipped to the canvas, plus its name or prompt become an object or character item. Layers that fill the canvas are named in the caption as the backdrop. OCR lines from the latest whole-picture text detection become text items with their exact words. The job runs this as text-to-image with the layout on the picture's nearest aspect ratio, and the result lands as a new layer on top with the original layers kept underneath. Models: open oss-moss-image; cloud moss-image (default), ideogram-4-5 and flux-3. The existing planLayout compiles the layout per model and turns prompt expansion and the enhancer off. The colour / depth control part was not built: it needs the ComfyUI pin bump.",
- "built": [
- "src/lib/catalog/storyboard.ts: SHEET_MODELS, SHEET_ASPECTS, SHEET_GUTTER, ONE_SHEET_GPU_TEST (null) + sheetPanelLimit(owner), sheetGrid (picks the cols/rows and sheet aspect that give the panels the most area, keeps each panel at its own shape, centres a short last row), sheetCrop/sheetCrops (whole pixels, rounded inward), sheetPanelStyle (CSS background crop), sheetCaption, planOneSheet (one FrameRequest with params.extra.layout and frame.sheet; refuses references)",
- "src/lib/catalog/types.ts: GenerationRequest.frame.sheet {cols, rows, aspect, panels[{scene, box}]}",
- "src/server/storyboard.ts: body field sheet:boolean; boardFrames() routes estimate and create to planOneSheet (a look is refused); estimates still go through priceAs on the existing route",
- "src/components/storyboard-view.tsx: SheetPill ('Frame by frame' / 'One sheet'), shown only when sheetPanelLimit > 0. The owner check waits for hydration. With One sheet on, references, look, partner and next-scene pickers are hidden, the count is capped, and the price reads 'N panels · 1 sheet'. The intro line and hint describe the sheet, and the board view shows SheetPanels (panel tiles cropped from the sheet; Animate and Edit cut the panel out in the browser, upload it and open /video or /edit)",
- "src/lib/layers.ts: LayerTool 'rerender', TOOL_LABELS, TOOL_MODELS.rerender, APPLIES_TO_DOC, settings.layout, RERENDER_MAX_LAYERS=32 / RERENDER_MAX_TEXT=16, PlacedText, layersLayout(doc, text, words)",
- "src/server/layers.ts: JobInputSchema tool 'rerender' + settings.layout; jobSteps case 'rerender' (readLayout, at most 48 boxes, t2i with the layout, nearestAspect on a log scale); nearestAspect exported",
- "src/components/layers: Re-render tool in the rail (RerenderTool in tools.tsx: counts of layers, text lines and backdrop; optional description; 'Read the text first' runs text-detect on the whole picture; a 'Keep the text word for word' switch; model picker; price; run). editor-context gets ToolId and TOOL_FOR_JOB. layers-editor no longer renders or uploads a picture for rerender. apply.ts lands the result as a 'Re-render' layer covering the canvas",
- "tests/moss-sheets.test.ts (19 tests), tests/layers.test.ts OPS map + rerender: ['t2i'], tests/e2e/moss-sheets.mjs"
- ],
- "tests": {
- "targeted": "tests/moss-sheets.test.ts 19/19. layers*, storyboard*, layout*, public-signup* all pass (228 tests in that run before the layers.test OPS fix, then layers.test 42/42)",
- "browser": "node tests/e2e/moss-sheets.mjs against pnpm dev -p 3461 (FUOBE_DEMO_MODE=on, own data dir), passed. Storyboard at 1440 and 390 px in light and dark: One sheet renders, is reached by keyboard and by tap at 390 px, hides references and the next-frame picker, shows 'Placeholder · free' and '4 panels · 1 sheet', and nothing scrolls sideways. A 4-panel sheet was generated and its panels showed as frames with Animate and Edit. Layers at 1440 px in light and dark: the tool is reached by keyboard and lists 3 layers plus 1 backdrop after a demo decomposition; the run landed the 'Re-render' layer on top. Console errors failed the run; one hydration mismatch it caught was fixed. Server stopped and .next deleted",
- "final": "npx next typegen exit 0. pnpm typecheck exit 0 (run with NODE_OPTIONS=--max-old-space-size=6144; the default heap ran out of memory once while ComfyUI was starting). pnpm lint exit 0 (3 warnings, none in files this package changed). Full vitest --maxWorkers=2 exit 1: 8 failed / 5074 passed. 6 of the 8 are the known rule-8 failures (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack). The other 2, picker-covers and preset-covers, are rule-12 timeouts and pass when rerun alone (36/36). No failures belong to this package"
- },
- "left": [
- "Render quality is unverified: no GPU and no fal key. One-sheet panels at 1K about 1 MP (each of 8 panels comes out around 300 px), how well MOSS follows multi_panel boxes, and how Ideogram 4.5 / FLUX.3 place layer boxes all wait for a GPU render or a fal key.",
- "One sheet stays owner-only until someone renders it on a GPU and sets ONE_SHEET_GPU_TEST {date, gpu, maxPanels} in src/lib/catalog/storyboard.ts.",
- "'Make the film' is not offered for a one-sheet board, because the film route chains frame generations and a sheet is one generation. Filming a sheet would need the crops stored as frames on the server.",
- "Retrying a failed sheet re-posts through /api/generations, whose schema drops request.frame (as it already does for ordinary storyboard frames), so the retried picture shows as a plain frame.",
- "Layers' editor is desktop-only: phones get the existing read-only view, so the Re-render tool has no 390 px or touch check.",
- "Not built (owner's or integrator's call): the ComfyUI pin bump to >= v0.43.1 (086099f5; requires comfyui-workflow-templates==0.11.98 and a full library re-validation). After it, the Sketch editor's draw mode can feed MOSS colour regions or a depth map through core MOSSImageControl with Comfy-Org's loras/moss_image_color_depth_control (0.313 GB, darask0, Apache-2.0; training depth from Depth Anything V2 Large, CC-BY-NC-4.0, information only). That needs a new graph (scripts/comfy entry plus model-pins.json pin) and a GPU test. There is no hosted equivalent, so the cloud keeps the box layout.",
- "No new ComfyUI graph, node pack, migration or route: no changes to requirements.json, packs.json, model-pins.json, STUDIO_ROWS or the public sign-up tables. Both features use existing routes (POST /api/storyboards, /api/storyboards/estimate, /api/layers/:id/jobs), which already follow the guest/account rules."
- ],
- "docsNotes": [
- "FEATURES/STATUS: Storyboard 'One sheet' (MOSS-Image on both engines; owner-only and marked as not yet tested on a GPU until a GPU result is recorded; panels cut out in the browser). Layers 'Re-render from layers' (MOSS-Image on both engines, plus Ideogram 4.5 and FLUX.3 in the cloud; layer boxes and OCR text become a layout).",
- "Brief out of date: the coordinator said n7-8 (layouts everywhere) was merged into the base, but origin/o/n7-8-layouts-everywhere is not an ancestor of origin/claude/fuobe-parity-4 at 3afb3bce, which is what this branch is built on. This package touches none of n7-8's files and stays additive. rotatedBounds is at L512 in src/lib/layers.ts, not L479.",
- "Already there before this package: compileMoss with canvas multi_panel, readLayout, planLayout (compile at the render size, expansion and enhancer off, exact size on both engines), oss-moss-image / moss-image in the catalog, rotatedBounds, the text-detect / OCR pipeline (textBlocksFrom, placeTextBlocks)."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "file": "src/server/layers.ts",
- "line": 385,
- "title": "Re-render: the backdrop is dropped from the prompt whenever the person types a description",
- "detail": "layersLayout(doc, text, words) builds the caption as '<words>. Behind everything: <backdrop>.' when words are given, and the tool shows '· N backdrop layer described in words'. But RerenderTool sends prompt: words.trim(), and jobSteps uses `prompt || layout.summary.caption`. planLayout then replaces the draft caption with that prompt. So the 'Behind everything: …' part never reaches the model. Verified with a scratch probe: a full-canvas layer named 'a beach at dusk' plus words 'warm photo' gives the draft caption 'warm photo. Behind everything: a beach at dusk.', but the planned moss-image prompt contains no 'beach'. Fix: let the layout's caption win for rerender (send no separate prompt, or have jobSteps use layout.summary.caption when the layout carries one), and add a test that a backdrop survives typed words."
- },
- {
- "severity": "low",
- "file": "src/lib/layers.ts",
- "line": 1230,
- "title": "A second re-render treats the first result as the backdrop named 'Re-render'",
- "detail": "apply.ts lands the result as a visible, opaque, full-canvas node named 'Re-render', and its prompt goes on the revision, not on node.prompt. On the next run layersLayout counts it as a backdrop (area >= 0.9). 'Re-render' is not in GENERIC_NAME, so the caption says 'Behind everything: Re-render.' and the status line counts an extra backdrop layer. That layer also hides every layer the run boxes. Either skip earlier re-render layers (or every hidden-by-cover result) or add 're-render' to GENERIC_NAME."
- },
- {
- "severity": "low",
- "file": "src/lib/layers.ts",
- "line": 1236,
- "title": "A sliver of a layer left on the canvas fails the whole re-render with 'Box 1 has no size: draw it again'",
- "detail": "intersect() keeps any positive overlap, but frac() rounds to 1e-6, so a layer whose on-canvas part is thinner than about 1e-6 of the canvas produces a zero-width box. validateLayout then refuses the run with a message that makes no sense in Layers. Verified with a probe: a 4000 px canvas with a layer at x=3999.9999 gives box [1,0,1,0.0125] and 'Box 1 has no size: draw it again'. This is rare, but the fix is cheap: drop boxes under about 1 px in layersLayout."
- },
- {
- "severity": "low",
- "file": "src/components/storyboard-view.tsx",
- "line": 379,
- "title": "A failed or cancelled sheet's header says 'on the way'",
- "detail": "The header reads `${done ? 'done' : 'on the way'}`, and done counts only succeeded generations. A failed or cancelled sheet therefore shows 'N panels on one sheet · on the way' next to the FailedTile. It should say failed when first.status is failed or canceled. Retrying, as the implementer noted, re-posts through /api/generations, whose schema drops request.frame, so the retried sheet shows as a plain frame."
- },
- {
- "severity": "low",
- "file": "src/server/storyboard.ts",
- "line": 89,
- "title": "The One sheet gate and the panel cap are enforced only in the browser",
- "detail": "sheetPanelLimit / ONE_SHEET_GPU_TEST only hide the pill and cap the counter in the UI. POST /api/storyboards and /estimate accept sheet:true with up to MAX_FRAMES panels from any caller allowed to reach them. Today this is harmless, because POST /api/storyboards is a library change and so owner-only (tests/public-signup.test.ts storyboards family). Once a GPU result is recorded, though, the recorded maxPanels is not enforced server-side. planOneSheet could clamp to sheetPanelLimit(true) instead. Also, after a test with maxPanels < 8, manual mode silently drops scenes past the limit that were written before One sheet was picked (filled.slice(0, sheetLimit)) without saying so."
- }
- ],
- "checks": {
- "diff_reviewed": "git diff 3afb3bce..HEAD (4 commits, 13 files): src/lib/catalog/storyboard.ts, types.ts, src/lib/layers.ts, src/server/layers.ts, src/server/storyboard.ts, src/components/storyboard-view.tsx, src/components/layers/{apply,editor-context,layers-editor,tools}.tsx, tests/moss-sheets.test.ts, tests/layers.test.ts, tests/e2e/moss-sheets.mjs. Traced: planGeneration -> planLayout (layout compiled at the render size, enhancePrompt off, image_size / width-height set); layoutCanvas and IMG_AR versus SHEET_ASPECTS (all 10 accepted by oss-moss-image and fal moss-image); the film button is hidden for sheet boards (frames.length is 1); /video?image= and /edit?image= deep links match the existing FrameTile.",
- "scratch_probe": "Vitest probe in the scratchpad (repo untouched). Every panel count 1-8 at 16:9, 9:16, 1:1, 21:9, 4:3 and auto on both engines plans without error (8 x 16:9 gives a 2x4 grid on a 4:5 sheet at 912x1152, prompt 1387 chars). A maximal rerender (32 layers + 16 text lines) plans on moss-image, oss-moss-image, ideogram-4-5 and flux-3 (prompts 6-10.6k chars; fal/Replicate prompt limits are unverified). The probe confirmed the backdrop-dropped and sliver-box findings.",
- "public_signup": "No new routes. POST /api/storyboards is in the storyboards library family (owner-only), /api/storyboards/estimate is in ESTIMATES (priceAs), and Layers jobs are LIBRARY_CHANGES for accounts. Rerender reads no input file (t2i), so no tenant or account-inputs path is involved. No new model, graph, pack or LoRA, so no licence, requirements or STUDIO_ROWS changes are needed (neither /storyboard nor /layers has a pre-flight row on the base, which is a pre-existing gap). No Higgsfield use, no committed media.",
- "targeted_vitest": "tests/moss-sheets, layers*, storyboard*, layout*, public-signup*: 13 files, 247/247 passed",
- "typecheck": "npx next typegen exit 0; NODE_OPTIONS=--max-old-space-size=6144 pnpm typecheck exit 0",
- "lint": "eslint on every changed file exit 0",
- "full_vitest": "The one allowed run (FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2) was cut off by the usage-limit interruption before it printed a summary. It was not rerun, because of the one-full-run limit. The failures it reported before the cut were only the rule-8 known ones: soul-runs (2), dop-originals, preset-featured, comfy-reuse and split-soundtrack. The implementer's full run reported 8 failures: those 6 plus picker-covers and preset-covers, which are rule-12 timeouts.",
- "browser": "Not rerun by the reviewer. Reviewed tests/e2e/moss-sheets.mjs, which the implementer ran: Storyboard at 1440 and 390 in light and dark, keyboard and tap, no sideways scroll, and it fails on console errors including hydration. Layers was checked at 1440 only, because the editor is desktop-only and phones get the read-only view."
- },
- "verdict": "approve with fixes: the build matches the brief (One sheet on oss-moss-image / moss-image, gated to the owner until a GPU result is recorded; Re-render from layers on MOSS on both engines plus Ideogram 4.5 / FLUX.3 in the cloud; the colour / depth control is correctly left out and what it needs is recorded). Fix the medium finding before merge: typed words drop the backdrop description from the re-render prompt. The low findings are polish."
- },
- "fix": {
- "applied": [
- "MEDIUM (src/server/layers.ts): when the person typed words, Re-render dropped the backdrop from the prompt. The cause was that jobSteps used `prompt || layout.summary.caption`. The new rerenderCaption(caption, prompt) makes the layout's caption win: the browser builds that caption from the typed words plus 'Behind everything: <backdrop>'. If words come in beside a caption that doesn't already start with them (an API caller), they are put in front of it, so neither the words nor the backdrop is lost. Test: a full-canvas 'a beach at dusk' layer plus the words 'warm photo' gives the request prompt 'warm photo. Behind everything: a beach at dusk.' on oss-moss-image, moss-image, ideogram-4-5 and flux-3, and the planned prompt contains 'a beach at dusk'. Also covers rerenderCaption's edge cases. The existing assertion for a typed prompt beside an auto caption was updated to match.",
- "LOW (src/lib/layers.ts): a second re-render counted the first result as a backdrop named 'Re-render'. layersLayout now skips any node whose active revision label is TOOL_LABELS.rerender. 're-render' is added to GENERIC_NAME, so a renamed or copied one reads as 'a picture element'. RerenderTool now sends TOOL_LABELS.rerender as the job label instead of a literal string. Test added.",
- "LOW (src/lib/layers.ts): a sliver of a layer on the canvas failed the whole run with 'Box 1 has no size'. layersLayout now keeps a layer or text box only when its part on the canvas is at least 1 px each way. Test: a layer at x=399.9999 on a 400 px canvas and a text box 0.5 px wide are both dropped, and the job plans without an error.",
- "LOW (src/components/storyboard-view.tsx, src/lib/catalog/storyboard.ts): a failed or cancelled sheet's header said 'on the way'. The new sheetState(status) returns done, failed, cancelled or on the way, and the header uses it. Test added.",
- "LOW (src/lib/catalog/storyboard.ts): the panel cap was enforced only in the browser. planOneSheet(input, test = ONE_SHEET_GPU_TEST) now refuses more panels than sheetPanelLimit(true, test), with 'A one-sheet board has at most N panels…', and refuses everything when the recorded test allows 0. Today nothing changes, because no test is recorded and the owner gets MAX_FRAMES. Test added with a recorded 6-panel result."
- ],
- "rejected": [
- "Part of LOW #5: when a recorded GPU test allows fewer than 8 panels, manual mode silently drops scenes past the limit (filled.slice(0, sheetLimit)). Not changed: this can't happen until ONE_SHEET_GPU_TEST is set, and the owner today gets all 8. Recorded in 'left'.",
- "Part of LOW #4: a retried sheet re-posts through /api/generations, whose schema drops request.frame. Not changed: this already happens for ordinary storyboard frames, and fixing it means changing the shared generations schema (a recipe-fidelity hot file). Already recorded by the implementer."
- ],
- "checks": {
- "setup": "Worked in /home/user/Fuobe on o/n7-11-moss-sheets-control, as the coordinator directed. The branch is checked out there, so a separate worktree for it could not be added. The branch lists only this package's 4 commits plus 2 fix commits. claude/fuobe-parity-4 is not an ancestor, and the base was NOT merged, per the coordinator's instruction.",
- "typegen": "npx next typegen exit 0",
- "typecheck": "NODE_OPTIONS=--max-old-space-size=6144 pnpm typecheck exit 0",
- "lint": "pnpm lint exit 0 (3 warnings, none in changed files)",
- "targeted_vitest": "tests/moss-sheets.test.ts 24/24. Together with layers*, storyboard*, layout* and public-signup*: 13 files, 252/252, exit 0",
- "full_vitest": "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2 exit 1: 7 failed / 5080 passed / 4 skipped. 6 are known rule-8 failures: soul-runs x2, dop-originals, preset-featured, comfy-reuse, split-soundtrack. The 7th, preset-covers, is a rule-12 timeout and passes alone (11/11). tests/library.test.ts also reported an afterAll hook timeout under load while all 36 of its tests passed, and it passes alone (36/36). No failure belongs to this package.",
- "browser": "Not rerun: the changes are a header string, server and library logic, and a job label, all covered by unit tests.",
- "tree": ".next deleted; git status clean; nothing pushed"
- },
- "finalSummary": "Fixed the medium finding: typed words no longer drop the backdrop from the Re-render prompt. All four low findings were confirmed and fixed (the UI-only half of #5 is deferred), each with a test in tests/moss-sheets.test.ts. Open engine (your GPU): One sheet on oss-moss-image and Re-render on oss-moss-image are built and plan correctly; render quality is unverified because there is no GPU. Cloud: One sheet on fal moss-image and Re-render on moss-image, ideogram-4-5 and flux-3 are built and plan correctly; not run, because there is no fal key. Public sign-up: guests browse read-only. POST /api/storyboards and Layers jobs are owner-only library changes (403 for accounts). The estimate goes through priceAs. One sheet stays owner-only until a GPU result is recorded, and that recorded panel count is now also held on the server. No routes, graphs, packs or migrations were added.",
- "left": [
- "Merge claude/fuobe-parity-4 into the branch (the coordinator's job; the base is not an ancestor now).",
- "Render quality on a GPU or with a fal key: how well MOSS follows the multi_panel boxes, panel resolution, and how Ideogram 4.5 and FLUX.3 place the layer boxes.",
- "Set ONE_SHEET_GPU_TEST after a GPU render. If its maxPanels is under 8, make manual mode say when scenes past the limit are dropped instead of slicing them silently.",
- "A retried sheet comes back as a plain frame, because /api/generations drops request.frame.",
- "'Make the film' is not offered for a one-sheet board.",
- "ComfyUI pin bump (>= v0.43.1) and the MOSS colour/depth control: not built; needs the owner's OK and a GPU test.",
- "The first fix commit includes the whole updated test file, so its storyboard tests only pass from the second commit on."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/n7-11-moss-sheets-control"
- ],
- "notMerged": [],
- "conflicts": "none",
- "checks": "batch of 6 (n7-11, o12 re-merge, pika-flex, keying, rtx-video, speech-edit): typecheck 0, lint 0, vitest 5612 passed, 8 failed (6 main known + blockout and moderation-hook load timeouts, 41/41 alone); requirements budget raised to 288/36 KB (a150159e); each merge checked by an independent verifier",
- "pushed": true,
- "head": "a150159e"
- }
-}
diff --git a/docs/handoff/reports/n7-9-worldcast-worker.json b/docs/handoff/reports/n7-9-worldcast-worker.json
deleted file mode 100644
index 3a09cf4c..00000000
--- a/docs/handoff/reports/n7-9-worldcast-worker.json
+++ /dev/null
@@ -1,160 +0,0 @@
-{
- "key": "n7-9-worldcast-worker",
- "impl": {
- "branch": "o/n7-9-worldcast-worker",
- "summary": "WorldCast now sits behind the Fly path, Turnaround / Fly around and the exact orbits on the open engine. It runs as a worker on the owner's GPU, with WORLDCAST_URL set in Settings → Open-source engine beside the isolated worker. While the worker answers, the buttons plan this run: MoGe 2 depth, a SAM 3.1 person mask for the still and for each view, then one WorldCast case. If no worker answers, the run stays on Uni3C or Frames and says \"Runs on Uni3C: add a WorldCast worker (48 GB+) for sides that match your photos\" (Turnaround says \"Runs on Frames: …\"). Fuobe builds each case itself: a 480×832 centre crop, 81 OpenCV camera-to-world poses plus the pixel intrinsic, render.mp4 and render_mask.mp4 at 15 fps from the server's point-cloud splat, the anchors with their masks, and ring cameras for the anchors. Correction: WorldCast's anchor names say where the camera stands, not which side of the body you see. The demo case's aligned cameras and its crops show this, so the person's own right side is WorldCast's left_side (270°). worldcastAnchor and its test were fixed to match, and a correction note was added to the research doc. Accounts and guests never reach the worker: accountRun answers own-gpu-tool, and visitors get no worker wording. This package added no new routes or migrations. Five signed commits, pushed.",
- "built": [
- "src/lib/worldcast.ts: the pure case builder. WORLDCAST_RUN (81 frames, 15 fps, 480×832, 50 steps, cfg 5, shift 2), worldcastLayout/readLayout, imageSlots, worldcastCrop/worldcastFov, cam_info (c2w), alignedAnchors (w2c ring cameras, first_frame included), anchorsMeta, the multipart parts and caseProblem checks. WORLDCAST and worldcastAnchor moved here from turnaround.ts (still re-exported there) to avoid an import cycle, and the side → view mapping is corrected: front→front 0°, right→left_side 270° (signed −90°), back→back 180°, left→right_side 90°.",
- "src/server/worldcast.ts: the worker client. Health check with a 60 s cache (refreshWorldcast / worldcastAnswers / worldcastDepths), submitCase as multipart, jobStatus, jobVideo / jobVideoUrl, cancelJob, and submitDepth / jobDepthUrl. It refuses to run inside an account's tenant. src/server/worldcast-on.ts gives the planners their context: true, false, or undefined for visitors or when WorldCast is switched off.",
- "src/server/worldcast-case.ts: builds the case on the server with sharp. It crops the still and binarises its mask, crops the MoGe depth the same way, builds the point cloud with the cropped field of view, runs framePoses for 81 frames, then splatFrame with the new hole-mask output and two ffmpeg encodes. Each anchor keeps its whole picture plus a 0/255 mask.",
- "A new ProviderId 'worldcast' with an adapter in src/server/providers/worldcast.ts (inputs held as data URIs until submit; endpoint 'cases' or 'depth/<model>'; poll, cancel and test). providerEngine maps it to the open engine, and its routes take their licence from ModelDef.licence. WorldCast runs time out after 3 hours instead of 45 minutes.",
- "Catalog (all hidden, open engine): oss-worldcast (Apache-2.0, with the SpatialVID academic-only note), oss-depth-pro (Apple research licence, non-commercial), oss-vggt-omega (FAIR Noncommercial, gated) and oss-person-mask. Each has its row and switch in Models & licences.",
- "A new ComfyUI graph, image-person-mask-sam3 (core SAM3_Detect + MaskToImage, the pinned sam3.1_multiplex_fp16), built through scripts/comfy and validated with /prompt on the live CPU ComfyUI. It is in manifest.json, validation-state.json and requirements.json; the regenerated object_info.subset.json was reverted to the base's because every node class was already in it.",
- "src/lib/catalog/worldcast-plan.ts: worldcastSteps (depth → masks → main, with chain slots placed by `at`), worldcastFallback, worldcastNote, WORLDCAST_AFTER (FPS Boost / RIFE to 24 fps and the upscalers in Upscale) and WORLDCAST_DEPTH (MoGe 2 by default; Depth Pro or VGGT-Omega through the worker's POST /depth).",
- "Fly around (planFlyAround(input, ctx)) is used by DoP exact orbits, Cinema exact orbits, Image to 3D's Film it photoreal and Assist's fly_around. It takes WorldCast with ctx.worldcast, plus new optional `sides` and `depth` inputs in FlyAroundSchema. The server blocks Depth Pro or VGGT-Omega when the worker doesn't list them.",
- "Turnaround: a new open-engine route 'worldcast', offered and chosen by default only when the worker answers. The front view is the first frame and every side with a picture becomes an anchor; drawn sides are added only when asked. Frames says the fallback line, and the GPU line reads 48 GB. Cinema's Turnaround take passes the same context.",
- "Cinema's Fly path: planPath plans WorldCast with ctx.worldcast and needs no browser recording. scene-viewer skips the recording, and PathOptions shows 'About 5.4 s · portrait 480 × 832, 81 frames at 15 fps with WorldCast'. The project GET returns context.worldcast to the owner only.",
- "Settings: a WorldCast worker URL field beside the isolated worker, in settings-form LocalComfy and in OwnerServerComfy (advanced or hosted). Save & test runs through the ComfyUI provider's test with focus worldcastUrl. Also covered: address validation (connections.ts), the hosted-page address refusal, and the install hosts (gpu/hosts.ts).",
- "docs/workers/worldcast.md: the contract, written like tribe-v2.md. It covers GET /health, POST /cases (multipart parts table), POST /depth, GET /jobs/{id}, GET /jobs/{id}/video, DELETE /jobs/{id}, the side→anchor table, how Fuobe prepares a case, and the no_padding_black crop rules read from demo_case/ and the pipeline: background blacked out, crop tight to the mask's bounding box, mask 0/255 at the same size.",
- "workers/worldcast/: server.py (FastAPI; imports WorldCast @ 7ccf2e0d from its own clone and virtualenv with demo.py's exact anchor-drop wiring; lays the case out like demo_case/ and cuts the no_padding_black crops; one job at a time; cancel; Depth Pro through apple/ml-depth-pro when installed), requirements.txt and a README. The README covers pinned installs (torch 2.8.0+cu128, transformers 5.8.1, ly56/worldcast @ 27635f27, Wan2.1-I2V-14B-720P @ 8823af45, both checkpoint byte sizes), running demo_case_traj5.json first, the environment variables and the licences."
- ],
- "tests": "Verified by tests. New files: tests/worldcast-case.test.ts (layout and side map, slots, crop and FOV, cam_info conventions, the ring cameras checked against the demo's geometry, multipart parts, refusals), tests/worldcast-worker.test.ts (the client and provider against a stand-in worker: health and cache, submit, poll, download, the worker's errors passed on, 404 and unknown status, bad ids, cancel, depth jobs, refusing an account's run, worker unreachable) and tests/worldcast-plan.test.ts (step chains; Fly around, Turnaround and Cinema Fly path with a worker, without one, and for visitors; the ModelDefs' visibility and licences; accountRun → own-gpu-tool; visitors get no context; the server case built with real sharp and ffmpeg, checked by ffprobe at 480×832, 15/1 fps, 81 frames). Updated tests: turnaround.test.ts (the corrected side map), catalog.test.ts (the worker counts as the open engine), no-higgsfield.test.ts (KNOWN providers include worldcast) and qma-angles.test.ts (ROUTES_ON.open). Full Vitest ran once with FUOBE_ACCOUNT_DISK_FREE_GB=1 and --maxWorkers=2: 11 failed, 5397 passed, 4 skipped. Four of the 11 failures were mine (no-higgsfield, qma-angles, and two in comfy-library-notes because the graph note mentioned the package id); I fixed them and they pass when rerun alone. moderation-hook failed under load and passed when rerun alone. The other 6 failures are the known ones from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2) and split-soundtrack. Typecheck is clean after npx next typegen. The graph passed /prompt validation on the live CPU ComfyUI. The browser check tests/e2e/worldcast.mjs passed 50/50 against pnpm dev in demo mode on the open engine, with a stand-in worker, at 1440 and 390 px in light and dark: the Settings row renders, Tab reaches the field, Save & test turns green, nothing scrolls sideways, the Turnaround dialog shows and selects the WorldCast route with a worker and the Frames fallback line without one, a finger drag scrolls the dialog at 390 px, the planner answers both ways through the API, and there were no console or page errors. The server was stopped and .next deleted. Nothing ran on a GPU and WorldCast itself was never run: its code was only read, at the pinned commit.",
- "left": [
- "GPU only, not verifiable here: any real WorldCast run (48 GB+, the 82 GB base, run time unknown), whether the reference server works end to end, quality with MoGe depth and ring-guessed anchor cameras (versus Depth Pro / VGGT-Omega, or no aligned cameras), and whether Fuobe's c2w path and splat render match WorldCast's training distribution closely enough. The worker README says to run demo_case_traj5.json first.",
- "VGGT-Omega is recorded (ModelDef, licence, switch, a 'vggt-omega' slot in the contract) but the reference server doesn't run it: its gated code and API weren't read. Depth Pro's worker code follows apple/ml-depth-pro's documented API and was never run.",
- "Depth Anything 3 metric-large was not built: MoGe 2, already pinned, is the default. DA3 metric-large isn't pinned (the base only has mono_large) and would need a new graph and model pin.",
- "Canvas's Fly around node stays on Uni3C: its step mapping counts each step's inputs.images, so WorldCast's slot layout needs its own mapping there. Image to 3D's browser render isn't used by WorldCast, which renders from MoGe depth instead.",
- "Fly around and Cinema's Fly path have no named views in their UIs yet, so on those routes WorldCast films from the still alone (first-frame anchor only; no body anchors, so no first-frame anchor either: the pipeline skips anchors). The Turnaround route is the one that uses the views. FlyAroundSchema accepts `sides` for API callers.",
- "When WorldCast is the route, the Turnaround dialog still offers Shape (Portrait / Landscape), though WorldCast is always portrait. pathTake still records the Uni3C length (81/16 s) for a WorldCast Fly-path take.",
- "No GPU pre-flight row was added: WorldCast isn't a ComfyUI graph and isn't a new page. The person-mask graph does reach requirements.json. A 'WorldCast worker' line on /connect could follow.",
- "tests/comfy-library-4.test.ts was not edited: the new graph is validated."
- ],
- "docsNotes": "These notes are for the docs pass. STATUS.md: N7-9 is built; WorldCast is behind the three buttons on the open engine while a worker answers (WORLDCAST_URL), it is GPU-only with no cloud route, and the anchors are named by where the camera stands. ARCHITECTURE.md: a new provider 'worldcast' (src/server/providers/worldcast.ts), src/server/worldcast.ts, worldcast-case.ts, worldcast-on.ts, src/lib/worldcast.ts, src/lib/catalog/worldcast-plan.ts, the image-person-mask-sam3 graph, and the docs/workers/worldcast.md contract. SELF-HOSTING / DEVELOPMENT: the WORLDCAST_URL env and setting, and workers/worldcast/README.md. FEATURES.md: Fly path, Turnaround and exact orbits film with WorldCast on a 48 GB+ GPU. CREDITS.md: PixCtrol/WorldCast (Apache-2.0), plus Depth Pro and VGGT-Omega as optional and non-commercial. Research correction made in new-models-7.md §3.11 (left/right). Where the brief was out of date: worldcast_pipeline.py's crop logic is in _encode_per_view_nopad as well as L842-869 (which loads the render and camera); DA3 metric-large is not pinned at the base (only mono_large); the turnaround's side map at the base (right→right_side) contradicted the demo case's geometry; the Settings 'isolated worker URL' row lives in settings-form.tsx LocalComfy and connect-choice.tsx OwnerServerComfy.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "verdict": "PLAUSIBLE",
- "file": "src/server/worldcast-case.ts",
- "line": 84,
- "summary": "Anchor pictures go to the worker at full size, and the worker cuts its no_padding_black crop at that size. The anchors' VAE latents and token counts grow with the upload. WorldCast was trained on crops about 540 x 1320 (the demo's body_view_*.png are cut from 768 x 1344 frames).",
- "failure_scenario": "A Turnaround with a 4000 x 6000 phone photo as the back view: buildCase sends the whole picture (sharp .rotate().removeAlpha(), no resize). server.py nopad() crops it to the person box, about 2500 x 5000. worldcast_pipeline._encode_per_view_nopad VAE-encodes that at its natural size rounded up to 16 and adds about 49k tokens for one anchor next to the 14B DiT. Likely result: CUDA OOM on a 48-80 GB card, or a run far outside the training distribution. Fix: scale each anchor and its mask so the person crop is about the first frame's scale (for example a long side of at most 1344 px) in buildCase, or in nopad() before saving."
- },
- {
- "severity": "medium",
- "verdict": "CONFIRMED",
- "file": "src/lib/catalog/fly-around.ts",
- "line": 131,
- "summary": "Fly around, the DoP / Cinema exact orbits and Cinema's Fly path send WorldCast no anchors at all. Without a body view the pipeline also drops the first-frame anchor, so these routes run the released anchor-drop checkpoint with no anchor tokens. That mode was never trained.",
- "failure_scenario": "planFlyAround(..., {worldcast:true}) without `sides` (always the case from the UIs) gives worldcastSteps anchors []. caseParts sends anchors \"[]\", and server.py write_case returns anchors=\"\". In worldcast_pipeline.py WorldCast_prepare_viewpoint_anchors.process, L443 `if not viewpoint_anchors_path: return {}` skips everything, including use_first_frame_anchor (an empty anchors dir also returns {} at L473, before the first frame is added). WorldCast's 'front' is by definition the first frame's camera (demo body_views_meta: front = source_frame 0, azimuth 0). The still, whose SAM mask is already computed, can always be sent as the 'front' anchor. That gives the trained first_frame + front slots, and zero-fill takes the rest."
- },
- {
- "severity": "medium",
- "verdict": "CONFIRMED",
- "file": "docs/workers/worldcast.md",
- "line": 1,
- "summary": "The worker contract and the reference server have no authentication. On hosted pages, Settings offers an https://... address for the worker. Anyone who can reach it can queue jobs on the owner's 48 GB+ GPU or cancel the owner's jobs. The 512 MB upload cap is only checked against the Content-Length header.",
- "failure_scenario": "The owner of a hosted install exposes the worker at https://gpu.example:8190, as the hosted placeholder suggests. A stranger POSTs /cases or /depth in a loop and holds the single job queue. A chunked request has no Content-Length, so it skips read_form's MAX_UPLOAD check and the whole body is read into memory. ComfyUI has comfyToken for this, and the worker has nothing. Fix: a secret worldcastToken setting sent as a Bearer header, checked by server.py, plus README guidance to bind 127.0.0.1 or put the worker behind a tunnel."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/server/worldcast-on.ts",
- "line": 16,
- "summary": "worldcastContext only checks that oss-worldcast is switched on. If the admin switches off a helper step (oss-person-mask, or oss-scene-moge) in Models & licences, the move is blocked instead of falling back to Uni3C / Frames.",
- "failure_scenario": "WorldCast is on and the worker answers, and the admin switches off 'SAM 3.1 person mask'. src/server/fly-around.ts plan() finds the off step and returns 'This move is switched off on this studio' for every exact orbit and Fly around. Uni3C would still run."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/lib/catalog/cinema.ts",
- "line": 2200,
- "summary": "pathTake reads plan.steps[0] and records the Uni3C length (PATH_FRAMES / PATH_FPS, about 5.06 s) for a WorldCast Fly-path take. WorldCast's steps[0] is the depth step, and its clip is 5.4 s at 15 fps.",
- "failure_scenario": "A Fly-path take filmed with WorldCast is saved with duration 5.0625 and the keys taken from input.path (the fallback), not the planned cameraPath. The implementer listed this under 'left'."
- },
- {
- "severity": "low",
- "verdict": "PLAUSIBLE",
- "file": "src/lib/catalog/worldcast-plan.ts",
- "line": 41,
- "summary": "The brief asks to offer RIFE to 24 fps and the existing upscalers after a WorldCast clip. The build only adds a note string (WORLDCAST_AFTER), with no action or pre-filled step.",
- "failure_scenario": "After a WorldCast run the person reads 'In Upscale, FPS Boost (RIFE) takes the clip to 24 fps…'. They have to move the clip to Upscale by hand, and no button sends it there."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/components/settings-form.tsx",
- "line": 493,
- "summary": "Rule 2 lists owner Settings sections as hot files, and this one was edited. The change is a small field insertion (WorldcastField in LocalComfy) that the brief asked for explicitly. The owner should confirm it.",
- "failure_scenario": "On a merge conflict in settings-form.tsx, rule 2 says to take the base's version, and that drops the WorldCast worker URL field from Settings → Open-source engine. The OwnerServerComfy copy in connect-choice.tsx stays."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/server/gpu/tools.ts",
- "line": 88,
- "summary": "The GPU pre-flight board can't see the WorldCast worker: STUDIO_ROWS counts only comfyui and local routes, and /connect has no 'WorldCast worker' line. The UI also still offers Turnaround Shape (Portrait / Landscape) on the portrait-only WorldCast route. The implementer acknowledged both.",
- "failure_scenario": "The owner's /connect board shows Turnaround as Ready while the WorldCast worker is down. The worker's state only appears as the fallback note in the dialog."
- }
- ],
- "checks": [
- "Read the stage prompt and main-rules.md. Reviewed git diff claude/fuobe-parity-4...o/n7-9-worldcast-worker (5 commits, 60 files) and the code around it. HEAD 3958bc0b equals origin/o/n7-9-worldcast-worker (pushed). Commits are SSH-signed (not verifiable locally: no allowedSignersFile), and the messages are neutral 'Area: result'. The worktree is clean.",
- "Cloned PixCtrol/WorldCast @ 7ccf2e0d into the scratchpad and read it as data only, running none of its code. Checked server.py against demo.py: the anchor-drop wiring (BANK_CONFIG, ANCHOR_PRIORITY, ANCHOR_K, use_first_frame_anchor, zero-fill, plucker), the load_pipeline / load_checkpoint / build_bank / build_anchor_adapter calls and the pipe() kwargs all match, and progress_bar_cmd exists in __call__. The anchors / no_padding_black / person_mask layout matches _encode_per_view_nopad and resolve_semantic_anchor_paths. The aligned-camera file path matches _find_nopadblack_aligned_file.",
- "Checked the implementer's left/right correction against the demo data. In anchors_aligned_camera_info.json (w2c), inv(right_side) has translation (+0.288, −0.034, 0.225), which matches cam_info frame 28.6 (stored c2w), and inv(left_side) is (−0.298, …), which matches frame 65. The flatring cam_info is self-consistent as c2w. In first_frame.png the boy faces image-right, and body_view_right_side.png shows his face. So right_side is the camera moved to its own right, and a front-facing person's own right side is left_side. worldcastAnchor's corrected map (right→left_side 270°/−90°, left→right_side 90°) is right, and keyPose (+azimuth → +x) puts the ring cameras on the matching sides.",
- "Checked render_mask polarity by extracting frame 20 of the demo flatring render.mp4 / render_mask.mp4 with ffmpeg: white is where the render is empty, so 255 = hole, matching splatFrame's new holes output. cam_info c2w 'as stored' with invert_camera_extrinsic off matches demo.py.",
- "Public sign-up: accountRun('acct', 'worldcast') answers own-gpu-tool, and a hosted-run pool submit refuses non-comfyui providers. worldcastContext gives undefined for a tenant, ownGpu or visitor (priceAs). The worker client's guard() throws inside a tenant. The Cinema project GET sends context.worldcast to the owner only. isInstallHost now includes the worker's host, so an account can't link it. No new routes, migrations or ASSET_REFS tables. FlyAroundSchema.sides is only used on the owner's WorldCast path.",
- "Licences recorded as data: oss-worldcast (Apache-2.0 + SpatialVID note), oss-depth-pro (Apple research, commercial false), oss-vggt-omega (FAIR NC, gated); oss-person-mask takes the manifest's SAM licence through comfyFacts. routeLicence covers the worldcast provider through ModelDef.licence. No Higgsfield API, code or media; no LoRA files or preview media committed.",
- "The person-mask graph: SAM3_Detect / MaskToImage inputs match the live CPU ComfyUI's /object_info at 127.0.0.1:8188. The manifest bindings (image node 1, prompt node 3 text, threshold node 4, filenamePrefix node 6) match the JSON. requirements.json and validation-state.json have the new entry with the pinned sam3.1 checkpoint.",
- "npx next typegen && tsc --noEmit: clean.",
- "Targeted Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1). worldcast-case, worldcast-worker, worldcast-plan, turnaround, catalog, no-higgsfield, qma-angles and comfy-library-notes: 316/316 passed. account-tenant, camera-path, cinema-path, connections, fly-around, licences, model-access(-listings, -studios), public-signup(-tools, -visitors), settings-read, turnaround-api, connect-card-studios, request-body-limits and hosted-runs: 244/244 passed. The full suite and the browser check tests/e2e/worldcast.mjs were not re-run in this review.",
- "Not verifiable here: any real WorldCast run on a GPU (48 GB+, an 82 GB base), quality with MoGe depth and ring-guessed anchor cameras, and the Depth Pro worker path."
- ],
- "verdict": "changes-requested: the build is sound and the left/right correction is right (verified against the demo case's cameras and images). Before merge, fix the two medium WorldCast-input issues: scale the anchors to training size, and send the still as the 'front' anchor so the Fly around / exact orbit / Fly path routes are not anchor-less. Also add a worker token, or document that the worker must not be exposed. The low findings can follow."
- },
- "fix": {
- "applied": [
- "Medium (Fly around, the exact orbits and Cinema's Fly path sent no anchors, so the pipeline dropped every anchor, the first frame's included, which the checkpoint was never trained for). Confirmed. worldcastSteps now always sends the still as the 'front' anchor (with its own mask-front SAM step) when no front view is given. Turnaround is unchanged because it already sent the front. Tests: Fly around with and without named sides, and Cinema's Fly path layout is ['front'] (tests/worldcast-plan.test.ts).",
- "Medium (anchors were sent at full photo size, outside WorldCast's training scale, with a risk of running out of memory). Confirmed as plausible. buildCase now scales each anchor and its mask to a longest side of ANCHOR_MAX_SIDE = 1344 px (the demo's 768 × 1344 source frames) and never enlarges them. Test: a 2000 × 3000 view and a 500 × 750 mask both arrive at 896 × 1344. docs/workers/worldcast.md says the same.",
- "Medium (the worker had no authentication, and a chunked upload got past the 512 MB cap). Confirmed. New secret setting worldcastToken (env WORLDCAST_TOKEN, src/server/settings.ts). The client sends Authorization: Bearer on every call, and the provider puts the header on the clip and depth downloads. server.py checks WORLDCAST_TOKEN on every route with hmac.compare_digest and answers 401 without it. It answers 411 to a request with no Content-Length, keeps the 413 cap, and warns when it listens beyond localhost without a token. The README and the contract document all of this. Test: the stand-in worker sees no header without a token, then 'Bearer s3cret' on health, submit, status and cancel, and the download output carries the header (tests/worldcast-worker.test.ts).",
- "Low (switching off a helper step blocked the move instead of falling back). Confirmed. worldcastContext and worldcastContextNow now need oss-worldcast, oss-person-mask and oss-scene-moge all switched on. With any of them off, the buttons quietly keep their Uni3C / Frames run. Test: each one switched off in turn gives an undefined context.",
- "Low (pathTake recorded the Uni3C length for a WorldCast take). Confirmed. pathTake now reads the film step (the last one) for a WorldCast plan and records 81/15 s with the planned cameraPath. Test in worldcast-plan.test.ts.",
- "Low (RIFE was offered only as text). Partly addressed: every finished video already has the generic 'Upscale' next step (src/lib/output-actions.ts, /upscale/video?video=…), which holds FPS Boost (RIFE) and the upscalers. The WORLDCAST_AFTER note now points at that button."
- ],
- "rejected": [
- "Low: settings-form.tsx is a hot file (rule 2). The brief explicitly asked for the field, and it stays a small insertion. No change. This needs the owner's confirmation and is listed under left.",
- "Low: GPU pre-flight row and Turnaround Shape on the WorldCast route. WorldCast is not a new studio page or ComfyUI graph, so STUDIO_ROWS has no row type for an outside worker. The person-mask graph already reaches requirements.json. Hiding Shape is a UI polish that the implementer and reviewer both listed as follow-up. Left for later, not changed."
- ],
- "checks": [
- "Worktree case (1): the branch had only this package's 5 commits, and the base is an ancestor. pnpm install --frozen-lockfile succeeded.",
- "npx next typegen, then NODE_OPTIONS=--max-old-space-size=6144 pnpm typecheck: exit 0.",
- "pnpm lint: exit 0 (0 errors, 5 warnings that were already there in unrelated files).",
- "Targeted tests: worldcast-plan, worldcast-case, worldcast-worker, turnaround, fly-around, cinema-path, settings-read and connections all passed (worldcast-plan + worldcast-worker 19/19 after the fixes; the 8-file set passed before the last two tests were added).",
- "Full suite, run once after the container restart (FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2): 7 failed, 5404 passed, 4 skipped. The failures are the known ones from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2) and split-soundtrack. preset-covers also failed under load and passed 11/11 when rerun alone (rule 8).",
- "server.py parses (ast). It was never run here, and WorldCast was never run.",
- "Committed eae55317 with the trailer and pushed it to origin/o/n7-9-worldcast-worker (HEAD equals the remote). .next was removed and the worktree is clean."
- ],
- "finalSummary": "Open engine: when the owner's WorldCast worker (WORLDCAST_URL, and WORLDCAST_TOKEN if it is exposed) answers and WorldCast, the SAM 3.1 person mask and MoGe 2 are all switched on, Fly around, the exact orbits, Cinema's Fly path and Turnaround plan these steps: MoGe 2 depth, SAM masks, then one WorldCast case. The still is now always the front anchor. Anchors are scaled to the demo's scale, and the worker calls are authenticated. Otherwise the buttons run Uni3C / Frames, with the fallback line when only the worker is missing, and with no line when WorldCast or a step it needs is switched off. What was verified: case building, the client against a stand-in worker, plans, licences, and the earlier browser checks. What needs a GPU: any real WorldCast run (48 GB+, an 82 GB base), the reference server end to end, the Depth Pro path, and quality. Cloud engine: no WorldCast route, by the owner's GPU-only rule; the cloud's existing H3 routes are unchanged. Guests and accounts: they never reach the worker. accountRun answers own-gpu-tool, the context is undefined for a tenant, own-GPU run or visitor, the client refuses inside a tenant, and visitors see no worker wording.",
- "left": [
- "Everything on a GPU: a real WorldCast run, its memory use with 1344 px anchors, quality with MoGe depth and ring-guessed anchor cameras, and the Depth Pro / VGGT-Omega worker paths. VGGT-Omega is recorded but the reference server does not implement it.",
- "The owner should confirm the small WorldCastField insertion in settings-form.tsx (rule 2, hot file). The OwnerServerComfy copy in connect-choice.tsx does not depend on it.",
- "WORLDCAST_TOKEN is settable through the environment (or the settings key worldcast.token) but has no Settings field yet, to keep the hot settings form unchanged.",
- "There is no 'WorldCast worker' row on the /connect GPU pre-flight board. Turnaround still shows Shape (Portrait / Landscape) on the portrait-only WorldCast route.",
- "Fly around and Cinema's Fly path have no UI for naming the subject's other views yet: they send the still as the front anchor only (API callers can pass `sides`). Canvas's Fly around node stays on Uni3C.",
- "The browser check tests/e2e/worldcast.mjs was not rerun: this fix stage changed no UI. Only the wording of the after-run note changed.",
- "tests/comfy-library-4.test.ts was not edited."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/n7-9-worldcast-worker"
- ],
- "notMerged": [],
- "conflicts": "validation-state and manifest unions; requirements regenerated",
- "checks": "batch of 7 (dbs-d7, idol-5, idol-2, idol-6, n7-9, kandinsky6, n7-10): typecheck 0, lint 0, vitest 5788 passed, 6 failed (main known); each merge checked by an independent verifier; n7-10 + Pika Flex interaction fixed in 64900624",
- "pushed": true,
- "head": "64900624"
- }
-}
diff --git a/docs/handoff/reports/nm10-hy-nomas-world.json b/docs/handoff/reports/nm10-hy-nomas-world.json
deleted file mode 100644
index 48b13de9..00000000
--- a/docs/handoff/reports/nm10-hy-nomas-world.json
+++ /dev/null
@@ -1,127 +0,0 @@
-{
- "key": "nm10-hy-nomas-world",
- "impl": {
- "branch": "o/nm10-hy-nomas-world",
- "summary": "World mode on your GPU. Cinema gets a World take: you write the opening (the world in words, who the camera follows, the camera and the look), then add turns. Each turn has what changes, what the subject does, a camera move from the fly-path library (or Still) and 3-12 s. The panel has Run turn, Redo from here (the turns before it stay), a top-down view of the camera path, Export (the turns joined into one film on the open engine's packet join) and links to Sound for video and Music, because Hy-Nomas makes no sound. It runs on Hy-Nomas (Tencent, Apache-2.0) through Nynxz's ComfyUI-HyNomas port, which is pinned with its converted weights. The new pure converter src/lib/world-path.ts turns Fuobe camera paths into Tencent's trajectory (OpenCV c2ws plus normalised intrinsics at 24 fps, gains 1.0 / 2.5) and into the key script the port reads. Assist gets world_film ('a 60 s walk-through' = the opening plus four 12 s turns). There is a GPU pre-flight row 'World mode' and licence rows. Open engine only: the cloud says it runs on your GPU, and 'Paid APIs only' hides the World chip. fal's worlds models are recorded in research as different models. Nothing from the plan existed before; the camera-path library (src/lib/camera-path.ts framePoses / presets, N7-5) was reused.",
- "built": [
- "Port and weights: packs.json pins ComfyUI-HyNomas at a89e0515 (Apache-2.0, no Python deps, not in the Comfy Registry) and install-comfyui.sh installs it. model-pins.json pins nynxz/Hy-Nomas at e8ddc4bf with sha256: int8 ConvRot DiT 8.97 GB, PixelUMM VAE 15.78 GB, and the bf16 DiT 17.11 GB as optional. The text encoder qwen_2.5_vl_7b was already pinned (Comfy-Org/Qwen-Image) and is shared, so the new files come to about 24.8 GB. library.spec.mjs has PACK_CLASSES and KNOWN_MODELS entries. object_info.subset.json has the 6 Nomas node definitions, written by hand from nomas/nodes.py at the pin. manifest.json and requirements.json were rebuilt (validated:false, like the other packs that are not on the validation server).",
- "History between /prompt calls: the port keeps a world in ComfyUI's memory (the NOMAS_WORLD output plus an int8 KV cache in temp/nomas_history). Separate prompts share it only through ComfyUI's output cache, or through the Nomas Explore node's in-process sessions, which only accept keyboard input. So the graph world-hy-nomas-turn (scripts/comfy/hand-built, based on the port's nomas_world example) is rebuilt per run by src/lib/world.ts expandWorldWorkflow (expand:'world'). It holds the opening plus one NomasWorldContinue per turn up to k, with stable node ids and inputs, then TrimVideoLatent cuts off the earlier turns' latents, then VAEDecode, CreateVideo 24 fps and SaveVideo. So turn k decodes only its own frames, and ComfyUI reuses turns 0..k-1 while it still holds them. If it doesn't (another job ran, or a restart), it makes them again from the script's fixed seed and gets the same world. This is the 'whole film as N turns' fallback, made incremental.",
- "src/lib/world-path.ts: worldTrajectory (the turns chained, each starting where the last stopped), worldIntrinsic (fx=f/W, fy=f/H, cx=cy=0.5 as generate_npz_trajectories.py writes them), WORLD_SCALES {translation 1.0, rotation 2.5}, turnPoses. steerTicks/worldScripts fly a simulation of the port's Pose (W/S along the view, A/D strafe, arrows at 20°/s, mouse at 0.0024 rad/px) along the path in closed loop. Mouse-drag ticks catch up turns faster than the arrows can, and the heading carries from turn to turn. ticksScript/parseScript write and read the port's script; pathSketch gives the preview.",
- "src/lib/world.ts: the script model (opening plus turns, seed), limits (3-12 s in 0.5 s steps, 10 turns, 120 s), the port's latent arithmetic (turnLatents/latentsBefore/clipSeconds), subject → <|Subject1|>, turn state (scriptKey, clipsFromTakes with Redo-from-here cut-offs, nextTurn, canRun, redoFrom, exportClips) and the graph expansion.",
- "Catalog: new op 'world-turn' (types, labels, output video, PROMPTLESS, script check in planGeneration). New model oss-hy-nomas-world (open, hidden from the studio menus, comfy route world-hy-nomas-turn). The comfyui provider reads params.extra.world/turn, always uses the script's seed, and expands the graph.",
- "Cinema: CinemaAction 'world' with planWorld (open only: the cloud gets WORLD_OPEN_ONLY and no stand-in; notes; free) and Export through oss-join-encoded. The take remembers {turn, script, made, joined}. cinema-schemas has WorldSchema. UI: src/components/cinema/world-panel.tsx, a World chip in the prompt bar (video mode, hidden under 'Paid APIs only'), and /cinema?world=1 on the projects list and in the workspace.",
- "Assist: world_film studio tool (worldFilmSteps: each turn after the one before, then a join; refused under 'Paid APIs only'), plus a mention in the agent prompt.",
- "GPU pre-flight: STUDIO_ROWS 'World mode' (/cinema?world=1: world-turn plus the join), vramGb 24 (a guess). Licences: the workflow's licence text is Apache-2.0 for the DiT and NVIDIA One-Way Noncommercial (NON-COMMERCIAL) for the PixelUMM decoder, per the nynxz card. Qwen2.5-VL is Apache-2.0. NODE_PACKS has ComfyUI-HyNomas as Apache-2.0.",
- "Research: docs/research/new-models-10.json. The Hy-Nomas record is updated with the licence read from the LICENSE file at bb6a8ca4, the port pin and the history finding, and inFuobe is now true. Prices were added to H3 Max Director ($0.08/s, 60 s minimum, November promo), and new records were added for Abot World 0 (commercial), Lingbot World 2 (research licence) and VAST Eden Live 5B/14B ($0.0035 / $0.01 per s, 10 s minimum), all as different models whose use is the owner's call."
- ],
- "tests": [
- "New tests/world-path.test.ts (16): matrix conventions (rigid, OpenCV axes, dolly +z, truck +x, arc turning back to the subject), intrinsics, frame counts (24 fps + 1), default gains, chaining, still turns, the key script read back by the port's rules at exactly one tick per frame, W/S/A/D for dolly and trucks, heading accuracy along orbits, the figure-8 and the push-pull arc, mouse drags for fast rings, heading carried across turns, and the port's control speeds.",
- "New tests/world-mode.test.ts (21): library entry, pins, licence and install line. The template and the expanded graphs pass a node-list validator against the port's definitions (input names, required inputs, link types). Also covered: stable ids so the cache can reuse turns, trim amounts, the subject token, latent arithmetic, refusals, normalisation, turn state (stale, running, failed, Redo from here, export), the provider's bindings (script seed, trim 56), the planner (cloud refused, free open turn, join), a demo-mode API run filed as a take with take.world, the Assist 60 s film, and the STUDIO_ROWS row.",
- "Edited tests: comfy-library-4 (world-hy-nomas-turn added to the unvalidated list) and assist-context (world_film samples, and OPEN_ONLY now includes world_film).",
- "Targeted runs pass: 32 files, 602 tests (world-*, comfy-library-4/7, comfy, gpu-*, model-access, kandinsky6, idol-clean, speech-edit-comfy, blockout, camera-path, fly-around, assist-context, assist-studio-routes, public-signup(+tools), fake-local-comfy, cloud-catalog(-4), reuse-pack-pin, catalog, cinema*, licences, canvas-models).",
- "The full Vitest run (one attempt) hit the 30-minute background limit before finishing. The failures it reported before then are all on the known list: comfy-reuse, dop-originals, soul-runs (2), split-soundtrack, and preset-covers (a timeout under load).",
- "tsc --noEmit is clean, and eslint is clean on the changed files.",
- "Browser: tests/e2e/cinema-world.mjs passed against pnpm dev in demo mode. At 1440 light on the open engine it ran the opening, added a turn, previewed the path, ran turn 1 and exported. At 1440 dark on the cloud engine it showed the 'Runs on your GPU' notice with the switch. At 390 px light and dark nothing scrolls sideways. It recorded no page or console errors (no filters). The server was stopped and .next deleted.",
- "No GPU here: every speed figure is the port author's. The graph has not run live: the pack isn't installed on the CPU ComfyUI, and packs weren't installed, as the rules require."
- ],
- "left": [
- "Live run on a GPU with ComfyUI-HyNomas installed. Still unverified: that VAE Decode accepts the trimmed 5D latent, the turn speed, and that ComfyUI's cache really reuses the chain between prompts. Newer ComfyUI cache modes (LRU or RAM-pressure) should also reuse it; with --cache-none every turn regenerates the whole chain.",
- "The CPU validation server does not have the pack, so world-hy-nomas-turn stays validated:false. tests/comfy-library-4.test.ts got its one allowed edit: the new id added to the unvalidated list.",
- "Redo from here with unchanged words gives the same turn, because the port's noise is a seeded bank. A different take needs changed words or a changed move; the button's tooltip says so. A per-turn re-roll would need a port change.",
- "The port only reads camera poses, not intrinsics: worldIntrinsic exists for Tencent's .npz form, and Fuobe doesn't run Tencent's runtime. Keys can't rise straight up, so height changes are flown along the tilted view.",
- "The 24 GB VRAM figure is a guess. Tencent's 4090 configuration uses an FP8 decoder, which the port doesn't ship (it refuses Tencent's int8 file).",
- "Whether to offer fal's worlds models (H3 Max Director, Abot World 0, Lingbot World 2, Eden Live) under their own names is the owner's call; they are recorded in research only."
- ],
- "docsNotes": [
- "The brief named the text encoder as 'Comfy-Org/Qwen-Image_ComfyUI'. The pinned qwen_2.5_vl_7b.safetensors actually comes from Comfy-Org/Qwen-Image @1f12b17b, which was already in KNOWN_MODELS. The fp8_scaled variant lives in Qwen-Image_ComfyUI.",
- "Brief out of date or unclear: the 'trajectory file' is what Tencent's runtime reads; the ComfyUI port reads WASD/mouse scripts (NomasCameraPath) instead, so the converter produces both.",
- "Licence correction: Hy-Nomas itself is Apache-2.0, but the PixelUMM decoder weights (which both the converted and Tencent's files are) are under the NVIDIA One-Way Noncommercial License per nynxz's card. The PE is in Tencent's Apache-2.0 repo (~55 GB, 18 shards) and is not used.",
- "FEATURES/STATUS: Cinema → World (World chip, /cinema?world=1), Assist world_film, GPU board row 'World mode', Models & licences rows (ComfyUI-HyNomas pack Apache-2.0; workflow non-commercial flag from the PixelUMM decoder).",
- "ARCHITECTURE: src/lib/world.ts (script, turn state, expand:'world'), src/lib/world-path.ts (camera converter), op 'world-turn', CinemaAction 'world', and the take's world info.",
- "SELF-HOSTING: about 24.8 GB of new files plus the shared 16.6 GB Qwen2.5-VL; install-comfyui.sh adds ComfyUI-HyNomas."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "category": "correctness",
- "verdict": "CONFIRMED",
- "file": "src/components/cinema/world-panel.tsx",
- "line": 106,
- "summary": "The browser matches a turn's clip against the raw script it is editing, but the server stamps the take with the key of the cleaned-up script. When the two differ, a turn that finished correctly shows as 'Changed: run it again'. The next turn and Export then stay blocked until the page is reloaded.",
- "failure_scenario": "Write the opening as 'A forest at dusk. ' (a trailing space, or a newline at the end of the textarea) and press Run the opening. worldTake (src/lib/catalog/cinema.ts:2572) builds `made` with scriptKey(normalizeWorld(script)), and normalizeWorld trims the words. The panel calls clipsFromTakes(w, …) with the untrimmed state `w`, so scriptKey(w,0) !== take.made. The result is clips=[undefined] and states=['stale']. Checked two ways. A scratch vitest probe returned made===key false and states ['stale']. A demo-mode browser probe on :3417 showed 'Changed: run it again' and no 'Ready' after the opening's take succeeded. The same mismatch happens for leading or trailing spaces in the subject, details, action or turn words, and for a typed length that isn't a half-second step (4.3 s is rounded to 4.5 on the server). A reload hides the problem only because restore() normalises the stored script. Fix: key and send the normalised script on the client (normalizeWorld(w) for clipsFromTakes, input() and plan), or compare keys after normalising both sides. Add a test with untrimmed words."
- },
- {
- "severity": "low",
- "category": "quality",
- "verdict": "PLAUSIBLE",
- "file": "src/lib/world.ts",
- "line": 380,
- "summary": "Each turn's latents are trimmed and decoded alone. The PixelUMM decoder then starts every turn with no earlier latents as context, and its window noise is seeded from absolute frame 0 instead of the turn's real offset. The exported join can therefore show a visible seam at every turn boundary.",
- "failure_scenario": "Read in the port at a89e0515. integration.PixelUMMVAE.decode calls pixelumm.decode_clip(latent), which runs decode_windows with offset=0. The port's own continuation path, decode_tail, re-decodes STRIDE=5 latents before the new frames, passes offset=start and cross-fades the overlap 'for continuity'. TrimVideoLatent → VAEDecode skips both, so frame 0 of turn k is decoded cold. oss-join-encoded joins packets without re-encoding, so nothing smooths the cut. This can't be checked without a GPU. The 'left' list mentions the 5D decode as unverified, but not the seam. Possible fix: trim to latentsBefore−5, then cut the first 20 pixel frames after decode, so the decoder gets the port's context."
- },
- {
- "severity": "low",
- "category": "correctness",
- "verdict": "CONFIRMED",
- "file": "src/components/cinema/world-panel.tsx",
- "line": 133,
- "summary": "Redo-from-here cut-offs (redoAt) live only in component state. After the panel is closed or the page reloaded, the takes made before the redo count as current clips for the later turns again.",
- "failure_scenario": "Turns 0–2 are done. Press Redo from here on turn 1 and close or reload before turn 2 is re-run. clipsFromTakes loses redoAt, and the old turn-2 take still matches scriptKey (the script is unchanged), so it shows as Ready and goes into Export. The harm is small today, because the port's noise is seeded and an unchanged redo gives identical frames. It still contradicts the button's promise. Each turn's 'films this turn again and the ones after it' should survive a reload, for example stored with the script in localStorage or as a take field."
- }
- ],
- "checks": [
- "Read the whole diff claude/fuobe-parity-4...o/nm10-hy-nomas-world (33 files) and the code around it: comfyui provider prepareWorkflow, planGeneration, cinema planner and generateInProject, hosted-run decidePlace/poolQuote, guest-access.",
- "Cloned Nynxz/ComfyUI-HyNomas at a89e0515 as data and read nomas/nodes.py, world.py, camera.py, prompt.py, integration.py, pixelumm.py. Node inputs and outputs match the template and expansion: NomasWorldGenerate/Continue give (LATENT, NOMAS_WORLD), and world is [id,1]. World.latent() concatenates every segment, so TrimVideoLatent by latentsBefore leaves turn k only. The latent arithmetic matches the port in all cases: with a camera, len(ticks)//4+1; without one, (max(round(s*24),5)-1)//4+1, and the opening's bounds use int(s*24), which is exact on half seconds. Continue forks the world, so cached upstream outputs are not mutated. PortPose forward/right/yaw/pitch match camera.Pose. The script's tick count equals turnFrames, and 'look … 0.0417' parses to one tick.",
- "Primary sources: the HF tree of nynxz/Hy-Nomas at e8ddc4bf matches the pinned sizes and sha256 of all three files. The model card says licence 'apache-2.0-and-nvidia-one-way-noncommercial'. The port's LICENSE is Apache-2.0. The licence data is recorded in NODE_PACKS and in the manifest licence text, which is flagged NON-COMMERCIAL.",
- "Live CPU ComfyUI object_info: the TrimVideoLatent, VAEDecode, CreateVideo, SaveVideo, CLIPLoader (qwen_image) and UNETLoader inputs match the template.",
- "node scripts/comfy/build-requirements.mjs left requirements.json unchanged (up to date). The STUDIO_ROWS 'World mode' row is present. tests/comfy-library-4 has only the allowed edit (the new id in the unvalidated list).",
- "Cloud and Paid-APIs-only: planWorld refuses any engine but open with WORLD_OPEN_ONLY and no stand-in. The World chip and panel are hidden when engineMode is cloud. Assist world_film throws under 'Paid APIs only'. No Higgsfield API or media, and no LoRA files committed. No new route, so public sign-up gating is inherited (cinema project generation is already a library change). The script travels in params.extra and is normalised and size-bounded server-side. No file inputs for a turn. The join's clips are FileRefs.",
- "npx next typegen && tsc --noEmit: clean.",
- "vitest: world-path, world-mode, comfy-library-4, assist-context, licences: 5 files, 130 tests pass. cinema, cinema-api, gpu-requirements, gpu-readiness, public-signup, public-signup-tools, assist-studio-routes, camera-path, comfy, model-access-studios: 10 files, 225 tests pass. A larger 29-file batch hit my 900 s timeout before reporting and was not rerun as one batch.",
- "Browser: FUOBE_DEMO_MODE=on next dev on http://localhost:3417. tests/e2e/cinema-world.mjs passed: 1440 light open engine (opening, turn, path, export), 1440 dark cloud notice, 390 light and dark with no sideways scroll, no console or page errors. A separate probe confirmed finding 1 in the browser (trailing space → 'Changed: run it again'). The server was stopped with fuser -k -n tcp 3417 and .next deleted. The worktree is clean."
- ],
- "verdict": "changes-requested: the build is sound against the port and pins, tsc is clean and the targeted tests and the browser check pass. One confirmed medium bug needs fixing first: the World panel compares its raw script with the server's normalised script key, so ordinary input such as trailing spaces leaves a finished turn showing 'Changed: run it again' and blocks the next turn and Export until a reload. The two low findings (decode seams at turn boundaries, Redo cut-offs not persisted) can be fixed or recorded in 'left'."
- },
- "fix": {
- "applied": [
- "Finding 1 (medium, confirmed): the World panel's turn state no longer goes stale when the fields have stray spaces or a length off the half second. scriptKey in src/lib/world.ts now keys normalizeWorld(script), so the browser's key and the server's take key (worldTake) agree. The panel (src/components/cinema/world-panel.tsx) also works from the tidied script for everything it sends, keys and checks: clipsFromTakes, nextTurn, canRun, exportClips, worldProblem, the plan, the request body, the totals, the timeline and the path sketch. The fields still show what was typed. New unit test: untrimmed opening, subject and turn words plus a 4.3 s length are matched against the take the server files. tests/e2e/cinema-world.mjs now types stray spaces and checks that 'Changed: run it again' doesn't show after the opening is ready.",
- "Finding 3 (low, confirmed): Redo from here now survives closing the panel or reloading. clipsFromTakes only counts a turn's take if it was made after the current clips of the turns before it, because the world continues from those clips. So once a redone turn has a newer take, the later turns' older takes stop counting, and this is worked out from the takes themselves with nothing stored. If a redo fails, the earlier film stands. The in-memory redoAt still covers the moment before the new take shows up. New unit test covers a reload after a redo, a running redo and a failed redo."
- ],
- "rejected": [
- "Finding 2 (low, plausible: possible decode seams at turn boundaries, because each turn's latents are trimmed and decoded with no context and the decoder's window noise starts at offset 0). Not changed. It can't be checked without a GPU. The suggested fix would change the trim arithmetic, which is currently checked against the port, and would add a pixel-frame cut whose size depends on PixelUMM's undocumented causal frame layout for a decode that starts partway through. The noise offset can't be set through stock nodes at all. Recorded in 'left' to settle on the first live GPU run."
- ],
- "checks": [
- "Worktree /home/user/wt/o-nm10-hy-nomas-world on o/nm10-hy-nomas-world: holds only this package's commits, and claude/fuobe-parity-4 is an ancestor.",
- "Before fixing, read both confirmed findings against the code: worldTake keys normalizeWorld(script) while the panel keyed the raw script, and redoAt lived only in component state.",
- "vitest: world-mode, world-path, cinema, cinema-api, assist-context: 5 files, 100 tests pass, including the 2 new ones. Full suite not run, as instructed (the coordinator runs it).",
- "npx next typegen, then tsc --noEmit: clean. pnpm typecheck under the default heap ran out of memory (exit 134), so it was rerun with NODE_OPTIONS=--max-old-space-size=6144 and passed with exit 0.",
- "pnpm lint: exit 0 (0 errors; 5 warnings, none in the changed files).",
- "Browser: FUOBE_DEMO_MODE=on next dev on http://localhost:3419 with tests/e2e/cinema-world.mjs, which now types stray spaces and asserts there is no 'Changed: run it again'. Passed: 1440 light open engine (opening, turn, path, export), 1440 dark cloud notice, 390 light and dark fit, no console or page errors. Server stopped with fuser -k -n tcp 3419, .next deleted, git status clean.",
- "Committed 29255479 with the attribution lines; not pushed.",
- "Coordinator FINISH: merged origin/claude/fuobe-parity-4 (already up to date); npx next typegen exit 0; NODE_OPTIONS=--max-old-space-size=8192 pnpm typecheck exit 0; pnpm lint exit 0 (0 errors, 5 warnings); full vitest: 5825 passed, 8 failed, 4 skipped. 2 failures were this package (tests/comfy-library-notes: the world-hy-nomas-turn notes named source files and said \"a guess\"); the notes were rewritten in library.spec.mjs and the same text edited into manifest.json (build-library not re-run), and comfy-library-notes, world-mode and comfy-library-4 then pass (325 tests). The 6 remaining failures are the known pre-existing ones: comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack."
- ],
- "finalSummary": "World mode in Cinema, now with the review's confirmed fixes. Open engine (your ComfyUI): Hy-Nomas turns through ComfyUI-HyNomas (pinned a89e0515) with its converted weights pinned by sha256. The world-hy-nomas-turn graph is rebuilt per turn and the camera paths are converted by src/lib/world-path.ts. The World panel covers the opening, turns, the path preview, Run turn, Redo from here and Export (the turns joined on the open engine), then links to Sound for video and Music. Assist has world_film, and there is a GPU board row 'World mode' (24 GB is a guess) plus licence rows (the port is Apache-2.0; the PixelUMM decoder is NVIDIA non-commercial). Verified: unit tests, the graph checked against the port's node definitions and the live CPU ComfyUI's stock nodes, typecheck, lint, and the demo-mode browser run. Built but not run live: a real turn on a GPU (the pack isn't installed on the CPU server). Cloud engine: no route, because Hy-Nomas isn't hosted. The panel says it runs on your GPU (open source), 'Paid APIs only' hides the World chip, and Assist refuses world_film there. fal's worlds models are recorded in research only. Public sign-up: no new route. Guests browse read-only. Accounts run World turns only on their own GPU through the existing Cinema generation path (cinema project changes are already gated as library changes). Turns take no file inputs, and the join takes the account's own clip references.",
- "left": [
- "Live GPU run with ComfyUI-HyNomas installed. Still to confirm: that VAE Decode accepts the trimmed 5D latent, the turn speed, that ComfyUI's cache reuses the chain between prompts, and whether turn boundaries show a decode seam (each turn is decoded with no previous latents as context, and PixelUMM's window noise starts at offset 0). If there is a seam, trim to latentsBefore-5 and cut the extra decoded frames, or ask the port for an offset input.",
- "world-hy-nomas-turn stays validated:false because the CPU validation server doesn't have the pack. tests/comfy-library-4.test.ts has its one allowed edit: the new id added to the unvalidated list.",
- "An unchanged Redo from here gives the same frames, because the port's noise is seeded. A per-turn re-roll would need a port change.",
- "The 24 GB VRAM figure is a guess. Tencent's 4090 configuration uses an FP8 decoder, which the port doesn't ship.",
- "Whether to offer fal's worlds models (H3 Max Director, Abot World 0, Lingbot World 2, Eden Live) under their own names is the owner's call.",
- "Full Vitest suite to be run by the coordinator."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/nm10-hy-nomas-world"
- ],
- "notMerged": [],
- "conflicts": "assist/agent.ts lines (world_film + Soundtracks), manifest generatedAt; requirements regenerated",
- "checks": "batch of 3 (idol-8, idol-3, nm10-hy-nomas-world): typecheck 0, lint 0, vitest 5972 passed, 6 failed (main known); idol-8 and hy-nomas each checked by an independent verifier; idol-3 merged by hand (README rows) with follow-up fb8e099e (demo splat now comes with idol-4's turntable)",
- "pushed": true,
- "head": "b97c9762"
- }
-}
diff --git a/docs/handoff/reports/nm10-kandinsky6.json b/docs/handoff/reports/nm10-kandinsky6.json
deleted file mode 100644
index ad8c3460..00000000
--- a/docs/handoff/reports/nm10-kandinsky6.json
+++ /dev/null
@@ -1,153 +0,0 @@
-{
- "key": "nm10-kandinsky6",
- "impl": {
- "branch": "o/nm10-kandinsky6",
- "summary": "Kandinsky 6.0 on both engines. Cloud: one model, kandinsky-6, where Quality picks fal's Pro or Lite endpoint at Fast, Standard or Best steps (Pro 8/20/50, Lite 4/10/16), priced at fal's published price for each step count. Also kandinsky-vsr, priced per output megapixel per frame. Open engine: oss-kandinsky6 for text or image to video with sound, Lite by default with Pro as an option, plus oss-kandinsky6-vsr, both on Kandinsky Lab's pinned kandinsky6 and kandinsky6-sr packs. Quoted words in the prompt become Kandinsky's spoken-line tags and a closing 'Sound:' line becomes its sound caption, on both engines. Upscale → Video offers Kandinsky VSR at 2x, 2.25x or 4x on both engines, and clips over 5 s are refused before they run. Lipsync & avatars links to Kandinsky as a 'talking character from words' maker. It is not offered as lip-sync of existing footage. Licence rows are recorded and everything stays on. The GPU pre-flight board has two new rows. Nothing from the plan was in the code before; research part 4 had already recorded the Pro and VSR endpoints, but Lite was missing.",
- "built": [
- "Research: scripts/fetch-hosted-schemas.py --kandinsky6 reads fal's 6 endpoints into docs/research/new-models-10.json endpointRecords. Each record has its schema and a parsed price. Pro t2v $0.24/$0.56/$1.35 at 8/20/50 steps, i2v $0.25/$0.58/$1.40. Lite was read at the source: t2v $0.08/$0.16/$0.24 at 4/10/16 steps (default 10, step range 4-16), i2v $0.085/$0.17/$0.25. VSR and VSR Lite are both $0.00036 per output MP per frame, capped at 121 frames.",
- "Cloud (scripts/gen-cloud-models.py → cloud-models.generated.ts): kandinsky-6 has four routes, each tagged with ModelRoute.when {variant: pro|lite}. routesFor(model, op, params) picks the route for the run's variant; the generator adds 'variant' to the route's ignore list so it is never sent to fal. A 6-value Quality control writes variant and num_inference_steps through the control's sets. Pricing.steps holds the per-op, per-variant step price tables, with linear interpolation between published points. The Prompt helper control drives enable_prompt_expansion. That field defaults to false on this route, and payload.ts sends true only when the helper is 'on' and the route's default is false, so FLUX 3 Klein is unchanged. kandinsky-vsr uses factor tiers 2x/2.25x/4x through FieldMap.upscaleFactor. The generator now accepts an enum of numbers there, and factorTier was added in src/lib/av/upscale.ts. Pricing.outputFrames prices the run from params.sourceSize and sourceDuration: 24 fps, at most 121 frames, and 848x480 assumed until the clip's header is read.",
- "Clip size and length checks: params.sourceSize was added to the request schema and is filled by the composer from the clip's header. The server re-prices from that header. ModelOptions.maxSourceSeconds (5) is enforced by sourceLengthProblem in the plan, the composer's clipBlocker and the server's upscale block.",
- "Prompt tags: src/lib/kandinsky-prompt.ts (promptFormat 'kandinsky6') turns quotes into <S>…<E> and a closing Sound:/Audio:/Music: line into <AUDCAP>…<ENDAUDCAP>. It runs in generations.ts on both engines. The run keeps the words as typed.",
- "Open graphs (scripts/comfy/hand-built): kandinsky6-t2av, kandinsky6-i2av and video-upscale-kandinsky6-vsr. They follow the packs' T2VA, I2VA and SR templates, without the in-graph VSR and without MagCache, which is bypassed for distilled models anyway. The open Quality control picks the transformer file through the unet binding: Lite distill 6.38 GB by default, Pro distill 60.3 GB as an optional file. The beautify node is removed unless the Prompt helper is 'on' (PROMPT_HELPER_OPT_IN; skipPromptHelper now understands Kandinsky6TextEncode). The VSR's 'scale' and new 'upscalerScale' bindings are filled from the factor.",
- "Library: packs.json pins kandinsky6 at 7ceeefad (Registry 1.0.2) and kandinsky6-sr at b15e2aac (Registry 0.1.2), each with subdir comfyui. install-comfyui.sh adds them (K6_PACKS=0 skips them). library.spec.mjs gets the pack repos, PACK_CLASSES and KNOWN_MODELS at pinned Hugging Face revisions. The VSR's config.json files and BigVGAN are listed as requiredModels. build-library.mjs gets the new LOADER_FOLDERS entries and the upscalerScale binding key, and now reads x-linked-size from Hugging Face's redirect, so small config files keep their size. model-pins.json gets 16 new pins, with revision, size and sha256 for LFS files. object_info.subset.json gets 12 pack class definitions written by hand from the packs' source at the pinned commits (additions only). manifest.json and requirements.json were rebuilt.",
- "Licences: the open graphs' licence line reads MIT for the Kandinsky weights, Apache-2.0 for the Qwen2.5-VL encoder, MIT for CLIP-L and BigVGAN, the Tencent Hunyuan Community licence for the HunyuanVideo VAE (territory excludes the EU, UK and South Korea), and CC BY-NC 4.0, non-commercial, for the audio VAE v1-44.pth from hkchengrex/MMAudio. The VSR is MIT. Pack records in licences.ts: kandinsky6 MIT, with vendored Apache-2.0 code; kandinsky6-sr Apache-2.0. The cloud models carry a ModelLicence of MIT. Everything is on by default.",
- "UI: StudioConfig.related can now name a model per engine (relatedHref in src/lib/composer.ts). The link is hydration-safe: it uses useHydrated and only names its model once the browser's engine is known. Lipsync shows 'No voice yet? Make a talking character from words with Kandinsky 6.0', which opens /video on each engine's Kandinsky.",
- "GPU pre-flight: STUDIO_ROWS gains 'Video with dialogue' (/video?model=oss-kandinsky6, t2v and i2v) and 'Kandinsky VSR' (/upscale/video?model=oss-kandinsky6-vsr)."
- ],
- "tests": [
- "New tests/kandinsky6.test.ts (16 tests) covers: library entries, packs, pins and licences; graph defaults and sizing through prepareWorkflow; Quality picking the transformer; the helper being removed unless on; the VSR's scale and latent-upscaler bank binding; fal routes chosen by variant; step prices for both variants and both ops; payload contents (steps, generate_audio, expansion; no variant or quality fields sent; Lite gets no negative_prompt); VSR factor tiers and the clip-outcome text; per-frame pricing; the 5 s refusal; the prompt tags; the Lipsync link and the pre-flight rows. All pass.",
- "New tests/hosted-runs-kandinsky6.test.ts (3 tests): poolQuote and decidePlace for oss-kandinsky6; i2v and VSR follow the uploads policy; fal's Kandinsky models are never pooled. All pass.",
- "Existing tests: tests/comfy-library-4.test.ts, unvalidated list only (added the 3 new graph ids). Targeted runs of these pass: cloud-catalog, cloud-catalog-4, library, library-pure, comfy-library-4/7/notes, gpu-requirements/readiness/api, open-engine, flux3-klein, plan, composer, composer-fixes, model-access, public-signup-tools, regenerate-2k, video-finish, kling-4, launch-prices, edit-video-pricing, canvas, character-swap(-2k), qwen21-fast, open-tools, no-higgsfield, av-dub, blockout, cinema-original. Total 658 tests plus earlier runs, all green. No full suite run.",
- "tsc --noEmit is clean after next typegen. The first attempt ran out of memory; it passes with NODE_OPTIONS=--max-old-space-size=6144. eslint is clean on the changed files.",
- "Library build run with npm run build for the 3 ids. validate-workflows --shared against the CPU ComfyUI (0.41.0) answers missing_node_type for every graph, because the packs are not installed there, so all three stay validated:false. The graphs are checked against the hand-recorded node definitions. Nothing was run end to end.",
- "Browser check: new tests/e2e/kandinsky6.mjs in demo mode on pnpm dev -p 3471, at 1440 and 390 px, light and dark, on both engines, covering the Video studio, Upscale → Video and Lipsync. 98 checks passed, with no page errors, no console errors and no sideways scroll. The first run caught a hydration mismatch on the Lipsync link, now fixed. Server stopped and .next deleted afterwards (.next/types regenerated for tsc)."
- ],
- "left": [
- "Nothing has run on a GPU, and fal was never called (no key here). The graphs need a GPU ComfyUI 0.38 or newer with both packs installed (install-comfyui.sh does this) before they can be validated. They should then be checked for: VAEDecode of the joint latent, GetVideoComponents audio on a silent clip going into the VSR, the beautifier loading qwen3.5_9b_bf16 with CLIPLoader type qwen_image as the template does, and Fuobe's 16:9 480p size of 848x480 (the template uses 864x480).",
- "VRAM figures are estimates because none are published. Lite is set at 24 GB in the manifest. Pro distill holds a 60.3 GB DiT, so it needs about an 80 GB GPU or heavy offload. Pre-flight uses the graph's single vramGb of 24, so it doesn't warn when Pro is picked.",
- "The audio VAE file the pack loads, v1-44.pth, is CC BY-NC 4.0 (non-commercial), so Models & licences flags the open Kandinsky graphs. Kandinsky's own MIT audio_vae safetensors, shipped in its Diffusers repos, might work with the pack's loader (which accepts .safetensors), but this is unverified. Owner decision: keep the file as it is, or test the MIT one on a GPU.",
- "The audio_vae folder is registered by the pack under the name kandinsky6_audio_vae, so the pre-flight's folder listing may not see v1-44.pth or bigvgan_vocoder/* until the pack is loaded.",
- "Core ComfyUI PR #16825 (native Kandinsky 6) is not in 0.41 or 0.42. If it merges, move the graphs to core nodes.",
- "fal's VSR Lite page quotes $0.08 for 480p→1080p at the same $0.00036 per-MP-per-frame rate. Only the full 5-step VSR endpoint is routed; VSR Lite is recorded in research but not routed.",
- "Not done: the upscale_factor option on the fal generation endpoints (generate and upscale in one call) and the non-distilled Pro and Lite checkpoints (50 steps, CFG 5, MagCache).",
- "Brief corrections: Lite's step range is 4-16, so the brief's Fast 8 / Standard 20 / Best 50 applies to Pro only; Lite uses 4/10/16. Pro i2v costs $0.25/$0.58/$1.40. The brief's '$1.53 to 1080p' is Pro t2v at 50 steps plus $0.18. The ComfyUI templates default to Pro distilled, but Fuobe's open engine defaults to Lite so it runs on ordinary GPUs."
- ],
- "docsNotes": "For STATUS/FEATURES on the docs pass: Kandinsky 6.0 (Kandinsky Lab, MIT) is in the Video studio on both engines. It makes 5 s clips at 480p and 24 fps with sound and lip-synced dialogue, from words or a first frame. On the open engine Lite is the default, Pro is optional, and there is a Prompt helper; in the cloud, fal's Pro or Lite at Fast, Standard or Best steps are priced per clip. Kandinsky VSR is in Upscale → Video on both engines at 2x, 2.25x or 4x, for clips up to 5 s, priced at $0.00036 per output MP per frame in the cloud. Lipsync & avatars links to it for a 'talking character from words'. Prompt tip: put spoken words in quotes and end with 'Sound: …'. SELF-HOSTING: install-comfyui.sh now installs the kandinsky6 and kandinsky6-sr packs (K6_PACKS=0 skips them). The file downloads are Lite 6.4 GB, Qwen2.5-VL 7B bf16 16.6 GB, the audio VAE 1.2 GB plus BigVGAN, optionally Pro 60 GB, optionally the Qwen3.5 9B helper 19.3 GB, and the VSR bundle about 17.5 GB. Licence note: the audio VAE v1-44.pth is CC BY-NC 4.0, and the HunyuanVideo VAE's licence excludes the EU, UK and South Korea. Research corrections are in the 'left' field; new-models-10.json now holds the Kandinsky endpoint records.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "high",
- "area": "GPU pre-flight / open engine",
- "file": "scripts/comfy/library.spec.mjs, scripts/comfy/build-library.mjs (LOADER_FOLDERS), workflows/comfyui/requirements.json",
- "summary": "The pre-flight can never see the BigVGAN vocoder, so open Kandinsky 6.0 always reads Needs setup and an account's run on its own ComfyUI is refused.",
- "detail": "The audio files sit in folder 'audio_vae'. ComfyUI has no model folder of that name: the kandinsky6 pack registers models/audio_vae as 'kandinsky6_audio_vae' (nodes.py:31), and the live CPU ComfyUI's /models has no audio_vae (GET /models/audio_vae answers 404). gather.ts therefore records audio_vae as folderMissing. v1-44.pth is still found through the Kandinsky6AudioVAELoader.tod_vae list. bigvgan_vocoder/bigvgan_generator.pt has presence 'list' and no loader, so filePresence returns 'missing' even when it is installed. I checked this with a probe on requirements.json and an inventory of a ComfyUI with the pack loaded: v1-44.pth present, bigvgan_generator.pt missing. As a result the 'Video with dialogue' row and the oss-kandinsky6 chip never read Ready. gateGeneration (preflight is on by default) returns ok:false for an account's ComfyUI, so accounts can't run either Kandinsky graph, and the fix plan keeps asking them to download BigVGAN again. tests/kandinsky6.test.ts never checks readiness against an inventory, so this went unnoticed.",
- "fix": "List the folder under the name ComfyUI reports (kandinsky6_audio_vae, still downloading to models/audio_vae), or mark the bigvgan files unobservable like the config.json. Add a readiness test with an inventory of a ComfyUI that has the packs loaded."
- },
- {
- "severity": "medium",
- "area": "GPU pre-flight / open engine",
- "file": "scripts/comfy/library.spec.mjs (kandinsky6-t2av / -i2av optionalModels), src/server/gpu/gate.ts",
- "summary": "The 19.3 GB Qwen3.5 9B prompt-helper file is required even though the Prompt helper is off by default and its nodes are removed from the run.",
- "detail": "requirements.json lists text_encoders/qwen3.5_9b_bf16.safetensors under files, not optional, for both graphs. PROMPT_HELPER_OPT_IN drops nodes 19 and 20 unless promptHelper is 'on' (a probe of prepareWorkflow shows no node 20 by default). The pre-flight still asks for a 19 GB download nobody uses by default, and the gate blocks an account that lacks it. The reverse gap exists too: the Pro transformer (60 GB) is optional, and the gate adds an optional file only for Qwen-Image 2.1's clean VAE. So Quality 'pro' without the file is never caught before the run, and vramGb 24 never warns for Pro's roughly 80 GB.",
- "fix": "Move qwen3.5_9b_bf16 to optionalModels. In gateGeneration, add it when extra.promptHelper is 'on' and the Pro file when quality is 'pro', the way CLEAN_VAE is handled."
- },
- {
- "severity": "medium",
- "area": "cloud payload / both engines",
- "file": "src/lib/catalog/plan.ts, src/lib/av/upscale.ts (upscaleFactorFor), src/server/providers/comfyui.ts (upscalerScale block)",
- "summary": "Kandinsky VSR accepts a resolution outside its 2x / 2.25x / 4x tiers, and the two engines then do different things.",
- "detail": "planGeneration doesn't check params.resolution against options.resolutions. Probe with params.resolution '1080p' (an API call, a chain or a Reuse from another upscaler) on a 1280x720 clip: the cloud payload is {video_url, upscale_factor: 1.5}, but fal's enum takes only 2, 2.25 or 4, so the run fails at fal. estimateCost prices it at the 2x fallback. The open engine quietly runs 2.25x (factorTier('1080p') is undefined, so the default applies).",
- "fix": "Refuse any resolution that isn't one of the model's factor tiers before the run, with a plain message, on both engines. Or map it to the nearest tier the same way on both engines."
- },
- {
- "severity": "low",
- "area": "cloud payload",
- "file": "src/lib/composer.ts (clipBlocker), src/lib/catalog/cloud-models.generated.ts (kandinsky-vsr)",
- "summary": "fal's Kandinsky VSR needs width and height in multiples of 16 for 2x and 4x, and nothing checks this before the run.",
- "detail": "The research record for fal-ai/kandinsky6-vsr says: 'For 2x and 4x upscaling, width and height must be multiples of 16.' An 854x480 clip at 2x is sent anyway and fails at fal. The open pack pads the source itself (source_padding), so this affects the cloud engine only.",
- "fix": "Have clipBlocker and the server's upscale check refuse such a clip in the cloud, or suggest 2.25x, with a plain message."
- },
- {
- "severity": "low",
- "area": "cloud UI",
- "file": "scripts/gen-cloud-models.py (kandinsky-6), src/lib/catalog/cloud-models.generated.ts",
- "summary": "The cloud Lite routes take no negative prompt, but kandinsky-6 still shows the field, and what is typed is dropped without a word.",
- "detail": "options.negativePrompt is true for the whole model. A probe shows the lite-best payload without negative_prompt while pro-fast carries it. The UI doesn't say that Lite ignores it.",
- "fix": "Hide the negative prompt or add a note when Quality is Lite (for example engineOptions-style per-variant options), or state it in the Quality labels."
- },
- {
- "severity": "low",
- "area": "server input trust",
- "file": "src/server/request-schema.ts:100, src/server/generations.ts (input built from ...plan.params, then Object.assign(input, source))",
- "summary": "A size the client states (params.sourceSize) now reaches GenInput.sourceSize for every model when the server can't read the clip's header.",
- "detail": "The schema used to strip sourceSize. Now it is copied into input through ...plan.params, and `source` replaces it only when mediaFacts finds a width and height. Factor upscalers such as Topaz and FLUX Upscale then compute upscale_factor from the client's claim, and the VSR's price follows it. The browser sends true values, so only API callers are affected.",
- "fix": "Price with params.sourceSize before the run, but delete it from input before the header is merged, so only the server's own header read sets GenInput.sourceSize."
- },
- {
- "severity": "low",
- "area": "prompt format",
- "file": "src/lib/kandinsky-prompt.ts",
- "summary": "Every quoted phrase becomes a spoken line, and a prompt made only of a 'Sound:' line gets no sound tags.",
- "detail": "Probe: 'A sign reads \"OPEN\" in neon' becomes 'A sign reads <S>OPEN<E> in neon', so the character speaks the sign. 'Sound: rain' on its own is left untagged because m.index is 0. The placeholder does explain the quotes rule, so this is a known trade-off.",
- "fix": "Take quotes as speech only after a speech verb or a colon, or accept the trade-off and say it in the tip. Tag a prompt that is only a sound line."
- }
- ],
- "checks": [
- "Read the stage prompt and the binding rules. Reviewed git diff claude/fuobe-parity-4...o/nm10-kandinsky6 (4 commits, 40 files) and the code around it: plan.ts routesFor / stepsPrice / outputFramesPrice, payload.ts, comfyui.ts prepareWorkflow, generations.ts submitNow, gpu gate / readiness / gather.",
- "Cloned kandinskylab/kandinsky-6 at 7ceeefad and kandinsky-6-sr at b15e2aac into the scratchpad (read only). The hand-written object_info subset matches the packs' INPUT_TYPES for all 12 classes. The graphs follow the T2VA, I2VA and VSR templates. Kandinsky6TextEncode joins audio_caption as <AUDCAP>, so the inline tags with an empty audio_caption give the same text. The pack's 16 px and 4n+1 frame rules hold for every aspect ratio. Licences checked at the pinned commits: kandinsky6 MIT (comfyui/LICENSE); kandinsky6-sr's comfyui/LICENSE Apache-2.0. The Lite repo's model_index matches DualCLIPLoader kandinsky5.",
- "Checked the core nodes' schemas against the CPU ComfyUI at 127.0.0.1:8188 (GetVideoComponents output order, CreateVideo, LoadVideo, DualCLIPLoader type kandinsky5, ImageScale). /models has no audio_vae folder, which confirms finding 1. Nothing was installed or restarted.",
- "Re-read fal's pricing pages for kandinsky6-lite/text-to-video ($0.08 / $0.16 / $0.24 at 4 / 10 / 16 steps) and kandinsky6-vsr ($0.00036 per output MP per frame, about $0.09 for 480p to 1080p, $0.29 at 4x). They match Pricing.steps and outputFrames.",
- "Probes in the scratchpad (vitest, no repo edits): routesFor picks Pro or Lite by Quality, with prices 0.24 / 0.24 / 0.56; payloads send num_inference_steps and enable_prompt_expansion:false and never variant or quality; Lite drops negative_prompt; prepareWorkflow sizes 848x480, 480x848, 480x480, 640x480 and 480x640 at 121 frames; Pro unet through Quality; helper removed unless 'on'; VSR 2x→2x/2x, 4x→4x/4x, 1080p→2.25x on open versus upscale_factor 1.5 in the cloud; filePresence shows bigvgan_generator.pt missing on a ComfyUI with the pack loaded.",
- "Targeted Vitest, all green: kandinsky6, hosted-runs-kandinsky6, flux3-klein, payload, public-signup, cloud-catalog (100 tests); comfy-library-4/7, gpu-requirements/readiness/api, library, library-pure, plan, composer, composer-fixes, account-inputs, account-tenant, request-body-limits, public-signup-tools (302 tests).",
- "Public sign-up: no new routes, estimates or previews. No new server path reads a file; the inputs go through the existing prep and readRef paths, and the uploads policy test covers i2v and VSR on hosted runs. fal's Kandinsky models are never pooled. No Higgsfield API, code or media. No LoRA files committed. No hot files touched; the tests/comfy-library-4 edit is only the allowed unvalidated-list addition. validation-state.json was rebuilt.",
- "Not run: the browser checks at 1440 and 390 px (the implementer's e2e reports 98 checks passing), the full suite, and anything on a GPU or with a fal key."
- ],
- "verdict": "changes-requested: one high finding (the pre-flight never sees the BigVGAN vocoder in 'audio_vae', so the open Kandinsky graphs stay Needs setup and accounts' runs on their own ComfyUI are refused) and two medium findings (the 19 GB helper file is required while the helper is off and Pro's file and VRAM are never checked; VSR accepts a non-factor resolution and the engines then diverge, with the cloud sending a factor fal rejects). The rest of the package, including the cloud routing, payloads, prices, graphs, licences and the Lipsync link, checks out against the packs' source and fal's pages."
- },
- "fix": {
- "applied": [
- "HIGH (confirmed: the pack's nodes.py registers models/audio_vae as 'kandinsky6_audio_vae', and the live CPU ComfyUI has no audio_vae in /models). packs.json can now say which name a pack lists a folder under (kandinsky6: listAs {audio_vae: kandinsky6_audio_vae}). build-requirements writes that name into IndexFile.listFolder and into index.folders. gather.ts files the listing under it, filePresence and needTargets read it, and downloads still go to models/audio_vae, where the pack reads them. requirements.json was rebuilt: the bigvgan generator now reads present on a ComfyUI that has the pack. tests/helpers/fake-local-comfy.ts lists pack folders by their registered name. New test: a gather against the fake ComfyUI with everything installed shows kandinsky6_audio_vae holding all 3 audio files and both graphs Ready. With the vocoder taken away, the only need is that one file, and its download target is still models/audio_vae.",
- "MEDIUM (confirmed): qwen3.5_9b_bf16 is now in optionalModels for kandinsky6-t2av and kandinsky6-i2av. build-library.mjs now marks a file the graph loads as optional when the spec lists it there (none of the 37 existing optional entries were in their own graphs, so nothing else changed). In gateGeneration, the optional files a run picks are now added generically: a file named by the run's control settings (controlSets, so Quality 'pro' adds the Pro transformer), the helper's file (PROMPT_HELPER_FILES in src/lib/comfy.ts) when promptHelper is 'on', and the clean Qwen VAE case as before. New gate test: the defaults pass; 'pro', or helper 'on', each needs 1 more thing; both together need 2.",
- "MEDIUM (confirmed): factorTierProblem in src/lib/av/upscale.ts. planGeneration refuses an upscale-video resolution outside a factor-only model's tiers, on both engines, with 'Kandinsky VSR upscales by 2x, 2.25x or 4x: pick one of those'. Upscalers that take a size are untouched. Tested on both engines: 1080p is refused, 4x and the default pass.",
- "LOW (confirmed from the research record of fal's page): new ModelOptions.sideMultiple, set to {of:16, factors:[2x,4x]} on the cloud kandinsky-vsr only through gen-cloud-models.py; the open pack pads the clip itself. sideMultipleProblem refuses the clip in the composer's clipBlocker and in the server's upscale block: 'Kandinsky VSR at 2x needs a clip whose width and height are multiples of 16 (this one is 854×480): pick 2.25x, or resize the clip first'. Tested.",
- "LOW (confirmed): the cloud's Lite Quality labels now end '· no negative prompt' (generated). Tested.",
- "LOW (confirmed): in submitNow, GenInput.sourceSize starts undefined, so only the server's header read sets it. params.sourceSize still prices the run before it starts. New test in tests/video-finish.test.ts: a clip whose header can't be read, with a stated 640x360, sends no sourceSize. It fails without the fix.",
- "LOW (half): kandinskyPrompt now tags a prompt that is only a sound line ('Sound: thunder' becomes '<AUDCAP>thunder<ENDAUDCAP>'). The test was updated."
- ],
- "rejected": [
- "Prompt format, the quotes half: still every quoted phrase is a spoken line. Taking quotes as speech only after a speech verb would miss common dialogue (a quote after a name or a dash) and would differ by language. The prompt box's placeholder already says to put what someone says in quotes. It is a known trade-off, left as it was.",
- "Pro's VRAM warning: the pre-flight's VRAM comes from the graph's single vramGb (24). A per-variant VRAM figure needs a new field in the index, and VRAM only ever warns, so it stays in 'left'."
- ],
- "checks": [
- "Worktree case (1). The branch holds only this package's 4 commits and the base is an ancestor. pnpm install --frozen-lockfile --prefer-offline and npx next typegen were run.",
- "Confirmed finding 1 against kandinskylab/kandinsky-6 at 7ceeefad (cloned read-only into the scratchpad). comfyui/kandinsky6/nodes.py line 31 is folder_paths.add_model_folder_path('kandinsky6_audio_vae', models_dir/audio_vae), with no extension filter, so GET /models/kandinsky6_audio_vae lists bigvgan_vocoder/* too. Also noted: _list_tod_vae falls back to ['v1-44.pth'] when the folder is empty, so the loader combo can't prove that v1-44.pth is there (see left).",
- "Rebuilt the library for the 3 Kandinsky graph ids (npm run build in scripts/comfy). manifest.json and requirements.json were regenerated: qwen3.5 is optional, the audio files carry listFolder, and index.folders lists kandinsky6_audio_vae instead of audio_vae. Regenerated cloud-models.generated.ts with gen-cloud-models.py; only the Kandinsky labels and sideMultiple changed.",
- "tests/kandinsky6.test.ts now has 21 tests (5 new, 2 updated), all passing. The new video-finish test passes and fails without the fix.",
- "pnpm typecheck (with NODE_OPTIONS=--max-old-space-size=6144) exit 0. pnpm lint exit 0, with only the 3 old warnings in library.spec.mjs WAN_NEG_EN and elements.ts.",
- "Full suite, run once after the container restart: FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2. 5059 passed, 7 failed in 6 files. All are the known failures from main: comfy-reuse, dop-originals, preset-featured, soul-runs x2 and split-soundtrack. preset-covers timed out under load and passed alone (11/11).",
- "No browser checks this stage: no new pages, and only label text changed. .next was deleted and git status is clean. Nothing was installed into ComfyUI and nothing was pushed."
- ],
- "finalSummary": "Open engine (your ComfyUI): Kandinsky 6.0 text or image to video with sound (Lite by default, Pro optional, Prompt helper optional), and Kandinsky VSR at 2x, 2.25x or 4x for clips up to 5 s. Built and checked against the packs' source and the node definitions recorded by hand; nothing has run on a GPU. The GPU pre-flight now sees the vocoder where the pack lists it, so a ComfyUI that has everything reads Ready. The 19 GB helper and the 60 GB Pro file are asked for only when the run picks them, both on the board and in the check before a run, so an account's run on its own ComfyUI is no longer refused for files it doesn't use. Cloud engine (fal, needs the owner's key; never called here): kandinsky-6 Pro or Lite at fal's step prices, and kandinsky-vsr priced per output megapixel per frame. Payloads and prices are tested. A non-tier factor is refused on both engines before the run, a clip whose sides fal can't take at 2x or 4x is refused with a pointer to 2.25x, and Lite's labels say it takes no negative prompt. The upscale factor is now made only from the clip's own header, for every factor upscaler. Public sign-up: guests browse the studios read-only. Accounts run the open Kandinsky graphs only on their own ComfyUI, with the pre-flight above, and the cloud stays the owner's. No new routes, and inputs go through the existing account checks.",
- "left": [
- "Nothing has run on a GPU or with a fal key. On a GPU ComfyUI with both packs: validate the 3 graphs, check the joint-latent decode and the VSR on a silent clip, the beautifier's loader, and 848x480.",
- "The pack's tod_vae list falls back to 'v1-44.pth' when its folder is empty, so the loader check can report v1-44.pth present when it isn't. The run itself would then fail. Reading it through the kandinsky6_audio_vae listing first would need filePresence to prefer the listing for this file.",
- "VRAM: the pre-flight uses vramGb 24 for both variants. Pro (a 60 GB DiT) needs about 80 GB and doesn't warn.",
- "Owner decision still open: the audio VAE v1-44.pth is CC BY-NC 4.0. Testing Kandinsky's MIT audio_vae safetensors needs a GPU.",
- "tests/comfy-library-4.test.ts: only the allowed unvalidated-list addition (the 3 Kandinsky graph ids, from the implementation stage).",
- "Still from the implementation stage: core ComfyUI PR #16825 is not merged; fal's VSR Lite is recorded but not routed; upscale_factor on the generation endpoints and the non-distilled checkpoints are not done."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/nm10-kandinsky6"
- ],
- "notMerged": [],
- "conflicts": "research JSON union, build-library keys, library.spec, fetch-hosted-schemas, plan imports, licences packs, generations prompt blocks, comfyui imports, comfy-library-4 ids, gpu-requirements comments, manifest/model-pins unions; requirements and cloud catalog regenerated",
- "checks": "batch of 7 (dbs-d7, idol-5, idol-2, idol-6, n7-9, kandinsky6, n7-10): typecheck 0, lint 0, vitest 5788 passed, 6 failed (main known); each merge checked by an independent verifier; n7-10 + Pika Flex interaction fixed in 64900624",
- "pushed": true,
- "head": "64900624"
- }
-}
diff --git a/docs/handoff/reports/nm10-keying.json b/docs/handoff/reports/nm10-keying.json
deleted file mode 100644
index fd98227c..00000000
--- a/docs/handoff/reports/nm10-keying.json
+++ /dev/null
@@ -1,193 +0,0 @@
-{
- "key": "nm10-keying",
- "impl": {
- "branch": "o/nm10-keying",
- "summary": "Added green-screen keying and fine-hair cut-outs on both engines. Video tools has a new 'Green screen' mode: CorridorKey on your GPU (v1.0 weights, because no ComfyUI wrapper loads CorridorKey 2.0 yet) and Bria green-screen despill in the cloud. Remove background gains Bria VRMBG 3.0 on the open engine. Layers' Remove background gains FeyNoBg 'fine hair' (open) and Bria's guided cut-out with a 'What to keep or drop' box (cloud). The open cut-outs come as transparent WebM, ProRes 4444 with alpha, or linear EXR frames. A mask or clean-foreground result links on to Export. Licences are recorded as information: CorridorKey's no-paid-API rule, VRMBG non-commercial and gated, FeyNoBg unknown. Models and endpoints were re-checked at their primary sources. 9 commits, not pushed by me.",
- "built": [
- {
- "feature": "Research",
- "status": "built",
- "verifiedHow": "Research: scripts/fetch-hosted-schemas.py --keying reads fal's bria/video/background-removal/green-screen-despill ($0.05/s, active; video_url, spill_suppression 0-1, output_container_and_codec, preserve_audio) and bria/guided-remove-background ($0.03/image, active; image_url, optional prompt, autocrop) into docs/research/new-models-10.json endpointRecords. The keying model rows there and a 'Checked while building' note in new-models-10.md §6.10 record the corrections below."
- },
- {
- "feature": "Primary sources checked 2026-1",
- "status": "built",
- "verifiedHow": "Primary sources checked 2026-11-02. CorridorKey2.0 @cf44a8db: corridorkey_v2.safetensors 2,661,698,720 B; LICENSE 'Corridor Key Licence 2.0' (CC BY-NC-SA 4.0 plus: no resale, no charging for access to the code or weights, no paid API or inference service, derivatives free, a commercial software package needs a written agreement, a seat per user above US$20M revenue). briaai/VRMBG-3.0 @59716e19: gated (manual); card says non-commercial only, commercial use needs a Bria agreement; model.safetensors 884,915,688 B. 1038lab/FeyNobg @59dd27c6: no card, no tag, no LICENSE, so recorded as unknown; FeyNobg.safetensors 1.05 GB. ComfyUI-RMBG has no 3.3.0 tag, so it is pinned at commit a66a5e64 (version 3.3.0, 2026-10-20). CorridorKey wrappers: pixelworldai @7eb44e48, SeanBRVFX @0f724f7c and TrentNodes @3d80a9df all load CorridorKey_v1.0.pth (nikopueringer/CorridorKey_v1.0, 0.40 GB, HF tag cc-by-nc-sa-4.0; the v1 engine's LICENSE is Corridor Key Licence 1.0). None loads v2, so the graph is built on v1.0 through pixelworldai's wrapper."
- },
- {
- "feature": "Graphs (hand-built + library.s",
- "status": "built",
- "verifiedHow": "Graphs (hand-built + library.spec + build + validate): video-key-corridorkey: VHS meta-batch, 32 frames per pass; ChromaKeyPrepass -> CorridorKeyGreenscreen; cut-out as WebM yuva420p or ProRes 4444 with alpha; matte as H.264; EXR frames written only for format exr and zipped onto the cut-out; 'foreground' sends the despilled colours through the cut-out encoder as H.264; bindings screenColor, despill (new keys in BINDING_KEYS), format, profile. video-matte-vrmbg3: AILab_VRMBG; VHS cut-out WebM/ProRes 4444; matte MP4; EXR frames; requiredModels VRMBG-3.0/model.safetensors (folder RMBG, gated). image-matte-feynobg: AILab_FeyNoBg with refine_foreground on."
- },
- {
- "feature": "Packs and pre-flight",
- "status": "built",
- "verifiedHow": "Packs and pre-flight: ComfyUI-RMBG pin moved to a66a5e64 in packs.json and install-comfyui.sh; RMBG and ClothesSegment inputs are unchanged between the two commits. New pack ComfyUI-CorridorKeyWrapper (packs.json, install-comfyui.sh, CUSTOM_NODE_REPOS, PACK_CLASSES). VRMBG weights pinned in model-pins.json (revision, size, sha256). requirements.json rebuilt. The five new classes are recorded in object_info.subset.json from the packs' source at the pinned commits. The subset otherwise keeps the base's records: the validator had rewritten it from the current server, which made a Character-swap test fail, so I restored the base and added only the five classes."
- },
- {
- "feature": "Catalog",
- "status": "built",
- "verifiedHow": "Catalog: open models oss-video-key-corridorkey (greenScreen; outputs cut-out, mask, clean foreground; formats WebM/ProRes 4444/EXR; Spill cleanup slider), oss-video-matte-vrmbg3 (same formats) and oss-matte-feynobg. Cloud models through gen-cloud-models.py: bria-green-screen (greenScreen, cut-out only, $0.05/s, Spill cleanup slider, webm_vp9 fixed) and bria-guided-cutout (guided, promptOptional, empty words omitted, $0.03/image). Types: MatteOutput gains 'foreground'; VideoFormat gains 'webm_alpha' (FORMAT_INFO 'Transparent WebM'); ModelOptions gains greenScreen and guided; the request-schema enum is extended."
- },
- {
- "feature": "Video tools",
- "status": "built",
- "verifiedHow": "Video tools: new hub mode /video-tools/green-screen (VIDEO_KEY_STUDIO 'Key out a green screen'). Green-screen keyers are listed only there; Remove background lists the other mattes (studioCatalog, the palette's modelHref and the GPU board's studioOthers all split on greenScreen). New STUDIO_ROWS entry on /connect. Plan checks: ProRes and EXR apply to the cut-out only, and 'clean foreground' is CorridorKey's alone (src/lib/av/keying.ts keyFormatValues, shared with the ComfyUI provider). Option notes adjusted for the cloud keyer."
- },
- {
- "feature": "Image cut-outs",
- "status": "built",
- "verifiedHow": "Image cut-outs: Layers TOOL_MODELS bg-remove gains oss-matte-feynobg (open) and bria-guided-cutout (cloud). A new RemoveBgTool shows a 'What to keep or drop (optional)' box for a guided model, and the server's Layers bg-remove step sends those words. Both models also appear in the Canvas bg-remove node's model list, since they are bg-remove models."
- },
- {
- "feature": "Exports",
- "status": "built",
- "verifiedHow": "Exports: the open cut-outs write ProRes 4444 with alpha or EXR themselves, because Export's VHS loader reads a VP9 WebM without its alpha (checked with ffmpeg: the default probe reports yuv420p). A result whose matteOutput is mask or clean foreground gets a new 'Export as ProRes or EXR' action linking to /upscale/export?video=…&format=prores_4444; it is not shown when the Engine mode is Paid APIs only."
- },
- {
- "feature": "Licences",
- "status": "built",
- "verifiedHow": "Licences: VRMBG's text says NON-COMMERCIAL, so it is flagged. 'Corridor Key Licence' reads as 'conditions', and its paid-API rule is stated plainly. FeyNoBg reads 'unknown'. New NODE_PACKS row for the CorridorKey wrapper (no LICENSE file); the ComfyUI-RMBG note now mentions VRMBG and FeyNoBg. All new models are on by default."
- }
- ],
- "tests": "New tests/keying.test.ts (15 tests, pass): the 3 graphs' packs, pins and roles; every node's inputs checked against the recorded class definitions (required inputs present, links to existing outputs of the right type, combo values valid); licence flags; the VRMBG gate and first-run downloads; the meta-batch chunking; every output and format path (WebM, ProRes 4444, EXR, mask, foreground, and the refusals); FeyNoBg's bindings; the Green screen list split, palette links and /connect row; settings shape; payloads for both Bria routes; Layers model lists; the export action.\nComfyUI validation (live CPU server, --shared): all 3 graphs answer missing_node_type as expected, because ComfyUI-RMBG 3.3.0 and the CorridorKey wrapper are not installed on the server. They are therefore validated: false. Their classes are checked statically against the packs' source in tests/keying.test.ts. tests/comfy-library-4.test.ts got the 3 ids added to its unvalidated list (the one allowed edit).\nOther test edits: tests/gpu-requirements.test.ts's gated-file regex now includes briaai/VRMBG-3.0.\nTargeted suites pass: comfy-library-4, comfy-library-7, comfy-library-notes, gpu-requirements, gpu-readiness, video-tool-options, command-palette, licences, layers, layers-comfy, catalog, cloud-catalog(-4), composer, studio-pickers, model-counts, connect-card-studios, canvas-models, model-access(-studios), engine-mode, remove-object-comfy, marketing-catalog, voice-design-comfy, open-tools, restore-comfy, comfy-character-swap.\nFull Vitest, run once (before the last two fixes): 9 failed of 5060. Pre-existing: split-soundtrack, soul-runs ×2, preset-featured, dop-originals, comfy-reuse, preset-covers (a known timeout under load). Two were mine and are now fixed and pass: model-access (the wrapper's NODE_PACKS row) and comfy-character-swap (the object_info subset restored).\nBrowser (tests/e2e/keying.mjs, demo mode, pnpm dev on port 3412): 85 checks passed. Covered at 1440 and 390 px, light and dark, both engines: the Green screen heading and default model (CorridorKey / Bria green screen); the price (Placeholder with no GPU connected); the settings listing Cutout video / Alpha mask / Clean foreground and WebM / ProRes 4444 / EXR; Remove background opening on VRMBG 3.0 via ?model= and not listing CorridorKey; Layers' Remove background listing FeyNoBg (open) and Bria guided cut-out with its box (cloud, 1440); no sideways scroll; no page or console errors. Screenshots must be taken with caret 'initial': Playwright's caret hiding caused a false hydration mismatch. The server was stopped and .next deleted afterwards.\ntypecheck (next typegen + tsc --noEmit) passes on the final commit; it needs NODE_OPTIONS=--max-old-space-size=6144 here, because the default heap ran out of memory.",
- "left": [
- "Nothing has run on a GPU: CorridorKey v1.0 through the wrapper, VRMBG 3.0 (needs Bria's approval and the four files placed in models/RMBG/VRMBG-3.0/), FeyNoBg (needs the nobg Python package). Untested: VHS's ProRes 4444 alpha for RGBA frames, whether SaveImageAdvanced writes a 4-channel EXR alpha and how its inverse sRGB treats alpha, and the CorridorKey meta-batch across passes.",
- "To validate here, the server needs ComfyUI-RMBG updated to a66a5e64 (+ nobg, refiners) and ComfyUI-CorridorKeyWrapper @7eb44e48 installed. Its loader pip-installs Corridor's v1 engine from GitHub the first time it runs.",
- "CorridorKey 2.0 waits for a ComfyUI wrapper that loads corridorkey_v2.safetensors.",
- "LTX-2.5 Alpha-Gen ('Best · Alpha-Gen', 48 GB+) is recorded for later: the library's LTX-2.5 IC-LoRA graph (video-restore-ltx25-tiled) has not validated.",
- "Item 4 is not built. Character Swap Studio Finish and Remove object use SAM masks of a subject picked by clicks or words. VRMBG and CorridorKey matte the whole foreground with no way to pick one subject, so they are not a drop-in. Offering them there needs a Finish option UI.",
- "No in-graph EXR or ProRes for the BiRefNet/SAM mattes: their cut-outs can't be exported with alpha. Only their mask results get the Export link.",
- "Hosted runs (poolQuote) were not specifically tested for the new open models. No new API routes were added, so public sign-up rules are unchanged.",
- "The Layers 'What to keep or drop' box renders above the Model select (the children come before the picker in SimpleTool). This could be reordered."
- ],
- "docsNotes": "STATUS/FEATURES: Video tools → Green screen (CorridorKey on your GPU, Bria green-screen despill in the cloud, $0.05/s); Remove background adds Bria VRMBG 3.0 on your GPU (gated weights, non-commercial unless Bria agrees); Layers' Remove background adds FeyNoBg fine hair (licence unknown) and Bria's guided cut-out ($0.03/image, optional what-to-keep words); open cut-outs come as WebM, ProRes 4444 with alpha, or linear EXR frames; masks link to Export.\nARCHITECTURE: ModelOptions.greenScreen splits bg-remove-video models between Remove background and Green screen (studioCatalog, palette modelHref, gpu studioOthers). ModelOptions.guided marks a cut-out that reads words. MatteOutput 'foreground' and VideoFormat 'webm_alpha' are new. src/lib/av/keying.ts holds keyFormatValues and exportsCleanly. The ComfyUI provider keeps role 'frames' only for format exr, and routes 'foreground' through the cut-out node.\nscripts/comfy/README.md could get a 'Green screen and fine hair (nm10-keying)' section, written from the spec notes: the 3 graphs, the packs (ComfyUI-RMBG 3.3.0 @a66a5e64, ComfyUI-CorridorKeyWrapper @7eb44e48), validated no (missing_node_type), the CorridorKey v1/v2 situation.\nCREDITS.md: CorridorKey (Corridor Digital, Corridor Key Licence), Bria VRMBG 3.0, FeyNoBg (1038lab), pixelworldai's CorridorKey wrapper.\nBrief out of date: the video-bg-remove-* graphs are not chunked (the key's VHS meta-batch follows video-export-pro-chunked instead); ComfyUI-RMBG has no 3.3.0 tag; no CorridorKey wrapper loads 2.0. The research corrections are in new-models-10.md/.json."
- },
- "review": {
- "findings": [
- {
- "file": "src/server/providers/comfyui.ts",
- "line": 2269,
- "severity": "major",
- "summary": "Green screen's EXR output fails on any clip longer than one 32-frame pass. video-key-corridorkey runs in VHS meta-batch passes, but its SaveImageAdvanced EXR node (node 11) saves in every pass. When the first prompt finishes, its history already holds that pass's 32 EXR frames, so poll() never calls followMetaBatch. bundleFrames then finds no preview video and throws. Even when followMetaBatch does run, it keeps only the newest pass's files, so the frames from earlier passes would be lost anyway.",
- "failureScenario": "CorridorKey on your GPU, Cutout video plus EXR, any clip over 32 frames (about 1.3 s at 24 fps). Pass 1 completes with outputs {7: unfinished_batch, 11: 32 EXR images}, and poll answers {state: failed, error: 'The EXR export finished without its preview clip'}. Passes 2..N stay queued and keep using the GPU, because the job is forgotten rather than cancelled. I reproduced this with a scratch vitest that stubs ComfyUI's history and queue for comfyProvider.poll (meta {workflowId: video-key-corridorkey, metaBatch: true}). tests/keying.test.ts only checks prepareWorkflow and never polls a multi-pass EXR job.",
- "verified": true
- },
- {
- "file": "scripts/comfy/library.spec.mjs",
- "line": 400,
- "severity": "major",
- "summary": "The VRMBG 3.0 weights are indexed under folder 'RMBG', but ComfyUI-RMBG registers its folder under the key 'rmbg' (add_model_folder_path(\"rmbg\", models/RMBG)). The GPU pre-flight's folder listing looks up GET /models for 'RMBG', never finds it, marks the folder missing, and reports the file as missing even when it is installed. Because the file has presence 'list' and is not loader-read, nothing corrects that.",
- "failureScenario": "The owner gets Bria's approval and places the four files in models/RMBG/VRMBG-3.0/. /connect still shows Bria VRMBG 3.0 as Needs setup. For an account, src/server/gpu/gate.ts blocks the run with 409 gpu-setup once a live read confirms the file as 'missing'. On the live CPU ComfyUI here, GET /models lists \"rmbg\", GET /models/RMBG answers 404 and GET /models/rmbg answers 200. src/lib/gpu/gather.ts sets folderMissing when !present.has(folder), and filePresence then returns 'missing'.",
- "verified": true
- },
- {
- "file": "scripts/comfy/library.spec.mjs",
- "line": 2498,
- "severity": "major",
- "summary": "The package says no ComfyUI wrapper loads CorridorKey 2.0 yet and ships the v1.0 weights instead, but at least three public wrappers load corridorkey_v2.safetensors plus foundation_stats.safetensors. The brief asked to check which wrapper loads 2.0, and only the three it named were checked. The brief's headline model (native-resolution 2.0, 4-6 GB) is therefore not delivered, and the UI, notes and research present v1 as the only option.",
- "failureScenario": "Shallow clones checked 2026-11-02: hashu786/ComfyUI-CorridorKey2 @d1228b68 (2026-10-28), miguelangelarribas/ComfyUI-CorridorKey2 @ab948899 (2026-10-29; vendors upstream CorridorKey2.0 at 485f5e9, its loader reads corridorkey_v2.safetensors) and marawan206/ComfyUI-CorridorKey2.0 @c3abf212 (2026-11-02). All three are under the Corridor Key Licence 2.0 and grep for corridorkey_v2 in their loaders. Users get the v1 model (about 10 GB at 2048 px on NVIDIA) where a 2.0 graph was possible.",
- "verified": true
- },
- {
- "file": "scripts/comfy/library.spec.mjs",
- "line": 1188,
- "severity": "major",
- "summary": "Settings → Models & licences shows FeyNoBg's licence as 'commercial', not 'unknown'. Its text, 'FeyNoBg weights: unknown (...); ComfyUI-RMBG code GPL-3.0', matches none of licenceTerms' flags, and it is not UNKNOWN_LICENCE, so licenceInfo classes it as commercial and buildLicenceList gives the row flags []. The brief and the report both say it should read unknown.",
- "failureScenario": "In the scratch vitest, licenceInfo(workflowLicence(image-matte-feynobg)) gives {name: 'FeyNoBg weights', class: 'commercial'}, and buildLicenceList's oss-matte-feynobg row has flags []. The admin sees an unlicensed model filed with the commercial-OK ones, with no warning. tests/keying.test.ts only checks the text prefix, not the class.",
- "verified": true
- },
- {
- "file": "src/lib/studios.ts",
- "line": 463,
- "severity": "minor",
- "summary": "Green screen promises 'footage shot on a green or blue screen', but blue can't be chosen. Nothing in src sets params.extra.screenColor (there is no option or enum for it). pixelworldai's CorridorKeyGreenscreen never passes the engine's screen_channel, which defaults to green. Bria's cloud despill is for green screen only. The UI does not say plainly what each engine does here.",
- "failureScenario": "A user uploads blue-screen footage because the copy invites it. ChromaKeyPrepass runs with screen_color 'green' and CorridorKey despills green, so the matte comes out wrong on both engines. grep for screenColor or screen_color in src finds nothing. The wrapper's key() calls process_frame without screen_channel, and CorridorKey's process_frame defaults screen_channel to 1 (green).",
- "verified": true
- },
- {
- "file": "src/lib/licences.ts",
- "line": 282,
- "severity": "minor",
- "summary": "CorridorKey's licence row is named 'CC BY-NC 4.0' and links to SPDX CC-BY-NC-4.0. The KNOWN regex /CC[- ]BY[- ]NC(?:[- ]4\\.0)?\\b/ matches 'CC BY-NC' inside 'CC BY-NC-SA 4.0', yet the licence is the Corridor Key Licence 1.0, a CC BY-NC-SA 4.0 variant that allows commercial projects. The class 'conditions' is right, but the name and link are wrong.",
- "failureScenario": "In the scratch vitest, licenceInfo for video-key-corridorkey gives {name: 'CC BY-NC 4.0', class: 'conditions', url: spdx CC-BY-NC-4.0}. Settings then shows the wrong licence name and links to a non-commercial licence page for a model whose own terms allow commercial projects.",
- "verified": true
- },
- {
- "file": "scripts/comfy/library.spec.mjs",
- "line": 2484,
- "severity": "minor",
- "summary": "video-key-corridorkey sets vramGb 6, which is Corridor's figure for CorridorKey 2.0. The graph runs v1.0 through a wrapper that builds CorridorKeyEngine with img_size=2048, and Corridor's v1 README says inference at 2048x2048 uses about 10 GB on NVIDIA.",
- "failureScenario": "The pre-flight board marks Green screen as Ready on a 6 or 8 GB GPU, and the run then runs out of memory on the first pass. Sources: the CorridorKey v1 README ('CorridorKey inference at 2048x2048 uses ~10GB on NVIDIA') and nodes/load_model.py at 7eb44e48 (img_size=2048).",
- "verified": true
- },
- {
- "file": "scripts/comfy/install-comfyui.sh",
- "line": 51,
- "severity": "minor",
- "summary": "The wrapper is pinned, but the first time LoadCorridorKeyModel loads it runs pip install --no-deps 'corridorkey @ git+https://github.com/nikopueringer/CorridorKey.git' at the branch head, unpinned, inside ComfyUI's Python. That includes the install's own ComfyUI when hosted runs are on. The install script does not pre-install a pinned engine.",
- "failureScenario": "Whatever is on CorridorKey's main branch on the day of the first run gets installed and executed. An API change or a compromised upstream breaks or affects every install, with no pin to roll back to. The engine's current head (97e55a45) is compatible with the wrapper's calls today.",
- "verified": true
- },
- {
- "file": "src/lib/layers.ts",
- "line": 234,
- "severity": "minor",
- "summary": "Parts of the brief are missing. Item 4 (offer the new matte in Character Swap Studio Finish and Remove object) was not built; the report acknowledges this. The guided cut-out's optional autocrop is not exposed. The guided words box exists only in Layers: the Canvas bg-remove node and the Remove Background app list bria-guided-cutout but give no way to enter the keep-or-drop words.",
- "failureScenario": "Picking Bria guided cut-out in the Canvas node runs only the plain cut-out of the obvious subject. I checked this by reading the code: the Canvas node and the app are not changed in the diff. I did not exercise them in a browser.",
- "verified": false
- },
- {
- "file": "src/components/layers/tools.tsx",
- "line": 712,
- "severity": "nit",
- "summary": "The 'What to keep or drop' box renders above the Model select, because SimpleTool places its children before the picker. Choosing Bria guided cut-out makes a field appear above the control the user just changed.",
- "failureScenario": "The layout shifts above the focus point when the model changes. This is minor for keyboard and screen-reader users. The report acknowledges it.",
- "verified": true
- }
- ],
- "checks": "Read the review prompt and main-rules. Reviewed git diff claude/fuobe-parity-4...o/nm10-keying (9 commits, 46 files) with the code around it: prepareWorkflow and poll/followMetaBatch/bundleFrames, plan checks, studioCatalog/modelHref/studioOthers split, Layers job steps, output actions, licences, GPU pre-flight gather/readiness/gate. Primary sources: fal OpenAPI for bria/video/background-removal/green-screen-despill (video_url required; spill_suppression 0-1, default 1; output_container_and_codec enum incl. webm_vp9; preserve_audio) and bria/guided-remove-background (image_url, nullable prompt, autocrop, sync_mode). These match the payloads and the $0.05/s and $0.03/image prices. HF API: briaai/VRMBG-3.0 @59716e19 is gated (manual), card says non-commercial only, model.safetensors is 884,915,688 B with sha256 3100fd29…, matching model-pins.json. 1038lab/FeyNobg @59dd27c6 has no licence. nikopueringer/CorridorKey_v1.0 is tagged cc-by-nc-sa-4.0. CorridorKey2.0 is at cf44a8db. Cloned pixelworldai/ComfyUI-CorridorKeyWrapper @7eb44e48: class names, inputs and output slots (MASK, foreground, processed_rgba, comp) match the graph wiring. Cloned ComfyUI-RMBG @a66a5e64 (version 3.3.0): AILab_VRMBG and AILab_FeyNoBg inputs and outputs match; the folder key is 'rmbg'. Cloned three ComfyUI CorridorKey 2.0 wrappers, which disprove the 'no v2 wrapper' claim. Checked the CorridorKey v1 engine head (API compatible, timm covered by the install script; VRAM about 10 GB at 2048 px). Checked the live CPU ComfyUI: /models lists 'rmbg', /models/RMBG answers 404. Scratch vitest (custom config in the scratchpad, no worktree edits) reproduced the multi-pass EXR failure and computed the licence classes (FeyNoBg 'commercial'; CorridorKey named 'CC BY-NC 4.0'). Targeted Vitest: keying, comfy-library-4, gpu-requirements, licences, video-tool-options, layers, model-access, connect-card-studios, comfy-provider: 9 files, 239 tests, all pass. eslint on the changed source files is clean. No full Vitest, typecheck or browser run in this stage (the implementer reports typecheck and 85 browser checks passing). Public sign-up: no new routes, and the Layers and generation paths are unchanged in shape, so no sign-up issues found. No Higgsfield API use and no LoRA or preview media committed. Worktree left clean; scratch clones deleted.",
- "verdict": "Changes requested. The research, payloads, pins, graph wiring and Green screen list split are solid, and the targeted tests pass. Four major issues need fixing before merge. (1) EXR on the chunked CorridorKey key fails for any clip over 32 frames: the first pass's EXR frames short-circuit the meta-batch follow-up, and frames from earlier passes would be lost anyway. (2) The VRMBG weights' index folder 'RMBG' does not match ComfyUI's 'rmbg' key, so the pre-flight never sees the weights and accounts are blocked. (3) The 'no CorridorKey 2.0 wrapper' premise is false: at least three wrappers load corridorkey_v2.safetensors, so the 2.0 graph the brief asked for is buildable. (4) FeyNoBg's licence is classed commercial in Settings, not unknown. Also fix the blue-screen claim (no UI, and neither engine keys blue), the CorridorKey licence name and link, the v1 VRAM figure, and the unpinned runtime pip install."
- },
- "fix": {
- "applied": [
- "Major 1 (EXR on a meta-batched key): confirmed. When a key ran in several passes and its first pass saved only EXR frames, the run finished early and failed, and earlier passes' frames were lost. Fixed in src/server/providers/comfyui.ts with a new metaBatchResults helper. A meta-batch job whose entry holds frames but no clip now follows its passes. The passes are put in order by ComfyUI's numbering: the first pass keeps a number of 0 or more, and VHS re-queues each later pass under a more negative number. The result is the last pass's clip plus every pass's frames, in order. The same logic covers both paths: poll/followMetaBatch on the server, and planRelayOutputs for a job on someone's computer. When frames are present, the history window grows to META_BATCH_HISTORY (512, in src/lib/relay.ts). The computer tab (src/lib/computer-runner.ts) now reads that window once, after the last pass, instead of on every poll. Tests in tests/comfy-provider.test.ts cover a 3-pass EXR poll (6 frames, in order), the relay plan (follow first, then collect every frame) and the ordering helper.",
- "Major 2 (VRMBG folder case): confirmed on the live CPU ComfyUI: GET /models lists 'rmbg', and /models/RMBG answers 404. Fixed in src/lib/gpu/gather.ts. A folder that is not listed under its exact name is matched without regard to case ('RMBG' finds 'rmbg') and stored under its index name. modelRoots match the same way. The index keeps 'RMBG', which is the real directory, so the download commands and the 'put it in models/RMBG' wording stay right on Linux. New test in tests/gpu-probe.test.ts; it fails without the fix.",
- "Major 3 (CorridorKey 2.0): confirmed. I re-checked six wrappers at their sources (shallow clones on 2026-11-02, plus the HF API). hashu786/ComfyUI-CorridorKey2 @d1228b68, miguelangelarribas/ComfyUI-CorridorKey2 @ab948899 and marawan206/ComfyUI-CorridorKey2.0 @c3abf212 all load corridorkey_v2.safetensors. All three ship Corridor Key Licence 2.0 (hashu786's file is byte-identical to upstream). hashu786 and miguelangelarribas vendor upstream corridorkey/ at 485f5e9 unmodified (checked with diff -r); marawan206 patches blocks.py. I built on hashu786's pack. It is the simplest graph: one CorridorKey2 node gives fg, matte, processed, QC and an RGBA cutout. It installs nothing at run time. Its first run downloads about 5.1 GB into models/corridorkey2/. That is Corridor's corridorkey_v2.safetensors (2,661,698,720 B, sha256 c43596de…, from the main revision, which was cf44a8db when checked) and foundation_stats, plus three frozen models at pinned revisions: C-RADIOv4-SO400M c0457f5d (1.72 GB, NVIDIA Open Model License), MoGe-2 ViT-B ca5f0e07 (0.42 GB, MIT) and RVM small (0.27 GB, CC-BY 4.0, md5-checked). VRAM: 4 GB up to 1440p and 6 GB for 4K (vramGb 6), NVIDIA RTX 30 or newer. The graph keeps the id video-key-corridorkey and is still meta-batched, now at 48 frames per pass. The cut-out is output 4 (RGBA); the matte is output 1; 'foreground' is output 2, the despilled foreground premultiplied over black. EXR frames come from output 4. The despill slider is now 0-1 with a default of 0.5, Corridor's own range. Pack ComfyUI-CorridorKey2 is pinned in packs.json and install-comfyui.sh. CUSTOM_NODE_REPOS, PACK_CLASSES and the NODE_PACKS licence row are updated. CorridorKey2's class is recorded in object_info.subset.json from its source, and the three v1 classes are removed. The manifest, requirements.json and validation-state are rebuilt: missing_node_type, validated false, as expected. The catalog model is now 'CorridorKey 2.0'. I dropped v1.0 and the pixelworldai wrapper. v2 does the same job in 4-6 GB at native resolution, where v1 needs about 10 GB at its 2048 px working size. v1's wrapper also pip-installed an unpinned engine at run time. Dropping v1 also resolves minors 7 and 8. Research docs (new-models-10.md/.json) are corrected.",
- "Major 4 (FeyNoBg filed as commercial): confirmed. In licenceInfo, a text of the form '<model> weights: unknown (…)' is now class 'unknown' ('Not recorded', linking the model card). Non-commercial or regional terms still win over it.",
- "Minor 5 (blue screen): confirmed. Corridor's v2 despill (_despill_average_srgb_torch) and Bria's endpoint both take out green only. The copy now says green screen. The Green screen subtitle also says plainly what each engine gives: on your GPU, the cut-out, mask or clean foreground as WebM, ProRes 4444 or EXR; in the cloud, the cut-out as a transparent WebM. The unused screenColor binding key is removed.",
- "Minor 6 (licence name and link): confirmed. A KNOWN entry 'Corridor Key Licence 2.0' (class conditions) now comes before the CC entries and links Corridor's LICENSE at 485f5e9. The CC BY-NC regex no longer matches inside 'CC BY-NC-SA', and the SA entry accepts the spaced spelling.",
- "Minor 9 (partly): the Canvas Remove background node now shows a prompt port for a guided model (ModelOptions.guided). Words from a text node reach Bria's guided cut-out; a test checks the planned request. The Remove Background app was not affected: it uses fixed BiRefNet routes.",
- "Nit 10: Layers' 'What to keep or drop' box now sits below the Model select, through a new SimpleTool afterModel slot. Checked in a screenshot.",
- "tests/e2e/keying.mjs now expects 'CorridorKey 2.0'."
- ],
- "rejected": [
- "Minor 7 (vramGb 6 is too low for v1): no longer applies. The graph runs 2.0, and Corridor gives 6 GB as its 4K figure in low-VRAM mode.",
- "Minor 8 (unpinned runtime pip install): no longer applies. The v1 wrapper is gone, and hashu786's pack installs nothing at run time. One gap remains and is listed under 'left': Corridor's own weights download from the HF main revision.",
- "Minor 9, autocrop: not exposed. In Layers a cropped cut-out would no longer line up with its layer box. On the Canvas, the plain cut-out is the expected output.",
- "Minor 9 / brief item 4 (offer the new matte in Character Swap Studio Finish and Remove object): not built. Both run SAM masks of one subject, picked by clicks or words, with frame windows and a previous mask (planMask). VRMBG 3.0 and CorridorKey 2.0 matte the whole foreground with no way to pick a subject, so they are not a drop-in. Offering them needs a mask-model choice in the studio's mask versions."
- ],
- "checks": "Worktree /home/user/wt/o-nm10-keying on o/nm10-keying. Its base claude/fuobe-parity-4 @cb1d3b3a is an ancestor; the branch has only this package's commits and no merges. 6 new commits, not pushed. Targeted Vitest passed: comfy-provider, computer-relay, computer-pure, gpu-probe, gpu-readiness, gpu-requirements, keying (16), licences, comfy-library-4/-7/-notes, model-access, video-tool-options, connect-card-studios, catalog, model-counts, studio-pickers, command-palette, canvas-models, canvas-plus, canvas-api. The new gpu-probe test fails without the fix. npx next typegen plus pnpm typecheck (NODE_OPTIONS=--max-old-space-size=6144): exit 0. pnpm lint: exit 0 with 3 warnings, none in changed lines. Full Vitest, run once (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 6 failed out of 5065, all on the known list: comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack. Library: build-library.mjs video-key-corridorkey against the live CPU ComfyUI. validate-workflows.mjs --shared video-key-corridorkey gives missing_node_type for CorridorKey2, as expected. I put back object_info.subset.json afterwards (base records, plus CorridorKey2, minus the v1 classes). No packs were installed and the server was not restarted. Browser: tests/e2e/keying.mjs, demo mode, pnpm dev on localhost:3412. 85 checks passed at 1440 and 390 px, light and dark, on both engines, with no console or page errors. Screenshots checked: the Green screen subtitle and CorridorKey 2.0, and the Layers box under the model. The server was stopped, .next and the scratch clones were deleted, and git status is clean.",
- "finalSummary": "Open engine (your ComfyUI): Green screen runs CorridorKey 2.0 through hashu786/ComfyUI-CorridorKey2 @d1228b68 (Corridor Key Licence 2.0; no paid API or resale, shown in Settings as Conditions). It runs in 48-frame passes, so a long EXR key now waits for its last pass and zips every pass's frames. It writes a WebM, ProRes 4444 or EXR cut-out, its mask, or the clean foreground. It needs an NVIDIA RTX 30-series card or newer with 4-6 GB, and downloads about 5.1 GB on first run. Bria VRMBG 3.0 in Remove background needs Bria's approval and the files placed in models/RMBG/VRMBG-3.0/; the GPU check now finds them there. FeyNoBg fine hair in Layers reads as licence Not recorded. All three are built and checked statically against their packs' source. None has run on a GPU, and none validates on the CPU server, which lacks the packs. Cloud engine (fal, needs a fal key): Bria green-screen despill ($0.05/s, cut-out only as WebM) and Bria guided cut-out ($0.03/image, optional what-to-keep words in Layers and now on the Canvas node). Payloads are checked against fal's schemas; no live call was made. Guests and accounts under public sign-up: no new routes. Guests browse these tools read-only. Accounts run the open models on their own GPU through POST /api/generations as for any studio run, and cloud runs stay the owner's. The relay fix keeps an account's frame limits (1,800 EXR frames, file budget) as before.",
- "left": [
- "Nothing here has run on a GPU yet. To check: CorridorKey 2.0 through hashu786's node (CUDA only); whether VHS's ProRes 4444 keeps the alpha of RGBA frames; whether SaveImageAdvanced writes a 4-channel EXR; the seam between 48-frame passes (each pass starts its temporal window afresh); VRMBG 3.0 (gated) and FeyNoBg (needs the nobg package).",
- "hashu786's first-run download takes Corridor's corridorkey_v2.safetensors from the HF main revision; it was cf44a8db when checked. The three frozen models are pinned. A Fuobe-side pin would mean pre-placing the weights through an install step, or the pack accepting a revision.",
- "To validate on the CPU server, it needs ComfyUI-RMBG @a66a5e64 (+ nobg, refiners) and ComfyUI-CorridorKey2 @d1228b68. tests/comfy-library-4.test.ts already lists the 3 ids as unvalidated; the id did not change, so that file was not edited again.",
- "Brief item 4 (Character Swap Finish, Remove object) is not built; see 'rejected'.",
- "LTX-2.5 Alpha-Gen is still recorded for later; video-restore-ltx25-tiled has not validated.",
- "BiRefNet and SAM cut-outs still can't be exported with alpha (only their masks get the Export link).",
- "The pre-flight board has no 'NVIDIA only' marker, so a Mac or AMD GPU sees CorridorKey 2.0 as runnable until the node refuses. Its notes say CUDA only.",
- "docsNotes from the implementer still apply. Update the names: CorridorKey 2.0 through hashu786/ComfyUI-CorridorKey2 for CREDITS.md and the scripts/comfy/README section."
- ]
- },
- "merge": {
- "merged": [
- "o/nm10-keying"
- ],
- "notMerged": [],
- "conflicts": "library.spec, studio-context (voiceFirst + greenScreen), licences regex, packs (ComfyUI-RMBG newer pin a66a5e64), manifest; requirements regenerated",
- "checks": "batch of 6 (n7-11, o12 re-merge, pika-flex, keying, rtx-video, speech-edit): typecheck 0, lint 0, vitest 5612 passed, 8 failed (6 main known + blockout and moderation-hook load timeouts, 41/41 alone); requirements budget raised to 288/36 KB (a150159e); each merge checked by an independent verifier",
- "pushed": true,
- "head": "a150159e"
- }
-}
diff --git a/docs/handoff/reports/nm10-pika-flex.json b/docs/handoff/reports/nm10-pika-flex.json
deleted file mode 100644
index 70565c54..00000000
--- a/docs/handoff/reports/nm10-pika-flex.json
+++ /dev/null
@@ -1,163 +0,0 @@
-{
- "key": "nm10-pika-flex",
- "impl": {
- "branch": "o/nm10-pika-flex (pushed at 9d23a846, 3 commits on claude/fuobe-parity-4 fdad177c)",
- "summary": "Pika H3 Flex now runs on the open engine. There are four 6-step graphs on Pika's Comfy adapters, and all four pass validation on the live CPU ComfyUI. MiniMax H3 gets a Quality choice 'Fast · Pika Flex (6 steps)' next to Standard (8 steps) and Sharper (20 steps). The Video studio gets a References mode: up to 9 images, 3 clips and 3 voice or music clips, checked against Pika's limits before anything uploads, shown in order as 'Image 1 … Clip 1, Voice 1', which the server turns into H3's <Picture N>/<Video N>/<Audio N> tags. Cinema takes on your GPU send @Elements, several images and reference clips to Ref2VA. Lipsync & avatars gets 'Talk from a voice clip'. Settings → Models & licences lists both adapters with Pika's NOTICE, switched on. /connect gets a 'Video from references' row. There is no cloud route: no cloud service offers Pika H3 Flex, and the UI says so.",
- "built": [
- "Graphs minimax-h3-flex-t2v / -i2v / -flf2v (FL2VA) and minimax-h3-flex-ref2va (core MiniMaxH3ReferenceToVideo). They are hand-built in scripts/comfy/hand-built, follow Comfy-Org's video_pika_h3_flex_* templates, and have library.spec.mjs entries. Sampling: LoraLoaderModelOnly at 1.0, KSamplerSelect lcm, ManualSigmas 1.0, 0.972973, 0.923077, 0.8, 0.571429, 0.333333, 0 (the 1000/750/500/250/100/40/0 knots at video shift 12), BasicGuider at CFG 1, no SigmaShift node and no Turbo LoRA. All four built and validated (validated: true). Two expanded ref2va variants (2 images + clip + voice, and clip only) were also POSTed to the live ComfyUI with 0 node_errors.",
- "Pika's files pinned at 3ff166447d5e in workflows/comfyui/model-pins.json: pika_h3_flex_fl2va_comfy_bf16 (1956172176 B, sha 68783e64…) and pika_h3_flex_ref2va_comfy_bf16 (1956172176 B, sha e4d058fb…). requirements.json was rebuilt. The adapters are downloaded at run time (pikaFlexGraphLoras in src/lib/catalog/pika-flex.ts, wired into graphLoras in generations.ts), never committed.",
- "src/lib/h3-references.ts (pure): H3_REFERENCE_LIMITS, h3ReferenceProblem (needs an image or clip; 9/3/3, 12 in all; each clip 2-15 s; each group ≤ 15 s; a clip's own sound isn't counted as a file), h3ReferenceLabels, h3ReferenceTags, h3TalkPrompt, openReferenceMode, and expandH3References. The expander adds loaders in order: LoadImage → ref_images.ref_image_N; VHS_LoadVideo at 24 fps capped at 360 frames → ref_videos, plus the clip's own sound → ref_video_audios when the header says it has sound; LoadAudio → ref_audios. Image 1's loader is removed when there is no image.",
- "comfy-variants: H3_FLEX_GRAPH (quality 'flex' → the Flex graphs; an orbit still wins). Manifest expand type gains 'references'.",
- "ComfyUI provider: on the references graph, Pika's limits are checked on the uploads' headers before the run. Aspect ratio is kept for references (not frames). Avatar on H3 = one image + the voice as audio reference, with frames set to h3Frames(voice length clamped to 5-15 s). generations.ts wraps ref2v prompts (names → tags) and avatar prompts (h3TalkPrompt) in H3's layout.",
- "Catalog oss-minimax-h3: ref2v and avatar routes on minimax-h3-flex-ref2va; maxImages 9, maxVideos 3, maxAudios 3; Quality values fast/best/flex relabelled 'Standard · 8 steps' / 'Sharper · 20 steps, about 2.3x longer' / 'Fast · Pika Flex (6 steps)'. engineNote says Flex runs on your GPU only and the cloud runs hosted MiniMax H3 without it. takesClips accepts ComfyUI routes whose model declares maxVideos/maxAudios.",
- "Cinema (planVideo): on your GPU, a model with a references mode takes several images or @Elements and clips as ref2v. Images give way to clips so the total stays at 12. Other open models keep one start frame.",
- "Video studio UI: a 'References' chip (icon-only on phones) opens Add clip / Add voice tiles (new src/components/studio/reference-tray.tsx). Tiles are named Clip N / Voice N. An order line reads 'References in order: …' and shows Pika-limit problems; these block Generate through planError. Clip lengths are read in the browser. New Draft fields refClips/refAudios; upload reaper and replaceAttachment handle them; buildRequest sends inputs.videos/audios only for a studio with ref2v.",
- "Licences: PIKA_FLEX_LORAS rows (MiniMax H3 Community License, regions class, Pika's NOTICE with the Mellis, Inc. copyright among the notices, model card URL), switched on; knownSwitch knows them. Manifest licence text adds the adapters and the NOTICE requirement.",
- "GPU pre-flight: new STUDIO_ROWS row '/video?model=oss-minimax-h3' ('Video from references': the Ref2VA graph plus Pika's Ref2VA adapter). The Video row skips ref2v (new skipOps) so it doesn't ask for the Ref2VA partition. modelTool includes the graph's own adapter.",
- "Cloud check at primary sources: the fal OpenAPI schemas for minimax/h3/image-to-video/lora and minimax/h3/reference-to-video/lora take loras[{path, scale, weight_name}] but have no steps / scheduler / sigmas field, so fal runs its own schedule. fal model search for 'pika' returned 0 models. replicate.com/pika-labs/pika-h3-flex returns 404. Pika's hosted extras (4K, stems, prompt rewriter) are only on Pika's own API. So there is no cloud route, and the cloud keeps hosted minimax-h3 under its own name."
- ],
- "tests": "New tests/pika-flex.test.ts: 16 tests covering the graphs' contract and pins, variant choice, adapter downloads, reference limits / labels / tags, the expander, provider binding and refusals, Video-studio planning, Cinema mapping, Lipsync 'Talk from a voice clip' (158 frames for a 6 s voice), licence rows and pre-flight rows. All pass. Updated tests/open-minimax-h3, cinema-refs (on your GPU the note now names MiniMax H3 as the model that takes clips), and model-access-listings (183 LoRAs). Targeted runs passed: 28 files / 662 tests, then 27 files / 438 tests, then 4 files / 90 tests after the last UI change. This covered comfy-library-4/7/notes, comfy-provider, gpu-requirements, cinema*, elements, model-access*, public-signup*, hosted-runs, composer* and others. tsc and eslint are clean. No full Vitest was run. Browser check: new tests/e2e/pika-flex.mjs in demo mode at 1440 and 390, light and dark, all passed with no console errors and no sideways scroll. It covers the References tray, Clip 1 / Voice 1 order line, Free price (desktop), the 17 s voice refused, the Quality menu listing Fast · Pika Flex, no tray on the cloud H3, Cinema, and Lipsync with MiniMax H3. Dev server stopped and .next deleted. Nothing was rendered on a GPU: Pika's quality and speed claims are Pika's own, and Pika says no end-to-end ComfyUI render was verified.",
- "left": [
- "No GPU render of any Flex graph. VRAM is recorded as 32 GB (Pika published only H100 80 GB).",
- "The expander loads clips with VideoHelperSuite's VHS_LoadVideo at run time, so requirements.json doesn't list VHS for minimax-h3-flex-ref2va. VHS is in the standard install.",
- "When reference clips have mixed sound (clip 1 silent, clip 2 with sound), ref_video_audio numbering has gaps. The core autogrow node accepted this in validation, but it is not render-tested.",
- "Only 768p is offered (h3Canvas). Flex's 480p and 21:9 / 3:2 / 5:4 / 4:5 / 2:3 / 9:21 buckets are recorded in the notes but not exposed.",
- "Lipsync & avatars with MiniMax H3 still shows the Video slot, and the 'generation, not re-sync' wording appears only as the route note once the op is avatar. A more visible label could come later.",
- "The Quality chip still shows on H3's avatar and ref2v runs, where it has no effect: those always run Flex.",
- "Fuobe Speak and Genjutsu Motion were not given explicit H3 Flex options beyond what the catalog's avatar route makes available. Assist untouched.",
- "Alternatives recorded only, not built: Taobao MiniMax-H3-PTD-LoRAs (Ref2VA 4-step 5.58 GB / 8-step 11.11 GB), RefAsymOPD, FastH3 Omni.",
- "Already there before this package: oss-minimax-h3 with the turbo / 20-step / orbit graphs, the Ref2VA int8 base pin (Character swap), core MiniMaxH3ReferenceToVideo, and the inputs.videos/audios plumbing and account checks in generations.ts. Character swap and its Akatz LoRA graph untouched.",
- "Out-of-date brief detail: Comfy-Org's templates name the adapters pika_h3_flex_*_v1_bf16 (a Comfy-Org repack, 128 bytes larger, different sha). Fuobe pins Pika's own comfy/loras files instead.",
- "Parallel nm10-h3-any-gpu may touch the same oss-minimax-h3 entry (Quality control labels and routes) and comfy-variants: expect a small merge there.",
- "Pre-existing failures per rules item 8 were not re-run."
- ],
- "docsNotes": [
- "FEATURES / STATUS: MiniMax H3 on your GPU has Quality 'Fast · Pika Flex (6 steps)' (Pika H3 Flex), a References mode in the Video studio (9 images, 3 clips, 3 voice or music clips, 12 in all, named Image 1 / Clip 1 / Voice 1 in the prompt), Cinema references on your GPU, and 'Talk from a voice clip' in Lipsync & avatars. All open-engine only: no cloud service hosts Pika H3 Flex, and fal's MiniMax H3 LoRA routes run their own step count.",
- "ARCHITECTURE: src/lib/h3-references.ts (limits, tags, expander; manifest expand 'references'), src/lib/catalog/pika-flex.ts (adapters, NOTICE, graph LoRAs), H3_FLEX_GRAPH in comfy-variants, the reference-tray component, and STUDIO_ROWS skipOps plus the 'Video from references' row.",
- "Research correction for docs/research/new-models-10.md: Comfy-Org's Pika templates use repacked file names (pika_h3_flex_*_v1_bf16 in Comfy-Org/MiniMax-H3 at 912b6e38). The templates bake shift 12 into ManualSigmas and run lcm; there is no SigmaShift node.",
- "CREDITS: Pika H3 Flex adapters, Copyright 2026 Mellis, Inc., MiniMax H3 Community License; keep Pika's NOTICE."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium-high",
- "verdict": "CONFIRMED",
- "file": "src/lib/catalog/models.ts",
- "line": 617,
- "summary": "Lipsync & avatars with MiniMax H3: a Video + Voice request plans to text-to-video, so the person's clip and voice are dropped without a word.",
- "detail": "oss-minimax-h3 now has an 'avatar' route, so it shows in Lipsync & avatars, where the Video slot still shows and satisfies anyOf [image, video]. inferOperation (src/lib/catalog/plan.ts:36-50) returns 'lipsync' only when the model has a lipsync route, and 'avatar' only with an image. Every other branch misses, so it falls through to has('t2v'). Probe through planGeneration: {feature:'lipsync', modelId:'oss-minimax-h3', prompt:'friendly', inputs:{video, audio}} → op t2v, endpoint minimax-h3-t2v. With no words it answers 'Write a prompt first'. Neither the composer (studioOp is undefined for a 2-op studio) nor the server checks that the op is one of the studio's ops. This is new: every other avatar-only model has no t2v route to fall back to. Fix: on H3 in this studio, need the Portrait (hide or refuse the Video slot), or refuse a 'lipsync' request on a model with no lipsync route instead of falling through to t2v."
- },
- {
- "severity": "medium",
- "verdict": "CONFIRMED",
- "file": "src/components/studio/composer.tsx",
- "line": 686,
- "summary": "Video studio on H3: with an End frame set, the reference clips, voice clips and extra images are silently dropped (it runs flf2v), while the order line says they go.",
- "detail": "inferOperation checks images + endImage → flf2v (plan.ts:44) before ref2v. Probe: {images:[a], endImage:b, videos:[c]} on oss-minimax-h3 → flf2v / minimax-h3-flf2v. buildRequest still sends inputs.videos/audios, and refProblem / ReferenceOrder still show 'References in order: Image 1, Clip 1, Voice 1'. The flf2v graph binds only image/endImage, so the clips, voices and refs[1..] never reach the run. Fix: block it in planError (references can't be combined with an end frame), or hide the End frame while References is open."
- },
- {
- "severity": "medium",
- "verdict": "CONFIRMED",
- "file": "src/server/model-access.ts",
- "line": 360,
- "summary": "Switching off a Pika H3 Flex adapter in Settings → Models & licences does nothing: Flex, References and Talk runs still download and load it.",
- "detail": "PIKA_FLEX_LORAS rows have a switch (knownSwitch accepts them). But offeredLoras is only called on plan.loras (generations.ts:734) and on explicit graph-LoRA checks: regenSwitchedOff, swap-studio.ts:851/853, genjutsu.ts:263/268, remove-object.ts:174. pikaFlexGraphLoras feeds graphLoras → ensureLorasOnComfy (generations.ts:1809) with no access check. Every other graph-loaded LoRA refuses with 'switched off in Settings → Models & licences'. The owner's rule says the admin turns things on or off. Fix: refuse (or route Quality flex back to Standard) when offeredLoras([PIKA_FLEX_FL2VA|REF2VA]).dropped is non-empty, with a test."
- },
- {
- "severity": "low-medium",
- "verdict": "CONFIRMED",
- "file": "src/components/studio/reference-tray.tsx",
- "line": 346,
- "summary": "The References tray's 'Add clip' and 'Add voice' tiles have a 'Choose from library' button that does nothing.",
- "detail": "MediaSlot renders <LibraryPicker onPick={onChange}/> on every empty tile (media-slot.tsx:322). ReferenceTiles passes onChange={() => {}} for both tiles (lines 346 and 350), so picking a clip or voice from the library closes the popover and adds nothing. The button is keyboard-focusable (focus-visible:opacity-100). Fix: wire onChange to append the picked SlotValue to refClips/refAudios with the same max."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/lib/h3-references.ts",
- "line": 774,
- "summary": "A References run with a clip needs VideoHelperSuite, which requirements.json and the GPU pre-flight don't list, so the board can say Ready while the run fails at queue time.",
- "detail": "expandH3References adds VHS_LoadVideo per clip. requirements.json 'minimax-h3-flex-ref2va' lists packs:{} (the implementer noted it). An account's own ComfyUI without VHS gets Ready on 'Video from references' and an unknown-node error on its first clip run. The installed core LoadVideo + GetVideoComponents (used by other H3 graphs here) would avoid the pack, or VHS could go in the row's optional pack."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/lib/catalog/models.ts",
- "line": 615,
- "summary": "Parts of the brief are missing (all listed in 'left').",
- "detail": "No H3 Flex option in Fuobe Speak or Genjutsu Motion, Assist untouched. Lipsync's 'generation, not lip-sync of existing footage' wording is only in the route note. Flex's 480p and its other aspect buckets are not exposed. The Quality chip still shows on ref2v/avatar runs, where it has no effect. CREDITS.md is not updated with the Mellis, Inc. credit; it is only in docsNotes."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "tests/e2e/pika-flex.mjs",
- "line": 1,
- "summary": "The browser check is timing-sensitive on a cold dev server.",
- "detail": "The first run against a fresh demo-mode dev server failed 'order line names Clip 1 and Voice 1' and 'Free before the run' at 1440 light. A warm rerun passed every check. It should wait for the clip length and price to settle rather than reading them right away."
- }
- ],
- "checks": [
- "Diff claude/fuobe-parity-4...o/nm10-pika-flex read in full (33 files; base fdad177c = merge-base; 3 commits, neutral 'Area: result' messages; working tree clean; no LoRA or Higgsfield media committed; no Higgsfield API use; no new API routes, so public-signup, ESTIMATES/PREVIEWS, LIBRARY_CHANGES and request-body limits are unaffected).",
- "HF primary source: Pika-Labs/Pika-H3-Flex main = 3ff166447d5edb1406107ab8370c42000ce173e4. comfy/loras/pika_h3_flex_fl2va_comfy_bf16 (1956172176 B, sha256 68783e64…) and pika_h3_flex_ref2va_comfy_bf16 (1956172176 B, sha256 e4d058fb…) match model-pins.json. Card licence: minimax-h3-community-license-agreement. The NOTICE text matches PIKA_FLEX_NOTICE word for word. The card confirms the 9/3/3, 12-file, 2-15 s and ≤15 s per group limits, 480p/768p, the 124/362-frame grid, and that generic 6-step Euler is not equivalent.",
- "Comfy-Org workflow_templates video_pika_h3_flex_ref2va / _t2v: KSamplerSelect lcm, ManualSigmas '1.0, 0.972973, 0.923077, 0.8, 0.571429, 0.333333, 0.0', BasicGuider, LoraLoaderModelOnly at 1, ref2va/fl2va pruned int8 UNET. The branch's graphs match. I also checked the shift-12 maths for the knots.",
- "Live ComfyUI object_info: MiniMaxH3ReferenceToVideo autogrow inputs (ref_images max 9, ref_videos/ref_video_audios/ref_audios max 3) and VHS_LoadVideo (outputs IMAGE, frame_count, AUDIO, video_info; format 'None' valid). Node source (comfy_extras/nodes_minimax_h3.py:318-319) pairs ref_video_audio_N with ref_video_N by index, so the gaps for mixed-sound clips are correct, not a bug.",
- "Built expanded graphs through prepareWorkflow in a scratch Vitest (no repo edits): 2 images + silent clip + sounded clip + voice at 9:16 / 6 s → 768x1344, 158 frames, ref_video_audio_1 only on clip 2, in the right order. Avatar 3 s voice → 124 frames, 768x768, Image 1 + ref_audio_0. Not POSTed to ComfyUI: the validator's dummy model files are gone, and a real POST would queue a run.",
- "fal OpenAPI (primary): minimax/h3/image-to-video/lora and reference-to-video/lora take loras[{path, scale, weight_name}] with no steps, scheduler or sigmas field. fal model search 'pika h3' returns 0 models. replicate.com/pika-labs/pika-h3-flex returns 404. So no cloud route is right, and engineNote says so.",
- "Planner probes (scratch Vitest): Lipsync H3 video+voice+words → t2v (finding 1). Video start+end+clip → flf2v (finding 2). Audio only → ref2v, then refused 'Add at least one image or clip'. 1 image + quality flex → i2v with extra.quality flex → minimax-h3-flex-i2v.",
- "Traced the Settings switch: no offeredLoras check for the Pika adapters (finding 3). Traced MediaSlot's LibraryPicker → noop onChange (finding 4).",
- "Account and hosted paths: inputs.videos/audios/audio go through the existing prep/prepClip/prepVoice with account checks. decidePlace/poolQuote are generic over op. The GPU pre-flight row 'Video from references' resolves to the ref2va graph plus the Ref2VA adapter. Badges are keyed by model op, so the two /video rows don't collide.",
- "Targeted Vitest (20 files: pika-flex, open-minimax-h3, cinema, cinema-refs, cinema-models, model-access*, comfy-library-4/7/notes, gpu-requirements, gpu-readiness, comfy-provider, composer, elements, hosted-runs, public-signup, account-inputs, account-tenant): 586/586 passed. No full Vitest run.",
- "Browser: FUOBE_DEMO_MODE=on next dev on localhost:3317, implementer's tests/e2e/pika-flex.mjs at 1440/390, light/dark. Cold first pass had 2 FAILs at 1440 light; the warm rerun passed everything with no console errors and no sideways scroll. Server stopped (fuser -k 3317) and .next deleted."
- ],
- "verdict": "changes-requested: the graphs, pins, licence data, cloud decision and reference limits are right and verified at primary sources, but three flows fail without a word: Lipsync on H3 with a Video runs text-to-video, End frame + references runs flf2v without the references, and the Pika adapters' Settings switch doesn't stop runs. The dead library picker in the tray should be fixed too. All are small, local fixes; the rest of the findings are low."
- },
- "fix": {
- "applied": [
- "F1 (medium-high, confirmed): planGeneration (src/lib/catalog/plan.ts) now refuses a request where the operation was inferred and it drops an attached video, which happens when a video lands on t2v/i2v/flf2v/keyframes/ref2v/avatar (MAKES_FROM_STILLS). On a model with an avatar route and no lipsync route (MiniMax H3, InfiniteTalk) the message is: '<model> makes a new talking video from a portrait and the voice; it doesn't re-sync an existing clip. Add a portrait instead of the video, or pick another model'. Lipsync & avatars shows it as the blocker. Models that have a lipsync route (LatentSync) still re-sync.",
- "F2 (medium, confirmed): the planner refuses flf2v when reference clips or sound are attached. The composer also blocks References mode when an end frame sits next to extra images, clips or sound: 'References can't go with an end frame. Remove the end frame, or the references'. This blocker comes before 'Write a prompt first'; WRITE_PROMPT is now exported from src/lib/composer.ts.",
- "F3 (medium, confirmed): in src/server/generations.ts, a ComfyUI route whose graph loads a Pika adapter (pikaFlexGraphLoras) now checks offeredLoras. If the adapter is switched off, the run is refused. The owner sees '<Fast · Pika Flex | References | Talk from a voice clip> runs with “<adapter>”, which is switched off in Settings → Models & licences. Pick Standard or Sharper / Use one start frame, or pick another model, or turn it back on there'. An account sees '<mode> isn't available here. …', with no LoRA, Settings or file wording.",
- "F4 (low-medium, confirmed): the References tray's 'Choose from library' now adds the picked clip or voice. New attach.addToList (attachments.ts) applies the same max and toast, and ReferenceTiles gets an onPick prop.",
- "F5 (low, confirmed): new spec field runtimeNodes, for classes the app adds per run. build-library.mjs counts them for customNodes and writes them to the manifest entry. build-requirements.mjs counts them as the graph's classes. ManifestWorkflow type gains runtimeNodes. minimax-h3-flex-ref2va declares runtimeNodes ['VHS_LoadVideo'], so requirements.json now lists packs {ComfyUI-VideoHelperSuite: [VHS_LoadVideo]} and the GPU pre-flight asks for VideoHelperSuite. Only that entry was rebuilt (build-library.mjs minimax-h3-flex-ref2va, then build-requirements.mjs). The graph file is unchanged, so it stays validated: true.",
- "F6 (low, partly): the Quality control on oss-minimax-h3 gains ops (t2v/i2v/flf2v for all three values), so the chip is hidden on References and Talk runs, which always use Flex. CREDITS.md: a Pika H3 Flex attribution (Mellis, Inc., MiniMax H3 Community License, NOTICE note) is added to ATTRIBUTIONS in src/lib/licences.ts, and that one line, exactly as scripts/credits.mjs writes it, is added to CREDITS.md.",
- "F7 (low, confirmed): tests/e2e/pika-flex.mjs waits for the order line, the price and the refusals (waitText polls the body and the Generate button's label) instead of reading them at once. It also checks two new flows at all four sizes: the end frame plus clip refusal, and Lipsync Video + Voice on H3 being refused. Before the Quality check it removes the clip, since Quality is now hidden on references.",
- "Tests: tests/pika-flex.test.ts has 5 new tests: Lipsync re-sync refusal (and LatentSync still lipsyncs), end frame + clips/sound refusal, Quality chip ops, the Settings switch through previewGeneration for owner and account, and the VHS pack in requirements. Updated tests: open-minimax-h3 (control ops), open-engine (a control offered on some ops only is checked against those routes only), gpu-requirements (runtimeNodes count as graph classes)."
- ],
- "rejected": [
- "F6 remainder: no H3 Flex option was added to Fuobe Speak or Genjutsu Motion, and Assist is untouched. Each is a separate studio change with its own planner and tests, and both reach H3 through the catalog's avatar/ref2v routes already. Left for a later package.",
- "F6 remainder: Flex's 480p and its extra aspect buckets are not exposed. That needs h3Canvas and grid changes on every H3 graph, which overlaps the parallel nm10-h3-any-gpu package that owns H3 sizing.",
- "Full CREDITS.md regeneration: on the base, scripts/credits.mjs fails under Node 22 (a JSON import attribute is missing), and when forced it rewrites dozens of other packages' rows that are out of date on the base. Only the Pika line was added; the full regeneration is for the integrator."
- ],
- "checks": [
- "Worktree /home/user/wt/o-nm10-pika-flex on o/nm10-pika-flex. The branch held only this package's 3 commits on claude/fuobe-parity-4. The base was not merged in, as the coordinator asked. pnpm install --frozen-lockfile and next typegen were run.",
- "pnpm typecheck: exit 0. pnpm lint: exit 0 (one pre-existing warning, WAN_NEG_EN in library.spec.mjs). eslint on every changed file after the last edits: clean.",
- "One full run, FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: 311 files, 4969 passed, 10 failed. 6 of the failures are the known pre-existing ones from rules item 8: comfy-reuse ('Clean up voice demo' attribution), dop-originals (effect-acid), preset-featured, soul-runs (2) and split-soundtrack. preset-covers timed out under load and passes alone (11/11). The other 3 were mine and are now fixed: gpu-requirements (runtimeNodes), open-engine (Quality ops on ref2va) and open-minimax-h3 (control ops). A targeted rerun of these plus pika-flex, composer, cinema-refs and comfy-library-4 passed: 8 files, 210 tests (preset-covers' one failure here was again the load timeout), and open-engine passed 43/43 after a typing fix.",
- "tests/pika-flex.test.ts: 21/21.",
- "Browser: FUOBE_DEMO_MODE=on next dev on localhost:3317, then node tests/e2e/pika-flex.mjs at 1440 and 390, light and dark. Everything passed with no console errors and no sideways scroll. That covers the References tray, the Clip 1 / Voice 1 order line, Free, the 17 s voice refused, the end frame + clip refused, Quality listing Fast · Pika Flex, no tray on cloud H3, Cinema, Lipsync with H3, and Lipsync Video + Voice refused. The server was stopped with fuser -k and .next deleted.",
- "Pinned workflow rebuild: build-library.mjs minimax-h3-flex-ref2va reports custom: ComfyUI-VideoHelperSuite, and build-requirements.mjs reports 208 workflows, 205 files, 31 packs. The live CPU ComfyUI was only read (object_info). Nothing was installed or restarted.",
- "Committed cf74601b and pushed with git push -u origin o/nm10-pika-flex. git status is clean."
- ],
- "finalSummary": "Pika H3 Flex on MiniMax H3 is complete on the open engine. The four 6-step graphs are pinned and validated on the CPU ComfyUI. Quality offers 'Fast · Pika Flex (6 steps)' on words and frames. The References mode takes 9 images, 3 clips and 3 voice or music clips, with Pika's limits checked before upload and the names Image N, Clip N and Voice N turned into H3's tags. Cinema references and 'Talk from a voice clip' also work. The review's silent drops now produce plain refusals: a clip given to re-sync on H3, and an end frame beside references. The Settings → Models & licences switch for each adapter now stops the runs that load it. The library picker in the tray works. The GPU pre-flight asks for VideoHelperSuite for references. Open engine: everything above is built, unit- and browser-tested in demo mode, and the graphs are validated (POSTed with 0 node_errors). No GPU render has been done, so speed, quality and VRAM (recorded as 32 GB) are Pika's claims, and Pika itself did not verify an end-to-end ComfyUI render. Cloud engine: there is no Pika H3 Flex route. fal's MiniMax H3 LoRA endpoints take adapters but expose no steps, scheduler or sigmas, and Pika is not on fal or Replicate. The cloud keeps hosted MiniMax H3 under its own name, and the UI says Flex runs on your GPU only. No key is needed for the open engine. Under public sign-up: guests browse read-only. Accounts run Flex, References and Talk only on their own ComfyUI, with inputs going through the existing account checks (prep, prepClip, prepVoice in account-inputs). Accounts get plain-words refusals with no LoRA or Settings wording. The adapter switches stay the owner's. No new API routes were added.",
- "left": [
- "No GPU render of any Flex graph. VRAM is recorded as 32 GB; Pika published only H100 80 GB.",
- "CREDITS.md on the base is out of date beyond this package, and scripts/credits.mjs needs a JSON import attribute fix to run under Node 22. Only the Pika attribution line was added by hand, in the generator's format.",
- "Not built: Fuobe Speak and Genjutsu Motion H3 Flex options, Assist, and Flex's 480p and extra aspect buckets. Alternatives were recorded only, not built: Taobao PTD LoRAs, RefAsymOPD, FastH3 Omni.",
- "Mixed-sound reference clips leave gaps in the ref_video_audio numbering. This matches the node source but has not been render-tested.",
- "With a clip attached, Lipsync & avatars on H3 still shows the Video slot; the planner refuses with a clear message rather than hiding the slot.",
- "Expect a small merge with the parallel nm10-h3-any-gpu in oss-minimax-h3's Quality control (now with ops) and in comfy-variants.",
- "Pre-existing failures (rules item 8) are reported, not fixed: comfy-reuse, dop-originals, preset-featured, soul-runs, split-soundtrack. preset-covers is a load timeout and passes alone."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/nm10-pika-flex"
- ],
- "notMerged": [],
- "conflicts": "gpu/tools.ts rows, validation-state, manifest, model-pins unions; requirements regenerated",
- "checks": "batch of 6 (n7-11, o12 re-merge, pika-flex, keying, rtx-video, speech-edit): typecheck 0, lint 0, vitest 5612 passed, 8 failed (6 main known + blockout and moderation-hook load timeouts, 41/41 alone); requirements budget raised to 288/36 KB (a150159e); each merge checked by an independent verifier",
- "pushed": true,
- "head": "a150159e"
- }
-}
diff --git a/docs/handoff/reports/nm10-rtx-video.json b/docs/handoff/reports/nm10-rtx-video.json
deleted file mode 100644
index a0cc26a5..00000000
--- a/docs/handoff/reports/nm10-rtx-video.json
+++ /dev/null
@@ -1,114 +0,0 @@
-{
- "key": "nm10-rtx-video",
- "impl": {
- "branch": "o/nm10-rtx-video",
- "summary": "Comfy-Org's NVIDIA VFX Nodes 0.2.1 (pinned at 38d790d) now drive three new choices on the open engine. 'Quick · RTX' is RTX Video Super Resolution in Upscale → Video. 'RTX Frame Generation' (RTX 40 series or newer) is in FPS boost. 'RTX Video HDR' (HLG or HDR10/PQ) is in SDR to HDR. Each choice has its own hand-built ComfyUI graph and pre-flight board row. The GPU pre-flight reads the card's name, so the board, chips, guided fix and run check say 'Needs an NVIDIA RTX card' (or 'RTX 40 series or newer') on CPU, Apple, AMD, Intel and GTX devices. Nothing is picked automatically and today's defaults are unchanged. Upscale → Video shows Quick · RTX next to Restore · faithful and Regenerate · creative: first on an RTX card, switched off with the reason on a card that can't run it, and last when the card is unknown. The cloud has no RTX route because nobody hosts NVIDIA's SDK. Nothing was built before this package: no RTX graph, pack, model or readiness check existed at fdad177c. The brief was out of date in two places: the installer did not already know the platform (it installs CPU PyTorch; I added nvidia-smi detection), and the licence is stated (pack Apache-2.0, nvidia-vfx runtime proprietary under NVIDIA's Software License Agreement).",
- "built": [
- "Library: three hand-built graphs. upscale-video-rtx works in VHS meta-batch passes like upscale-video-esrgan-chunked, keeps the sound, scales by min(4, max(1, shortSide / the shorter edge)) worked out in the graph, then resizes to exactly shortSide. fps-rtx-framegen is interpolate-rife-fps with RTXVideoFrameGeneration in FrameInterpolate's place (m and every n-th frame, shot-change detection on, last frame held so N becomes N×m+1). sdr-to-hdr-rtx is RTXTrueHDR into CreateVideo 10-bit, with one colorSpace binding feeding both output_colorspace and color_space so the H.264 High 10 tags always match (bt2020 + arib-std-b67 or smpte2084). All three are in library.spec.mjs with packs, licence and notes, plus manifest, requirements.json and validation-state.json.",
- "New spec field gpu (nvidia-rtx / nvidia-rtx-40), carried through build-library.mjs into manifest.json and through build-requirements.mjs into requirements.json. New binding key rtxQuality. PACK_CLASSES and CUSTOM_NODE_REPOS entries. object_info.subset.json gains only the three RTX classes, as null.",
- "Node pack: ComfyUI_Nvidia_VFX_Nodes is in workflows/comfyui/packs.json (registry id comfyui_nvidia_rtx_nodes, requirementsTxt true). install-comfyui.sh clones it and installs nvidia-vfx==0.2.0.0 only when nvidia-smi names an RTX or GB10 card (RTX_VIDEO=1 forces it, RTX_VIDEO=0 skips it), and warns when PyTorch is not a CUDA 13 build. scripts/comfy/README.md has a new section on these graphs.",
- "Licences as information: a NODE_PACKS row for the pack (Apache-2.0) with a note on the NVIDIA runtime. The 'NVIDIA Software License Agreement' is recognised as a licence with conditions, so the workflows show under that class in Settings → Models & licences. The research table row in new-models-10.md is corrected.",
- "src/lib/gpu/rtx.ts (readCard, cardFits, offerOn, GPU_NEED_TEXT) reads RTX cards and their series from ComfyUI device names. It covers GeForce, RTX A-series, Ada and Blackwell pro cards, Quadro and TITAN RTX, and GB10; AMD, ROCm, Apple, Intel, CPU and GTX read as not RTX; data-centre names read as unknown and are never blocked.",
- "Readiness: workflowReadiness returns unsupported with the reason and gpuNeed. Badge flags 8 and 16 make the chip read 'RTX only' or 'RTX 40+'. stateLine, the header pill, the guided-fix title and body, and a separate board summary sentence all say the card is needed. FixPlan carries reason and gpuNeed. An RTX graph never reads 'Runs on any computer'. The run gate stops an RTX run on a card that can't run it, with a plain message.",
- "Catalog: src/lib/catalog/rtx-video.ts (ids, copy, rtxStanding, RTX_MISSING). Three open models: oss-rtx-video-upscale (Source control), oss-rtx-frame-generation (Quality control, fps targets and slow motion) and oss-rtx-video-hdr (HLG and PQ formats, peak 400-2000 nits). They come after each tool's own models, are open only, and studio defaults are unchanged.",
- "UI: FinishChoices adds Quick · RTX. It is first on a fitting card, last when the card is unknown, and switched off (aria-disabled) with 'Needs an NVIDIA RTX card' otherwise. Three choices sit in 3 columns on desktop, and on a phone the first takes a row of its own. A line under the picked choice says it runs only on NVIDIA RTX cards. FPS boost and SDR to HDR offer the RTX models through the model picker, whose taglines say RTX.",
- "Pre-flight board (/connect): three new rows ('Quick upscale · RTX', 'FPS boost · RTX', 'SDR to HDR · RTX'). Canvas: an Upscale node entry 'Quick upscale (RTX)', switched off on the cloud, with no cloud stand-in (GPU_ONLY_FIXED).",
- "Provider: RTX passes are sized by RTX's own scale, not ESRGAN's 4x. RTXVideoFrameGeneration is linked out when m is 1. A ComfyUI without the nodes gets plain words, one version for the owner and one for visitors."
- ],
- "tests": "New tests/rtx-video.test.ts, 21 tests, all passing. It checks each graph's RTX node inputs against the pack's define_schema at 38d790d; chunk sizes and scale (rtxScale, rtxOutputSize, framesPerPass, and the provider's framesPerBatch, shortSide and quality); frame counts ((N-1)M+1, and N×m+1 matching RIFE's fpsFrames); m/n and the link-out; that both HDR colour tags are always equal in HLG and PQ, and that EXR is refused; the GPU names; readiness on CPU, --cpu, AMD, GTX, Apple, H100 and RTX 3090 vs 4070; badge text and stateLine; rtxStanding; that models are open only and defaults unchanged; board rows; the Canvas entry and its missing cloud stand-in; licences; and the missing-nodes message. Added the three ids to the unvalidated list in tests/comfy-library-4.test.ts (the allowed edit). Live check on the CPU ComfyUI: the graphs with core stand-ins in place of the RTX nodes (ImageScaleBy, ImageSDRToHDR) ran end to end. 3 s 320x180 25 fps with sound became 1280x720, 75 frames in 5 passes, AAC kept; the HDR graph wrote H.264 High 10 yuv420p10le tagged bt2020/arib-std-b67 (HLG) and smpte2084 (PQ), sound kept. validate-workflows records missing_node_type for the three graphs, as expected. Browser check with tests/e2e/rtx-video.mjs (demo mode, port 3461, 1440 and 390 px, light and dark, stubbed GPU answers for unknown, RTX 4070 and AMD cards): all 104 checks passed, with no console or page errors, no hydration filter and no sideways scroll; .next deleted after. npx next typegen 0, pnpm typecheck 0, pnpm lint 0 (one existing warning, WAN_NEG_EN). Full vitest (--maxWorkers=2) exit 1: 8 failed out of 4982. Six are the known rule-8 failures: dop-originals, split-soundtrack, soul-runs ×2, comfy-reuse, preset-featured. The other two, picker-covers and preset-covers, are rule-12 timeouts and passed when rerun alone (36/36).",
- "left": [
- "Nothing has run on an NVIDIA RTX card. Validate on a ComfyUI with the pack and an RTX card: node scripts/comfy/validate-workflows.mjs upscale-video-rtx fps-rtx-framegen sdr-to-hdr-rtx, then a real run of each. The things to confirm are the DynamicCombo nested keys (resize_type.scale, generation_type.multiplier) taking a link, VRAM use, and speed.",
- "Needs on a GPU host: a CUDA 13 (cu130) PyTorch, which install-comfyui.sh does not install (it installs CPU wheels; it only warns), and NVIDIA driver 570.190+ / 580.82+ / 590.44+ on Linux. nvidia-vfx 0.2.0.0 ships wheels for Linux x86_64 and Windows only, so DGX Spark (Linux arm64) has no wheel even though the pack's README says Spark is supported.",
- "tests/comfy-library-4.test.ts: the unvalidated list now names upscale-video-rtx, fps-rtx-framegen and sdr-to-hdr-rtx (the only allowed edit).",
- "Not built: EXR and ProRes output for the RTX HDR path. EXR stays on video-sdr-to-hdr-exr, and the model refuses exr. The brief's 'encode HDR10 / ProRes' is covered as HDR10 = PQ in 10-bit H.264, the existing export path's colorSpace.",
- "Hosted runs (FUOBE_HOSTED_RUNS): RTX models go through the existing decidePlace and poolAllows unchanged, and video inputs usually keep them on the account's own GPU. The run gate stops them on an install card that isn't RTX. No pool-specific RTX rule and no hosted-runs test were added.",
- "'Fast preview tier' for n7-3 and archive-restore: the upscale-video-rtx graph and the oss-rtx-video-upscale model are ready to reuse, but nothing is wired into those packages.",
- "Owner decision still open: should Quick · RTX become the default on RTX hosts? The brief says to keep today's default unless the owner chooses, so SeedVR2 stays the default and RTX is only placed first."
- ],
- "docsNotes": "ARCHITECTURE: library 204 → 207 workflows and one node pack (ComfyUI_Nvidia_VFX_Nodes @38d790d, registry comfyui_nvidia_rtx_nodes, Apache-2.0, with the NVIDIA nvidia-vfx 0.2.0.0 runtime under the NVIDIA Software License Agreement). The graphs are upscale-video-rtx (upscale-video), fps-rtx-framegen (interpolate) and sdr-to-hdr-rtx (sdr-to-hdr). New spec, manifest and requirements field gpu (nvidia-rtx / nvidia-rtx-40), read by src/lib/gpu/rtx.ts and checked in workflowReadiness (state unsupported, gpuNeed, badge flags 8/16). New binding key rtxQuality. install-comfyui.sh RTX_VIDEO=auto|1|0. FEATURES and SELF-HOSTING (docs pass): Upscale → Video 'Quick · RTX', FPS boost 'RTX Frame Generation' (RTX 40+), SDR to HDR 'RTX Video HDR' (HLG or HDR10) run only on NVIDIA RTX cards with a CUDA 13 PyTorch; the pre-flight says 'Needs an NVIDIA RTX card' elsewhere; there is no cloud version. STATUS: the three graphs are not validated (they need an RTX card).",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "file": "src/server/hosted-run.ts:83 (decidePlace) / src/app/api/generations/route.ts:162",
- "summary": "Hosted runs (FUOBE_HOSTED_RUNS=1) never check the card for the RTX models. decidePlace puts a pool run on the install's own ComfyUI without asking whether that card is an NVIDIA RTX one, and the generations route skips gateGeneration for every pool run ('its plan was checked by decidePlace'). So the new gpuNeed stop never runs on that path. Take an account with no GPU online (or wish 'pool'), a policy that allows video uploads, and an install GPU that isn't RTX or lacks the pack: picking Quick · RTX / RTX Frame Generation / RTX Video HDR gets a quote and a hold, then fails inside ComfyUI with missing_node_type or a CUDA error. ownGpu() is unset on the pool, so promptRefusal returns RTX_MISSING.owner, and that text names scripts/comfy/install-comfyui.sh and RTX_VIDEO=1 to an account (the brief bans file names and jargon in visitor copy). The brief asked for these models to plan and price on the pool path with a test in the style of tests/hosted-runs.test.ts. None was added (the implementer says so in 'left'). Hosted runs are off by default, hence medium.",
- "verified": "Traced: route.ts:162 `if (viewer.kind !== \"guest\" && !onPool)` wraps the only gateGeneration call; hosted-run.ts decidePlace and poolAllows have no card/gpu check; comfyui.ts promptRefusal picks RTX_MISSING.owner when !ownGpu()."
- },
- {
- "severity": "low",
- "file": "src/components/gpu/guided-fix.tsx:275",
- "summary": "The guided-fix body for an RTX tool puts the raw device name into visitor copy. Both callers fill plan.gpu with deviceLabel(dev.name): gate.ts:90 always, and readiness-service.ts:135 whenever vram_total is set, which ComfyUI also sets to system RAM on a CPU. ComfyUI names the CPU device 'cpu' and Apple's 'mps', so a CPU or Mac visitor reads '…which only NVIDIA RTX cards have, and your cpu isn't one' / 'your mps isn't one'. The older GpuState copy avoids this because it only names the card when haveGb is set, and haveGb is undefined on a CPU. The closing sentence 'The other choices in this tool work on your GPU' is also not true on a CPU, or where the other choices need a bigger GPU. Fix: drop the name unless the device type is cuda/xpu (or use summary.gpu, which is only set for real GPUs), and soften or drop the last sentence.",
- "verified": "Read deviceLabel (the strip regex needs whitespace after 'cpu'/'mps', so a bare 'cpu' comes back unchanged), gate.ts:90, readiness-service.ts:134-135 and guided-fix.tsx:159-166."
- },
- {
- "severity": "low",
- "file": "src/lib/gpu/rtx.ts:33 / scripts/comfy/install-comfyui.sh:134",
- "summary": "GB10 (DGX Spark) reads as a fitting RTX card (series 50), so readiness says it fits and Quick · RTX goes first, and the installer auto-installs the pack there. But pypi.nvidia.com has no linux aarch64 wheel of nvidia-vfx 0.2.0.0, only manylinux x86_64, win_amd64 and win_arm64. On a Spark the install fails, and the tool shows as one setup step away when it can never run. The pack's README does claim 'RTX Spark is supported', and the implementer flagged the gap in 'left'. Until a wheel exists, readCard should treat GB10 as unknown (never first, never blocked) rather than as fitting.",
- "verified": "Listed https://pypi.nvidia.com/nvidia-vfx/: there are 0.2.0.0 wheels for cp310, cp311 and cp312-abi3 manylinux x86_64 and win_amd64, plus win_arm64 for cp311 and cp312, and nothing for aarch64."
- },
- {
- "severity": "low",
- "file": "src/components/studio/finish-choices.tsx:90 + src/components/studio/radio-keys.ts",
- "summary": "Keyboard use of the switched-off choice. radioKeys walks '[role=\"radio\"]:not([disabled])', but Quick · RTX is only aria-disabled, so on a card that can't run it the arrow keys land on it and 'click' it: nothing is picked and focus rests on a choice that is switched off. Not a trap (the next arrow moves on), and ARIA allows focusable disabled radios. Skipping aria-disabled in radioKeys would match how a mouse user experiences it.",
- "verified": "Read radio-keys.ts and finish-choices.tsx."
- }
- ],
- "checks": [
- "Read the review prompt and main-rules. Branch o/nm10-rtx-video at 7b0c3573, worktree clean before and after. I diffed fdad177c...HEAD over 37 files and reviewed the changes with the code around them.",
- "Primary sources: I cloned Comfy-Org/ComfyUI_Nvidia_VFX_Nodes. HEAD = 38d790d (the pin), pyproject name comfyui_nvidia_rtx_nodes 0.2.1, LICENSE Apache-2.0, requirements.txt 'nvidia-vfx>=0.2'. The README confirms an RTX GPU, cu130+ PyTorch, no CPU or non-NVIDIA path, and frame generation on the 40 series and later only. In __init__.py, define_schema matches the graphs and the test SCHEMA: resize_type DynamicCombo with scale 1-4, quality default ULTRA, the frame-generation generation_type/multiplier 2-16 and mode LOW/MEDIUM/HIGH, and RTXTrueHDR luminance 400-2000 with output_colorspace HDR/HDR PQ.",
- "nvidia-vfx: on PyPI, 0.2.0.0 is a wheel-stub sdist (LicenseRef-NvidiaProprietary, index_url pypi.nvidia.com), so the installer's plain `uv pip install nvidia-vfx==0.2.0.0` does resolve through the stub. Through range reads of the 443 MB wheel's zip directory I confirmed it ships NVIDIA-Software-License-Agreement-2025.05.05.pdf, product-specific-terms-for-nvidia-ai-products-2025.05.05.pdf and NVIDIA-Open-Model-License-Agreements-24-10-2025.pdf. The driver minimums 570.190+/580.82+/590.44+ (Linux) and 570.65 (Windows) match the package metadata. The licence data recorded in the spec, licences.ts NODE_PACKS and KNOWN, and new-models-10.md is accurate.",
- "Graphs: hand-built and workflows/ copies are the same (differences only in number formatting, 1.0 vs 1). Checked against object_info.subset.json: CreateVideo color_space takes HDR / HDR PQ with bit_depth 10, ComfyMathExpression outputs FLOAT, ImageFromBatch takes -1, and the VHS_VideoInfo outputs 5/8/9 are loaded fps/width/height. The colorSpace binding feeds both RTXTrueHDR.output_colorspace and CreateVideo.color_space. fps-rtx-framegen keeps interpolate-rife-fps's node ids, and the bypass now also finds RTXVideoFrameGeneration.",
- "Not auto-picked: the studio defaults (oss-seedvr2, oss-rife, oss-sdr-to-hdr) and PREFERRED are unchanged, and the RTX models come after each tool's own models. FinishChoices puts Quick · RTX first only when offerOn says the card fits. It is switched off with 'Needs an NVIDIA RTX card' when the chip has flag 8/16 or the name reads non-RTX, and goes last but stays enabled when the card is unknown. composer pickModel resets params to the new model's defaults, so the HDR peakNits minimum of 200 doesn't carry over to RTX's 400. On the Canvas the GPU_ONLY_FIXED entry is disabled on the cloud and has no counterpart.",
- "Pre-flight: workflowReadiness returns unsupported with gpuNeed on cpu/--cpu/mps/xpu/AMD/GTX. Unknown names such as data-centre cards are never blocked, which fits the SDK: Turing to Hopper with Tensor Cores. Chip, header pill, stateLine, board summary sentence and guided-fix title all use the 'Needs an NVIDIA RTX card' / 'RTX 40 series or newer' wording. The gate stops RTX runs even on the install key, with a plain message. There are 3 new STUDIO_ROWS and requirements.json carries gpu plus the pack's classes.",
- "Public sign-up: no new routes, pages or file-reading server paths. Hot files: none touched, apart from the allowed tests/comfy-library-4 unvalidated-list edit and the rebuilt validation-state.json. There are no Higgsfield, analytics or media files in the change.",
- "Full Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2): 6 failed / 4972 passed / 4 skipped of 4982, across 5 files. All 6 are the known rule-8 failures: comfy-reuse, dop-originals, preset-featured, soul-runs ×2, split-soundtrack. There were no rule-12 timeouts this run, and tests/rtx-video.test.ts passed.",
- "npx next typegen exit 0; pnpm typecheck exit 0. .next removed afterwards and git status is clean.",
- "The CPU ComfyUI at 127.0.0.1:8188 wasn't reachable during the review, so I checked the node inputs against workflows/comfyui/object_info.subset.json instead. I ran no browser check myself: the implementer's tests/e2e/rtx-video.mjs, which I read, covers 1440/390 px, light/dark and unknown/RTX/AMD cards. No packs were installed."
- ],
- "verdict": "approve with fixes: the work matches the brief, and the licences and node schemas check out against the primary sources. Nothing is auto-picked, and the pre-flight and UI say plainly that an NVIDIA RTX card is needed. Before FINISH, fix the hosted-run gap (the pool path skips the card check, and it can show the owner's missing-pack message to an account) or record it as a known limitation, and fix the 'your cpu isn't one' wording in the guided fix. The rest is low."
- },
- "fix": {
- "applied": [
- "Medium (hosted runs, confirmed): the pool path now checks the install's card before it plans an RTX model. New poolCardRefuses(modelId) in src/server/hosted-run.ts reads the install's last GPU check. It refuses Quick · RTX, RTX Frame Generation or RTX Video HDR when gpuFits says the card can't run it (CPU, Apple, AMD, Intel, GTX, or an RTX 20/30 card for frame generation) or when the check lists any RTX Video node class as missing. decidePlace refuses after poolAllows (403 not-offered) with the new HOSTED_WORDS.rtxCard line: 'This one needs an NVIDIA RTX card, and this studio's GPUs can't run it right now. Connect your own GPU in Settings, or pick another choice.' When the account has its own GPU and didn't ask for the pool, the run goes to its own GPU instead, where the existing gate applies. poolQuote returns null, so the price check never quotes it on the pool. Nothing reaches /v1/quote or /v1/reserve. A card the name doesn't identify (data-centre cards), or no check yet, is never refused (R11). RTX_CLASSES is exported from src/lib/catalog/rtx-video.ts.",
- "Owner copy never reaches an account: promptRefusal in src/server/providers/comfyui.ts now uses the visitor wording when ownGpu() or tenantAccount() is set, so hosted runs inside runOnPool are covered. This applies to RTX_MISSING and also to the same pattern in REGEN_COPY, which named install-comfyui.sh and OPEN_H3_REGEN to pool accounts.",
- "Low ('your cpu isn't one', confirmed): new cardLabel(device) in src/lib/gpu/readiness.ts gives a name only for cuda/xpu devices and never a bare cpu/mps/cuda:N. gate.ts and readiness-service.ts use it for the fix plan's gpu, which also fixes the old 'Your mps has N GB' in GpuState. The guided-fix closing sentence 'The other choices in this tool work on your GPU' is now 'Pick another choice in this tool for this clip.'",
- "Low (GB10, confirmed by the reviewer's pypi.nvidia.com listing): readCard reads GB10 as unknown (never put first, never blocked). install-comfyui.sh auto mode now matches only 'RTX' and skips machines that aren't x86_64, because nvidia-vfx 0.2.0.0 has no Linux arm64 wheel. RTX_VIDEO=1 still forces the install. The tests are updated to match.",
- "Low (radioKeys): the arrow keys now skip [aria-disabled=\"true\"] radios as well as [disabled] ones, so a switched-off Quick · RTX is no longer landed on and 'clicked'.",
- "Tests: tests/hosted-runs.test.ts has a new route-level test. The account uploads a clip under a billing policy that allows video. The install check is CPU, AMD, GTX 1080 Ti, or RTX 4090 without the nodes. In each case the RTX upscale gets 403 not-offered with plain words, no script or switch names, no /v1/quote or /v1/reserve call, and the ?preview=1 price check has no place 'pool'. Frame generation is refused on an RTX 3090 and allowed on an RTX 4070, and an H100 is never refused. I confirmed the test fails without the fix (409, a hold was attempted). tests/rtx-video.test.ts gains: the missing-nodes message inside runAsTenant is the visitor's; cardLabel never names cpu/mps; the guided-fix sentence is gone; the radioKeys selector; and the GB10 and installer expectations.",
- "Commit dba5be1a 'Hosted runs: RTX Video models are refused in plain words on a studio GPU that can't run them' pushed to origin/o/nm10-rtx-video (7b0c3573..dba5be1a)."
- ],
- "rejected": [],
- "checks": [
- "Worktree /home/user/wt/o-nm10-rtx-video on o/nm10-rtx-video, clean at 7b0c3573 to start. The only commits beyond claude/fuobe-parity-4 were this package's own. The base has moved past the branch (it is no longer an ancestor), but as instructed I did not merge it; that is for FINISH.",
- "Confirmed each finding in code before fixing. route.ts:162 skips gateGeneration on the pool. decidePlace and poolAllows had no card check. promptRefusal picked the owner copy whenever ownGpu() was unset, and on the pool the submit and poll paths run inside runOnPool, where tenantAccount() is set but ownGpu() is not. deviceLabel('cpu') returns 'cpu'.",
- "npx next typegen exit 0; pnpm typecheck exit 0; pnpm lint exit 0 (one existing warning, WAN_NEG_EN); bash -n install-comfyui.sh ok.",
- "Targeted: tests/hosted-runs.test.ts 9/9, tests/rtx-video.test.ts 22/22. gpu-api, regenerate-2k, qwen21-fast, public-signup, billing-hook* and gpu-*: 8 files, 186/186.",
- "Full FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2 (one run): 7 failed / 4973 passed / 4 skipped of 4984. Six are the known rule-8 failures: comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack. The seventh, preset-covers, is a rule-12 timeout and passed alone (11/11, exit 0).",
- "No browser check this stage, because the UI changes are copy and a keyboard selector. No .next is left behind, git status is clean, and no ComfyUI packs were installed."
- ],
- "finalSummary": "nm10-rtx-video is ready for FINISH. Open engine (ComfyUI): Quick · RTX (Upscale → Video), RTX Frame Generation (FPS boost, RTX 40+) and RTX Video HDR (HLG or HDR10/PQ) are built as three hand-built graphs with the Comfy-Org NVIDIA VFX pack pinned at 38d790d (Apache-2.0; the nvidia-vfx runtime is under NVIDIA's Software License Agreement, shown as information). Graph inputs are checked against the pack's schema, and core stand-ins ran on the CPU ComfyUI. Nothing has run on a real RTX card: that needs an NVIDIA RTX GPU, a CUDA 13 PyTorch and a recent driver. The pre-flight, chips, guided fix and run gate say 'Needs an NVIDIA RTX card' (or 'RTX 40 series or newer') on CPU, Apple, AMD, Intel and GTX devices, and never name a bare cpu or mps device. Nothing is auto-picked and today's defaults are unchanged. GB10 / DGX Spark now reads as unknown and the installer skips it, since there is no arm64 runtime. Cloud engine: no route, because nobody hosts NVIDIA's SDK; the Canvas entry is switched off on the cloud. No key is needed. Public sign-up: guests browse as before. Accounts run these on their own GPU with the existing gate. With hosted runs on (FUOBE_HOSTED_RUNS=1), an account's RTX run on the install's GPUs is refused in plain words before any quote or hold when the install's card can't run it or lacks the nodes. Where it does run there, a missing-nodes failure shows the visitor's words, never the owner's script or switch names.",
- "left": [
- "Validate on an RTX card: node scripts/comfy/validate-workflows.mjs upscale-video-rtx fps-rtx-framegen sdr-to-hdr-rtx, then a real run of each (DynamicCombo nested keys taking a link, VRAM, speed). Needs a CUDA 13 PyTorch (the installer only warns) and driver 570.190+/580.82+/590.44+ on Linux.",
- "tests/comfy-library-4.test.ts: the unvalidated list names upscale-video-rtx, fps-rtx-framegen and sdr-to-hdr-rtx (the only allowed edit).",
- "DGX Spark: when NVIDIA ships a Linux arm64 nvidia-vfx wheel, make GB10 read as fitting again (rtx.ts) and drop the installer's x86_64 rule.",
- "The pool's card check is only as fresh as the install's last GPU check; an install with no check yet is not refused (the run's own missing-nodes answer, in visitor words, covers it).",
- "Not changed: the generic missing-pack message ('…node pack on your ComfyUI (see scripts/comfy/README.md)') that accounts can still get for other packs predates this package. Worth a visitor-wording pass in its own change.",
- "Not built: EXR/ProRes for the RTX HDR path (EXR stays on video-sdr-to-hdr-exr); fast preview tier wiring for n7-3 and archive-restore (graph and model ready to reuse).",
- "Owner decision still open: should Quick · RTX be the default on RTX hosts (SeedVR2 stays the default for now)?",
- "Base claude/fuobe-parity-4 has moved ahead of the branch; merge it at FINISH."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/nm10-rtx-video"
- ],
- "notMerged": [],
- "conflicts": "build-library keys, canvas imports, licences regex, gpu/tools imports, hosted-run (poolAllowsRun then poolCardRefuses), comfyui provider imports, packs, manifest; requirements regenerated",
- "checks": "batch of 6 (n7-11, o12 re-merge, pika-flex, keying, rtx-video, speech-edit): typecheck 0, lint 0, vitest 5612 passed, 8 failed (6 main known + blockout and moderation-hook load timeouts, 41/41 alone); requirements budget raised to 288/36 KB (a150159e); each merge checked by an independent verifier",
- "pushed": true,
- "head": "a150159e"
- }
-}
diff --git a/docs/handoff/reports/nm10-speech-edit.json b/docs/handoff/reports/nm10-speech-edit.json
deleted file mode 100644
index 6f421758..00000000
--- a/docs/handoff/reports/nm10-speech-edit.json
+++ /dev/null
@@ -1,150 +0,0 @@
-{
- "key": "nm10-speech-edit",
- "impl": {
- "branch": "o/nm10-speech-edit",
- "summary": "Audio → Edit speech with Tencent AuK, on the open engine only. Edit a line of the transcript and only the smallest changed span of words is re-spoken. Each change gets its own window, cut at silences, with at least 1 s of untouched speech on each side and kept inside AuK's 30 s budget (source plus output). The window is crossfaded back with no clicks. Pitch, pace, volume, emotion, whisper and normal voice, Clean up, and Keep only this speaker work on ticked lines the same way. On a video, the new sound goes back on with the picture stream-copied, and the page warns and offers Lipsync. Also added: Fix this line in the Captions editor, an Edit speech item in the ⋯ menu of audio and video results, the Assist/MCP tool edit_speech, a row on the GPU pre-flight board, the ComfyUI-AuK pack pinned with an MIT licence row, and a second graph, speech-tts-auk, for AuK text to speech. Nothing from this plan existed in the base; everything was built new. Pushed at a66b9538. Commits are signed.",
- "built": [
- "workflows: hand-built speech-edit-auk (core TrimAudioDuration/AudioMerge/AudioConcat/SplitAudioChannels/EmptyAudio + AuKModelLoader/AuKGenerateEdit; manifest expand 'speech' rebuilds N windows in one prompt) and speech-tts-auk (zero-shot clone, or instruct TTS from params.voiceDescription with the loader removed); library.spec entries, manifest, requirements.json, validation-state (both validated:false, missing_node_type); object_info.subset.json gains AuKModelLoader/AuKGenerateEdit schemas written from nodes.py at the pinned commit (live-server churn reverted); build-library SELF_DOWNLOADING += AuKModelLoader",
- "workflows/comfyui/packs.json ComfyUI-AuK (Tencent-Hunyuan/AuK @ 0d40366b, subdir comfyui/ComfyUI-AuK); install-comfyui.sh opt-in AUK=1 block (clone beside custom_nodes, pip install -e .[comfyui], symlink the node folder) with AUK_WEIGHTS=1 hf download of AuK-Flash @575b92f0 and Qwen2.5-Omni-3B @f75b40e3, plus AUK_BASE=1 for AuK @790742b7",
- "src/lib/speech-edit.ts (pure): words timed from transcript lines, word-level LCS diff that ignores case and punctuation, Cookbook instructions (Replace/Add after/before/Remove, an ambiguous phrase widened until it is unique), windows (silence cuts → word boundaries → exact times, ≥1 s context, 30 s budget with a 0.5 s margin, neighbouring windows merged), effect windows split at silences, stitchPlan/editedLength/mapTime, TTS instruction and length, planSpeechEdit (AuK step + oss-mux step for video), engine refusals, Prompt Enhancer note",
- "src/lib/av/speech-edit-graph.ts: the window expander; the recording and each edit are brought to one sample rate first (AuK outputs 24 kHz); each seam is a + (b−a)×fade-in, where the fade-in curve has a flat tail that AudioMerge trims off, so no click from the resampler's edges; device/dtype for AuK (cuda:0 bf16, cpu fp32, Apple GPU refused); speechFadeWav",
- "catalog: new op 'speech-edit' (types, labels, output kind, plan.ts input rule and windows check), ModelDef oss-auk (speech-edit + tts routes), comfy.ts expand 'speech'; provider (comfyui.ts) wiring for windows, fade upload, TTS instruction and length, device",
- "server: /api/audio-tools tool 'speech-edit' (zod body, header-read length, Paid APIs only refusal, readable error messages); Assist/MCP edit_speech (studio-tools.ts, plus mentions in agent.ts and mcp.ts)",
- "UI: src/components/audio-tools/speech-edit-tool.tsx (Audio → Edit speech: upload/record/Library pick, Transcribe with Qwen3-ASR, Words / How it sounds, Fast/Best quality, price before running, Original/Edited A/B player, the video's new sound plus a Lipsync link, cloud-engine panel, Prompt Enhancer, language and consent lines); hubs mode edit-speech; CueEditor onFixLine plus Captions 'Fix this line' (handoff via src/lib/speech-edit-handoff.ts); ⋯ menu 'edit-speech' (hidden in Paid APIs only and on music/sfx); GPU pre-flight row /audio/edit-speech; licences NODE_PACKS ComfyUI-AuK MIT"
- ],
- "tests": "New: tests/speech-edit.test.ts (19: diff, word boundaries, instructions, windows at the start and end, 30 s cap, silence cuts, several edits and merges, effects, stitch and crossfade timing, run plans), tests/speech-edit-comfy.test.ts (7: both graphs checked against AuK's node list from nodes.py, pack pins, expander links and lengths, fade curve, provider binding for edit and TTS), tests/speech-edit-server.test.ts (8: /api/audio-tools demo run and preview, errors, cloud and Paid APIs only refusals, video mux, public sign-up (account price check only of its own file, not a demo; run gets own-gpu-tool through the proxy), MCP tools/list schema, estimate_job and run, ⋯ menu, licence, pre-flight row). Updated: tests/assist-context.test.ts (edit_speech samples; its cloud-only mode expects the refusal), tests/comfy-library-4.test.ts (only the two new unvalidated ids added to its list). Targeted runs passed: assist-context, assist-studio-routes, catalog, licences, mcp, public-signup(-tools), record-pages, voice-design-comfy, clean-dialogue, comfy-library-4/-notes, gpu-requirements. tsc --noEmit clean; it needs NODE_OPTIONS=--max-old-space-size=6144 here, the default heap runs out. eslint clean on the touched files. Live CPU ComfyUI check: the expanded stitch graph ran on the core nodes, with AuK replaced by a +6 dB volume change, at 16 kHz and 48 kHz sources. Output was 10.000 s, the edited spans landed at the right times, and there were no clicks: the largest sample step matched the sine's own. Browser: tests/e2e/speech-edit.mjs passed every check at 1440 and 390 px, light and dark, in demo mode: transcribe, edit, price, run, A/B, effect, cloud panel, Captions Fix this line opening Edit speech with line 2 focused, no sideways scroll, no console errors. One hydration mismatch it first reported was the script taking a screenshot before hydration (Playwright hides the caret on inputs); the script now waits for hydration. Dev server stopped and .next deleted. The one full Vitest run (--maxWorkers=2) started at 15:5x and had not finished when this report was due, so I have no full-suite result. Full Vitest: not finished within the stage; it runs in the finish stage.",
- "left": [
- "Untested on a GPU: no real AuK run, and its weights (~19 GB) were not downloaded. The graphs are checked against a node list written from nodes.py; ComfyUI-AuK was not installed on the validation server.",
- "Not built (brief surfaces): 'Fix this line' in Transcribe studio results, 'Re-voice this line' in Translate & dub review, Faceless narration lines, the Canvas audio node. Edit speech is reachable from the Audio tab, the ⋯ menu, Captions and Assist/MCP. AuK TTS (speech-tts-auk) is a catalog route only; no picker exposes it.",
- "model-pins.json not used: AuK reads its files by path inside the AuK checkout's ckpts/, not from a ComfyUI models folder, so the pre-flight could never see them. Revisions and sizes are in the entries' first-run text, install-comfyui.sh and library.spec.",
- "Hosted runs (FUOBE_HOSTED_RUNS) pricing for oss-auk is not specially tested; Edit speech runs through /api/audio-tools, which accounts reach as own-gpu-tool, as main's other audio tools do.",
- "Word times come from transcript lines (time spread by character length inside a line). The Qwen3-ASR forced-aligner word times are not read yet, so cuts fall at the pauses between lines.",
- "tests/comfy-library-4.test.ts: only the allowed edit, the two unvalidated ids added (speech-edit-auk, speech-tts-auk)."
- ],
- "docsNotes": "STATUS/ARCHITECTURE not edited. For the docs pass: (1) Audio → Edit speech (/audio/edit-speech), open engine only. AuK is MIT, but it needs the Qwen2.5-Omni-3B encoder, which is under the Qwen Research License (NON-COMMERCIAL), so the model reads as non-commercial in Models & licences. (2) Brief corrections from primary sources: the AuK README publishes VRAM (A800, bf16: ~25 GiB peak, ~17 GiB with the loader's cpu_offload), and the brief's 'automatic offload not supported' needs that nuance (cpu_offload is opt-in); the 30 s limit is source + output per call, so a same-length effect takes at most ~14.7 s of source; AuK outputs 24 kHz mono; Qwen2.5-Omni-3B is 11.97 GB; languages are English and Chinese (arXiv 2609.08936: a bilingual corpus); the comfyui folder imports the auk package, so the whole repo must be installed with pip install -e .[comfyui]. Pinned commit 0d40366b (2026-10-27). (3) The brief's line numbers did not apply; the code was found by name. (4) The base had no voice-consent gate (voice design/clone carry only a 'Get consent for cloned voices' note), so Edit speech shows a plain consent line rather than a gate. (5) The Prompt Enhancer is always off: Fuobe writes the instruction and generation_seconds, and the UI says no language model sees the words.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "major",
- "title": "On a video, any edit that changes length puts all later speech out of sync with the picture",
- "where": "src/lib/speech-edit.ts planTextWindows (seconds = old length + delta), planEffectWindows (pace), planSpeechEdit (video branch: oss-mux video-mux-audio-replace)",
- "detail": "The edited soundtrack is muxed onto the stream-copied picture as it is. planSpeechEdit returns length 11.913 s for a 9 s clip after 'on Tuesday morning.' becomes 'on a very sunny Wednesday morning in late October.', and 4.6 s for Pace 2x over the whole 9 s clip (checked with a probe test). Every word after the edit then drifts by the difference, and with pace the second half of the clip is silent. The only video warning is that lips won't match the changed words, and the UI never shows the new length. Fix: for kind 'video', keep each window's generation_seconds equal to its old length (AuK re-times the words to fit it), or refuse or clearly warn about length-changing edits and Pace on a video.",
- "verified": "probe test calling planSpeechEdit (removed afterwards); read video-mux-audio-replace.json (LoadVideo + LoadAudio + ConcatenateVideo + SaveVideo, nothing re-times the audio)"
- },
- {
- "severity": "major",
- "title": "Seams can click on loud recordings: ComfyUI's AudioMerge rescales any result that peaks above 1.0",
- "where": "src/lib/av/speech-edit-graph.ts expandSpeechEditWorkflow (seam = a + (b - a) x fade-in, built from AudioMerge subtract, multiply and add)",
- "detail": "Core AudioMerge (comfy_extras/nodes_audio.py, the execute method) ends with `if max_val > 1.0: waveform = waveform / max_val`. The seam's diff b - a is the original against AuK's version of the same moment, and the two are not phase-aligned, so it easily goes past 1.0 on speech mastered near 0 dBFS. Example: a = 0.8 and b = -0.5 give a diff of -1.3. The whole diff piece is then divided by its peak, so the seam ends at a + (b - a)/k instead of b, and the next piece (the edit's middle) starts at b: a step, heard as a click. The final add can also be normalised on its own. The implementer's no-click check used a quiet sine with a +6 dB stand-in for AuK, which doesn't reach this. Fix: scale both sides down before the seam math and back up after (e.g. AudioAdjustVolume -12 dB, then +12 dB), or crossfade without the diff (a x fade-out + b x fade-in with both curves written), and add a loud-signal case to the CPU check.",
- "verified": "read /home/user/ComfyUI/comfy_extras/nodes_audio.py AudioMerge.execute"
- },
- {
- "severity": "minor",
- "title": "Merging two nearby changes puts the old words' punctuation into AuK's new text",
- "where": "src/lib/speech-edit.ts mergeChanges (`between` uses the old words with their punctuation)",
- "detail": "'on Tuesday morning.' → 'on a very sunny Wednesday morning in late October.' produces the instruction \"Replace 'Tuesday morning.' with 'a very sunny Wednesday morning. in late October.'\". The stray full stop in the middle asks AuK for a sentence break there. Fix: take the words between the two changes from the edited text, or strip the old words' trailing punctuation when merging.",
- "verified": "probe test"
- },
- {
- "severity": "minor",
- "title": "AuK text to speech appears in Audio → Speech's open-engine model picker, though the report says no picker shows it",
- "where": "src/lib/catalog/models.ts oss-auk routes (tts), AUDIO_STUDIO ops ['tts']",
- "detail": "modelsFor({kind:'audio', ops:['tts'], engine:'open'}) returns oss-chatterbox, oss-indextts2, oss-qwen3-tts, oss-voxcpm2, oss-auk. A run works (clone, or a neutral narrator without a sample, since the composer sends no voiceDescription for this model). But the picker doesn't say it takes only English and Chinese, and the Audio Speech pre-flight row doesn't list speech-tts-auk. Either declare it or keep it out of the picker. Smaller issue: ttsLength says 'use one under 20 seconds' but only refuses samples over about 28.5 s.",
- "verified": "probe test"
- },
- {
- "severity": "minor",
- "title": "Visitor-facing copy uses jargon (rule 5)",
- "where": "src/components/audio-tools/speech-edit-tool.tsx (quality hint 'AuK-Flash, 4 steps' / 'Full AuK, 32 steps'); src/lib/speech-edit.ts planSpeechEdit notes ('Fast uses AuK-Flash (4 steps)')",
- "detail": "Sampling step counts are technical wording that guests and accounts see. Say 'Fast' / 'Best: slower, a little closer to the voice' instead.",
- "verified": "read the page and its screenshots at 1440 and 390 px"
- },
- {
- "severity": "nit",
- "title": "AuK instructions differ slightly from the Cookbook templates",
- "where": "src/lib/speech-edit.ts effectInstruction",
- "detail": "The Cookbook (docs/COOKBOOK.md at 0d40366b) writes 'Adjust the speech speed to {0.5/0.75/1.25/1.5/2.0}x.'; Fuobe sends '2x'. It writes 'by {1/2/3} semitones'; Fuobe sends '1 semitone'. Following the templates exactly is safer.",
- "verified": "fetched COOKBOOK.md at the pinned commit"
- },
- {
- "severity": "nit",
- "title": "Models & licences links the Qwen Research License to Qwen-Image-2.1's LICENSE",
- "where": "src/lib/licences.ts KNOWN (base map) applied to the speech-edit-auk / speech-tts-auk licence text",
- "detail": "licenceInfo gives class non-commercial (correct: Qwen2.5-Omni-3B @f75b40e3 is license: other / qwen-research) but links to huggingface.co/Qwen/Qwen-Image-2.1/blob/main/LICENSE. This comes from the base's regex map; the right link is Qwen/Qwen2.5-Omni-3B's LICENSE.",
- "verified": "probe test plus the HF API"
- },
- {
- "severity": "nit",
- "title": "The pre-flight board can show Edit speech as Ready without AuK's weights (acknowledged in 'left')",
- "where": "workflows/comfyui/requirements.json speech-edit-auk (files: [])",
- "detail": "The weights live in the AuK checkout's ckpts/, which the pre-flight can't see, so it checks only the pack's nodes. The first-run text says what to download. Acceptable, but worth a docs note.",
- "verified": "rebuilt requirements.json (deterministic, no diff)"
- }
- ],
- "checks": {
- "hotFiles": "src/lib/av/clean-voice.ts identical to claude/fuobe-parity-4 (git diff --quiet). No changes to public/previews, preset-*.generated, src/components/live, api/admin, src/server/db.ts, .github, deploy or docs/deploy.md. tests/comfy-library-4.test.ts gets only the allowed addition of the two unvalidated ids. validation-state.json entries are written by the build.",
- "migrations": "src/server/db.ts unchanged, so no migrations (rule 11 holds)",
- "cloud": "No cloud route for oss-auk and no substitute model. The cloud engine and Paid APIs only refuse with 'runs on your GPU (open source)'. The ⋯ menu item is hidden in Paid APIs only; Captions' Fix this line is hidden in Paid APIs only. samAudioCloud is still false in docs/handoff/owner-decisions.json and this package doesn't touch SAM Audio. No Higgsfield API use, Higgsfield media or LoRA files.",
- "publicSignup": "/api/audio-tools with ?preview=1 is already in PREVIEWS. The run answers own-gpu-tool at the proxy for accounts. A price check reads only the asker's own file: the owner's file answers 'That recording is gone'. An account is priced for its own GPU, never a demo (tests/speech-edit-server.test.ts; the test sits there rather than in tests/public-signup-tools.test.ts). No new route; the JSON body is well under the proxy limit. Edit speech's own run (planSpeechEdit) makes its job through createPipeline/createGenerations, so it carries no inputs of its own past account-inputs.",
- "consent": "The base voice tools have no consent gate (consent gates exist only for likeness and Soul ID). Edit speech shows a plain consent line, which matches the base.",
- "licences": "ComfyUI-AuK is in NODE_PACKS as MIT at the pin, and both workflows carry licence text that classifies as non-commercial because of the Qwen2.5-Omni-3B encoder. Re-checked at primary sources: the AuK LICENSE at 0d40366b is MIT for code and weights. tencent/AuK @790742b7 (auk_base 6.12 GB, vae 0.64 GB, config.yaml) and AuK-Flash @575b92f0 (auk_flash 6.12 GB) are licensed MIT. Qwen2.5-Omni-3B @f75b40e3 is qwen-research; its 3 shards total 11.97 GB.",
- "comfyBindings": "The hand-built graphs match nodes.py at 0d40366b: loader inputs checkpoint_path, config_path, qwen_path, device, dtype, cpu_offload; edit-node inputs engine, instruction, generation_seconds, use_prompt_enhancer, seed, input_audio, nfe_steps, cfg_strength, sway_sampling_coef. Flash uses 4 steps, CFG 0, sway -1, as the node requires. The config and VAE sit beside each checkpoint in the HF repos. The 30 s budget for source plus output is respected (window budget (29.5 - delta)/2). requirements.json rebuilds with no diff.",
- "typecheck": "npx next typegen, then tsc --noEmit with NODE_OPTIONS=--max-old-space-size=6144: exit 0",
- "lint": "eslint on the changed files: 0 errors, 1 warning (WAN_NEG_EN unused in library.spec.mjs, from the base)",
- "targetedTests": "speech-edit, speech-edit-comfy, speech-edit-server, public-signup, public-signup-tools, comfy-library-4, assist-context, licences, gpu-requirements, eval-harness, picker-covers, preset-covers run together: 12 files, 280 tests, all passed",
- "fullVitest": "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 1, 8 files and 9 tests failed out of 326 files and 5204 tests. Six are rule-8 known failures: split-soundtrack, dop-originals, soul-runs (2), comfy-reuse, preset-featured. picker-covers and preset-covers are rule-8 load timeouts. eval-harness (the Genjutsu studio route) failed under load, so it is reported here as a load timeout. All three pass when run alone. No new failures.",
- "browser": "tests/e2e/speech-edit.mjs on next dev with FUOBE_DEMO_MODE=on at http://localhost:3417: every check passed at 1440 and 390 px, light and dark, with no console or page errors. It covered transcribe, edit, price, run and the A/B player, an effect, the cloud panel, and Captions' Fix this line opening line 2. Screenshots looked right. The dev server was stopped and .next deleted.",
- "worktree": "Read-only: two temporary probe tests were created in tests/ and deleted. git status is clean at a66b9538."
- },
- "verdict": "changes requested: fix the two major issues (a video's sound drifting out of sync after a length-changing edit or Pace, and seam clicks from AudioMerge's peak normalisation on loud audio), then the punctuation in merged changes. Everything else is minor. Hot files, the public sign-up rules, the open-engine-only rule, licences as data, migrations and samAudioCloud are all fine."
- },
- "fix": {
- "applied": [
- "MAJOR, video sound drift (confirmed with planSpeechEdit: a 9 s clip came out at 11.9 s after a longer edit, and at 4.6 s with Pace 2x): on a video, every window now keeps its old length. PlanInput.keepLength is set by speechWindowsFor when kind is 'video', delta is 0, and AuK fits the new words into the same time. Pace on a video is refused with PACE_ON_VIDEO_PROBLEM. The page hides Pace for a video and resets a picked Pace when a video is loaded, the plan notes say each change keeps its length, and the Assist/MCP edit_speech descriptions say so. Tests: a longer edit and a removal on a video both stay 9 s, audio still lengthens, Pace on a video throws, Volume on a video and Pace on audio still run.",
- "MAJOR, seam clicks on loud audio (confirmed on the live CPU ComfyUI): expandSpeechEditWorkflow now runs all the stitching HEADROOM_DB (12 dB) lower with core AudioAdjustVolume (src_low -12). Each window goes to AuK brought back to its own level (w{n}_in +12), AuK's output goes down again (w{n}_low -12), and the whole result comes up once before the save (out +12), so the net gain is 0 dB. Loud-signal CPU check: a 0.97-peak signal at 24 kHz and 48 kHz, with a polarity-flipped stand-in for AuK (the worst case for b minus a), two windows. Old graph: max sample step 0.50 against the signal's own 0.055, max error 0.86. New graph: max step 0.0547/0.0274, equal to the signal's own, max error 0.003 (the 8 kHz fade curve's resampling), length 8.000 s, off-seam error 0. Tests check the gain pairs, the AuK input and output levels, the final gain before the save, and that every expanded node exists in object_info.subset.json.",
- "MINOR, merged changes carried old punctuation (confirmed): diffWords now records `at` (where the new words start in the edited text), and mergeChanges takes the words between two changes from the edited text (PlanInput.next). The example now gives \"Replace 'Tuesday morning.' with 'a very sunny Wednesday morning in late October.'.\" Tested.",
- "MINOR, AuK text to speech in the Voice picker (confirmed): kept in the picker, as it is a working open route, and its tagline now says it speaks English and Chinese. Checked that it is already on the pre-flight board as one of Voice's other open models (studioOthers lists speech-tts-auk), and added a test for that. ttsLength now refuses voice samples over AUK_TTS_MAX_SAMPLE (20 s), which matches its message. Tested.",
- "MINOR, jargon in visitor copy (confirmed): the quality labels are now 'Fast' and 'Best' with plain hints (QUALITY_HINTS: 'The quickest take, in the same voice' / 'Slower, a little closer to the voice'), and the plan note no longer names AuK-Flash or step counts. A test checks the notes have no 'Flash' or 'steps'.",
- "NIT, Cookbook wording (confirmed against docs/COOKBOOK.md at 0d40366b): pitch is always 'by N semitones', and pace is written as 0.5/0.75/1.25/1.5/2.0x. Tested.",
- "NIT, Qwen Research License link (confirmed with the HF API: Qwen/Qwen2.5-Omni-3B has license_name qwen-research and its own LICENSE): a KNOWN entry placed before the general one points AuK's encoder text to huggingface.co/Qwen/Qwen2.5-Omni-3B/blob/main/LICENSE. Other Qwen Research texts keep their link. Tested."
- ],
- "rejected": [
- "NIT, pre-flight shows Edit speech as Ready without AuK's weights: no code change. The weights sit inside the AuK checkout's ckpts/, which the pre-flight can't see, and the first-run text names the downloads. The implementer already noted this in 'left'; it is a note for the docs pass.",
- "Running the full Vitest suite and merging claude/fuobe-parity-4: left for the later base-merge step, as the coordinator asked for this stage."
- ],
- "checks": {
- "worktree": "/home/user/wt/o-nm10-speech-edit on o/nm10-speech-edit. Branch history held only this package's commits, and the base was already an ancestor, so no merge was needed. Three commits were added (de5fde38, ab5eb997, 841a9d63), all signed, and pushed to origin/o/nm10-speech-edit at 841a9d63. git status is clean and .next was deleted.",
- "hotFiles": "src/lib/av/clean-voice.ts is identical to claude/fuobe-parity-4. No hot files, validation-state, db.ts, deploy or admin files were touched.",
- "typecheck": "npx next typegen, then pnpm typecheck with NODE_OPTIONS=--max-old-space-size=6144: exit 0",
- "lint": "eslint on the changed files: exit 0",
- "targetedTests": "speech-edit, speech-edit-comfy, speech-edit-server, assist-context, licences, catalog, mcp, public-signup, public-signup-tools, gpu-requirements, comfy-library-4: 11 files, 214 tests, all passed",
- "loudCpuCheck": "Live CPU ComfyUI at 127.0.0.1:8188. The old and new expanded stitch graphs ran on a 0.97-peak signal (24 and 48 kHz), with a polarity-flipped stand-in for AuK. Old: max step 0.50 (a click). New: max step equal to the signal's own, max error 0.003, length 8.000 s. The test files and outputs were removed from ComfyUI afterwards. No packs were installed and the server was not restarted.",
- "browser": "tests/e2e/speech-edit.mjs on next dev with FUOBE_DEMO_MODE=on at http://localhost:3417: all checks passed at 1440 and 390 px, light and dark, including Captions' Fix this line. The server was stopped and .next deleted.",
- "fullVitest": "After merging claude/fuobe-parity-4 (23bfafd5): typecheck 0, lint 0 (warnings only), vitest 5436 passed / 6 failed, all six rule-8 known failures (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack)."
- },
- "finalSummary": "Edit speech (Audio → Edit speech, the ⋯ menu, Captions' Fix this line, Assist/MCP edit_speech) runs on the open engine only, with Tencent AuK on the person's ComfyUI. On the cloud engine it says it runs on your GPU (open source), and Paid APIs only hides or refuses it, since AuK is hosted on neither fal nor Replicate. After this fix, a video's edited sound keeps the clip's length, so it stays in step with the stream-copied picture. Pace is for audio only. Seams no longer click on loud recordings, verified on CPU ComfyUI with the core stitch nodes and a stand-in for AuK. What is verified: planning, diff and windows, graph expansion and stitch accuracy on CPU, provider bindings, routes, and the page in the browser in demo mode. What is built but not verified: AuK itself. It needs an NVIDIA GPU (about 17 to 25 GiB VRAM), the ComfyUI-AuK pack (AUK=1 in install-comfyui.sh) and about 19 GB of weights. No API key is involved. Public sign-up: guests see the page read-only. Accounts get a price check of their own file, priced for their own GPU and never a demo; the run answers own-gpu-tool at the proxy, like main's other audio tools.",
- "left": [
- "Untested on a GPU: no real AuK run, and its weights were not downloaded. The graphs are checked against a node list from nodes.py at the pinned commit.",
- "Brief surfaces not built: 'Fix this line' in Transcribe results, 'Re-voice this line' in Translate & dub review, Faceless narration lines, and the Canvas audio node.",
- "On a video, a much longer replacement is fitted into the old window's time, so AuK speaks it faster. The page doesn't yet warn when a change is much longer than the words it replaces.",
- "The hand-built template workflows/comfyui/speech-edit-auk.json keeps its single-window stitch without the headroom gains. The expander always rebuilds the stitch (expand 'speech'), so runs are unaffected.",
- "Pre-flight can show Edit speech as Ready without AuK's weights (ckpts/ inside the AuK checkout). This needs a docs note.",
- "Word times come from transcript lines. Qwen3-ASR's forced-aligner word times are not read yet.",
- "tests/comfy-library-4.test.ts: only the allowed edit, the two unvalidated ids added (speech-edit-auk, speech-tts-auk); no change in this stage.",
- "Full Vitest and the merge of claude/fuobe-parity-4 run in the later step."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/nm10-speech-edit"
- ],
- "notMerged": [],
- "conflicts": "library.spec, comfy.ts expand union, licences, comfy-library-4 unvalidated list (order fixed 4752e659), manifest; requirements regenerated",
- "checks": "batch of 6 (n7-11, o12 re-merge, pika-flex, keying, rtx-video, speech-edit): typecheck 0, lint 0, vitest 5612 passed, 8 failed (6 main known + blockout and moderation-hook load timeouts, 41/41 alone); requirements budget raised to 288/36 KB (a150159e); each merge checked by an independent verifier",
- "pushed": true,
- "head": "a150159e"
- }
-}
diff --git a/docs/handoff/reports/o12-training-kit.json b/docs/handoff/reports/o12-training-kit.json
deleted file mode 100644
index 407edef1..00000000
--- a/docs/handoff/reports/o12-training-kit.json
+++ /dev/null
@@ -1,157 +0,0 @@
-{
- "key": "o12-training-kit",
- "impl": {
- "branch": "o/o12-training-kit",
- "summary": "Built the O12 training kit: everything up to a training run for Fuobe's own LoRAs and the motion library. That covers 13 job specs, each with both routes; a data-licence log format and a checker that refuses to start a job; planned LoRA library entries that no preset may use; a motion-library manifest and its checker for the 13 sports moves; and publishing to a Fuobe Hugging Face org, dry-run by default. None of it has been trained or uploaded: there is no GPU, no fal key and no owned dataset here. Already on the base before this package: the hosted trainer fields, prices and outputs (trainers.generated.ts), aiToolkitJob for Z-Image Turbo, which the kit reuses, the research's fuobeTrainedLoras list (10 rows for section 6, not used by any code), the 'train' flags on 16 Soul looks, the WORDS_ONLY handling for the train-own and motion-library rows in dop.ts, and a library test that checks licence fields. The generator had no refusal for a missing licence until this package added one.",
- "built": [
- "scripts/train/specs/*.json: 13 job specs. They are the 10 LoRAs in section 6 (fuobe-soul-core, fuobe-cctv and fuobe-ultrawide-05 first) plus three Wan 2.2 I2V motion LoRAs: fuobe-push-in (Eyes In, Mouth In, Eating Zoom), fuobe-timelapse and fuobe-drone-reveal. Each spec has dataset size and caption rules, steps, rank, learning rate, trigger, the fal trainer (with extra fields such as training_type), the AI-Toolkit arch (zimage:turbo, zimage, wan22_14b_i2v) and the target file and Hugging Face repo.",
- "src/lib/training-kit.ts (pure): specProblems checks each spec against the research's trainer fields, step limits, field enums, media, base and planned entry. falTrainingPayload builds the fal request from the trainer's own fields (number_of_steps on Wan, default_caption or trigger_phrase where the schema has them). aiToolkitConfig builds the AI-Toolkit job; Z-Image Turbo reuses aiToolkitJob, and Z-Image base and Wan 2.2 I2V 14B take AI-Toolkit's own defaults, read at main e9c72b7 on 2026-11-02. specCostUsd gives the fal price.",
- "Data-licence log (scripts/train/data-logs/<id>.json, shipped empty, so every job is refused today). Each item has file, sha256, a source (own-shoot, licensed, cc0 or public-domain), licence, proof, author and date. A licensed item also needs aiTraining:true. A file with people in it needs a signed release covering ai-training, from adults only. dataLogProblems also checks a dataset folder: every file is logged, unchanged by SHA256 and captioned, and the count is within the spec's range, and the log must be reviewed. publicLog removes release references before publishing.",
- "LoRA library: gen-lora-library.py now refuses any entry without a licence snapshot (licence, commercial and hostedOk), and refuses any preset, motion or effect row, or Mixed Media look that uses a planned LoRA. It emits PLANNED_LORAS (13 entries with status 'planned' and a licence snapshot). A research row with a 'trained' block (pinned URL, SHA256, size, licence) becomes an ordinary LORA_LIBRARY entry the next time gen:catalog runs. PlannedLora type added in loras.ts.",
- "Motion library: src/lib/catalog/motion-library.json lists the 13 sports moves with their DoP preset ids and no clips yet. motionLibraryProblems checks that each clip is CC0, public domain or own-shot, 2-10 s, at least 480 px, https, with a release where people appear. motionLibraryClip(presetId) returns a move's first clip that passes, and undefined until then, so the moves keep their current route.",
- "scripts/train/kit.mjs, a command line with five commands: list (log counts and fal price per spec); check <id>|--all [--dataset]; job <id> --dataset [--zip-url] [--out], which writes .aitk.json and .fal.json under .train/ (git-ignored), refuses while the log fails, and submits nothing; motions; and publish <id> --file [--org] [--upload] [--write-research], a dry run by default. --upload uses 'hf' with HF_TOKEN, and --write-research writes the trained block into the research JSON before pnpm gen:catalog. FUOBE_TRAIN_LOGS can point at a private log folder.",
- "scripts/train/README.md: a short guide covering data, log format, check, job, publish and the motion library.",
- "Research: added the three Wan rows to fuobeTrainedLoras in the JSON, and to the section 6 table in the markdown with a dated note. Every row now has group and status 'planned'. Re-checked at source: fal's three trainer schemas (z-image-trainer, z-image-turbo-trainer-v2, wan-22-trainer/i2v-a14b) match the JSON, and AI-Toolkit's arch names and defaults for these bases."
- ],
- "tests": "tests/training-kit.test.ts adds 17 tests (16 after the fix commit dropped one assertion), all passing. They cover specs, payloads, AI-Toolkit configs, every log gap, folder matching, release rules, the public log, planned entries, generator refusals and the trained-block publish path, the motion library, and the command line end to end: refusal, a ready dataset writing both configs, a changed file refused, and a dry-run publish. lora-library and oss-loras tests pass. npx next typegen, pnpm typecheck: OK. pnpm lint: 0 errors, 1 warning that was already on the base (WAN_NEG_EN). One full Vitest run (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 4963 passed, 8 failed. 6 of the 8 are rule 8's known failures: comfy-reuse, dop-originals, preset-featured, soul-runs x2 and split-soundtrack. picker-covers timed out under load and passes alone (rule 12). no-higgsfield was mine: the provider's name appeared in the data checker and the README. Fixed in cbe62a22: the checker now relies on its four allowed sources instead of matching a name. no-higgsfield and training-kit pass after the fix.",
- "left": [
- "Nothing is trained. Each LoRA needs an owned or licensed dataset, a completed and reviewed data-licence log, and then a GPU (AI-Toolkit; Wan 2.2 14B needs 24 GB) or a fal key (prices in kit.mjs list: about $1.0-5.7 per LoRA).",
- "The Fuobe Hugging Face org ('fuobe' by default, or FUOBE_HF_ORG) has to be created by the owner, with a write HF_TOKEN. The --upload path (hf repo create, hf upload, then reading the commit through the HF API) has never been run.",
- "The motion library has no clips. The step that runs a move from its clip (Fuobe Genjutsu motion transfer on both engines, 'maker' in the manifest) is not wired into dopPreset or the generation path; only motionLibraryClip exists, and today it leaves every move on its current route.",
- "fuobe-beauty-details stands for four concept LoRAs (grillz, bleached brows, long legs, creatures). Its spec says to copy it once per concept and add each to fuobeTrainedLoras before the first run.",
- "Unverified until the first run: whether a LoRA trained on Z-Image base (fal z-image-trainer, used by soul-core, scale-surreal, frutiger-aero and paper-collage) behaves the same on Z-Image Turbo, and whether fal's single Wan 2.2 I2V lora_file works loaded on both experts.",
- "Planned entries are not shown in Settings → Models & licences. Once a file is published it appears there like any library LoRA.",
- "Brief out of date: 'the library test rejects an entry without a licence snapshot' was only partly there. The test checked the generated fields, but the generator fell back silently when a licence was missing; the generator now refuses."
- ],
- "docsNotes": "STATUS.md (O12): the training kit is built and nothing is trained. It has 13 specs with both routes, data-licence logs with a checker that blocks jobs, PLANNED_LORAS in the library, a motion-library manifest for the 13 sports moves (no clips, current routes kept), and a dry-run publish to a Fuobe HF org followed by gen:catalog. ARCHITECTURE.md: src/lib/training-kit.ts (pure) and scripts/train/kit.mjs; gen-lora-library.py now emits PLANNED_LORAS and turns research fuobeTrainedLoras[].trained into library entries; src/lib/catalog/motion-library.json. The guide is scripts/train/README.md. No routes, pages, migrations or ComfyUI graphs were added, so there is nothing to change for public sign-up or the GPU pre-flight.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "verdict": "CONFIRMED",
- "file": "scripts/train/kit.mjs",
- "line": 62,
- "summary": "The data-licence check only sees files that match its own extension list, so unlogged files in the dataset folder pass and still get trained. The fal zip is not checked at all.",
- "detail": "readDataset() keeps only /\\.(jpe?g|png|webp)$/ for image specs and /\\.(mp4|mov|webm)$/ for video specs. Any other file in the folder never reaches dataLogProblems. That includes a .mkv/.avi/.m4v clip, which AI-Toolkit's video loader reads, and a .jpg in a Wan dataset, which AI-Toolkit trains as a one-frame item. Yet the .aitk.json points AI-Toolkit at that whole folder. Reproduced: a valid 20-clip log for fuobe-push-in plus an unlogged stray.mkv and still.jpg in the same folder. `kit.mjs job fuobe-push-in --dataset <dir> --zip-url https://example.com/anything.zip` printed 'the data-licence log passes' and wrote both configs. The fal route also takes any --zip-url, and nothing ties it to the checked folder, so the hosted path skips the log check in practice. Fix: refuse any file in the folder that is not logged media or a caption, or at least any extension AI-Toolkit reads. For fal, have the kit build the zip from the checked files and record its SHA256.",
- "brief": "item 2: 'a checker script that refuses to start a job whose dataset log is incomplete'"
- },
- {
- "severity": "medium",
- "verdict": "PLAUSIBLE",
- "file": "scripts/train/kit.mjs",
- "line": 143,
- "summary": "The published model card has `base_model: z-image-turbo` / `wan2.2-i2v-a14b`. Those are not Hugging Face repo ids, and the Hub rejects commits whose README base_model metadata is not a valid model id.",
- "detail": "From memory of how the Hub behaves: it refuses such a commit with 'Invalid metadata in README.md … \"base_model\" with value … is not valid. Use a model id from https://hf.co/models'. Not run here; the implementer says --upload has never been run. If so, the first `hf upload` fails. The value is also wrong in substance for the four specs on fal z-image-trainer and the AI-Toolkit 'zimage' arch, which train on Tongyi-MAI/Z-Image (base), not Turbo. Use the real repo ids, e.g. Tongyi-MAI/Z-Image-Turbo, Tongyi-MAI/Z-Image, or the Wan-AI Wan2.2-I2V-A14B repo, chosen by the route actually used, or leave the field out."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "scripts/train/kit.mjs",
- "line": 151,
- "summary": "The trained block and the HF card hard-code `license: apache-2.0`, `commercial: true` and `hostedOk: true`, whatever the data log's sources or licences say.",
- "detail": "Licences are information to be recorded, not assumed. A dataset with 'licensed' stock items can carry redistribution or hosting limits, and publish copies none of that into the snapshot Settings → Models & licences will show. Derive the snapshot from the log (e.g. list the distinct item licences, and flag non-own sources), or at least let the operator set it, rather than asserting Apache-2.0 / commercial / hostedOk."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/lib/training-kit.ts",
- "line": 283,
- "summary": "publicLog() goes up publicly to Hugging Face with each item's `proof` and `author`. Per the format's own docs, those can be receipts, contracts, shoot folders and call sheets.",
- "detail": "Only `consent` is stripped. proof is documented as 'the receipt or contract, the shoot's folder or call sheet', and the README example is 'call sheet 2026-11-12, raw folder cctv/2026-11-12'. That is internal material, and people's names in author/proof go public too. Consider publishing only source, licence, sha256, date and a has-proof flag, or a separate publicProof field."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/lib/training-kit.ts",
- "line": 260,
- "summary": "The caption check only tests that <stem>.txt exists. An empty caption, or one without the trigger, passes, though every spec's caption rules require the trigger.",
- "detail": "folder.captions is a list of names; the content is never read. specProblems insists that the caption rules mention the trigger, but the dataset check never enforces it."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "scripts/gen-lora-library.py",
- "line": 21,
- "summary": "The generator docstring and comment cite scripts/train/publish.mjs, which does not exist (publishing is `scripts/train/kit.mjs publish`).",
- "detail": "Lines 21 and 235."
- },
- {
- "severity": "low",
- "verdict": "CONFIRMED",
- "file": "src/lib/training-kit.ts",
- "line": 317,
- "summary": "The motion library has no pick-up point: motionLibraryClip() is used by nothing in src/, so a clip added to the manifest changes nothing for the 13 moves.",
- "detail": "Brief item 4 asks for 'where those moves would pick the clips up once present'. The helper exists and the README says honestly that it is not wired. The moves keeping their current route is correct for now, but the hook into dopPreset / the generation path, which would ask for the clip and fall back, is not there. The implementer reports this under 'left'."
- },
- {
- "severity": "info",
- "verdict": "CONFIRMED",
- "file": "src/lib/training-kit.ts",
- "line": 71,
- "summary": "BASE_OF accepts the AI-Toolkit 'zimage' (base) arch for a spec whose base is z-image-turbo. So soul-core, scale-surreal, frutiger-aero and paper-collage train on Z-Image base on both routes, though the library entry and Soul run on Turbo.",
- "detail": "The soul-core note says to 'compare it with the AI-Toolkit Turbo run', but the spec's AI-Toolkit route is base, not Turbo, so no Turbo run is configured. The base-vs-Turbo question is acknowledged in 'left'. Consider making AI-Toolkit train on zimage:turbo (with the training adapter) for these, so one of the two routes matches the runtime model."
- }
- ],
- "checks": [
- "Read review prompt, main rules and the implementer report; reviewed git diff claude/fuobe-parity-4...o/o12-training-kit (2 commits, 37 files: specs, empty data logs, kit.mjs, training-kit.ts, gen-lora-library.py, PlannedLora type, motion-library.json, research rows, tests).",
- "No routes, pages, migrations, ComfyUI graphs, node packs or server paths added: nothing to check against public sign-up, tenant/account-inputs, the proxy body limits or the GPU pre-flight board. training-kit.ts is imported by nothing in src/ (only scripts/tests).",
- "No binary/LoRA/Higgsfield media committed; no Higgsfield API use; tests/no-higgsfield passes.",
- "fal payloads checked against trainers.generated.ts: z-image-trainer (image_data_url, steps 100-10000, learning_rate, default_caption, training_type enum), z-image-turbo-trainer-v2 (steps 10-40000), wan-22-trainer/i2v-a14b (training_data_url, number_of_steps 100-20000, learning_rate, trigger_phrase). falTrainingPayload only sends fields in the schema; the step counts are in range.",
- "Motion library presetIds (13) all exist in the catalog (preset-recipe-book.json / oss-loras.generated.ts), and the test checks getPreset for each.",
- "python3 scripts/gen-lora-library.py regenerates lora-library.generated.ts with no diff (124 LoRAs, 13 planned); the tree stays clean.",
- "Generator: refuses an entry with no licence snapshot, and refuses a preset, motion/effect row or Mixed Media look that uses a planned LoRA; a trained block goes through entry(), which pins resolve/main to the revision and needs sha256. Research JSON rewrite in --write-research keeps the file's indent-1 format byte-for-byte.",
- "vitest tests/training-kit, lora-library, oss-loras, no-higgsfield: 4 files, 69 tests passed. No full Vitest run (the implementer's covered it; the targeted runs were enough).",
- "pnpm typecheck (after next typegen): OK. eslint on the changed TS/MJS files: clean.",
- "kit.mjs list / check --all / motions run: every spec is planned, every job refused for an empty log, and all 13 moves keep their current route.",
- "Reproduced finding 1 in the scratchpad: with a valid 20-clip log plus an unlogged .mkv and .jpg in the dataset, `job` passed and wrote both configs; also took an arbitrary --zip-url. Scratch files removed; no edits or commits to the worktree."
- ],
- "verdict": "approve-with-fixes: the kit is a solid, honestly labelled build of brief items 1-6, matches the research's trainer fields and touches no runtime route. Before merge, fix the data-licence checker so unlogged files in the dataset folder (any extension the trainer reads) and an unchecked fal zip cannot slip past it (finding 1), and the HF model card's base_model (finding 2). The rest are low-severity follow-ups."
- },
- "fix": {
- "applied": [
- "Finding 1 (medium, confirmed): the dataset check now reads the whole folder (scripts/train/kit.mjs readDataset). Every file that is not a caption is hashed, whatever its extension, and anything that is not a plain file is listed. dataLogProblems (src/lib/training-kit.ts) refuses any file that is not the spec's media ('stray.mkv is not a clip the spec trains on', a .jpg in a Wan set, notes.pdf), any sub-folder or link, and every unlogged or changed file, as before. For fal, `job` now zips exactly the checked files (datasetZipNames: the logged media plus captions) into .train/<id>/<id>.dataset.zip and prints its SHA256. It writes <id>.fal.json only with --zip-url, after downloading that URL and finding the same SHA256 as the zip it built, and it records datasetZip {file, sha256} in the request file. Tests: unit cases for a stray .mkv, a still in a clip set, a .pdf and a sub-folder; CLI cases for a stray .webm refusing the job, a served zip with the wrong bytes refused, and the right zip accepted (local http server).",
- "Finding 2 (medium, plausible; fixed): checked at the primary source. Per the Hub model-card docs (huggingface.co/docs/hub/model-cards) and the spec (hub-docs modelcard.md), base_model takes Hub model identifiers. The real repo ids were read from the HF API on 2026-11-02, all Apache-2.0: Tongyi-MAI/Z-Image-Turbo, Tongyi-MAI/Z-Image, Wan-AI/Wan2.2-I2V-A14B. Neither source confirms that the Hub rejects an invalid value; the review gave that from memory. A library base name is wrong either way. Fix: hfBaseModel(spec, route) maps the route's trainer to the repo it trains on: fal z-image-trainer and AI-Toolkit zimage to Z-Image, the Turbo trainer and zimage:turbo to Z-Image-Turbo, and both Wan routes to Wan-AI/Wan2.2-I2V-A14B. `publish` now requires --route fal|ai-toolkit, and the card gets base_model plus base_model_relation: adapter.",
- "Finding 3 (low): the licence snapshot comes from the data-licence log (trainedLicence). Data that is all own-shoot, CC0 or public domain defaults to Apache-2.0, commercial and hostable. With any 'licensed' item, publish refuses until the operator passes --licence, --commercial yes|no and --hosted-ok yes|no. The snapshot text names the data's sources and licences. The card's license is the SPDX id, or 'other' with license_name.",
- "Finding 4 (low): publicLog publishes only file, sha256, source, licence, date, aiTraining (licensed items), people and a consent flag. Proof becomes 'on file', and author and the release reference are dropped. A CC0 or public-domain original with an https proof keeps it as `original` with its author, as a credit.",
- "Finding 5 (low): captions are read. The folder passes caption text by name, and the check refuses a missing caption, an empty one, or one without the trigger as a whole word.",
- "Finding 6 (low): gen-lora-library.py now points to `scripts/train/kit.mjs publish` instead of the nonexistent scripts/train/publish.mjs (both places).",
- "Finding 7 (info): soul-core, scale-surreal, frutiger-aero and paper-collage now take AI-Toolkit zimage:turbo (with the training adapter), not zimage. fal's z-image-trainer stays the base route, so one route matches Soul's runtime model, and the spec notes now describe the comparison that is actually configured. This matches the research row ('AI-Toolkit on Z-Image base / Turbo + ostris training adapter v2'). The zimage arch path stays tested through a spec override.",
- "README (scripts/train/README.md) updated: the folder rule, the zip-then-URL job flow, --route and base_model, the licence options and the public log's fields. Tests: tests/training-kit.test.ts has 19 tests, all passing."
- ],
- "rejected": [
- "Finding 8 (low, motionLibraryClip not wired into dopPreset): not wired. No clip exists, so wiring would change no behaviour today. Running a move from a fixed driving clip needs the clip passed as the video input of fuobe-genjutsu-motion (op motion-transfer) through the generation path, which means touching the recipe-fidelity files (dop.ts routes, generations.ts and plan.ts per rule 2), and it can only be verified with a GPU or fal run. The pick-up point the brief asks for exists: motionLibraryClip(presetId) returns a checked clip or undefined, and the README and the manifest's `maker` name the step. Kept under 'left'."
- ],
- "checks": [
- "Worktree /home/user/wt/o-o12-training-kit on o/o12-training-kit: git log claude/fuobe-parity-4..HEAD lists only this package's two commits, and the base is an ancestor, so nothing was merged. Local claude/fuobe-parity-4 (fdad177c) is behind origin (85be87db); the base merge was left to the later stage as instructed.",
- "Primary sources for finding 2: https://huggingface.co/docs/hub/model-cards (base_model = 'base model Hub identifier'; base_model_relation adapter); https://github.com/huggingface/hub-docs/blob/main/modelcard.md ('base_model: {base_model} # Example: stabilityai/stable-diffusion-xl-base-1.0'); https://huggingface.co/api/models/Tongyi-MAI/Z-Image-Turbo, /Tongyi-MAI/Z-Image, /Wan-AI/Wan2.2-I2V-A14B (all exist, cardData license apache-2.0, read 2026-11-02). A web search found no primary source quoting the Hub's 'Invalid metadata' rejection.",
- "npx next typegen: exit 0. pnpm typecheck: exit 0. pnpm lint: exit 0, 0 errors, 1 warning that was already on the base (WAN_NEG_EN in scripts/comfy/library.spec.mjs).",
- "Targeted: vitest tests/training-kit, lora-library, oss-loras, no-higgsfield: 4 files and 71 tests passed (training-kit is 19/19 after the last edit).",
- "python3 scripts/gen-lora-library.py regenerates with no diff. kit.mjs list shows every Z-Image spec on AI-Toolkit zimage:turbo, with fal prices unchanged.",
- "One full run, FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: 4966 passed, 7 failed, 4 skipped. Six are rule 8's known failures (comfy-reuse, dop-originals effect-acid, preset-featured, soul-runs x2, split-soundtrack). preset-covers timed out at 5000 ms under load (rule 12) and passes alone (11/11).",
- "No browser check was needed (no UI change). .next was removed, git status is clean, and 6dc2cf50 is pushed to origin/o/o12-training-kit."
- ],
- "finalSummary": "The fixes close the review's two medium findings and its low and info notes. The data-licence check now covers everything in the dataset folder, and the caption text must have the trigger. The fal route trains only on a zip the kit built from the checked files, accepted only when the uploaded URL has that zip's SHA256. Publishing takes the route, writes a real Hugging Face base_model (Tongyi-MAI/Z-Image, Tongyi-MAI/Z-Image-Turbo or Wan-AI/Wan2.2-I2V-A14B) with base_model_relation adapter, takes the licence snapshot from the log (licensed data needs an explicit licence, commercial and hosting decision), and keeps proof, authors and release references off the public log. The Z-Image specs now train on Turbo on the GPU route, so one route matches Soul. Per engine: the open engine (the user's GPU) gets AI-Toolkit configs for all 13 specs (Z-Image Turbo with the training adapter; Wan 2.2 I2V 14B, which needs a 24 GB card). Built and unit-tested, never run: no GPU here. The cloud engine gets fal trainer requests for the same 13 specs, built from the trainers' schema fields, with the dataset zip pinned by SHA256. Built and tested against a local server, never submitted: no fal key, no owned dataset. Publishing to the Fuobe HF org is tested as a dry run; --upload needs HF_TOKEN, the hf CLI and the org, and has never run. Nothing is trained; all 13 LoRAs stay PLANNED_LORAS that no preset uses. Public sign-up: the kit is scripts and pure library code with no routes, pages or runs, so guests and accounts see no change. Planned LoRAs are not shown to anyone, and a published one would appear like any library LoRA under the owner's Models & licences.",
- "left": [
- "Nothing is trained: each LoRA needs an owned or licensed dataset, a complete reviewed data-licence log, and a GPU (AI-Toolkit; Wan 2.2 14B needs 24 GB) or a fal key.",
- "The Fuobe Hugging Face org and a write HF_TOKEN have to come from the owner. The --upload path (hf repo create, hf upload, reading the commit) has never run, so whether the Hub accepts the new card is confirmed only on the first upload.",
- "The motion library has no clips, and running a move from its clip (fuobe-genjutsu-motion with the clip as the driving video) is not wired into dopPreset or the generation path. motionLibraryClip is the pick-up point (finding 8, deferred).",
- "Unverified until the first run: how a Z-Image base LoRA (fal z-image-trainer) behaves on Turbo compared with the AI-Toolkit Turbo file, and whether fal's single Wan 2.2 I2V file works loaded on both experts.",
- "The `job` zip uses python3's zipfile module, so python3 must be on the machine that makes the job (gen:catalog already needs it).",
- "fuobe-beauty-details is to be copied into four concept specs before its first run. Planned entries are not shown in Settings → Models & licences.",
- "The base branch still has to be merged (later stage). The local claude/fuobe-parity-4 is behind origin."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/o12-training-kit"
- ],
- "notMerged": [],
- "conflicts": "none (already in the base at 23bfafd5; this records its later report commit)",
- "checks": "batch of 6 (n7-11, o12 re-merge, pika-flex, keying, rtx-video, speech-edit): typecheck 0, lint 0, vitest 5612 passed, 8 failed (6 main known + blockout and moderation-hook load timeouts, 41/41 alone); requirements budget raised to 288/36 KB (a150159e); each merge checked by an independent verifier",
- "pushed": true,
- "head": "a150159e"
- }
-}
diff --git a/docs/handoff/reports/w2s-w5.json b/docs/handoff/reports/w2s-w5.json
deleted file mode 100644
index ed55ec45..00000000
--- a/docs/handoff/reports/w2s-w5.json
+++ /dev/null
@@ -1,135 +0,0 @@
-{
- "key": "w2s-w5",
- "impl": {
- "branch": "o/w2s-w5 (worktree /home/user/wt/o-w2s-w5, head eb1d7128)",
- "summary": "W5 Skills as canvases. Pure recipeToCanvas and canvasToRecipe are in src/lib/catalog/canvas.ts. Open as canvas is POST /api/canvases {skill}. Save as skill from a canvas uses POST /api/assist/skills/draft {canvas, page} and opens W2's review screen. A skill opened as a canvas can be saved back into the same skill (saveDraft replace). The Canvas list has a Skills tab, and the editor's run menu has Save as skill…. A saved canvas skill is an ordinary recipe skill, so it runs from the Run form, Assist and MCP (run_skill), the CLI and schedules with no extra code.",
- "built": [
- "Converter (src/lib/catalog/canvas.ts). recipeToCanvas(recipe, {elements, from}): inputs become prompt, image, video, audio or element nodes. Generate steps become model nodes with their model, op, words and settings. Chain slots become edges into prompt, images, endImage, video, videos, audio, or voice (for voiceAudio).",
- "recipeToCanvas refuses with 'This skill can't be drawn yet' and a reason for: a studio (tool) step, which shows as a 'Studio step' note; number or choice inputs; audio2, audios, model3d or mask; chain slots with stem, index, position, of or optional; file inputs with no port; placeholders in settings; two text inputs apart in one prompt; linked (http) fixed files. Every drawing is read back with canvasToRecipe and compared by recipeShape, and a drawing that wouldn't come back the same is refused.",
- "What a board has no field for is kept on its nodes, and the canvases NodeData schema now accepts both fields (size-capped). data.skill holds the step key, label, feature, extra request fields (LoRAs, preset, negativePrompt, settings outside the board's Params) and check; the extra fields are dropped if the model is swapped. data.input holds the input's id, limits and form order, or marks a fixed file.",
- "canvasToRecipe(graph, {canvas}): input nodes that feed a step become inputs (fixed-file nodes stay fixed). Steps are built by describeNode. A Video concatenator compiles to its cut, frame, mute and join steps as runCanvas does, with helper steps on feature canvas-step. Element @handles become placeholders. Chain positions are kept only where they matter. A Table's columns become text inputs, read as '{Column}' in the words or as the row text, and its filled rows (at most 50 x 8, TABLE_LIMITS) become the Many tab's rows. It refuses a concatenator that joins a clip per table row, a second table, loops, more than 24 steps, and nodes that can't run (named by node). Leaf steps on a board made from scratch get a kind check.",
- "src/lib/recipe-builder.ts: fixedDraft(recipe, varies) turns a recipe with inputs into W2's draft. Every input starts Fixed except inputs of the skill the board was drawn from and Table columns. A new DraftCandidate.part means text-node words inside longer words vary as those words (buildRecipe handles it). Also new: DraftCandidate.varies, SkillDraft.rows, SkillDraft.replaces, and rowsCsv.",
- "src/server/canvas-skills.ts: canvasFromSkill(name) and draftFromCanvas(id, page). The draft is built from the page with current elements. Silence references are written as files, as Run all does. Each step's thumbnail is the node's last result. A Table's rows and the source skill's name, title and description carry over.",
- "Routes: DraftSource accepts {canvas, page?} in the draft and draft/name routes. The draft/save route takes replace: true, which writes only recipe.json into an existing user skill (a built-in gets 403 'Duplicate it first'). POST /api/canvases takes {skill}: 201, 422 'This skill can't be drawn yet: …', or 404. RecipeView.canvas says whether a skill can be drawn, and names the studio for a studio step.",
- "UI: the Canvas list has tabs Mine (shown as 'Your canvases' from sm up) | Templates | Skills. The Skills tab lists recipe skills: drawable ones have Open as canvas (hidden for visitors), a studio step shows a 'Studio step' note, other undrawable skills give the reason. The editor's 'More run options' menu has Save as skill… (owner only); it saves the board first, then opens the review. In the review: header and refusal copy for a canvas, inputs that start as Varies, a 'Save back into /name' checkbox (on by default, locks the name, button 'Save back'), and the Run form opens on the Many tab with the table's rows (new RunSkillDialog csv prop).",
- "Public sign-up: no new routes. The draft routes are already owner-only (assist-owner), and POST /api/canvases is already a library change for guests and accounts. Comments in tests/public-signup.test.ts and tests/public-signup-visitors.test.ts note the new bodies."
- ],
- "tests": [
- "New tests/canvas-recipe.test.ts (18, pass): recipe to canvas to recipe is equal (steps, params, checks, keys, labels, features, extra fields); a fixed file, an element and two texts in order; a model swapped on the board; each refusal (audio2, audios, model3d, mask, stem, index, position, an unported input, settings inputs, studio step, texts apart); canvas to recipe inputs and steps; Table rows to rows (named columns, read as text, more than 50 refused); fixedDraft plus buildRecipe round trip; a node that can't run, and an empty board.",
- "New tests/canvas-skills.test.ts (6, pass, server, demo setup): Open as canvas through the route (201, nodes kept through the schema; 422 and 404); RecipeView.canvas; a skill opened as a canvas drafts with Varies kept, a model swapped on the board is saved back (replace; SKILL.md kept; plan verified; built-in refused 403); a board made on the Canvas drafts with inputs Fixed plus Table rows, saves, and runs 2 rows through runRecipe stamped with the skill; a refused node is named.",
- "Also passing: tests/recipe-builder, recipes, recipe, canvas, public-signup, public-signup-visitors (8 files, 210 tests). Typecheck clean (tsc with NODE_OPTIONS=--max-old-space-size=8192 after next typegen; the default heap runs out of memory). eslint clean on changed files. Full suite not run (not in this stage).",
- "Browser: tests/e2e/canvas-smoke.mjs gained check 5 and fully passes in demo mode on pnpm dev -p 3456: Skills tab at 1440 and 390 px, light and dark, with no sideways scroll; at 1440 light, Open as canvas, Save as skill…, the free check, Save back, the Run form opens, and the skill keeps its input and is verified; at 390 the review opens and fits. Console errors fail the check. I also looked at screenshots. Server stopped and .next deleted."
- ],
- "left": [
- "An undrawable skill isn't opened as a read-only canvas: the Skills tab shows the reason (or the 'Studio step' note) instead.",
- "Canvas drafts propose no settings candidates (takes, shape, length, quality), since W2's settings come from server-side result nodes. A board's checks are the stash's, or kind-only on leaves.",
- "Pinned nodes run again in the skill; the review notes this.",
- "Layout boxes that fill '{Column}' from a table aren't turned into inputs.",
- "Number and choice inputs aren't drawable yet: the board has no settings-input node.",
- "Not verified: live Claude or Ollama naming on canvas drafts, and a GPU or keyed real run.",
- "No ComfyUI graphs, node packs, migrations or LoRAs were touched."
- ],
- "docsNotes": [
- "STATUS: W5 Skills as canvases. A recipe skill opens as a new canvas from Canvas → Skills, and a canvas is saved as a skill from the run menu's Save as skill…. Saving can put the steps back into the skill it was opened from. A Table's rows become the Many tab's rows, and a saved canvas skill runs from Skills, Assist and MCP, the CLI and schedules.",
- "ARCHITECTURE: recipeToCanvas and canvasToRecipe (src/lib/catalog/canvas.ts) with node fields data.skill and data.input; src/server/canvas-skills.ts; DraftSource {canvas, page}; POST /api/canvases {skill}; draft/save replace; RecipeView.canvas. No migration (canvases.graph_json).",
- "docs/cli.md: no change (the CLI already runs recipe skills).",
- "The brief's line numbers were out of date: the canvas list tabs are now near line 255 of canvas-list.tsx and were labelled 'Your canvases | Templates'; the editor menu is the 'More run options' dropdown in EditorHeader. All plan items were missing from the base: only RecipeSchema.source.canvas existed."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "title": "Save back silently drops a skill's text input when the input has no example",
- "where": "src/lib/recipe-builder.ts fixedDraft (locked 'Write its words on the canvas first') + src/server/recipes.ts saveDraft replace",
- "detail": "A recipe text param with no example/default (allowed by RecipeSchema, e.g. a hand-written or uploaded recipe.json) is drawn as an empty text node (recipeView.canvas says ok). canvasToRecipe keeps it, but fixedDraft gives it example '' so it is 'locked' and never starts as Varies. buildRecipe then makes it Fixed with an empty value, and Save back writes it into the existing skill. The skill loses the input, and its prompt 'A photo of {{subject}}' becomes 'A photo of '. The plan check still passes. Schedules, MCP and CLI callers that pass `subject` no longer reach a prompt.",
- "verified": "Scratch vitest probe (outside the repo): saveRecipe s2 {params:[subject text, no example], prompt 'A photo of {{subject}}'} -> canvasFromSkill -> draftFromCanvas -> buildRecipe(start choices) -> saveDraft({replace:true}) gave saved params [] and prompt 'A photo of '.",
- "fix": "When an input comes from a skill (data.input.param exists), keep it as Varies even if it is empty, or refuse Save back until the words are filled in. Don't write a replace that removes an input the original skill had without saying so."
- },
- {
- "severity": "medium",
- "title": "A swapped model keeps the old step's check, so a skill changed from image to video fails its free check and real test forever",
- "where": "src/lib/catalog/canvas.ts canvasToRecipe: `if (mark?.check) checks[key] = mark.check` (extra is dropped when modelId changes, but check is not)",
- "detail": "The brief's user story is swapping a model visually and saving it back. data.skill.extra is applied only while mark.modelId === req.modelId, but data.skill.check is always kept. Swapping an image step's model for a video model (nano-banana-pro t2i -> kling-3 t2v) keeps checks.a = {kind:'image'}. saveDraft gates only on the plan, so Save back succeeds. After that, dryRun reports 'Step a made no image' and realRun reports 'it made no image (got video)' on every check, so the skill can never earn dryRun/real verification. An aspect or seconds check can also go stale after a swap that changes the output.",
- "verified": "Scratch probe: lamp-style skill with checks {a:{kind:'image'}}, node swapped to kling-3/t2v -> draftFromCanvas -> saveDraft replace succeeded with checks {a:{kind:'image'}}; the generation ran as a video. In the dryRun code (recipes.ts ~line 614), kindOf(check) 'image' against video outputs adds a problem.",
- "fix": "Drop the kept check when the node's model or op changes and its output kind differs (or when the model changes at all, like extra), and fall back to the kind-only leaf check used for boards made from scratch. Add a test that swaps an image model for a video model."
- },
- {
- "severity": "low",
- "title": "Brief items not built: undrawable skills don't open read-only, and number/choice inputs make a skill undrawable",
- "where": "src/lib/catalog/canvas.ts recipeToCanvas, src/components/canvas/canvas-list.tsx SkillCard",
- "detail": "The brief says undrawable recipes 'open read-only with This skill can't be drawn yet', and a tool step shows as one read-only 'Studio step' note on the canvas. The build only shows the reason (or the note) on the Skills tab card. recipeToCanvas also refuses every recipe with a number or choice param or a placeholder in settings. The brief's refusal list doesn't include these, and W2 makes them whenever a setting varies (numOutputs, aspectRatio, duration, resolution), so many Library-made skills can't be drawn. Both gaps are listed in 'left'.",
- "verified": "Traced recipeToCanvas (settings refusal at the top, the placeholder-in-settings refusal) and SkillCard (no read-only open path).",
- "fix": "Either build the read-only open and a settings-input node, or have the owner accept these as follow-ups."
- },
- {
- "severity": "low",
- "title": "Unticking 'Save back into /name' leaves the taken name, and in replace mode the title and description edits are thrown away",
- "where": "src/components/skills/skill-builder.tsx Review",
- "detail": "draft.name is replaces.name. After unticking, the name field is enabled but still holds the existing skill's name, and the own-checks pass (regex only), so Save is enabled and the server's createSkill then refuses with 'already exists'. With replace on, Title, Description and When to use stay editable, but saveDraft's replace path ignores them. The toast says so only after saving.",
- "verified": "Probe: draftFromCanvas on a skill opened as a canvas returns name 's1' with replaces {name:'s1'}. Code reading of save() and saveDraft replace.",
- "fix": "On untick, switch the name to freeName(title). Disable or hide the About fields while Save back is on."
- },
- {
- "severity": "low",
- "title": "Concatenator compile and the replace-mode SKILL.md drift have no tests; the e2e leaves its canvas and skill behind",
- "where": "tests/canvas-recipe.test.ts, tests/canvas-skills.test.ts, tests/e2e/canvas-smoke.mjs",
- "detail": "The brief asks that concat nodes compile as runCanvas does, but no test covers a concat board. A probe shows it works: 8 steps (fit/sound/quiet/mute helpers on canvas-step, join-clips), and the plan and dry run pass on cloud demo. The e2e check 5 never deletes the canvas made by Open as canvas at 1440 or the e2e-canvas-skill skill.",
- "verified": "grep on the tests, plus a scratch probe of the concat board through draft and the demo-level check route (ok).",
- "fix": "Add a concat round-trip test. Clean up in the e2e."
- }
- ],
- "checks": [
- "git diff claude/fuobe-parity-4...o/w2s-w5 read in full (23 files) with surrounding code (describeNode {text} slot, saveRecipe, checkEngines/dryRun/realRun, guest-access, proxy readAsGuest).",
- "Public sign-up: POST /api/canvases {skill} is under the existing LIBRARY_CHANGES POST /api/canvases (403 for accounts, 401 for guests). The draft, draft/name and draft/save routes are assist-owner. GET /api/assist/skills is GUEST_FILTERED (built-ins only for visitors), and the recipe view's new `canvas` field leaks nothing. The Open as canvas and Save as skill buttons are hidden for visitors. No new route, no file read for an account run, no price check, no ComfyUI graph, model, LoRA or node pack, no Higgsfield use.",
- "npx next typegen + tsc --noEmit (8 GB heap): clean. eslint on the changed files: clean.",
- "Targeted vitest (canvas-recipe, canvas-skills, recipe-builder, recipes, recipe, canvas, public-signup, public-signup-visitors): 8 files, 210 tests pass.",
- "Full vitest suite, run twice. Run 1 under load: 8 failures in 7 files. Run 2: 6 failures in 5 files, exactly the known pre-existing ones (comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack); nothing new.",
- "Scratch vitest probes kept outside the repo (scratchpad config): a text input with no example lost on Save back (confirmed); an image input with no example drafts as Varies (ok); an image->video model swap keeps the image check, saves and runs as video (confirmed); a concat board drafts 8 steps and passes the plan and demo check (ok); unticked replace keeps the taken name (confirmed).",
- "The browser e2e (tests/e2e/canvas-smoke.mjs check 5) was not re-run by the reviewer. I relied on the implementer's run, and the UI diff reads fine at 390 px (3-column tab grid with 'Mine' under sm, cards min-w-0).",
- "No edits or commits. The .next made by typegen was deleted; the worktree is clean."
- ],
- "verdict": "changes requested: two medium bugs in the core round trip (a text input with no example is silently dropped on Save back; a swapped model keeps a stale check kind, so the skill fails its free check and real test). Both have small, local fixes. The rest is sound and follows the public sign-up rules."
- },
- "fix": {
- "applied": [
- "Medium, confirmed (Save back dropped a text input with no example): fixedDraft (src/lib/recipe-builder.ts) now marks an input of the source skill that a canvas holds no value for as a 'kept' candidate. Its {{id}} stays in the steps and the checks, it starts as Varies (not locked), and it carries the original param, so buildRecipe writes the input back exactly as the skill had it. Fixed puts in the value (empty words), and the review row says so. New helper putKept. Tests: canvas-recipe 'keeps words a skill asks for with no example', and canvas-skills 'saves back a skill's inputs a canvas holds no value for' (route-level Save back keeps prompt 'A photo of {{subject}}').",
- "Medium, confirmed (a swapped model kept a stale check): canvasToRecipe keeps a step's own check only while the node keeps its model and the check's kind matches the op's output. Otherwise the step gets the kind-only leaf check a board made from scratch gets. A skill step with no check still gets none while its model stays, so the round trip is unchanged. Checks are now copied, not shared: an in-place edit used to leak back into the source recipe. Test: an image step (nano-banana-pro t2i, check image) swapped to kling-3 t2v reads back with {kind:'video'}.",
- "Low, built (number/choice inputs made a skill undrawable): a settings input that fills a whole setting (params.<name>) and has a value now rides on its model node. The node shows the value, and data.skill.settings keeps {param, at}, with the canvases NodeData schema extended. On the way back it becomes {{id}} again while the node keeps its model and a value the input takes, and it follows a value changed on the board (default/example updated). A value outside the input's options or range, or a swapped model, leaves the board's value fixed, and any check part that followed it is dropped. In the review these inputs start as Varies as the skill had them (kept), and Fixed puts the value into the steps and the checks, typed. Settings used anywhere else, or with no value, are still refused, with a reason. Tests: draw, round trip, a changed value, an invalid value, a swapped model, the review start, and Fixed.",
- "Low, confirmed (the Save back untick UX): the draft's name is now always a free name (freeName(title)). With Save back on, the Name field shows the target skill and Title, Description and When to use are disabled because the replace path keeps them. Unticking gives an editable free name, so Save no longer hits 'already exists'.",
- "Low (test gaps): added a Video concatenator compile test (two clips become two video inputs, cut helper steps on canvas-step, the join is the node's own step and comes last, recipeProblems and RecipeSchema clean). e2e check 5 now seeds a choice setting input, asserts that both inputs survive Save back, and deletes the canvas it opened and the e2e skill at the end."
- ],
- "rejected": [
- "Low, part (undrawable skills 'open read-only'): not built. A refused recipe has no drawing to open: a partial read-only board would need a second, lossy converter path. The Skills tab card already gives the exact reason, or the 'Studio step' note for a tool step. Settings inputs, the biggest cause of undrawable skills, are now drawable, so far fewer skills are affected. Listed in 'left'."
- ],
- "checks": [
- "Branch check: git log claude/fuobe-parity-4..o/w2s-w5 lists only this package's commits, and the base is an ancestor (no merge needed). Worktree was clean at start.",
- "npx next typegen + pnpm typecheck (NODE_OPTIONS=--max-old-space-size=8192): exit 0.",
- "pnpm lint: exit 0 (5 pre-existing warnings in untouched files).",
- "Targeted: tests/canvas-recipe.test.ts 24 pass, tests/canvas-skills.test.ts 7 pass.",
- "FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2: exit 1, with 6 failures in 5 files (5477 passed, 4 skipped). These are exactly the known pre-existing failures from main: comfy-reuse, dop-originals, preset-featured, soul-runs x2, split-soundtrack. No new failures.",
- "Browser: node tests/e2e/canvas-smoke.mjs against pnpm dev -p 3456 with FUOBE_DEMO_MODE=on, a temp data dir, and COMFYUI_URL/OLLAMA_URL pointing nowhere: all checks passed. That covers checks 1-3, then check 5 at 1440 and 390 px, light and dark. At 1440 light: Open as canvas, Save as skill, the free check, Save back, and the Run form opening, with the skill keeping both its words input and the new choice setting input. At 390: the review opens and fits. No sideways scroll, and console errors fail the check. The ComfyUI at :8188 was not touched. The server was stopped, and .next and the temp data deleted. git status is clean after commit 3baadb01."
- ],
- "finalSummary": "W5 Skills as canvases is finished on o/w2s-w5 (head 3baadb01, on top of the implementer's 4 commits). A recipe skill opens as a canvas from Canvas → Skills. A canvas saves as a skill from the run menu, including back into the skill it came from. Saving back now keeps inputs the board has no value for (words with no example, settings), and a step whose model is swapped gets a check that fits the new output. Skills W2 makes with varying takes, shape, length or resolution can now be drawn: those inputs ride on their model nodes. Engines: the converter, the draft and Save back are engine-neutral. A saved canvas skill runs through runRecipe like any recipe skill (form, Assist/MCP run_skill, CLI, schedules) on whichever engine its steps' models use. Verified in demo mode only: the free plan/demo check, the cloud demo and the open demo provider. No GPU run or keyed cloud run was made. No ComfyUI graphs, node packs, models, LoRAs or migrations changed. Public sign-up: no new routes. POST /api/canvases {skill} is under the existing LIBRARY_CHANGES rule (guests 401, accounts 403 library). The draft, draft/name and draft/save routes stay owner-only. Visitors see the Skills tab's built-in list (GUEST_FILTERED) without the Open as canvas or Save as skill buttons, and their runs are untouched.",
- "left": [
- "An undrawable skill isn't opened as a read-only canvas: the Skills tab card shows the reason, or the 'Studio step' note.",
- "A settings input that appears anywhere but a whole params.<name> setting (in words, a nested setting) or has no default/example still isn't drawable.",
- "Canvas drafts propose no new settings candidates of their own (takes, shape, length, quality) for boards made from scratch. A board's checks are the skill's, or kind-only on leaves.",
- "Pinned nodes run again in the skill (the review notes this). Layout boxes that fill '{Column}' from a table aren't turned into inputs.",
- "Not verified: live Claude or Ollama naming on canvas drafts, a GPU run, or a keyed cloud run.",
- "Pre-existing failures (not this package): comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/w2s-w5"
- ],
- "notMerged": [],
- "conflicts": "none",
- "checks": "batch of 6 (dbs-d9, idol-7, w2s-w5, w2s-w6, w2s-w7, idol-4): typecheck 0, lint 0, vitest 5907 passed, 8 failed (6 main known + preset-covers and reuse-pack-pin load timeouts, 13/13 alone); each merge but idol-4 checked by an independent verifier (idol-4 merged by hand after: one conflict, its tests 99/99); W5/W6/W7 joined by follow-ups 642a167e, bef8778e, 22378b4b, 739a0c1d",
- "pushed": true,
- "head": "148f2459"
- }
-}
diff --git a/docs/handoff/reports/w2s-w6.json b/docs/handoff/reports/w2s-w6.json
deleted file mode 100644
index f2c26052..00000000
--- a/docs/handoff/reports/w2s-w6.json
+++ /dev/null
@@ -1,167 +0,0 @@
-{
- "key": "w2s-w6",
- "impl": {
- "branch": "o/w2s-w6",
- "summary": "Skills W6 is built on o/w2s-w6 (7 signed commits, pushed, worktree clean). The Library now suggests a skill for a chain you keep making. Saved skills get a run history, a 'Suggest a fix' action, and use-based ranking in Assist. A new `pnpm eval:from-skill` command writes a harness suite for a skill. Already there before this package (from W1/W2): the skill stamp in request_json, needsRecheck (REPLACED_BY and switched-off reasons), builder.open(ids), the eval and skill-check helper features, and the server's ?batch= list option. None of W6 itself existed.",
- "built": [
- "src/lib/recipe.ts: shapeOf, shapeOfRecipe, shapeWords, rankSkills, SUGGEST_RULE (3 runs in 14 days) and the types for suggestions, history and fixes.",
- "shapeOf groups a chain by its sorted model ids, ops and chain slots. It ignores prompts, inputs and helper or eval rows, and counts several takes of one step once.",
- "src/server/recipes.ts, sweepSuggestions and skillSuggestions: chains are linked by depends_on and also by a result handed on by hand (its output file is the next step's input). This makes hand-made composer chains count, because the brief's depends_on alone would miss them; the links match how W2's linkByFile builds recipes.",
- "The sweep counts only the owner's own runs and leaves out skill runs, canceled rows and trashed rows. It runs at most once a day and its result is cached in the settings row skills.suggestions (JSON; no migration). That row also holds dismissals and 'Not now' put-offs (7 days).",
- "Shapes that a saved recipe skill already has are filtered out when the list is read.",
- "dismissSuggestion handles 'Don't suggest this' and 'Not now'.",
- "skillHistory: runs grouped by the skill.run stamp, with run count, success rate, spend, last run, favourites and the last 10 runs; the skill's own dry runs are left out.",
- "stepFixes: a step is flagged when it failed in 2 of its last 5 finished runs, was moved by REPLACED_BY, or is switched off. Candidates come from offeredModels(modelsFor) (same op and kind, switched on), each priced as the whole run would be, marked demo when that price is a placeholder.",
- "applyFix: takes only an offered candidate, runs W1's plan check and free dry run, then saves. Nothing is ever swapped automatically.",
- "src/server/skill-uses.ts: skillUses(), use counts per skill, cached for 60 seconds. It is a separate module to avoid an import cycle with assist/tools.",
- "New routes: GET/POST /api/assist/skills/suggestions (a guest or account gets {items: []}; POST is owner-only through isAssistChange), GET /api/assist/skills/[name]/history, and GET/POST /api/assist/skills/[name]/fixes. 'suggestions' is now a reserved skill name (skills.ts RESERVED and the builder's freeName).",
- "Assist: chatFacts ranks the SKILL_INDEX list with rankSkills, using the chat's word match (new optional ChatInfo.words), use count and recency. list_skills ranks the same way.",
- "UI: the 'Save it as a skill?' card in the Library's All view, under the filters (owner only, full width at 390 px): Make a skill opens the W2 builder with the newest run's rows; Not now and Don't suggest this hide it; it says when it was made from demo results. In src/components/skills/skill-suggestion.tsx.",
- "UI: the History section under Files in the skill dialog, and 'Suggest a fix' on the 'Needs a re-check' line with a dialog that prices each candidate and runs Check and save. In src/components/assist/skill-upkeep.tsx; skills-view.tsx has only small edits.",
- "Library: a /library?batch=<id> filter with a 'One run' chip. FeedFilter.batchId was added, plus its matchesFilter and filterToSearch handling.",
- "Evaluation: `pnpm eval:from-skill <name>` (scripts/eval/lib/from-skill.mjs plus a from-skill command in eval.mjs) writes scripts/eval/local/cases/skill-<name>.json. It has one case per engine, submitted to the skill's run and estimate routes with the recipe's examples (fixtures for a demo run or a missing example); the recipe's checks go into the case note, and metrics are chosen by output kind.",
- "The harness's routeResult and price() now read a skill run's answer and estimate. The usage line in bin/lib/commands.mjs, docs/cli.md and scripts/eval/README.md (new 'Saved skills' section) are updated."
- ],
- "tests": [
- "New tests/skill-suggest.test.ts (9 tests, passing): one shape for the same chain with different prompts and inputs; helper and eval rows ignored; the 3-in-14-days threshold; hand-made chains count; account runs left out; the demo flag; the once-a-day sweep; Not now and Don't suggest this; no suggestion for a shape a saved skill has; trashed rows; the reserved name.",
- "tests/recipes.test.ts: 25 tests passing. 4 new: history from the skill stamp; fix candidates for a switched-off step share op and kind, are switched on, and save after the checks; a fix offered after 2 failed runs; ranking puts the used skill first, and list_skills and the context index follow it.",
- "New tests/eval-from-skill.test.ts (3 tests, passing): the command writes the suite and the harness runs it end to end on the demo provider through the skill's routes.",
- "Targeted runs passing: public-signup and public-signup-visitors (50; new routes added to both files), assist-skills, assist-skill-tools, recipe-builder and recipe (98), the library tests (71), eval-harness, eval-api and the CLI tests (125).",
- "Typecheck (after next typegen) and eslint on the changed files are clean.",
- "Browser: tests/e2e/skills-upkeep.mjs against pnpm dev in demo mode passed every check at 1440 and 390 px, light and dark: the card (text, demo note, three buttons, full width on a phone, absent outside All), the History section, no sideways scroll, and no console errors. The flows also passed: History's Open link leads to the 'One run' Library view, Make a skill opens the builder, Suggest a fix saves a new model, and Not now hides the card for good. The dev server was stopped and .next deleted.",
- "Full Vitest run (--maxWorkers=2) was still running when the report was requested, so it has no final count. So far only tests/split-soundtrack.test.ts has failed, 1 test, which is on the list of known failures from main."
- ],
- "left": [
- "Finish the full Vitest run: only a partial result was in when this report was written.",
- "A skill whose recipe runs a studio tool (dub, Katana, Captions) is not measured by eval:from-skill, and such a recipe has no shape, so it never hides a suggestion.",
- "The sweep reads at most 5000 rows from the 14-day window.",
- "Use counts and the sweep use json_extract on generations with no index. This is fine at current sizes; a large install may want an index (a migration).",
- "The suggestions list is fixed for the day once the Library has opened; a fresh sweep is available server-side but has no button.",
- "A Re-check does not refresh the fixes list, only Check and save does.",
- "The Suggest a fix dialog was checked in the browser only at 1440 light."
- ],
- "docsNotes": [
- "ARCHITECTURE: add Skills W6. That covers lib/recipe.ts (shapeOf, shapeOfRecipe, rankSkills, SUGGEST_RULE) and server/recipes.ts (sweep, suggestions, history, fixes).",
- "It also covers server/skill-uses.ts, the routes /api/assist/skills/suggestions and /api/assist/skills/[name]/{history,fixes}, components skills/skill-suggestion.tsx and assist/skill-upkeep.tsx, and the Library's ?batch= filter.",
- "'suggestions' is now a reserved skill name next to upload, new and draft (the ARCHITECTURE line names only 'draft').",
- "The skills.suggestions settings row holds the dismissed shapes, the put-offs and the day's sweep.",
- "Public sign-up: suggestions answer {items: []} to guests and accounts; history and fixes are closed to them (401 or 403); POST suggestions and POST fixes answer assist-owner.",
- "STATUS: W6 is built, and verified in demo mode and the browser; there was no live-model or GPU run of eval:from-skill.",
- "docs/cli.md and scripts/eval/README.md are already updated."
- ],
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "file": "src/server/recipes.ts",
- "line": 565,
- "title": "Suggest a fix also blames the steps after the one that failed",
- "detail": "stepTrouble counts a step as failing when any row in the run with the same model id failed. When a step fails, advanceDependents fails every step waiting on it with \"An earlier step didn't finish\" (generations.ts waitedOnFailure), so those downstream steps are flagged too and the user is offered model swaps for steps that never ran. The match is also by model id rather than by the row's own `step` stamp (request_json.step, which compileRun writes), so two steps on the same model are both blamed for one step's failure.",
- "verified": "A scratch vitest (deleted afterwards) used a 2-step skill (cut: birefnet-cloud → place: gpt-image-2) with 2 runs. In each run only 'cut' really failed and 'place' failed with \"An earlier step didn't finish\". stepFixes returned [[\"cut\",\"…failed in 2 of the last 2 runs\"],[\"place\",\"GPT Image 2 failed in 2 of the last 2 runs\"]]. The new recipes.test case only inserts failures of the last step, so it misses this.",
- "fix": "Count failures per step key (json_extract '$.step') and leave out rows whose error is waitedOnFailure(). Add a test with an upstream failure."
- },
- {
- "severity": "medium",
- "file": "src/server/recipes.ts",
- "line": 336,
- "title": "Failed or still-running chains count toward a suggestion, and Make a skill can be handed one",
- "detail": "The sweep keeps every status except 'canceled', and the suggestion's ids are the newest run's rows whatever their status. A failed attempt therefore counts as one of the '3 times'. If the newest chain has a failed row or is still running, Make a skill opens the builder with it, and the builder refuses that step (\"It didn't finish, so there's nothing to repeat\" / \"It's still running\"). The user sees the card and clicks Make a skill, and the step they wanted is missing or refused. The newest run should be the newest chain that fully succeeded, and only succeeded chains (or at least only those with a succeeded leaf) should count.",
- "verified": "A scratch vitest (deleted afterwards) made 3 finished chains plus a 4th, newer chain whose last row failed. skillSuggestions gave count 4 with ids = the failed chain. draftFromGenerations(ids) returned refusals [{id:'rv-b3…', reason:\"It didn't finish, so there's nothing to repeat\"}].",
- "fix": "Base the count on chains whose rows all succeeded (or skip failed rows) and pick ids from the newest succeeded chain. Add a test."
- },
- {
- "severity": "low",
- "file": "src/server/assist/agent.ts",
- "line": 1334,
- "title": "Assist's context index never uses word match: ChatInfo.words is never passed",
- "detail": "The brief asks for both list_skills and the context index to be ranked by word match, use count and recency. chatFacts now calls rankSkills with query c.words, but the only caller (contextFor in agent.ts) never sets `words`. The context index is therefore ranked only by use and recency. The implementer's report claims it uses the chat's word match.",
- "verified": "grep: chatFacts( is called only in agent.ts:1334, without words. The recipes.test check also calls chatFacts without words.",
- "fix": "Pass the thread's first user message (or title) as words in contextFor, and add a test where a word-matching skill outranks a used one in the index."
- },
- {
- "severity": "low",
- "file": "src/components/assist/skills-view.tsx",
- "line": 296,
- "title": "A failing-history reason shows as 'Needs a re-check', which a Re-check can't clear",
- "detail": "The why texts from fixes (e.g. 'X failed in 2 of the last 5 runs') are merged into the recheck list. The line then reads 'Needs a re-check: …' with a Re-check button. A passing demo re-check doesn't change the run history, so the line stays until more successful runs push the failures out, and the fixes query isn't refreshed after a Re-check (the implementer's 'left' list notes this).",
- "verified": "Traced: recheck = [...v.recheck, ...fixes.map(f => f.why)]. useRecipeActions().verify doesn't invalidate ['assist-skill-fixes', name].",
- "fix": "Show failing-step reasons with their own wording (e.g. 'Keeps failing: …') next to Suggest a fix, and invalidate the fixes query after verify."
- },
- {
- "severity": "low",
- "file": "src/server/recipes.ts",
- "line": 548,
- "title": "applyFix drops a step's pinned engine",
- "detail": "withModel deletes request.engine on the swapped step. A step pinned to one engine of a dual-engine model (e.g. kept on the open engine for its LoRAs or custom nodes) loses that pin after a fix, so the skill may now also run, or be priced, on the cloud. This only matters when the pick is a dual-engine model. Keeping the engine when the new model supports it would follow the each-engine-does-all-it-can rule.",
- "verified": "Read the code; no test covers it.",
- "fix": "Keep request.engine when the candidate supports that engine."
- },
- {
- "severity": "info",
- "file": "docs/handoff (report)",
- "line": 0,
- "title": "Report accuracy: 6 commits, not 7",
- "detail": "claude/fuobe-parity-4..o/w2s-w6 has 6 commits, all signed (gpgsig present), with neutral messages. The report says 7.",
- "verified": "git rev-list",
- "fix": "None needed in code."
- }
- ],
- "checks": [
- "Read main-rules.md, the review prompt and the implementer's report. Reviewed git diff claude/fuobe-parity-4...o/w2s-w6 (29 files) with the code around it: recipes.ts sweep, suggestions, history and fixes; lib/recipe.ts shapeOf and rankSkills; skill-uses.ts; the 3 new routes; guest-access/proxy behaviour; library-view, skill-suggestion, skill-upkeep and skills-view; the eval from-skill script and the run.mjs changes.",
- "Base is up to date: merge-base equals claude/fuobe-parity-4 (03e49f2d). No hot or off-limits files touched, no migration, no analytics, no Higgsfield code or media. Commit messages are neutral and signed.",
- "Public sign-up: GET /api/assist/skills/suggestions goes through the proxy as a guest skill path and the route answers {items: []} for guests and accounts. GET history and fixes are refused to visitors (401 for guests, 403 for accounts). The POSTs are assist-owner through isAssistChange. The sweep, history and use counts leave out rows that carry $.account. No new run path or file read for accounts. The owner-only fixes pricing is not a visitor price check.",
- "Scratch vitest (deleted): a suggestion made from 3 demo createPipeline chains → draftFromGenerations(newest ids) → saveDraft → the suggestion disappears (PASS: the builder's recipe has the same shape as the sweep's).",
- "Scratch vitest (deleted): newest chain failed → Make a skill ids refused by the builder (finding 2). Upstream failure → downstream step also offered a fix (finding 1).",
- "Targeted: skill-suggest, recipes, eval-from-skill, public-signup and public-signup-visitors: 5 files, 87 tests passed.",
- "npx next typegen && tsc --noEmit: exit 0. eslint on the changed ts/tsx/mjs files: exit 0.",
- "Browser: ran tests/e2e/skills-upkeep.mjs against pnpm dev (FUOBE_DEMO_MODE=on, fresh data dir, http://localhost:3417). All checks passed at 1440 and 390 px, light and dark, and in the flows (Open → One run, Make a skill, Suggest a fix saved, Not now), with no console errors. Looked at the screenshots of the 390-dark card and the Suggest a fix dialog. Server stopped (fuser -k) and .next deleted.",
- "Full Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 5493 passed, 6 failed, 4 skipped. All 6 failures are on the known list from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2) and split-soundtrack.",
- "Worktree left clean (scratch tests removed, no edits or commits)."
- ],
- "verdict": "changes-requested: The package is mostly sound and complete against the brief. Suggestions, history, Suggest a fix, Assist ranking, eval:from-skill and the batch filter are built, sign-up rules hold, and typecheck, lint, the browser checks and the full suite are clean apart from failures already known on main. Two verified medium bugs should be fixed before merge: (1) Suggest a fix blames steps that only failed because an earlier step did (match by step key, skip waitedOnFailure rows); (2) failed or running chains count toward a suggestion and can be the rows Make a skill is handed, which the builder then refuses. Also wire ChatInfo.words in agent.ts so the context index really uses word match, as the brief asks."
- },
- "fix": {
- "applied": [
- "Finding 1 (medium): Suggest a fix blamed downstream steps. Each pipeline step's stamp now carries its recipe step key (request_json skill.step, set in compile() in src/lib/recipe.ts, type in src/lib/catalog/types.ts). stepTrouble (src/server/recipes.ts) counts a failure only on the step that made the row, and leaves out failures an earlier step caused (waitedOnFailure, or 'An earlier step …' shortfalls). Older rows without a step key still match by model id. New test in tests/recipes.test.ts: with cut-out ok, scene failed and spin failed by 'An earlier step didn't finish', only 'scene' is offered a fix.",
- "Finding 2 (medium): failed or running chains counted, and Make a skill could get them. The sweep now reads every status. It skips a chain that still has a queued or running row, and a chain with a failed or canceled step that wasn't made again (a retry with the same model and op). A counted chain's shape and ids are its succeeded rows only. New test in tests/skill-suggest.test.ts covers failed last step, failed first step, canceled, running and queued chains (none count), the newest succeeded chain's ids, and a retried chain counting with its working rows.",
- "Finding 3 (low): ChatInfo.words was never passed. contextFor in src/server/assist/agent.ts now passes the chat's first user message (firstWords). rankSkills now splits on punctuation and ignores a small set of common words, so a whole sentence doesn't match every skill. New test: a skill that matches the words outranks the most used one in the context index, and common words alone change nothing.",
- "Finding 4 (low): a failing-history reason showed as 'Needs a re-check'. StepFix has a new 'failing' flag. skills-view shows such a reason as 'Keeps failing: …' with Suggest a fix (no Re-check button for it). Replaced and switched-off reasons stay on the re-check line. useRecipeActions().verify now invalidates ['assist-skill-fixes', name].",
- "Finding 5 (low): applyFix dropped a pinned engine. withModel keeps request.engine when the new model is dual-engine and runs on that engine; otherwise it drops it as before. New test: a fuobe-soul step pinned to the open engine is switched off, fixed to fuobe-soul-hd, and stays on the open engine.",
- "Tests updated for the new stamp field: tests/recipe.test.ts and tests/recipes.test.ts expect {name, run, step}."
- ],
- "rejected": [
- "Finding 6 (info, the report said 7 commits but there were 6): this is report accuracy only, with no code change. The branch now has 7 commits, counting this fix."
- ],
- "checks": [
- "Worktree /home/user/wt/o-w2s-w6 on o/w2s-w6: clean at start, claude/fuobe-parity-4 is an ancestor, and it holds only this package's commits.",
- "Confirmed findings 1, 2, 3 and 5 by reading the code (stepTrouble matched by model id; the sweep kept failed and running rows; contextFor did not pass words; withModel deleted engine). Finding 4 was confirmed in skills-view and hooks.",
- "npx next typegen, then tsc --noEmit (NODE_OPTIONS=--max-old-space-size=6144; the default heap ran out of memory): exit 0.",
- "eslint on the changed files: exit 0.",
- "Targeted Vitest (FUOBE_ACCOUNT_DISK_FREE_GB=1, --maxWorkers=2): 12 files, 267 tests passed. Files: assist-context, assist-schedules, assist-skill-tools, assist-skills, cli-run, recipe, recipes, skill-suggest, recipe-builder, eval-from-skill, public-signup and public-signup-visitors. The full suite was not run, as instructed (the orchestrator runs it).",
- "Browser: tests/e2e/skills-upkeep.mjs passed every check against next dev on http://localhost:3418 (FUOBE_DEMO_MODE=on, fresh data dir). That covers 1440 and 390 px, light and dark: the card, History, no sideways scroll, Make a skill, Suggest a fix saved, Not now, and no console errors. Server stopped, .next deleted, scratch data dir removed.",
- "Commit ae6e4911 is signed and pushed to origin/o/w2s-w6. git status is clean.",
- "After merging the latest claude/fuobe-parity-4 (clean, no conflicts): next typegen, typecheck and lint exit 0; full Vitest 5635 passed, 6 failed, 4 skipped. The 6 failures are all known from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack."
- ],
- "finalSummary": "Skills W6 on o/w2s-w6 now has fixes for the review's two medium findings and three low findings. (1) Suggest a fix blames only the step that failed: each run's rows record their recipe step, and failures caused by an earlier step are ignored. (2) A suggestion counts only finished chains that worked (a retried step counts), and Make a skill gets the newest such chain's rows, which the builder accepts. (3) Assist's skills index ranks the skills that match the chat's first words first, ignoring common words. (4) A step that keeps failing says 'Keeps failing: …' next to Suggest a fix, not 'Needs a re-check', and a Re-check refreshes the fixes list. (5) A fix keeps a step on the engine it was kept on when the new model runs there. Engines: all of W6 is server-side logic and UI. Suggestions, history, fixes and ranking work on both engines' rows and on demo rows. Fix candidates are priced on whichever engine's plan check passes (the open engine is free). A pinned open-engine step keeps its LoRA and custom-node capability after a fix. Verified: in demo mode only, by unit tests and the browser script. No GPU or key run (eval:from-skill against a live model still needs one). Public sign-up is unchanged from the implementation: guests and accounts get {items: []} from suggestions; history and fixes are refused to them (401/403); POSTs are owner-only. The sweep, history and use counts leave out account rows.",
- "left": [
- "The full Vitest suite was not run in this stage (the orchestrator runs it).",
- "The 'Keeps failing: …' wording is covered by unit tests only: the browser script doesn't make failing runs.",
- "Rows made before this fix have no step key, so their failures still match by model id. Downstream 'An earlier step' failures are now ignored for them too.",
- "Carried over from the implementation: tool recipes have no shape and eval:from-skill doesn't measure them; the sweep reads at most 5000 rows; json_extract on generations has no index; there is no button for a fresh sweep; Suggest a fix was browser-checked at 1440 light only.",
- "Docs pass: also note request_json skill.step (the recipe step key) next to the skill stamp in ARCHITECTURE."
- ],
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/w2s-w6"
- ],
- "notMerged": [],
- "conflicts": "none (overlaps with W5 auto-merged)",
- "checks": "batch of 6 (dbs-d9, idol-7, w2s-w5, w2s-w6, w2s-w7, idol-4): typecheck 0, lint 0, vitest 5907 passed, 8 failed (6 main known + preset-covers and reuse-pack-pin load timeouts, 13/13 alone); each merge but idol-4 checked by an independent verifier (idol-4 merged by hand after: one conflict, its tests 99/99); W5/W6/W7 joined by follow-ups 642a167e, bef8778e, 22378b4b, 739a0c1d",
- "pushed": true,
- "head": "148f2459"
- }
-}
diff --git a/docs/handoff/reports/w2s-w7.json b/docs/handoff/reports/w2s-w7.json
deleted file mode 100644
index 9e71cf49..00000000
--- a/docs/handoff/reports/w2s-w7.json
+++ /dev/null
@@ -1,107 +0,0 @@
-{
- "key": "w2s-w7",
- "impl": {
- "branch": "o/w2s-w7",
- "summary": "Skills W7 built on o/w2s-w7 (worktree /home/user/wt/o-w2s-w7, 8 commits, not pushed). A skill can now span studios: recipe version 2 puts {{steps.<key>.output}} in a step's input, tool steps can go anywhere in the order, and each run is kept in a new skill_runs table that a 10 s sweep moves forward. For example a dub, then captions, then a 9:16 cut each start by themselves when the step before finishes. If a step fails, the steps after it fail too and the run says which step failed and why. Studio dry runs now exist: runAsDemo/inDemoScope on AsyncLocalStorage, chooseRoute returns the demo route inside that scope and createGenerations marks the rows request.demo. After a check, what it made goes to the Trash and the studio records it opened are deleted. Save as skill now writes cross-call studio references as step references instead of refusing them. The run's result names the run and the steps that wait, everywhere a skill runs: the Run toast ('See progress'), run_skill, schedules (they go through run_skill) and the CLI (--wait follows the run). The skill dialog has a Runs section showing 'Dub · done → Captions · running → 9:16 cut · waiting' with 'Open in <Studio>'. Already there from earlier packages: W1's runner, checks and Run dialog; W3's run_skill and draftFromThread; W4's schedules and CLI; the request.demo flag with forceDemo in chooseRoute and chainMode; stampRequests; createPipeline's existing option.",
- "built": [
- "src/lib/recipe.ts: fuobeRecipe 1|2 (RECIPE_VERSION 2); stepRef/refKey/stepRefs/fieldKind/TOOL_MAKES/isStaged/recipeParts/fillRefs; recipeProblems takes {makes} and checks references: must point at an earlier step, fill the whole field, fit the field's kind; a generate step can't use `after` on a studio step; a dub feeding a later step needs review:false; parts can't loop; v1 keeps the rule that a tool step stands alone. compile() returns kind 'staged' with parts; recipeMarkdown handles staged recipes; RecipeRun gains run/waiting; SkillRunStep/SkillRunView/runLine types",
- "src/server/demo-scope.ts (new): runAsDemo, inDemoScope; hooked into chooseRoute and createGenerations (src/server/generations.ts)",
- "src/server/skill-runs.ts (new): startSkillRun, advanceSkillRun (settle, fail what waits, start ready parts through createPipeline or executeTool, stamp studio rows), getSkillRun, listSkillRuns, discardSkillRun (trashes rows plus their batch mates; deletes dub, Layers, Shorts, Faceless episode and Katana records), stopSkillRun, sweepSkillRuns, ensureSkillRunSweep (started in src/instrumentation.ts)",
- "src/server/recipes.ts: compileRun/planRun/planHash/asDemo/planCheck handle staged recipes. Each part is priced with stand-ins for references; a video-to-video studio step is priced on the clip it takes. Tool plans whose only error is 'connect a provider' are re-planned inside runAsDemo. runRecipe starts one skill run per row. The demo check now runs studio dry runs, for a single-tool recipe as well. The real check follows a staged run",
- "src/server/recipe-builder.ts: draftFromThread no longer refuses (STUDIO_WAIT removed); linkStudios writes step references, and in a chat draft tool steps can sit beside other steps (v2). The Library builder is unchanged (still one studio step per skill)",
- "src/server/db.ts: one appended migration (the last entry, 27 after 26 assist_schedules.skill_json): skill_runs(id, skill, status, values_json, state_json, created_at, updated_at) plus indexes. skill_runs values_json/state_json added to ASSET_REFS",
- "GET /api/assist/skills/[name]/runs (src/app/api/assist/skills/[name]/runs/route.ts)",
- "UI: src/components/assist/skill-runs.tsx (new Runs section, polls every 3 s while a run is going), mounted in skills-view.tsx SkillDetail for the owner with one line; the Run toast in run-skill-dialog.tsx says which steps wait, with 'See progress'",
- "run_skill (src/server/assist/skill-tools.ts): each run's result includes run and waiting, and a note telling the agent not to start the waiting steps itself",
- "CLI bin/lib/commands.mjs: skills run names the steps that wait and the progress URL; --wait/--out poll the runs route until the run ends, then wait for and save every step's results; docs/cli.md updated",
- "Docs: ARCHITECTURE.md migration row 27 and a 'Skills that span studios' bullet; skills/README.md describes v2; docs/handoff/verify.sh DEMO_CHECKS gains skills-span",
- "Browser check tests/e2e/skills-span.mjs"
- ],
- "tests": "New tests/skill-runs.test.ts (8 tests, pass): v2 problems and parts; compile and fillRefs; dub → captions → reframe in demo mode starts the dub, waits, then the rest, each step taking the one before's video, all stamped; run_skill result names the run and the waiting steps; a failed dub fails the rest ('Dub failed: No speech found in the clip', the others 'Didn't start: … failed'); state survives a restart (vi.resetModules, then the run finishes from skill_runs); runAsDemo runs add_captions on mock with Demo mode off; the studio dry run with Demo mode off passes, deletes the dub session, leaves no skill_runs row, and everything it made is in the Trash. Updated and passing: recipe.test (v2 loads), recipes.test (a tool recipe's check now does a studio dry run), assist-skill-tools.test (a generate result going into captions and a dub going into captions become step references), cli-run.test (new test for a run that spans studios: --wait/--json), public-signup.test (the runs GET is refused for guests (401) and accounts (403); POST run is refused for accounts), plus library, recipe-builder, mcp and assist-skills, all passing. Typecheck (NODE_OPTIONS=--max-old-space-size=8192 tsc --noEmit) and eslint on the touched files are clean. Browser: tests/e2e/skills-span.mjs passes every check at 1440 and 390 px, light and dark, on pnpm dev -p 3471 with FUOBE_DEMO_MODE=on: seed, free check, priced form, run from the form, the toast, See progress, the Runs section moving on its own to every step done, Open in Translate & dub and Open in Captions, no sideways scroll, no console or page errors. Screenshots were looked over; the server is stopped and .next and the data folder deleted. The one full vitest run (FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2, log /tmp/claude-0/w7-vitest.log) was still running when this report was asked for, so its result isn't known yet.",
- "left": "Read the full vitest result in /tmp/claude-0/w7-vitest.log; failures already known on main are listed in the rules. createPipeline's `existing` option was not used (later generate steps wait for the sweep), so that guess is still untested. The sweep runs every 10 s (the brief's model ran every 30 s), so a later step can start up to 10 s after the step before it finishes. Things that need real keys or a GPU: nothing has run with a paid key or on a GPU. Dry-run cleanup keeps the Ads brand kit a create_ads step makes from a brief and the shared Faceless 'Assist' channel; it deletes the episode. During a dry run the studio rows briefly appear in the Library before they go to the Trash (they aren't the hidden skill-check feature). A dub that feeds a later step must dub in one go (review:false): on the open engine the studio refuses that and the tool's own Library pipeline runs instead. The Library builder (W2) still makes one studio step per skill; only chats span studios. No new ComfyUI graph, node pack, studio or tool, so no pre-flight changes.",
- "docsNotes": "STATUS.md: add a row or line for Skills W7: skills that span studios; recipe v2 {{steps.<key>.output}}; the skill_runs table (migration 27, the integrator may renumber); 10 s sweep; Runs in the skill dialog; studio dry runs now also run for single-tool recipes, replacing W1's 'plan only'; Save as skill turns cross-call studio references into step references; checked in demo mode only (tests/skill-runs.test.ts, e2e skills-span.mjs). DEVELOPMENT.md and STATUS.md e2e lists: add `node tests/e2e/skills-span.mjs [url]` (demo mode, ComfyUI unreachable). ARCHITECTURE.md line 464 ('Checked …') still says run_skill doesn't exist yet; that predates this package. Add /api/assist/skills/[name]/runs to the Assist row of the route table.",
- "blocked": ""
- },
- "review": {
- "findings": [
- {
- "severity": "medium",
- "title": "CLI --wait/--out never finishes for a CSV of more than 8 staged rows: the runs route only returns a skill's 8 newest runs",
- "where": "bin/lib/commands.mjs waitRuns (mine.length === runIds.length); src/app/api/assist/skills/[name]/runs/route.ts calls listSkillRuns(name) with its default limit 8 (src/server/skill-runs.ts listSkillRuns)",
- "detail": "RECIPE_LIMITS.rows is 50 and runRecipe starts one skill_runs row per CSV row. `fuobe skills run <staged skill> --rows file.csv --wait` with 9+ rows polls GET /api/assist/skills/<name>/runs, which never lists more than 8 runs, so `mine.length === runIds.length` is never true. The CLI waits until --timeout (30 min by default) and exits with EXIT.timeout even though every run has ended, and it never saves the earlier rows' outputs with --out. The same happens with 8 rows or fewer when another run of the same skill (a schedule, the Run dialog) starts while it waits and pushes one out of the newest 8. Verified by tracing; no test covers more than one run (tests/cli-run.test.ts has one staged run).",
- "fix": "Let the route take ?ids= (or a limit up to RECIPE_LIMITS.rows) and have waitRuns ask for its own run ids, or add GET /api/assist/skills/[name]/runs/[id]; add a CLI test with more than 8 rows."
- },
- {
- "severity": "medium",
- "title": "faceless_episode is declared to make a video, but its tool result names only the stills, so a step that takes its output always fails and the episode step reads 'done' too early",
- "where": "src/lib/recipe.ts TOOL_MAKES.faceless_episode = 'video'; src/server/assist/studio-routes.ts facelessRoute.run returns ids: stills.slice(0, 8); src/server/skill-runs.ts startPart/settle/outputOf",
- "detail": "recipeProblems accepts {faceless_episode} -> {add_captions video: {{steps.ep.output}}} (checked: recipeProblems returns []). At run time the part's ids are the episode's stills (images), so settle() marks the Faceless step done once those pictures finish, while the episode is still animating and mixing in stage two. outputOf(key, 'video') then finds no video and fillRefs throws '“ep” made no video for the next step', so every later step fails after stage one has been paid for. The Runs section also shows 'Faceless Studio · done' while the episode is still rendering. A dry run would catch it (the later step fails, so the check fails), but the format promises a combination it can't run, and a single-step faceless recipe's new studio dry run passes after the stills only and then deletes the episode mid-render. Related: Faceless's stage two is created by its own 2 s sweep outside the runAsDemo scope, so in a dry run with Demo mode off it could start for real if that sweep beats the discard.",
- "fix": "Either drop faceless_episode from TOOL_MAKES (refuse a reference to it in refProblems) or track the episode, so the part settles on the episode's final generation, and carry the demo mark into stage two."
- },
- {
- "severity": "low",
- "title": "The demo scope isn't left by outsideRuns, so a long-lived timer first started inside a dry run would route every later run on the install to the demo provider",
- "where": "src/server/demo-scope.ts; src/server/generations.ts outsideRuns/ensureRunner (outsideTenant/outsideOwnGpu/withoutCandidates only)",
- "detail": "ensureRunner wraps startRunner in outsideRuns precisely so an AsyncLocalStorage scope isn't captured by the runner's setInterval, but outsideRuns doesn't leave the new demo scope. getGeneration/createGenerations call ensureRunner. If the runner (or its fastTimer after a dev hot reload) is first created inside runAsDemo, every later tick, including advanceDependents re-planning other runs' waiting steps through chooseRoute, would see inDemoScope() true and run as demos. In production src/instrumentation.ts starts the runner at boot, so this is latent (tests and the hot-reload path are where it could bite).",
- "fix": "Have outsideRuns (or ensureRunner) also run outside the demo scope (for example scope.exit), and do the same for ensureSkillRunSweep."
- },
- {
- "severity": "low",
- "title": "A 'free' studio dry run with Demo mode off can still call the install's LLM and leave records behind",
- "where": "src/server/assist/studio-routes.ts adsRoute.run -> createManualBrand -> llmText (src/server/brand.ts), ads copy (src/server/ads.ts); faceless askLlm and restore.ts check getSetting('demoMode') directly",
- "detail": "runAsDemo only changes chooseRoute and createGenerations. LLM helpers (llmText goes to Claude when an Anthropic key is set) don't look at inDemoScope, so the new dry run of a create_ads step (now run for single-tool recipes too, replacing W1's plan-only check) makes paid Claude calls and keeps the brand kit it made. The implementer noted the kit; the LLM spend isn't noted, and the docs call the check free.",
- "fix": "Make llmText/askLlm return null (offline wording) inside the demo scope, or skip studio dry runs whose tool writes with an LLM; say it in the notes."
- },
- {
- "severity": "low",
- "title": "Docs: ARCHITECTURE.md's Checks bullet still says 'Tool steps get the plan check only'",
- "where": "docs/ARCHITECTURE.md (Checks bullet, line ~460)",
- "detail": "W7 now runs a studio dry run for tool steps too. The new W7 bullet says so, but the older sentence contradicts it. Left for the docs pass along with the implementer's docsNotes.",
- "fix": "Update that sentence in the docs pass."
- }
- ],
- "checks": [
- "Read the stage prompt, binding rules and implementer report; reviewed git diff claude/fuobe-parity-4...o/w2s-w7 (7 commits, 25 files) with the surrounding code (generations.ts chooseRoute/createGenerations/runner, studio-routes.ts, studio-tools.ts, faceless.ts, ads/brand LLM paths, guest-access.ts).",
- "Public sign-up: GET /api/assist/skills/[name]/runs isn't matched by GUEST_SKILL and is refused for guests (401) and accounts (403) per tests/public-signup.test.ts. POST run is refused for accounts. Assist changes are owner-only (so no run_skill for accounts), and the sweep only advances owner runs. The estimate route still goes through priceAs, and planCheck/runAsDemo is only on the owner's verify path. No new file-reading path for account runs. No issues.",
- "Migration appended as the last entry after 26; skill_runs values_json/state_json in ASSET_REFS. No ComfyUI graph, node pack, model, LoRA or Higgsfield usage added; no pre-flight changes needed.",
- "Verified with node --experimental-strip-types that recipeProblems accepts faceless_episode -> add_captions via {{steps.ep.output}} (returns []).",
- "Targeted vitest: tests/skill-runs.test.ts, tests/public-signup.test.ts, tests/recipe.test.ts: 3 files, 75 tests passed.",
- "The implementer's full run log (/tmp/claude-0/w7-vitest.log) stopped after its header (no vitest process was left), so I ran the one full suite: FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2. Result: 341/346 files, 5485 passed, 6 failed, 4 skipped. All 6 failures are known from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack.",
- "eslint on the touched source files (skill-runs, demo-scope, recipes, recipe, recipe-builder, skill-runs.tsx, run-skill-dialog.tsx, runs route, bin/lib/commands.mjs): clean.",
- "UI read-through: skill-runs.tsx wraps at 390 px (flex-wrap, truncate, max-w-full), the links are real <Link> elements reachable by keyboard, and icons are aria-hidden with the status also in words. tests/e2e/skills-span.mjs fails on any console or page error and doesn't filter hydration errors. I didn't re-run the browser check (no server started)."
- ],
- "verdict": "approve-with-fixes: the core works and is tested (staged runs, the sweep, surviving a restart, the failure cascade, demo-scope dry runs, Save as skill linking, public-sign-up refusals), and the full suite shows only failures known from main. Fix before merge: the CLI --wait limit of 8 runs (medium) and faceless_episode's TOOL_MAKES 'video', whose result is only stills (medium). The rest are low."
- },
- "fix": {
- "applied": [
- "Medium, confirmed (traced: the route always returned listSkillRuns(name) with limit 8, so waitRuns' mine.length === runIds.length could never hold for 9+ rows). GET /api/assist/skills/[name]/runs now takes ?ids=a,b (up to RECIPE_LIMITS.rows = 50, else 400) and returns exactly those runs of that skill (listSkillRuns(skill, limit, ids)). Without ids it still lists the newest 8. The CLI's waitRuns asks for its own run ids, so other runs starting meanwhile can't push them out. Tests: a new tests/cli-run.test.ts case with a 9-row staged CSV, where the fake server returns only the newest 8 without ids (this would time out before the fix), and a new tests/skill-runs.test.ts route test covering 12 runs (newest 8, 10 asked by id, another skill's id left out, 51 ids → 400). Commit e02e0375.",
- "Medium, confirmed (facelessRoute.run returns only the stills as ids). Added OUTPUT_NOT_HANDED_ON in src/lib/recipe.ts (faceless_episode) and removed faceless_episode from TOOL_MAKES. recipeProblems now refuses a step that takes a Faceless episode's output, saying why. linkStudios (Save as skill) keeps such a file as the literal file instead of a step reference. The studio dry run leaves out Faceless parts: their plan is the check again, as in W1, reported as skipped, so no dry-run date is stamped and no episode is started or deleted mid-render. That also removes the risk that stage two escapes the demo scope during a check. Other parts of the recipe still dry-run. Tests: the recipeProblems refusal, and verifyRecipe on a faceless recipe gives dryRun.skipped with no faceless_episodes row created. Commit c4782e28.",
- "Low, confirmed. New outsideDemo(fn) (scope.exit) in src/server/demo-scope.ts. outsideRuns (and so ensureRunner) now also runs outside the demo scope, and ensureSkillRunSweep creates its setInterval through outsideDemo. Test: inside runAsDemo, outsideDemo, outsideRuns and a timer started through outsideDemo all see inDemoScope() false.",
- "Low, confirmed. Inside runAsDemo, llmText (src/server/enhance.ts) returns null, so callers use their offline wording; Faceless askLlm and restore's writeRestorePrompt go offline too. A skill's free dry run (for example a create_ads step's brand kit and copy) no longer calls Claude or a local model. Test: llmText inside the scope returns null. This test is weak, because the test install has no LLM backend anyway.",
- "Low (docs). docs/ARCHITECTURE.md: the Checks bullet no longer says 'Tool steps get the plan check only'; it describes studio dry runs and the Faceless exception. The W7 bullet adds the Faceless reference rule, the runs route's ?ids=, and outsideDemo. skills/README.md says no later step takes a Faceless episode's output."
- ],
- "rejected": [
- "Part of the LLM-spend finding: 'leave records behind'. A create_ads step's dry run still keeps the brand kit it makes from a brief (createManualBrand), as does the shared Faceless 'Assist' channel. Deleting a brand kit the user might then reuse is riskier than keeping it, and the implementer had already noted it. It now costs nothing (no LLM call). Left as a note, not fixed."
- ],
- "checks": [
- "Worktree /home/user/wt/o-w2s-w7 on o/w2s-w7: only this package's own commits, and the base is an ancestor (no merge needed). pnpm install --frozen-lockfile --prefer-offline and npx next typegen: OK.",
- "Targeted vitest: tests/cli-run.test.ts 26/26 passed. tests/skill-runs, recipe, recipes, recipe-builder, assist-skill-tools and public-signup: 6 files, 142/142 passed.",
- "pnpm typecheck: exit 0. pnpm lint: exit 0 (0 errors, 5 warnings that were already there, in files this package didn't touch).",
- "Full suite, one run (FUOBE_ACCOUNT_DISK_FREE_GB=1 pnpm vitest run --maxWorkers=2, log /tmp/claude-0/w7fix-vitest.log): 341 of 346 files passed. Tests: 5490 passed, 6 failed, 4 skipped (5500). All 6 failures are known from main: comfy-reuse, dop-originals, preset-featured, soul-runs (2), split-soundtrack.",
- "No server started and no browser check re-run (no UI change). .next is absent and git status is clean. Two fix commits (e02e0375, c4782e28), not pushed."
- ],
- "finalSummary": "Skills W7 (skills that span studios) is done, with the review's fixes. Recipe v2's {{steps.<key>.output}}, staged runs in skill_runs moved on by a 10 s sweep, the failure cascade, surviving a restart, studio dry runs inside runAsDemo, Save as skill linking, the Runs section, run_skill/toast/schedule/CLI results that name the waiting steps, and CLI --wait (now for any number of rows). Fixed here: the CLI no longer waits forever on 9+ rows; a Faceless episode's output can't be referenced (its result is only the stills), and Faceless is checked by its plan only; the demo scope can't leak into long-lived timers; a dry run asks no AI helper. Engines: everything was verified in demo mode on the mock provider only (unit/integration tests, plus the implementer's browser check at 1440/390 px, light and dark). Cloud: the staged chain uses the same studio tools and hosted models as before, but nothing has run with a paid key. Open engine: same, nothing has run on a GPU. A dub feeding a later step must use review:false, which the open engine's studio refuses, so the tool's own Library pipeline runs there. Public sign-up: the runs route (GET, including ?ids=) and running skills belong to the owner. Guests are refused (401) and accounts are refused (403) by the proxy, as tests/public-signup.test.ts shows. The sweep only moves owner runs, and no new file-reading path exists for account runs.",
- "left": "Docs pass (STATUS.md / DEVELOPMENT.md): add the Skills W7 line, the e2e entry `node tests/e2e/skills-span.mjs [url]` and the runs route (with ?ids=) in the Assist route table. The ARCHITECTURE.md line about run_skill not existing yet predates this package. A single Faceless step in a staged run still shows 'done' in the Runs section once its stills finish, while the episode keeps rendering in Faceless Studio (it has an 'Open in Faceless Studio' link); tracking the episode's final generation is a possible follow-up. A create_ads dry run keeps the brand kit it made. createPipeline's `existing` option is still unused. Nothing has run with paid keys or on a GPU. Migration 27 (skill_runs) stays the last entry; the integrator may renumber it.",
- "blocked": ""
- },
- "merge": {
- "merged": [
- "o/w2s-w7"
- ],
- "notMerged": [],
- "conflicts": "recipe.ts compile() (W7 generate() helper + W6 step key), recipes.ts imports; migration skill_runs at index 27; follow-ups 642a167e, bef8778e, 22378b4b, 739a0c1d",
- "checks": "batch of 6 (dbs-d9, idol-7, w2s-w5, w2s-w6, w2s-w7, idol-4): typecheck 0, lint 0, vitest 5907 passed, 8 failed (6 main known + preset-covers and reuse-pack-pin load timeouts, 13/13 alone); each merge but idol-4 checked by an independent verifier (idol-4 merged by hand after: one conflict, its tests 99/99); W5/W6/W7 joined by follow-ups 642a167e, bef8778e, 22378b4b, 739a0c1d",
- "pushed": true,
- "head": "148f2459"
- }
-}