aboutsummaryrefslogtreecommitdiff
path: root/modules/core/module-loader.js
diff options
context:
space:
mode:
authorAgando <roduccomm@gmail.com>2026-10-22 00:46:05 +0200
committerAgando <roduccomm@gmail.com>2026-10-22 00:46:05 +0200
commit70b9a2f8cc2b249362ca4893fdbb6703c0ea7b8a (patch)
treeb87027e9790b2bb0945f4192a5d08419fa58b478 /modules/core/module-loader.js
parent14c3cb36a3b037111a9fbdf8ff6ea32ee62b3be1 (diff)
feat(newos4): world-model-ask answers with the LLM, grounded in the model (v4.6.50)
`world-model-ask` was a 10-keyword lookup: any real question returned "Unknown query. Try: modules, skills, ...". The documented example ("what changed since yesterday") compared nothing — it restated the current snapshot. - _modelDigest(): whitelisted snapshot (measured 942-965 chars on fixtures, ~3.3 KB live) + recent error sample + changesSinceLastSnapshot - _buildAskPrompt(): "answer only from this JSON, never invent numbers, name the command that would produce missing data" - ask(): connects Ollama on demand, answers via chat(), falls back to the facts path with a visible warning; --facts keeps the instant lookup - _diffSincePrev(): keeps one previous snapshot in /system/world-model.prev.json so "what changed" is a real diff (files 136 -> 140) - world_model_query tool returns the snapshot (digest or detail:full) instead of ten canned strings; no nested LLM call inside a tool call - help text now says what it does; node test modules/test/test-world-model-ask.js (11 assertions, runs the real class) Verified live v4.6.50: facts "Loaded 46 modules" | LLM "The snapshot does not contain information regarding the cause of memory growth ... use world-model-refresh" | diff "files 136 -> 140" | tool snapshot 3,334 bytes.
Diffstat (limited to 'modules/core/module-loader.js')
-rw-r--r--modules/core/module-loader.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/core/module-loader.js b/modules/core/module-loader.js
index 8330eaf..64ece7c 100644
--- a/modules/core/module-loader.js
+++ b/modules/core/module-loader.js
@@ -4,7 +4,7 @@
// Core module bundle loaded synchronously in main.html.
// This loader only handles version cache-busting, splash, terminal init, and optional ext modules.
- const LATEST_VER = 'v4.6.49';
+ const LATEST_VER = 'v4.6.50';
const CACHE = '?v=' + LATEST_VER;
const stored = localStorage.getItem('webx11_cache_ver');
if (stored !== LATEST_VER) {