> For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt.

# PAG注意力引导（PerturbedAttentionGuidance）

<div class="node-meta"><code>PerturbedAttentionGuidance</code><span>model/patch/unet</span><span>角色：模型补丁</span><span class="star">★ 常用节点</span></div>

PerturbedAttentionGuidance 节点对扩散模型应用扰动注意力引导，以提升生成质量。在采样过程中，它会进行额外预测，其中中间块的自注意力被替换为一个简化版本，该版本直接传递值投影，然后将正常条件预测与该扰动预测之间的缩放差值添加到去噪结果中。将 `scale` 设为 0 会完全禁用该效果。

## 参数

| 参数      | 类型           | 默认 / 范围              | 说明                        |
| ------- | ------------ | -------------------- | ------------------------- |
| `model` | MODEL · 扩散模型 | —（连线输入）              | 修改后的模型，其采样过程中附加了扰动注意力引导补丁 |
| `scale` | FLOAT        | 0.0 \~ 100.0，步长 0.01 | 整体缩放比例。                   |

## 输出

| 输出    | 类型    | 说明   |
| ----- | ----- | ---- |
| MODEL | MODEL | 扩散模型 |

## 怎么接

- **上游**：CheckpointLoaderSimple / UNETLoader
- **下游**：KSampler / 下一个补丁节点
- **接线**：串在模型链中间：上游接 CheckpointLoaderSimple / UNETLoader 的 MODEL，输出接 KSampler 的 `model` 或下一个补丁；多个补丁叠加时顺序会改变结果。

## 使用案例

属于「模型补丁」类节点，向下游提供可采样的模型对象。从 `model`、`scale`（3.0） 开始填就能跑起来。典型接法：`CheckpointLoaderSimple` → 本节点 → `KSampler`。注意：补丁节点按「加载器 → 补丁 → 采样器」的顺序串接，顺序不同效果不同。

## 端口与连线示意

![PerturbedAttentionGuidance 端口与连线示意](/svg/PerturbedAttentionGuidance.svg)

## 实战提示

- 补丁节点按「加载器 → 补丁 → 采样器」的顺序串接，顺序不同效果不同。

## 同类节点

\[Epsilon缩放]\(/nodes/01/Epsilon Scaling) · [FreeU](/nodes/01/FreeU.md) · [FreeU_V2](/nodes/01/FreeU_V2.md) · [超分块HyperTile](/nodes/01/HyperTile.md) · [收缩模型UNET（Kohya Deep Shrink）](/nodes/01/PatchModelAddDownscale.md) · [Tome合并模型Token](/nodes/01/TomePatchModel.md) · [TSR - 时序分数重缩放](/nodes/01/TemporalScoreRescaling.md)
