Commit Graph

293 Commits

Author SHA1 Message Date
Youzini-afk
03ec52d4c5 feat: add message hiding assistant 2026-04-02 16:05:29 +08:00
Hao19911125
fc8a5ffaec Merge pull request #1 from Hao19911125/codex/ena-planner-bme
Add Ena Planner integration for ST-BME
2026-04-02 16:01:08 +08:00
Hao19911125
c75083a456 Add Ena Planner integration for ST-BME 2026-04-02 15:56:24 +08:00
Youzini-afk
c711ff17f7 fix: harden auto extraction trigger flow 2026-04-02 14:46:09 +08:00
Youzini-afk
6f8554e11a feat: improve retrieval recall and maintenance undo 2026-04-01 22:37:29 +08:00
Youzini-afk
1dc87245a7 fix: 修复图谱可读性检查在ST插件环境下误判
1. isGraphReadableForRecall: 移除loadState!==LOADING时的硬性阻断,
   改为始终检查运行时图谱结构。持久化状态机可能因getCurrentChatId()
   返回空而卡在NO_CHAT,但图谱数据已通过IndexedDB probe加载

2. hasReadableRuntimeGraphForRecall: 放宽chatId匹配要求,
   当chatId不可用时(ST插件环境),只要图谱有节点/边就允许召回
2026-04-01 17:05:47 +08:00
Youzini-afk
3790f26082 diag+fix: 添加recall诊断日志 + 修复用户输入获取
诊断:recall-controller.js 添加图谱/设置/可读性状态日志
修复:buildGenerationAfterCommandsRecallInput 允许normal类型在chat中有用户消息时继续
修复:buildNormalGenerationRecallInput 添加 getLatestUserChatMessage 兜底
2026-04-01 16:55:52 +08:00
Youzini-afk
b75203d6c8 fix: 修复GENERATION_AFTER_COMMANDS无法获取用户输入的两个关键bug
1. buildGenerationAfterCommandsRecallInput: 对normal类型不再因targetUserMessageIndex
   非有限值而提前返回,改为检查chat中是否存在任何用户消息后决定是否执行

2. buildNormalGenerationRecallInput: 新增getLatestUserChatMessage兜底——
   当GENERATION_AFTER_COMMANDS触发时ST可能已追加空assistant消息导致
   getLastNonSystemChatMessage返回assistant,现在通过反向扫描找到真正的用户消息
   (与shujuku参考实现一致)
2026-04-01 16:44:19 +08:00
Youzini-afk
d8aa795867 diag: 添加召回管线诊断日志 [ST-BME:DIAG] 2026-04-01 16:33:28 +08:00
Youzini-afk
ddc654eb1a fix: 修复召回拦截管线三个致命bug
1. recordRecallSentUserMessage 不再在 MESSAGE_SENT 阶段清空
   pendingRecallSendIntent/pendingHostGenerationInputSnapshot/transactions,
   避免 GENERATION_AFTER_COMMANDS 找不到用户输入而跳过召回

2. resolveGenerationRecallDeliveryMode 将 GENERATION_AFTER_COMMANDS
   从 deferred 改为 immediate,使召回完成后通过 setExtensionPrompt 即时注入

3. onGenerationAfterCommandsController 在 immediate 模式下完成
   runRecall 后直接返回(注入已在 applyRecallInjection 内完成),
   GENERATE_BEFORE_COMBINE_PROMPTS 保留 deferred rewrite 兜底
2026-04-01 16:16:31 +08:00
Youzini-afk
83f8f24f1c fix: defer recall injection to pre-send rewrite 2026-04-01 15:24:42 +08:00
Youzini-afk
bf3a24261b fix: stabilize recall persistence regression coverage 2026-04-01 01:37:20 +08:00
Youzini-afk
7d71d1015e fix: harden history recovery and graph persistence regressions 2026-03-31 22:48:48 +08:00
Youzini-afk
1098c33a93 fix: finalize phase0 and phase1 persistence regressions 2026-03-31 20:04:42 +08:00
Youzini-afk
d5b4b7e1dc fix: freeze recall input from host lifecycle 2026-03-31 16:33:40 +08:00
Youzini-afk
d8710f45f1 fix: restore before-combine recall gating 2026-03-31 15:22:08 +08:00
Youzini-afk
4c58121cce fix: restore before-combine recall interception provisional binding 2026-03-31 13:55:26 +08:00
Youzini-afk
4925810064 fix: rerender expanded recall card content on persisted update 2026-03-31 13:13:16 +08:00
Youzini-afk
b0f9d191bd fix: finalize deepfix p2 recall binding and p3 validation matrix 2026-03-31 03:53:53 +08:00
Youzini-afk
a2bed39e28 fix: deep repair p0-p1 persistence runtime merge and integrity 2026-03-31 02:38:27 +08:00
Youzini-afk
10c6db258b refactor: deepen indexeddb-first load path and finalize phase ef docs/scripts 2026-03-30 20:00:38 +08:00
Youzini-afk
1c76ad7a11 feat: switch ST-BME runtime to indexeddb-primary with sync hardening 2026-03-30 18:38:58 +08:00
Youzini-afk
1fd9da738f fix: add recall card persistence and mount diagnostic logs for end-to-end visibility 2026-03-29 22:39:48 +08:00
Youzini-afk
4bf571ba37 fix: harden metadata readiness and add persistence self-heal reconcile 2026-03-29 21:39:58 +08:00
Youzini-afk
16e1427fe1 fix(recall-ui): dedupe observer/timer refresh attempts 2026-03-29 21:08:24 +08:00
root
e09b116a71 fix: stabilize recall card mounting and refresh timing 2026-03-29 20:45:08 +08:00
Youzini-afk
4aeba55e90 feat: recall card UI v2 — inline card with force-graph sub-graph, sidebar editor, no more prompt/alert/confirm 2026-03-29 20:02:02 +08:00
Youzini-afk
fc2e9abc72 fix: limit reroll re-extract to single latest assistant batch 2026-03-29 19:13:46 +08:00
Youzini-afk
ab37e2111c fix: delegate rebuild confirm to host globalThis wrapper 2026-03-29 18:56:18 +08:00
Youzini-afk
b3b0b3a64c feat: implement persistent recall injection with per-message fallback UI 2026-03-29 18:41:25 +08:00
Youzini-afk
5023b75f3f refactor: controllerize onReroll and keep reroll harness green 2026-03-29 17:39:41 +08:00
Youzini-afk
b7c986d9ea fix: inject message-received controller into graph persistence vm harness 2026-03-29 17:25:43 +08:00
Youzini-afk
33afa996aa refactor: move message received hook into event binding controller 2026-03-29 17:24:57 +08:00
Youzini-afk
899216db62 refactor: move sleep synopsis and evolve actions into ui actions controller 2026-03-29 17:22:40 +08:00
Youzini-afk
f18f05feb1 refactor: move vector rebuild actions into ui actions controller 2026-03-29 17:21:02 +08:00
Youzini-afk
6695f68f11 refactor: move graph import flow into ui actions controller 2026-03-29 17:18:42 +08:00
Youzini-afk
18897dc6bf refactor: move manual rebuild flow into ui actions controller 2026-03-29 17:16:30 +08:00
Youzini-afk
5edbc4e4be fix: add missing ui action controller exports 2026-03-29 17:14:25 +08:00
Youzini-afk
5be8f6ab96 refactor: controllerize compress export and injection viewer actions 2026-03-29 17:13:29 +08:00
Youzini-afk
7e5c561997 refactor: extract ui action helpers into controller module 2026-03-29 17:11:41 +08:00
Youzini-afk
d3479bc672 refactor: controllerize generation recall event hooks 2026-03-29 17:09:09 +08:00
Youzini-afk
e29e413516 refactor: move chat/message event handlers into event binding controller 2026-03-29 17:06:05 +08:00
Youzini-afk
ca2eb35ec5 refactor: route panel live-state helpers through panel bridge 2026-03-29 17:04:25 +08:00
Youzini-afk
079a01ee78 refactor: extract event binding and panel bridge modules 2026-03-29 17:01:47 +08:00
Youzini-afk
4b769d312a refactor: move manual extraction flow into extraction controller 2026-03-29 16:50:05 +08:00
Youzini-afk
29e0b838c0 refactor: move extraction and recall pipelines into controllers 2026-03-29 16:45:21 +08:00
Youzini-afk
81d06870db refactor: extract extraction and recall helper controllers 2026-03-29 16:39:22 +08:00
Youzini-afk
d9f04d4388 refactor: extract chat history helpers 2026-03-29 16:28:54 +08:00
Youzini-afk
a371150661 refactor: batch 5 phase 2 - extract graph-persistence.js (20 exports, ~230 lines) from index.js 2026-03-29 15:43:11 +08:00
Youzini-afk
1e6e5853e7 refactor: batch 5 phase 1 - extract ui-status.js (25 pure functions, ~280 lines) from index.js 2026-03-29 15:25:06 +08:00