From b193eed0199b41ac0fec08f3f739cedf8badaed7 Mon Sep 17 00:00:00 2001 From: Youzini-afk <13153778771cx@gmail.com> Date: Sun, 12 Apr 2026 22:38:32 +0800 Subject: [PATCH] fix(ui): task monitor data binding - use correct getter functions for pipeline/persistence/injection views --- style.css | 4 +++ ui/panel.js | 90 +++++++++++++++++++++++------------------------------ 2 files changed, 43 insertions(+), 51 deletions(-) diff --git a/style.css b/style.css index b7348e8..89f720d 100644 --- a/style.css +++ b/style.css @@ -1246,6 +1246,10 @@ flex-shrink: 0; } +.bme-memory-list-filters .bme-filter-select { + flex: 0 0 auto; +} + .bme-memory-list-scroll { flex: 1; overflow-y: auto; diff --git a/ui/panel.js b/ui/panel.js index 779053c..4dec443 100644 --- a/ui/panel.js +++ b/ui/panel.js @@ -1371,23 +1371,21 @@ function _refreshTaskPipelineOverview() { const el = document.getElementById("bme-task-pipeline"); if (!el) return; - const debug = _getRuntimeDebugSnapshot?.() || {}; - const rd = debug.runtimeDebug || {}; const graph = _getGraph?.() || {}; - const historyState = graph.runtimeState?.historyState || {}; - const graphPersistenceState = graph.graphPersistenceState || {}; + const historyState = graph.runtimeState?.historyState || graph.historyState || {}; + const loadInfo = _getGraphPersistenceSnapshot(); - const extraction = _resolvePipelineStatus(rd.lastExtractionStatus); - const vector = _resolvePipelineStatus(rd.lastVectorStatus); - const recall = _resolvePipelineStatus(rd.lastRecallStatus); - const persistLevel = graphPersistenceState.loadState === "loaded" ? "info" : graphPersistenceState.loadState === "loading" ? "info" : "warn"; + const extraction = _resolvePipelineStatus(_getLastExtractionStatus?.()); + const vector = _resolvePipelineStatus(_getLastVectorStatus?.()); + const recall = _resolvePipelineStatus(_getLastRecallStatus?.()); + const persistLevel = loadInfo.loadState === "loaded" ? "info" : loadInfo.loadState === "loading" ? "info" : "warn"; const persistence = _resolvePipelineStatus({ - text: graphPersistenceState.loadState || "unknown", - meta: `rev ${graphPersistenceState.lastAcceptedRevision || 0}`, + text: loadInfo.loadState || "unknown", + meta: `rev ${loadInfo.revision || 0}`, level: persistLevel, }); - const batchStatus = historyState.lastBatchStatus || {}; + const batchStatus = _getLatestBatchStatusSnapshot() || {}; const stages = [ { key: "core", label: "Core" }, { key: "structural", label: "结构" }, @@ -1670,49 +1668,41 @@ function _refreshTaskInjectionPreview() { const el = document.getElementById("bme-task-injection"); if (!el) return; - const debug = _getRuntimeDebugSnapshot?.() || {}; - const rd = debug.runtimeDebug || {}; - const injection = rd?.injections?.recall || null; - - if (!injection) { - el.innerHTML = '