@remnic/core 9.21.0 → 9.22.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.
Files changed (158) hide show
  1. package/dist/access-admin-ops-surface.d.ts +18 -1
  2. package/dist/access-admin-ops-surface.js +29 -29
  3. package/dist/access-boundary.d.ts +2 -2
  4. package/dist/access-boundary.js +29 -29
  5. package/dist/access-cli.js +80 -79
  6. package/dist/access-cli.js.map +1 -1
  7. package/dist/access-http.d.ts +1 -1
  8. package/dist/access-http.js +38 -37
  9. package/dist/access-identity-continuity-surface.js +29 -29
  10. package/dist/access-lcm-surface.d.ts +1 -1
  11. package/dist/access-lcm-surface.js +29 -29
  12. package/dist/access-mcp-admin-tools.d.ts +18 -0
  13. package/dist/access-mcp-admin-tools.js +10 -0
  14. package/dist/access-mcp-admin-tools.js.map +1 -0
  15. package/dist/access-mcp-output-schemas.js +1 -1
  16. package/dist/access-mcp.d.ts +1 -1
  17. package/dist/access-mcp.js +35 -34
  18. package/dist/access-namespace-preflight.js +29 -29
  19. package/dist/access-observe-write-surface.d.ts +1 -1
  20. package/dist/access-observe-write-surface.js +29 -29
  21. package/dist/access-operations-batch.js +30 -30
  22. package/dist/access-operations.d.ts +5 -5
  23. package/dist/access-operations.js +32 -32
  24. package/dist/access-recall-concurrency.d.ts +1 -1
  25. package/dist/access-recall-concurrency.js +29 -29
  26. package/dist/access-recall-response.d.ts +1 -1
  27. package/dist/access-recall-response.js +29 -29
  28. package/dist/access-recall-surface.d.ts +1 -1
  29. package/dist/access-recall-surface.js +29 -29
  30. package/dist/access-schema.d.ts +76 -76
  31. package/dist/{access-service-BqUii7LY.d.ts → access-service-BtxW52vv.d.ts} +10 -0
  32. package/dist/access-service.d.ts +1 -1
  33. package/dist/access-service.js +31 -31
  34. package/dist/access-surface-catalog.d.ts +1 -1
  35. package/dist/access-surface-catalog.js +1 -0
  36. package/dist/access-surface-catalog.js.map +1 -1
  37. package/dist/active-recall.js +5 -5
  38. package/dist/adapters/index.js +4 -4
  39. package/dist/adapters/registry.js +2 -2
  40. package/dist/auto-sync-UPTUVE4X.js +1 -1
  41. package/dist/briefing.js +8 -8
  42. package/dist/causal-consolidation.js +9 -9
  43. package/dist/{chunk-JWMYVQAM.js → chunk-55FDQYPS.js} +2 -2
  44. package/dist/chunk-56BSXSHC.js +158 -0
  45. package/dist/chunk-56BSXSHC.js.map +1 -0
  46. package/dist/{chunk-62QM5MKY.js → chunk-6ANPNUVL.js} +68 -34
  47. package/dist/chunk-6ANPNUVL.js.map +1 -0
  48. package/dist/{chunk-EZKKHVFY.js → chunk-6L775BUB.js} +2 -2
  49. package/dist/{chunk-LI4ZOFHW.js → chunk-6RYWNBSA.js} +2 -2
  50. package/dist/{chunk-5IXPWEQB.js → chunk-7S5OMI76.js} +9 -9
  51. package/dist/{chunk-5IXPWEQB.js.map → chunk-7S5OMI76.js.map} +1 -1
  52. package/dist/{chunk-SB4OKS6C.js → chunk-A5N6ISRK.js} +2 -2
  53. package/dist/{chunk-V5TSUGRB.js → chunk-ACGGTPU4.js} +5 -5
  54. package/dist/{chunk-B7C3TF5H.js → chunk-BRT7KEXU.js} +2 -2
  55. package/dist/{chunk-JN3IUA2Q.js → chunk-CV6ZYXK3.js} +3 -3
  56. package/dist/{chunk-N7EVMKP6.js → chunk-DGLON3AL.js} +10 -10
  57. package/dist/{chunk-5RUE3GHQ.js → chunk-DM5A4ZFL.js} +7 -1
  58. package/dist/chunk-DM5A4ZFL.js.map +1 -0
  59. package/dist/{chunk-KHRKEELC.js → chunk-EQYBHXRR.js} +34 -34
  60. package/dist/{chunk-Z54EM5YZ.js → chunk-GF22HWS2.js} +4 -4
  61. package/dist/{chunk-QO2KODU6.js → chunk-GSWPU5CR.js} +2 -2
  62. package/dist/{chunk-RKNJBZ55.js → chunk-JBPKEARU.js} +4 -4
  63. package/dist/{chunk-5JQLAQUZ.js → chunk-JN57HZCD.js} +2 -2
  64. package/dist/{chunk-X5QS5C2O.js → chunk-KL5Y6PEV.js} +2 -2
  65. package/dist/{chunk-275ENJDK.js → chunk-KQ2XCQYN.js} +2 -2
  66. package/dist/{chunk-HJEEAO4O.js → chunk-N47ZWQBO.js} +2 -2
  67. package/dist/{chunk-AT3TDN6O.js → chunk-N6M7MRVN.js} +83 -83
  68. package/dist/{chunk-EXU5IQ3S.js → chunk-NB2P47N7.js} +2 -2
  69. package/dist/{chunk-53WDAG7X.js → chunk-OCMLGND7.js} +2 -2
  70. package/dist/{chunk-3ZUY2VQF.js → chunk-P72WZMWQ.js} +2 -2
  71. package/dist/{chunk-LRGSLV7M.js → chunk-PYHOAXTI.js} +4 -4
  72. package/dist/{chunk-4F6AANKS.js → chunk-QMGIQUBG.js} +5 -5
  73. package/dist/{chunk-TCZWBJBO.js → chunk-QTO2FGBT.js} +11 -142
  74. package/dist/chunk-QTO2FGBT.js.map +1 -0
  75. package/dist/{chunk-Q3FWRDCP.js → chunk-SACPRJ7F.js} +2 -2
  76. package/dist/{chunk-HPOY2PHQ.js → chunk-TTKWTT72.js} +6 -6
  77. package/dist/{chunk-EILX7SQR.js → chunk-W3XT32W7.js} +7 -6
  78. package/dist/chunk-W3XT32W7.js.map +1 -0
  79. package/dist/{chunk-MJYYXODM.js → chunk-XBRPEGXF.js} +4 -4
  80. package/dist/{cli-DPEhq0Cp.d.ts → cli-D9vXgWwM.d.ts} +1 -1
  81. package/dist/cli.d.ts +2 -2
  82. package/dist/cli.js +59 -58
  83. package/dist/compounding/engine.js +8 -8
  84. package/dist/config.js +2 -2
  85. package/dist/connectors/codex-materialize-runner.js +8 -8
  86. package/dist/connectors/index.js +9 -9
  87. package/dist/contradiction/index.js +1 -1
  88. package/dist/entity-retrieval.js +8 -8
  89. package/dist/explicit-capture.js +1 -1
  90. package/dist/index.d.ts +407 -407
  91. package/dist/index.js +133 -132
  92. package/dist/lcm/engine.js +2 -2
  93. package/dist/lcm/index.js +4 -4
  94. package/dist/maintenance/memory-governance.js +8 -8
  95. package/dist/maintenance/rebuild-memory-lifecycle-ledger.js +8 -8
  96. package/dist/maintenance/rebuild-memory-projection.js +9 -9
  97. package/dist/mcp-memory-inspector-app.d.ts +1 -1
  98. package/dist/namespaces/migrate.js +12 -12
  99. package/dist/namespaces/search.js +3 -3
  100. package/dist/namespaces/storage.js +8 -8
  101. package/dist/offline-sync-impression-drain.js +1 -1
  102. package/dist/operator-toolkit.js +19 -19
  103. package/dist/orchestration/maintenance.js +14 -14
  104. package/dist/orchestrator.js +76 -75
  105. package/dist/resolution-3K27T4VO.js +1 -1
  106. package/dist/resume-bundles.js +3 -3
  107. package/dist/salvage-envelope.js +1 -1
  108. package/dist/schemas.d.ts +76 -76
  109. package/dist/search/factory.js +2 -2
  110. package/dist/search/index.js +4 -4
  111. package/dist/semantic-consolidation.js +9 -9
  112. package/dist/semantic-rule-promotion.js +8 -8
  113. package/dist/semantic-rule-verifier.js +8 -8
  114. package/dist/shared-context/manager.d.ts +8 -8
  115. package/dist/storage.js +7 -7
  116. package/dist/transfer/import-sqlite.js +2 -2
  117. package/dist/transfer/types.d.ts +66 -66
  118. package/dist/verified-recall.js +8 -8
  119. package/dist/write-envelope.js +1 -1
  120. package/package.json +2 -2
  121. package/src/access-admin-ops-surface.ts +47 -0
  122. package/src/access-boundary.ts +1 -0
  123. package/src/access-http.ts +1 -0
  124. package/src/access-mcp-admin-tools.ts +171 -0
  125. package/src/access-mcp-output-schemas.ts +6 -0
  126. package/src/access-mcp.ts +6 -141
  127. package/src/access-operations-batch.ts +1 -0
  128. package/src/access-service.ts +16 -0
  129. package/src/access-surface-catalog.ts +1 -0
  130. package/dist/chunk-5RUE3GHQ.js.map +0 -1
  131. package/dist/chunk-62QM5MKY.js.map +0 -1
  132. package/dist/chunk-EILX7SQR.js.map +0 -1
  133. package/dist/chunk-TCZWBJBO.js.map +0 -1
  134. /package/dist/{chunk-JWMYVQAM.js.map → chunk-55FDQYPS.js.map} +0 -0
  135. /package/dist/{chunk-EZKKHVFY.js.map → chunk-6L775BUB.js.map} +0 -0
  136. /package/dist/{chunk-LI4ZOFHW.js.map → chunk-6RYWNBSA.js.map} +0 -0
  137. /package/dist/{chunk-SB4OKS6C.js.map → chunk-A5N6ISRK.js.map} +0 -0
  138. /package/dist/{chunk-V5TSUGRB.js.map → chunk-ACGGTPU4.js.map} +0 -0
  139. /package/dist/{chunk-B7C3TF5H.js.map → chunk-BRT7KEXU.js.map} +0 -0
  140. /package/dist/{chunk-JN3IUA2Q.js.map → chunk-CV6ZYXK3.js.map} +0 -0
  141. /package/dist/{chunk-N7EVMKP6.js.map → chunk-DGLON3AL.js.map} +0 -0
  142. /package/dist/{chunk-KHRKEELC.js.map → chunk-EQYBHXRR.js.map} +0 -0
  143. /package/dist/{chunk-Z54EM5YZ.js.map → chunk-GF22HWS2.js.map} +0 -0
  144. /package/dist/{chunk-QO2KODU6.js.map → chunk-GSWPU5CR.js.map} +0 -0
  145. /package/dist/{chunk-RKNJBZ55.js.map → chunk-JBPKEARU.js.map} +0 -0
  146. /package/dist/{chunk-5JQLAQUZ.js.map → chunk-JN57HZCD.js.map} +0 -0
  147. /package/dist/{chunk-X5QS5C2O.js.map → chunk-KL5Y6PEV.js.map} +0 -0
  148. /package/dist/{chunk-275ENJDK.js.map → chunk-KQ2XCQYN.js.map} +0 -0
  149. /package/dist/{chunk-HJEEAO4O.js.map → chunk-N47ZWQBO.js.map} +0 -0
  150. /package/dist/{chunk-AT3TDN6O.js.map → chunk-N6M7MRVN.js.map} +0 -0
  151. /package/dist/{chunk-EXU5IQ3S.js.map → chunk-NB2P47N7.js.map} +0 -0
  152. /package/dist/{chunk-53WDAG7X.js.map → chunk-OCMLGND7.js.map} +0 -0
  153. /package/dist/{chunk-3ZUY2VQF.js.map → chunk-P72WZMWQ.js.map} +0 -0
  154. /package/dist/{chunk-LRGSLV7M.js.map → chunk-PYHOAXTI.js.map} +0 -0
  155. /package/dist/{chunk-4F6AANKS.js.map → chunk-QMGIQUBG.js.map} +0 -0
  156. /package/dist/{chunk-Q3FWRDCP.js.map → chunk-SACPRJ7F.js.map} +0 -0
  157. /package/dist/{chunk-HPOY2PHQ.js.map → chunk-TTKWTT72.js.map} +0 -0
  158. /package/dist/{chunk-MJYYXODM.js.map → chunk-XBRPEGXF.js.map} +0 -0
@@ -0,0 +1,158 @@
1
+ // src/access-mcp-admin-tools.ts
2
+ var MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED = {
3
+ cwd: {
4
+ type: "string",
5
+ description: "Accepted for MCP client compatibility (git-context auto-injection); ignored by this tool."
6
+ },
7
+ projectTag: {
8
+ type: "string",
9
+ description: "Accepted for MCP client compatibility; ignored by this tool."
10
+ }
11
+ };
12
+ var MCP_ADMIN_OPS_TOOLS = [
13
+ {
14
+ name: "engram.capsule_export",
15
+ description: "Export a portable Remnic capsule archive from the namespace-scoped memory store.",
16
+ inputSchema: {
17
+ type: "object",
18
+ properties: {
19
+ name: {
20
+ type: "string",
21
+ description: "Capsule id (alphanumeric with single dashes, max 64 characters)."
22
+ },
23
+ namespace: { type: "string" },
24
+ since: {
25
+ type: "string",
26
+ description: "Only include files modified on or after this ISO 8601 timestamp."
27
+ },
28
+ includeKinds: {
29
+ type: "array",
30
+ items: { type: "string" },
31
+ description: "Optional top-level directory allow-list."
32
+ },
33
+ peerIds: {
34
+ type: "array",
35
+ items: { type: "string" },
36
+ description: "Optional peer id allow-list for the peers/ subtree."
37
+ },
38
+ includeTranscripts: { type: "boolean" },
39
+ encrypt: { type: "boolean" },
40
+ ...MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED
41
+ },
42
+ required: ["name"],
43
+ additionalProperties: false
44
+ }
45
+ },
46
+ {
47
+ name: "engram.capsule_import",
48
+ description: "Import a Remnic capsule archive into the namespace-scoped memory store.",
49
+ inputSchema: {
50
+ type: "object",
51
+ properties: {
52
+ archivePath: {
53
+ type: "string",
54
+ description: "Path to a .capsule.json.gz or .capsule.json.gz.enc archive."
55
+ },
56
+ namespace: { type: "string" },
57
+ mode: {
58
+ type: "string",
59
+ enum: ["skip", "overwrite", "fork"],
60
+ description: "Conflict handling mode. Defaults to skip."
61
+ },
62
+ passphrase: {
63
+ type: "string",
64
+ description: "Passphrase for encrypted capsule archives."
65
+ },
66
+ ...MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED
67
+ },
68
+ required: ["archivePath"],
69
+ additionalProperties: false
70
+ }
71
+ },
72
+ {
73
+ name: "engram.capsule_list",
74
+ description: "List capsule archives in the namespace-scoped capsule store.",
75
+ inputSchema: {
76
+ type: "object",
77
+ properties: {
78
+ namespace: { type: "string" },
79
+ sessionKey: {
80
+ type: "string",
81
+ description: "Optional session key used to derive namespace principal when no trusted transport principal is present."
82
+ },
83
+ ...MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED
84
+ },
85
+ additionalProperties: false
86
+ }
87
+ },
88
+ {
89
+ name: "engram.memory_governance_run",
90
+ description: "Run Remnic memory governance in a bounded shadow/apply pass.",
91
+ inputSchema: {
92
+ type: "object",
93
+ properties: {
94
+ namespace: { type: "string" },
95
+ mode: { type: "string", enum: ["shadow", "apply"] },
96
+ recentDays: { type: "number" },
97
+ maxMemories: { type: "number" },
98
+ batchSize: { type: "number" }
99
+ },
100
+ additionalProperties: false
101
+ }
102
+ },
103
+ {
104
+ name: "engram.entity_synthesis_run",
105
+ description: "Bulk-drain the entity synthesis queue (issue #2136). Processes up to maxEntities (default 25, max 200) queued entity names into canonical syntheses; loop until processed < requested to drain fully.",
106
+ inputSchema: {
107
+ type: "object",
108
+ properties: {
109
+ namespace: { type: "string" },
110
+ maxEntities: { type: "number" }
111
+ },
112
+ additionalProperties: false
113
+ }
114
+ },
115
+ {
116
+ name: "engram.procedure_mining_run",
117
+ description: "Run procedural memory mining from causal trajectories (issue #519). Respects procedural.enabled; writes under procedures/ when clusters qualify.",
118
+ inputSchema: {
119
+ type: "object",
120
+ properties: {
121
+ namespace: { type: "string" }
122
+ },
123
+ additionalProperties: false
124
+ }
125
+ },
126
+ {
127
+ name: "engram.pattern_reinforcement_run",
128
+ description: "Run the pattern-reinforcement maintenance job (issue #687 PR 2/4). Clusters duplicate non-procedural memories by normalized content, promotes the most-recent member to canonical, and supersedes the older duplicates. Gated on patternReinforcementEnabled and the patternReinforcementCadenceMs floor \u2014 pass force=true to bypass the cadence for an ad-hoc operator run.",
129
+ inputSchema: {
130
+ type: "object",
131
+ properties: {
132
+ namespace: { type: "string" },
133
+ force: { type: "boolean" }
134
+ },
135
+ additionalProperties: false
136
+ }
137
+ },
138
+ {
139
+ // The canonical `remnic.procedural_stats` alias is added automatically
140
+ // by `withToolAliases` — the dual-naming invariant keeps both names
141
+ // alive for the legacy surface.
142
+ name: "engram.procedural_stats",
143
+ description: "Procedural memory stats (issue #567): counts by status, recent write activity, and the active procedural.* config. Read-only, namespace-scoped.",
144
+ inputSchema: {
145
+ type: "object",
146
+ properties: {
147
+ namespace: { type: "string" }
148
+ },
149
+ additionalProperties: false
150
+ }
151
+ }
152
+ ];
153
+
154
+ export {
155
+ MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED,
156
+ MCP_ADMIN_OPS_TOOLS
157
+ };
158
+ //# sourceMappingURL=chunk-56BSXSHC.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../src/access-mcp-admin-tools.ts"],"sourcesContent":["/**\n * MCP tool-listing entries for the admin/maintenance operation surface\n * (capsules, governance, entity synthesis, procedure mining, pattern\n * reinforcement, procedural stats). Extracted from access-mcp.ts (#2136)\n * to keep the transport file under its structural-ratchet ceiling; the\n * dispatch name map and operation handlers stay in their existing homes.\n */\n/** Git-context schema props accepted-and-ignored by every tool (issue #569\n * compatibility surface) — defined here so the tool tables and the transport\n * share one copy without an import cycle. */\nexport const MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED: Record<string, unknown> = {\n cwd: {\n type: \"string\",\n description: \"Accepted for MCP client compatibility (git-context auto-injection); ignored by this tool.\",\n },\n projectTag: {\n type: \"string\",\n description: \"Accepted for MCP client compatibility; ignored by this tool.\",\n },\n};\n\nexport const MCP_ADMIN_OPS_TOOLS: Array<{\n name: string;\n description: string;\n inputSchema: Record<string, unknown>;\n}> = [\n{\n name: \"engram.capsule_export\",\n description: \"Export a portable Remnic capsule archive from the namespace-scoped memory store.\",\n inputSchema: {\n type: \"object\",\n properties: {\n name: {\n type: \"string\",\n description: \"Capsule id (alphanumeric with single dashes, max 64 characters).\",\n },\n namespace: { type: \"string\" },\n since: {\n type: \"string\",\n description: \"Only include files modified on or after this ISO 8601 timestamp.\",\n },\n includeKinds: {\n type: \"array\",\n items: { type: \"string\" },\n description: \"Optional top-level directory allow-list.\",\n },\n peerIds: {\n type: \"array\",\n items: { type: \"string\" },\n description: \"Optional peer id allow-list for the peers/ subtree.\",\n },\n includeTranscripts: { type: \"boolean\" },\n encrypt: { type: \"boolean\" },\n ...MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED,\n },\n required: [\"name\"],\n additionalProperties: false,\n },\n},\n{\n name: \"engram.capsule_import\",\n description: \"Import a Remnic capsule archive into the namespace-scoped memory store.\",\n inputSchema: {\n type: \"object\",\n properties: {\n archivePath: {\n type: \"string\",\n description: \"Path to a .capsule.json.gz or .capsule.json.gz.enc archive.\",\n },\n namespace: { type: \"string\" },\n mode: {\n type: \"string\",\n enum: [\"skip\", \"overwrite\", \"fork\"],\n description: \"Conflict handling mode. Defaults to skip.\",\n },\n passphrase: {\n type: \"string\",\n description: \"Passphrase for encrypted capsule archives.\",\n },\n ...MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED,\n },\n required: [\"archivePath\"],\n additionalProperties: false,\n },\n},\n{\n name: \"engram.capsule_list\",\n description: \"List capsule archives in the namespace-scoped capsule store.\",\n inputSchema: {\n type: \"object\",\n properties: {\n namespace: { type: \"string\" },\n sessionKey: {\n type: \"string\",\n description:\n \"Optional session key used to derive namespace principal when no trusted transport principal is present.\",\n },\n ...MCP_GIT_CONTEXT_SCHEMA_PROPS_IGNORED,\n },\n additionalProperties: false,\n },\n},\n{\n name: \"engram.memory_governance_run\",\n description: \"Run Remnic memory governance in a bounded shadow/apply pass.\",\n inputSchema: {\n type: \"object\",\n properties: {\n namespace: { type: \"string\" },\n mode: { type: \"string\", enum: [\"shadow\", \"apply\"] },\n recentDays: { type: \"number\" },\n maxMemories: { type: \"number\" },\n batchSize: { type: \"number\" },\n },\n additionalProperties: false,\n },\n},\n{\n name: \"engram.entity_synthesis_run\",\n description:\n \"Bulk-drain the entity synthesis queue (issue #2136). Processes up to maxEntities (default 25, max 200) queued entity names into canonical syntheses; loop until processed < requested to drain fully.\",\n inputSchema: {\n type: \"object\",\n properties: {\n namespace: { type: \"string\" },\n maxEntities: { type: \"number\" },\n },\n additionalProperties: false,\n },\n},\n{\n name: \"engram.procedure_mining_run\",\n description:\n \"Run procedural memory mining from causal trajectories (issue #519). Respects procedural.enabled; writes under procedures/ when clusters qualify.\",\n inputSchema: {\n type: \"object\",\n properties: {\n namespace: { type: \"string\" },\n },\n additionalProperties: false,\n },\n},\n{\n name: \"engram.pattern_reinforcement_run\",\n description:\n \"Run the pattern-reinforcement maintenance job (issue #687 PR 2/4). Clusters duplicate non-procedural memories by normalized content, promotes the most-recent member to canonical, and supersedes the older duplicates. Gated on patternReinforcementEnabled and the patternReinforcementCadenceMs floor — pass force=true to bypass the cadence for an ad-hoc operator run.\",\n inputSchema: {\n type: \"object\",\n properties: {\n namespace: { type: \"string\" },\n force: { type: \"boolean\" },\n },\n additionalProperties: false,\n },\n},\n{\n // The canonical `remnic.procedural_stats` alias is added automatically\n // by `withToolAliases` — the dual-naming invariant keeps both names\n // alive for the legacy surface.\n name: \"engram.procedural_stats\",\n description:\n \"Procedural memory stats (issue #567): counts by status, recent write activity, and the active procedural.* config. Read-only, namespace-scoped.\",\n inputSchema: {\n type: \"object\",\n properties: {\n namespace: { type: \"string\" },\n },\n additionalProperties: false,\n },\n},\n];\n"],"mappings":";AAUO,IAAM,uCAAgE;AAAA,EAC3E,KAAK;AAAA,IACH,MAAM;AAAA,IACN,aAAa;AA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AAAA,IAIE,MAAM;AAAA,IACN,aACE;AAAA,IACF,aAAa;AAAA,MACX,MAAM;AAAA,MACN,YAAY;AAAA,QACV,WAAW,EAAE,MAAM,SAAS;AAAA,MAC9B;AAAA,MACA,sBAAsB;AAAA,IACxB;AAAA,EACF;AACA;","names":[]}
@@ -30,6 +30,9 @@ import {
30
30
  import {
31
31
  planSessionTranscriptMigration
32
32
  } from "./chunk-P5FPO2BR.js";
33
+ import {
34
+ decideDisclosureEscalation
35
+ } from "./chunk-H7XKCNR6.js";
33
36
  import {
34
37
  toRecallExplainJson
35
38
  } from "./chunk-GEUDRENF.js";
@@ -37,11 +40,11 @@ import {
37
40
  estimateRecallTokens
38
41
  } from "./chunk-JFDEYXF7.js";
39
42
  import {
40
- decideDisclosureEscalation
41
- } from "./chunk-H7XKCNR6.js";
43
+ offlineSyncStorageForSnapshot
44
+ } from "./chunk-UGH6VPPO.js";
42
45
  import {
43
46
  namespaceCollectionName
44
- } from "./chunk-SB4OKS6C.js";
47
+ } from "./chunk-A5N6ISRK.js";
45
48
  import {
46
49
  buildProposedActions,
47
50
  buildQualityScore,
@@ -49,16 +52,7 @@ import {
49
52
  listMemoryGovernanceRuns,
50
53
  readMemoryGovernanceRunArtifact,
51
54
  runMemoryGovernance
52
- } from "./chunk-B7C3TF5H.js";
53
- import {
54
- recordObjectiveStateSnapshotsFromObservedMessages
55
- } from "./chunk-ICP53SKG.js";
56
- import {
57
- objectiveStateStoreOverrideForNamespace
58
- } from "./chunk-6HMYUWXR.js";
59
- import {
60
- offlineSyncStorageForSnapshot
61
- } from "./chunk-UGH6VPPO.js";
55
+ } from "./chunk-BRT7KEXU.js";
62
56
  import {
63
57
  combineNamespaces,
64
58
  defaultGitInvoker,
@@ -73,6 +67,12 @@ import {
73
67
  resolveWritableNamespaceValue,
74
68
  sanitizeFragment
75
69
  } from "./chunk-MQVINOJQ.js";
70
+ import {
71
+ recordObjectiveStateSnapshotsFromObservedMessages
72
+ } from "./chunk-ICP53SKG.js";
73
+ import {
74
+ objectiveStateStoreOverrideForNamespace
75
+ } from "./chunk-6HMYUWXR.js";
76
76
  import {
77
77
  recordMemoryOutcome
78
78
  } from "./chunk-EIR5VLIH.js";
@@ -114,13 +114,13 @@ import {
114
114
  enqueuePassiveCorrectionNotification,
115
115
  parseBriefingFocus,
116
116
  parseBriefingWindow
117
- } from "./chunk-Q3FWRDCP.js";
117
+ } from "./chunk-SACPRJ7F.js";
118
118
  import {
119
119
  parseEntityFile,
120
120
  qmdCollectionPathParts,
121
121
  qmdResultPathCandidates,
122
122
  selfDeps
123
- } from "./chunk-4F6AANKS.js";
123
+ } from "./chunk-QMGIQUBG.js";
124
124
  import {
125
125
  supersessionKeysForFact
126
126
  } from "./chunk-DNHVPZOD.js";
@@ -169,6 +169,9 @@ import {
169
169
  import {
170
170
  computeContentHash
171
171
  } from "./chunk-W5H6ZRPT.js";
172
+ import {
173
+ exportCapsule
174
+ } from "./chunk-KQAFEZQX.js";
172
175
  import {
173
176
  assertFleetWideOperationAllowed,
174
177
  assertOperationAllowed,
@@ -177,22 +180,15 @@ import {
177
180
  isNamespaceAllowed,
178
181
  tokenCapabilityStore
179
182
  } from "./chunk-7AMFUATK.js";
183
+ import {
184
+ evaluateActionConfidence
185
+ } from "./chunk-Z2YFLXHU.js";
180
186
  import {
181
187
  sanitizeMemoryContent
182
188
  } from "./chunk-5GKPFL3S.js";
183
189
  import {
184
190
  expandTildePath
185
191
  } from "./chunk-EYIEWJNI.js";
186
- import {
187
- buildHandleIndexForResults,
188
- isHandleToken
189
- } from "./chunk-JAKIDQB2.js";
190
- import {
191
- exportCapsule
192
- } from "./chunk-KQAFEZQX.js";
193
- import {
194
- evaluateActionConfidence
195
- } from "./chunk-Z2YFLXHU.js";
196
192
  import {
197
193
  OFFLINE_SYNC_SNAPSHOT_FORMAT,
198
194
  applyOfflineSyncChangeset,
@@ -205,14 +201,9 @@ import {
205
201
  readOfflineSyncFileContentChunk
206
202
  } from "./chunk-E4OCKU67.js";
207
203
  import {
208
- EngramAccessForbiddenError,
209
- EngramAccessInputError,
210
- NamespaceNotWritableError
211
- } from "./chunk-2Z24E5W2.js";
212
- import {
213
- AccessIdempotencyStore,
214
- hashAccessIdempotencyPayload
215
- } from "./chunk-VFUEZZBS.js";
204
+ buildHandleIndexForResults,
205
+ isHandleToken
206
+ } from "./chunk-JAKIDQB2.js";
216
207
  import {
217
208
  defaultNamespaceAtFlatRoot,
218
209
  mergeMemorySearchDefaultFallback,
@@ -242,6 +233,15 @@ import {
242
233
  resolveRecallEnhancementCapabilities,
243
234
  resolveSecurityCapabilities
244
235
  } from "./chunk-RDQGLJRR.js";
236
+ import {
237
+ EngramAccessForbiddenError,
238
+ EngramAccessInputError,
239
+ NamespaceNotWritableError
240
+ } from "./chunk-2Z24E5W2.js";
241
+ import {
242
+ AccessIdempotencyStore,
243
+ hashAccessIdempotencyPayload
244
+ } from "./chunk-VFUEZZBS.js";
245
245
  import {
246
246
  abortError,
247
247
  throwIfAborted
@@ -4839,6 +4839,7 @@ var OPERATION_NAMES = [
4839
4839
  "capsule_import",
4840
4840
  "capsule_list",
4841
4841
  "memory_governance_run",
4842
+ "entity_synthesis_run",
4842
4843
  "procedure_mining_run",
4843
4844
  "pattern_reinforcement_run",
4844
4845
  "procedural_stats",
@@ -6688,6 +6689,36 @@ var AccessAdminOpsSurface = class {
6688
6689
  reportPath: result.reportPath
6689
6690
  };
6690
6691
  }
6692
+ /**
6693
+ * Operator-triggered bulk drain of the entity synthesis queue (issue #2136).
6694
+ * Every automatic call site processes at most 5 entities per event, which a
6695
+ * busy deployment's queue inflow outruns; this surface drains a bounded
6696
+ * batch on demand. `maxEntities` is clamped to 200 per call so a single
6697
+ * request stays bounded; loop until `processed < requested` to drain fully.
6698
+ */
6699
+ async entitySynthesisRun(request, principal) {
6700
+ const resolvedNamespace = this.deps.writableNamespaceFor(
6701
+ request.namespace,
6702
+ void 0,
6703
+ request.authenticatedPrincipal ?? principal
6704
+ );
6705
+ let requested = 25;
6706
+ if (request.maxEntities !== void 0) {
6707
+ if (typeof request.maxEntities !== "number" || !Number.isInteger(request.maxEntities) || request.maxEntities < 1) {
6708
+ throw new Error(
6709
+ `Invalid maxEntities: ${String(request.maxEntities)} (expected an integer >= 1)`
6710
+ );
6711
+ }
6712
+ requested = Math.min(200, request.maxEntities);
6713
+ }
6714
+ const processed = await this.deps.orchestrator.entitySynthesisCoordinator.processQueue(
6715
+ resolvedNamespace,
6716
+ requested
6717
+ );
6718
+ const storage = await this.deps.orchestrator.getStorage(resolvedNamespace);
6719
+ const remaining = (await storage.readEntitySynthesisQueue()).length;
6720
+ return { namespace: resolvedNamespace, requested, processed, remaining };
6721
+ }
6691
6722
  async conversationIndexUpdate(request = {}) {
6692
6723
  if (!resolveIndexingCapabilities(this.deps.orchestrator.config).conversationIndex) {
6693
6724
  return {
@@ -10422,6 +10453,9 @@ var EngramAccessService = class {
10422
10453
  principal
10423
10454
  );
10424
10455
  }
10456
+ async entitySynthesisRun(request, principal) {
10457
+ return this.accessAdminOpsSurface.entitySynthesisRun(request, principal);
10458
+ }
10425
10459
  async procedureMiningRun(request, principal) {
10426
10460
  const resolvedNamespace = this.writableNamespaceFor(
10427
10461
  request.namespace,
@@ -12385,4 +12419,4 @@ export {
12385
12419
  EngramAccessService,
12386
12420
  AccessAdminOpsSurface
12387
12421
  };
12388
- //# sourceMappingURL=chunk-62QM5MKY.js.map
12422
+ //# sourceMappingURL=chunk-6ANPNUVL.js.map