Nodes/SAX Bridge/SAX Tag Dictionary
ComfyUI Node

SAX Tag Dictionary

A Node With No Wires That Keeps Your Danbooru Tags Current

By so16tm·Created 7 months ago·Updated a day ago· 2
SAX Tag Dictionary

      Most custom nodes are a black box with sockets on both ends. This one has no sockets at all. It's a button in a box, and all it does is download a file - which sounds useless until you remember what happens when your tag autocomplete is six months stale and the model you're prompting was trained on vocabulary you can't spell.

      What it is

      SAX_Bridge_Tag_Dictionary (display name "SAX Tag Dictionary") is a standalone utility from the SAX_Bridge pack. No inputs, no outputs, nothing to wire it to. You drop it on the canvas, press one button, and it fetches the newest published Danbooru-compatible tag CSV into your ComfyUI install so that tag autocomplete has something accurate to suggest from.

      If you prompt Illustrious, NoobAI, WAI, Pony or anything else from the Danbooru-trained family, your prompt is a list of database keys, not a description. Getting the exact string right - long_hair vs long hair, a character tag vs a copyright tag - is the whole game. The catalog panel goes further and calls tag prompting the precision interface for those models, and notes that anything popular on the board resolves by name. A stale or partial tag list doesn't just make autocomplete annoying; it quietly narrows what you can ask for.

      Where this node earns its place is the migration story. Lots of people still carry a danbooru.csv downloaded in 2023 for the A1111 tag-autocomplete extension, and that habit has been drifting around the ComfyUI ecosystem ever since - Impact Pack used to carry wildcards and dynamic prompting for half the ecosystem, and SAX_Bridge now ships explicitly without requiring it. This node is the small, single-purpose piece that keeps the vocabulary half current.

      How it works

      There's no workflow execution involved. The button in the node's UI posts to a route on the ComfyUI server (/sax/tag-dictionary/update), and the Python side does the fetch:

      • It reads the published file list from DraconicDragon/dbr-e621-lists-archive, picks the newest file matching danbooru_YYYY-MM-DD_pt20-ia-dd.csv, and downloads it.
      • It validates before touching anything: size cap of 32 MiB, four columns per row, category in the booru set, no duplicate names. Then it replaces your existing file atomically, so a failed download leaves the old one intact.
      • Only one update can run at a time; a second click from another browser tab gets a busy error rather than a half-written file.

      Two details are better than they needed to be. Files downloaded from that archive carry the tags used in at least 20 posts plus active and deleted aliases, which is why the filename says pt20. And because Autocomplete++ treats a line starting with # as a comment, the writer quotes real tags that begin with a hash - #compass survives instead of silently vanishing from your suggestions.

      Install and run it

      No pip dependencies. The pack's pyproject.toml declares an empty dependency list, and there's no root requirements.txt - it's plain ComfyUI plus optional Autocomplete++.

      cd ComfyUI/custom_nodes
      git clone https://github.com/so16tm/SAX_Bridge
      

      Restart ComfyUI. In ComfyUI Manager you can also use Install via Git URL with https://github.com/so16tm/SAX_Bridge.

      Then:

      1. Right-click → Add Node → SAX/Bridge/Utility → SAX Tag Dictionary.
      2. Press 最新CSVを取得 - the button label is Japanese even in the English docs; it means "Get latest CSV". Nothing downloads at startup, and queuing the graph downloads nothing either.
      3. If Autocomplete++ is installed, reload the browser and pick sax_danbooru.csv in its Main Tag File setting. If a controller node overrides that setting, change it there too.

      Files land in sax_tag_dictionary/sax_danbooru.csv under ComfyUI's system user directory, with a copy placed in Autocomplete++'s own tags/ folder. Your existing danbooru.csv and any translation dictionaries are left alone - this adds a file, it doesn't take one over.

      Where people get stuck

      The node works without Autocomplete++, but then nothing reads the CSV and you'll wonder what the button did. It's a dictionary provider, not an expander.

      Click failed with a 502? That's the server failing to reach GitHub - ComfyUI's host needs outbound internet, not just your browser. A 400 means the archive handed back something that didn't validate; your previous file is still in place.

      If you've hand-edited the dedicated copy, SAX refuses to overwrite it. That's deliberate - archive your edits elsewhere or delete the file, then update.

      And "latest" means the archive's latest, not today's Danbooru. Those lists are published roughly quarterly, so a file dated a couple of months back is normal, not broken.

      Honest note on the pack

      SAX_Bridge is young and near-invisible on Reddit - a literal phrase count for "SAX Bridge" through late 2026 returns nothing in our corpus. What it does have is a 1,400-line node reference, CI, and a test suite, which is more care than most packs with a hundred times the chatter. You're early, not late.

      CategorySAX/Bridge/Utility

      Inputs (0)

      No inputs

      Outputs (0)

      No outputs