Nodes/ComfyUI EasyUse Anima/Anima AiO Hook Combine
ComfyUI Node

Anima AiO Hook Combine

Stack third-party AiO extensions in the order you want

By n0va39·Created 3 months ago·Updated a day ago· 24
Anima AiO Hook Combine
  • hook_a
  • hook_b
  • hook_c
  • hook_d
  • aio_hook

Most ComfyUI users will never touch this node, and that's the point. Anima AiO Hook Combine is developer plumbing: it takes up to four EASYUSE_ANIMA_AIO_HOOK values and merges them into one socket for the AiO Generator's aio_hook input. It exists because ComfyUI sockets carry one value, and if three different extension packs each want to hook into your generation, something has to hold all three.

What the hook system is

The AiO Generator exposes an optional aio_hook input, and the pack publishes a v1 extension API so other custom node packs can plug into the generation lifecycle without forking the generator. Version 1 supports: replacing the first-pass MODEL and selected sampler settings at first_pass/before, adjusting the final image at postprocess/before and postprocess/after, and attaching JSON-safe extension metadata with optional previews. A third-party pack implements a session class, emits an EASYUSE_ANIMA_AIO_HOOK output, and you connect it to the generator. If only one pack does that, you never need this node - connect it directly.

What the combine node adds

Middleware ordering. When you connect multiple hooks, order matters, and this node makes it explicit rather than accidental:

  • hook_a and hook_b are required; hook_c and hook_d are optional.
  • Before callbacks run in socket order: hook_a → hook_b → hook_c → hook_d.
  • After callbacks and session-close run in reverse: d → c → b → a.
  • Cleanup callbacks use global reverse-registration order.

That's the classic middleware sandwich: the first hook you wire in gets the first crack at the forward pass and the last word on the way out. If you're building a pipeline where hook A sets up a model state that hook B reads, wire A first.

The output

aio_hook - the combined EASYUSE_ANIMA_AIO_HOOK value, ready for the AiO Generator's aio_hook socket. Nothing else. The node is a pure combinator: no settings, no execution of its own.

When you'd actually use it

Three realistic cases: (1) you run two or more AiO-compatible extension packs and want both applied; (2) you're a pack developer and want a predictable composition story for your own hooks; (3) you're testing a hook in isolation and the combine node doubles as a pass-through - feed one hook into hook_a and leave the rest disconnected.

Install and gotchas

Pack install:

cd ComfyUI/custom_nodes
git clone https://github.com/n0va39/ComfyUI-EasyUseAnima
cd ComfyUI-EasyUseAnima && pip install -r requirements.txt

Restart ComfyUI; Manager: "ComfyUI EasyUse Anima".

The gotcha is failure policy, and it's deliberate: invalid hook contracts and plugin failures fail the generation, loudly, rather than silently swallowing the extension's contribution. If a workflow that worked without hooks starts erroring after you add one, suspect the hook before the generator. Also remember the ordering asymmetry - if two hooks both want to patch the image at postprocess, the last one wired wins the final output, and knowing that saves you a confusing debugging session.

CategoryEasyUse Anima/AiO/Extensions

Inputs (4)

NameTypeDefaultDescription
hook_aEASYUSE_ANIMA_AIO_HOOK
hook_bEASYUSE_ANIMA_AIO_HOOK
hook_coptEASYUSE_ANIMA_AIO_HOOK
hook_doptEASYUSE_ANIMA_AIO_HOOK

Outputs (1)

NameTypeDescription
aio_hookEASYUSE_ANIMA_AIO_HOOKCombined EASYUSE_ANIMA_AIO_HOOK value for Anima AiO Generator.