You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On a clean Linux (WSL2) install of episodic-memory@1.4.2, onnxruntime-common is not hoisted to top-level node_modules/. It is physically nested under bothonnxruntime-node and onnxruntime-web, each carrying a different version, so npm cannot hoist either. @huggingface/transformers's bare import { Tensor } from "onnxruntime-common" then fails with ERR_MODULE_NOT_FOUND.
This is a clean-install reproduction of Bug 2 from #95, which was closed as "does NOT reproduce — onnxruntime-common IS hoisted on clean installs (macOS + Windows 11)." It reproduces deterministically here on Linux, so it is not the Windows-postinstall red herring suspected in that thread — it's a genuine cross-platform npm hoisting failure driven by conflicting onnxruntime-common versions.
OS: Linux 6.6.87.2-microsoft-standard-WSL2 x86_64 (WSL2)
Node: v22.22.1
npm: 10.9.4
Evidence
1. onnxruntime-common is not at top-level — it's nested under both parents:
$ ls node_modules/onnxruntime-common
ls: cannot access 'node_modules/onnxruntime-common': No such file or directory
$ find node_modules -name onnxruntime-common -type d
node_modules/onnxruntime-web/node_modules/onnxruntime-common
node_modules/onnxruntime-node/node_modules/onnxruntime-common
2. The two parents pull conflicting versions — this is why npm won't hoist either:
Re: the npm ls clarification in #95 — agreed that npm ls shows the logical tree. The evidence above is the physical layout (find ... -type d + a top-level ls that 404s + require.resolve failing), which is what was requested. onnxruntime-common genuinely is not hoisted here.
Impact
The SessionStart hook (episodic-memory.js sync --background) fails silently (it's --background), so background conversation indexing never runs.
search-conversations / remembering-conversations hit the same ERR_MODULE_NOT_FOUND when invoked.
A cosmetic startup warning surfaces, but the session is otherwise unaffected (non-blocking).
The #95 close reasoned that onnxruntime-common is always hoisted on a clean install and that the reporter's real problem was the Windows-only postinstall redirection (2>/dev/null || true, fixed in a3438a6). On Linux that postinstall path is fine, yet the non-hoist still happens — because onnxruntime-node@1.24.3 and onnxruntime-web@1.26.0-dev… depend on incompatibleonnxruntime-common versions (1.24.3 vs 1.24.0-dev…). With two conflicting versions, npm must nest at least one, and here it nests both, leaving top-level empty. Whether it hoists is install-order / npm-version sensitive, which likely explains why it didn't reproduce in the earlier macOS/Windows tests.
Suggested fixes (any one resolves it)
Declare onnxruntime-common as a direct dependency of the plugin, pinned to a single version, so it hoists to top-level deterministically.
Add an overrides entry forcing a single onnxruntime-common across onnxruntime-node/onnxruntime-web, so only one version exists and it hoists.
Summary
On a clean Linux (WSL2) install of
episodic-memory@1.4.2,onnxruntime-commonis not hoisted to top-levelnode_modules/. It is physically nested under bothonnxruntime-nodeandonnxruntime-web, each carrying a different version, so npm cannot hoist either.@huggingface/transformers's bareimport { Tensor } from "onnxruntime-common"then fails withERR_MODULE_NOT_FOUND.This is a clean-install reproduction of Bug 2 from #95, which was closed as "does NOT reproduce — onnxruntime-common IS hoisted on clean installs (macOS + Windows 11)." It reproduces deterministically here on Linux, so it is not the Windows-postinstall red herring suspected in that thread — it's a genuine cross-platform npm hoisting failure driven by conflicting
onnxruntime-commonversions.Environment
episodic-memory@1.4.2(viasuperpowers-marketplace)Evidence
1.
onnxruntime-commonis not at top-level — it's nested under both parents:2. The two parents pull conflicting versions — this is why npm won't hoist either:
@huggingface/transformersdeclares only the two parents, notonnxruntime-commonitself:3. The bare import fails (both CJS resolve and the real ESM entry point):
Impact
SessionStarthook (episodic-memory.js sync --background) fails silently (it's--background), so background conversation indexing never runs.search-conversations/remembering-conversationshit the sameERR_MODULE_NOT_FOUNDwhen invoked.Why this differs from the #95 close
The #95 close reasoned that
onnxruntime-commonis always hoisted on a clean install and that the reporter's real problem was the Windows-only postinstall redirection (2>/dev/null || true, fixed ina3438a6). On Linux that postinstall path is fine, yet the non-hoist still happens — becauseonnxruntime-node@1.24.3andonnxruntime-web@1.26.0-dev…depend on incompatibleonnxruntime-commonversions (1.24.3vs1.24.0-dev…). With two conflicting versions, npm must nest at least one, and here it nests both, leaving top-level empty. Whether it hoists is install-order / npm-version sensitive, which likely explains why it didn't reproduce in the earlier macOS/Windows tests.Suggested fixes (any one resolves it)
onnxruntime-commonas a direct dependency of the plugin, pinned to a single version, so it hoists to top-level deterministically.overridesentry forcing a singleonnxruntime-commonacrossonnxruntime-node/onnxruntime-web, so only one version exists and it hoists.require.resolve('onnxruntime-common')as a sentinel (like the post-Plugin fails to load on Windows: two upstream dep-resolution bugs slip past mcp-server-wrapper.js #95 manifest probe) and re-install / symlink if missing — though (1) or (2) is the real fix and belongs upstream.Filed via Claude Code after reproducing locally. Happy to run any additional
find/npmdiagnostics on this WSL2 install.