Nodes/ComfyUI-Tagger/PixAI Tagger
ComfyUI Node

PixAI Tagger

The one that tells you which franchise the image is from

By sln77·Created 5 months ago·Updated 3 months ago· 6
PixAI Tagger
  • image
  • tags_string
  • character_tags
  • ip_tags
  • general_tags
model_filemodel_v0.9.pth
tags_filetags_v0.9_13k.json
char_map_filechar_ip_map.json
general_threshold0.30
character_threshold0.85
replace_underscorefalse
exclude_tags

Every tagger will tell you the character in the image. PixAI Tagger is the one that also tells you what they're from. Its party trick is a dedicated IP output: detect a character, look it up in a mapping file, and emit the franchise it belongs to. Find a random anime image and you get hatsune_miku and vocaloid without having to know either. That's the differentiator, and it's a genuinely useful one when you're trying to reverse-engineer someone's prompt from a screenshot.

It's PixAI Labs' own model (pixai-tagger-v0.9), a 13k-tag vocabulary that slots into the WD14 lineage rather than competing with the new heavyweight taggers. The code builds the encoder from SmilingWolf's wd-eva02-large-tagger-v3 repo via timm and loads PixAI's trained weights onto it - so this is effectively a WD14-family backbone with PixAI's head and vocab on top. Community reports call it faster than the typical tagger, which tracks: the eva02-large encoder at 448x448 is a known, well-optimized workhorse.

The two-threshold design

This is the node's real quirk, and it's worth understanding before you touch anything. PixAI doesn't use one cutoff - it uses two:

  • general_threshold (0.3) - deliberately low, so it grabs a fat list of general tags (poses, clothing, backgrounds).
  • character_threshold (0.85) - deliberately high, so only confident character detections make it through.

That asymmetry is the feature. General tags are cheap and plentiful, so it errs toward more of them; character tags are load-bearing (they name the person), so it errs toward precision. The default balance is good - leave general_threshold where it is and only nudge character_threshold down if the model keeps missing characters you can plainly see.

The remaining inputs are the pack's usual shapes: image, the three file paths (model_file, tags_file, char_map_file), replace_underscore, and exclude_tags. Outputs are tags_string (everything combined - wire this into a positive prompt or a captioning pass), plus character_tags, general_tags, and the distinctive ip_tags.

Installing it

Same pack install as the rest of the family - ComfyUI Manager (search "ComfyUI-Tagger") or:

cd ComfyUI/custom_nodes
git clone https://github.com/sln77/ComfyUI-Tagger
# restart ComfyUI

Then grab three files from pixai-labs/pixai-tagger-v0.9: model_v0.9.pth, tags_v0.9_13k.json, and char_ip_map.json. Any path works; the defaults assume the pack's models/ folder.

One genuine gotcha here, and it's the pack's dirtiest secret: the code imports timm, but the pack never declares it as a dependency. The pyproject.toml lists numpy, onnxruntime, Pillow, and torch - not timm. If you installed through ComfyUI Manager you'll probably be fine (ComfyUI's environment frequently already has it), but if PixAI Tagger throws an import error right after install, that's your culprit:

pip install timm

Also note this is the pack's only PyTorch-.pth tagger, so it wants to run on GPU (cuda if available, CPU otherwise) - same caveat as the others: fine for one-off tagging, slow for bulk.

The honest take

As a pure tagger it's a solid WD14 cousin, but 13k tags means it has thinner coverage of rare and obscure tags than Camie's 70k vocabulary. Where it wins is the IP mapping - nothing else in this pack gives you series identification as an output, and that alone justifies keeping it installed. Two taggers on one image, PixAI for the franchise and Camie for the deep general coverage, merged through a Tag Combiner, is a genuinely better setup than any single model on its own.

CategoryImage/Tagger

Inputs (8)

NameTypeDefaultDescription
imageIMAGE
model_fileSTRINGmodel_v0.9.pth
tags_fileSTRINGtags_v0.9_13k.json
char_map_fileSTRINGchar_ip_map.json
general_thresholdFLOAT0.300–1
character_thresholdFLOAT0.850–1
replace_underscoreBOOLEANfalse
exclude_tagsSTRING

Outputs (4)

NameTypeDescription
tags_stringSTRING
character_tagsSTRING
ip_tagsSTRING
general_tagsSTRING