mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-01-23 07:51:18 +01:00
Fix jailbreak prompt not being overwritten by character
This commit is contained in:
parent
221ecbf8d6
commit
4ed92d69b0
@ -239,7 +239,7 @@ PromptManagerModule.prototype.init = function (moduleConfiguration, serviceSetti
|
|||||||
prompts.set(systemPrompt, prompts.index('main'));
|
prompts.set(systemPrompt, prompts.index('main'));
|
||||||
}
|
}
|
||||||
|
|
||||||
const jailbreakPromptOverride = this.activeCharacter.data?.jailbreak_prompt ?? null;
|
const jailbreakPromptOverride = this.activeCharacter.data?.post_history_instructions ?? null;
|
||||||
const jailbreakPrompt = prompts.get('jailbreak') ?? null;
|
const jailbreakPrompt = prompts.get('jailbreak') ?? null;
|
||||||
if (jailbreakPromptOverride && jailbreakPrompt) {
|
if (jailbreakPromptOverride && jailbreakPrompt) {
|
||||||
jailbreakPrompt.content = jailbreakPromptOverride;
|
jailbreakPrompt.content = jailbreakPromptOverride;
|
||||||
@ -607,6 +607,9 @@ PromptManagerModule.prototype.loadPromptIntoEditForm = function (prompt) {
|
|||||||
roleField.disabled = true;
|
roleField.disabled = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const resetPromptButton = document.getElementById(this.configuration.prefix + 'prompt_manager_popup_entry_form_reset');
|
||||||
|
resetPromptButton.dataset.pmPrompt = prompt.identifier;
|
||||||
|
|
||||||
const savePromptButton = document.getElementById(this.configuration.prefix + 'prompt_manager_popup_entry_form_save');
|
const savePromptButton = document.getElementById(this.configuration.prefix + 'prompt_manager_popup_entry_form_save');
|
||||||
savePromptButton.dataset.pmPrompt = prompt.identifier;
|
savePromptButton.dataset.pmPrompt = prompt.identifier;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user