Closed zymox closed 3 months ago
Are you using a Multiline Text to feed to CLIPTextEncode? I disabled it on that node so it can handle JSON and code for all the LLM stuff.
On Sun, May 26, 2024, 5:15 AM zymox @.***> wrote:
If I'm using a prompt like "a woman wearing a {red|green|blue} shirt" with the "CLIP Text Encode (NSP)" node, the random selection doesn't work anymore, it seems to take the prompt as is, resulting in color bleeding / multiple colored shirts. Wildcards/NSP still work fine.
It used to behave here like it still does with the ComfyUI native "CLIP Text Encode (Prompt)" node, where it selects a random text from the given list.
I'm not sure when this broke, but I'm sure that it used to work.
— Reply to this email directly, view it on GitHub https://github.com/WASasquatch/was-node-suite-comfyui/issues/404, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIZEZPLSMHLXX3DLMT2L2DZEHG5BAVCNFSM6AAAAABIJX45OWVHI2DSMVQWIX3LMV43ASLTON2WKOZSGMYTONRXGUZDINI . You are receiving this because you are subscribed to this thread.Message ID: @.***>
No, just simple single line text that contains both wildcards and this random list. I use this node to parse the wildcards, but now it stopped understanding the simple random list.
Any way I can re-enable it? Maybe it could be turned into a switch on the node?
Yeah, I'll re-enable it an add a new one for raw (without it)
On Sun, May 26, 2024, 10:26 AM zymox @.***> wrote:
No, just simple single line text that contains both wildcards and this random list. I use this node to parse the wildcards, but now it stopped understanding the simple random list.
Any way I can re-enable it? Maybe it could be turned into a switch on the node?
— Reply to this email directly, view it on GitHub https://github.com/WASasquatch/was-node-suite-comfyui/issues/404#issuecomment-2132292784, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIZEZIZ7FH24Z2S5VX2LNLZEILLHAVCNFSM6AAAAABIJX45OWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMZSGI4TENZYGQ . You are receiving this because you commented.Message ID: @.***>
Alright, original Multiline is reverted: https://github.com/WASasquatch/was-node-suite-comfyui/commit/c258f1115dc52bc82b7c20bb5635f10cc369f62e
Doesn't seem to work. Your commit only seems to be about the Text Multiline node, which I'm not using.
Ah, well CLIPTextEncode NSP should work. I haven't touched that node in well over a year.
Yeah, weird, but it doesn't work, at least not for me. Maybe you can verify.
Example workflow "three women wearing {red|green|blue} shirts":
It does work if I put the text through the Text Multiline node first so the dynamic prompts get parsed there.
Found the reason in the code ... You're using the wrong brackets in your regex:
parse_prompt = re.sub(r'\<(.*?)\>', replace_match, prompt)
It works with <red|green|blue> instead of {red|green|blue}.
No, that's how I do it. The {}
are for JS, which would replace before
hitting the backend. There is usage on the readme.
On Tue, Jun 4, 2024, 9:40 AM zymox @.***> wrote:
Found the reason in the code ... You're using the wrong brackets in your regex:
parse_prompt = re.sub(r'\<(.*?)>', replace_match, prompt)
It works with <red|green|blue> instead of {red|green|blue}.
— Reply to this email directly, view it on GitHub https://github.com/WASasquatch/was-node-suite-comfyui/issues/404#issuecomment-2147969949, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIZEZOUIGIKHDNUXQ77DD3ZFXUZRAVCNFSM6AAAAABIJX45OWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNBXHE3DSOJUHE . You are receiving this because you commented.Message ID: @.***>
Even in the node that you fixed a few comments above it works (and only works) with "{ }" so it's not exactly consistent behaviour
But whatever, I know how to use it now :) i'll close this, thanks for your time
And you aren't using multiline text to hook up to nsp to provide the text? What commit works prior?
On Tue, Jun 4, 2024, 10:17 AM zymox @.***> wrote:
Even in the node that you fixed a few comments above it works (and only works) with "{ }" so it's not exactly consistent behaviour image.png (view on web) https://github.com/WASasquatch/was-node-suite-comfyui/assets/18327640/7c145162-e991-41cc-8f04-2f40672e8314
But whatever, I know how to use it now :) i'll close this, thanks for your time
— Reply to this email directly, view it on GitHub https://github.com/WASasquatch/was-node-suite-comfyui/issues/404#issuecomment-2148033304, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAIZEZLZ5I2C2UY4BYBC5TDZFXZEFAVCNFSM6AAAAABIJX45OWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCNBYGAZTGMZQGQ . You are receiving this because you commented.Message ID: @.***>
If I'm using a prompt like "a woman wearing a {red|green|blue} shirt" with the "CLIP Text Encode (NSP)" node, the random selection doesn't work anymore, it seems to take the prompt as is, resulting in color bleeding / multiple colored shirts. Wildcards/NSP still work fine.
It used to behave here like it still does with the ComfyUI native "CLIP Text Encode (Prompt)" node, where it selects a random text from the given list.
I'm not sure when this broke, but I'm sure that it used to work.