@edihasaj/recall 0.9.2 → 0.9.4

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.
Files changed (46) hide show
  1. package/dist/{chunk-PLOL3UCO.js → chunk-5GKJR75B.js} +4 -4
  2. package/dist/{chunk-UPSMHCTY.js → chunk-AE646XCL.js} +2 -2
  3. package/dist/{chunk-OGZO2WKA.js → chunk-ETQ4ZICM.js} +7 -7
  4. package/dist/{chunk-QLAFLCY4.js → chunk-FHEH6QDU.js} +3 -1
  5. package/dist/{chunk-QLAFLCY4.js.map → chunk-FHEH6QDU.js.map} +1 -1
  6. package/dist/{chunk-K5PIUKRM.js → chunk-ILPPEXXU.js} +3 -3
  7. package/dist/{chunk-VYZSP23L.js → chunk-IWKO72WH.js} +21 -17
  8. package/dist/{chunk-VYZSP23L.js.map → chunk-IWKO72WH.js.map} +1 -1
  9. package/dist/{chunk-57OKXD4B.js → chunk-LXM75CET.js} +7 -7
  10. package/dist/{chunk-IBNDQXUB.js → chunk-O2SK7DSZ.js} +7 -6
  11. package/dist/chunk-O2SK7DSZ.js.map +1 -0
  12. package/dist/{chunk-HGZOF7YH.js → chunk-U77N3BFL.js} +2 -2
  13. package/dist/{chunk-CYQPEGXG.js → chunk-UJ3CEOAR.js} +24 -11
  14. package/dist/{chunk-CYQPEGXG.js.map → chunk-UJ3CEOAR.js.map} +1 -1
  15. package/dist/{chunk-PQJRYAVG.js → chunk-UZBJBVAW.js} +12 -4
  16. package/dist/{chunk-PQJRYAVG.js.map → chunk-UZBJBVAW.js.map} +1 -1
  17. package/dist/{cleanup-62AZROOV.js → cleanup-AXEV7OYT.js} +6 -6
  18. package/dist/cli.js +23 -23
  19. package/dist/daemon.js +11 -11
  20. package/dist/{dispatcher-GJNTZX2I.js → dispatcher-KJHTFHYA.js} +6 -6
  21. package/dist/{embeddings-E362AC3R.js → embeddings-ZFZRA46X.js} +3 -3
  22. package/dist/{ingest-BLMXKKGP.js → ingest-HET7DF2P.js} +4 -4
  23. package/dist/{keychain-PWFWKTZW.js → keychain-PA25RZXE.js} +2 -2
  24. package/dist/mcp.js +9 -9
  25. package/dist/{memory-value-B3AQW4IE.js → memory-value-TNQOOIVG.js} +6 -6
  26. package/dist/{quality-MIDMOC3L.js → quality-JMTT3OOA.js} +7 -7
  27. package/dist/retrieval-2STFA5XU.js +13 -0
  28. package/dist/{tasks-6CDIKOIR.js → tasks-INHGPSBF.js} +6 -6
  29. package/package.json +1 -1
  30. package/dist/chunk-IBNDQXUB.js.map +0 -1
  31. package/dist/retrieval-FHCKFVXX.js +0 -13
  32. /package/dist/{chunk-PLOL3UCO.js.map → chunk-5GKJR75B.js.map} +0 -0
  33. /package/dist/{chunk-UPSMHCTY.js.map → chunk-AE646XCL.js.map} +0 -0
  34. /package/dist/{chunk-OGZO2WKA.js.map → chunk-ETQ4ZICM.js.map} +0 -0
  35. /package/dist/{chunk-K5PIUKRM.js.map → chunk-ILPPEXXU.js.map} +0 -0
  36. /package/dist/{chunk-57OKXD4B.js.map → chunk-LXM75CET.js.map} +0 -0
  37. /package/dist/{chunk-HGZOF7YH.js.map → chunk-U77N3BFL.js.map} +0 -0
  38. /package/dist/{cleanup-62AZROOV.js.map → cleanup-AXEV7OYT.js.map} +0 -0
  39. /package/dist/{dispatcher-GJNTZX2I.js.map → dispatcher-KJHTFHYA.js.map} +0 -0
  40. /package/dist/{embeddings-E362AC3R.js.map → embeddings-ZFZRA46X.js.map} +0 -0
  41. /package/dist/{ingest-BLMXKKGP.js.map → ingest-HET7DF2P.js.map} +0 -0
  42. /package/dist/{keychain-PWFWKTZW.js.map → keychain-PA25RZXE.js.map} +0 -0
  43. /package/dist/{memory-value-B3AQW4IE.js.map → memory-value-TNQOOIVG.js.map} +0 -0
  44. /package/dist/{quality-MIDMOC3L.js.map → quality-JMTT3OOA.js.map} +0 -0
  45. /package/dist/{retrieval-FHCKFVXX.js.map → retrieval-2STFA5XU.js.map} +0 -0
  46. /package/dist/{tasks-6CDIKOIR.js.map → tasks-INHGPSBF.js.map} +0 -0
@@ -2,7 +2,7 @@ import {
2
2
  CONFIDENCE,
3
3
  PROMOTION,
4
4
  queueMemoryEmbeddingSync
5
- } from "./chunk-PQJRYAVG.js";
5
+ } from "./chunk-UZBJBVAW.js";
6
6
  import {
7
7
  isPlausibleEntityName,
8
8
  linkMemoryToEntity,
@@ -810,4 +810,4 @@ export {
810
810
  getMemoryFeedbackSummaries,
811
811
  feedbackWeightedScore
812
812
  };
813
- //# sourceMappingURL=chunk-HGZOF7YH.js.map
813
+ //# sourceMappingURL=chunk-U77N3BFL.js.map
@@ -6,16 +6,16 @@ import {
6
6
  recordAudit,
7
7
  redactSensitiveValue,
8
8
  seedScannedConfidence
9
- } from "./chunk-IBNDQXUB.js";
9
+ } from "./chunk-O2SK7DSZ.js";
10
10
  import {
11
11
  recordInjectionValueEvents,
12
12
  recordMemoryInjections,
13
13
  recordOutcomeValueEvent,
14
14
  resolveMemoryInjectionOutcome
15
- } from "./chunk-PLOL3UCO.js";
15
+ } from "./chunk-5GKJR75B.js";
16
16
  import {
17
17
  textMatchScore
18
- } from "./chunk-QLAFLCY4.js";
18
+ } from "./chunk-FHEH6QDU.js";
19
19
  import {
20
20
  asc,
21
21
  desc
@@ -34,7 +34,7 @@ import {
34
34
  recordFeedback,
35
35
  rejectMemory,
36
36
  statusFromConfidence
37
- } from "./chunk-HGZOF7YH.js";
37
+ } from "./chunk-U77N3BFL.js";
38
38
  import {
39
39
  CONFIDENCE,
40
40
  RetrievalEvalCase,
@@ -52,7 +52,7 @@ import {
52
52
  readUtf8FileIfExists,
53
53
  resolveProvider,
54
54
  tagActivitySource
55
- } from "./chunk-PQJRYAVG.js";
55
+ } from "./chunk-UZBJBVAW.js";
56
56
  import {
57
57
  Column,
58
58
  Columns,
@@ -5190,13 +5190,26 @@ function dedupeMemoriesForInjection(memories4) {
5190
5190
  }
5191
5191
  function dedupeRankedMemoriesForInjection(ranked) {
5192
5192
  const seen = /* @__PURE__ */ new Set();
5193
- return ranked.filter((item) => {
5193
+ const selected = [];
5194
+ for (const item of ranked) {
5194
5195
  const key = canonicalInjectionText(item.memory);
5195
- if (!key) return false;
5196
- if (seen.has(key)) return false;
5196
+ if (!key || seen.has(key)) continue;
5197
+ const scopedOverrideIndex = selected.findIndex(
5198
+ (existing) => existing.memory.scope === "global" && item.memory.scope !== "global" && existing.memory.type === item.memory.type && textMatchScore(existing.memory.text, item.memory.text).score >= 0.6
5199
+ );
5200
+ if (scopedOverrideIndex >= 0) {
5201
+ seen.add(key);
5202
+ selected[scopedOverrideIndex] = item;
5203
+ continue;
5204
+ }
5205
+ const hasNarrowerEquivalent = selected.some(
5206
+ (existing) => existing.memory.scope !== "global" && item.memory.scope === "global" && existing.memory.type === item.memory.type && textMatchScore(existing.memory.text, item.memory.text).score >= 0.6
5207
+ );
5208
+ if (hasNarrowerEquivalent) continue;
5197
5209
  seen.add(key);
5198
- return true;
5199
- });
5210
+ selected.push(item);
5211
+ }
5212
+ return selected;
5200
5213
  }
5201
5214
  function canonicalInjectionText(memory) {
5202
5215
  return renderMemoryText(memory).toLowerCase().replace(/[`*_]/g, "").replace(/\s+/g, " ").trim();
@@ -6522,4 +6535,4 @@ export {
6522
6535
  pruneMemories,
6523
6536
  formatPruneReport
6524
6537
  };
6525
- //# sourceMappingURL=chunk-CYQPEGXG.js.map
6538
+ //# sourceMappingURL=chunk-UJ3CEOAR.js.map