mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Fix SD group gen bugs
This commit is contained in:
@ -2378,10 +2378,6 @@ async function Generate(type, { automatic_trigger, force_name2, resolve, reject,
|
|||||||
abortController = new AbortController();
|
abortController = new AbortController();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (main_api == 'novel' && quiet_prompt) {
|
|
||||||
quiet_prompt = adjustNovelInstructionPrompt(quiet_prompt);
|
|
||||||
}
|
|
||||||
|
|
||||||
// OpenAI doesn't need instruct mode. Use OAI main prompt instead.
|
// OpenAI doesn't need instruct mode. Use OAI main prompt instead.
|
||||||
const isInstruct = power_user.instruct.enabled && main_api !== 'openai';
|
const isInstruct = power_user.instruct.enabled && main_api !== 'openai';
|
||||||
const isImpersonate = type == "impersonate";
|
const isImpersonate = type == "impersonate";
|
||||||
@ -2470,6 +2466,11 @@ async function Generate(type, { automatic_trigger, force_name2, resolve, reject,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (quiet_prompt) {
|
||||||
|
quiet_prompt = substituteParams(quiet_prompt);
|
||||||
|
quiet_prompt = main_api == 'novel' ? adjustNovelInstructionPrompt(quiet_prompt) : quiet_prompt;
|
||||||
|
}
|
||||||
|
|
||||||
if (true === dryRun ||
|
if (true === dryRun ||
|
||||||
(online_status != 'no_connection' && this_chid != undefined && this_chid !== 'invalid-safety-id')) {
|
(online_status != 'no_connection' && this_chid != undefined && this_chid !== 'invalid-safety-id')) {
|
||||||
let textareaText;
|
let textareaText;
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
import {
|
import {
|
||||||
substituteParams,
|
|
||||||
saveSettingsDebounced,
|
saveSettingsDebounced,
|
||||||
systemUserName,
|
systemUserName,
|
||||||
hideSwipeButtons,
|
hideSwipeButtons,
|
||||||
@ -513,7 +512,7 @@ function getQuietPrompt(mode, trigger) {
|
|||||||
return trigger;
|
return trigger;
|
||||||
}
|
}
|
||||||
|
|
||||||
return substituteParams(stringFormat(extension_settings.sd.prompts[mode], trigger));
|
return stringFormat(extension_settings.sd.prompts[mode], trigger);
|
||||||
}
|
}
|
||||||
|
|
||||||
function processReply(str) {
|
function processReply(str) {
|
||||||
@ -862,7 +861,7 @@ async function sdMessageButton(e) {
|
|||||||
const message_id = $mes.attr('mesid');
|
const message_id = $mes.attr('mesid');
|
||||||
const message = context.chat[message_id];
|
const message = context.chat[message_id];
|
||||||
const characterName = message?.name || context.name2;
|
const characterName = message?.name || context.name2;
|
||||||
const messageText = substituteParams(message?.mes);
|
const messageText = message?.mes;
|
||||||
const hasSavedImage = message?.extra?.image && message?.extra?.title;
|
const hasSavedImage = message?.extra?.image && message?.extra?.title;
|
||||||
|
|
||||||
if ($icon.hasClass(busyClass)) {
|
if ($icon.hasClass(busyClass)) {
|
||||||
|
Reference in New Issue
Block a user