@dvquys/qrec 0.2.4 → 0.3.0
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/package.json +5 -2
- package/plugin/scripts/bun-finder.js +25 -0
- package/plugin/scripts/qrec-mcp.cjs +62 -0
- package/plugin/scripts/qrec-mcp.js +24 -0
- package/plugin/scripts/qrec.cjs +217 -57
package/package.json
CHANGED
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dvquys/qrec",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.3.0",
|
|
4
4
|
"description": "Purpose-built session recall engine — persistent daemon with BM25 + vector hybrid search",
|
|
5
5
|
"bin": {
|
|
6
6
|
"qrec": "plugin/scripts/qrec-cli.js"
|
|
7
7
|
},
|
|
8
8
|
"files": [
|
|
9
9
|
"plugin/scripts/qrec.cjs",
|
|
10
|
+
"plugin/scripts/qrec-mcp.cjs",
|
|
10
11
|
"plugin/scripts/qrec-cli.js",
|
|
12
|
+
"plugin/scripts/qrec-mcp.js",
|
|
13
|
+
"plugin/scripts/bun-finder.js",
|
|
11
14
|
"README.md"
|
|
12
15
|
],
|
|
13
16
|
"scripts": {
|
|
@@ -18,7 +21,7 @@
|
|
|
18
21
|
},
|
|
19
22
|
"dependencies": {
|
|
20
23
|
"@modelcontextprotocol/sdk": "^1.0.0",
|
|
21
|
-
"node-llama-cpp": "3.
|
|
24
|
+
"node-llama-cpp": "3.17.1",
|
|
22
25
|
"sqlite-vec": "^0.1.0"
|
|
23
26
|
},
|
|
24
27
|
"devDependencies": {
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
const { spawnSync } = require("child_process");
|
|
3
|
+
const { existsSync } = require("fs");
|
|
4
|
+
const { homedir } = require("os");
|
|
5
|
+
const path = require("path");
|
|
6
|
+
|
|
7
|
+
const BUN_CANDIDATES = [
|
|
8
|
+
path.join(homedir(), ".bun", "bin", "bun"),
|
|
9
|
+
"/usr/local/bin/bun",
|
|
10
|
+
"/opt/homebrew/bin/bun",
|
|
11
|
+
"/home/linuxbrew/.linuxbrew/bin/bun",
|
|
12
|
+
];
|
|
13
|
+
|
|
14
|
+
function findBun() {
|
|
15
|
+
for (const candidate of BUN_CANDIDATES) {
|
|
16
|
+
if (existsSync(candidate)) return candidate;
|
|
17
|
+
}
|
|
18
|
+
try {
|
|
19
|
+
const r = spawnSync("which", ["bun"], { encoding: "utf-8", timeout: 3000 });
|
|
20
|
+
if (r.status === 0 && r.stdout.trim()) return r.stdout.trim();
|
|
21
|
+
} catch {}
|
|
22
|
+
return null;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
module.exports = { findBun };
|