TC sysprompt: Add Post-History Instructions control Closes #3920

775ae0f5570e2adda3f986a383e62113a3b1213d

Cohee <18619528+Cohee1207@users.noreply.github.com>

48 files changed, +30 -62Showing whitespace changes
default/content/presets/context/Adventure.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": false,6 "always_force_name2": false,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": true,8 "single_line": true,
default/content/presets/context/Alpaca-Single-Turn.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": false,6 "always_force_name2": false,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Alpaca.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/ChatML-Names.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/ChatML.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Command R.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "<|START_OF_TURN_TOKEN|><|SYSTEM_TOKEN|>New Roleplay:<|END_OF_TURN_TOKEN|>",4 "chat_start": "<|START_OF_TURN_TOKEN|><|SYSTEM_TOKEN|>New Roleplay:<|END_OF_TURN_TOKEN|>",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/DeepSeek-V2.5.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Default.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "***",3 "example_separator": "***",
4 "chat_start": "***",4 "chat_start": "***",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/DreamGen Role-Play V1 ChatML.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": false,6 "always_force_name2": false,
8 "trim_sentences": true,7 "trim_sentences": true,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/DreamGen Role-Play V1 Llama3.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "<|eot_id|>\n<|start_header_id|>user<|end_header_id|>\n\nWrite an example narrative / conversation that is not part of the main story.",3 "example_separator": "<|eot_id|>\n<|start_header_id|>user<|end_header_id|>\n\nWrite an example narrative / conversation that is not part of the main story.",
4 "chat_start": "<|eot_id|>\n<|start_header_id|>user<|end_header_id|>\n\nStart the role-play between {{char}} and {{user}}.",4 "chat_start": "<|eot_id|>\n<|start_header_id|>user<|end_header_id|>\n\nStart the role-play between {{char}} and {{user}}.",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": false,6 "always_force_name2": false,
8 "trim_sentences": true,7 "trim_sentences": true,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/GLM-4.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Gemma 2.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Libra-32B.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "### Example:",3 "example_separator": "### Example:",
4 "chat_start": "### START ROLEPLAY:",4 "chat_start": "### START ROLEPLAY:",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Lightning 1.1.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "Example of an interaction:\n",3 "example_separator": "Example of an interaction:\n",
4 "chat_start": "This is the history of the roleplay:\n",4 "chat_start": "This is the history of the roleplay:\n",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Llama 2 Chat.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Llama 3 Instruct.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Llama 4 Instruct.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Llama-3-Instruct-Names.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Minimalist.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Mistral V1.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Mistral V2 & V3.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Mistral V3-Tekken.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Mistral V7.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/NovelAI.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "***",3 "example_separator": "***",
4 "chat_start": "***",4 "chat_start": "***",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/OldDefault.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "This is how {{char}} should talk",3 "example_separator": "This is how {{char}} should talk",
4 "chat_start": "\nThen the roleplay chat between {{user}} and {{char}} begins.\n",4 "chat_start": "\nThen the roleplay chat between {{user}} and {{char}} begins.\n",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Phi.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Pygmalion.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Story.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Synthia.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/Tulu.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "",3 "example_separator": "",
4 "chat_start": "",4 "chat_start": "",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
default/content/presets/context/simple-proxy-for-tavern.json+0 -1
@@ -3,7 +3,6 @@
3 "example_separator": "### New Roleplay:",3 "example_separator": "### New Roleplay:",
4 "chat_start": "### New Roleplay:",4 "chat_start": "### New Roleplay:",
5 "use_stop_strings": false,5 "use_stop_strings": false,
6 "allow_jailbreak": false,
7 "always_force_name2": true,6 "always_force_name2": true,
8 "trim_sentences": false,7 "trim_sentences": false,
9 "single_line": false,8 "single_line": false,
public/index.html+7 -8
@@ -3622,11 +3622,6 @@
3622 <small data-i18n="Names as Stop Strings">Names as Stop Strings</small>3622 <small data-i18n="Names as Stop Strings">Names as Stop Strings</small>
3623 </label>3623 </label>
3624 </div>3624 </div>
3625
3626 <label class="checkbox_label" title="Includes Post-History Instructions at the end of the prompt, if defined in the character card AND ''Prefer Char. Instructions'' is enabled.&#10;THIS IS NOT RECOMMENDED FOR TEXT COMPLETION MODELS, CAN LEAD TO BAD OUTPUT." data-i18n="[title]context_allow_post_history_instructions">
3627 <input id="context_allow_jailbreak" type="checkbox" />
3628 <small data-i18n="Allow Post-History Instructions">Allow Post-History Instructions</small>
3629 </label>
3630 </div>3625 </div>
3631 </div>3626 </div>
3632 </div>3627 </div>
@@ -3816,7 +3811,7 @@
3816 </details>3811 </details>
3817 </div>3812 </div>
3818 </div>3813 </div>
3819 <div id="SystemPromptColumn" class="flex-container flexNoGap flexFlowColumn flex1">3814 <div id="SystemPromptColumn" class="flex-container flexNoGap flexFlowColumn flex1 marginBot10">
3820 <h4 class="standoutHeader title_restorable justifySpaceBetween">3815 <h4 class="standoutHeader title_restorable justifySpaceBetween">
3821 <div class="flex-container">3816 <div class="flex-container">
3822 <span data-i18n="System Prompt">System Prompt</span>3817 <span data-i18n="System Prompt">System Prompt</span>
@@ -3852,10 +3847,14 @@
3852 </label>3847 </label>
3853 <textarea id="sysprompt_content" class="text_pole textarea_compact autoSetHeight"></textarea>3848 <textarea id="sysprompt_content" class="text_pole textarea_compact autoSetHeight"></textarea>
3854 </div>3849 </div>
3855 </div>
38563850
3857 <div>3851 <div>
3858 &nbsp;3852 <label for="sysprompt_post_history" class="flex-container">
3853 <small data-i18n="Post-History Instructions">Post-History Instructions</small>
3854 <i class="editor_maximize fa-solid fa-maximize right_menu_button" data-for="sysprompt_post_history" title="Expand the editor" data-i18n="[title]Expand the editor"></i>
3855 </label>
3856 <textarea id="sysprompt_post_history" class="text_pole textarea_compact autoSetHeight"></textarea>
3857 </div>
3859 </div>3858 </div>
38603859
3861 <div>3860 <div>
public/locales/ar-sa.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "بداية الدردشة",411 "Chat Start": "بداية الدردشة",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "أضف بداية الدردشة وفاصل الأمثلة إلى قائمة سلاسل التوقف.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "أضف بداية الدردشة وفاصل الأمثلة إلى قائمة سلاسل التوقف.",
413 "Use as Stop Strings": "استخدم كسلاسل التوقف",413 "Use as Stop Strings": "استخدم كسلاسل التوقف",
414 "context_allow_jailbreak": "يتضمن كسر الحماية في نهاية المطالبة، إذا تم تحديده في بطاقة الشخصية و''Prefer Char. تم تمكين الهروب من السجن.\nلا يُنصح بهذا بالنسبة لنماذج إكمال النص، فقد يؤدي إلى نتائج سيئة.",
415 "Allow Jailbreak": "السماح بالجيلبريك",414 "Allow Jailbreak": "السماح بالجيلبريك",
416 "Context Order": "ترتيب السياق",415 "Context Order": "ترتيب السياق",
417 "Summary": "ملخص",416 "Summary": "ملخص",
public/locales/de-de.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Chat-Start",411 "Chat Start": "Chat-Start",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Fügen Sie einer Liste von Stoppzeichenfolgen „Chat-Start“ und „Beispieltrennzeichen“ hinzu.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Fügen Sie einer Liste von Stoppzeichenfolgen „Chat-Start“ und „Beispieltrennzeichen“ hinzu.",
413 "Use as Stop Strings": "Verwende als Stoppzeichenfolgen",413 "Use as Stop Strings": "Verwende als Stoppzeichenfolgen",
414 "context_allow_jailbreak": "Schließt Jailbreak am Ende der Eingabeaufforderung ein, wenn dies in der Charakterkarte definiert ist UND „Charakter-Jailbreak bevorzugen“ aktiviert ist.\nDIES WIRD FÜR TEXTVERVOLLSTÄNDIGUNGSMODELLE NICHT EMPFOHLEN, KANN ZU SCHLECHTEN AUSGABEN FÜHREN.",
415 "Allow Jailbreak": "Jailbreak zulassen",414 "Allow Jailbreak": "Jailbreak zulassen",
416 "Context Order": "Kontextreihenfolge",415 "Context Order": "Kontextreihenfolge",
417 "Summary": "Zusammenfassung",416 "Summary": "Zusammenfassung",
public/locales/es-es.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Inicio de chat",411 "Chat Start": "Inicio de chat",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Agregue Inicio de chat y Separador de ejemplo a una lista de cadenas de parada.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Agregue Inicio de chat y Separador de ejemplo a una lista de cadenas de parada.",
413 "Use as Stop Strings": "Usar como Cadenas de Parada",413 "Use as Stop Strings": "Usar como Cadenas de Parada",
414 "context_allow_jailbreak": "Incluye Jailbreak al final del mensaje, si está definido en la tarjeta de personaje Y está habilitado \"Prefer Char. Jailbreak\".\nESTO NO SE RECOMIENDA PARA MODELOS DE COMPLETO DE TEXTO, PUEDE PRODUCIR UN RESULTADO INCORRECTO.",
415 "Allow Jailbreak": "Permitir Jailbreak",414 "Allow Jailbreak": "Permitir Jailbreak",
416 "Context Order": "Orden de contexto",415 "Context Order": "Orden de contexto",
417 "Summary": "Resumen",416 "Summary": "Resumen",
public/locales/is-is.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Chat Start",411 "Chat Start": "Chat Start",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Bættu Chat Start og Example Separator við lista yfir stöðvunarstrengi.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Bættu Chat Start og Example Separator við lista yfir stöðvunarstrengi.",
413 "Use as Stop Strings": "Nota sem Stoppa Strengir",413 "Use as Stop Strings": "Nota sem Stoppa Strengir",
414 "context_allow_jailbreak": "Inniheldur Jailbreak í lok hvetjunnar, ef það er skilgreint á stafkortinu OG ''Velst Char. Jailbreak'' er virkt.\nÞETTA ER EKKI MÆLT FYRIR TEXTAÚRSLUNARGERÐ, GETUR leitt til lélegrar úttaks.",
415 "Allow Jailbreak": "Leyfa jailbreak",414 "Allow Jailbreak": "Leyfa jailbreak",
416 "Context Order": "Samhengisröð",415 "Context Order": "Samhengisröð",
417 "Summary": "Samantekt",416 "Summary": "Samantekt",
public/locales/it-it.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Inizio chat",411 "Chat Start": "Inizio chat",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Aggiungi Inizio chat e Separatore di esempio a un elenco di stringhe di arresto.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Aggiungi Inizio chat e Separatore di esempio a un elenco di stringhe di arresto.",
413 "Use as Stop Strings": "Usa come stringhe di arresto",413 "Use as Stop Strings": "Usa come stringhe di arresto",
414 "context_allow_jailbreak": "Include il jailbreak alla fine del prompt, se definito nella carta personaggio E ''Preferisci Char. Il jailbreak'' è abilitato.\nQUESTO NON È CONSIGLIATO PER I MODELLI DI COMPLETAMENTO DEL TESTO, PUÒ PORTARE A UN RISULTATO CATTIVO.",
415 "Allow Jailbreak": "Consenti jailbreak",414 "Allow Jailbreak": "Consenti jailbreak",
416 "Context Order": "Ordine del contesto",415 "Context Order": "Ordine del contesto",
417 "Summary": "Riepilogo",416 "Summary": "Riepilogo",
public/locales/ja-jp.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "チャット開始",411 "Chat Start": "チャット開始",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "停止文字列のリストにチャット開始と例の区切り文字を追加します。",412 "Add Chat Start and Example Separator to a list of stopping strings.": "停止文字列のリストにチャット開始と例の区切り文字を追加します。",
413 "Use as Stop Strings": "ストップ文字列として使用",413 "Use as Stop Strings": "ストップ文字列として使用",
414 "context_allow_jailbreak": "文字カードで定義されていて、「文字 Jailbreak を優先」が有効になっている場合は、プロンプトの最後に Jailbreak が含まれます。\nこれはテキスト補完モデルには推奨されません。出力が悪くなる可能性があります。",
415 "Allow Jailbreak": "脱獄を許可する",414 "Allow Jailbreak": "脱獄を許可する",
416 "Context Order": "コンテキスト順序",415 "Context Order": "コンテキスト順序",
417 "Summary": "まとめ",416 "Summary": "まとめ",
public/locales/ko-kr.json+0 -1
@@ -421,7 +421,6 @@
421 "Chat Start": "채팅 시작",421 "Chat Start": "채팅 시작",
422 "Add Chat Start and Example Separator to a list of stopping strings.": "중지 문자열 목록에 채팅 시작 및 예제 구분 기호를 추가합니다.",422 "Add Chat Start and Example Separator to a list of stopping strings.": "중지 문자열 목록에 채팅 시작 및 예제 구분 기호를 추가합니다.",
423 "Use as Stop Strings": "중지 문자열로 사용",423 "Use as Stop Strings": "중지 문자열로 사용",
424 "context_allow_jailbreak": "캐릭터 카드에 정의되어 있고 ''Prefer Char. Jailbreak''가 활성화되어 있는 경우 프롬프트 끝에 Jailbreak를 포함합니다.\n이는 텍스트 완성 모델에 권장되지 않으며, 나쁜 출력으로 이어질 수 있습니다.",
425 "Allow Jailbreak": "탈옥 허용",424 "Allow Jailbreak": "탈옥 허용",
426 "Context Order": "컨텍스트 순서",425 "Context Order": "컨텍스트 순서",
427 "Summary": "요약",426 "Summary": "요약",
public/locales/nl-nl.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Chatstart",411 "Chat Start": "Chatstart",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Voeg Chat Start en Voorbeeldscheidingsteken toe aan een lijst met stoptekenreeksen.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Voeg Chat Start en Voorbeeldscheidingsteken toe aan een lijst met stoptekenreeksen.",
413 "Use as Stop Strings": "Gebruik als stopreeksen",413 "Use as Stop Strings": "Gebruik als stopreeksen",
414 "context_allow_jailbreak": "Inclusief jailbreak aan het einde van de prompt, indien gedefinieerd in de karakterkaart EN ''Prefer Char. Jailbreak'' is ingeschakeld.\nDIT WORDT NIET AANBEVOLEN VOOR MODELLEN VOOR HET INVOEREN VAN TEKST. KAN TOT SLECHTE UITVOER LEIDEN.",
415 "Allow Jailbreak": "Jailbreak toestaan",414 "Allow Jailbreak": "Jailbreak toestaan",
416 "Context Order": "Contextvolgorde",415 "Context Order": "Contextvolgorde",
417 "Summary": "Samenvatting",416 "Summary": "Samenvatting",
public/locales/pt-pt.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Início do Chat",411 "Chat Start": "Início do Chat",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Adicione o início do bate-papo e o separador de exemplo a uma lista de strings de parada.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Adicione o início do bate-papo e o separador de exemplo a uma lista de strings de parada.",
413 "Use as Stop Strings": "Usar como Strings de Parada",413 "Use as Stop Strings": "Usar como Strings de Parada",
414 "context_allow_jailbreak": "Inclui Jailbreak no final do prompt, se definido no cartão de personagem E ''Prefer Char. Jailbreak'' está habilitado.\nISTO NÃO É RECOMENDADO PARA MODELOS DE COMPLEMENTAÇÃO DE TEXTO, PODE LEVAR A UMA SAÍDA RUIM.",
415 "Allow Jailbreak": "Permitir jailbreak",414 "Allow Jailbreak": "Permitir jailbreak",
416 "Context Order": "Ordem de Contexto",415 "Context Order": "Ordem de Contexto",
417 "Summary": "Resumo",416 "Summary": "Resumo",
public/locales/ru-ru.json+0 -1
@@ -1257,7 +1257,6 @@
1257 "Peek a password": "Посмотреть пароль",1257 "Peek a password": "Посмотреть пароль",
1258 "Clear your cookie": "Clear your cookie",1258 "Clear your cookie": "Clear your cookie",
1259 "Add Chat Start and Example Separator to a list of stopping strings.": "Использовать Начало чата и Разделитель примеров сообщений в качестве стоп-строк.",1259 "Add Chat Start and Example Separator to a list of stopping strings.": "Использовать Начало чата и Разделитель примеров сообщений в качестве стоп-строк.",
1260 "context_allow_jailbreak": "Если в карточке есть джейлбрейк И ПРИ ЭТОМ включена опция \"Приоритет джейлбрейку из карточки персонажа\", то этот джейлбрейк добавляется в конец промпта.\nНЕ РЕКОМЕНДУЕТСЯ ДЛЯ МОДЕЛЕЙ TEXT COMPLETION, МОЖЕТ ПОРТИТЬ ВЫХОДНОЙ ТЕКСТ.",
1261 "Context Order": "Context Order",1260 "Context Order": "Context Order",
1262 "Summary": "Summary",1261 "Summary": "Summary",
1263 "Example Dialogues": "Примеры диалогов",1262 "Example Dialogues": "Примеры диалогов",
public/locales/uk-ua.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Початок чату",411 "Chat Start": "Початок чату",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Додайте початок чату та роздільник прикладів до списку рядків зупинки.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Додайте початок чату та роздільник прикладів до списку рядків зупинки.",
413 "Use as Stop Strings": "Використовувати як рядки зупинки",413 "Use as Stop Strings": "Використовувати як рядки зупинки",
414 "context_allow_jailbreak": "Включає втечу з в’язниці в кінці підказки, якщо визначено в картці символів ТА «Переважати символ. Втечу з в'язниці'' увімкнено.\nЦЕ НЕ РЕКОМЕНДУЄТЬСЯ ДЛЯ МОДЕЛЕЙ ЗАВЕРШЕННЯ ТЕКСТУ, МОЖЕ ПРИЗВЕСТИ ДО ПОГАНОГО РЕЗУЛЬТАТУ.",
415 "Allow Jailbreak": "Дозволити втечу з в'язниці",414 "Allow Jailbreak": "Дозволити втечу з в'язниці",
416 "Context Order": "Порядок контексту",415 "Context Order": "Порядок контексту",
417 "Summary": "Резюме",416 "Summary": "Резюме",
public/locales/vi-vn.json+0 -1
@@ -411,7 +411,6 @@
411 "Chat Start": "Bắt đầu Chat",411 "Chat Start": "Bắt đầu Chat",
412 "Add Chat Start and Example Separator to a list of stopping strings.": "Thêm Bắt đầu trò chuyện và Dấu phân cách ví dụ vào danh sách các chuỗi dừng.",412 "Add Chat Start and Example Separator to a list of stopping strings.": "Thêm Bắt đầu trò chuyện và Dấu phân cách ví dụ vào danh sách các chuỗi dừng.",
413 "Use as Stop Strings": "Sử dụng như chuỗi dừng",413 "Use as Stop Strings": "Sử dụng như chuỗi dừng",
414 "context_allow_jailbreak": "Bao gồm Bẻ khóa ở cuối Prompt, nếu được xác định trong thẻ ký tự VÀ ''Thích Char. Bẻ khóa'' được bật.\nĐIỀU NÀY KHÔNG ĐƯỢC KHUYẾN NGHỊ CHO CÁC MÔ HÌNH HOÀN THÀNH VĂN BẢN, CÓ THỂ DẪN ĐẾN ĐẦU RA XẤU.",
415 "Allow Jailbreak": "Cho phép bẻ khóa",414 "Allow Jailbreak": "Cho phép bẻ khóa",
416 "Context Order": "Thứ tự bối cảnh",415 "Context Order": "Thứ tự bối cảnh",
417 "Summary": "Bản tóm tắt",416 "Summary": "Bản tóm tắt",
public/locales/zh-tw.json+0 -1
@@ -412,7 +412,6 @@
412 "Chat Start": "聊天開始符號",412 "Chat Start": "聊天開始符號",
413 "Add Chat Start and Example Separator to a list of stopping strings.": "將聊天開始和範例分隔符號加入終止字串中。",413 "Add Chat Start and Example Separator to a list of stopping strings.": "將聊天開始和範例分隔符號加入終止字串中。",
414 "Use as Stop Strings": "用作停止字串",414 "Use as Stop Strings": "用作停止字串",
415 "context_allow_jailbreak": "如果在角色卡中定義了越獄,且啟用了「角色卡越獄優先」,則會在提示詞的結尾加入越獄內容。\n這不建議用於文字完成模型,因為可能導致不良的輸出結果。",
416 "Allow Jailbreak": "允許越獄",415 "Allow Jailbreak": "允許越獄",
417 "Context Order": "上下文順序",416 "Context Order": "上下文順序",
418 "Summary": "摘要",417 "Summary": "摘要",
public/script.js+7 -5
@@ -4000,7 +4000,9 @@ export async function Generate(type, { automatic_trigger, force_name2, quiet_pro
40004000
4001 if (main_api !== 'openai') {4001 if (main_api !== 'openai') {
4002 if (power_user.sysprompt.enabled) {4002 if (power_user.sysprompt.enabled) {
4003 system = power_user.prefer_character_prompt && system ? system : baseChatReplace(power_user.sysprompt.content, name1, name2);4003 system = power_user.prefer_character_prompt && system
4004 ? substituteParams(system, name1, name2, (power_user.sysprompt.content ?? ''))
4005 : baseChatReplace(power_user.sysprompt.content, name1, name2);
4004 system = isInstruct ? formatInstructModeSystemPrompt(substituteParams(system, name1, name2, power_user.sysprompt.content)) : system;4006 system = isInstruct ? formatInstructModeSystemPrompt(substituteParams(system, name1, name2, power_user.sysprompt.content)) : system;
4005 } else {4007 } else {
4006 // Nullify if it's not enabled4008 // Nullify if it's not enabled
@@ -4207,10 +4209,10 @@ export async function Generate(type, { automatic_trigger, force_name2, quiet_pro
4207 injectedIndices = await doChatInject(coreChat, isContinue);4209 injectedIndices = await doChatInject(coreChat, isContinue);
4208 }4210 }
42094211
4210 // Insert character jailbreak as the last user message (if exists, allowed, preferred, and not using Chat Completion)4212 if (main_api !== 'openai' && power_user.sysprompt.enabled) {
4211 if (power_user.context.allow_jailbreak && power_user.prefer_character_jailbreak && main_api !== 'openai' && jailbreak) {4213 jailbreak = power_user.prefer_character_jailbreak && jailbreak
4212 // Set "original" explicity to empty string since there's no original4214 ? substituteParams(jailbreak, name1, name2, (power_user.sysprompt.post_history ?? ''))
4213 jailbreak = substituteParams(jailbreak, name1, name2, '');4215 : baseChatReplace(power_user.sysprompt.post_history, name1, name2);
42144216
4215 // When continuing generation of previous output, last user message precedes the message to continue4217 // When continuing generation of previous output, last user message precedes the message to continue
4216 if (isContinue) {4218 if (isContinue) {
public/scripts/power-user.js+1 -2
@@ -244,7 +244,6 @@ let power_user = {
244 chat_start: defaultChatStart,244 chat_start: defaultChatStart,
245 example_separator: defaultExampleSeparator,245 example_separator: defaultExampleSeparator,
246 use_stop_strings: true,246 use_stop_strings: true,
247 allow_jailbreak: false,
248 names_as_stop_strings: true,247 names_as_stop_strings: true,
249 },248 },
250249
@@ -255,6 +254,7 @@ let power_user = {
255 enabled: true,254 enabled: true,
256 name: 'Neutral - Chat',255 name: 'Neutral - Chat',
257 content: 'Write {{char}}\'s next reply in a fictional chat between {{char}} and {{user}}.',256 content: 'Write {{char}}\'s next reply in a fictional chat between {{char}} and {{user}}.',
257 post_history: '',
258 },258 },
259259
260 reasoning: {260 reasoning: {
@@ -334,7 +334,6 @@ const contextControls = [
334 { id: 'context_example_separator', property: 'example_separator', isCheckbox: false, isGlobalSetting: false },334 { id: 'context_example_separator', property: 'example_separator', isCheckbox: false, isGlobalSetting: false },
335 { id: 'context_chat_start', property: 'chat_start', isCheckbox: false, isGlobalSetting: false },335 { id: 'context_chat_start', property: 'chat_start', isCheckbox: false, isGlobalSetting: false },
336 { id: 'context_use_stop_strings', property: 'use_stop_strings', isCheckbox: true, isGlobalSetting: false, defaultValue: false },336 { id: 'context_use_stop_strings', property: 'use_stop_strings', isCheckbox: true, isGlobalSetting: false, defaultValue: false },
337 { id: 'context_allow_jailbreak', property: 'allow_jailbreak', isCheckbox: true, isGlobalSetting: false, defaultValue: false },
338 { id: 'context_names_as_stop_strings', property: 'names_as_stop_strings', isCheckbox: true, isGlobalSetting: false, defaultValue: true },337 { id: 'context_names_as_stop_strings', property: 'names_as_stop_strings', isCheckbox: true, isGlobalSetting: false, defaultValue: true },
339338
340 // Existing power user settings339 // Existing power user settings
public/scripts/sysprompt.js+15 -3
@@ -17,6 +17,7 @@ export let system_prompts = [];
17const $enabled = $('#sysprompt_enabled');17const $enabled = $('#sysprompt_enabled');
18const $select = $('#sysprompt_select');18const $select = $('#sysprompt_select');
19const $content = $('#sysprompt_content');19const $content = $('#sysprompt_content');
20const $postHistory = $('#sysprompt_post_history');
20const $contentBlock = $('#SystemPromptBlock');21const $contentBlock = $('#SystemPromptBlock');
2122
22async function migrateSystemPromptFromInstructMode() {23async function migrateSystemPromptFromInstructMode() {
@@ -25,6 +26,7 @@ async function migrateSystemPromptFromInstructMode() {
25 delete power_user.instruct.system_prompt;26 delete power_user.instruct.system_prompt;
26 power_user.sysprompt.enabled = power_user.instruct.enabled;27 power_user.sysprompt.enabled = power_user.instruct.enabled;
27 power_user.sysprompt.content = prompt;28 power_user.sysprompt.content = prompt;
29 power_user.sysprompt.post_history = '';
2830
29 const existingPromptName = system_prompts.find(x => x.content === prompt)?.name;31 const existingPromptName = system_prompts.find(x => x.content === prompt)?.name;
3032
@@ -59,7 +61,8 @@ export async function loadSystemPrompts(data) {
5961
60 $enabled.prop('checked', power_user.sysprompt.enabled);62 $enabled.prop('checked', power_user.sysprompt.enabled);
61 $select.val(power_user.sysprompt.name);63 $select.val(power_user.sysprompt.name);
62 $content.val(power_user.sysprompt.content);64 $content.val(power_user.sysprompt.content || '');
65 $postHistory.val(power_user.sysprompt.post_history || '');
63 if (!CSS.supports('field-sizing', 'content')) {66 if (!CSS.supports('field-sizing', 'content')) {
64 await resetScrollHeight($content);67 await resetScrollHeight($content);
65 }68 }
@@ -165,13 +168,17 @@ export function initSystemPrompts() {
165 const name = String($(this).val());168 const name = String($(this).val());
166 const prompt = system_prompts.find(p => p.name === name);169 const prompt = system_prompts.find(p => p.name === name);
167 if (prompt) {170 if (prompt) {
168 $content.val(prompt.content);171 $content.val(prompt.content || '');
172 $postHistory.val(prompt.post_history || '');
173
169 if (!CSS.supports('field-sizing', 'content')) {174 if (!CSS.supports('field-sizing', 'content')) {
170 await resetScrollHeight($content);175 await resetScrollHeight($content);
176 await resetScrollHeight($postHistory);
171 }177 }
172178
173 power_user.sysprompt.name = name;179 power_user.sysprompt.name = name;
174 power_user.sysprompt.content = prompt.content;180 power_user.sysprompt.content = prompt.content || '';
181 power_user.sysprompt.post_history = prompt.post_history || '';
175 }182 }
176 saveSettingsDebounced();183 saveSettingsDebounced();
177 });184 });
@@ -181,6 +188,11 @@ export function initSystemPrompts() {
181 saveSettingsDebounced();188 saveSettingsDebounced();
182 });189 });
183190
191 $postHistory.on('input', function () {
192 power_user.sysprompt.post_history = String($(this).val());
193 saveSettingsDebounced();
194 });
195
184 SlashCommandParser.addCommandObject(SlashCommand.fromProps({196 SlashCommandParser.addCommandObject(SlashCommand.fromProps({
185 name: 'sysprompt',197 name: 'sysprompt',
186 aliases: ['system-prompt'],198 aliases: ['system-prompt'],