Do not apply instruct formatting if on CC

0423cb7ad36dc30a81fb60e9ab8e47e03e9cadea

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

1 files changed, +6 -3Ignore whitespace
public/script.js+6 -3
@@ -2719,8 +2719,11 @@ export function substituteParams(content, _name1, _name2, _original, _group, _re
27192719 environment.mesExamples = () => {
27202720 const isInstruct = power_user.instruct.enabled && main_api !== 'openai';
27212721 const mesExamplesArray = parseMesExamples(fields.mesExamples, isInstruct);
2722- const instructExamples = formatInstructModeExamples(mesExamplesArray, name1, name2);
2722+ if (isInstruct) {
2723- return instructExamples.join('');
2723+ const instructExamples = formatInstructModeExamples(mesExamplesArray, name1, name2);
2724+ return instructExamples.join('');
2725+ }
2726+ return mesExamplesArray.join('');
27242727 };
27252728 environment.mesExamplesRaw = fields.mesExamples || '';
27262729 environment.charVersion = fields.version || '';
@@ -3303,7 +3306,7 @@ class StreamingProcessor {
33033306 'send_date': chat[messageId]['send_date'],
33043307 'gen_started': chat[messageId]['gen_started'],
33053308 'gen_finished': chat[messageId]['gen_finished'],
33063309 'extra': JSON.parse(JSON.stringify(chat[messageId]['extra'])),
33073310 };
33083311 }
33093312