toon-memory 4.4.0 → 4.4.2
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/mcp/server.js +5 -4
- package/package.json +1 -1
- package/src/lib/quality.ts +4 -2
package/mcp/server.js
CHANGED
|
@@ -23142,10 +23142,11 @@ function generateSmartRecall(data, intent, opts = {}) {
|
|
|
23142
23142
|
const ngBoost = ngMatch ? ngScore * 0.15 : 0;
|
|
23143
23143
|
let combined;
|
|
23144
23144
|
const utilityBoost = (opts.utility?.get(e.key) || 0) * 0.25;
|
|
23145
|
+
const denseBoost = (opts.dense?.get(e.key) || 0) * 0.25;
|
|
23145
23146
|
if (opts.rrf) {
|
|
23146
|
-
combined = (fused?.get(e.key) ?? 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + ngBoost + utilityBoost;
|
|
23147
|
+
combined = (fused?.get(e.key) ?? 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + ngBoost + utilityBoost + denseBoost;
|
|
23147
23148
|
} else {
|
|
23148
|
-
combined = bm25Score + 0.3 * centScore + 0.3 * impScore + (matchesQuery ? 0.5 : 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + utilityBoost;
|
|
23149
|
+
combined = bm25Score + 0.3 * centScore + 0.3 * impScore + (matchesQuery ? 0.5 : 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + utilityBoost + denseBoost;
|
|
23149
23150
|
}
|
|
23150
23151
|
return { entry: e, score: combined, matchesQuery, priority: e.priority, bm25Score };
|
|
23151
23152
|
}).filter((x) => x.score > 0 || x.matchesQuery).sort((a, b2) => {
|
|
@@ -49734,7 +49735,7 @@ var INSTRUCTIONS = [
|
|
|
49734
49735
|
"Save decisions, directives and resolved bugs with memory_remember."
|
|
49735
49736
|
].join(" ");
|
|
49736
49737
|
var server = new McpServer(
|
|
49737
|
-
{ name: "toon-memory", version: "4.4.
|
|
49738
|
+
{ name: "toon-memory", version: "4.4.2" },
|
|
49738
49739
|
{
|
|
49739
49740
|
instructions: INSTRUCTIONS,
|
|
49740
49741
|
capabilities: { tools: { listChanged: true }, resources: { listChanged: true }, experimental: { "io.modelcontextprotocol/ui": {} } }
|
|
@@ -49749,7 +49750,7 @@ s.setRequestHandler(InitializeRequestSchema, async (request) => {
|
|
|
49749
49750
|
return {
|
|
49750
49751
|
protocolVersion,
|
|
49751
49752
|
capabilities: s.getCapabilities(),
|
|
49752
|
-
serverInfo: { name: "toon-memory", version: "4.4.
|
|
49753
|
+
serverInfo: { name: "toon-memory", version: "4.4.2" },
|
|
49753
49754
|
...s._instructions && { instructions: s._instructions }
|
|
49754
49755
|
};
|
|
49755
49756
|
});
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "toon-memory",
|
|
3
3
|
"mcpName": "io.github.LuiggiVal08/toon-memory",
|
|
4
|
-
"version": "4.4.
|
|
4
|
+
"version": "4.4.2",
|
|
5
5
|
"description": "The Continuity Layer for AI Agents — an MCP memory server that preserves project knowledge, decisions, and conventions across sessions so every session starts where the last one ended. Offline, token-efficient, no LLM, no server; works with 20+ agents.",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"bin": {
|
package/src/lib/quality.ts
CHANGED
|
@@ -217,6 +217,7 @@ export function generateSmartRecall(
|
|
|
217
217
|
explain?: boolean
|
|
218
218
|
budgetTokens?: number
|
|
219
219
|
utility?: Map<string, number>
|
|
220
|
+
dense?: Map<string, number>
|
|
220
221
|
} = {}
|
|
221
222
|
): string {
|
|
222
223
|
const entries = parseEntries(data)
|
|
@@ -305,11 +306,12 @@ export function generateSmartRecall(
|
|
|
305
306
|
const ngBoost = ngMatch ? ngScore * 0.15 : 0
|
|
306
307
|
let combined: number
|
|
307
308
|
const utilityBoost = (opts.utility?.get(e.key) || 0) * 0.25
|
|
309
|
+
const denseBoost = (opts.dense?.get(e.key) || 0) * 0.25
|
|
308
310
|
if (opts.rrf) {
|
|
309
|
-
combined = (fused?.get(e.key) ?? 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + ngBoost + utilityBoost
|
|
311
|
+
combined = (fused?.get(e.key) ?? 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + ngBoost + utilityBoost + denseBoost
|
|
310
312
|
} else {
|
|
311
313
|
combined =
|
|
312
|
-
bm25Score + 0.3 * centScore + 0.3 * impScore + (matchesQuery ? 0.5 : 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + utilityBoost
|
|
314
|
+
bm25Score + 0.3 * centScore + 0.3 * impScore + (matchesQuery ? 0.5 : 0) - drift + sessionBias + langBoost + folderBoost + warningBoost + impBoost + evBoost + utilityBoost + denseBoost
|
|
313
315
|
}
|
|
314
316
|
return { entry: e, score: combined, matchesQuery, priority: e.priority, bm25Score }
|
|
315
317
|
})
|