From c84174e10663112cafbacd83d169c9f0b2fe2ed7 Mon Sep 17 00:00:00 2001 From: siddseethepalli Date: Sat, 14 Feb 2026 17:42:07 +0000 Subject: [PATCH] Restart daemon after sessions clear to reset Qdrant state When `vellum sessions clear` deletes the Qdrant collection, the running daemon's VellumQdrantClient still has collectionReady=true cached in memory. This causes subsequent search/upsert calls to fail with collection-not-found. Restart the daemon after clearing so it picks up a fresh state and re-creates the collection on next use. Co-Authored-By: Claude Opus 4.6 --- assistant/src/index.ts | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/assistant/src/index.ts b/assistant/src/index.ts index e8001281ade..67f2262a809 100755 --- a/assistant/src/index.ts +++ b/assistant/src/index.ts @@ -331,6 +331,15 @@ sessions console.log('Qdrant collection not found or not reachable (skipped)'); } + // Restart the daemon so its in-memory Qdrant client drops the stale + // collectionReady flag and will re-create the collection on next use. + const status = getDaemonStatus(); + if (status.running) { + await stopDaemon(); + await startDaemon(); + console.log('Daemon restarted'); + } + console.log('Done.'); });