@remnic/core 10.0.113 → 10.0.114
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
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@remnic/core",
|
|
3
|
-
"version": "10.0.
|
|
3
|
+
"version": "10.0.114",
|
|
4
4
|
"description": "Framework-agnostic Remnic memory engine — orchestrator, storage, extraction, search, trust zones",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -3386,7 +3386,7 @@
|
|
|
3386
3386
|
"core"
|
|
3387
3387
|
],
|
|
3388
3388
|
"peerDependencies": {
|
|
3389
|
-
"@remnic/coding-graph": "^10.0.
|
|
3389
|
+
"@remnic/coding-graph": "^10.0.114"
|
|
3390
3390
|
},
|
|
3391
3391
|
"peerDependenciesMeta": {
|
|
3392
3392
|
"@remnic/coding-graph": {
|
|
@@ -409,6 +409,7 @@ function flushHarness(memories: FlushMemory[], buffered: FlushBuffer) {
|
|
|
409
409
|
namespaceFromPath: () => "default",
|
|
410
410
|
storageRouter: {
|
|
411
411
|
storageFor: async () => ({
|
|
412
|
+
dir: "/memory",
|
|
412
413
|
flushAccessTracking: async (entries: AccessTrackingEntry[]) => {
|
|
413
414
|
out.flushed = entries;
|
|
414
415
|
},
|
|
@@ -496,3 +497,16 @@ test("flushAccessTracking takes the earlier memory when a relative path matches
|
|
|
496
497
|
await coordinator.flushAccessTracking();
|
|
497
498
|
assert.deepEqual(out.flushed.map((e) => [e.memoryPath, e.newCount]), [[underMemoryDir, 6]]);
|
|
498
499
|
});
|
|
500
|
+
|
|
501
|
+
test("flushAccessTracking tries the plain path before the QMD collection candidates", async () => {
|
|
502
|
+
const viaCandidate = path.join("/memory", "facts", "x.md");
|
|
503
|
+
const viaPlainPath = path.join("/memory", "collection", "facts", "x.md");
|
|
504
|
+
const memories = [
|
|
505
|
+
{ path: viaCandidate, frontmatter: { id: "cand-a", accessCount: 5 } },
|
|
506
|
+
{ path: viaPlainPath, frontmatter: { id: "plain-b", accessCount: 50 } },
|
|
507
|
+
];
|
|
508
|
+
const buffered: FlushBuffer = new Map([["default:x", { memoryId: "x", memoryPath: "collection/facts/x.md", count: 1, lastAccessed: stamp }]]);
|
|
509
|
+
const { out, coordinator } = flushHarness(memories, buffered);
|
|
510
|
+
await coordinator.flushAccessTracking();
|
|
511
|
+
assert.deepEqual(out.flushed.map((e) => [e.memoryPath, e.newCount]), [[viaPlainPath, 51]]);
|
|
512
|
+
});
|