Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add 'sub-graphs' to ComfyUI #5353

Open
Creare-d-arte opened this issue Oct 25, 2024 · 3 comments
Open

Add 'sub-graphs' to ComfyUI #5353

Creare-d-arte opened this issue Oct 25, 2024 · 3 comments
Labels
Feature A new feature to add to ComfyUI.

Comments

@Creare-d-arte
Copy link

Creare-d-arte commented Oct 25, 2024

Feature Idea

Node-based programs (like Geogen, WorldMachine, etc.) feature what are called "sub-graphs" or "Macros".

Double-clicking a subgraph/Macro node will open a blank node graph.

In this new graph/space, one can place a series of nodes; and connect then to special Input & Output nodes.

The Subgraph/Macro nodes in the main graph/space, update their inputs & outputs according to the number of connected Input & Output nodes within the sub-graph.

....................................................................................................

The common purpose of this feature; is to clean up the main graph/space.

e.g. I aim to use such, to hide a bunch of nodes that the user(myself) doesn't need to see.

There are other purposes for subgraphs;

  1. In WorldMachine, Macros are treated like Custom Nodes; and are distributed on the forums like such.

  2. Saving and loading sub-graphs into workflows is a better alterative to that of ComfyUI's 'Templates'.

Existing Solutions

No response

Other

No response

@Creare-d-arte Creare-d-arte added the Feature A new feature to add to ComfyUI. label Oct 25, 2024
@LukeG89
Copy link

LukeG89 commented Oct 25, 2024

Someone already proposed this feature request in the frontend repo: Comfy-Org/ComfyUI_frontend#1077

I think the current way to have subgraphs is using this custom node: ComfyUI-Sub-Nodes

And maybe components have a similar purpose: ComfyUI-Workflow-Component

@Creare-d-arte
Copy link
Author

Creare-d-arte commented Oct 25, 2024

Someone...

The frontend request seems very similar to mine; though I would prefer this issue remain open, for exposure.

As for the suggestions; unfortunately both are janky and out-of-date, and such are not viable for me/ComfyUI users.

@ltdrdata
Copy link
Collaborator

ltdrdata commented Oct 25, 2024

Someone already proposed this feature request in the frontend repo: Comfy-Org/ComfyUI_frontend#1077

I think the current way to have subgraphs is using this custom node: ComfyUI-Sub-Nodes

And maybe components have a similar purpose: ComfyUI-Workflow-Component

ComfyUI-Workflow-Component was an experimentally implemented feature, and since it hasn't been maintained for a while and cannot be used properly, I recommend not using it.
I plan to maintain it when time permits in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature A new feature to add to ComfyUI.
Projects
None yet
Development

No branches or pull requests

3 participants