ComfyUI Extension: ComfyUI Utilitools Nodes

Authored by aesethtics

Created

Updated

0 stars

A collection of utility nodes for ComfyUI to improve workflow efficiency.

Custom Nodes (0)

    README

    ComfyUI-Utilitools

    A collection of utility nodes for ComfyUI that I find handy. Nothing fancy, just stuff that makes workflows a bit easier when you need simple operations.

    What's in here?

    These aren't the most sophisticated nodes out there, but they get the job done for basic operations:

    🧮 Math Nodes

    • Add, Subtract, Multiply, Divide - Basic math with both int and float outputs
    • Calculator - Safely evaluate simple math expressions like "2 + 2 * 3"

    šŸ“ Text Utilities

    • Text Concatenation - Join two strings with optional separator
    • String Replace - Find and replace text with optional count limit

    šŸ”„ Type Conversions

    • Float to Int / Int to Float - Convert between number types
    • Whatever To String - Convert any value (int, float, string) to string

    šŸ¤” Logic & Control

    • If Then Else - Branch workflows based on boolean conditions
    • Switch - Select from up to 8 inputs by index
    • Boolean Gates - AND, OR, NOT operations

    šŸ“‹ Data Manipulation

    • Create List - Make lists from up to 8 items
    • List Index - Get item from list by index
    • Batch Controller - Adjust tensor batch sizes

    āš™ļø Workflow Helpers

    • Passthrough - For workflow organization (does nothing, just passes data through)
    • Counter - Increment/decrement with optional reset
    • Date Timestamp - Generate formatted date/time strings with toggles for components
    • Constants - Int, Float, and String constant value nodes

    šŸ–¼ļø Image Utilities

    • Image Dimensions - Get width, height, and batch size from images
    • Aspect Ratio - Calculate ratio as decimal and simplified fraction (like "16:9")

    Installation

    Just drop this folder into your ComfyUI custom_nodes directory and restart ComfyUI. That's it.

    ComfyUI/custom_nodes/ComfyUI-Utilitools/
    

    Notes

    • All nodes are organized under "Utilitools" categories in the node browser
    • Most math operations work with both int and float inputs
    • The calculator node only accepts basic math expressions for safety
    • These are utility nodes I made for myself - they're useful but not groundbreaking

    Structure

    The code is organized by category for easier maintenance:

    nodes/
    ā”œā”€ā”€ math.py          # Arithmetic operations
    ā”œā”€ā”€ text.py          # Text processing
    ā”œā”€ā”€ conversion.py    # Type conversions  
    ā”œā”€ā”€ logic.py         # Conditional logic
    ā”œā”€ā”€ data.py          # Lists and batching
    ā”œā”€ā”€ workflow.py      # Workflow helpers
    ā”œā”€ā”€ constants.py     # Constant values
    ā”œā”€ā”€ image.py         # Image utilities
    └── main.py          # Central registry
    

    Feel free to use, modify, or ignore as needed!