Closed xueqing0622 closed 1 month ago
@xueqing0622 I did not find an easy and reliable way to rename the in- and output sockets. For inputs it seems, its always depending on the name of the slot and the name of the node.
For example, I renamed cliptextencoder nodes in the node properties panel to "Pos.Prompt" and "Neg.Prompt" and text input sockets to "PosText" and "NegText": In the subgraph node then, it appears like this: So for input sockets it is always NameOfTheInputSocket.NameOfTheNode.SomeInteger
For output sockets I haven't figured out how to influence the name by customizing any node or socket name. The only way I figured out is by opening the .json file and search for the socket name and change it manually. But that way seems not to be reliable, because if you open this .json file in ComfyUI and change anything in the workflow, you need to redo all the renaming in the new .json file again.
You are correct in how the input names are determined, (idr how the output names are set at the top of my head). Supporting renaming the sockets directly is something I am gonna add when I get back home (on vacation, I released this thing at a good time xD). Honestly idk how supporting that completely slipped my mind during the first iterations of this
You can now rename the slots on both inputs and outputs and those names will be respected when using the subgraph
how to change name, I even change the json file, but still not work. Do you have tutor.
ok, re name the slot input output in json file, and must rename to save another name. but it only work in subnode json, not in subnode node
You should use the builtin comfyui slot rename feature, right click on the slot (the circle) to rename stuff.
Yes, Thx your tips! have a nice day!
how to customize the names of the inputs and outputs of a subgraph?