From 29524aa328b5e72122c219423e3d1e7ec2eb49c1 Mon Sep 17 00:00:00 2001 From: Hao19911125 <99091644+Hao19911125@users.noreply.github.com> Date: Thu, 9 Apr 2026 22:05:45 +0800 Subject: [PATCH 1/4] Update .gitignore --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 5b041ad..42d89e8 100644 --- a/.gitignore +++ b/.gitignore @@ -12,3 +12,4 @@ AGENTS.md plans/fix-regex-stage-alias-override.md 猫妖恬恬.json plan_global_task_regex.md +docs/BME六大功能全景解析.xlsx From 1d54740cb34b233761bb9e6b4c94fa18badebb66 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 9 Apr 2026 14:06:01 +0000 Subject: [PATCH 2/4] chore: bump manifest version [skip ci] --- manifest.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.json b/manifest.json index 2ee2979..90078ae 100644 --- a/manifest.json +++ b/manifest.json @@ -6,6 +6,6 @@ "js": "index.js", "css": "style.css", "author": "Youzini", - "version": "4.2.1", + "version": "4.2.2", "homePage": "https://github.com/Youzini-afk/ST-Bionic-Memory-Ecology" } From d475b121da5462bf40b685637b5a996c8d2e4a8f Mon Sep 17 00:00:00 2001 From: Hao19911125 <99091644+Hao19911125@users.noreply.github.com> Date: Thu, 9 Apr 2026 22:14:08 +0800 Subject: [PATCH 3/4] Reuse main timeout for Ena planner requests --- ena-planner/ena-planner.js | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/ena-planner/ena-planner.js b/ena-planner/ena-planner.js index 46396b7..981a947 100644 --- a/ena-planner/ena-planner.js +++ b/ena-planner/ena-planner.js @@ -20,6 +20,13 @@ function getPlannerRecallTimeoutMs() { : VECTOR_RECALL_TIMEOUT_MS; } +function getPlannerRequestTimeoutMs() { + const timeoutMs = Number(_bmeRuntime?.getPlannerRecallTimeoutMs?.()); + return Number.isFinite(timeoutMs) && timeoutMs > 0 + ? timeoutMs + : PLANNER_REQUEST_TIMEOUT_MS; +} + function getTrustedOrigin() { return window.location.origin; } function postToIframe(iframe, payload) { @@ -988,7 +995,8 @@ async function callPlanner(messages, options = {}) { if (mt != null && !Number.isNaN(mt) && mt > 0) body.max_tokens = mt; const controller = new AbortController(); - const timeoutId = setTimeout(() => controller.abort(), PLANNER_REQUEST_TIMEOUT_MS); + const plannerRequestTimeoutMs = getPlannerRequestTimeoutMs(); + const timeoutId = setTimeout(() => controller.abort(), plannerRequestTimeoutMs); try { const res = await fetch(url, { method: 'POST', @@ -1047,7 +1055,7 @@ async function callPlanner(messages, options = {}) { return full; } catch (err) { if (controller.signal.aborted || err?.name === 'AbortError') { - throw new Error(`规划请求超时(>${Math.floor(PLANNER_REQUEST_TIMEOUT_MS / 1000)}s)`); + throw new Error(`规划请求超时(>${Math.floor(plannerRequestTimeoutMs / 1000)}s)`); } throw err; } finally { From a6a325a6c0febbfde1fd64072769d77e280d8226 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Thu, 9 Apr 2026 14:15:45 +0000 Subject: [PATCH 4/4] chore: bump manifest version [skip ci] --- manifest.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manifest.json b/manifest.json index 90078ae..51a5f15 100644 --- a/manifest.json +++ b/manifest.json @@ -6,6 +6,6 @@ "js": "index.js", "css": "style.css", "author": "Youzini", - "version": "4.2.2", + "version": "4.2.3", "homePage": "https://github.com/Youzini-afk/ST-Bionic-Memory-Ecology" }