Unbake — Recipe from Image
Unbake a PNG back into a ComfyUI workflow
- prompt
- negative
- seed
- steps
- cfg
- sampler
- scheduler
- checkpoint
"You can't unbake a cake" - which is exactly what this node does anyway. Unbake - Recipe from Image is the single canvas node shipped by ComfyUI-Unbake, and its job is to take one picture and read the generation settings back out of it. Drop in a PNG that has metadata and it hands you the prompt, seed, steps, CFG and more that made it. Swap the image and the whole graph re-runs under that image's conditions.
That one property is why it exists. ComfyUI embeds the full workflow in its output PNGs - the metadata is the source code, not a footnote to it. So a file that kept its chunks is a recipe waiting to be read. That's the mechanism: the extraction happens in the browser, not in Python. web/unbake.js reads the PNG's prompt/workflow chunks - or fetches a Civitai image page and reconstructs from the API - and writes a flat bundle of values into the node's recipe field. The Python class is deliberately dumb: it just parses that bundle and coerces each value to the right type (the author's own design note says the extractor is not duplicated server-side).
The three inputs
Only three, and only one is sacred:
- image - a picker over your
input/folder; upload or select the PNG. The node accepts anything with readable generation metadata. - url - a Civitai image page URL or a ComfyUI output URL. If it's non-empty it beats the image, and it goes through the exact same routing as the pack's sidebar panel - anything the sidebar refuses, the node refuses too. Note it takes
/images/…page URLs; a/posts/…URL is refused on purpose because one post can hold several images. - recipe - the multiline JSON bundle the front-end writes. You can paste one by hand too. Leave it empty and the node doesn't throw: it returns defaults (seed 0, steps 20, cfg 7.0) so a placed-but-unconfigured node doesn't kill the whole graph.
The eight outputs
prompt, negative, seed, steps, cfg - wire these straight into your text encoders and sampler. sampler, scheduler, checkpoint - here's the trap: these come out as plain strings, and ComfyUI's native sampler/checkpoint widgets are dropdowns, so you can't plug them directly into those nodes. They're data for downstream nodes and notes, not plug-in values. Read the checkpoint name as information and load the model yourself. That's expected, not a bug - and the tradeoff is stated plainly in the README: a graph built this way needs Unbake installed to run. If you want a clean, dependency-free workflow, build it from the pack's sidebar instead of this node.
Installing
From ComfyUI Manager, search ComfyUI-Unbake - or manually:
cd ComfyUI/custom_nodes
git clone https://github.com/syugoji/ComfyUI-Unbake
Then restart ComfyUI. No pip deps: the pack leans on what the host already supplies (folder_paths, PIL, requests), so there's no separate install step. It adds exactly this one canvas node; the rest of the pack is a sidebar tab you can open fullscreen.
Where people get burned
A re-encoded JPEG or a screenshot carries no metadata - there's nothing to read, and no tool can rebuild what was never saved. Get the original file, or re-drop from a host that stored it intact. Second: a verdict of "high/medium" is a likelihood the image reproduces, not a promise - while a model is missing, the replay comes out and just isn't the same picture. Install what it flags as missing and rerun. And if you're sharing the workflow JSON, remember it now depends on this pack - anyone who opens it without Unbake sees a red node and a Manager prompt to install it.
Inputs (3)
| Name | Type | Default | Description |
|---|---|---|---|
| image | COMBO | 1 options: example.png | |
| url | STRING | — | |
| recipe | STRING | — |
Outputs (8)
| Name | Type | Description |
|---|---|---|
| prompt | STRING | — |
| negative | STRING | — |
| seed | INT | — |
| steps | INT | — |
| cfg | FLOAT | — |
| sampler | euler,euler_cfg_pp,euler_ancestral,euler_ancestral_cfg_pp,heun,heunpp2,exp_heun_2_x0,exp_heun_2_x0_sde,dpm_2,dpm_2_ancestral,lms,dpm_fast,dpm_adaptive,dpmpp_2s_ancestral,dpmpp_2s_ancestral_cfg_pp,dpmpp_sde,dpmpp_sde_gpu,dpmpp_2m,dpmpp_2m_cfg_pp,dpmpp_2m_sde,dpmpp_2m_sde_gpu,dpmpp_2m_sde_heun,dpmpp_2m_sde_heun_gpu,dpmpp_3m_sde,dpmpp_3m_sde_gpu,ddpm,lcm,ipndm,ipndm_v,deis,res_multistep,res_multistep_cfg_pp,res_multistep_ancestral,res_multistep_ancestral_cfg_pp,gradient_estimation,gradient_estimation_cfg_pp,er_sde,seeds_2,seeds_3,sa_solver,sa_solver_pece,ddim,uni_pc,uni_pc_bh2 | — |
| scheduler | simple,sgm_uniform,karras,exponential,ddim_uniform,beta,normal,linear_quadratic,kl_optimal | — |
| checkpoint | STRING | — |