memory dashboard threshold

frdel committed Sep 23, 2025 at 23:17 UTC 6a74f891e4d797210d725f60109d2fd97e3d4c4b
2 files changed +11 -2
webui/components/settings/memory/memory-dashboard-store.js
+5 -2
@@ -31,7 +31,8 @@ const memoryDashboardStore = {
31 // Search and filters
32 searchQuery: "",
33 areaFilter: "",
34 - limit: parseInt(localStorage.getItem('memoryDashboard_limit') || '100'),
34 + threshold: parseFloat(localStorage.getItem('memoryDashboard_threshold') || '0.6'),
35 + limit: parseInt(localStorage.getItem('memoryDashboard_limit') || '1000'),
36
37 // Stats
38 totalCount: 0,
@@ -137,6 +138,7 @@ const memoryDashboardStore = {
138 async searchMemories(silent = false) {
139 // Save limit to localStorage for persistence
140 localStorage.setItem('memoryDashboard_limit', this.limit.toString());
141 + localStorage.setItem('memoryDashboard_threshold', this.threshold.toString());
142
143 if (!silent) {
144 this.loading = true;
@@ -155,7 +157,8 @@ const memoryDashboardStore = {
157 memory_subdir: this.selectedMemorySubdir,
158 area: this.areaFilter,
159 search: this.searchQuery,
158 - limit: this.limit
160 + limit: this.limit,
161 + threshold: this.threshold
162 });
163
164 if (response.success) {
webui/components/settings/memory/memory-dashboard.html
+6
@@ -55,6 +55,12 @@
55 min="10" max="1000" step="10" style="min-width: 100px;" />
56 </div>
57
58 + <div class="filter-group">
59 + <label for="threshold-input">Threshold: <span x-text="$store.memoryDashboardStore.threshold.toFixed(2)"></span></label>
60 + <input type="range" id="threshold-input" x-model.number="$store.memoryDashboardStore.threshold"
61 + min="0" max="1" step="0.01" style="min-width: 10em;" />
62 + </div>
63 +
64 <div class="filter-actions">
65 <button class="btn primary slim" @click="$store.memoryDashboardStore.searchMemories()"
66 :disabled="$store.memoryDashboardStore.loading || $store.memoryDashboardStore.loadingSubdirs">