Nodes/Presentation ComfyUI/Presentation File
ComfyUI Node

Presentation File

Let people pick checkpoints and LoRAs without touching the graph

By niknah·Created 11 months ago·Updated 4 months ago· 5
Presentation File
    • filename
    pathoutput
    regex.
    value

    Presentation File is the workhorse of this pack. If you're shipping a ComfyUI workflow as a website - which is exactly what niknah's Presentation ComfyUI does - this is the node that lets the person on the other end choose which model, LoRA, or file gets used, without ever seeing a wire or a node.

    The README lists it first for a reason: "Used to pick models, loras, etc." You put the nodes you want your users to touch inside a group with a Presentation Tab node, and where you'd normally let them free-type a filename, you drop a Presentation File so they get a real browser instead. There's a YouTube walkthrough linked from the README, but the short version is: point it at a folder, filter with a regex, and connect the filename output wherever a path is expected.

    How it works

    Under the hood it's deceptively simple. The Python class is a stub - pickfile returns (value,), the string you gave it. The browsing magic lives in the generated Nuxt site, whose files API recursively scans the folder you named, matches your regex (case-insensitive), and returns a sorted file list. The site renders that as a picker, and the chosen value is written back into the workflow's JSON before it runs.

    The one piece of genuine Python logic is IS_CHANGED, which hashes path, regex, and value. That's what makes ComfyUI re-queue when the user picks a different file - without it, the sampler would see "same inputs as last time" and skip. It's the difference between a picker that works and a picker that politely ignores you.

    The inputs that matter

    • path (default output) - which ComfyUI folder to browse. Anything in folder_paths.py: input, output, checkpoints, loras, vae, text_encoders, diffusion_models, clip_vision, diffusers, upscale_models. For models, point it at checkpoints or loras.
    • regex (default . - matches everything) - filter by extension or name. \.(safetensors|ckpt)$ for model files.
    • value - the default file, pre-selected when the site loads.

    Output: filename, a wildcard * string. It plugs into anything that reads a file path - CheckpointLoaderSimple, LoraLoader, LoadImage, you name it. That wildcard type is deliberate: Presentation is designed to "plug into most things that reads a file, models, loras, load image / audio / etc."

    How to install it

    One install for the whole pack. ComfyUI Manager, search "Presentation ComfyUI", or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/niknah/presentation-ComfyUI
    

    then restart. Prereqs: Node.js installed separately (README links nodejs.org). First launch copies the Nuxt site to output/presentation-site and runs npm install - budget a few minutes. The site lives at http://localhost:3000. The pack's only Python dependency is psutil, which is basically free.

    Common issues & troubleshooting

    The picker lists files the user shouldn't have. That's on your path and regex. path decides the folder, regex decides what's visible in it. In multi-user mode, remember each user's files live in output/<username>.

    Selecting a file doesn't re-run the workflow. If you see the value change but the queue doesn't pick it up, check the node isn't muted or bypassed - IS_CHANGED only fires when the node actually runs.

    The site needs a kick after workflow edits. Settings → Presentation → Restart, or Rebuild if the layout is stale. And if things look wrong, make sure there isn't a second nuxt process holding the same folder.

    Regex grief. The default . regex is "everything," and it's a regex - so safetensors as a literal matches any filename containing "safetensors," which is usually fine, but \.safetensors$ is the exact version when you need it.

    CategoryPresentation

    Inputs (3)

    NameTypeDefaultDescription
    pathSTRINGoutputCan be anything defined in folder_paths.py. input, output, checkpoints, loras, vae, text_encoders, diffusion_models, clip_vision, diffusers, upscale_models
    regexoptSTRING.Example: \.(gif|png|webp)$
    valueoptSTRINGDefault file

    Outputs (1)

    NameTypeDescription
    filename*