fix: call _memory plugin paths for knowledge reindex

Import knowledge and project knowledge browse POSTed to /api/knowledge_reindex, which is not registered. Route those calls through /plugins/_memory/knowledge_reindex so dispatch matches plugin api handlers. Chat import already used knowledge_path_get under the plugin; its call is reformatted only. update knowledge_reindex.py

Alessandro committed Mar 25, 2026 at 21:32 UTC e24b304ecb4f3ba2987ea9375366e2f0f1b9875e
2 files changed +6 -5
webui/components/chat/input/input-store.js
+5 -4
@@ -101,9 +101,10 @@ const model = {
101
102 async loadKnowledge() {
103 try {
104 - const resp = await shortcuts.callJsonApi("/plugins/_memory/knowledge_path_get", {
105 - ctxid: shortcuts.getCurrentContextId(),
106 - });
104 + const resp = await shortcuts.callJsonApi(
105 + "/plugins/_memory/knowledge_path_get",
106 + { ctxid: shortcuts.getCurrentContextId() }
107 + );
108 if (!resp.ok) throw new Error("Error getting knowledge path");
109 const path = resp.path;
110
@@ -121,7 +122,7 @@ const model = {
122 });
123
124 // then reindex knowledge
124 - await globalThis.sendJsonData("/knowledge_reindex", {
125 + await globalThis.sendJsonData("/plugins/_memory/knowledge_reindex", {
126 ctxid: shortcuts.getCurrentContextId(),
127 });
128
webui/components/projects/projects-store.js
+1 -1
@@ -459,7 +459,7 @@ const model = {
459 });
460
461 // call reindex knowledge
462 - const reindexCall = api.callJsonApi("/knowledge_reindex", {
462 + const reindexCall = api.callJsonApi("/plugins/_memory/knowledge_reindex", {
463 ctxid: shortcuts.getCurrentContextId(),
464 });
465