SAX Guidance
Fix fried colors and flat details without a CFG re-roll
- pipe
- PIPE_LINE
High CFG gets you prompt adherence and gives you fried, oversaturated colors. Low CFG gets you clean color and gives you flat, mushy details. SAX Guidance is the node that tries to have both: it sits between your loader and sampler and rewrites how the guidance term is applied, so you can keep the CFG you like and fix the side effects. The author calls the family "CFG guidance enhancement," and it's built into the Detailers too - this is the standalone version you place before the KSampler (or the upscaler's i2i pass).
There's a second, arguably more interesting feature on the same node: PAG (Perturbed Attention Guidance), which improves detail at any CFG - including CFG 1 on the guidance-distilled models where raising CFG is off-limits. That's the sleeper here.
The modes
mode (default agc+fdg) selects what happens to the guidance term:
agc- spike suppression for high CFG (5+). It tanh soft-clips the guidance delta so the oversaturation spikes can't blow out. Color stays rich, saturation stops frying.fdg- frequency-band detail emphasis for high CFG. Separates the guidance signal into frequency bands and boosts the detail-carrying band.agc+fdg- both, the default. For the classic CFG-8-style workflow, this is the "just make it better" option.post_fdg- the low-CFG variant (CFG 1–3), tuned for low-step LoRA workflows like DMD2 that can't raise CFG. Pumps detail into a regime that normally can't have it.off- bypass.
strength (default 0.5) is the intensity dial for AGC/FDG modes - 0 is no effect, 1 is maximum. Start at the default and nudge, because "too much detail emphasis" is a real look and it's not flattering.
PAG, the part you'll actually want
pag_strength (default 0) is separate from the mode entirely. PAG (arXiv:2403.17377) perturbs the self-attention during sampling and pushes the result away from the degenerate attention patterns that cause softness - the same family as the self-attention guidance tricks the KB's UI-history doc notes in Fooocus. It works at any CFG, which makes it the tool for distilled models stuck at CFG 1, and it combines with the AGC/FDG modes. 0 disables it; 0.5 is "standard" (scale ~3); it costs one extra forward pass per step, so it roughly doubles per-step compute - turn it on when you're iterating on final quality, not while you're still chasing composition.
Where it goes
SAX Loader → SAX Guidance → SAX KSampler → ...
It takes a PIPE and returns a PIPE with the guidance-wrapped model installed, so the sampler downstream just runs. Same mechanics as SAX Cache - one node on the line, everything after inherits it. And if you're already using a SAX Detailer, you don't need a separate Guidance node for the detail passes: the Detailers carry the same guidance_mode/guidance_strength/pag_strength controls in their optional inputs.
Install and honest advice
Part of the pack:
cd ComfyUI/custom_nodes
git clone https://github.com/so16tm/SAX_Bridge
Under SAX/Bridge/Enhance after restart. The honest advice: if your workflow is already CFG 8 and happy, leave agc+fdg at 0.5 and move on - this is polish, not a cure. If your model can't run high CFG (anything guidance-distilled), skip the AGC/FDG modes entirely and play with pag_strength instead; that's the mode the node exists for.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| pipe | PIPE_LINE | — | |
| mode | COMBO | agc+fdg | off=bypass, agc=spike suppression, fdg=detail emphasis (high CFG), agc+fdg=both, post_fdg=detail emphasis (low CFG / low-step LoRA) |
| strength | FLOAT | 0.500–1 | Effect intensity for AGC/FDG modes. 0.0=no effect, 0.5=moderate, 1.0=maximum. |
| pag_strength | FLOAT | 0.000–1 | Perturbed Attention Guidance intensity. Works at any CFG. 0.0=disabled, 0.5=standard (scale=3.0). Can combine with other modes. Note: adds one extra forward pass per step. |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| PIPE_LINE | PIPE_LINE | — |