> ## Documentation Index
> Fetch the complete documentation index at: https://docs.comfy.org/llms.txt
> Use this file to discover all available pages before exploring further.

# NAGuidance - ComfyUI Built-in Node Documentation

> Complete documentation for the NAGuidance node in ComfyUI. Learn its inputs, outputs, parameters and usage.

## 概述

NAGuidance 节点将归一化注意力引导（Normalized Attention Guidance）应用于模型。该技术通过在采样过程中修改模型的注意力机制，使蒸馏或快速模型能够使用负面提示，从而引导生成结果远离不期望的概念。

## 输入

| 参数          | 描述                                                  | 数据类型  | 是否必填 | 取值范围       |
| ----------- | --------------------------------------------------- | ----- | ---- | ---------- |
| `model`     | 要应用归一化注意力引导的模型。                                     | MODEL | 是    | -          |
| `nag_scale` | 引导缩放因子。数值越高，生成结果越远离负面提示。（默认值：5.0）                   | FLOAT | 是    | 0.0 - 50.0 |
| `nag_alpha` | 归一化注意力的混合因子。值为 1.0 时完全替换原始注意力，值为 0.0 时无效果。（默认值：0.5） | FLOAT | 是    | 0.0 - 1.0  |
| `nag_tau`   | 用于限制归一化比率的缩放因子。（默认值：1.5）                            | FLOAT | 是    | 1.0 - 10.0 |

## 输出

| 输出名称    | 描述                 | 数据类型  |
| ------- | ------------------ | ----- |
| `model` | 已启用归一化注意力引导的修补后模型。 | MODEL |

> 本文档由 AI 生成。如果您发现任何错误或有改进建议，欢迎贡献！ [在 GitHub 上编辑](https://github.com/Comfy-Org/embedded-docs/blob/main/comfyui_embedded_docs/docs/NAGuidance/zh.md)

***

**Source fingerprint (SHA-256):** `ea3d7fea94e62c8a0784887f3df9d8a503c3dbaa552bf860bd4dde1ae576fa9c`
