From 37819df542a412dbd2d5d3e515accb067cc4e4e3 Mon Sep 17 00:00:00 2001 From: Cohee <18619528+Cohee1207@users.noreply.github.com> Date: Wed, 12 Mar 2025 23:59:53 +0200 Subject: [PATCH] Move reasoning continue regex depth adjustment --- public/script.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/script.js b/public/script.js index 48841d055..5ccd253a4 100644 --- a/public/script.js +++ b/public/script.js @@ -3958,7 +3958,7 @@ export async function Generate(type, { automatic_trigger, force_name2, quiet_pro const promptReasoning = new PromptReasoning(); for (let i = coreChat.length - 1; i >= 0; i--) { - const depth = coreChat.length - i - 1; + const depth = coreChat.length - i - (isContinue ? 2 : 1); const isPrefix = isContinue && i === coreChat.length - 1; coreChat[i] = { ...coreChat[i],