[Bug fix] Remove html tags form the Prompt sent to Stable Diffusion (#3151)

This commit is contained in:
SodaPrettyCold 2023-08-05 07:20:28 +08:00 committed by GitHub
parent 6e30f76ba5
commit 23055b21ee
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -133,6 +133,9 @@ def get_SD_pictures(description, character):
if params['manage_VRAM']: if params['manage_VRAM']:
give_VRAM_priority('SD') give_VRAM_priority('SD')
description = re.sub('<audio.*?</audio>', ' ', description)
description = f"({description}:1)"
payload = { payload = {
"prompt": params['prompt_prefix'] + description, "prompt": params['prompt_prefix'] + description,
"seed": params['seed'], "seed": params['seed'],