Save workflow (disk)
Write the current workflow to disk
- workflow
The write half of ComfyUI_NetDist's workflow-JSON pair: take a workflow, dump it to disk as a JSON file - the same way core Save Image dumps a PNG. Feed it LoadCurrentWorkflowJSON's output and you've got a snapshot you can reload later with LoadDiskWorkflowJSON, instead of rebuilding the graph you feed into RemoteChainStart from scratch every session.
This is part of the "advanced" side of city96's ComfyUI_NetDist pack - the pattern built for running more than two GPUs, where a workflow gets shipped as a standalone JSON payload rather than read live off the graph each time. It's a small, unglamorous node, but it's what turns "rebuild the advanced setup from scratch every session" into "pick a saved file and go."
How it works
It's an output node - no downstream connections, nothing to wire further. It writes the workflow JSON you hand it into your ComfyUI output directory, nested under whatever filename_prefix you set, matching the exact same output-folder convention every other Save node in ComfyUI follows. Nothing special about where it lands beyond that.
The inputs and outputs that matter
workflow(JSON, required) - the graph to save, almost always piped straight fromLoadCurrentWorkflowJSON.filename_prefix(STRING, defaultworkflow/ComfyUI) - the default already nests saves under aworkflow/subfolder inside your output directory, so they don't mix in with your generated images and latents.
No outputs - this is a terminal node, same shape as core Save Image.
How to install it
Via ComfyUI Manager: search ComfyUI_NetDist. Manually:
cd ComfyUI/custom_nodes
git clone https://github.com/city96/ComfyUI_NetDist
pip install requests
Restart ComfyUI. requests is the pack's only dependency.
Common issues & troubleshooting
Can't find the saved file. Check your ComfyUI output directory under the workflow/ prefix (or wherever you overrode filename_prefix to point) - same base folder as everything else you save, just a JSON file sitting alongside your images.
Expecting it to save the generated output too. It doesn't - this only captures the workflow graph itself, none of the actual images or latents produced by running it. If you want those preserved as well, pair it with SaveImageUrl or SaveLatentNumpy separately; they're independent nodes with independent jobs.
Files piling up over time. Like any other Save node in ComfyUI, nothing here gets cleaned up automatically - if you're saving workflow snapshots regularly, expect that folder to grow and prune it yourself when it matters.
Not sure whether to bother with this at all. If you're only ever running the advanced chain from a live graph you're actively editing, LoadCurrentWorkflowJSON alone covers you and you can skip this node entirely. It earns its place once you've got a stable multi-GPU setup you want to fire off repeatedly without rebuilding it - a batch job you kick off the same way every night, say - where reloading a saved file beats recreating the graph by hand each time.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| workflow | JSON | — | |
| filename_prefix | STRING | workflow/ComfyUI | — |
Outputs (0)
No outputs