@swarmvaultai/engine 3.16.0 → 3.17.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/dist/chunk-65IRGGXX.js +27576 -0
- package/dist/chunk-HORJDLXV.js +27614 -0
- package/dist/chunk-JEWLYIHN.js +27619 -0
- package/dist/chunk-VSDBQVSE.js +27584 -0
- package/dist/hooks/claude.js +236 -19
- package/dist/hooks/codex.js +134 -6
- package/dist/hooks/copilot.js +95 -3
- package/dist/hooks/gemini.js +153 -5
- package/dist/hooks/opencode.js +4 -2
- package/dist/index.d.ts +22 -1
- package/dist/index.js +272 -14
- package/dist/memory-GFOW2QWQ.js +32 -0
- package/dist/memory-GSCQ6F53.js +32 -0
- package/dist/memory-HMP3Y4PQ.js +32 -0
- package/dist/memory-PQWSJ4RR.js +32 -0
- package/dist/viewer/assets/{index-Cq5HAlrV.js → index-BZE-2FtS.js} +37 -37
- package/dist/viewer/index.html +1 -1
- package/dist/viewer/lib.js +29 -1
- package/package.json +3 -3
package/dist/viewer/index.html
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<meta charset="UTF-8" />
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
6
|
<title>SwarmVault Graph</title>
|
|
7
|
-
<script type="module" crossorigin src="/assets/index-
|
|
7
|
+
<script type="module" crossorigin src="/assets/index-BZE-2FtS.js"></script>
|
|
8
8
|
<link rel="stylesheet" crossorigin href="/assets/index-CxosWf8Q.css">
|
|
9
9
|
</head>
|
|
10
10
|
<body>
|
package/dist/viewer/lib.js
CHANGED
|
@@ -299,7 +299,8 @@ function embeddedGraphQuery(graph, question, searchResults, options) {
|
|
|
299
299
|
communities,
|
|
300
300
|
matches,
|
|
301
301
|
summary: [
|
|
302
|
-
|
|
302
|
+
formatTopMatchesLine(matches, nodesById, pagesById),
|
|
303
|
+
formatSeedsLine(seeds),
|
|
303
304
|
`Visited nodes: ${visitedNodeIds.length}`,
|
|
304
305
|
`Visited edges: ${visitedEdgeIds.size}`,
|
|
305
306
|
`Touched group patterns: ${hyperedgeIds.length}`,
|
|
@@ -308,6 +309,33 @@ function embeddedGraphQuery(graph, question, searchResults, options) {
|
|
|
308
309
|
].join("\n")
|
|
309
310
|
};
|
|
310
311
|
}
|
|
312
|
+
function formatTopMatchesLine(matches, nodesById, pagesById) {
|
|
313
|
+
if (matches.length === 0) {
|
|
314
|
+
return "Top matches: none";
|
|
315
|
+
}
|
|
316
|
+
const parts = matches.slice(0, 8).map((match) => {
|
|
317
|
+
let pagePath;
|
|
318
|
+
if (match.type === "page") {
|
|
319
|
+
pagePath = pagesById.get(match.id)?.path ?? match.id;
|
|
320
|
+
} else if (match.type === "node") {
|
|
321
|
+
const pageId = nodesById.get(match.id)?.pageId;
|
|
322
|
+
if (pageId) {
|
|
323
|
+
pagePath = pagesById.get(pageId)?.path ?? pageId;
|
|
324
|
+
}
|
|
325
|
+
}
|
|
326
|
+
return `${match.label || match.id} (${match.type}, score ${match.score}${pagePath ? `, page ${pagePath}` : ""})`;
|
|
327
|
+
});
|
|
328
|
+
const more = matches.length > 8 ? ` (+${matches.length - 8} more)` : "";
|
|
329
|
+
return `Top matches: ${parts.join("; ")}${more}`;
|
|
330
|
+
}
|
|
331
|
+
function formatSeedsLine(seeds) {
|
|
332
|
+
if (seeds.length === 0) {
|
|
333
|
+
return "Seeds: none";
|
|
334
|
+
}
|
|
335
|
+
const shown = seeds.slice(0, 15).join(", ");
|
|
336
|
+
const more = seeds.length > 15 ? ` (+${seeds.length - 15} more)` : "";
|
|
337
|
+
return `Seeds: ${shown}${more}`;
|
|
338
|
+
}
|
|
311
339
|
function normalizeSnippet(content, query) {
|
|
312
340
|
const normalized = content.replace(/\s+/g, " ").trim();
|
|
313
341
|
if (!query) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@swarmvaultai/engine",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.17.0",
|
|
4
4
|
"description": "Core engine for SwarmVault: ingest, compile, query, lint, and provider abstractions.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"chokidar": "^4.0.3",
|
|
56
56
|
"compromise": "^14.14.4",
|
|
57
57
|
"csv-parse": "^6.2.1",
|
|
58
|
-
"fast-xml-parser": "^5.
|
|
58
|
+
"fast-xml-parser": "^5.8.0",
|
|
59
59
|
"fflate": "^0.8.2",
|
|
60
60
|
"graphology": "^0.26.0",
|
|
61
61
|
"graphology-communities-louvain": "^2.0.2",
|
|
@@ -94,9 +94,9 @@
|
|
|
94
94
|
"@types/node": "^24.6.0",
|
|
95
95
|
"@types/turndown": "^5.0.5",
|
|
96
96
|
"graphology-types": "^0.24.8",
|
|
97
|
-
"tsup": "^8.5.0",
|
|
98
97
|
"tree-sitter-julia": "0.23.1",
|
|
99
98
|
"tree-sitter-systemverilog": "0.3.1",
|
|
99
|
+
"tsup": "^8.5.0",
|
|
100
100
|
"vitest": "^3.2.4"
|
|
101
101
|
}
|
|
102
102
|
}
|