Nodes/ComfyUI_LC123_nodes/LC ✂️ Duplicate Tags 🏷️
ComfyUI Node

LC ✂️ Duplicate Tags 🏷️

Removes repeated tags so none gets double weight. Matches ignoring case, underscores and weights (long_hair = (long hair:1.2)). Sentences, blank-line breaks and BREAK pass through. Optional second prompt to merge two prompts and clean them together.

By lonecatone23·Created 2 months ago·Updated about 17 hours ago· 42
LC ✂️ Duplicate Tags 🏷️
    • text
    • removed
    ◄keepfirst►
    ◄text—►
    ◄text_2—►
    CategoryLC123/utils

    Inputs (3)

    NameTypeDefaultDescription
    keepCOMBOfirstWhich copy of a repeated tag stays. first: the first one, as written. strongest: the most heavily weighted one, placed where the first was.
    textoptSTRINGThe prompt to clean. Optional so either input can be bypassed upstream.
    text_2optSTRINGOptional second prompt, added after text and cleaned together (e.g. your own prompt plus LC Vision Danbooru Caption's).

    Outputs (2)

    NameTypeDescription
    textSTRINGThe prompt with every tag once.
    removedSTRINGThe tags that were taken out, for checking.