The most powerful and modular diffusion model GUI, api and backend with a graph/nodes interface. The fastest local inference engine in the world.
Update AGENTS.md (#14726)
comfyanonymous35c147093504
diff --git a/AGENTS.md b/AGENTS.mdindex 8eabed6d0..bd6a3e5e8 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -8,6 +8,8 @@directly required.- Prefer practical fixes over broad architecture work. Add abstractions onlywhen they remove real repeated logic or match an existing ComfyUI pattern.+- Prefer fewer dependencies. Do not add new dependencies to ComfyUI unless they+ are absolutely necessary.- Delete obsolete code aggressively when newer infrastructure makes it useless.Remove dead fallbacks, migration paths, unused options, debug prints, andcompatibility branches that are no longer needed. Do not leave dead branches,@@ -111,6 +113,11 @@- Do not add freeze, unfreeze, or trainability toggles to model classes. ComfyUImodels are always treated as frozen for inference, so explicit freezefunctionality is redundant and should not be added.+- Remove training-only behavior such as dropout from inference model code, but+ preserve checkpoint and state-dict compatibility when doing so. If deleting a+ module would change state-dict keys, module ordering, or checkpoint loading+ behavior, replace it with a no-op such as `nn.Identity` instead of removing the+ slot outright.## Python Style@@ -234,6 +241,9 @@`CATEGORY`, and registration through the local mapping used by that file.- Keep node changes backward compatible by default. Add inputs with sensibledefaults and avoid changing output types unless the request requires it.+- Model implementations should add the minimal number of ComfyUI nodes required+ to run the model. Reuse existing nodes as much as possible; adapting the model+ to work with existing nodes is strongly preferred over creating new nodes.- Node-level code must not patch model code directly. Any node behavior thatmodifies, wraps, hooks, or changes model behavior must go through the modelpatcher class instead of reaching into model internals.