Nodes/ComfyUI Gender Tag Filter/Gender Tag Filter πŸ³οΈβ€πŸŒˆ
ComfyUI Node

Gender Tag Filter πŸ³οΈβ€πŸŒˆ

A ComfyUI node in utils/tags with 11 inputs and 1 output.

By senjinthedragonΒ·Created 5 months agoΒ·Updated 5 months agoΒ· 0
Gender Tag Filter πŸ³οΈβ€πŸŒˆ
  • spacy_nlp
  • filtered_tags
β—„textβ–Ί
β—„modestrip_female_tagsβ–Ί
β—„filter_anatomytrueβ–Ί
β—„replace_anatomyfalseβ–Ί
β—„filter_presentationfalseβ–Ί
β—„swap_clothingtrueβ–Ί
β—„use_underscorestrueβ–Ί
β—„rewrite_referencestrueβ–Ί
β—„map_neopronounstrueβ–Ί
β—„handle_negationstrueβ–Ί
Categoryutils/tags

Inputs (11)

NameTypeDefaultDescription
textSTRINGTag string to filter. NL fragments are detected and preserved automatically.
modeCOMBOstrip_female_tags'strip_female_tags' -> remove female anatomy/presentation tags 'strip_male_tags' -> remove male anatomy/presentation tags 'format_only' -> no filtering; apply use_underscores only 'off' -> pass through completely unchanged
filter_anatomyBOOLEANtrueRemove explicit anatomical tags for the unwanted gender. Also scans compound tags for anatomy root words, so huge_breasts, breast_grab, hanging_breasts etc. are all caught even if not individually listed.
replace_anatomyBOOLEANfalseReplace removed anatomy tags with gender-appropriate counterparts instead of just deleting them. e.g. large_breasts -> muscular_chest, breasts -> pecs 1girl -> 1boy, yuri -> yaoi, cameltoe -> bulge Has no effect when filter_anatomy is off.
filter_presentationBOOLEANfalseRemove gendered clothing, accessory, and makeup tags. Disable for crossdressing characters.
swap_clothingBOOLEANtrueWhen filter_presentation is on, replace clothing tags with gender-appropriate equivalents instead of just removing. e.g. skirt -> trousers, bikini -> swim_trunks, evening_gown -> tuxedo, bra -> removed (no equivalent) Has no effect when filter_presentation is off.
use_underscoresBOOLEANtrueOutput word separator style. On -> big_breasts (Danbooru/e621, most SDXL models) Off -> big breasts (some fine-tuned models) Input tags are always accepted in either style. Natural language fragments bypass this setting entirely.
rewrite_referencesBOOLEANtrueSwap standalone gendered noun tags. woman -> man, girl -> boy, vixen -> fox, doe -> buck etc. Covers the same word set as the NL Filter's rewrite_references for consistent behaviour across both nodes.
map_neopronounsBOOLEANtrueMap neopronoun tags to binary equivalents that image models are likely to recognise from their training data. Covers: shi/hir (Chakat/furry), they/them, xe/xem, ze/zir, ey/em (Spivak), fae/faer, ve/ver, per. When off, neopronoun tags pass through unchanged.
handle_negationsBOOLEANtrueProtect tags that appear in a negated context from removal. e.g. in a mixed prompt, 'no breasts' will leave the tag untouched rather than removing it. Uses a 4-token proximity heuristic.
spacy_nlpoptSPACY_NLPConnect a SpaCy Model Loader node to enable spaCy-backed NL fragment detection. Leave disconnected to use the stop-word heuristic fallback instead.

Outputs (1)

NameTypeDescription
filtered_tagsSTRINGβ€”