CFG: NAI fixes

NAI does CFG differently, so add special cases for them. Also gate
CFG access to only work on textgenwebui since that's where it's
implemented.

Signed-off-by: kingbri <bdashore3@proton.me>
This commit is contained in:
kingbri
2023-08-20 19:51:01 -04:00
parent 4ea9e481a8
commit 60faaf1831
2 changed files with 6 additions and 1 deletions

View File

@@ -2971,7 +2971,7 @@ async function Generate(type, { automatic_trigger, force_name2, resolve, reject,
}
// Get the negative prompt first since it has the unmodified mesSend array
let negativePrompt = getCombinedPrompt(true);
let negativePrompt = main_api == 'textgenerationwebui' ? getCombinedPrompt(true) : undefined;
let finalPromt = getCombinedPrompt(false);
const cfgValues = {
guidanceScale: cfgGuidanceScale?.value,