-
Notifications
You must be signed in to change notification settings - Fork 315
Advanced
This feature can be used when the detection model detects more than 1 object and you want to apply different prompts to each object.
You can separate the prompts with [SEP]
to apply them in order. (To be precise, it is split by the regex \s*\[SEP\]\s*
.)
If there are more detected objects than separate prompts, the last prompt will be used for the rest.
The order in which objects are detected is highly arbitrary, so use with caution.
masterpiece, 1girl, red hair, red eyes, __woman_clothes__ [SEP] masterpiece, 1girl, blue hair, blue eyes, __woman_clothes__
If there is only one object detected, only the first prompt masterpiece, 1girl, red hair, red eyes, __woman_clothes__
applies.
If there are two, then masterpiece, 1girl, red hair, red eyes, __woman_clothes__
and masterpiece, 1girl, blue hair, blue eyes, __woman_clothes__
are applied in that order.
If there are more than three, the last prompt is applied to the remaining objects. masterpiece, 1girl, blue hair, blue eyes, __woman_clothes__
If any prompt is left blank, the default prompt is applied as if nothing had been typed in the prompt box.
Input prompt:
masterpiece, best quality, 4girls
ADetailer prompt:
masterpiece, 1girl, red hair, red eyes [SEP] [SEP] masterpiece, 1girl, blue hair, blue eyes
The second prompt is blank, so if there are 5 detected objects, the prompts that would apply would be, in order, as follows:
masterpiece, 1girl, red hair, red eyes
masterpiece, best quality, 4girls
masterpiece, 1girl, blue hair, blue eyes
masterpiece, 1girl, blue hair, blue eyes
masterpiece, 1girl, blue hair, blue eyes
If the prompt for any part is [SKIP]
, that part is skipped without inpainting.
(Precisely, if it matches the regex ^\s*\[SKIP\]\s*$
).
The [PROMPT]
token is replaced with the original prompt (or negative prompt).
Input prompt:
masterpiece, best quality, 1girl
ADetailer prompt:
[PROMPT], red eyes
Result:
masterpiece, best quality, 1girl, red eyes