Nodes/APZmedia Naming Tools/APZmedia Standard Filename Builder
ComfyUI Node

APZmedia Standard Filename Builder

Project-episode-shot-pass without the regex

By APZmedia·Created 2 years ago·Updated 5 months ago· 8
APZmedia Standard Filename Builder
    • concatenated_name
    project_name
    episode_name
    shot_name
    pass_name
    delimiter-
    toggle_project_nameInclude
    toggle_episode_nameInclude
    toggle_shot_nameInclude
    toggle_pass_nameInclude

    If you've ever had to rename 2,000+ ComfyUI outputs that all landed in one folder with numbered names, you know the pain this pack exists to fix. APZmedia Standard Filename Builder is the original general-purpose assembler in the APZmedia Naming Tools set: you type four segments, it joins the ones you want with your delimiter, and out comes a string ready for a Save Image prefix.

    It's built on the classic VFX/editorial hierarchy - project, episode, shot, pass - which is the naming scheme everyone from post houses to hobbyists has converged on because it sorts correctly and never collides. The node gives you a text field per segment, an Include/Exclude dropdown per segment, and a delimiter field (default -). That's the whole interface, which is the point: zero programming, no regex, no chance of a pipe character murdering your output.

    The mechanism is dead simple and worth knowing so you're not surprised by the output: each segment is only appended if its toggle is Include and the field is non-empty. So you can leave episode_name blank and the result is project-shot-pass with no stray delimiter where the gap would be. To deliberately drop a segment, toggle it to Exclude - that's the difference between "empty" and "omit." The single output, concatenated_name, is a STRING you wire into the filename_prefix of Save Image, or into APZmediaGenerateFilePath if you're building a full folder path.

    Where it earns its keep is batching: feed the segments from other nodes - a fixed project name, a shot number from APZmediaCycleInt, a version you bump between runs - and every image that leaves your graph gets a consistent, sortable name instead of ComfyUI_00001_. Pair it with APZmediaLoadImageWithFilename and you can even rebuild a name from the source image's own segments.

    A couple of honest notes. This node does no sanitization - if you type a ? into a field, it goes into the name. Run the result through the APZmedia Clean File Name Node if you're not certain your segments are filesystem-safe. And numbers, padding, and version formatting are entirely on you: this won't pad 3 to 003 or enforce v03 - the README is explicit that these nodes assume you know what format you want. If you want that opinionated behavior, use the industry-specific naming nodes in the same pack instead.

    Install

    Via ComfyUI Manager, search "APZmedia Naming Tools". Or manually:

    cd ComfyUI/custom_nodes
    git clone https://github.com/APZmedia/ComfyUI-APZmedia-cleanName-from-string
    cd ComfyUI-APZmedia-cleanName-from-string
    pip install -e .
    

    Restart, then look under APZmedia. No models, no heavy dependencies - just unidecode, and this node doesn't even touch that. It's the kind of lightweight utility that makes the pack worth having around even if you only reach for it once a week.

    CategoryAPZmedia

    Inputs (9)

    NameTypeDefaultDescription
    project_nameSTRING
    episode_nameSTRING
    shot_nameSTRING
    pass_nameSTRING
    delimiterSTRING-
    toggle_project_nameCOMBOInclude2 options: Include, Exclude
    toggle_episode_nameCOMBOInclude2 options: Include, Exclude
    toggle_shot_nameCOMBOInclude2 options: Include, Exclude
    toggle_pass_nameCOMBOInclude2 options: Include, Exclude

    Outputs (1)

    NameTypeDescription
    concatenated_nameSTRING