ComfyUI Node

Workflow Name

Know Which Workflow You're Running, Right in the Filename

By QuietNoise·Created about a year ago·Updated 8 months ago· 57
Workflow Name
    • workflow_name

    Ever come back to a folder of renders and have no idea which workflow made which image? That's the problem this node kills. Workflow Name is the one genuinely useful piece of ComfyUI Queue Manager, a tiny node that just hands you the name of whatever workflow is currently running, so you can feed it into a Save Image node's filename_prefix and get output files that tell you what they are.

    It's a string emitter and nothing else - no inputs, no knobs, no settings. Drop it anywhere in your graph, and out pops one workflow_name (STRING) socket. Wire that into any node that accepts a string, and you're done. The obvious pairing is Save Image's filename_prefix: instead of a generic ComfyUI_00001_.png, you get upscale_test_00001_.png - every image tagged with the workflow that made it, with zero manual typing.

    How it actually works

    Peek under the hood and it's almost comically simple. The node asks ComfyUI's PromptServer for the currently running prompt, digs into that prompt's extra_pnginfo.workflow.workflow_name, and returns it. No computation, no model calls - it's just metadata plumbing.

    The clever part is where that name comes from. When Queue Manager queues a job, it stamps the queue item with the active workflow's filename (the .json you have open and saved). At run time the node reads that stamp. So it only means something when you queue through Queue Manager with a saved, named workflow. If nothing is running, or the running job has no name attached, the node quietly returns an empty string rather than erroring out.

    Where people get burned

    The empty-string case is the one to know about. Jobs that get queued without a full workflow context - the README calls out API-driven add-ons like the Krita plugin, which Queue Manager hands off to the native queue handler as "external" jobs - never get a name stamped, so this node gives you nothing for them. Same goes for anything queued from the stock Run button without Queue Manager in the picture. If your filenames suddenly come out bare, check how the job was queued, not the node.

    Also: the name is whatever you saved the workflow as. An unsaved or generically-named workflow means output files named workflow_00001_.png, which is barely better than nothing. Name your files before you queue.

    Installing it

    This is the whole pack, and it's painless - no pip requirements, no model downloads, just frontend plus a thin Python side:

    cd ComfyUI/custom_nodes
    git clone https://github.com/QuietNoise/comfyui_queue_manager
    

    Restart ComfyUI and it shows up under the Queue Manager category. Or skip the terminal: open ComfyUI Manager, search "ComfyUI Queue Manager", and click install. That's it.

    One catch, because the pack is frank about it: it's an early-access, proof-of-concept release that hijacks ComfyUI's native queue to give you its own pause/archive/export UI. It requires the new ComfyUI menu, it's not built for multi-user instances, and it can clash with other extensions that poke at the native queue object. The author says it plainly - things will change a lot. For a little string node that's a heavy setup, but if you're already running Queue Manager for its pause-and-resume workflow management, this node is the free perk. If you just want tidy filenames and don't want to hand your queue to an early-access extension, something like a plain text-concat or a filename template node does the job with less baggage. Trade-off's yours.

    CategoryQueue Manager

    Inputs (0)

    No inputs

    Outputs (1)

    NameTypeDescription
    workflow_nameSTRING