Summary
@ruvector/sona@0.1.6 is published to npm without its build output. The package
contains only README.md and package.json — no index.js and no dist/ — yet
package.json main points at index.js. As a result require('@ruvector/sona') throws
MODULE_NOT_FOUND, which silently disables all SONA-backed routing in ruvector@0.2.26.
Environment
ruvector@0.2.26 (latest)
@ruvector/sona@0.1.6
- Node v20.19.6, Linux
Reproduction
$ ls node_modules/@ruvector/sona
README.md package.json # no index.js, no dist/
$ node -p "require('@ruvector/sona/package.json').main"
index.js # main points at a non-existent file
$ node -e "require('@ruvector/sona')"
Error: Cannot find module '@ruvector/sona' (MODULE_NOT_FOUND)
Impact
dist/core/intelligence-engine.js gates SONA on isSonaAvailable(), which does
require('@ruvector/sona') inside a try/catch. Because the require throws, the engine
sets this.sona = null, so:
this.sona.findPatterns(embed, 5) never runs → patterns = []
- every
hooks route / mcp__ruvector__hooks_route call returns sonaPatterns: 0
- the SONA confidence-boost branch in
route() is permanently dead
So SONA-enhanced routing is non-functional end-to-end despite being fully wired, and there
is no surfaced error — it fails silently via the catch.
The same failure mode affects @ruvector/pi-brain@0.1.1 (also ships src/ only, no dist/),
which breaks all brain_* MCP tools (No "exports" main defined). Likely the same root
cause in the publish pipeline.
Suggested solution
- Verify the tarball before publishing.
npm pack --dry-run in npm/packages/sona
should list the built entrypoint. Add it to CI as a gate.
- Fix the
files allowlist / build step. Either:
- ensure
dist/ (or index.js) is produced by a prepublishOnly (or prepack) build
script, and
- ensure
package.json files includes the built output (a too-narrow files field is
the most common cause of a src-only / build-less tarball).
- Make
main/exports match what actually ships (point at the real built file).
- Apply the same fix to
@ruvector/pi-brain — it exhibits the identical defect and
gates the brain_* tools.
- Optionally, surface a one-time
console.warn when isSonaAvailable() returns false so the
degraded mode is visible rather than silent.
A minimal post-publish smoke test (npm i @ruvector/sona@latest && node -e "require('@ruvector/sona')")
in CI would prevent regressions.
Summary
@ruvector/sona@0.1.6is published to npm without its build output. The packagecontains only
README.mdandpackage.json— noindex.jsand nodist/— yetpackage.jsonmainpoints atindex.js. As a resultrequire('@ruvector/sona')throwsMODULE_NOT_FOUND, which silently disables all SONA-backed routing inruvector@0.2.26.Environment
ruvector@0.2.26(latest)@ruvector/sona@0.1.6Reproduction
Impact
dist/core/intelligence-engine.jsgates SONA onisSonaAvailable(), which doesrequire('@ruvector/sona')inside a try/catch. Because the require throws, the enginesets
this.sona = null, so:this.sona.findPatterns(embed, 5)never runs →patterns = []hooks route/mcp__ruvector__hooks_routecall returnssonaPatterns: 0route()is permanently deadSo SONA-enhanced routing is non-functional end-to-end despite being fully wired, and there
is no surfaced error — it fails silently via the catch.
The same failure mode affects
@ruvector/pi-brain@0.1.1(also shipssrc/only, nodist/),which breaks all
brain_*MCP tools (No "exports" main defined). Likely the same rootcause in the publish pipeline.
Suggested solution
npm pack --dry-runinnpm/packages/sonashould list the built entrypoint. Add it to CI as a gate.
filesallowlist / build step. Either:dist/(orindex.js) is produced by aprepublishOnly(orprepack) buildscript, and
package.jsonfilesincludes the built output (a too-narrowfilesfield isthe most common cause of a
src-only / build-less tarball).main/exportsmatch what actually ships (point at the real built file).@ruvector/pi-brain— it exhibits the identical defect andgates the
brain_*tools.console.warnwhenisSonaAvailable()returns false so thedegraded mode is visible rather than silent.
A minimal post-publish smoke test (
npm i @ruvector/sona@latest && node -e "require('@ruvector/sona')")in CI would prevent regressions.