@remnic/core 9.3.680 → 9.3.682

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 (167) hide show
  1. package/dist/access-boundary.d.ts +178 -0
  2. package/dist/access-boundary.js +121 -0
  3. package/dist/access-cli.js +115 -101
  4. package/dist/access-cli.js.map +1 -1
  5. package/dist/access-http.d.ts +1 -1
  6. package/dist/access-http.js +48 -46
  7. package/dist/access-mcp.d.ts +1 -1
  8. package/dist/access-mcp.js +44 -42
  9. package/dist/access-operations.d.ts +127 -0
  10. package/dist/access-operations.js +115 -0
  11. package/dist/access-operations.js.map +1 -0
  12. package/dist/access-schema.d.ts +34 -34
  13. package/dist/access-schema.js +6 -6
  14. package/dist/{access-service-S9oGKPZc.d.ts → access-service-DvA6jyHL.d.ts} +1 -1
  15. package/dist/access-service.d.ts +1 -1
  16. package/dist/access-service.js +40 -40
  17. package/dist/access-surface-catalog.d.ts +125 -0
  18. package/dist/access-surface-catalog.js +162 -0
  19. package/dist/access-surface-catalog.js.map +1 -0
  20. package/dist/adapters/index.js +7 -7
  21. package/dist/adapters/registry.js +3 -3
  22. package/dist/auto-sync-5CJBJMPZ.js +1 -1
  23. package/dist/briefing.js +8 -8
  24. package/dist/{capsule-crypto-YO5QJ6L3.js → capsule-crypto-7FJQINUR.js} +2 -2
  25. package/dist/capsule-crypto-7FJQINUR.js.map +1 -0
  26. package/dist/causal-behavior.js +5 -5
  27. package/dist/causal-chain.js +3 -3
  28. package/dist/causal-consolidation.js +16 -16
  29. package/dist/causal-retrieval.js +3 -3
  30. package/dist/causal-trajectory.js +1 -1
  31. package/dist/{chunk-BXLOS5AJ.js → chunk-2NLLXCJG.js} +2 -2
  32. package/dist/{chunk-JBPKEARU.js → chunk-2QSZNTDO.js} +7 -7
  33. package/dist/{chunk-3OKWZT7F.js → chunk-3IND7N4X.js} +2 -2
  34. package/dist/{chunk-GYSYLGNE.js → chunk-7MOTEVAA.js} +2 -2
  35. package/dist/{chunk-6T4LTI2F.js → chunk-7XH7VJN4.js} +4 -4
  36. package/dist/{chunk-AGNBY3VG.js → chunk-APJQ6UEA.js} +4 -4
  37. package/dist/{chunk-LZSMQHXC.js → chunk-ARLRTZZZ.js} +5 -5
  38. package/dist/{chunk-DL6H3D7S.js → chunk-ARV3AUOM.js} +2 -2
  39. package/dist/{chunk-Q2H5U37U.js → chunk-B2B2IHUH.js} +2 -2
  40. package/dist/{chunk-SECQS4G4.js → chunk-BTVX7ZXZ.js} +5 -5
  41. package/dist/{chunk-DGEZKYVI.js → chunk-DOCTITOP.js} +4 -4
  42. package/dist/{chunk-EQYP3HA6.js → chunk-EG4TCVMU.js} +2 -2
  43. package/dist/{chunk-SLTKP5WJ.js → chunk-EW5KFXHL.js} +4 -4
  44. package/dist/{chunk-5TEYIXMP.js → chunk-FDSOMA6M.js} +28 -41
  45. package/dist/chunk-FDSOMA6M.js.map +1 -0
  46. package/dist/{chunk-CTCPB57O.js → chunk-G7Z3C2X6.js} +2 -2
  47. package/dist/{chunk-OBM7EVFU.js → chunk-H4BDNIKQ.js} +53 -53
  48. package/dist/{chunk-MTJ2LFAJ.js → chunk-H6PMGMNP.js} +2 -2
  49. package/dist/{chunk-7AAKSHDG.js → chunk-I3HSKQT7.js} +136 -136
  50. package/dist/{chunk-NXBXM7Q6.js → chunk-I75DF4FZ.js} +2 -2
  51. package/dist/{chunk-RC3AFF6Z.js → chunk-JD4SCARD.js} +1 -1
  52. package/dist/{chunk-LVTTO3VC.js → chunk-KACIOX42.js} +2 -2
  53. package/dist/{chunk-VDX2J7OX.js → chunk-KQAFEZQX.js} +2 -2
  54. package/dist/{chunk-ATRB6Q25.js → chunk-KV6CX4ON.js} +2 -2
  55. package/dist/{chunk-VL5JJOOY.js → chunk-L5MUA6Q7.js} +5 -5
  56. package/dist/{chunk-W67ZZDHO.js → chunk-M4I3TREG.js} +75 -75
  57. package/dist/chunk-NHFXF4ZO.js +107 -0
  58. package/dist/chunk-NHFXF4ZO.js.map +1 -0
  59. package/dist/{chunk-MNUPGYIV.js → chunk-NQMBSSWW.js} +2 -2
  60. package/dist/{chunk-V4ZHKCGA.js → chunk-O2WELT5C.js} +5 -5
  61. package/dist/{chunk-Z6SEG36L.js → chunk-OUWAQVDJ.js} +4 -4
  62. package/dist/{chunk-57ME5VSI.js → chunk-Q5ZU3RNY.js} +4 -4
  63. package/dist/{chunk-ACYX37IM.js → chunk-QUA2JPH2.js} +6 -6
  64. package/dist/{chunk-DWQPM67F.js → chunk-QVWM4C24.js} +37 -32
  65. package/dist/chunk-QVWM4C24.js.map +1 -0
  66. package/dist/{chunk-2AP4QJX5.js → chunk-TOQEZ63C.js} +8 -8
  67. package/dist/{chunk-EUM7CZFM.js → chunk-TY5NT3T3.js} +17 -17
  68. package/dist/{chunk-ZCVPFDHB.js → chunk-UAODC6GJ.js} +14 -14
  69. package/dist/{chunk-JI6HWBYL.js → chunk-UDJLF3BO.js} +2 -2
  70. package/dist/{chunk-YJ4J2JJ2.js → chunk-UJDV2NLT.js} +9 -9
  71. package/dist/chunk-V254FAT5.js +85 -0
  72. package/dist/chunk-V254FAT5.js.map +1 -0
  73. package/dist/{chunk-3IE22DJ2.js → chunk-WEPMT6SC.js} +10 -10
  74. package/dist/{chunk-DQEMWVMT.js → chunk-X7Y7WX73.js} +1 -1
  75. package/dist/{chunk-EZ25VE3G.js → chunk-YNDLCWXS.js} +4 -4
  76. package/dist/{cli-B2Ve7R22.d.ts → cli-feUe-x3I.d.ts} +1 -1
  77. package/dist/cli.d.ts +2 -2
  78. package/dist/cli.js +75 -73
  79. package/dist/compounding/engine.js +9 -9
  80. package/dist/connectors/codex-materialize-runner.js +9 -9
  81. package/dist/connectors/index.js +9 -9
  82. package/dist/consolidation-provenance-check.js +2 -2
  83. package/dist/dashboard-runtime.js +2 -2
  84. package/dist/entity-retrieval.js +7 -7
  85. package/dist/extraction.js +2 -2
  86. package/dist/{first-start-migration-PG5HBC3K.js → first-start-migration-FF7YFGRP.js} +4 -4
  87. package/dist/index.d.ts +2 -2
  88. package/dist/index.js +209 -207
  89. package/dist/index.js.map +1 -1
  90. package/dist/lcm/engine.js +4 -4
  91. package/dist/lcm/index.js +12 -12
  92. package/dist/maintenance/memory-governance.js +8 -8
  93. package/dist/maintenance/rebuild-memory-lifecycle-ledger.js +7 -7
  94. package/dist/maintenance/rebuild-memory-projection.js +9 -9
  95. package/dist/mcp-memory-inspector-app.d.ts +1 -1
  96. package/dist/namespaces/migrate.js +17 -17
  97. package/dist/namespaces/search.js +8 -8
  98. package/dist/namespaces/storage.js +8 -8
  99. package/dist/operator-toolkit.js +22 -22
  100. package/dist/orchestrator.js +70 -70
  101. package/dist/resume-bundles.js +1 -1
  102. package/dist/schemas.d.ts +28 -28
  103. package/dist/search/factory.js +7 -7
  104. package/dist/search/index.js +11 -11
  105. package/dist/search/lancedb-backend.js +3 -3
  106. package/dist/search/meilisearch-backend.js +3 -3
  107. package/dist/search/orama-backend.js +3 -3
  108. package/dist/semantic-consolidation.js +11 -11
  109. package/dist/semantic-rule-promotion.js +7 -7
  110. package/dist/semantic-rule-verifier.js +8 -8
  111. package/dist/storage.js +6 -6
  112. package/dist/transfer/backup.js +4 -4
  113. package/dist/transfer/capsule-export.js +4 -4
  114. package/dist/transfer/capsule-import.js +3 -3
  115. package/dist/transfer/import-sqlite.js +2 -2
  116. package/dist/transfer/types.d.ts +20 -20
  117. package/dist/verified-recall.js +8 -8
  118. package/package.json +2 -2
  119. package/src/access-boundary.test.ts +212 -0
  120. package/src/access-boundary.ts +235 -0
  121. package/src/access-cli.ts +32 -15
  122. package/src/access-http.ts +38 -28
  123. package/src/access-mcp.ts +41 -35
  124. package/src/access-operations.ts +157 -0
  125. package/src/access-surface-catalog.test.ts +772 -0
  126. package/src/access-surface-catalog.ts +218 -0
  127. package/dist/chunk-5TEYIXMP.js.map +0 -1
  128. package/dist/chunk-DWQPM67F.js.map +0 -1
  129. /package/dist/{capsule-crypto-YO5QJ6L3.js.map → access-boundary.js.map} +0 -0
  130. /package/dist/{chunk-BXLOS5AJ.js.map → chunk-2NLLXCJG.js.map} +0 -0
  131. /package/dist/{chunk-JBPKEARU.js.map → chunk-2QSZNTDO.js.map} +0 -0
  132. /package/dist/{chunk-3OKWZT7F.js.map → chunk-3IND7N4X.js.map} +0 -0
  133. /package/dist/{chunk-GYSYLGNE.js.map → chunk-7MOTEVAA.js.map} +0 -0
  134. /package/dist/{chunk-6T4LTI2F.js.map → chunk-7XH7VJN4.js.map} +0 -0
  135. /package/dist/{chunk-AGNBY3VG.js.map → chunk-APJQ6UEA.js.map} +0 -0
  136. /package/dist/{chunk-LZSMQHXC.js.map → chunk-ARLRTZZZ.js.map} +0 -0
  137. /package/dist/{chunk-DL6H3D7S.js.map → chunk-ARV3AUOM.js.map} +0 -0
  138. /package/dist/{chunk-Q2H5U37U.js.map → chunk-B2B2IHUH.js.map} +0 -0
  139. /package/dist/{chunk-SECQS4G4.js.map → chunk-BTVX7ZXZ.js.map} +0 -0
  140. /package/dist/{chunk-DGEZKYVI.js.map → chunk-DOCTITOP.js.map} +0 -0
  141. /package/dist/{chunk-EQYP3HA6.js.map → chunk-EG4TCVMU.js.map} +0 -0
  142. /package/dist/{chunk-SLTKP5WJ.js.map → chunk-EW5KFXHL.js.map} +0 -0
  143. /package/dist/{chunk-CTCPB57O.js.map → chunk-G7Z3C2X6.js.map} +0 -0
  144. /package/dist/{chunk-OBM7EVFU.js.map → chunk-H4BDNIKQ.js.map} +0 -0
  145. /package/dist/{chunk-MTJ2LFAJ.js.map → chunk-H6PMGMNP.js.map} +0 -0
  146. /package/dist/{chunk-7AAKSHDG.js.map → chunk-I3HSKQT7.js.map} +0 -0
  147. /package/dist/{chunk-NXBXM7Q6.js.map → chunk-I75DF4FZ.js.map} +0 -0
  148. /package/dist/{chunk-RC3AFF6Z.js.map → chunk-JD4SCARD.js.map} +0 -0
  149. /package/dist/{chunk-LVTTO3VC.js.map → chunk-KACIOX42.js.map} +0 -0
  150. /package/dist/{chunk-VDX2J7OX.js.map → chunk-KQAFEZQX.js.map} +0 -0
  151. /package/dist/{chunk-ATRB6Q25.js.map → chunk-KV6CX4ON.js.map} +0 -0
  152. /package/dist/{chunk-VL5JJOOY.js.map → chunk-L5MUA6Q7.js.map} +0 -0
  153. /package/dist/{chunk-W67ZZDHO.js.map → chunk-M4I3TREG.js.map} +0 -0
  154. /package/dist/{chunk-MNUPGYIV.js.map → chunk-NQMBSSWW.js.map} +0 -0
  155. /package/dist/{chunk-V4ZHKCGA.js.map → chunk-O2WELT5C.js.map} +0 -0
  156. /package/dist/{chunk-Z6SEG36L.js.map → chunk-OUWAQVDJ.js.map} +0 -0
  157. /package/dist/{chunk-57ME5VSI.js.map → chunk-Q5ZU3RNY.js.map} +0 -0
  158. /package/dist/{chunk-ACYX37IM.js.map → chunk-QUA2JPH2.js.map} +0 -0
  159. /package/dist/{chunk-2AP4QJX5.js.map → chunk-TOQEZ63C.js.map} +0 -0
  160. /package/dist/{chunk-EUM7CZFM.js.map → chunk-TY5NT3T3.js.map} +0 -0
  161. /package/dist/{chunk-ZCVPFDHB.js.map → chunk-UAODC6GJ.js.map} +0 -0
  162. /package/dist/{chunk-JI6HWBYL.js.map → chunk-UDJLF3BO.js.map} +0 -0
  163. /package/dist/{chunk-YJ4J2JJ2.js.map → chunk-UJDV2NLT.js.map} +0 -0
  164. /package/dist/{chunk-3IE22DJ2.js.map → chunk-WEPMT6SC.js.map} +0 -0
  165. /package/dist/{chunk-DQEMWVMT.js.map → chunk-X7Y7WX73.js.map} +0 -0
  166. /package/dist/{chunk-EZ25VE3G.js.map → chunk-YNDLCWXS.js.map} +0 -0
  167. /package/dist/{first-start-migration-PG5HBC3K.js.map → first-start-migration-FF7YFGRP.js.map} +0 -0
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  StorageManager
3
- } from "./chunk-EUM7CZFM.js";
3
+ } from "./chunk-TY5NT3T3.js";
4
4
 
5
5
  // src/semantic-rule-promotion.ts
6
6
  import { createHash, randomUUID } from "crypto";
@@ -529,4 +529,4 @@ export {
529
529
  setSemanticRulePromotionTestHooks,
530
530
  promoteSemanticRuleFromMemory
531
531
  };
532
- //# sourceMappingURL=chunk-3OKWZT7F.js.map
532
+ //# sourceMappingURL=chunk-3IND7N4X.js.map
@@ -632,7 +632,6 @@ function clusterByKey(items, keyFn) {
632
632
  }
633
633
 
634
634
  export {
635
- clusterByKey,
636
635
  stableHash,
637
636
  normalizeOriginUrl,
638
637
  resolveGitContext,
@@ -644,7 +643,8 @@ export {
644
643
  describeCodingScope,
645
644
  lcmSessionKeyForNamespace,
646
645
  lcmReadSessionIdsForNamespaces,
646
+ clusterByKey,
647
647
  resolveScopeProfilePlan,
648
648
  expandScopeProfileReadNamespaces
649
649
  };
650
- //# sourceMappingURL=chunk-GYSYLGNE.js.map
650
+ //# sourceMappingURL=chunk-7MOTEVAA.js.map
@@ -1,10 +1,10 @@
1
- import {
2
- sidecarKey
3
- } from "./chunk-VF4XKTX3.js";
4
1
  import {
5
2
  DERIVED_FROM_MEMORY_ID_RE,
6
3
  isConsolidationOperator
7
4
  } from "./chunk-G7D6GZ5J.js";
5
+ import {
6
+ sidecarKey
7
+ } from "./chunk-VF4XKTX3.js";
8
8
  import {
9
9
  RECALL_FALLBACK_DIRS
10
10
  } from "./chunk-VS2IYZRU.js";
@@ -342,4 +342,4 @@ function isPathWithin(candidate, root) {
342
342
  export {
343
343
  runConsolidationProvenanceCheck
344
344
  };
345
- //# sourceMappingURL=chunk-6T4LTI2F.js.map
345
+ //# sourceMappingURL=chunk-7XH7VJN4.js.map
@@ -1,10 +1,10 @@
1
- import {
2
- SQLITE_SCHEMA_VERSION
3
- } from "./chunk-Z734BLO3.js";
4
1
  import {
5
2
  parseConflictPolicy,
6
3
  validateManifestRecords
7
4
  } from "./chunk-G4IAEX6D.js";
5
+ import {
6
+ SQLITE_SCHEMA_VERSION
7
+ } from "./chunk-Z734BLO3.js";
8
8
  import {
9
9
  openBetterSqlite3
10
10
  } from "./chunk-6KYMPV2O.js";
@@ -84,4 +84,4 @@ async function importSqlite(opts) {
84
84
  export {
85
85
  importSqlite
86
86
  };
87
- //# sourceMappingURL=chunk-AGNBY3VG.js.map
87
+ //# sourceMappingURL=chunk-APJQ6UEA.js.map
@@ -4,13 +4,13 @@ import {
4
4
  } from "./chunk-ZFXCQPNO.js";
5
5
  import {
6
6
  StorageManager
7
- } from "./chunk-EUM7CZFM.js";
8
- import {
9
- isSafeRouteNamespace
10
- } from "./chunk-U3PN77QT.js";
7
+ } from "./chunk-TY5NT3T3.js";
11
8
  import {
12
9
  ALL_CATEGORY_DIRS
13
10
  } from "./chunk-VS2IYZRU.js";
11
+ import {
12
+ isSafeRouteNamespace
13
+ } from "./chunk-U3PN77QT.js";
14
14
 
15
15
  // src/namespaces/storage.ts
16
16
  import path from "path";
@@ -236,4 +236,4 @@ export {
236
236
  resolveNamespaceStorageRoot,
237
237
  NamespaceStorageRouter
238
238
  };
239
- //# sourceMappingURL=chunk-LZSMQHXC.js.map
239
+ //# sourceMappingURL=chunk-ARLRTZZZ.js.map
@@ -7,7 +7,7 @@ import {
7
7
  import {
8
8
  decryptCapsuleFileInMemory,
9
9
  isEncryptedCapsuleFile
10
- } from "./chunk-DQEMWVMT.js";
10
+ } from "./chunk-X7Y7WX73.js";
11
11
  import {
12
12
  assertIsDirectoryNotSymlink,
13
13
  assertRealpathInsideRoot,
@@ -227,4 +227,4 @@ function mintForkId(capsuleId, originalId, now) {
227
227
  export {
228
228
  importCapsule
229
229
  };
230
- //# sourceMappingURL=chunk-DL6H3D7S.js.map
230
+ //# sourceMappingURL=chunk-ARV3AUOM.js.map
@@ -4,7 +4,7 @@ import {
4
4
  } from "./chunk-DRD2Q7HQ.js";
5
5
  import {
6
6
  StorageManager
7
- } from "./chunk-EUM7CZFM.js";
7
+ } from "./chunk-TY5NT3T3.js";
8
8
  import {
9
9
  parseContinuityImprovementLoops
10
10
  } from "./chunk-LDXUBPMO.js";
@@ -1261,4 +1261,4 @@ export {
1261
1261
  defaultTierMigrationCycleBudget,
1262
1262
  CompoundingEngine
1263
1263
  };
1264
- //# sourceMappingURL=chunk-Q2H5U37U.js.map
1264
+ //# sourceMappingURL=chunk-B2B2IHUH.js.map
@@ -3,13 +3,13 @@ import {
3
3
  } from "./chunk-HQ6NIBL6.js";
4
4
  import {
5
5
  resolveCausalTrajectoryStoreDir
6
- } from "./chunk-RC3AFF6Z.js";
7
- import {
8
- normalizeRecallTokens
9
- } from "./chunk-ZBJMUXZH.js";
6
+ } from "./chunk-JD4SCARD.js";
10
7
  import {
11
8
  log
12
9
  } from "./chunk-2ODBA7MQ.js";
10
+ import {
11
+ normalizeRecallTokens
12
+ } from "./chunk-ZBJMUXZH.js";
13
13
  import {
14
14
  assertIsoRecordedAt,
15
15
  assertString,
@@ -339,4 +339,4 @@ export {
339
339
  scoreStitchCandidate,
340
340
  stitchCausalChain
341
341
  };
342
- //# sourceMappingURL=chunk-SECQS4G4.js.map
342
+ //# sourceMappingURL=chunk-BTVX7ZXZ.js.map
@@ -1,10 +1,10 @@
1
+ import {
2
+ scanMemoryDir
3
+ } from "./chunk-AER6MT24.js";
1
4
  import {
2
5
  isSearchAborted,
3
6
  throwIfSearchAborted
4
7
  } from "./chunk-CINZGPSJ.js";
5
- import {
6
- scanMemoryDir
7
- } from "./chunk-AER6MT24.js";
8
8
  import {
9
9
  resolveEnsureCollectionArgs
10
10
  } from "./chunk-YNQ6DFSV.js";
@@ -245,4 +245,4 @@ function isMeilisearchIndexNotFoundError(err) {
245
245
  export {
246
246
  MeilisearchBackend
247
247
  };
248
- //# sourceMappingURL=chunk-DGEZKYVI.js.map
248
+ //# sourceMappingURL=chunk-DOCTITOP.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  createSearchBackend
3
- } from "./chunk-YJ4J2JJ2.js";
3
+ } from "./chunk-UJDV2NLT.js";
4
4
  import {
5
5
  namespaceIdentityToken,
6
6
  normalizeNamespaceIdentity
@@ -401,4 +401,4 @@ export {
401
401
  namespaceCollectionName,
402
402
  NamespaceSearchRouter
403
403
  };
404
- //# sourceMappingURL=chunk-EQYP3HA6.js.map
404
+ //# sourceMappingURL=chunk-EG4TCVMU.js.map
@@ -19,14 +19,14 @@ import {
19
19
  import {
20
20
  LocalLlmClient
21
21
  } from "./chunk-H3HDXD3U.js";
22
+ import {
23
+ delinearize
24
+ } from "./chunk-VEWZZM3H.js";
22
25
  import {
23
26
  buildExtensionsFooterForSummary,
24
27
  formatDaySummaryMemories,
25
28
  loadDaySummaryPrompt
26
29
  } from "./chunk-WLEB7WCG.js";
27
- import {
28
- delinearize
29
- } from "./chunk-VEWZZM3H.js";
30
30
  import {
31
31
  FallbackLlmClient,
32
32
  fallbackLlmRuntimeContextFromConfig,
@@ -2328,4 +2328,4 @@ ${memoryList}` }
2328
2328
  export {
2329
2329
  ExtractionEngine
2330
2330
  };
2331
- //# sourceMappingURL=chunk-SLTKP5WJ.js.map
2331
+ //# sourceMappingURL=chunk-EW5KFXHL.js.map
@@ -9,15 +9,21 @@ import {
9
9
  import {
10
10
  buildCitationGuidance
11
11
  } from "./chunk-D24OXEPB.js";
12
+ import {
13
+ validateRequest
14
+ } from "./chunk-UDJLF3BO.js";
15
+ import {
16
+ getOperation
17
+ } from "./chunk-NHFXF4ZO.js";
12
18
  import {
13
19
  EngramAccessInputError
14
- } from "./chunk-OBM7EVFU.js";
20
+ } from "./chunk-H4BDNIKQ.js";
15
21
  import {
16
22
  projectTagProjectId
17
- } from "./chunk-GYSYLGNE.js";
23
+ } from "./chunk-7MOTEVAA.js";
18
24
  import {
19
25
  validateBriefingFormat
20
- } from "./chunk-ATRB6Q25.js";
26
+ } from "./chunk-KV6CX4ON.js";
21
27
  import {
22
28
  resolvePrincipal
23
29
  } from "./chunk-UZYLX7M6.js";
@@ -27,9 +33,6 @@ import {
27
33
  import {
28
34
  readEnvVar
29
35
  } from "./chunk-JUC24CTX.js";
30
- import {
31
- validateRequest
32
- } from "./chunk-JI6HWBYL.js";
33
36
 
34
37
  // src/access-mcp.ts
35
38
  import { readFile } from "fs/promises";
@@ -49,6 +52,11 @@ function withToolAliases(tool, emitLegacyTools = true) {
49
52
  if (canonicalName === tool.name) return [canonicalTool];
50
53
  return emitLegacyTools ? [canonicalTool, tool] : [canonicalTool];
51
54
  }
55
+ var MCP_MIGRATED_OPERATIONS = {
56
+ "engram.memory_get": "memory_get",
57
+ "engram.memory_search": "memory_search",
58
+ "engram.memory_store": "memory_store"
59
+ };
52
60
  function resolveChatGptInspectorRecallSessionKey(explicitSessionKey, authenticatedPrincipal) {
53
61
  if (explicitSessionKey) return explicitSessionKey;
54
62
  if (!authenticatedPrincipal) return void 0;
@@ -2095,6 +2103,19 @@ ${body}`;
2095
2103
  }));
2096
2104
  }
2097
2105
  async callTool(name, args, effectivePrincipal, mcpSessionId) {
2106
+ const migrated = MCP_MIGRATED_OPERATIONS[toLegacyToolName(name)];
2107
+ if (migrated) {
2108
+ const op = getOperation(migrated);
2109
+ if (!op) {
2110
+ throw new EngramAccessInputError(`access-boundary: operation not registered: ${migrated}`);
2111
+ }
2112
+ const envelope = migrated === "memory_store" ? parseMcpRequest("memoryStore", args) : args;
2113
+ const output = await op.run(envelope, {
2114
+ service: this.service,
2115
+ authenticatedPrincipal: effectivePrincipal
2116
+ });
2117
+ return output.result;
2118
+ }
2098
2119
  switch (toLegacyToolName(name)) {
2099
2120
  case "engram.recall": {
2100
2121
  let disclosure;
@@ -2454,12 +2475,6 @@ ${body}`;
2454
2475
  },
2455
2476
  effectivePrincipal
2456
2477
  );
2457
- case "engram.memory_get":
2458
- return this.service.memoryGet(
2459
- typeof args.memoryId === "string" ? args.memoryId : "",
2460
- typeof args.namespace === "string" ? args.namespace : void 0,
2461
- effectivePrincipal
2462
- );
2463
2478
  case "engram.memory_timeline": {
2464
2479
  const limit = typeof args.limit === "number" && Number.isFinite(args.limit) ? args.limit : 200;
2465
2480
  return this.service.memoryTimeline(
@@ -2469,26 +2484,6 @@ ${body}`;
2469
2484
  effectivePrincipal
2470
2485
  );
2471
2486
  }
2472
- case "engram.memory_store": {
2473
- const body = parseMcpRequest("memoryStore", args);
2474
- return this.service.memoryStore({
2475
- schemaVersion: body.schemaVersion,
2476
- idempotencyKey: body.idempotencyKey,
2477
- dryRun: body.dryRun,
2478
- sessionKey: body.sessionKey,
2479
- authenticatedPrincipal: effectivePrincipal,
2480
- content: body.content,
2481
- category: body.category,
2482
- confidence: body.confidence,
2483
- namespace: body.namespace,
2484
- tags: body.tags,
2485
- entityRef: body.entityRef,
2486
- ttl: body.ttl,
2487
- sourceReason: body.sourceReason,
2488
- cwd: body.cwd,
2489
- projectTag: body.projectTag
2490
- });
2491
- }
2492
2487
  case "engram.suggestion_submit": {
2493
2488
  const body = parseMcpRequest("suggestionSubmit", args);
2494
2489
  return this.service.suggestionSubmit({
@@ -2727,14 +2722,6 @@ ${body}`;
2727
2722
  expectedGuidelineVersion: typeof args.expectedGuidelineVersion === "number" ? args.expectedGuidelineVersion : void 0
2728
2723
  });
2729
2724
  // ── Memory search & debug tools ──────────────────────────────────
2730
- case "engram.memory_search":
2731
- return this.service.memorySearch({
2732
- query: typeof args.query === "string" ? args.query : "",
2733
- namespace: typeof args.namespace === "string" ? args.namespace : void 0,
2734
- maxResults: typeof args.maxResults === "number" && Number.isFinite(args.maxResults) ? args.maxResults : void 0,
2735
- collection: typeof args.collection === "string" ? args.collection : void 0,
2736
- principal: effectivePrincipal
2737
- });
2738
2725
  case "engram.memory_profile":
2739
2726
  return this.service.memoryProfile(
2740
2727
  typeof args.namespace === "string" ? args.namespace : void 0,
@@ -3117,4 +3104,4 @@ ${body}`;
3117
3104
  export {
3118
3105
  EngramMcpServer
3119
3106
  };
3120
- //# sourceMappingURL=chunk-5TEYIXMP.js.map
3107
+ //# sourceMappingURL=chunk-FDSOMA6M.js.map