Nodes/Ultra Tools/Ultra Tools Wildcard Browser
ComfyUI Node

Ultra Tools Wildcard Browser

Browse the folder, copy the call

By Yamoon-jjang·Created 14 days ago·Updated 9 days ago· 5
Ultra Tools Wildcard Browser
      ◄wildcards_pathF:\models\wildcards►
      ◄folder[Root]►
      ◄file_list►

      A copy-paste tool, and proud of it

      Wildcards are one of the oldest tricks in this ecosystem: __01_Natural/K-Pop/female_singer__ in a prompt gets replaced at queue time with a random line from that file, and suddenly one prompt is ten thousand prompts. The syntax is owned by the wildcard machinery you're already using - Impact Pack's wildcard processor, ComfyUI's native dynamic prompts behaviour, whichever pack you installed first.

      The friction isn't the syntax. It's finding the file. Wildcard libraries grow to thousands of .txt files across nested folders, and the UIs that list them tend to be a single enormous dropdown - or worse, a dropdown that comes up empty. Impact Pack's wildcard processor has a long-standing reputation for "the list doesn't show up / clicking does nothing," which is precisely the problem this node dodges.

      Ultra Tools Wildcard Browser is a file browser for your wildcard folder. Click into a folder, click into the next one, click the file you want, and the full call string - __folder/file__ - lands on your clipboard. Paste it into your prompt. That's it. It doesn't resolve wildcards, doesn't replace anything, doesn't participate in generation at all.

      How it works

      It's deliberately lazy. The node holds a wildcards_path and a current folder, and asks the server for one level at a time via the pack's HTTP routes rather than gathering the whole tree up front. That's why a 5,000-file library stays readable: you're never looking at 5,000 files, only the contents of the folder you clicked into.

      Details worth knowing from the implementation:

      • It lists .txt, .yaml, .yml and .json. Files with the same stem and different extensions are merged into one entry, ranked by extension priority, so your styles.txt and styles.json don't look like two wildcards.
      • Symlinks and Windows junctions are followed, with cycle detection: the resolver tracks the real paths of the ancestors it walked through and marks a folder as cycle rather than recursing forever. That's the failure that takes down naive tree walkers.
      • 📁 .. goes up a level, and the node remembers the last folder you were in, so reopening a workflow puts you back where you were.
      • It's not an output node and takes no wires, so it is never executed. If the wildcard drive is unplugged, your image generation doesn't fail - you just get an empty list in the browser.

      The inputs

      wildcards_path - a plain STRING, and the default is the author's own F:\models\wildcards. On Linux or macOS that's meaningless; put your real path in. It has to be readable by the ComfyUI process, so inside Docker it must be a mounted path, not a host path.

      folder - the current folder selector, showing [Root] until you dig in.

      file_list - the listing display, filled by the node. Clicking a file copies its call string.

      There are no outputs. The clipboard is the output.

      Install

      cd ComfyUI/custom_nodes
      git clone https://github.com/Yamoon-jjang/comfyui-Ultra-Tools
      

      Or Manager → Ultra Tools. Restart and Ctrl+F5 - the browser is web/wildcard_browser.js, and a stale bundle is the usual explanation for a node that lists nothing after an update. No pip dependencies of any kind; this is pathlib, os and a couple of routes.

      If you previously installed comfyui-Ultra-wildcard_browser as its own pack, delete that folder. This is the unified version and both register WildcardBrowser.

      Getting it right

      The copied string is not a promise. __01_Natural/K-Pop/female_singer__ resolves relative to whatever directory your wildcard processor is configured to read. If the browser is pointed at your D: drive and the processor is looking in its own custom_wildcards folder, the call will come back as literal text - that's the classic symptom of "wildcards aren't working," and it isn't the browser's fault. Point both at the same root.

      Path, not copy. Pointing the browser at a folder outside ComfyUI's install is fine and often the best choice: no re-copying when you reorganise, one library shared between machines.

      Nothing at runtime reads this path. Since the node doesn't execute, adding files doesn't require a restart; the browser reads the folder live when you click. The corollary is that if generation is broken by wildcards, looking here will never find it - go check the processor node and its configured search path.

      No syntax help beyond the call. The node copies paths, not {a|b|c} alternatives or $$ weighting. If your library leans on those, the prompt-engineering side of the KB has the syntax; the browser just gets you the filename without typing.

      CategoryUltra Tools

      Inputs (3)

      NameTypeDefaultDescription
      wildcards_pathSTRINGF:\models\wildcards—
      folderCOMBO[Root]1 options: [Root]
      file_listSTRING—

      Outputs (0)

      No outputs