Nodes/ComfyUI-Dart/Dart Decode By Splited Parts
ComfyUI Node

Dart Decode By Splited Parts

Dart Decode By Splited Parts (DanbooruTagsTransformerDecodeBySplitedParts) — ComfyUI node guide

By nkchocoai·Created 2 years ago·Updated about a year ago· 33
Dart Decode By Splited Parts
  • tokenizer
  • token_ids
  • rating
  • copyright
  • character
  • people
  • other general

Dart Decode By Splited Parts is what you reach for when one big tag string isn't what you actually want - when you'd rather have the rating, the character, the copyright, and the rest of the tags as separate pieces you can route independently. It's the same decode job as the plain Dart Decode node, just done five times instead of once, along the same category lines the Compose Prompt nodes use to build the prompt in the first place.

Why you'd split instead of joining

Danbooru's own tagging system is categorical - general, character, copyright, artist, meta - and this pack's Compose Prompt nodes ask you for pieces in roughly that shape (rating, copyright, character, general tags) before combining them into one prompt string for the model. This node runs that in reverse on the output side: instead of one flat tag string, you get the model's generated content already sorted back into its parts. That's useful the moment you want to do something different with different pieces of a generation - feed the character name into a lookup for a matching LoRA trigger word, log which copyright/series the model picked across a seed sweep, or just inspect what it decided for each category without parsing a comma list by hand.

Inputs and outputs

Only two required inputs, both familiar from the rest of the pack: tokenizer (DART_TOKENIZER, from Dart Load) and token_ids (DART_TOKEN_IDS, which has to come from Dart Generate(Advanced) or a token-editing node downstream of it - this node doesn't accept the plain string output of regular Dart Generate, only raw tokens).

Where it earns its name is the outputs: instead of one STRING, you get five - rating, copyright, character, people, and other general - each its own STRING socket. The first three map directly onto Danbooru's own tag categories (rating and copyright are self-explanatory; character is named characters like hatsune_miku). people and other general split what would otherwise be one undifferentiated pile of general tags: people covers headcount-and-subject tags (things like 1girl, multiple_boys), while other general is everything else the model generated - poses, clothing, setting, expression, and so on.

Installing it

Install through ComfyUI Manager (search "ComfyUI-Dart") or clone by hand - cd ComfyUI/custom_nodes && git clone https://github.com/nkchocoai/ComfyUI-Dart.git, restart ComfyUI. It's part of the same pack as every other Dart node here, so there's no separate install step, and no extra model download: it only needs the tokenizer Dart Load already fetched.

What actually catches people out

The most common mistake is wiring the plain Dart Generate node's STRING output into this node expecting it to split - it won't, because this node needs token_ids, not a decoded string. You have to go through Dart Generate(Advanced) to get the raw tokens this node wants; the shortcut through the simple Generate node doesn't exist for splitting.

The other thing worth knowing going in: the split is a category label, not a guarantee of perfect classification. The model is generating tags, and where it decides a given tag "belongs" (say, into people versus other general) follows whatever pattern it learned from training data - it's not a hand-curated taxonomy check. If you're piping character straight into something that needs an exact, reliable match (a LoRA-trigger lookup, for instance), treat the output as a strong hint worth a sanity check rather than something to trust blindly on every generation.

CategoryDart

Inputs (2)

NameTypeDefaultDescription
tokenizerDART_TOKENIZER
token_idsDART_TOKEN_IDS

Outputs (5)

NameTypeDescription
ratingSTRING
copyrightSTRING
characterSTRING
peopleSTRING
other generalSTRING