openclaw - ✅(Solved) Fix [Bug]: sqlite-vec unavailable on node:sqlite — vector recall degraded (macOS ARM64, v2026.4.26) [1 pull requests, 1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openclaw/openclaw#74401Fetched 2026-04-30 06:24:19
View on GitHub
Comments
1
Participants
2
Timeline
4
Reactions
2
Timeline (top)
closed ×1commented ×1cross-referenced ×1labeled ×1

sqlite-vec fails to load on macOS ARM64 with node:sqlite runtime. Vector recall degraded to BM25-only. Root cause: sqliteVec.load() is better-sqlite3 API, incompatible with node:sqlite used in 2026.4.26. ¥

Error Message

Workaround attempted: manually set memorySearch.extensionPath in openclaw.json pointing to vec0.dylib — no effect, same error.

Root Cause

sqlite-vec fails to load on macOS ARM64 with node:sqlite runtime. Vector recall degraded to BM25-only. Root cause: sqliteVec.load() is better-sqlite3 API, incompatible with node:sqlite used in 2026.4.26. ¥

Fix Action

Fix / Workaround

Workaround attempted: manually set memorySearch.extensionPath in openclaw.json pointing to vec0.dylib — no effect, same error.

PR fix notes

PR #74435: fix(memory): use db.loadExtension() instead of sqliteVec.load() for n…

Description (problem / solution / changelog)

Problem

sqliteVec.load(db) is a better-sqlite3 API. OpenClaw 2026.4.26 switched to node:sqlite (DatabaseSync), which does not support this method. This causes sqlite-vec to silently fail on all platforms, degrading vector recall to BM25-only.

Fix

Remove the sqliteVec.load(db) branch. Both code paths now call db.loadExtension(extensionPath), which node:sqlite supports natively.

Also removed the unused load method from the SqliteVecModule type definition.

Fixes #74401

Changed files

  • src/memory-host-sdk/host/sqlite-vec.ts (modified, +1/-6)

Code Example

$ openclaw memory index --force
[memory] chunks_vec not updated — sqlite-vec unavailable. Vector recall degraded. Further duplicate warnings suppressed.

$ openclaw memory status
Provider: none (requested: auto)
Model: none
Vector: unknown
FTS: ready

vec0.dylib confirmed present and loadable:
/opt/homebrew/lib/node_modules/openclaw/node_modules/sqlite-vec-darwin-arm64/vec0.dylib
size: 161896 bytes, loads OK via koffi

Source trace: engine-storage-BDCm2rBI.js line 92
  sqliteVec.load(params.db)  ← better-sqlite3 API, incompatible with node:sqlite
RAW_BUFFERClick to expand / collapse

Bug type

Regression (worked before, now fails)

Beta release blocker

No

Summary

sqlite-vec fails to load on macOS ARM64 with node:sqlite runtime. Vector recall degraded to BM25-only. Root cause: sqliteVec.load() is better-sqlite3 API, incompatible with node:sqlite used in 2026.4.26. ¥

Steps to reproduce

  1. Install OpenClaw 2026.4.26 on macOS ARM64 (M4) via npm global
  2. Run: openclaw memory index --force
  3. Observe: [memory] chunks_vec not updated — sqlite-vec unavailable. Vector recall degraded.
  4. Run: openclaw memory status
  5. Observe: Vector: unknown, Provider: none

Expected behavior

  1. Install OpenClaw 2026.4.26 on macOS ARM64 (M4)
  2. Run: openclaw memory index --force
  3. Observe: [memory] chunks_vec not updated — sqlite-vec unavailable

Actual behavior

sqlite-vec unavailable. openclaw memory status shows Vector: unknown, Provider: none. BM25-only fallback.

Root cause traced to engine-storage-BDCm2rBI.js line 92: sqliteVec.load(params.db) uses better-sqlite3 API but OpenClaw 2026.4.26 uses node:sqlite (experimental Node.js native SQLite), which does not support this method. vec0.dylib exists and loads correctly via koffi (161896 bytes, darwin-arm64).

OpenClaw version

2026.4.26 (be8c246)

Operating system

macOS 15.4, Apple M4

Install method

npm global

Model

MiniMax-M2.7

Provider / routing chain

openclaw -> api.minimaxi.com/anthropic

Additional provider/model setup details

No response

Logs, screenshots, and evidence

$ openclaw memory index --force
[memory] chunks_vec not updated — sqlite-vec unavailable. Vector recall degraded. Further duplicate warnings suppressed.

$ openclaw memory status
Provider: none (requested: auto)
Model: none
Vector: unknown
FTS: ready

vec0.dylib confirmed present and loadable:
/opt/homebrew/lib/node_modules/openclaw/node_modules/sqlite-vec-darwin-arm64/vec0.dylib
size: 161896 bytes, loads OK via koffi

Source trace: engine-storage-BDCm2rBI.js line 92
  sqliteVec.load(params.db)  ← better-sqlite3 API, incompatible with node:sqlite

Impact and severity

Affects all macOS ARM64 users on 2026.4.26. Severity: blocks workflow — vector/semantic memory recall is completely disabled, falling back to BM25-only. Frequency: always reproducible. Consequence: memory search quality severely degraded, agents cannot perform semantic recall across sessions.

Additional information

Workaround attempted: manually set memorySearch.extensionPath in openclaw.json pointing to vec0.dylib — no effect, same error.

Suggested fix: in loadSqliteVecExtension(), replace sqliteVec.load(params.db) with db.loadExtension(extensionPath) when node:sqlite is detected, or restore better-sqlite3 as the SQLite backend.

extent analysis

TL;DR

Replace sqliteVec.load(params.db) with db.loadExtension(extensionPath) in loadSqliteVecExtension() when using node:sqlite to fix the compatibility issue.

Guidance

  • Identify the SQLite backend used by OpenClaw 2026.4.26, which is node:sqlite, and note its incompatibility with the sqliteVec.load() method.
  • Verify that the vec0.dylib file is present and loadable, as confirmed by the presence of the file and successful loading via koffi.
  • Consider restoring better-sqlite3 as the SQLite backend as an alternative solution, if feasible.
  • Test the suggested fix by replacing the incompatible method call and verifying that vector recall is restored.

Example

// loadSqliteVecExtension() function
if (usingNodeSqlite) {
  db.loadExtension(extensionPath);
} else {
  sqliteVec.load(params.db);
}

Notes

The suggested fix assumes that the db.loadExtension() method is compatible with node:sqlite and that the extensionPath variable points to the correct location of the vec0.dylib file.

Recommendation

Apply the workaround by replacing sqliteVec.load(params.db) with db.loadExtension(extensionPath) in loadSqliteVecExtension() when node:sqlite is detected, as this is a targeted fix for the identified compatibility issue.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

  1. Install OpenClaw 2026.4.26 on macOS ARM64 (M4)
  2. Run: openclaw memory index --force
  3. Observe: [memory] chunks_vec not updated — sqlite-vec unavailable

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

openclaw - ✅(Solved) Fix [Bug]: sqlite-vec unavailable on node:sqlite — vector recall degraded (macOS ARM64, v2026.4.26) [1 pull requests, 1 comments, 2 participants]