Nodes/AAA Metadata System/File Organizer
ComfyUI Node

File Organizer

A File-Moving Robot That Lives Inside a ComfyUI Node

By EricRollei·Created 10 months ago·Updated 9 months ago· 13
File Organizer
    • status_message
    • files_processed
    • stats_json
    • log_output
    min_pixel_size512
    dimension_checkshortest_side
    subfolder_handlingorganize_each_subfolder
    sidecar_handlingkeep_all_sidecars_with_images
    folder_paths_input
    folder_paths_manual
    handle_small_imagesmove_to_below_min
    create_subfolderstrue

    Every ComfyUI user eventually accumulates a swamp: a downloads folder where training images, web-scraped batches, and sidecar files all sit in one pile. File Organizer is a batch file-management tool that happens to be packaged as a node - you give it folders, it sorts files into type folders (images, movies, text, other, sidecars, below_min), moves undersized images aside, and reports what it did. It's not an image-processing node at all; it's a filesystem tool that runs when your workflow executes. That distinction matters, and it's the first thing to internalize.

    The required inputs are its policy knobs. min_pixel_size (default 512) is the resolution cutoff for images, with dimension_check choosing whether to test the shortest side, longest side, or both. subfolder_handling decides scope: organize_each_subfolder (default) creates type folders inside each existing subfolder, flatten_all drags everything up to one main set of type folders, ignore_subfolders only touches the top level. sidecar_handling controls what happens to .txt/.xmp/.json companions - critical if you have caption files that must stay next to their images. You point it at folders via folder_paths_manual (one per line) or folder_paths_input (a path string from another node, like a scraper).

    The scary part is in the optional section: handle_small_images defaults to move_to_below_min, but its other choice is delete. Yes - this node can permanently delete files when a workflow runs. There is no undo, no trash. That's the #1 beginner trap. If you wire this into a workflow you run often, you are running a file-mover with destructive options on every Queue press.

    Outputs are all report-like: status_message, files_processed (INT), stats_json, and log_output. Nothing image-shaped comes out - this node produces accountability, not pixels.

    Honest framing: this is a niche, single-author pack with zero community presence, and File Organizer is the kind of tool that makes sense in a personal utility workflow rather than a shareable generation graph. If your use case is "tidy a scraped folder of training images," it genuinely saves time. If your use case is "make art," there are simpler ways to spend your evening.

    Install the pack and restart, then find it under Eric/Images:

    cd ComfyUI/custom_nodes
    git clone https://github.com/EricRollei/AAA_Metadata_System
    cd AAA_Metadata_System
    pip install -r requirements.txt
    

    Set it up on a test directory first, keep handle_small_images on move_to_below_min, and read the log_output before you let it loose on real files. A file organizer is only a tool; delete is a decision.

    CategoryEric/Images

    Inputs (8)

    NameTypeDefaultDescription
    min_pixel_sizeINT5121–4096Minimum pixel size for image dimension check
    dimension_checkCOMBOshortest_sideWhich dimension(s) to check against minimum
    subfolder_handlingCOMBOorganize_each_subfolderflatten_all: Move all files from subfolders to main type folders | organize_each_subfolder: Create type folders within each existing subfolder | ignore_subfolders: Only organize files in the main directory
    sidecar_handlingCOMBOkeep_all_sidecars_with_imageskeep_txt_with_images: Keep only .txt files with images (for captions), move .xmp/.json to sidecars folder | keep_all_sidecars_with_images: Keep all .txt/.xmp/.json files with images | separate_sidecars: Move all sidecars to separate sidecars folder
    folder_paths_inputoptSTRINGOptional: Folder paths from another node (like web scraper output)
    folder_paths_manualoptSTRINGManual input: One folder path per line to organize
    handle_small_imagesoptCOMBOmove_to_below_minWhat to do with images below minimum size
    create_subfoldersoptBOOLEANtrueCreate type subfolders (images, movies, text, other, sidecars, below_min)

    Outputs (4)

    NameTypeDescription
    status_messageSTRING
    files_processedINT
    stats_jsonSTRING
    log_outputSTRING