The graph ComfyUIComfyUIThe dominant node-based interface for running diffusion models locally. Started by 'comfyanonymous' in January 2023, now stewarded by Comfy Org. opens with is the text-to-image workflow, and learning to read it is learning the tool. Six nodes, left to right. Load CheckpointCheckpointA saved set of model weights. The .safetensors or .ckpt files you download to run a model. loads a model file and splits it into its three parts, outputting MODEL, CLIPCLIPA text encoder developed by OpenAI in 2021 that learns to align text and images in a shared embedding space. Foundation of most text-to-image models from 2022 onward., and VAEVAE (Variational Autoencoder)A neural network that learns to compress images into a small numerical representation (a latent) and decompress them back. Used in latent diffusion models to make the generation process tractable. from the one file. Two CLIP Text Encode nodes turn text into CONDITIONINGConditioningAny extra input that steers generation beyond the prompt, such as a depth map, pose, edge map, or reference image., one for the positive promptPromptThe text description you provide to a model to specify what you want it to generate. (what you want) and one for the negative (what you do not), both fed the CLIP from the checkpoint. Empty Latent Image makes a blank latent canvas at your chosen dimensions, which is really a block of noise for the model to carve into. KSamplerKSamplerThe ComfyUI node where denoising actually happens, taking the model, prompts, and a latent and running the sampling loop under its seed, steps, CFG, sampler, and scheduler settings. is the engine room, where denoisingDenoisingThe core loop of diffusion. Starting from pure noise, the model repeatedly predicts and subtracts a little noise until a coherent image emerges. happens: it takes the MODEL, the two CONDITIONINGs, and the LATENT and runs the sampling loop. VAE Decode takes the finished LATENT plus the VAE and turns it back into an IMAGE. Save Image writes it to disk.
Fig.diagram
■A basic text-to-image workflow in ComfyUI, the six-node spine that every other graph is just a variation on. Read it left to right.
The KSampler is where your attention goes, and its parameters are worth knowing exactly. Seed is the random seed for the initial noise, with a control that can fix, increment, decrement, or randomize it after each run. Steps, default twenty, is how many denoising iterations to run. CfgCFG (Classifier-Free Guidance)A technique that pushes a diffusion model to follow the prompt more strongly by contrasting its prediction with and without the prompt. Higher values obey the text more but can look oversaturated or 'fried'. (the classifier-free guidance scaleGuidance scale (Classifier-Free Guidance (CFG) scale)A parameter that controls how strongly the model adheres to the prompt versus producing diverse outputs. Higher values mean stricter prompt following. Typical range 5-10., default eight on the classic samplerSamplerThe algorithm used to perform the denoising steps. Different samplers (Euler, DPM++, etc.) have different speed-quality trade-offs.) balances prompt adherencePrompt adherenceHow faithfully a model follows the specifics of your prompt, meaning the objects, counts, colors, spatial relationships, and text you asked for. High adherence means you get what you described, not just something in the right neighborhood. against quality, and the foundations chapter explains why turning it too high backfires. Sampler_name and schedulerSchedulerThe algorithm that decides the sequence of denoising steps and how each is applied. Often called the sampler. Different schedulers trade speed against quality. choose the algorithm and the noise scheduleNoise scheduleThe recipe that decides how much noise is added at each step of the forward process and removed on the way back. It strongly affects quality and speed., the part that, as the foundations argued, matters least once you pick a sane default like dpmpp_2m with the karras scheduleKarras scheduleA popular noise schedule that spaces the denoising steps to get better quality in fewer steps. Often paired with DPM++ samplers.. Denoise, at its default of one, means generate from scratch; drop it below one and you get image-to-image, which is the whole trick of the next section. One caution: distilled and Flux-style models change these defaults substantially, so treat eight-cfg and twenty-steps as the classic baseline, not a universal law.
Check your understanding
pass: 5 of 7
Answer at least 5 of 7 correctly to unlock the next chapter.
1. How many nodes make up the default text-to-image workflow ComfyUI opens with?
2. What three outputs does the Load Checkpoint node produce from a single model file?
3. Why are there two CLIP Text Encode nodes in the default graph?
4. What is the default value of the KSampler's Steps parameter?
5. What does the Cfg parameter balance, and what is its classic default?
6. What happens when you drop the KSampler's Denoise parameter below 1?
7. Which sampler and scheduler are cited as a sane default that makes the choice matter least?
The weekly briefing
Get the week's moves in your inbox.
A short, sourced digest of what actually moved across generative AI, every week. Free.
Free. One email a week, no spam, unsubscribe anytime. Prefer a reader? RSS.