Nodes/AUN ComfyUI Nodes/Filename Resolver V2
ComfyUI Node

Filename Resolver V2

Use AUN's filename builder with ComfyUI's stock Save Image

By loz2754·Created 8 months ago·Updated about 18 hours ago· 5
Filename Resolver V2
    • path_filename
    • sidecar_text
    path_filename%date% %seed%
    delimiter
    model_name
    sampler_nameeuler
    scheduler_namenormal
    steps_value20
    cfg_value7.50
    seed_value123456
    output_typeVideo
    sidecar_formatOutput only (text)
    pos_prompt
    neg_prompt
    date_format%Y-%m-%d
    frame_rate16.00
    loop_count0
    quality85
    width0
    height0
    count1
    batch_num1

    The AUN filename system is built around one combined path_filename string from the pack's AUNPathFilenameV2 builder - but the stock ComfyUI Save Image node doesn't understand that contract. It wants a plain resolved filename. AUNFilenameResolverPreviewV2 is the adapter in the middle: it takes a path_filename template, resolves all the %token% placeholders into concrete values, and returns a filename a standard save node can use - plus a sidecar text or JSON describing the run's parameters.

    The main required input is path_filename, the combined template from a V2 builder node (default %date% %seed%). Then you feed it the resolved values it needs to substitute: model_name, sampler_name, scheduler_name, steps_value, cfg_value, and seed_value. Yes, you have to supply the values yourself - that's the "resolver" part, it turns tokens into text, it doesn't scrape them from your graph (that's what AUNGraphScraper and AUNExtractWidgetValue are for). The typical wiring is: builder → resolver, with your extractor nodes feeding the resolved values in.

    output_type switches the node's vocabulary between Video and Image, which changes which optional fields show up. In Video mode you get frame/video fields - frame_rate, loop_count, quality, width, height, count - which are recorded in the sidecar and used to build things like a loop-count or frame-count token. In Image mode you instead get batch_num, which appends a batch number to filenames when you're saving multiple. The sidecar_format dropdown (four options) decides whether the sidecar comes back as text or JSON, and whether it's just returned as output or written to a .txt/.json file next to the saved output. Either way, the node always returns sidecar_text on its second output.

    The two outputs are path_filename - the fully resolved string you feed into standard Save Image or a video combine node - and sidecar_text, which carries the parameter summary. That sidecar is where this node shines: model, sampler, scheduler, steps, CFG, seed, and (in video mode) frame info, all recorded, so your saved images carry a plain-text record of how they were made without relying on PNG metadata alone.

    The date_format input controls the %date%/%time% placeholders and the sidecar timestamp, and it accepts both Python and Java-style format strings (it converts between them - a nice touch if you're migrating from a Java-format workflow).

    Install with the pack: ComfyUI Manager (search "AUN") or cd ComfyUI/custom_nodes && git clone https://github.com/loz2754/AUN-ComfyUI-Nodes, then restart. Dependency-light, no models. If you've fully embraced the pack, the simpler path is AUNSaveImageV2, which takes the same path_filename directly - this node exists precisely for people who want the AUN naming but are keeping the stock save node.

    CategoryAUN Nodes/File Management

    Inputs (20)

    NameTypeDefaultDescription
    path_filenameSTRING%date% %seed%Combined path + filename template from a V2 builder node.
    delimiterSTRING Delimiter used by the builder node.
    model_nameSTRINGFull model name (used in sidecar 'model' field).
    sampler_nameSTRINGeulerResolved sampler name.
    scheduler_nameSTRINGnormalResolved scheduler name.
    steps_valueINT20Resolved steps value.
    cfg_valueFLOAT7.50Resolved cfg value.
    seed_valueINT123456Resolved seed value.
    output_typeCOMBOVideoVideo: includes frame_rate/loop/quality/width/height/count fields. Image: includes batch_num field instead.
    sidecar_formatCOMBOOutput only (text)Choose sidecar output format. 'Save to file' writes a .txt/.json next to the resolved output file; the node always returns sidecar_text.
    pos_promptoptSTRINGPositive prompt text for the sidecar.
    neg_promptoptSTRINGNegative prompt text for the sidecar.
    date_formatoptSTRING%Y-%m-%dDate format for %date and %time placeholders and sidecar timestamp.
    frame_rateoptFLOAT16.00(Video) Frame rate of the saved video.
    loop_countoptINT0(Video) Loop count (0 = infinite for gif/webp).
    qualityoptINT850–100(Video) Output quality value.
    widthoptINT0(Video) Output frame width in pixels.
    heightoptINT0(Video) Output frame height in pixels.
    countoptINT1(Video) Number of frames in the output.
    batch_numoptINT1(Image) Batch number appended to filenames.

    Outputs (2)

    NameTypeDescription
    path_filenameSTRING
    sidecar_textSTRING