@skedulo/memory-hub-mcp 0.2.9 → 0.2.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -85,12 +85,6 @@ Developer tools → API tokens. It never mints a token you didn't ask for.
85
85
 
86
86
  Then restart Claude Code, or quit Claude Desktop completely and reopen it.
87
87
 
88
- If your npm skips install scripts it hasn't been told to allow (npm 12 does by default), the
89
- embedding model's `sharp` dependency isn't built. The server still runs, but saves and recalls match
90
- on text only, and tool results say why. To fix it, add `allow-scripts=sharp` to `~/.npmrc`, rerun
91
- `npm install -g @skedulo/memory-hub-mcp`, delete `~/.npm/_npx` (npx keeps its own copy there), and
92
- restart.
93
-
94
88
  Installing the package is not the same as having access: every call is authorised by your personal
95
89
  Skedulo API token, and the package is useless without one.
96
90
 
@@ -106,7 +100,7 @@ once, and `setup --no-auto-update` pins the installed binary instead (update it
106
100
  `npm i -g @skedulo/memory-hub-mcp`, then re-run `setup`).
107
101
 
108
102
  The first start after a release fetches the new version, about 1 to 5 seconds with the dependencies
109
- already in npm's cache. `setup` warms that cache, so nobody's first start pays the ~430 MB cold
103
+ already in npm's cache. `setup` warms that cache, so nobody's first start pays the ~400 MB cold
110
104
  download (about 16 seconds).
111
105
 
112
106
  ### Releasing
package/dist/cli.js CHANGED
@@ -15,7 +15,15 @@ if (command === 'setup') {
15
15
  else if (command === 'embed') {
16
16
  // eslint-disable-next-line @typescript-eslint/no-var-requires
17
17
  const { runEmbed, readProcessStdin } = require('./embed-cli');
18
- runEmbed(process.argv.slice(3), { readStdin: readProcessStdin, write: (line) => console.log(line) }).then((code) => process.exit(code));
18
+ runEmbed(process.argv.slice(3), { readStdin: readProcessStdin, write: (line) => console.log(line) }).then((code) => {
19
+ // onnxruntime aborts the process if process.exit() runs while its model session is open, so a success ends on its own.
20
+ if (code === 0) {
21
+ process.exitCode = 0;
22
+ }
23
+ else {
24
+ process.exit(code);
25
+ }
26
+ });
19
27
  }
20
28
  else if (command === '--help' || command === '-h') {
21
29
  console.log(`memory-hub-mcp — MCP server for the SE AI Memory Hub
@@ -37,11 +37,12 @@ exports.MODEL_CACHE_DIR = process.env.MEMORY_HUB_MODEL_CACHE || (0, path_1.join)
37
37
  let extractorPromise;
38
38
  let loadFailure;
39
39
  const EXTRACTOR_LOAD_TIMEOUT_MS = 15_000;
40
- // Imported here, not at module top: the library needs sharp's native build, which npm 12 skips by default, and a top-level import would stop the whole server from starting.
40
+ // Imported here, not at module top: the library loads native modules, and one that fails must not stop the whole server from starting.
41
41
  async function loadPipeline() {
42
- const { env, pipeline } = await Promise.resolve().then(() => __importStar(require('@xenova/transformers')));
42
+ const { env, pipeline } = await Promise.resolve().then(() => __importStar(require('@huggingface/transformers')));
43
43
  env.cacheDir = exports.MODEL_CACHE_DIR;
44
- return pipeline('feature-extraction', 'Xenova/all-MiniLM-L6-v2');
44
+ // q8 is the quantized model every stored vector was made with; the library's default would change them all.
45
+ return pipeline('feature-extraction', 'Xenova/all-MiniLM-L6-v2', { dtype: 'q8' });
45
46
  }
46
47
  function loadExtractor() {
47
48
  let timer;
@@ -72,15 +73,11 @@ function getExtractor() {
72
73
  }
73
74
  return extractorPromise;
74
75
  }
75
- // Shown on tool results so the agent can tell the user why semantic matching is off.
76
76
  function embeddingNotice() {
77
77
  if (!loadFailure) {
78
78
  return undefined;
79
79
  }
80
- const fix = loadFailure.includes('sharp')
81
- ? ' npm blocked the install script of sharp, which the model needs: add allow-scripts=sharp to ~/.npmrc, then reinstall (rerun npm install -g @skedulo/memory-hub-mcp, or delete ~/.npm/_npx when the server runs through npx) and restart.'
82
- : '';
83
- return `Note: semantic matching is off because the embedding model could not load (${loadFailure}). Saves and recalls still work but match on text only, and new saves are stored without an embedding.${fix}`;
80
+ return `Note: semantic matching is off because the embedding model could not load (${loadFailure}). Saves and recalls still work but match on text only, and new saves are stored without an embedding.`;
84
81
  }
85
82
  exports.embeddingNotice = embeddingNotice;
86
83
  // 384-dimension vector (all-MiniLM-L6-v2's fixed output size), mean-pooled and
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@skedulo/memory-hub-mcp",
3
- "version": "0.2.9",
3
+ "version": "0.2.10",
4
4
  "description": "MCP server for the SE AI Memory Hub: recall and save developer memory from Claude Code and Claude Desktop.",
5
5
  "license": "UNLICENSED",
6
6
  "repository": {
@@ -31,8 +31,8 @@
31
31
  "prepack": "./scripts/copy-assets.sh"
32
32
  },
33
33
  "dependencies": {
34
+ "@huggingface/transformers": "3.8.1",
34
35
  "@modelcontextprotocol/sdk": "^1.30.0",
35
- "@xenova/transformers": "^2.17.2",
36
36
  "axios": "^1.7.0",
37
37
  "zod": "^3.25.0"
38
38
  },