@stacklink/sdk 0.2.0 → 0.3.7

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 (63) hide show
  1. package/README.md +33 -0
  2. package/compatibility.json +1 -1
  3. package/dist/src/domain/bot-contract.d.ts +4336 -0
  4. package/dist/src/domain/bot-contract.d.ts.map +1 -0
  5. package/dist/src/domain/bot-contract.js +382 -0
  6. package/dist/src/domain/bot-contract.js.map +1 -0
  7. package/dist/src/domain/memory-contract.d.ts +1705 -543
  8. package/dist/src/domain/memory-contract.d.ts.map +1 -1
  9. package/dist/src/domain/memory-contract.js +331 -60
  10. package/dist/src/domain/memory-contract.js.map +1 -1
  11. package/dist/src/domain/platform-approval-contract.d.ts +508 -0
  12. package/dist/src/domain/platform-approval-contract.d.ts.map +1 -0
  13. package/dist/src/domain/platform-approval-contract.js +77 -0
  14. package/dist/src/domain/platform-approval-contract.js.map +1 -0
  15. package/dist/src/domain/provider-branding.d.ts +1 -1
  16. package/dist/src/domain/provider-branding.d.ts.map +1 -1
  17. package/dist/src/domain/provider-branding.js +306 -8
  18. package/dist/src/domain/provider-branding.js.map +1 -1
  19. package/dist/src/domain/stacklink-meta-tools.d.ts +14 -16
  20. package/dist/src/domain/stacklink-meta-tools.d.ts.map +1 -1
  21. package/dist/src/domain/stacklink-meta-tools.js +217 -128
  22. package/dist/src/domain/stacklink-meta-tools.js.map +1 -1
  23. package/dist/src/sdk/framework-tools.d.ts +24 -2
  24. package/dist/src/sdk/framework-tools.d.ts.map +1 -1
  25. package/dist/src/sdk/framework-tools.js +50 -0
  26. package/dist/src/sdk/framework-tools.js.map +1 -1
  27. package/dist/src/sdk/index.d.ts +475 -143
  28. package/dist/src/sdk/index.d.ts.map +1 -1
  29. package/dist/src/sdk/index.js +633 -236
  30. package/dist/src/sdk/index.js.map +1 -1
  31. package/dist/src/sdk/langchain.d.ts +7 -2
  32. package/dist/src/sdk/langchain.d.ts.map +1 -1
  33. package/dist/src/sdk/langchain.js +3 -2
  34. package/dist/src/sdk/langchain.js.map +1 -1
  35. package/dist/src/sdk/memory-lifecycle.d.ts +25 -0
  36. package/dist/src/sdk/memory-lifecycle.d.ts.map +1 -1
  37. package/dist/src/sdk/memory-lifecycle.js +75 -1
  38. package/dist/src/sdk/memory-lifecycle.js.map +1 -1
  39. package/dist/src/sdk/openai-agents.d.ts +6 -6
  40. package/dist/src/sdk/openai-agents.d.ts.map +1 -1
  41. package/dist/src/sdk/openai-agents.js +21 -16
  42. package/dist/src/sdk/openai-agents.js.map +1 -1
  43. package/dist/src/sdk/openai.d.ts +2 -2
  44. package/dist/src/sdk/openai.d.ts.map +1 -1
  45. package/dist/src/sdk/openai.js +67 -31
  46. package/dist/src/sdk/openai.js.map +1 -1
  47. package/dist/src/sdk/vercel-ai.d.ts +15 -4
  48. package/dist/src/sdk/vercel-ai.d.ts.map +1 -1
  49. package/dist/src/sdk/vercel-ai.js +33 -9
  50. package/dist/src/sdk/vercel-ai.js.map +1 -1
  51. package/package.json +1 -1
  52. package/dist/src/domain/knowledge-meta-tools.d.ts +0 -12
  53. package/dist/src/domain/knowledge-meta-tools.d.ts.map +0 -1
  54. package/dist/src/domain/knowledge-meta-tools.js +0 -38
  55. package/dist/src/domain/knowledge-meta-tools.js.map +0 -1
  56. package/dist/src/domain/memory-meta-tools.d.ts +0 -5
  57. package/dist/src/domain/memory-meta-tools.d.ts.map +0 -1
  58. package/dist/src/domain/memory-meta-tools.js +0 -18
  59. package/dist/src/domain/memory-meta-tools.js.map +0 -1
  60. package/dist/src/domain/platform-mcp-tools.d.ts +0 -3
  61. package/dist/src/domain/platform-mcp-tools.d.ts.map +0 -1
  62. package/dist/src/domain/platform-mcp-tools.js +0 -30
  63. package/dist/src/domain/platform-mcp-tools.js.map +0 -1
@@ -5,6 +5,100 @@ export declare const memoryAutomaticRecordKinds: readonly ["fact", "episode"];
5
5
  export declare const memoryTypes: readonly ["preference", "decision", "commitment", "goal", "constraint", "relationship", "durable_fact"];
6
6
  export type MemoryType = typeof memoryTypes[number];
7
7
  export declare const memorySensitivityClasses: readonly ["standard", "personal", "restricted", "secret"];
8
+ export declare const memorySourceClasses: readonly ["human_communication", "structured_temporal", "structured_profile", "authored_document", "operational_event", "external_feed"];
9
+ export declare const memoryAuthorshipClasses: readonly ["connected_user", "other_human", "bot", "application", "system", "unknown"];
10
+ export declare const memoryAdmissionBases: readonly ["self_authored", "provider_structured_state", "attributed_third_party", "tool_execution", "user_confirmed"];
11
+ export declare const memoryDurabilities: readonly ["durable", "episodic", "transient"];
12
+ export declare const memoryQualityRatingClasses: readonly ["low", "medium", "high"];
13
+ export declare const memoryDestinations: readonly ["durable_memory", "episodic_memory", "restricted_candidate", "source_only", "reject_noise"];
14
+ export declare const memoryRetentionAdmissionStatuses: readonly ["memory", "source_only", "reject_noise", "uncertain"];
15
+ export declare const memoryQualityContractVersion: 1;
16
+ export declare const memoryProviderQualityContextSchema: z.ZodObject<{
17
+ authorshipBoundary: z.ZodOptional<z.ZodEnum<["exact_source_unit", "message_may_include_quotes"]>>;
18
+ contract: z.ZodLiteral<"stacklink.memory.source-quality.v1">;
19
+ qualityContractVersion: z.ZodLiteral<1>;
20
+ sourceClass: z.ZodEnum<["human_communication", "structured_temporal", "structured_profile", "authored_document", "operational_event", "external_feed"]>;
21
+ authorshipClass: z.ZodEnum<["connected_user", "other_human", "bot", "application", "system", "unknown"]>;
22
+ admissionBasis: z.ZodEnum<["self_authored", "provider_structured_state", "attributed_third_party", "tool_execution", "user_confirmed"]>;
23
+ actorCanonicalKey: z.ZodNullable<z.ZodString>;
24
+ actors: z.ZodDefault<z.ZodArray<z.ZodObject<{
25
+ canonicalKey: z.ZodString;
26
+ authorshipClass: z.ZodEnum<["connected_user", "other_human", "bot", "application", "system", "unknown"]>;
27
+ admissionBasis: z.ZodEnum<["self_authored", "provider_structured_state", "attributed_third_party", "tool_execution", "user_confirmed"]>;
28
+ defaultDestination: z.ZodEnum<["durable_memory", "episodic_memory", "restricted_candidate", "source_only", "reject_noise"]>;
29
+ allowedMemoryTypes: z.ZodArray<z.ZodEnum<["preference", "decision", "commitment", "goal", "constraint", "relationship", "durable_fact"]>, "many">;
30
+ }, "strict", z.ZodTypeAny, {
31
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
32
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
33
+ canonicalKey: string;
34
+ defaultDestination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
35
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
36
+ }, {
37
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
38
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
39
+ canonicalKey: string;
40
+ defaultDestination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
41
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
42
+ }>, "many">>;
43
+ connectedUserCanonicalKey: z.ZodNullable<z.ZodString>;
44
+ allowConnectedUserIntent: z.ZodBoolean;
45
+ allowedMemoryTypes: z.ZodArray<z.ZodEnum<["preference", "decision", "commitment", "goal", "constraint", "relationship", "durable_fact"]>, "many">;
46
+ defaultDestination: z.ZodEnum<["durable_memory", "episodic_memory", "restricted_candidate", "source_only", "reject_noise"]>;
47
+ defaultDurability: z.ZodEnum<["durable", "episodic", "transient"]>;
48
+ attachmentsIncluded: z.ZodBoolean;
49
+ hardExclusionSignals: z.ZodArray<z.ZodString, "many">;
50
+ validFrom: z.ZodDefault<z.ZodNullable<z.ZodString>>;
51
+ validTo: z.ZodDefault<z.ZodNullable<z.ZodString>>;
52
+ }, "strict", z.ZodTypeAny, {
53
+ contract: "stacklink.memory.source-quality.v1";
54
+ qualityContractVersion: 1;
55
+ sourceClass: "human_communication" | "structured_temporal" | "structured_profile" | "authored_document" | "operational_event" | "external_feed";
56
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
57
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
58
+ actorCanonicalKey: string | null;
59
+ defaultDestination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
60
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
61
+ actors: {
62
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
63
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
64
+ canonicalKey: string;
65
+ defaultDestination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
66
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
67
+ }[];
68
+ connectedUserCanonicalKey: string | null;
69
+ allowConnectedUserIntent: boolean;
70
+ defaultDurability: "durable" | "episodic" | "transient";
71
+ attachmentsIncluded: boolean;
72
+ hardExclusionSignals: string[];
73
+ validFrom: string | null;
74
+ validTo: string | null;
75
+ authorshipBoundary?: "exact_source_unit" | "message_may_include_quotes" | undefined;
76
+ }, {
77
+ contract: "stacklink.memory.source-quality.v1";
78
+ qualityContractVersion: 1;
79
+ sourceClass: "human_communication" | "structured_temporal" | "structured_profile" | "authored_document" | "operational_event" | "external_feed";
80
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
81
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
82
+ actorCanonicalKey: string | null;
83
+ defaultDestination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
84
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
85
+ connectedUserCanonicalKey: string | null;
86
+ allowConnectedUserIntent: boolean;
87
+ defaultDurability: "durable" | "episodic" | "transient";
88
+ attachmentsIncluded: boolean;
89
+ hardExclusionSignals: string[];
90
+ authorshipBoundary?: "exact_source_unit" | "message_may_include_quotes" | undefined;
91
+ actors?: {
92
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
93
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
94
+ canonicalKey: string;
95
+ defaultDestination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
96
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
97
+ }[] | undefined;
98
+ validFrom?: string | null | undefined;
99
+ validTo?: string | null | undefined;
100
+ }>;
101
+ export type MemoryProviderQualityContext = z.infer<typeof memoryProviderQualityContextSchema>;
8
102
  export declare const memoryRestrictedDataClasses: readonly ["health", "biometric", "government_identity", "precise_location", "protected_trait", "minor", "detailed_personal_financial"];
9
103
  export declare const memoryRecordStates: readonly ["current", "conflicted", "forgotten"];
10
104
  export declare const memoryRecallableRecordStates: readonly ["current", "conflicted"];
@@ -14,10 +108,10 @@ export declare const memorySubjectRefSchema: z.ZodObject<{
14
108
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
15
109
  externalId: z.ZodString;
16
110
  }, "strict", z.ZodTypeAny, {
17
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
111
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
18
112
  externalId: string;
19
113
  }, {
20
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
114
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
21
115
  externalId: string;
22
116
  }>;
23
117
  export type MemorySubjectRef = z.infer<typeof memorySubjectRefSchema>;
@@ -28,12 +122,12 @@ export declare const memoryConsentProofSchema: z.ZodObject<{
28
122
  reference: z.ZodOptional<z.ZodString>;
29
123
  }, "strict", z.ZodTypeAny, {
30
124
  status: "granted";
31
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
125
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
32
126
  recordedAt: string;
33
127
  reference?: string | undefined;
34
128
  }, {
35
129
  status: "granted";
36
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
130
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
37
131
  recordedAt: string;
38
132
  reference?: string | undefined;
39
133
  }>;
@@ -66,6 +160,156 @@ export declare const memoryTenantSelectorSchema: z.ZodEffects<z.ZodObject<{
66
160
  sessionId?: string | undefined;
67
161
  externalTenantId?: string | undefined;
68
162
  }>;
163
+ /** Minimal retained provenance, independent of the original source payload. */
164
+ export declare const memoryEvidenceReferenceSchema: z.ZodObject<{
165
+ contract: z.ZodDefault<z.ZodLiteral<"stacklink.memory.evidence.v1">>;
166
+ kind: z.ZodEnum<["email", "message", "object", "conversation", "file", "manual", "api", "unknown"]>;
167
+ href: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
168
+ availability: z.ZodDefault<z.ZodEnum<["available", "deleted", "unknown"]>>;
169
+ from: z.ZodOptional<z.ZodObject<{
170
+ name: z.ZodString;
171
+ address: z.ZodOptional<z.ZodString>;
172
+ }, "strip", z.ZodTypeAny, {
173
+ name: string;
174
+ address?: string | undefined;
175
+ }, {
176
+ name: string;
177
+ address?: string | undefined;
178
+ }>>;
179
+ subject: z.ZodOptional<z.ZodString>;
180
+ channel: z.ZodOptional<z.ZodString>;
181
+ object: z.ZodOptional<z.ZodObject<{
182
+ kind: z.ZodString;
183
+ name: z.ZodString;
184
+ id: z.ZodString;
185
+ observed: z.ZodOptional<z.ZodString>;
186
+ }, "strip", z.ZodTypeAny, {
187
+ kind: string;
188
+ id: string;
189
+ name: string;
190
+ observed?: string | undefined;
191
+ }, {
192
+ kind: string;
193
+ id: string;
194
+ name: string;
195
+ observed?: string | undefined;
196
+ }>>;
197
+ fields: z.ZodOptional<z.ZodArray<z.ZodObject<{
198
+ label: z.ZodString;
199
+ before: z.ZodOptional<z.ZodNullable<z.ZodString>>;
200
+ after: z.ZodString;
201
+ }, "strip", z.ZodTypeAny, {
202
+ label: string;
203
+ after: string;
204
+ before?: string | null | undefined;
205
+ }, {
206
+ label: string;
207
+ after: string;
208
+ before?: string | null | undefined;
209
+ }>, "many">>;
210
+ conversation: z.ZodOptional<z.ZodObject<{
211
+ sessionId: z.ZodOptional<z.ZodString>;
212
+ turn: z.ZodOptional<z.ZodString>;
213
+ speaker: z.ZodOptional<z.ZodString>;
214
+ assistant: z.ZodOptional<z.ZodBoolean>;
215
+ }, "strip", z.ZodTypeAny, {
216
+ sessionId?: string | undefined;
217
+ turn?: string | undefined;
218
+ speaker?: string | undefined;
219
+ assistant?: boolean | undefined;
220
+ }, {
221
+ sessionId?: string | undefined;
222
+ turn?: string | undefined;
223
+ speaker?: string | undefined;
224
+ assistant?: boolean | undefined;
225
+ }>>;
226
+ file: z.ZodOptional<z.ZodObject<{
227
+ title: z.ZodString;
228
+ section: z.ZodOptional<z.ZodString>;
229
+ edited: z.ZodOptional<z.ZodString>;
230
+ }, "strip", z.ZodTypeAny, {
231
+ title: string;
232
+ section?: string | undefined;
233
+ edited?: string | undefined;
234
+ }, {
235
+ title: string;
236
+ section?: string | undefined;
237
+ edited?: string | undefined;
238
+ }>>;
239
+ by: z.ZodOptional<z.ZodString>;
240
+ requestId: z.ZodOptional<z.ZodString>;
241
+ }, "strict", z.ZodTypeAny, {
242
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
243
+ contract: "stacklink.memory.evidence.v1";
244
+ availability: "unknown" | "available" | "deleted";
245
+ object?: {
246
+ kind: string;
247
+ id: string;
248
+ name: string;
249
+ observed?: string | undefined;
250
+ } | undefined;
251
+ channel?: string | undefined;
252
+ conversation?: {
253
+ sessionId?: string | undefined;
254
+ turn?: string | undefined;
255
+ speaker?: string | undefined;
256
+ assistant?: boolean | undefined;
257
+ } | undefined;
258
+ file?: {
259
+ title: string;
260
+ section?: string | undefined;
261
+ edited?: string | undefined;
262
+ } | undefined;
263
+ href?: string | undefined;
264
+ from?: {
265
+ name: string;
266
+ address?: string | undefined;
267
+ } | undefined;
268
+ subject?: string | undefined;
269
+ fields?: {
270
+ label: string;
271
+ after: string;
272
+ before?: string | null | undefined;
273
+ }[] | undefined;
274
+ by?: string | undefined;
275
+ requestId?: string | undefined;
276
+ }, {
277
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
278
+ object?: {
279
+ kind: string;
280
+ id: string;
281
+ name: string;
282
+ observed?: string | undefined;
283
+ } | undefined;
284
+ channel?: string | undefined;
285
+ contract?: "stacklink.memory.evidence.v1" | undefined;
286
+ conversation?: {
287
+ sessionId?: string | undefined;
288
+ turn?: string | undefined;
289
+ speaker?: string | undefined;
290
+ assistant?: boolean | undefined;
291
+ } | undefined;
292
+ file?: {
293
+ title: string;
294
+ section?: string | undefined;
295
+ edited?: string | undefined;
296
+ } | undefined;
297
+ href?: string | undefined;
298
+ availability?: "unknown" | "available" | "deleted" | undefined;
299
+ from?: {
300
+ name: string;
301
+ address?: string | undefined;
302
+ } | undefined;
303
+ subject?: string | undefined;
304
+ fields?: {
305
+ label: string;
306
+ after: string;
307
+ before?: string | null | undefined;
308
+ }[] | undefined;
309
+ by?: string | undefined;
310
+ requestId?: string | undefined;
311
+ }>;
312
+ export type MemoryEvidenceReference = z.input<typeof memoryEvidenceReferenceSchema>;
69
313
  export declare const memoryIngestInputSchema: z.ZodEffects<z.ZodObject<{
70
314
  occurredAt: z.ZodOptional<z.ZodString>;
71
315
  validFrom: z.ZodOptional<z.ZodString>;
@@ -77,10 +321,10 @@ export declare const memoryIngestInputSchema: z.ZodEffects<z.ZodObject<{
77
321
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
78
322
  externalId: z.ZodString;
79
323
  }, "strict", z.ZodTypeAny, {
80
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
324
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
81
325
  externalId: string;
82
326
  }, {
83
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
327
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
84
328
  externalId: string;
85
329
  }>, "many">>;
86
330
  mode: z.ZodDefault<z.ZodEnum<["exact", "extract"]>>;
@@ -101,24 +345,244 @@ export declare const memoryIngestInputSchema: z.ZodEffects<z.ZodObject<{
101
345
  resourceId: z.ZodOptional<z.ZodString>;
102
346
  toolExecutionId: z.ZodOptional<z.ZodString>;
103
347
  applicationKey: z.ZodOptional<z.ZodString>;
348
+ evidence: z.ZodOptional<z.ZodObject<{
349
+ contract: z.ZodDefault<z.ZodLiteral<"stacklink.memory.evidence.v1">>;
350
+ kind: z.ZodEnum<["email", "message", "object", "conversation", "file", "manual", "api", "unknown"]>;
351
+ href: z.ZodOptional<z.ZodEffects<z.ZodString, string, string>>;
352
+ availability: z.ZodDefault<z.ZodEnum<["available", "deleted", "unknown"]>>;
353
+ from: z.ZodOptional<z.ZodObject<{
354
+ name: z.ZodString;
355
+ address: z.ZodOptional<z.ZodString>;
356
+ }, "strip", z.ZodTypeAny, {
357
+ name: string;
358
+ address?: string | undefined;
359
+ }, {
360
+ name: string;
361
+ address?: string | undefined;
362
+ }>>;
363
+ subject: z.ZodOptional<z.ZodString>;
364
+ channel: z.ZodOptional<z.ZodString>;
365
+ object: z.ZodOptional<z.ZodObject<{
366
+ kind: z.ZodString;
367
+ name: z.ZodString;
368
+ id: z.ZodString;
369
+ observed: z.ZodOptional<z.ZodString>;
370
+ }, "strip", z.ZodTypeAny, {
371
+ kind: string;
372
+ id: string;
373
+ name: string;
374
+ observed?: string | undefined;
375
+ }, {
376
+ kind: string;
377
+ id: string;
378
+ name: string;
379
+ observed?: string | undefined;
380
+ }>>;
381
+ fields: z.ZodOptional<z.ZodArray<z.ZodObject<{
382
+ label: z.ZodString;
383
+ before: z.ZodOptional<z.ZodNullable<z.ZodString>>;
384
+ after: z.ZodString;
385
+ }, "strip", z.ZodTypeAny, {
386
+ label: string;
387
+ after: string;
388
+ before?: string | null | undefined;
389
+ }, {
390
+ label: string;
391
+ after: string;
392
+ before?: string | null | undefined;
393
+ }>, "many">>;
394
+ conversation: z.ZodOptional<z.ZodObject<{
395
+ sessionId: z.ZodOptional<z.ZodString>;
396
+ turn: z.ZodOptional<z.ZodString>;
397
+ speaker: z.ZodOptional<z.ZodString>;
398
+ assistant: z.ZodOptional<z.ZodBoolean>;
399
+ }, "strip", z.ZodTypeAny, {
400
+ sessionId?: string | undefined;
401
+ turn?: string | undefined;
402
+ speaker?: string | undefined;
403
+ assistant?: boolean | undefined;
404
+ }, {
405
+ sessionId?: string | undefined;
406
+ turn?: string | undefined;
407
+ speaker?: string | undefined;
408
+ assistant?: boolean | undefined;
409
+ }>>;
410
+ file: z.ZodOptional<z.ZodObject<{
411
+ title: z.ZodString;
412
+ section: z.ZodOptional<z.ZodString>;
413
+ edited: z.ZodOptional<z.ZodString>;
414
+ }, "strip", z.ZodTypeAny, {
415
+ title: string;
416
+ section?: string | undefined;
417
+ edited?: string | undefined;
418
+ }, {
419
+ title: string;
420
+ section?: string | undefined;
421
+ edited?: string | undefined;
422
+ }>>;
423
+ by: z.ZodOptional<z.ZodString>;
424
+ requestId: z.ZodOptional<z.ZodString>;
425
+ }, "strict", z.ZodTypeAny, {
426
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
427
+ contract: "stacklink.memory.evidence.v1";
428
+ availability: "unknown" | "available" | "deleted";
429
+ object?: {
430
+ kind: string;
431
+ id: string;
432
+ name: string;
433
+ observed?: string | undefined;
434
+ } | undefined;
435
+ channel?: string | undefined;
436
+ conversation?: {
437
+ sessionId?: string | undefined;
438
+ turn?: string | undefined;
439
+ speaker?: string | undefined;
440
+ assistant?: boolean | undefined;
441
+ } | undefined;
442
+ file?: {
443
+ title: string;
444
+ section?: string | undefined;
445
+ edited?: string | undefined;
446
+ } | undefined;
447
+ href?: string | undefined;
448
+ from?: {
449
+ name: string;
450
+ address?: string | undefined;
451
+ } | undefined;
452
+ subject?: string | undefined;
453
+ fields?: {
454
+ label: string;
455
+ after: string;
456
+ before?: string | null | undefined;
457
+ }[] | undefined;
458
+ by?: string | undefined;
459
+ requestId?: string | undefined;
460
+ }, {
461
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
462
+ object?: {
463
+ kind: string;
464
+ id: string;
465
+ name: string;
466
+ observed?: string | undefined;
467
+ } | undefined;
468
+ channel?: string | undefined;
469
+ contract?: "stacklink.memory.evidence.v1" | undefined;
470
+ conversation?: {
471
+ sessionId?: string | undefined;
472
+ turn?: string | undefined;
473
+ speaker?: string | undefined;
474
+ assistant?: boolean | undefined;
475
+ } | undefined;
476
+ file?: {
477
+ title: string;
478
+ section?: string | undefined;
479
+ edited?: string | undefined;
480
+ } | undefined;
481
+ href?: string | undefined;
482
+ availability?: "unknown" | "available" | "deleted" | undefined;
483
+ from?: {
484
+ name: string;
485
+ address?: string | undefined;
486
+ } | undefined;
487
+ subject?: string | undefined;
488
+ fields?: {
489
+ label: string;
490
+ after: string;
491
+ before?: string | null | undefined;
492
+ }[] | undefined;
493
+ by?: string | undefined;
494
+ requestId?: string | undefined;
495
+ }>>;
104
496
  }, "strict", z.ZodTypeAny, {
105
- kind: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution";
106
- providerKey?: string | undefined;
497
+ kind: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document";
107
498
  externalId?: string | undefined;
499
+ providerKey?: string | undefined;
500
+ resourceId?: string | undefined;
108
501
  connectedAccountId?: string | undefined;
109
502
  resourceType?: string | undefined;
110
- resourceId?: string | undefined;
111
503
  toolExecutionId?: string | undefined;
112
504
  applicationKey?: string | undefined;
505
+ evidence?: {
506
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
507
+ contract: "stacklink.memory.evidence.v1";
508
+ availability: "unknown" | "available" | "deleted";
509
+ object?: {
510
+ kind: string;
511
+ id: string;
512
+ name: string;
513
+ observed?: string | undefined;
514
+ } | undefined;
515
+ channel?: string | undefined;
516
+ conversation?: {
517
+ sessionId?: string | undefined;
518
+ turn?: string | undefined;
519
+ speaker?: string | undefined;
520
+ assistant?: boolean | undefined;
521
+ } | undefined;
522
+ file?: {
523
+ title: string;
524
+ section?: string | undefined;
525
+ edited?: string | undefined;
526
+ } | undefined;
527
+ href?: string | undefined;
528
+ from?: {
529
+ name: string;
530
+ address?: string | undefined;
531
+ } | undefined;
532
+ subject?: string | undefined;
533
+ fields?: {
534
+ label: string;
535
+ after: string;
536
+ before?: string | null | undefined;
537
+ }[] | undefined;
538
+ by?: string | undefined;
539
+ requestId?: string | undefined;
540
+ } | undefined;
113
541
  }, {
114
- providerKey?: string | undefined;
542
+ kind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
115
543
  externalId?: string | undefined;
116
- kind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
544
+ providerKey?: string | undefined;
545
+ resourceId?: string | undefined;
117
546
  connectedAccountId?: string | undefined;
118
547
  resourceType?: string | undefined;
119
- resourceId?: string | undefined;
120
548
  toolExecutionId?: string | undefined;
121
549
  applicationKey?: string | undefined;
550
+ evidence?: {
551
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
552
+ object?: {
553
+ kind: string;
554
+ id: string;
555
+ name: string;
556
+ observed?: string | undefined;
557
+ } | undefined;
558
+ channel?: string | undefined;
559
+ contract?: "stacklink.memory.evidence.v1" | undefined;
560
+ conversation?: {
561
+ sessionId?: string | undefined;
562
+ turn?: string | undefined;
563
+ speaker?: string | undefined;
564
+ assistant?: boolean | undefined;
565
+ } | undefined;
566
+ file?: {
567
+ title: string;
568
+ section?: string | undefined;
569
+ edited?: string | undefined;
570
+ } | undefined;
571
+ href?: string | undefined;
572
+ availability?: "unknown" | "available" | "deleted" | undefined;
573
+ from?: {
574
+ name: string;
575
+ address?: string | undefined;
576
+ } | undefined;
577
+ subject?: string | undefined;
578
+ fields?: {
579
+ label: string;
580
+ after: string;
581
+ before?: string | null | undefined;
582
+ }[] | undefined;
583
+ by?: string | undefined;
584
+ requestId?: string | undefined;
585
+ } | undefined;
122
586
  }>>;
123
587
  idempotencyKey: z.ZodOptional<z.ZodString>;
124
588
  policyKey: z.ZodOptional<z.ZodString>;
@@ -129,80 +593,154 @@ export declare const memoryIngestInputSchema: z.ZodEffects<z.ZodObject<{
129
593
  reference: z.ZodOptional<z.ZodString>;
130
594
  }, "strict", z.ZodTypeAny, {
131
595
  status: "granted";
132
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
596
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
133
597
  recordedAt: string;
134
598
  reference?: string | undefined;
135
599
  }, {
136
600
  status: "granted";
137
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
601
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
138
602
  recordedAt: string;
139
603
  reference?: string | undefined;
140
604
  }>>;
141
605
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
142
606
  }, "strip", z.ZodTypeAny, {
607
+ kind: "block" | "fact" | "episode" | "profile_item";
143
608
  source: {
144
- kind: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution";
145
- providerKey?: string | undefined;
609
+ kind: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document";
146
610
  externalId?: string | undefined;
611
+ providerKey?: string | undefined;
612
+ resourceId?: string | undefined;
147
613
  connectedAccountId?: string | undefined;
148
614
  resourceType?: string | undefined;
149
- resourceId?: string | undefined;
150
615
  toolExecutionId?: string | undefined;
151
616
  applicationKey?: string | undefined;
617
+ evidence?: {
618
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
619
+ contract: "stacklink.memory.evidence.v1";
620
+ availability: "unknown" | "available" | "deleted";
621
+ object?: {
622
+ kind: string;
623
+ id: string;
624
+ name: string;
625
+ observed?: string | undefined;
626
+ } | undefined;
627
+ channel?: string | undefined;
628
+ conversation?: {
629
+ sessionId?: string | undefined;
630
+ turn?: string | undefined;
631
+ speaker?: string | undefined;
632
+ assistant?: boolean | undefined;
633
+ } | undefined;
634
+ file?: {
635
+ title: string;
636
+ section?: string | undefined;
637
+ edited?: string | undefined;
638
+ } | undefined;
639
+ href?: string | undefined;
640
+ from?: {
641
+ name: string;
642
+ address?: string | undefined;
643
+ } | undefined;
644
+ subject?: string | undefined;
645
+ fields?: {
646
+ label: string;
647
+ after: string;
648
+ before?: string | null | undefined;
649
+ }[] | undefined;
650
+ by?: string | undefined;
651
+ requestId?: string | undefined;
652
+ } | undefined;
152
653
  };
153
654
  metadata: Record<string, unknown>;
154
655
  content: string;
155
656
  mode: "exact" | "extract";
156
- kind: "fact" | "episode" | "profile_item" | "block";
157
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
657
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
158
658
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
159
659
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
160
660
  topicTags: string[];
161
- idempotencyKey?: string | undefined;
162
661
  tenantId?: string | undefined;
163
662
  sessionId?: string | undefined;
663
+ idempotencyKey?: string | undefined;
664
+ validFrom?: string | undefined;
665
+ validTo?: string | undefined;
164
666
  externalTenantId?: string | undefined;
667
+ title?: string | undefined;
165
668
  subjects?: {
166
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
669
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
167
670
  externalId: string;
168
671
  }[] | undefined;
169
- title?: string | undefined;
170
672
  language?: string | undefined;
171
673
  policyKey?: string | undefined;
172
674
  consent?: {
173
675
  status: "granted";
174
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
676
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
175
677
  recordedAt: string;
176
678
  reference?: string | undefined;
177
679
  } | undefined;
178
680
  occurredAt?: string | undefined;
179
- validFrom?: string | undefined;
180
- validTo?: string | undefined;
181
681
  }, {
182
682
  content: string;
683
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
684
+ tenantId?: string | undefined;
183
685
  source?: {
184
- providerKey?: string | undefined;
686
+ kind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
185
687
  externalId?: string | undefined;
186
- kind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
688
+ providerKey?: string | undefined;
689
+ resourceId?: string | undefined;
187
690
  connectedAccountId?: string | undefined;
188
691
  resourceType?: string | undefined;
189
- resourceId?: string | undefined;
190
692
  toolExecutionId?: string | undefined;
191
693
  applicationKey?: string | undefined;
694
+ evidence?: {
695
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
696
+ object?: {
697
+ kind: string;
698
+ id: string;
699
+ name: string;
700
+ observed?: string | undefined;
701
+ } | undefined;
702
+ channel?: string | undefined;
703
+ contract?: "stacklink.memory.evidence.v1" | undefined;
704
+ conversation?: {
705
+ sessionId?: string | undefined;
706
+ turn?: string | undefined;
707
+ speaker?: string | undefined;
708
+ assistant?: boolean | undefined;
709
+ } | undefined;
710
+ file?: {
711
+ title: string;
712
+ section?: string | undefined;
713
+ edited?: string | undefined;
714
+ } | undefined;
715
+ href?: string | undefined;
716
+ availability?: "unknown" | "available" | "deleted" | undefined;
717
+ from?: {
718
+ name: string;
719
+ address?: string | undefined;
720
+ } | undefined;
721
+ subject?: string | undefined;
722
+ fields?: {
723
+ label: string;
724
+ after: string;
725
+ before?: string | null | undefined;
726
+ }[] | undefined;
727
+ by?: string | undefined;
728
+ requestId?: string | undefined;
729
+ } | undefined;
192
730
  } | undefined;
731
+ sessionId?: string | undefined;
193
732
  metadata?: Record<string, unknown> | undefined;
194
733
  idempotencyKey?: string | undefined;
195
- tenantId?: string | undefined;
196
734
  mode?: "exact" | "extract" | undefined;
197
- sessionId?: string | undefined;
735
+ validFrom?: string | undefined;
736
+ validTo?: string | undefined;
198
737
  externalTenantId?: string | undefined;
738
+ title?: string | undefined;
199
739
  subjects?: {
200
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
740
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
201
741
  externalId: string;
202
742
  }[] | undefined;
203
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
204
- title?: string | undefined;
205
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
743
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
206
744
  sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
207
745
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
208
746
  topicTags?: string[] | undefined;
@@ -210,77 +748,149 @@ export declare const memoryIngestInputSchema: z.ZodEffects<z.ZodObject<{
210
748
  policyKey?: string | undefined;
211
749
  consent?: {
212
750
  status: "granted";
213
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
751
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
214
752
  recordedAt: string;
215
753
  reference?: string | undefined;
216
754
  } | undefined;
217
755
  occurredAt?: string | undefined;
218
- validFrom?: string | undefined;
219
- validTo?: string | undefined;
220
756
  }>, {
757
+ kind: "block" | "fact" | "episode" | "profile_item";
221
758
  source: {
222
- kind: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution";
223
- providerKey?: string | undefined;
759
+ kind: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document";
224
760
  externalId?: string | undefined;
761
+ providerKey?: string | undefined;
762
+ resourceId?: string | undefined;
225
763
  connectedAccountId?: string | undefined;
226
764
  resourceType?: string | undefined;
227
- resourceId?: string | undefined;
228
765
  toolExecutionId?: string | undefined;
229
766
  applicationKey?: string | undefined;
767
+ evidence?: {
768
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
769
+ contract: "stacklink.memory.evidence.v1";
770
+ availability: "unknown" | "available" | "deleted";
771
+ object?: {
772
+ kind: string;
773
+ id: string;
774
+ name: string;
775
+ observed?: string | undefined;
776
+ } | undefined;
777
+ channel?: string | undefined;
778
+ conversation?: {
779
+ sessionId?: string | undefined;
780
+ turn?: string | undefined;
781
+ speaker?: string | undefined;
782
+ assistant?: boolean | undefined;
783
+ } | undefined;
784
+ file?: {
785
+ title: string;
786
+ section?: string | undefined;
787
+ edited?: string | undefined;
788
+ } | undefined;
789
+ href?: string | undefined;
790
+ from?: {
791
+ name: string;
792
+ address?: string | undefined;
793
+ } | undefined;
794
+ subject?: string | undefined;
795
+ fields?: {
796
+ label: string;
797
+ after: string;
798
+ before?: string | null | undefined;
799
+ }[] | undefined;
800
+ by?: string | undefined;
801
+ requestId?: string | undefined;
802
+ } | undefined;
230
803
  };
231
804
  metadata: Record<string, unknown>;
232
805
  content: string;
233
806
  mode: "exact" | "extract";
234
- kind: "fact" | "episode" | "profile_item" | "block";
235
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
807
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
236
808
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
237
809
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
238
810
  topicTags: string[];
239
- idempotencyKey?: string | undefined;
240
811
  tenantId?: string | undefined;
241
812
  sessionId?: string | undefined;
813
+ idempotencyKey?: string | undefined;
814
+ validFrom?: string | undefined;
815
+ validTo?: string | undefined;
242
816
  externalTenantId?: string | undefined;
817
+ title?: string | undefined;
243
818
  subjects?: {
244
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
819
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
245
820
  externalId: string;
246
821
  }[] | undefined;
247
- title?: string | undefined;
248
822
  language?: string | undefined;
249
823
  policyKey?: string | undefined;
250
824
  consent?: {
251
825
  status: "granted";
252
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
826
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
253
827
  recordedAt: string;
254
828
  reference?: string | undefined;
255
829
  } | undefined;
256
830
  occurredAt?: string | undefined;
257
- validFrom?: string | undefined;
258
- validTo?: string | undefined;
259
831
  }, {
260
832
  content: string;
833
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
834
+ tenantId?: string | undefined;
261
835
  source?: {
262
- providerKey?: string | undefined;
836
+ kind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
263
837
  externalId?: string | undefined;
264
- kind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
838
+ providerKey?: string | undefined;
839
+ resourceId?: string | undefined;
265
840
  connectedAccountId?: string | undefined;
266
841
  resourceType?: string | undefined;
267
- resourceId?: string | undefined;
268
842
  toolExecutionId?: string | undefined;
269
843
  applicationKey?: string | undefined;
844
+ evidence?: {
845
+ kind: "object" | "message" | "unknown" | "email" | "manual" | "api" | "conversation" | "file";
846
+ object?: {
847
+ kind: string;
848
+ id: string;
849
+ name: string;
850
+ observed?: string | undefined;
851
+ } | undefined;
852
+ channel?: string | undefined;
853
+ contract?: "stacklink.memory.evidence.v1" | undefined;
854
+ conversation?: {
855
+ sessionId?: string | undefined;
856
+ turn?: string | undefined;
857
+ speaker?: string | undefined;
858
+ assistant?: boolean | undefined;
859
+ } | undefined;
860
+ file?: {
861
+ title: string;
862
+ section?: string | undefined;
863
+ edited?: string | undefined;
864
+ } | undefined;
865
+ href?: string | undefined;
866
+ availability?: "unknown" | "available" | "deleted" | undefined;
867
+ from?: {
868
+ name: string;
869
+ address?: string | undefined;
870
+ } | undefined;
871
+ subject?: string | undefined;
872
+ fields?: {
873
+ label: string;
874
+ after: string;
875
+ before?: string | null | undefined;
876
+ }[] | undefined;
877
+ by?: string | undefined;
878
+ requestId?: string | undefined;
879
+ } | undefined;
270
880
  } | undefined;
881
+ sessionId?: string | undefined;
271
882
  metadata?: Record<string, unknown> | undefined;
272
883
  idempotencyKey?: string | undefined;
273
- tenantId?: string | undefined;
274
884
  mode?: "exact" | "extract" | undefined;
275
- sessionId?: string | undefined;
885
+ validFrom?: string | undefined;
886
+ validTo?: string | undefined;
276
887
  externalTenantId?: string | undefined;
888
+ title?: string | undefined;
277
889
  subjects?: {
278
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
890
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
279
891
  externalId: string;
280
892
  }[] | undefined;
281
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
282
- title?: string | undefined;
283
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
893
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
284
894
  sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
285
895
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
286
896
  topicTags?: string[] | undefined;
@@ -288,13 +898,11 @@ export declare const memoryIngestInputSchema: z.ZodEffects<z.ZodObject<{
288
898
  policyKey?: string | undefined;
289
899
  consent?: {
290
900
  status: "granted";
291
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
901
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
292
902
  recordedAt: string;
293
903
  reference?: string | undefined;
294
904
  } | undefined;
295
905
  occurredAt?: string | undefined;
296
- validFrom?: string | undefined;
297
- validTo?: string | undefined;
298
906
  }>;
299
907
  export type MemoryIngestInput = z.input<typeof memoryIngestInputSchema>;
300
908
  export type ParsedMemoryIngestInput = z.output<typeof memoryIngestInputSchema>;
@@ -309,10 +917,10 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
309
917
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
310
918
  externalId: z.ZodString;
311
919
  }, "strict", z.ZodTypeAny, {
312
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
920
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
313
921
  externalId: string;
314
922
  }, {
315
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
923
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
316
924
  externalId: string;
317
925
  }>, "many">>;
318
926
  mode: z.ZodDefault<z.ZodEnum<["exact", "extract"]>>;
@@ -357,17 +965,18 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
357
965
  reference: z.ZodOptional<z.ZodString>;
358
966
  }, "strict", z.ZodTypeAny, {
359
967
  status: "granted";
360
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
968
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
361
969
  recordedAt: string;
362
970
  reference?: string | undefined;
363
971
  }, {
364
972
  status: "granted";
365
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
973
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
366
974
  recordedAt: string;
367
975
  reference?: string | undefined;
368
976
  }>>;
369
977
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
370
978
  }, "strip", z.ZodTypeAny, {
979
+ kind: "block" | "fact" | "episode" | "profile_item";
371
980
  metadata: Record<string, unknown>;
372
981
  input: {
373
982
  type: "file";
@@ -379,31 +988,30 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
379
988
  url: string;
380
989
  };
381
990
  mode: "exact" | "extract";
382
- kind: "fact" | "episode" | "profile_item" | "block";
383
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
991
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
384
992
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
385
993
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
386
994
  topicTags: string[];
387
- idempotencyKey?: string | undefined;
388
995
  tenantId?: string | undefined;
389
996
  sessionId?: string | undefined;
997
+ idempotencyKey?: string | undefined;
998
+ validFrom?: string | undefined;
999
+ validTo?: string | undefined;
390
1000
  externalTenantId?: string | undefined;
1001
+ title?: string | undefined;
391
1002
  subjects?: {
392
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1003
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
393
1004
  externalId: string;
394
1005
  }[] | undefined;
395
- title?: string | undefined;
396
1006
  language?: string | undefined;
397
1007
  policyKey?: string | undefined;
398
1008
  consent?: {
399
1009
  status: "granted";
400
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1010
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
401
1011
  recordedAt: string;
402
1012
  reference?: string | undefined;
403
1013
  } | undefined;
404
1014
  occurredAt?: string | undefined;
405
- validFrom?: string | undefined;
406
- validTo?: string | undefined;
407
1015
  }, {
408
1016
  input: {
409
1017
  type: "file";
@@ -414,19 +1022,21 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
414
1022
  type: "url";
415
1023
  url: string;
416
1024
  };
1025
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
1026
+ tenantId?: string | undefined;
1027
+ sessionId?: string | undefined;
417
1028
  metadata?: Record<string, unknown> | undefined;
418
1029
  idempotencyKey?: string | undefined;
419
- tenantId?: string | undefined;
420
1030
  mode?: "exact" | "extract" | undefined;
421
- sessionId?: string | undefined;
1031
+ validFrom?: string | undefined;
1032
+ validTo?: string | undefined;
422
1033
  externalTenantId?: string | undefined;
1034
+ title?: string | undefined;
423
1035
  subjects?: {
424
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1036
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
425
1037
  externalId: string;
426
1038
  }[] | undefined;
427
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
428
- title?: string | undefined;
429
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
1039
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
430
1040
  sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
431
1041
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
432
1042
  topicTags?: string[] | undefined;
@@ -434,14 +1044,13 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
434
1044
  policyKey?: string | undefined;
435
1045
  consent?: {
436
1046
  status: "granted";
437
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1047
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
438
1048
  recordedAt: string;
439
1049
  reference?: string | undefined;
440
1050
  } | undefined;
441
1051
  occurredAt?: string | undefined;
442
- validFrom?: string | undefined;
443
- validTo?: string | undefined;
444
1052
  }>, {
1053
+ kind: "block" | "fact" | "episode" | "profile_item";
445
1054
  metadata: Record<string, unknown>;
446
1055
  input: {
447
1056
  type: "file";
@@ -453,31 +1062,30 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
453
1062
  url: string;
454
1063
  };
455
1064
  mode: "exact" | "extract";
456
- kind: "fact" | "episode" | "profile_item" | "block";
457
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
1065
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
458
1066
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
459
1067
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
460
1068
  topicTags: string[];
461
- idempotencyKey?: string | undefined;
462
1069
  tenantId?: string | undefined;
463
1070
  sessionId?: string | undefined;
1071
+ idempotencyKey?: string | undefined;
1072
+ validFrom?: string | undefined;
1073
+ validTo?: string | undefined;
464
1074
  externalTenantId?: string | undefined;
1075
+ title?: string | undefined;
465
1076
  subjects?: {
466
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1077
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
467
1078
  externalId: string;
468
1079
  }[] | undefined;
469
- title?: string | undefined;
470
1080
  language?: string | undefined;
471
1081
  policyKey?: string | undefined;
472
1082
  consent?: {
473
1083
  status: "granted";
474
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1084
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
475
1085
  recordedAt: string;
476
1086
  reference?: string | undefined;
477
1087
  } | undefined;
478
1088
  occurredAt?: string | undefined;
479
- validFrom?: string | undefined;
480
- validTo?: string | undefined;
481
1089
  }, {
482
1090
  input: {
483
1091
  type: "file";
@@ -488,19 +1096,21 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
488
1096
  type: "url";
489
1097
  url: string;
490
1098
  };
1099
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
1100
+ tenantId?: string | undefined;
1101
+ sessionId?: string | undefined;
491
1102
  metadata?: Record<string, unknown> | undefined;
492
1103
  idempotencyKey?: string | undefined;
493
- tenantId?: string | undefined;
494
1104
  mode?: "exact" | "extract" | undefined;
495
- sessionId?: string | undefined;
1105
+ validFrom?: string | undefined;
1106
+ validTo?: string | undefined;
496
1107
  externalTenantId?: string | undefined;
1108
+ title?: string | undefined;
497
1109
  subjects?: {
498
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1110
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
499
1111
  externalId: string;
500
1112
  }[] | undefined;
501
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
502
- title?: string | undefined;
503
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
1113
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
504
1114
  sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
505
1115
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
506
1116
  topicTags?: string[] | undefined;
@@ -508,13 +1118,11 @@ export declare const memoryRichIngestInputSchema: z.ZodEffects<z.ZodObject<{
508
1118
  policyKey?: string | undefined;
509
1119
  consent?: {
510
1120
  status: "granted";
511
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1121
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
512
1122
  recordedAt: string;
513
1123
  reference?: string | undefined;
514
1124
  } | undefined;
515
1125
  occurredAt?: string | undefined;
516
- validFrom?: string | undefined;
517
- validTo?: string | undefined;
518
1126
  }>;
519
1127
  export type MemoryRichIngestInput = z.input<typeof memoryRichIngestInputSchema>;
520
1128
  export type ParsedMemoryRichIngestInput = z.output<typeof memoryRichIngestInputSchema>;
@@ -531,10 +1139,10 @@ export declare const memorySearchInputSchema: z.ZodEffects<z.ZodObject<{
531
1139
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
532
1140
  externalId: z.ZodString;
533
1141
  }, "strict", z.ZodTypeAny, {
534
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1142
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
535
1143
  externalId: string;
536
1144
  }, {
537
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1145
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
538
1146
  externalId: string;
539
1147
  }>, "many">>;
540
1148
  query: z.ZodString;
@@ -563,11 +1171,11 @@ export declare const memorySearchInputSchema: z.ZodEffects<z.ZodObject<{
563
1171
  recordedAt?: string | undefined;
564
1172
  externalTenantId?: string | undefined;
565
1173
  subjects?: {
566
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1174
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
567
1175
  externalId: string;
568
1176
  }[] | undefined;
569
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
570
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1177
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1178
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
571
1179
  providerKeys?: string[] | undefined;
572
1180
  sourceFamilyKeys?: string[] | undefined;
573
1181
  connectedAccountIds?: string[] | undefined;
@@ -577,17 +1185,17 @@ export declare const memorySearchInputSchema: z.ZodEffects<z.ZodObject<{
577
1185
  semanticCandidateLimit?: number | undefined;
578
1186
  }, {
579
1187
  query: string;
580
- limit?: number | undefined;
581
1188
  tenantId?: string | undefined;
582
1189
  sessionId?: string | undefined;
1190
+ limit?: number | undefined;
583
1191
  recordedAt?: string | undefined;
584
1192
  externalTenantId?: string | undefined;
585
1193
  subjects?: {
586
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1194
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
587
1195
  externalId: string;
588
1196
  }[] | undefined;
589
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
590
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1197
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1198
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
591
1199
  providerKeys?: string[] | undefined;
592
1200
  sourceFamilyKeys?: string[] | undefined;
593
1201
  connectedAccountIds?: string[] | undefined;
@@ -609,11 +1217,11 @@ export declare const memorySearchInputSchema: z.ZodEffects<z.ZodObject<{
609
1217
  recordedAt?: string | undefined;
610
1218
  externalTenantId?: string | undefined;
611
1219
  subjects?: {
612
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1220
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
613
1221
  externalId: string;
614
1222
  }[] | undefined;
615
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
616
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1223
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1224
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
617
1225
  providerKeys?: string[] | undefined;
618
1226
  sourceFamilyKeys?: string[] | undefined;
619
1227
  connectedAccountIds?: string[] | undefined;
@@ -623,17 +1231,17 @@ export declare const memorySearchInputSchema: z.ZodEffects<z.ZodObject<{
623
1231
  semanticCandidateLimit?: number | undefined;
624
1232
  }, {
625
1233
  query: string;
626
- limit?: number | undefined;
627
1234
  tenantId?: string | undefined;
628
1235
  sessionId?: string | undefined;
1236
+ limit?: number | undefined;
629
1237
  recordedAt?: string | undefined;
630
1238
  externalTenantId?: string | undefined;
631
1239
  subjects?: {
632
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1240
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
633
1241
  externalId: string;
634
1242
  }[] | undefined;
635
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
636
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1243
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1244
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
637
1245
  providerKeys?: string[] | undefined;
638
1246
  sourceFamilyKeys?: string[] | undefined;
639
1247
  connectedAccountIds?: string[] | undefined;
@@ -655,10 +1263,10 @@ export declare const memoryContextInputSchema: z.ZodEffects<z.ZodObject<{
655
1263
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
656
1264
  externalId: z.ZodString;
657
1265
  }, "strict", z.ZodTypeAny, {
658
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1266
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
659
1267
  externalId: string;
660
1268
  }, {
661
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1269
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
662
1270
  externalId: string;
663
1271
  }>, "many">>;
664
1272
  kinds: z.ZodOptional<z.ZodArray<z.ZodEnum<["fact", "episode", "profile_item", "block"]>, "many">>;
@@ -695,11 +1303,11 @@ export declare const memoryContextInputSchema: z.ZodEffects<z.ZodObject<{
695
1303
  recordedAt?: string | undefined;
696
1304
  externalTenantId?: string | undefined;
697
1305
  subjects?: {
698
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1306
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
699
1307
  externalId: string;
700
1308
  }[] | undefined;
701
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
702
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1309
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1310
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
703
1311
  providerKeys?: string[] | undefined;
704
1312
  sourceFamilyKeys?: string[] | undefined;
705
1313
  connectedAccountIds?: string[] | undefined;
@@ -712,17 +1320,17 @@ export declare const memoryContextInputSchema: z.ZodEffects<z.ZodObject<{
712
1320
  includeBlocks?: boolean | undefined;
713
1321
  }, {
714
1322
  query: string;
715
- limit?: number | undefined;
716
1323
  tenantId?: string | undefined;
717
1324
  sessionId?: string | undefined;
1325
+ limit?: number | undefined;
718
1326
  recordedAt?: string | undefined;
719
1327
  externalTenantId?: string | undefined;
720
1328
  subjects?: {
721
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1329
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
722
1330
  externalId: string;
723
1331
  }[] | undefined;
724
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
725
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1332
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1333
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
726
1334
  providerKeys?: string[] | undefined;
727
1335
  sourceFamilyKeys?: string[] | undefined;
728
1336
  connectedAccountIds?: string[] | undefined;
@@ -751,11 +1359,11 @@ export declare const memoryContextInputSchema: z.ZodEffects<z.ZodObject<{
751
1359
  recordedAt?: string | undefined;
752
1360
  externalTenantId?: string | undefined;
753
1361
  subjects?: {
754
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1362
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
755
1363
  externalId: string;
756
1364
  }[] | undefined;
757
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
758
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1365
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1366
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
759
1367
  providerKeys?: string[] | undefined;
760
1368
  sourceFamilyKeys?: string[] | undefined;
761
1369
  connectedAccountIds?: string[] | undefined;
@@ -768,17 +1376,17 @@ export declare const memoryContextInputSchema: z.ZodEffects<z.ZodObject<{
768
1376
  includeBlocks?: boolean | undefined;
769
1377
  }, {
770
1378
  query: string;
771
- limit?: number | undefined;
772
1379
  tenantId?: string | undefined;
773
1380
  sessionId?: string | undefined;
1381
+ limit?: number | undefined;
774
1382
  recordedAt?: string | undefined;
775
1383
  externalTenantId?: string | undefined;
776
1384
  subjects?: {
777
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1385
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
778
1386
  externalId: string;
779
1387
  }[] | undefined;
780
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
781
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1388
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
1389
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
782
1390
  providerKeys?: string[] | undefined;
783
1391
  sourceFamilyKeys?: string[] | undefined;
784
1392
  connectedAccountIds?: string[] | undefined;
@@ -810,48 +1418,48 @@ export declare const memoryRecordListQuerySchema: z.ZodEffects<z.ZodObject<{
810
1418
  limit: z.ZodDefault<z.ZodNumber>;
811
1419
  }, "strip", z.ZodTypeAny, {
812
1420
  limit: number;
813
- cursor?: string | undefined;
1421
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
814
1422
  tenantId?: string | undefined;
815
1423
  sessionId?: string | undefined;
816
- externalTenantId?: string | undefined;
817
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
1424
+ cursor?: string | undefined;
818
1425
  state?: "current" | "conflicted" | undefined;
819
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1426
+ externalTenantId?: string | undefined;
1427
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
820
1428
  externalSubjectId?: string | undefined;
821
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1429
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
822
1430
  }, {
823
- cursor?: string | undefined;
824
- limit?: number | undefined;
1431
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
825
1432
  tenantId?: string | undefined;
826
1433
  sessionId?: string | undefined;
827
- externalTenantId?: string | undefined;
828
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
1434
+ cursor?: string | undefined;
1435
+ limit?: number | undefined;
829
1436
  state?: "current" | "conflicted" | undefined;
830
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1437
+ externalTenantId?: string | undefined;
1438
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
831
1439
  externalSubjectId?: string | undefined;
832
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1440
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
833
1441
  }>, {
834
1442
  limit: number;
835
- cursor?: string | undefined;
1443
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
836
1444
  tenantId?: string | undefined;
837
1445
  sessionId?: string | undefined;
838
- externalTenantId?: string | undefined;
839
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
1446
+ cursor?: string | undefined;
840
1447
  state?: "current" | "conflicted" | undefined;
841
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1448
+ externalTenantId?: string | undefined;
1449
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
842
1450
  externalSubjectId?: string | undefined;
843
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1451
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
844
1452
  }, {
845
- cursor?: string | undefined;
846
- limit?: number | undefined;
1453
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
847
1454
  tenantId?: string | undefined;
848
1455
  sessionId?: string | undefined;
849
- externalTenantId?: string | undefined;
850
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
1456
+ cursor?: string | undefined;
1457
+ limit?: number | undefined;
851
1458
  state?: "current" | "conflicted" | undefined;
852
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1459
+ externalTenantId?: string | undefined;
1460
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
853
1461
  externalSubjectId?: string | undefined;
854
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1462
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
855
1463
  }>;
856
1464
  export declare const memoryForgottenRecordListQuerySchema: z.ZodEffects<z.ZodObject<{
857
1465
  readonly tenantId: z.ZodOptional<z.ZodString>;
@@ -865,44 +1473,44 @@ export declare const memoryForgottenRecordListQuerySchema: z.ZodEffects<z.ZodObj
865
1473
  readonly limit: z.ZodDefault<z.ZodNumber>;
866
1474
  }, "strip", z.ZodTypeAny, {
867
1475
  limit: number;
868
- cursor?: string | undefined;
1476
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
869
1477
  tenantId?: string | undefined;
870
1478
  sessionId?: string | undefined;
1479
+ cursor?: string | undefined;
871
1480
  externalTenantId?: string | undefined;
872
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
873
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1481
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
874
1482
  externalSubjectId?: string | undefined;
875
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1483
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
876
1484
  }, {
877
- cursor?: string | undefined;
878
- limit?: number | undefined;
1485
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
879
1486
  tenantId?: string | undefined;
880
1487
  sessionId?: string | undefined;
1488
+ cursor?: string | undefined;
1489
+ limit?: number | undefined;
881
1490
  externalTenantId?: string | undefined;
882
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
883
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1491
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
884
1492
  externalSubjectId?: string | undefined;
885
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1493
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
886
1494
  }>, {
887
1495
  limit: number;
888
- cursor?: string | undefined;
1496
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
889
1497
  tenantId?: string | undefined;
890
1498
  sessionId?: string | undefined;
1499
+ cursor?: string | undefined;
891
1500
  externalTenantId?: string | undefined;
892
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
893
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1501
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
894
1502
  externalSubjectId?: string | undefined;
895
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1503
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
896
1504
  }, {
897
- cursor?: string | undefined;
898
- limit?: number | undefined;
1505
+ kind?: "block" | "fact" | "episode" | "profile_item" | undefined;
899
1506
  tenantId?: string | undefined;
900
1507
  sessionId?: string | undefined;
1508
+ cursor?: string | undefined;
1509
+ limit?: number | undefined;
901
1510
  externalTenantId?: string | undefined;
902
- kind?: "fact" | "episode" | "profile_item" | "block" | undefined;
903
- subjectType?: "run" | "user" | "agent" | "tenant" | "application" | "custom" | undefined;
1511
+ subjectType?: "custom" | "run" | "user" | "agent" | "tenant" | "application" | undefined;
904
1512
  externalSubjectId?: string | undefined;
905
- sourceKind?: "artifact" | "direct" | "conversation" | "document" | "provider" | "tool_execution" | undefined;
1513
+ sourceKind?: "provider" | "artifact" | "tool_execution" | "direct" | "conversation" | "document" | undefined;
906
1514
  }>;
907
1515
  export declare const memoryRecordUpdateInputSchema: z.ZodEffects<z.ZodObject<{
908
1516
  content: z.ZodOptional<z.ZodString>;
@@ -918,59 +1526,233 @@ export declare const memoryRecordUpdateInputSchema: z.ZodEffects<z.ZodObject<{
918
1526
  reason: z.ZodOptional<z.ZodString>;
919
1527
  metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
920
1528
  }, "strip", z.ZodTypeAny, {
1529
+ reason?: string | undefined;
921
1530
  metadata?: Record<string, unknown> | undefined;
922
1531
  content?: string | undefined;
923
- reason?: string | undefined;
1532
+ state?: "current" | "conflicted" | undefined;
1533
+ validFrom?: string | null | undefined;
1534
+ validTo?: string | null | undefined;
924
1535
  title?: string | null | undefined;
925
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
1536
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
926
1537
  sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
927
1538
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
928
1539
  topicTags?: string[] | undefined;
929
1540
  language?: string | null | undefined;
930
- validFrom?: string | null | undefined;
931
- validTo?: string | null | undefined;
932
- state?: "current" | "conflicted" | undefined;
933
1541
  }, {
1542
+ reason?: string | undefined;
934
1543
  metadata?: Record<string, unknown> | undefined;
935
1544
  content?: string | undefined;
936
- reason?: string | undefined;
1545
+ state?: "current" | "conflicted" | undefined;
1546
+ validFrom?: string | null | undefined;
1547
+ validTo?: string | null | undefined;
937
1548
  title?: string | null | undefined;
938
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
1549
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
939
1550
  sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
940
1551
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
941
1552
  topicTags?: string[] | undefined;
942
1553
  language?: string | null | undefined;
943
- validFrom?: string | null | undefined;
944
- validTo?: string | null | undefined;
945
- state?: "current" | "conflicted" | undefined;
946
1554
  }>, {
1555
+ reason?: string | undefined;
947
1556
  metadata?: Record<string, unknown> | undefined;
948
1557
  content?: string | undefined;
1558
+ state?: "current" | "conflicted" | undefined;
1559
+ validFrom?: string | null | undefined;
1560
+ validTo?: string | null | undefined;
1561
+ title?: string | null | undefined;
1562
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
1563
+ sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
1564
+ restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
1565
+ topicTags?: string[] | undefined;
1566
+ language?: string | null | undefined;
1567
+ }, {
949
1568
  reason?: string | undefined;
1569
+ metadata?: Record<string, unknown> | undefined;
1570
+ content?: string | undefined;
1571
+ state?: "current" | "conflicted" | undefined;
1572
+ validFrom?: string | null | undefined;
1573
+ validTo?: string | null | undefined;
950
1574
  title?: string | null | undefined;
951
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
1575
+ memoryType?: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
952
1576
  sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
953
1577
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
954
1578
  topicTags?: string[] | undefined;
955
1579
  language?: string | null | undefined;
1580
+ }>;
1581
+ export type MemoryRecordUpdateInput = z.infer<typeof memoryRecordUpdateInputSchema>;
1582
+ export declare const memoryQualityReviewDispositions: readonly ["keep", "correct", "convert_to_episode", "restrict"];
1583
+ export declare const memoryQualityReviewEntitySchema: z.ZodObject<{
1584
+ entityType: z.ZodString;
1585
+ canonicalKey: z.ZodString;
1586
+ displayName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1587
+ attributes: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1588
+ }, "strict", z.ZodTypeAny, {
1589
+ canonicalKey: string;
1590
+ entityType: string;
1591
+ attributes: Record<string, unknown>;
1592
+ displayName?: string | null | undefined;
1593
+ }, {
1594
+ canonicalKey: string;
1595
+ entityType: string;
1596
+ displayName?: string | null | undefined;
1597
+ attributes?: Record<string, unknown> | undefined;
1598
+ }>;
1599
+ export declare const memoryRecordQualityReviewInputSchema: z.ZodEffects<z.ZodObject<{
1600
+ disposition: z.ZodEnum<["keep", "correct", "convert_to_episode", "restrict"]>;
1601
+ content: z.ZodOptional<z.ZodString>;
1602
+ title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1603
+ memoryType: z.ZodEnum<["preference", "decision", "commitment", "goal", "constraint", "relationship", "durable_fact"]>;
1604
+ sensitivityClass: z.ZodEnum<["standard", "personal", "restricted", "secret"]>;
1605
+ restrictedDataClasses: z.ZodDefault<z.ZodArray<z.ZodEnum<["health", "biometric", "government_identity", "precise_location", "protected_trait", "minor", "detailed_personal_financial"]>, "many">>;
1606
+ topicTags: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
1607
+ language: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1608
+ validFrom: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1609
+ validTo: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1610
+ authorshipClass: z.ZodEnum<["connected_user", "other_human", "bot", "application", "system", "unknown"]>;
1611
+ salience: z.ZodEnum<["low", "medium", "high"]>;
1612
+ evidenceConfidence: z.ZodEnum<["low", "medium", "high"]>;
1613
+ actorEntity: z.ZodObject<{
1614
+ entityType: z.ZodString;
1615
+ canonicalKey: z.ZodString;
1616
+ displayName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1617
+ attributes: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1618
+ }, "strict", z.ZodTypeAny, {
1619
+ canonicalKey: string;
1620
+ entityType: string;
1621
+ attributes: Record<string, unknown>;
1622
+ displayName?: string | null | undefined;
1623
+ }, {
1624
+ canonicalKey: string;
1625
+ entityType: string;
1626
+ displayName?: string | null | undefined;
1627
+ attributes?: Record<string, unknown> | undefined;
1628
+ }>;
1629
+ subjectEntity: z.ZodObject<{
1630
+ entityType: z.ZodString;
1631
+ canonicalKey: z.ZodString;
1632
+ displayName: z.ZodOptional<z.ZodNullable<z.ZodString>>;
1633
+ attributes: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1634
+ }, "strict", z.ZodTypeAny, {
1635
+ canonicalKey: string;
1636
+ entityType: string;
1637
+ attributes: Record<string, unknown>;
1638
+ displayName?: string | null | undefined;
1639
+ }, {
1640
+ canonicalKey: string;
1641
+ entityType: string;
1642
+ displayName?: string | null | undefined;
1643
+ attributes?: Record<string, unknown> | undefined;
1644
+ }>;
1645
+ reason: z.ZodString;
1646
+ }, "strict", z.ZodTypeAny, {
1647
+ reason: string;
1648
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
1649
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
1650
+ sensitivityClass: "standard" | "personal" | "restricted" | "secret";
1651
+ restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
1652
+ disposition: "keep" | "correct" | "convert_to_episode" | "restrict";
1653
+ salience: "low" | "medium" | "high";
1654
+ evidenceConfidence: "low" | "medium" | "high";
1655
+ actorEntity: {
1656
+ canonicalKey: string;
1657
+ entityType: string;
1658
+ attributes: Record<string, unknown>;
1659
+ displayName?: string | null | undefined;
1660
+ };
1661
+ subjectEntity: {
1662
+ canonicalKey: string;
1663
+ entityType: string;
1664
+ attributes: Record<string, unknown>;
1665
+ displayName?: string | null | undefined;
1666
+ };
1667
+ content?: string | undefined;
956
1668
  validFrom?: string | null | undefined;
957
1669
  validTo?: string | null | undefined;
958
- state?: "current" | "conflicted" | undefined;
1670
+ title?: string | null | undefined;
1671
+ topicTags?: string[] | undefined;
1672
+ language?: string | null | undefined;
959
1673
  }, {
960
- metadata?: Record<string, unknown> | undefined;
1674
+ reason: string;
1675
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
1676
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
1677
+ sensitivityClass: "standard" | "personal" | "restricted" | "secret";
1678
+ disposition: "keep" | "correct" | "convert_to_episode" | "restrict";
1679
+ salience: "low" | "medium" | "high";
1680
+ evidenceConfidence: "low" | "medium" | "high";
1681
+ actorEntity: {
1682
+ canonicalKey: string;
1683
+ entityType: string;
1684
+ displayName?: string | null | undefined;
1685
+ attributes?: Record<string, unknown> | undefined;
1686
+ };
1687
+ subjectEntity: {
1688
+ canonicalKey: string;
1689
+ entityType: string;
1690
+ displayName?: string | null | undefined;
1691
+ attributes?: Record<string, unknown> | undefined;
1692
+ };
961
1693
  content?: string | undefined;
962
- reason?: string | undefined;
1694
+ validFrom?: string | null | undefined;
1695
+ validTo?: string | null | undefined;
963
1696
  title?: string | null | undefined;
964
- memoryType?: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact" | undefined;
965
- sensitivityClass?: "standard" | "personal" | "restricted" | "secret" | undefined;
966
1697
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
967
1698
  topicTags?: string[] | undefined;
968
1699
  language?: string | null | undefined;
1700
+ }>, {
1701
+ reason: string;
1702
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
1703
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
1704
+ sensitivityClass: "standard" | "personal" | "restricted" | "secret";
1705
+ restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
1706
+ disposition: "keep" | "correct" | "convert_to_episode" | "restrict";
1707
+ salience: "low" | "medium" | "high";
1708
+ evidenceConfidence: "low" | "medium" | "high";
1709
+ actorEntity: {
1710
+ canonicalKey: string;
1711
+ entityType: string;
1712
+ attributes: Record<string, unknown>;
1713
+ displayName?: string | null | undefined;
1714
+ };
1715
+ subjectEntity: {
1716
+ canonicalKey: string;
1717
+ entityType: string;
1718
+ attributes: Record<string, unknown>;
1719
+ displayName?: string | null | undefined;
1720
+ };
1721
+ content?: string | undefined;
969
1722
  validFrom?: string | null | undefined;
970
1723
  validTo?: string | null | undefined;
971
- state?: "current" | "conflicted" | undefined;
1724
+ title?: string | null | undefined;
1725
+ topicTags?: string[] | undefined;
1726
+ language?: string | null | undefined;
1727
+ }, {
1728
+ reason: string;
1729
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
1730
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
1731
+ sensitivityClass: "standard" | "personal" | "restricted" | "secret";
1732
+ disposition: "keep" | "correct" | "convert_to_episode" | "restrict";
1733
+ salience: "low" | "medium" | "high";
1734
+ evidenceConfidence: "low" | "medium" | "high";
1735
+ actorEntity: {
1736
+ canonicalKey: string;
1737
+ entityType: string;
1738
+ displayName?: string | null | undefined;
1739
+ attributes?: Record<string, unknown> | undefined;
1740
+ };
1741
+ subjectEntity: {
1742
+ canonicalKey: string;
1743
+ entityType: string;
1744
+ displayName?: string | null | undefined;
1745
+ attributes?: Record<string, unknown> | undefined;
1746
+ };
1747
+ content?: string | undefined;
1748
+ validFrom?: string | null | undefined;
1749
+ validTo?: string | null | undefined;
1750
+ title?: string | null | undefined;
1751
+ restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
1752
+ topicTags?: string[] | undefined;
1753
+ language?: string | null | undefined;
972
1754
  }>;
973
- export type MemoryRecordUpdateInput = z.infer<typeof memoryRecordUpdateInputSchema>;
1755
+ export type MemoryRecordQualityReviewInput = z.infer<typeof memoryRecordQualityReviewInputSchema>;
974
1756
  export declare const memoryForgetInputSchema: z.ZodObject<{
975
1757
  reason: z.ZodOptional<z.ZodString>;
976
1758
  }, "strip", z.ZodTypeAny, {
@@ -986,10 +1768,10 @@ export declare const memoryBlockInputSchema: z.ZodEffects<z.ZodObject<{
986
1768
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
987
1769
  externalId: z.ZodString;
988
1770
  }, "strict", z.ZodTypeAny, {
989
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1771
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
990
1772
  externalId: string;
991
1773
  }, {
992
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1774
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
993
1775
  externalId: string;
994
1776
  }>, "many">>;
995
1777
  title: z.ZodString;
@@ -999,60 +1781,60 @@ export declare const memoryBlockInputSchema: z.ZodEffects<z.ZodObject<{
999
1781
  required: z.ZodDefault<z.ZodBoolean>;
1000
1782
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1001
1783
  }, "strip", z.ZodTypeAny, {
1002
- required: boolean;
1003
1784
  metadata: Record<string, unknown>;
1004
1785
  content: string;
1005
- title: string;
1006
1786
  access: "read_only" | "editable";
1787
+ required: boolean;
1788
+ title: string;
1007
1789
  priority: number;
1008
1790
  tenantId?: string | undefined;
1009
1791
  sessionId?: string | undefined;
1010
1792
  externalTenantId?: string | undefined;
1011
1793
  subjects?: {
1012
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1794
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1013
1795
  externalId: string;
1014
1796
  }[] | undefined;
1015
1797
  }, {
1016
1798
  content: string;
1017
1799
  title: string;
1018
- required?: boolean | undefined;
1019
- metadata?: Record<string, unknown> | undefined;
1020
1800
  tenantId?: string | undefined;
1021
1801
  sessionId?: string | undefined;
1802
+ metadata?: Record<string, unknown> | undefined;
1803
+ access?: "read_only" | "editable" | undefined;
1804
+ required?: boolean | undefined;
1022
1805
  externalTenantId?: string | undefined;
1023
1806
  subjects?: {
1024
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1807
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1025
1808
  externalId: string;
1026
1809
  }[] | undefined;
1027
- access?: "read_only" | "editable" | undefined;
1028
1810
  priority?: number | undefined;
1029
1811
  }>, {
1030
- required: boolean;
1031
1812
  metadata: Record<string, unknown>;
1032
1813
  content: string;
1033
- title: string;
1034
1814
  access: "read_only" | "editable";
1815
+ required: boolean;
1816
+ title: string;
1035
1817
  priority: number;
1036
1818
  tenantId?: string | undefined;
1037
1819
  sessionId?: string | undefined;
1038
1820
  externalTenantId?: string | undefined;
1039
1821
  subjects?: {
1040
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1822
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1041
1823
  externalId: string;
1042
1824
  }[] | undefined;
1043
1825
  }, {
1044
1826
  content: string;
1045
1827
  title: string;
1046
- required?: boolean | undefined;
1047
- metadata?: Record<string, unknown> | undefined;
1048
1828
  tenantId?: string | undefined;
1049
1829
  sessionId?: string | undefined;
1830
+ metadata?: Record<string, unknown> | undefined;
1831
+ access?: "read_only" | "editable" | undefined;
1832
+ required?: boolean | undefined;
1050
1833
  externalTenantId?: string | undefined;
1051
1834
  subjects?: {
1052
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1835
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1053
1836
  externalId: string;
1054
1837
  }[] | undefined;
1055
- access?: "read_only" | "editable" | undefined;
1056
1838
  priority?: number | undefined;
1057
1839
  }>;
1058
1840
  export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
@@ -1081,10 +1863,10 @@ export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
1081
1863
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
1082
1864
  externalId: z.ZodString;
1083
1865
  }, "strict", z.ZodTypeAny, {
1084
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1866
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1085
1867
  externalId: string;
1086
1868
  }, {
1087
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1869
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1088
1870
  externalId: string;
1089
1871
  }>, "many">;
1090
1872
  policyKey: z.ZodDefault<z.ZodString>;
@@ -1095,12 +1877,12 @@ export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
1095
1877
  reference: z.ZodOptional<z.ZodString>;
1096
1878
  }, "strict", z.ZodTypeAny, {
1097
1879
  status: "granted";
1098
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1880
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1099
1881
  recordedAt: string;
1100
1882
  reference?: string | undefined;
1101
1883
  }, {
1102
1884
  status: "granted";
1103
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1885
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1104
1886
  recordedAt: string;
1105
1887
  reference?: string | undefined;
1106
1888
  }>>;
@@ -1116,14 +1898,14 @@ export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
1116
1898
  metadata: Record<string, unknown>;
1117
1899
  policyKey: string;
1118
1900
  targets: {
1119
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1901
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1120
1902
  externalId: string;
1121
1903
  }[];
1122
1904
  tenantId?: string | undefined;
1123
1905
  externalTenantId?: string | undefined;
1124
1906
  consent?: {
1125
1907
  status: "granted";
1126
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1908
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1127
1909
  recordedAt: string;
1128
1910
  reference?: string | undefined;
1129
1911
  } | undefined;
@@ -1136,16 +1918,16 @@ export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
1136
1918
  artifactIds?: string[] | undefined;
1137
1919
  };
1138
1920
  targets: {
1139
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1921
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1140
1922
  externalId: string;
1141
1923
  }[];
1142
- metadata?: Record<string, unknown> | undefined;
1143
1924
  tenantId?: string | undefined;
1925
+ metadata?: Record<string, unknown> | undefined;
1144
1926
  externalTenantId?: string | undefined;
1145
1927
  policyKey?: string | undefined;
1146
1928
  consent?: {
1147
1929
  status: "granted";
1148
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1930
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1149
1931
  recordedAt: string;
1150
1932
  reference?: string | undefined;
1151
1933
  } | undefined;
@@ -1160,14 +1942,14 @@ export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
1160
1942
  metadata: Record<string, unknown>;
1161
1943
  policyKey: string;
1162
1944
  targets: {
1163
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1945
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1164
1946
  externalId: string;
1165
1947
  }[];
1166
1948
  tenantId?: string | undefined;
1167
1949
  externalTenantId?: string | undefined;
1168
1950
  consent?: {
1169
1951
  status: "granted";
1170
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1952
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1171
1953
  recordedAt: string;
1172
1954
  reference?: string | undefined;
1173
1955
  } | undefined;
@@ -1180,16 +1962,16 @@ export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
1180
1962
  artifactIds?: string[] | undefined;
1181
1963
  };
1182
1964
  targets: {
1183
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1965
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1184
1966
  externalId: string;
1185
1967
  }[];
1186
- metadata?: Record<string, unknown> | undefined;
1187
1968
  tenantId?: string | undefined;
1969
+ metadata?: Record<string, unknown> | undefined;
1188
1970
  externalTenantId?: string | undefined;
1189
1971
  policyKey?: string | undefined;
1190
1972
  consent?: {
1191
1973
  status: "granted";
1192
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
1974
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1193
1975
  recordedAt: string;
1194
1976
  reference?: string | undefined;
1195
1977
  } | undefined;
@@ -1197,6 +1979,7 @@ export declare const memorySourceBindingInputSchema: z.ZodEffects<z.ZodObject<{
1197
1979
  export type MemorySourceBindingInput = z.input<typeof memorySourceBindingInputSchema>;
1198
1980
  export declare const memoryConnectedSourceBackfillRangeSchema: z.ZodEnum<["future_only", "last_30_days", "last_90_days", "all"]>;
1199
1981
  export declare const memoryConnectedSourceInputSchema: z.ZodEffects<z.ZodObject<{
1982
+ sessionId: z.ZodOptional<z.ZodString>;
1200
1983
  idempotencyKey: z.ZodString;
1201
1984
  tenantId: z.ZodOptional<z.ZodString>;
1202
1985
  externalTenantId: z.ZodOptional<z.ZodString>;
@@ -1208,19 +1991,30 @@ export declare const memoryConnectedSourceInputSchema: z.ZodEffects<z.ZodObject<
1208
1991
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
1209
1992
  externalId: z.ZodString;
1210
1993
  }, "strict", z.ZodTypeAny, {
1211
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1994
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1212
1995
  externalId: string;
1213
1996
  }, {
1214
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
1997
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1215
1998
  externalId: string;
1216
1999
  }>, "many">;
1217
2000
  existingContent: z.ZodDefault<z.ZodEnum<["future_only", "last_30_days", "last_90_days", "all"]>>;
1218
2001
  maxBackfillItems: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
1219
2002
  deliveryMode: z.ZodDefault<z.ZodEnum<["auto", "webhook", "polling"]>>;
2003
+ authorizationPerspective: z.ZodDefault<z.ZodEnum<["provider_default", "bot", "user"]>>;
2004
+ includeAttachments: z.ZodDefault<z.ZodBoolean>;
2005
+ includeFileContent: z.ZodDefault<z.ZodBoolean>;
2006
+ includeEmailBodies: z.ZodDefault<z.ZodBoolean>;
2007
+ includeConversationTranscripts: z.ZodDefault<z.ZodBoolean>;
2008
+ includeCallActivity: z.ZodDefault<z.ZodBoolean>;
2009
+ includePrivateConversations: z.ZodDefault<z.ZodBoolean>;
2010
+ includeExternalConversations: z.ZodDefault<z.ZodBoolean>;
2011
+ includeBotMessages: z.ZodDefault<z.ZodBoolean>;
2012
+ approvedOperationalActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
2013
+ excludedActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
1220
2014
  rememberInstructions: z.ZodDefault<z.ZodString>;
1221
2015
  excludeInstructions: z.ZodDefault<z.ZodString>;
1222
2016
  allowedMemoryTypes: z.ZodDefault<z.ZodArray<z.ZodEnum<["preference", "decision", "commitment", "goal", "constraint", "relationship", "durable_fact"]>, "many">>;
1223
- learnedRetentionDays: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
2017
+ learnedRetentionDays: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
1224
2018
  sourceRetentionDays: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
1225
2019
  consent: z.ZodOptional<z.ZodObject<{
1226
2020
  status: z.ZodLiteral<"granted">;
@@ -1229,12 +2023,12 @@ export declare const memoryConnectedSourceInputSchema: z.ZodEffects<z.ZodObject<
1229
2023
  reference: z.ZodOptional<z.ZodString>;
1230
2024
  }, "strict", z.ZodTypeAny, {
1231
2025
  status: "granted";
1232
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2026
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1233
2027
  recordedAt: string;
1234
2028
  reference?: string | undefined;
1235
2029
  }, {
1236
2030
  status: "granted";
1237
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2031
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1238
2032
  recordedAt: string;
1239
2033
  reference?: string | undefined;
1240
2034
  }>>;
@@ -1242,147 +2036,255 @@ export declare const memoryConnectedSourceInputSchema: z.ZodEffects<z.ZodObject<
1242
2036
  }, "strict", z.ZodTypeAny, {
1243
2037
  metadata: Record<string, unknown>;
1244
2038
  idempotencyKey: string;
2039
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1245
2040
  connectedAccountId: string;
1246
2041
  resourceIds: string[];
1247
2042
  targets: {
1248
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2043
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1249
2044
  externalId: string;
1250
2045
  }[];
2046
+ approvedOperationalActorCanonicalKeys: string[];
1251
2047
  sourceFamilyKey: string;
1252
2048
  selectionMode: "selected_resources" | "recipe_default";
1253
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2049
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
1254
2050
  maxBackfillItems: number | null;
1255
- deliveryMode: "auto" | "webhook" | "polling";
2051
+ deliveryMode: "webhook" | "auto" | "polling";
2052
+ authorizationPerspective: "bot" | "user" | "provider_default";
2053
+ includeAttachments: boolean;
2054
+ includeFileContent: boolean;
2055
+ includeEmailBodies: boolean;
2056
+ includeConversationTranscripts: boolean;
2057
+ includeCallActivity: boolean;
2058
+ includePrivateConversations: boolean;
2059
+ includeExternalConversations: boolean;
2060
+ includeBotMessages: boolean;
2061
+ excludedActorCanonicalKeys: string[];
1256
2062
  rememberInstructions: string;
1257
2063
  excludeInstructions: string;
1258
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1259
- learnedRetentionDays: number | null;
1260
2064
  sourceRetentionDays: number | null;
1261
2065
  tenantId?: string | undefined;
2066
+ sessionId?: string | undefined;
1262
2067
  externalTenantId?: string | undefined;
1263
2068
  consent?: {
1264
2069
  status: "granted";
1265
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2070
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1266
2071
  recordedAt: string;
1267
2072
  reference?: string | undefined;
1268
2073
  } | undefined;
2074
+ learnedRetentionDays?: number | null | undefined;
1269
2075
  }, {
1270
2076
  idempotencyKey: string;
1271
2077
  connectedAccountId: string;
1272
2078
  targets: {
1273
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2079
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1274
2080
  externalId: string;
1275
2081
  }[];
1276
2082
  sourceFamilyKey: string;
1277
- metadata?: Record<string, unknown> | undefined;
1278
2083
  tenantId?: string | undefined;
2084
+ sessionId?: string | undefined;
2085
+ metadata?: Record<string, unknown> | undefined;
2086
+ allowedMemoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1279
2087
  externalTenantId?: string | undefined;
1280
2088
  consent?: {
1281
2089
  status: "granted";
1282
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2090
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1283
2091
  recordedAt: string;
1284
2092
  reference?: string | undefined;
1285
2093
  } | undefined;
1286
2094
  resourceIds?: string[] | undefined;
2095
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
1287
2096
  selectionMode?: "selected_resources" | "recipe_default" | undefined;
1288
- existingContent?: "future_only" | "last_30_days" | "last_90_days" | "all" | undefined;
2097
+ existingContent?: "all" | "future_only" | "last_30_days" | "last_90_days" | undefined;
1289
2098
  maxBackfillItems?: number | null | undefined;
1290
- deliveryMode?: "auto" | "webhook" | "polling" | undefined;
2099
+ deliveryMode?: "webhook" | "auto" | "polling" | undefined;
2100
+ authorizationPerspective?: "bot" | "user" | "provider_default" | undefined;
2101
+ includeAttachments?: boolean | undefined;
2102
+ includeFileContent?: boolean | undefined;
2103
+ includeEmailBodies?: boolean | undefined;
2104
+ includeConversationTranscripts?: boolean | undefined;
2105
+ includeCallActivity?: boolean | undefined;
2106
+ includePrivateConversations?: boolean | undefined;
2107
+ includeExternalConversations?: boolean | undefined;
2108
+ includeBotMessages?: boolean | undefined;
2109
+ excludedActorCanonicalKeys?: string[] | undefined;
1291
2110
  rememberInstructions?: string | undefined;
1292
2111
  excludeInstructions?: string | undefined;
1293
- allowedMemoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1294
2112
  learnedRetentionDays?: number | null | undefined;
1295
2113
  sourceRetentionDays?: number | null | undefined;
1296
2114
  }>, {
1297
2115
  metadata: Record<string, unknown>;
1298
2116
  idempotencyKey: string;
2117
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1299
2118
  connectedAccountId: string;
1300
2119
  resourceIds: string[];
1301
2120
  targets: {
1302
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2121
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1303
2122
  externalId: string;
1304
2123
  }[];
2124
+ approvedOperationalActorCanonicalKeys: string[];
1305
2125
  sourceFamilyKey: string;
1306
2126
  selectionMode: "selected_resources" | "recipe_default";
1307
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2127
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
1308
2128
  maxBackfillItems: number | null;
1309
- deliveryMode: "auto" | "webhook" | "polling";
2129
+ deliveryMode: "webhook" | "auto" | "polling";
2130
+ authorizationPerspective: "bot" | "user" | "provider_default";
2131
+ includeAttachments: boolean;
2132
+ includeFileContent: boolean;
2133
+ includeEmailBodies: boolean;
2134
+ includeConversationTranscripts: boolean;
2135
+ includeCallActivity: boolean;
2136
+ includePrivateConversations: boolean;
2137
+ includeExternalConversations: boolean;
2138
+ includeBotMessages: boolean;
2139
+ excludedActorCanonicalKeys: string[];
1310
2140
  rememberInstructions: string;
1311
2141
  excludeInstructions: string;
1312
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1313
- learnedRetentionDays: number | null;
1314
2142
  sourceRetentionDays: number | null;
1315
2143
  tenantId?: string | undefined;
2144
+ sessionId?: string | undefined;
1316
2145
  externalTenantId?: string | undefined;
1317
2146
  consent?: {
1318
2147
  status: "granted";
1319
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2148
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1320
2149
  recordedAt: string;
1321
2150
  reference?: string | undefined;
1322
2151
  } | undefined;
2152
+ learnedRetentionDays?: number | null | undefined;
1323
2153
  }, {
1324
2154
  idempotencyKey: string;
1325
2155
  connectedAccountId: string;
1326
2156
  targets: {
1327
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2157
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1328
2158
  externalId: string;
1329
2159
  }[];
1330
2160
  sourceFamilyKey: string;
1331
- metadata?: Record<string, unknown> | undefined;
1332
2161
  tenantId?: string | undefined;
2162
+ sessionId?: string | undefined;
2163
+ metadata?: Record<string, unknown> | undefined;
2164
+ allowedMemoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1333
2165
  externalTenantId?: string | undefined;
1334
2166
  consent?: {
1335
2167
  status: "granted";
1336
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2168
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1337
2169
  recordedAt: string;
1338
2170
  reference?: string | undefined;
1339
2171
  } | undefined;
1340
2172
  resourceIds?: string[] | undefined;
2173
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
1341
2174
  selectionMode?: "selected_resources" | "recipe_default" | undefined;
1342
- existingContent?: "future_only" | "last_30_days" | "last_90_days" | "all" | undefined;
2175
+ existingContent?: "all" | "future_only" | "last_30_days" | "last_90_days" | undefined;
1343
2176
  maxBackfillItems?: number | null | undefined;
1344
- deliveryMode?: "auto" | "webhook" | "polling" | undefined;
2177
+ deliveryMode?: "webhook" | "auto" | "polling" | undefined;
2178
+ authorizationPerspective?: "bot" | "user" | "provider_default" | undefined;
2179
+ includeAttachments?: boolean | undefined;
2180
+ includeFileContent?: boolean | undefined;
2181
+ includeEmailBodies?: boolean | undefined;
2182
+ includeConversationTranscripts?: boolean | undefined;
2183
+ includeCallActivity?: boolean | undefined;
2184
+ includePrivateConversations?: boolean | undefined;
2185
+ includeExternalConversations?: boolean | undefined;
2186
+ includeBotMessages?: boolean | undefined;
2187
+ excludedActorCanonicalKeys?: string[] | undefined;
1345
2188
  rememberInstructions?: string | undefined;
1346
2189
  excludeInstructions?: string | undefined;
1347
- allowedMemoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1348
2190
  learnedRetentionDays?: number | null | undefined;
1349
2191
  sourceRetentionDays?: number | null | undefined;
1350
2192
  }>;
1351
2193
  export declare const memoryConnectedSourcePreviewInputSchema: z.ZodEffects<z.ZodObject<{
2194
+ sessionId: z.ZodOptional<z.ZodString>;
1352
2195
  tenantId: z.ZodOptional<z.ZodString>;
1353
2196
  externalTenantId: z.ZodOptional<z.ZodString>;
1354
2197
  connectedAccountId: z.ZodString;
1355
2198
  sourceFamilyKey: z.ZodString;
1356
2199
  resourceIds: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
1357
2200
  existingContent: z.ZodDefault<z.ZodEnum<["future_only", "last_30_days", "last_90_days", "all"]>>;
2201
+ authorizationPerspective: z.ZodDefault<z.ZodEnum<["provider_default", "bot", "user"]>>;
2202
+ includeAttachments: z.ZodDefault<z.ZodBoolean>;
2203
+ includeFileContent: z.ZodDefault<z.ZodBoolean>;
2204
+ includeEmailBodies: z.ZodDefault<z.ZodBoolean>;
2205
+ includeConversationTranscripts: z.ZodDefault<z.ZodBoolean>;
2206
+ includeCallActivity: z.ZodDefault<z.ZodBoolean>;
2207
+ includePrivateConversations: z.ZodDefault<z.ZodBoolean>;
2208
+ includeExternalConversations: z.ZodDefault<z.ZodBoolean>;
2209
+ includeBotMessages: z.ZodDefault<z.ZodBoolean>;
2210
+ approvedOperationalActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
2211
+ excludedActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
1358
2212
  }, "strict", z.ZodTypeAny, {
1359
2213
  connectedAccountId: string;
1360
2214
  resourceIds: string[];
2215
+ approvedOperationalActorCanonicalKeys: string[];
1361
2216
  sourceFamilyKey: string;
1362
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2217
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
2218
+ authorizationPerspective: "bot" | "user" | "provider_default";
2219
+ includeAttachments: boolean;
2220
+ includeFileContent: boolean;
2221
+ includeEmailBodies: boolean;
2222
+ includeConversationTranscripts: boolean;
2223
+ includeCallActivity: boolean;
2224
+ includePrivateConversations: boolean;
2225
+ includeExternalConversations: boolean;
2226
+ includeBotMessages: boolean;
2227
+ excludedActorCanonicalKeys: string[];
1363
2228
  tenantId?: string | undefined;
2229
+ sessionId?: string | undefined;
1364
2230
  externalTenantId?: string | undefined;
1365
2231
  }, {
1366
2232
  connectedAccountId: string;
1367
2233
  sourceFamilyKey: string;
1368
2234
  tenantId?: string | undefined;
2235
+ sessionId?: string | undefined;
1369
2236
  externalTenantId?: string | undefined;
1370
2237
  resourceIds?: string[] | undefined;
1371
- existingContent?: "future_only" | "last_30_days" | "last_90_days" | "all" | undefined;
2238
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
2239
+ existingContent?: "all" | "future_only" | "last_30_days" | "last_90_days" | undefined;
2240
+ authorizationPerspective?: "bot" | "user" | "provider_default" | undefined;
2241
+ includeAttachments?: boolean | undefined;
2242
+ includeFileContent?: boolean | undefined;
2243
+ includeEmailBodies?: boolean | undefined;
2244
+ includeConversationTranscripts?: boolean | undefined;
2245
+ includeCallActivity?: boolean | undefined;
2246
+ includePrivateConversations?: boolean | undefined;
2247
+ includeExternalConversations?: boolean | undefined;
2248
+ includeBotMessages?: boolean | undefined;
2249
+ excludedActorCanonicalKeys?: string[] | undefined;
1372
2250
  }>, {
1373
2251
  connectedAccountId: string;
1374
2252
  resourceIds: string[];
2253
+ approvedOperationalActorCanonicalKeys: string[];
1375
2254
  sourceFamilyKey: string;
1376
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2255
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
2256
+ authorizationPerspective: "bot" | "user" | "provider_default";
2257
+ includeAttachments: boolean;
2258
+ includeFileContent: boolean;
2259
+ includeEmailBodies: boolean;
2260
+ includeConversationTranscripts: boolean;
2261
+ includeCallActivity: boolean;
2262
+ includePrivateConversations: boolean;
2263
+ includeExternalConversations: boolean;
2264
+ includeBotMessages: boolean;
2265
+ excludedActorCanonicalKeys: string[];
1377
2266
  tenantId?: string | undefined;
2267
+ sessionId?: string | undefined;
1378
2268
  externalTenantId?: string | undefined;
1379
2269
  }, {
1380
2270
  connectedAccountId: string;
1381
2271
  sourceFamilyKey: string;
1382
2272
  tenantId?: string | undefined;
2273
+ sessionId?: string | undefined;
1383
2274
  externalTenantId?: string | undefined;
1384
2275
  resourceIds?: string[] | undefined;
1385
- existingContent?: "future_only" | "last_30_days" | "last_90_days" | "all" | undefined;
2276
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
2277
+ existingContent?: "all" | "future_only" | "last_30_days" | "last_90_days" | undefined;
2278
+ authorizationPerspective?: "bot" | "user" | "provider_default" | undefined;
2279
+ includeAttachments?: boolean | undefined;
2280
+ includeFileContent?: boolean | undefined;
2281
+ includeEmailBodies?: boolean | undefined;
2282
+ includeConversationTranscripts?: boolean | undefined;
2283
+ includeCallActivity?: boolean | undefined;
2284
+ includePrivateConversations?: boolean | undefined;
2285
+ includeExternalConversations?: boolean | undefined;
2286
+ includeBotMessages?: boolean | undefined;
2287
+ excludedActorCanonicalKeys?: string[] | undefined;
1386
2288
  }>;
1387
2289
  export declare const memoryConnectedSourceSettingsInputSchema: z.ZodObject<{
1388
2290
  resourceIds: z.ZodArray<z.ZodString, "many">;
@@ -1390,42 +2292,72 @@ export declare const memoryConnectedSourceSettingsInputSchema: z.ZodObject<{
1390
2292
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
1391
2293
  externalId: z.ZodString;
1392
2294
  }, "strict", z.ZodTypeAny, {
1393
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2295
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1394
2296
  externalId: string;
1395
2297
  }, {
1396
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2298
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1397
2299
  externalId: string;
1398
2300
  }>, "many">;
1399
2301
  existingContent: z.ZodEnum<["future_only", "last_30_days", "last_90_days", "all"]>;
2302
+ includeAttachments: z.ZodDefault<z.ZodBoolean>;
2303
+ includeFileContent: z.ZodDefault<z.ZodBoolean>;
2304
+ includeEmailBodies: z.ZodDefault<z.ZodBoolean>;
2305
+ includeConversationTranscripts: z.ZodDefault<z.ZodBoolean>;
2306
+ includeCallActivity: z.ZodDefault<z.ZodBoolean>;
2307
+ includePrivateConversations: z.ZodDefault<z.ZodBoolean>;
2308
+ includeExternalConversations: z.ZodDefault<z.ZodBoolean>;
2309
+ includeBotMessages: z.ZodDefault<z.ZodBoolean>;
2310
+ approvedOperationalActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
2311
+ excludedActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
1400
2312
  rememberInstructions: z.ZodString;
1401
2313
  excludeInstructions: z.ZodString;
1402
2314
  allowedMemoryTypes: z.ZodArray<z.ZodEnum<["preference", "decision", "commitment", "goal", "constraint", "relationship", "durable_fact"]>, "many">;
1403
2315
  learnedRetentionDays: z.ZodNullable<z.ZodNumber>;
1404
2316
  sourceRetentionDays: z.ZodNullable<z.ZodNumber>;
1405
2317
  }, "strict", z.ZodTypeAny, {
2318
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1406
2319
  resourceIds: string[];
1407
2320
  targets: {
1408
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2321
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1409
2322
  externalId: string;
1410
2323
  }[];
1411
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2324
+ approvedOperationalActorCanonicalKeys: string[];
2325
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
2326
+ includeAttachments: boolean;
2327
+ includeFileContent: boolean;
2328
+ includeEmailBodies: boolean;
2329
+ includeConversationTranscripts: boolean;
2330
+ includeCallActivity: boolean;
2331
+ includePrivateConversations: boolean;
2332
+ includeExternalConversations: boolean;
2333
+ includeBotMessages: boolean;
2334
+ excludedActorCanonicalKeys: string[];
1412
2335
  rememberInstructions: string;
1413
2336
  excludeInstructions: string;
1414
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1415
2337
  learnedRetentionDays: number | null;
1416
2338
  sourceRetentionDays: number | null;
1417
2339
  }, {
2340
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1418
2341
  resourceIds: string[];
1419
2342
  targets: {
1420
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2343
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1421
2344
  externalId: string;
1422
2345
  }[];
1423
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2346
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
1424
2347
  rememberInstructions: string;
1425
2348
  excludeInstructions: string;
1426
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1427
2349
  learnedRetentionDays: number | null;
1428
2350
  sourceRetentionDays: number | null;
2351
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
2352
+ includeAttachments?: boolean | undefined;
2353
+ includeFileContent?: boolean | undefined;
2354
+ includeEmailBodies?: boolean | undefined;
2355
+ includeConversationTranscripts?: boolean | undefined;
2356
+ includeCallActivity?: boolean | undefined;
2357
+ includePrivateConversations?: boolean | undefined;
2358
+ includeExternalConversations?: boolean | undefined;
2359
+ includeBotMessages?: boolean | undefined;
2360
+ excludedActorCanonicalKeys?: string[] | undefined;
1429
2361
  }>;
1430
2362
  export declare const memorySourceBindingUpdateInputSchema: z.ZodEffects<z.ZodObject<{
1431
2363
  status: z.ZodOptional<z.ZodEnum<["active", "paused"]>>;
@@ -1435,108 +2367,186 @@ export declare const memorySourceBindingUpdateInputSchema: z.ZodEffects<z.ZodObj
1435
2367
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
1436
2368
  externalId: z.ZodString;
1437
2369
  }, "strict", z.ZodTypeAny, {
1438
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2370
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1439
2371
  externalId: string;
1440
2372
  }, {
1441
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2373
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1442
2374
  externalId: string;
1443
2375
  }>, "many">;
1444
2376
  existingContent: z.ZodEnum<["future_only", "last_30_days", "last_90_days", "all"]>;
2377
+ includeAttachments: z.ZodDefault<z.ZodBoolean>;
2378
+ includeFileContent: z.ZodDefault<z.ZodBoolean>;
2379
+ includeEmailBodies: z.ZodDefault<z.ZodBoolean>;
2380
+ includeConversationTranscripts: z.ZodDefault<z.ZodBoolean>;
2381
+ includeCallActivity: z.ZodDefault<z.ZodBoolean>;
2382
+ includePrivateConversations: z.ZodDefault<z.ZodBoolean>;
2383
+ includeExternalConversations: z.ZodDefault<z.ZodBoolean>;
2384
+ includeBotMessages: z.ZodDefault<z.ZodBoolean>;
2385
+ approvedOperationalActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
2386
+ excludedActorCanonicalKeys: z.ZodDefault<z.ZodArray<z.ZodString, "many">>;
1445
2387
  rememberInstructions: z.ZodString;
1446
2388
  excludeInstructions: z.ZodString;
1447
2389
  allowedMemoryTypes: z.ZodArray<z.ZodEnum<["preference", "decision", "commitment", "goal", "constraint", "relationship", "durable_fact"]>, "many">;
1448
2390
  learnedRetentionDays: z.ZodNullable<z.ZodNumber>;
1449
2391
  sourceRetentionDays: z.ZodNullable<z.ZodNumber>;
1450
2392
  }, "strict", z.ZodTypeAny, {
2393
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1451
2394
  resourceIds: string[];
1452
2395
  targets: {
1453
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2396
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1454
2397
  externalId: string;
1455
2398
  }[];
1456
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2399
+ approvedOperationalActorCanonicalKeys: string[];
2400
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
2401
+ includeAttachments: boolean;
2402
+ includeFileContent: boolean;
2403
+ includeEmailBodies: boolean;
2404
+ includeConversationTranscripts: boolean;
2405
+ includeCallActivity: boolean;
2406
+ includePrivateConversations: boolean;
2407
+ includeExternalConversations: boolean;
2408
+ includeBotMessages: boolean;
2409
+ excludedActorCanonicalKeys: string[];
1457
2410
  rememberInstructions: string;
1458
2411
  excludeInstructions: string;
1459
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1460
2412
  learnedRetentionDays: number | null;
1461
2413
  sourceRetentionDays: number | null;
1462
2414
  }, {
2415
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1463
2416
  resourceIds: string[];
1464
2417
  targets: {
1465
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2418
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1466
2419
  externalId: string;
1467
2420
  }[];
1468
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2421
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
1469
2422
  rememberInstructions: string;
1470
2423
  excludeInstructions: string;
1471
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1472
2424
  learnedRetentionDays: number | null;
1473
2425
  sourceRetentionDays: number | null;
2426
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
2427
+ includeAttachments?: boolean | undefined;
2428
+ includeFileContent?: boolean | undefined;
2429
+ includeEmailBodies?: boolean | undefined;
2430
+ includeConversationTranscripts?: boolean | undefined;
2431
+ includeCallActivity?: boolean | undefined;
2432
+ includePrivateConversations?: boolean | undefined;
2433
+ includeExternalConversations?: boolean | undefined;
2434
+ includeBotMessages?: boolean | undefined;
2435
+ excludedActorCanonicalKeys?: string[] | undefined;
1474
2436
  }>>;
1475
2437
  }, "strict", z.ZodTypeAny, {
1476
- status?: "active" | "paused" | undefined;
2438
+ status?: "paused" | "active" | undefined;
1477
2439
  connectedSource?: {
2440
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1478
2441
  resourceIds: string[];
1479
2442
  targets: {
1480
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2443
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1481
2444
  externalId: string;
1482
2445
  }[];
1483
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2446
+ approvedOperationalActorCanonicalKeys: string[];
2447
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
2448
+ includeAttachments: boolean;
2449
+ includeFileContent: boolean;
2450
+ includeEmailBodies: boolean;
2451
+ includeConversationTranscripts: boolean;
2452
+ includeCallActivity: boolean;
2453
+ includePrivateConversations: boolean;
2454
+ includeExternalConversations: boolean;
2455
+ includeBotMessages: boolean;
2456
+ excludedActorCanonicalKeys: string[];
1484
2457
  rememberInstructions: string;
1485
2458
  excludeInstructions: string;
1486
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1487
2459
  learnedRetentionDays: number | null;
1488
2460
  sourceRetentionDays: number | null;
1489
2461
  } | undefined;
1490
2462
  }, {
1491
- status?: "active" | "paused" | undefined;
2463
+ status?: "paused" | "active" | undefined;
1492
2464
  connectedSource?: {
2465
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1493
2466
  resourceIds: string[];
1494
2467
  targets: {
1495
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2468
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1496
2469
  externalId: string;
1497
2470
  }[];
1498
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2471
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
1499
2472
  rememberInstructions: string;
1500
2473
  excludeInstructions: string;
1501
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1502
2474
  learnedRetentionDays: number | null;
1503
2475
  sourceRetentionDays: number | null;
2476
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
2477
+ includeAttachments?: boolean | undefined;
2478
+ includeFileContent?: boolean | undefined;
2479
+ includeEmailBodies?: boolean | undefined;
2480
+ includeConversationTranscripts?: boolean | undefined;
2481
+ includeCallActivity?: boolean | undefined;
2482
+ includePrivateConversations?: boolean | undefined;
2483
+ includeExternalConversations?: boolean | undefined;
2484
+ includeBotMessages?: boolean | undefined;
2485
+ excludedActorCanonicalKeys?: string[] | undefined;
1504
2486
  } | undefined;
1505
2487
  }>, {
1506
- status?: "active" | "paused" | undefined;
2488
+ status?: "paused" | "active" | undefined;
1507
2489
  connectedSource?: {
2490
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1508
2491
  resourceIds: string[];
1509
2492
  targets: {
1510
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2493
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1511
2494
  externalId: string;
1512
2495
  }[];
1513
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2496
+ approvedOperationalActorCanonicalKeys: string[];
2497
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
2498
+ includeAttachments: boolean;
2499
+ includeFileContent: boolean;
2500
+ includeEmailBodies: boolean;
2501
+ includeConversationTranscripts: boolean;
2502
+ includeCallActivity: boolean;
2503
+ includePrivateConversations: boolean;
2504
+ includeExternalConversations: boolean;
2505
+ includeBotMessages: boolean;
2506
+ excludedActorCanonicalKeys: string[];
1514
2507
  rememberInstructions: string;
1515
2508
  excludeInstructions: string;
1516
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1517
2509
  learnedRetentionDays: number | null;
1518
2510
  sourceRetentionDays: number | null;
1519
2511
  } | undefined;
1520
2512
  }, {
1521
- status?: "active" | "paused" | undefined;
2513
+ status?: "paused" | "active" | undefined;
1522
2514
  connectedSource?: {
2515
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1523
2516
  resourceIds: string[];
1524
2517
  targets: {
1525
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2518
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1526
2519
  externalId: string;
1527
2520
  }[];
1528
- existingContent: "future_only" | "last_30_days" | "last_90_days" | "all";
2521
+ existingContent: "all" | "future_only" | "last_30_days" | "last_90_days";
1529
2522
  rememberInstructions: string;
1530
2523
  excludeInstructions: string;
1531
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1532
2524
  learnedRetentionDays: number | null;
1533
2525
  sourceRetentionDays: number | null;
2526
+ approvedOperationalActorCanonicalKeys?: string[] | undefined;
2527
+ includeAttachments?: boolean | undefined;
2528
+ includeFileContent?: boolean | undefined;
2529
+ includeEmailBodies?: boolean | undefined;
2530
+ includeConversationTranscripts?: boolean | undefined;
2531
+ includeCallActivity?: boolean | undefined;
2532
+ includePrivateConversations?: boolean | undefined;
2533
+ includeExternalConversations?: boolean | undefined;
2534
+ includeBotMessages?: boolean | undefined;
2535
+ excludedActorCanonicalKeys?: string[] | undefined;
1534
2536
  } | undefined;
1535
2537
  }>;
1536
2538
  export type MemoryConnectedSourceInput = z.input<typeof memoryConnectedSourceInputSchema>;
1537
2539
  export type MemoryConnectedSourcePreviewInput = z.input<typeof memoryConnectedSourcePreviewInputSchema>;
1538
2540
  export type MemoryConnectedSourceSettingsInput = z.input<typeof memoryConnectedSourceSettingsInputSchema>;
1539
2541
  export type MemorySourceBindingUpdateInput = z.input<typeof memorySourceBindingUpdateInputSchema>;
2542
+ export declare const memorySourceRemovalInputSchema: z.ZodObject<{
2543
+ learnedRecords: z.ZodEnum<["retain", "forget", "erase"]>;
2544
+ }, "strict", z.ZodTypeAny, {
2545
+ learnedRecords: "retain" | "forget" | "erase";
2546
+ }, {
2547
+ learnedRecords: "retain" | "forget" | "erase";
2548
+ }>;
2549
+ export type MemorySourceRemovalInput = z.input<typeof memorySourceRemovalInputSchema>;
1540
2550
  export declare const memoryProcessSourceJobType = "memory_process_source";
1541
2551
  export declare const memoryNormalizeRichSourceJobType = "memory_normalize_rich_source";
1542
2552
  export declare const memoryRebuildProfileJobType = "memory_rebuild_profile";
@@ -1558,40 +2568,40 @@ export declare const memoryConversationTurnInputSchema: z.ZodObject<{
1558
2568
  reference: z.ZodOptional<z.ZodString>;
1559
2569
  }, "strict", z.ZodTypeAny, {
1560
2570
  status: "granted";
1561
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2571
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1562
2572
  recordedAt: string;
1563
2573
  reference?: string | undefined;
1564
2574
  }, {
1565
2575
  status: "granted";
1566
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2576
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1567
2577
  recordedAt: string;
1568
2578
  reference?: string | undefined;
1569
2579
  }>>;
1570
2580
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1571
2581
  }, "strict", z.ZodTypeAny, {
2582
+ sessionId: string;
1572
2583
  metadata: Record<string, unknown>;
1573
2584
  content: string;
1574
- sessionId: string;
1575
2585
  applicationKey: string;
1576
2586
  turnId: string;
1577
2587
  title?: string | undefined;
1578
2588
  consent?: {
1579
2589
  status: "granted";
1580
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2590
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1581
2591
  recordedAt: string;
1582
2592
  reference?: string | undefined;
1583
2593
  } | undefined;
1584
2594
  occurredAt?: string | undefined;
1585
2595
  }, {
1586
- content: string;
1587
2596
  sessionId: string;
2597
+ content: string;
1588
2598
  applicationKey: string;
1589
2599
  turnId: string;
1590
2600
  metadata?: Record<string, unknown> | undefined;
1591
2601
  title?: string | undefined;
1592
2602
  consent?: {
1593
2603
  status: "granted";
1594
- basis: "user_consent" | "contract" | "legitimate_interest" | "project_policy";
2604
+ basis: "contract" | "user_consent" | "legitimate_interest" | "project_policy";
1595
2605
  recordedAt: string;
1596
2606
  reference?: string | undefined;
1597
2607
  } | undefined;
@@ -1606,10 +2616,10 @@ export declare const memoryGraphQueryInputSchema: z.ZodEffects<z.ZodEffects<z.Zo
1606
2616
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
1607
2617
  externalId: z.ZodString;
1608
2618
  }, "strict", z.ZodTypeAny, {
1609
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2619
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1610
2620
  externalId: string;
1611
2621
  }, {
1612
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2622
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1613
2623
  externalId: string;
1614
2624
  }>, "many">>;
1615
2625
  kinds: z.ZodOptional<z.ZodArray<z.ZodEnum<["fact", "episode", "profile_item", "block"]>, "many">>;
@@ -1640,17 +2650,17 @@ export declare const memoryGraphQueryInputSchema: z.ZodEffects<z.ZodEffects<z.Zo
1640
2650
  seedRecordIds: string[];
1641
2651
  maxDepth: number;
1642
2652
  maxClaims: number;
1643
- query?: string | undefined;
1644
2653
  tenantId?: string | undefined;
1645
2654
  sessionId?: string | undefined;
2655
+ query?: string | undefined;
1646
2656
  recordedAt?: string | undefined;
1647
2657
  externalTenantId?: string | undefined;
1648
2658
  subjects?: {
1649
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2659
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1650
2660
  externalId: string;
1651
2661
  }[] | undefined;
1652
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
1653
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2662
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
2663
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1654
2664
  providerKeys?: string[] | undefined;
1655
2665
  sourceFamilyKeys?: string[] | undefined;
1656
2666
  connectedAccountIds?: string[] | undefined;
@@ -1660,18 +2670,18 @@ export declare const memoryGraphQueryInputSchema: z.ZodEffects<z.ZodEffects<z.Zo
1660
2670
  semanticCandidateLimit?: number | undefined;
1661
2671
  predicates?: string[] | undefined;
1662
2672
  }, {
1663
- limit?: number | undefined;
1664
- query?: string | undefined;
1665
2673
  tenantId?: string | undefined;
1666
2674
  sessionId?: string | undefined;
2675
+ limit?: number | undefined;
2676
+ query?: string | undefined;
1667
2677
  recordedAt?: string | undefined;
1668
2678
  externalTenantId?: string | undefined;
1669
2679
  subjects?: {
1670
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2680
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1671
2681
  externalId: string;
1672
2682
  }[] | undefined;
1673
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
1674
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2683
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
2684
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1675
2685
  providerKeys?: string[] | undefined;
1676
2686
  sourceFamilyKeys?: string[] | undefined;
1677
2687
  connectedAccountIds?: string[] | undefined;
@@ -1694,17 +2704,17 @@ export declare const memoryGraphQueryInputSchema: z.ZodEffects<z.ZodEffects<z.Zo
1694
2704
  seedRecordIds: string[];
1695
2705
  maxDepth: number;
1696
2706
  maxClaims: number;
1697
- query?: string | undefined;
1698
2707
  tenantId?: string | undefined;
1699
2708
  sessionId?: string | undefined;
2709
+ query?: string | undefined;
1700
2710
  recordedAt?: string | undefined;
1701
2711
  externalTenantId?: string | undefined;
1702
2712
  subjects?: {
1703
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2713
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1704
2714
  externalId: string;
1705
2715
  }[] | undefined;
1706
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
1707
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2716
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
2717
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1708
2718
  providerKeys?: string[] | undefined;
1709
2719
  sourceFamilyKeys?: string[] | undefined;
1710
2720
  connectedAccountIds?: string[] | undefined;
@@ -1714,18 +2724,18 @@ export declare const memoryGraphQueryInputSchema: z.ZodEffects<z.ZodEffects<z.Zo
1714
2724
  semanticCandidateLimit?: number | undefined;
1715
2725
  predicates?: string[] | undefined;
1716
2726
  }, {
1717
- limit?: number | undefined;
1718
- query?: string | undefined;
1719
2727
  tenantId?: string | undefined;
1720
2728
  sessionId?: string | undefined;
2729
+ limit?: number | undefined;
2730
+ query?: string | undefined;
1721
2731
  recordedAt?: string | undefined;
1722
2732
  externalTenantId?: string | undefined;
1723
2733
  subjects?: {
1724
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2734
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1725
2735
  externalId: string;
1726
2736
  }[] | undefined;
1727
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
1728
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2737
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
2738
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1729
2739
  providerKeys?: string[] | undefined;
1730
2740
  sourceFamilyKeys?: string[] | undefined;
1731
2741
  connectedAccountIds?: string[] | undefined;
@@ -1748,17 +2758,17 @@ export declare const memoryGraphQueryInputSchema: z.ZodEffects<z.ZodEffects<z.Zo
1748
2758
  seedRecordIds: string[];
1749
2759
  maxDepth: number;
1750
2760
  maxClaims: number;
1751
- query?: string | undefined;
1752
2761
  tenantId?: string | undefined;
1753
2762
  sessionId?: string | undefined;
2763
+ query?: string | undefined;
1754
2764
  recordedAt?: string | undefined;
1755
2765
  externalTenantId?: string | undefined;
1756
2766
  subjects?: {
1757
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2767
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1758
2768
  externalId: string;
1759
2769
  }[] | undefined;
1760
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
1761
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2770
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
2771
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1762
2772
  providerKeys?: string[] | undefined;
1763
2773
  sourceFamilyKeys?: string[] | undefined;
1764
2774
  connectedAccountIds?: string[] | undefined;
@@ -1768,18 +2778,18 @@ export declare const memoryGraphQueryInputSchema: z.ZodEffects<z.ZodEffects<z.Zo
1768
2778
  semanticCandidateLimit?: number | undefined;
1769
2779
  predicates?: string[] | undefined;
1770
2780
  }, {
1771
- limit?: number | undefined;
1772
- query?: string | undefined;
1773
2781
  tenantId?: string | undefined;
1774
2782
  sessionId?: string | undefined;
2783
+ limit?: number | undefined;
2784
+ query?: string | undefined;
1775
2785
  recordedAt?: string | undefined;
1776
2786
  externalTenantId?: string | undefined;
1777
2787
  subjects?: {
1778
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2788
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1779
2789
  externalId: string;
1780
2790
  }[] | undefined;
1781
- kinds?: ("fact" | "episode" | "profile_item" | "block")[] | undefined;
1782
- memoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2791
+ kinds?: ("block" | "fact" | "episode" | "profile_item")[] | undefined;
2792
+ memoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1783
2793
  providerKeys?: string[] | undefined;
1784
2794
  sourceFamilyKeys?: string[] | undefined;
1785
2795
  connectedAccountIds?: string[] | undefined;
@@ -1803,10 +2813,10 @@ export declare const memoryExportInputSchema: z.ZodEffects<z.ZodObject<{
1803
2813
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
1804
2814
  externalId: z.ZodString;
1805
2815
  }, "strict", z.ZodTypeAny, {
1806
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2816
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1807
2817
  externalId: string;
1808
2818
  }, {
1809
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2819
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1810
2820
  externalId: string;
1811
2821
  }>>;
1812
2822
  format: z.ZodDefault<z.ZodEnum<["json", "jsonl"]>>;
@@ -1815,7 +2825,7 @@ export declare const memoryExportInputSchema: z.ZodEffects<z.ZodObject<{
1815
2825
  tenantId?: string | undefined;
1816
2826
  externalTenantId?: string | undefined;
1817
2827
  subject?: {
1818
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2828
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1819
2829
  externalId: string;
1820
2830
  } | undefined;
1821
2831
  }, {
@@ -1823,7 +2833,7 @@ export declare const memoryExportInputSchema: z.ZodEffects<z.ZodObject<{
1823
2833
  format?: "json" | "jsonl" | undefined;
1824
2834
  externalTenantId?: string | undefined;
1825
2835
  subject?: {
1826
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2836
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1827
2837
  externalId: string;
1828
2838
  } | undefined;
1829
2839
  }>, {
@@ -1831,7 +2841,7 @@ export declare const memoryExportInputSchema: z.ZodEffects<z.ZodObject<{
1831
2841
  tenantId?: string | undefined;
1832
2842
  externalTenantId?: string | undefined;
1833
2843
  subject?: {
1834
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2844
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1835
2845
  externalId: string;
1836
2846
  } | undefined;
1837
2847
  }, {
@@ -1839,7 +2849,7 @@ export declare const memoryExportInputSchema: z.ZodEffects<z.ZodObject<{
1839
2849
  format?: "json" | "jsonl" | undefined;
1840
2850
  externalTenantId?: string | undefined;
1841
2851
  subject?: {
1842
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2852
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1843
2853
  externalId: string;
1844
2854
  } | undefined;
1845
2855
  }>;
@@ -1851,10 +2861,10 @@ export declare const memoryLegalHoldInputSchema: z.ZodEffects<z.ZodObject<{
1851
2861
  type: z.ZodEnum<["user", "agent", "tenant", "run", "application", "custom"]>;
1852
2862
  externalId: z.ZodString;
1853
2863
  }, "strict", z.ZodTypeAny, {
1854
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2864
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1855
2865
  externalId: string;
1856
2866
  }, {
1857
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2867
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1858
2868
  externalId: string;
1859
2869
  }>>;
1860
2870
  reason: z.ZodString;
@@ -1863,7 +2873,7 @@ export declare const memoryLegalHoldInputSchema: z.ZodEffects<z.ZodObject<{
1863
2873
  tenantId?: string | undefined;
1864
2874
  externalTenantId?: string | undefined;
1865
2875
  subject?: {
1866
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2876
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1867
2877
  externalId: string;
1868
2878
  } | undefined;
1869
2879
  }, {
@@ -1871,7 +2881,7 @@ export declare const memoryLegalHoldInputSchema: z.ZodEffects<z.ZodObject<{
1871
2881
  tenantId?: string | undefined;
1872
2882
  externalTenantId?: string | undefined;
1873
2883
  subject?: {
1874
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2884
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1875
2885
  externalId: string;
1876
2886
  } | undefined;
1877
2887
  }>, {
@@ -1879,7 +2889,7 @@ export declare const memoryLegalHoldInputSchema: z.ZodEffects<z.ZodObject<{
1879
2889
  tenantId?: string | undefined;
1880
2890
  externalTenantId?: string | undefined;
1881
2891
  subject?: {
1882
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2892
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1883
2893
  externalId: string;
1884
2894
  } | undefined;
1885
2895
  }, {
@@ -1887,7 +2897,7 @@ export declare const memoryLegalHoldInputSchema: z.ZodEffects<z.ZodObject<{
1887
2897
  tenantId?: string | undefined;
1888
2898
  externalTenantId?: string | undefined;
1889
2899
  subject?: {
1890
- type: "run" | "user" | "agent" | "tenant" | "application" | "custom";
2900
+ type: "custom" | "run" | "user" | "agent" | "tenant" | "application";
1891
2901
  externalId: string;
1892
2902
  } | undefined;
1893
2903
  }>;
@@ -1907,33 +2917,33 @@ export declare const memoryProjectPolicyInputSchema: z.ZodObject<{
1907
2917
  context: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1908
2918
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1909
2919
  }, "strip", z.ZodTypeAny, {
2920
+ context: Record<string, unknown>;
1910
2921
  metadata: Record<string, unknown>;
2922
+ key: string;
2923
+ languages: string[];
2924
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1911
2925
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
1912
2926
  consent: Record<string, unknown>;
1913
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1914
2927
  sourceRetentionDays: number | null;
1915
- key: string;
1916
2928
  captureMode: "explicit" | "bound_sources";
1917
2929
  extractionEnabled: boolean;
1918
2930
  profileEnabled: boolean;
1919
2931
  retentionDays: number | null;
1920
- languages: string[];
1921
2932
  extraction: Record<string, unknown>;
1922
- context: Record<string, unknown>;
1923
2933
  }, {
2934
+ context?: Record<string, unknown> | undefined;
1924
2935
  metadata?: Record<string, unknown> | undefined;
2936
+ key?: string | undefined;
2937
+ languages?: string[] | undefined;
2938
+ allowedMemoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1925
2939
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
1926
2940
  consent?: Record<string, unknown> | undefined;
1927
- allowedMemoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1928
2941
  sourceRetentionDays?: number | null | undefined;
1929
- key?: string | undefined;
1930
2942
  captureMode?: "explicit" | "bound_sources" | undefined;
1931
2943
  extractionEnabled?: boolean | undefined;
1932
2944
  profileEnabled?: boolean | undefined;
1933
2945
  retentionDays?: number | null | undefined;
1934
- languages?: string[] | undefined;
1935
2946
  extraction?: Record<string, unknown> | undefined;
1936
- context?: Record<string, unknown> | undefined;
1937
2947
  }>;
1938
2948
  export declare const memoryProjectPolicyUpdateInputSchema: z.ZodObject<Omit<{
1939
2949
  key: z.ZodDefault<z.ZodString>;
@@ -1952,33 +2962,33 @@ export declare const memoryProjectPolicyUpdateInputSchema: z.ZodObject<Omit<{
1952
2962
  }, "key"> & {
1953
2963
  expectedVersion: z.ZodNumber;
1954
2964
  }, "strict", z.ZodTypeAny, {
2965
+ context: Record<string, unknown>;
1955
2966
  metadata: Record<string, unknown>;
2967
+ languages: string[];
2968
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1956
2969
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
1957
2970
  consent: Record<string, unknown>;
1958
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
1959
2971
  sourceRetentionDays: number | null;
1960
2972
  captureMode: "explicit" | "bound_sources";
1961
2973
  extractionEnabled: boolean;
1962
2974
  profileEnabled: boolean;
1963
2975
  retentionDays: number | null;
1964
- languages: string[];
1965
2976
  extraction: Record<string, unknown>;
1966
- context: Record<string, unknown>;
1967
2977
  expectedVersion: number;
1968
2978
  }, {
1969
2979
  expectedVersion: number;
2980
+ context?: Record<string, unknown> | undefined;
1970
2981
  metadata?: Record<string, unknown> | undefined;
2982
+ languages?: string[] | undefined;
2983
+ allowedMemoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1971
2984
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
1972
2985
  consent?: Record<string, unknown> | undefined;
1973
- allowedMemoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
1974
2986
  sourceRetentionDays?: number | null | undefined;
1975
2987
  captureMode?: "explicit" | "bound_sources" | undefined;
1976
2988
  extractionEnabled?: boolean | undefined;
1977
2989
  profileEnabled?: boolean | undefined;
1978
2990
  retentionDays?: number | null | undefined;
1979
- languages?: string[] | undefined;
1980
2991
  extraction?: Record<string, unknown> | undefined;
1981
- context?: Record<string, unknown> | undefined;
1982
2992
  }>;
1983
2993
  export declare const memoryPolicyPreviewInputSchema: z.ZodObject<{
1984
2994
  idempotencyKey: z.ZodString;
@@ -2001,48 +3011,48 @@ export declare const memoryPolicyPreviewInputSchema: z.ZodObject<{
2001
3011
  context: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2002
3012
  metadata: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2003
3013
  }, "key">, "strip", z.ZodTypeAny, {
3014
+ context: Record<string, unknown>;
2004
3015
  metadata: Record<string, unknown>;
3016
+ languages: string[];
3017
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
2005
3018
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2006
3019
  consent: Record<string, unknown>;
2007
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
2008
3020
  sourceRetentionDays: number | null;
2009
3021
  captureMode: "explicit" | "bound_sources";
2010
3022
  extractionEnabled: boolean;
2011
3023
  profileEnabled: boolean;
2012
3024
  retentionDays: number | null;
2013
- languages: string[];
2014
3025
  extraction: Record<string, unknown>;
2015
- context: Record<string, unknown>;
2016
3026
  }, {
3027
+ context?: Record<string, unknown> | undefined;
2017
3028
  metadata?: Record<string, unknown> | undefined;
3029
+ languages?: string[] | undefined;
3030
+ allowedMemoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2018
3031
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
2019
3032
  consent?: Record<string, unknown> | undefined;
2020
- allowedMemoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2021
3033
  sourceRetentionDays?: number | null | undefined;
2022
3034
  captureMode?: "explicit" | "bound_sources" | undefined;
2023
3035
  extractionEnabled?: boolean | undefined;
2024
3036
  profileEnabled?: boolean | undefined;
2025
3037
  retentionDays?: number | null | undefined;
2026
- languages?: string[] | undefined;
2027
3038
  extraction?: Record<string, unknown> | undefined;
2028
- context?: Record<string, unknown> | undefined;
2029
3039
  }>>;
2030
3040
  }, "strict", z.ZodTypeAny, {
2031
3041
  content: string;
2032
3042
  idempotencyKey: string;
2033
3043
  policy: {
3044
+ context: Record<string, unknown>;
2034
3045
  metadata: Record<string, unknown>;
3046
+ languages: string[];
3047
+ allowedMemoryTypes: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
2035
3048
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2036
3049
  consent: Record<string, unknown>;
2037
- allowedMemoryTypes: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[];
2038
3050
  sourceRetentionDays: number | null;
2039
3051
  captureMode: "explicit" | "bound_sources";
2040
3052
  extractionEnabled: boolean;
2041
3053
  profileEnabled: boolean;
2042
3054
  retentionDays: number | null;
2043
- languages: string[];
2044
3055
  extraction: Record<string, unknown>;
2045
- context: Record<string, unknown>;
2046
3056
  };
2047
3057
  title?: string | undefined;
2048
3058
  language?: string | undefined;
@@ -2054,123 +3064,23 @@ export declare const memoryPolicyPreviewInputSchema: z.ZodObject<{
2054
3064
  language?: string | undefined;
2055
3065
  sourceCategory?: string | undefined;
2056
3066
  policy?: {
3067
+ context?: Record<string, unknown> | undefined;
2057
3068
  metadata?: Record<string, unknown> | undefined;
3069
+ languages?: string[] | undefined;
3070
+ allowedMemoryTypes?: ("decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2058
3071
  restrictedDataClasses?: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[] | undefined;
2059
3072
  consent?: Record<string, unknown> | undefined;
2060
- allowedMemoryTypes?: ("preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact")[] | undefined;
2061
3073
  sourceRetentionDays?: number | null | undefined;
2062
3074
  captureMode?: "explicit" | "bound_sources" | undefined;
2063
3075
  extractionEnabled?: boolean | undefined;
2064
3076
  profileEnabled?: boolean | undefined;
2065
3077
  retentionDays?: number | null | undefined;
2066
- languages?: string[] | undefined;
2067
3078
  extraction?: Record<string, unknown> | undefined;
2068
- context?: Record<string, unknown> | undefined;
2069
3079
  } | undefined;
2070
3080
  }>;
2071
3081
  export type MemoryProjectPolicyInput = z.input<typeof memoryProjectPolicyInputSchema>;
2072
3082
  export type MemoryProjectPolicyUpdateInput = z.input<typeof memoryProjectPolicyUpdateInputSchema>;
2073
3083
  export type MemoryPolicyPreviewInput = z.input<typeof memoryPolicyPreviewInputSchema>;
2074
- export declare const stacklinkPlatformEventTypes: readonly ["provider.resource.created", "provider.resource.updated", "provider.resource.deleted", "tool.execution.completed", "conversation.turn.completed", "artifact.created"];
2075
- export declare const stacklinkPlatformEventSchema: z.ZodObject<{
2076
- id: z.ZodString;
2077
- schemaVersion: z.ZodLiteral<"stacklink.event.v1">;
2078
- consumerAppId: z.ZodString;
2079
- tenantId: z.ZodString;
2080
- sessionId: z.ZodOptional<z.ZodString>;
2081
- userId: z.ZodOptional<z.ZodString>;
2082
- type: z.ZodEnum<["provider.resource.created", "provider.resource.updated", "provider.resource.deleted", "tool.execution.completed", "conversation.turn.completed", "artifact.created"]>;
2083
- source: z.ZodObject<{
2084
- kind: z.ZodEnum<["provider", "tool_execution", "conversation", "artifact"]>;
2085
- providerKey: z.ZodOptional<z.ZodString>;
2086
- connectedAccountId: z.ZodOptional<z.ZodString>;
2087
- resourceType: z.ZodOptional<z.ZodString>;
2088
- resourceId: z.ZodOptional<z.ZodString>;
2089
- resourcePreviousScopeIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2090
- resourceCurrentScopeIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2091
- resourceAffectedScopeIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
2092
- toolExecutionId: z.ZodOptional<z.ZodString>;
2093
- applicationKey: z.ZodOptional<z.ZodString>;
2094
- }, "strict", z.ZodTypeAny, {
2095
- kind: "artifact" | "conversation" | "provider" | "tool_execution";
2096
- providerKey?: string | undefined;
2097
- connectedAccountId?: string | undefined;
2098
- resourceType?: string | undefined;
2099
- resourceId?: string | undefined;
2100
- toolExecutionId?: string | undefined;
2101
- applicationKey?: string | undefined;
2102
- resourcePreviousScopeIds?: string[] | undefined;
2103
- resourceCurrentScopeIds?: string[] | undefined;
2104
- resourceAffectedScopeIds?: string[] | undefined;
2105
- }, {
2106
- kind: "artifact" | "conversation" | "provider" | "tool_execution";
2107
- providerKey?: string | undefined;
2108
- connectedAccountId?: string | undefined;
2109
- resourceType?: string | undefined;
2110
- resourceId?: string | undefined;
2111
- toolExecutionId?: string | undefined;
2112
- applicationKey?: string | undefined;
2113
- resourcePreviousScopeIds?: string[] | undefined;
2114
- resourceCurrentScopeIds?: string[] | undefined;
2115
- resourceAffectedScopeIds?: string[] | undefined;
2116
- }>;
2117
- occurredAt: z.ZodString;
2118
- observedAt: z.ZodString;
2119
- payloadRef: z.ZodOptional<z.ZodString>;
2120
- data: z.ZodRecord<z.ZodString, z.ZodUnknown>;
2121
- metadata: z.ZodRecord<z.ZodString, z.ZodUnknown>;
2122
- }, "strict", z.ZodTypeAny, {
2123
- id: string;
2124
- type: "provider.resource.created" | "provider.resource.updated" | "provider.resource.deleted" | "tool.execution.completed" | "conversation.turn.completed" | "artifact.created";
2125
- source: {
2126
- kind: "artifact" | "conversation" | "provider" | "tool_execution";
2127
- providerKey?: string | undefined;
2128
- connectedAccountId?: string | undefined;
2129
- resourceType?: string | undefined;
2130
- resourceId?: string | undefined;
2131
- toolExecutionId?: string | undefined;
2132
- applicationKey?: string | undefined;
2133
- resourcePreviousScopeIds?: string[] | undefined;
2134
- resourceCurrentScopeIds?: string[] | undefined;
2135
- resourceAffectedScopeIds?: string[] | undefined;
2136
- };
2137
- metadata: Record<string, unknown>;
2138
- tenantId: string;
2139
- occurredAt: string;
2140
- schemaVersion: "stacklink.event.v1";
2141
- consumerAppId: string;
2142
- observedAt: string;
2143
- data: Record<string, unknown>;
2144
- sessionId?: string | undefined;
2145
- userId?: string | undefined;
2146
- payloadRef?: string | undefined;
2147
- }, {
2148
- id: string;
2149
- type: "provider.resource.created" | "provider.resource.updated" | "provider.resource.deleted" | "tool.execution.completed" | "conversation.turn.completed" | "artifact.created";
2150
- source: {
2151
- kind: "artifact" | "conversation" | "provider" | "tool_execution";
2152
- providerKey?: string | undefined;
2153
- connectedAccountId?: string | undefined;
2154
- resourceType?: string | undefined;
2155
- resourceId?: string | undefined;
2156
- toolExecutionId?: string | undefined;
2157
- applicationKey?: string | undefined;
2158
- resourcePreviousScopeIds?: string[] | undefined;
2159
- resourceCurrentScopeIds?: string[] | undefined;
2160
- resourceAffectedScopeIds?: string[] | undefined;
2161
- };
2162
- metadata: Record<string, unknown>;
2163
- tenantId: string;
2164
- occurredAt: string;
2165
- schemaVersion: "stacklink.event.v1";
2166
- consumerAppId: string;
2167
- observedAt: string;
2168
- data: Record<string, unknown>;
2169
- sessionId?: string | undefined;
2170
- userId?: string | undefined;
2171
- payloadRef?: string | undefined;
2172
- }>;
2173
- export type StacklinkPlatformEvent = z.infer<typeof stacklinkPlatformEventSchema>;
2174
3084
  export declare const memorySessionConfigSchema: z.ZodEffects<z.ZodObject<{
2175
3085
  enabled: z.ZodDefault<z.ZodBoolean>;
2176
3086
  agentExternalId: z.ZodOptional<z.ZodString>;
@@ -2244,6 +3154,7 @@ export declare const memoryExtractedEntitySchema: z.ZodObject<{
2244
3154
  }>;
2245
3155
  export declare const memoryExtractedClaimSchema: z.ZodEffects<z.ZodObject<{
2246
3156
  subjectEntityKey: z.ZodString;
3157
+ assertedByEntityKey: z.ZodNullable<z.ZodString>;
2247
3158
  predicate: z.ZodString;
2248
3159
  objectEntityKey: z.ZodNullable<z.ZodString>;
2249
3160
  literalValue: z.ZodNullable<z.ZodUnknown>;
@@ -2253,11 +3164,13 @@ export declare const memoryExtractedClaimSchema: z.ZodEffects<z.ZodObject<{
2253
3164
  validFrom: string | null;
2254
3165
  validTo: string | null;
2255
3166
  subjectEntityKey: string;
3167
+ assertedByEntityKey: string | null;
2256
3168
  predicate: string;
2257
3169
  objectEntityKey: string | null;
2258
3170
  literalValue?: unknown;
2259
3171
  }, {
2260
3172
  subjectEntityKey: string;
3173
+ assertedByEntityKey: string | null;
2261
3174
  predicate: string;
2262
3175
  objectEntityKey: string | null;
2263
3176
  validFrom?: unknown;
@@ -2267,11 +3180,13 @@ export declare const memoryExtractedClaimSchema: z.ZodEffects<z.ZodObject<{
2267
3180
  validFrom: string | null;
2268
3181
  validTo: string | null;
2269
3182
  subjectEntityKey: string;
3183
+ assertedByEntityKey: string | null;
2270
3184
  predicate: string;
2271
3185
  objectEntityKey: string | null;
2272
3186
  literalValue?: unknown;
2273
3187
  }, {
2274
3188
  subjectEntityKey: string;
3189
+ assertedByEntityKey: string | null;
2275
3190
  predicate: string;
2276
3191
  objectEntityKey: string | null;
2277
3192
  validFrom?: unknown;
@@ -2319,6 +3234,16 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2319
3234
  sensitivityClass: z.ZodEnum<["standard", "personal", "restricted", "secret"]>;
2320
3235
  restrictedDataClasses: z.ZodArray<z.ZodEnum<["health", "biometric", "government_identity", "precise_location", "protected_trait", "minor", "detailed_personal_financial"]>, "many">;
2321
3236
  topicTags: z.ZodArray<z.ZodString, "many">;
3237
+ actorEntityKey: z.ZodNullable<z.ZodString>;
3238
+ subjectEntityKey: z.ZodNullable<z.ZodString>;
3239
+ authorshipClass: z.ZodEnum<["connected_user", "other_human", "bot", "application", "system", "unknown"]>;
3240
+ admissionBasis: z.ZodEnum<["self_authored", "provider_structured_state", "attributed_third_party", "tool_execution", "user_confirmed"]>;
3241
+ durability: z.ZodEnum<["durable", "episodic", "transient"]>;
3242
+ salience: z.ZodEnum<["low", "medium", "high"]>;
3243
+ evidenceConfidence: z.ZodEnum<["low", "medium", "high"]>;
3244
+ destination: z.ZodEnum<["durable_memory", "episodic_memory", "restricted_candidate", "source_only", "reject_noise"]>;
3245
+ contextEligible: z.ZodBoolean;
3246
+ qualityContractVersion: z.ZodLiteral<1>;
2322
3247
  validFrom: z.ZodEffects<z.ZodNullable<z.ZodString>, string | null, unknown>;
2323
3248
  validTo: z.ZodEffects<z.ZodNullable<z.ZodString>, string | null, unknown>;
2324
3249
  evidence: z.ZodArray<z.ZodEffects<z.ZodObject<{
@@ -2373,6 +3298,7 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2373
3298
  }>, "many">;
2374
3299
  claims: z.ZodArray<z.ZodEffects<z.ZodObject<{
2375
3300
  subjectEntityKey: z.ZodString;
3301
+ assertedByEntityKey: z.ZodNullable<z.ZodString>;
2376
3302
  predicate: z.ZodString;
2377
3303
  objectEntityKey: z.ZodNullable<z.ZodString>;
2378
3304
  literalValue: z.ZodNullable<z.ZodUnknown>;
@@ -2382,11 +3308,13 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2382
3308
  validFrom: string | null;
2383
3309
  validTo: string | null;
2384
3310
  subjectEntityKey: string;
3311
+ assertedByEntityKey: string | null;
2385
3312
  predicate: string;
2386
3313
  objectEntityKey: string | null;
2387
3314
  literalValue?: unknown;
2388
3315
  }, {
2389
3316
  subjectEntityKey: string;
3317
+ assertedByEntityKey: string | null;
2390
3318
  predicate: string;
2391
3319
  objectEntityKey: string | null;
2392
3320
  validFrom?: unknown;
@@ -2396,11 +3324,13 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2396
3324
  validFrom: string | null;
2397
3325
  validTo: string | null;
2398
3326
  subjectEntityKey: string;
3327
+ assertedByEntityKey: string | null;
2399
3328
  predicate: string;
2400
3329
  objectEntityKey: string | null;
2401
3330
  literalValue?: unknown;
2402
3331
  }, {
2403
3332
  subjectEntityKey: string;
3333
+ assertedByEntityKey: string | null;
2404
3334
  predicate: string;
2405
3335
  objectEntityKey: string | null;
2406
3336
  validFrom?: unknown;
@@ -2410,17 +3340,17 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2410
3340
  attributes: z.ZodRecord<z.ZodString, z.ZodUnknown>;
2411
3341
  }, "strict", z.ZodTypeAny, {
2412
3342
  content: string;
3343
+ qualityContractVersion: 1;
3344
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3345
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
3346
+ validFrom: string | null;
3347
+ validTo: string | null;
2413
3348
  title: string;
2414
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3349
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2415
3350
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2416
3351
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2417
3352
  topicTags: string[];
2418
3353
  language: string;
2419
- validFrom: string | null;
2420
- validTo: string | null;
2421
- attributes: Record<string, unknown>;
2422
- candidateId: string;
2423
- recordKind: "fact" | "episode";
2424
3354
  evidence: {
2425
3355
  sourceObjectId: string;
2426
3356
  segmentId: string;
@@ -2428,6 +3358,16 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2428
3358
  endOffset: number;
2429
3359
  quotedText: string;
2430
3360
  }[];
3361
+ attributes: Record<string, unknown>;
3362
+ salience: "low" | "medium" | "high";
3363
+ evidenceConfidence: "low" | "medium" | "high";
3364
+ subjectEntityKey: string | null;
3365
+ candidateId: string;
3366
+ recordKind: "fact" | "episode";
3367
+ actorEntityKey: string | null;
3368
+ durability: "durable" | "episodic" | "transient";
3369
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3370
+ contextEligible: boolean;
2431
3371
  entities: {
2432
3372
  type: string;
2433
3373
  key: string;
@@ -2439,21 +3379,22 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2439
3379
  validFrom: string | null;
2440
3380
  validTo: string | null;
2441
3381
  subjectEntityKey: string;
3382
+ assertedByEntityKey: string | null;
2442
3383
  predicate: string;
2443
3384
  objectEntityKey: string | null;
2444
3385
  literalValue?: unknown;
2445
3386
  }[];
2446
3387
  }, {
2447
3388
  content: string;
3389
+ qualityContractVersion: 1;
3390
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3391
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
2448
3392
  title: string;
2449
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3393
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2450
3394
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2451
3395
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2452
3396
  topicTags: string[];
2453
3397
  language: string;
2454
- attributes: Record<string, unknown>;
2455
- candidateId: string;
2456
- recordKind: "fact" | "episode";
2457
3398
  evidence: {
2458
3399
  sourceObjectId: string;
2459
3400
  segmentId: string;
@@ -2461,6 +3402,16 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2461
3402
  endOffset: number;
2462
3403
  quotedText: string;
2463
3404
  }[];
3405
+ attributes: Record<string, unknown>;
3406
+ salience: "low" | "medium" | "high";
3407
+ evidenceConfidence: "low" | "medium" | "high";
3408
+ subjectEntityKey: string | null;
3409
+ candidateId: string;
3410
+ recordKind: "fact" | "episode";
3411
+ actorEntityKey: string | null;
3412
+ durability: "durable" | "episodic" | "transient";
3413
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3414
+ contextEligible: boolean;
2464
3415
  entities: {
2465
3416
  type: string;
2466
3417
  key: string;
@@ -2470,6 +3421,7 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2470
3421
  }[];
2471
3422
  claims: {
2472
3423
  subjectEntityKey: string;
3424
+ assertedByEntityKey: string | null;
2473
3425
  predicate: string;
2474
3426
  objectEntityKey: string | null;
2475
3427
  validFrom?: unknown;
@@ -2480,17 +3432,17 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2480
3432
  validTo?: unknown;
2481
3433
  }>, {
2482
3434
  content: string;
3435
+ qualityContractVersion: 1;
3436
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3437
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
3438
+ validFrom: string | null;
3439
+ validTo: string | null;
2483
3440
  title: string;
2484
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3441
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2485
3442
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2486
3443
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2487
3444
  topicTags: string[];
2488
3445
  language: string;
2489
- validFrom: string | null;
2490
- validTo: string | null;
2491
- attributes: Record<string, unknown>;
2492
- candidateId: string;
2493
- recordKind: "fact" | "episode";
2494
3446
  evidence: {
2495
3447
  sourceObjectId: string;
2496
3448
  segmentId: string;
@@ -2498,6 +3450,16 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2498
3450
  endOffset: number;
2499
3451
  quotedText: string;
2500
3452
  }[];
3453
+ attributes: Record<string, unknown>;
3454
+ salience: "low" | "medium" | "high";
3455
+ evidenceConfidence: "low" | "medium" | "high";
3456
+ subjectEntityKey: string | null;
3457
+ candidateId: string;
3458
+ recordKind: "fact" | "episode";
3459
+ actorEntityKey: string | null;
3460
+ durability: "durable" | "episodic" | "transient";
3461
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3462
+ contextEligible: boolean;
2501
3463
  entities: {
2502
3464
  type: string;
2503
3465
  key: string;
@@ -2509,21 +3471,22 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2509
3471
  validFrom: string | null;
2510
3472
  validTo: string | null;
2511
3473
  subjectEntityKey: string;
3474
+ assertedByEntityKey: string | null;
2512
3475
  predicate: string;
2513
3476
  objectEntityKey: string | null;
2514
3477
  literalValue?: unknown;
2515
3478
  }[];
2516
3479
  }, {
2517
3480
  content: string;
3481
+ qualityContractVersion: 1;
3482
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3483
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
2518
3484
  title: string;
2519
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3485
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2520
3486
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2521
3487
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2522
3488
  topicTags: string[];
2523
3489
  language: string;
2524
- attributes: Record<string, unknown>;
2525
- candidateId: string;
2526
- recordKind: "fact" | "episode";
2527
3490
  evidence: {
2528
3491
  sourceObjectId: string;
2529
3492
  segmentId: string;
@@ -2531,6 +3494,16 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2531
3494
  endOffset: number;
2532
3495
  quotedText: string;
2533
3496
  }[];
3497
+ attributes: Record<string, unknown>;
3498
+ salience: "low" | "medium" | "high";
3499
+ evidenceConfidence: "low" | "medium" | "high";
3500
+ subjectEntityKey: string | null;
3501
+ candidateId: string;
3502
+ recordKind: "fact" | "episode";
3503
+ actorEntityKey: string | null;
3504
+ durability: "durable" | "episodic" | "transient";
3505
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3506
+ contextEligible: boolean;
2534
3507
  entities: {
2535
3508
  type: string;
2536
3509
  key: string;
@@ -2540,6 +3513,7 @@ export declare const memoryExtractedRecordSchema: z.ZodEffects<z.ZodObject<{
2540
3513
  }[];
2541
3514
  claims: {
2542
3515
  subjectEntityKey: string;
3516
+ assertedByEntityKey: string | null;
2543
3517
  predicate: string;
2544
3518
  objectEntityKey: string | null;
2545
3519
  validFrom?: unknown;
@@ -2560,6 +3534,16 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2560
3534
  sensitivityClass: z.ZodEnum<["standard", "personal", "restricted", "secret"]>;
2561
3535
  restrictedDataClasses: z.ZodArray<z.ZodEnum<["health", "biometric", "government_identity", "precise_location", "protected_trait", "minor", "detailed_personal_financial"]>, "many">;
2562
3536
  topicTags: z.ZodArray<z.ZodString, "many">;
3537
+ actorEntityKey: z.ZodNullable<z.ZodString>;
3538
+ subjectEntityKey: z.ZodNullable<z.ZodString>;
3539
+ authorshipClass: z.ZodEnum<["connected_user", "other_human", "bot", "application", "system", "unknown"]>;
3540
+ admissionBasis: z.ZodEnum<["self_authored", "provider_structured_state", "attributed_third_party", "tool_execution", "user_confirmed"]>;
3541
+ durability: z.ZodEnum<["durable", "episodic", "transient"]>;
3542
+ salience: z.ZodEnum<["low", "medium", "high"]>;
3543
+ evidenceConfidence: z.ZodEnum<["low", "medium", "high"]>;
3544
+ destination: z.ZodEnum<["durable_memory", "episodic_memory", "restricted_candidate", "source_only", "reject_noise"]>;
3545
+ contextEligible: z.ZodBoolean;
3546
+ qualityContractVersion: z.ZodLiteral<1>;
2563
3547
  validFrom: z.ZodEffects<z.ZodNullable<z.ZodString>, string | null, unknown>;
2564
3548
  validTo: z.ZodEffects<z.ZodNullable<z.ZodString>, string | null, unknown>;
2565
3549
  evidence: z.ZodArray<z.ZodEffects<z.ZodObject<{
@@ -2614,6 +3598,7 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2614
3598
  }>, "many">;
2615
3599
  claims: z.ZodArray<z.ZodEffects<z.ZodObject<{
2616
3600
  subjectEntityKey: z.ZodString;
3601
+ assertedByEntityKey: z.ZodNullable<z.ZodString>;
2617
3602
  predicate: z.ZodString;
2618
3603
  objectEntityKey: z.ZodNullable<z.ZodString>;
2619
3604
  literalValue: z.ZodNullable<z.ZodUnknown>;
@@ -2623,11 +3608,13 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2623
3608
  validFrom: string | null;
2624
3609
  validTo: string | null;
2625
3610
  subjectEntityKey: string;
3611
+ assertedByEntityKey: string | null;
2626
3612
  predicate: string;
2627
3613
  objectEntityKey: string | null;
2628
3614
  literalValue?: unknown;
2629
3615
  }, {
2630
3616
  subjectEntityKey: string;
3617
+ assertedByEntityKey: string | null;
2631
3618
  predicate: string;
2632
3619
  objectEntityKey: string | null;
2633
3620
  validFrom?: unknown;
@@ -2637,11 +3624,13 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2637
3624
  validFrom: string | null;
2638
3625
  validTo: string | null;
2639
3626
  subjectEntityKey: string;
3627
+ assertedByEntityKey: string | null;
2640
3628
  predicate: string;
2641
3629
  objectEntityKey: string | null;
2642
3630
  literalValue?: unknown;
2643
3631
  }, {
2644
3632
  subjectEntityKey: string;
3633
+ assertedByEntityKey: string | null;
2645
3634
  predicate: string;
2646
3635
  objectEntityKey: string | null;
2647
3636
  validFrom?: unknown;
@@ -2651,17 +3640,17 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2651
3640
  attributes: z.ZodRecord<z.ZodString, z.ZodUnknown>;
2652
3641
  }, "strict", z.ZodTypeAny, {
2653
3642
  content: string;
3643
+ qualityContractVersion: 1;
3644
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3645
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
3646
+ validFrom: string | null;
3647
+ validTo: string | null;
2654
3648
  title: string;
2655
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3649
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2656
3650
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2657
3651
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2658
3652
  topicTags: string[];
2659
3653
  language: string;
2660
- validFrom: string | null;
2661
- validTo: string | null;
2662
- attributes: Record<string, unknown>;
2663
- candidateId: string;
2664
- recordKind: "fact" | "episode";
2665
3654
  evidence: {
2666
3655
  sourceObjectId: string;
2667
3656
  segmentId: string;
@@ -2669,6 +3658,16 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2669
3658
  endOffset: number;
2670
3659
  quotedText: string;
2671
3660
  }[];
3661
+ attributes: Record<string, unknown>;
3662
+ salience: "low" | "medium" | "high";
3663
+ evidenceConfidence: "low" | "medium" | "high";
3664
+ subjectEntityKey: string | null;
3665
+ candidateId: string;
3666
+ recordKind: "fact" | "episode";
3667
+ actorEntityKey: string | null;
3668
+ durability: "durable" | "episodic" | "transient";
3669
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3670
+ contextEligible: boolean;
2672
3671
  entities: {
2673
3672
  type: string;
2674
3673
  key: string;
@@ -2680,21 +3679,22 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2680
3679
  validFrom: string | null;
2681
3680
  validTo: string | null;
2682
3681
  subjectEntityKey: string;
3682
+ assertedByEntityKey: string | null;
2683
3683
  predicate: string;
2684
3684
  objectEntityKey: string | null;
2685
3685
  literalValue?: unknown;
2686
3686
  }[];
2687
3687
  }, {
2688
3688
  content: string;
3689
+ qualityContractVersion: 1;
3690
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3691
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
2689
3692
  title: string;
2690
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3693
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2691
3694
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2692
3695
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2693
3696
  topicTags: string[];
2694
3697
  language: string;
2695
- attributes: Record<string, unknown>;
2696
- candidateId: string;
2697
- recordKind: "fact" | "episode";
2698
3698
  evidence: {
2699
3699
  sourceObjectId: string;
2700
3700
  segmentId: string;
@@ -2702,6 +3702,16 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2702
3702
  endOffset: number;
2703
3703
  quotedText: string;
2704
3704
  }[];
3705
+ attributes: Record<string, unknown>;
3706
+ salience: "low" | "medium" | "high";
3707
+ evidenceConfidence: "low" | "medium" | "high";
3708
+ subjectEntityKey: string | null;
3709
+ candidateId: string;
3710
+ recordKind: "fact" | "episode";
3711
+ actorEntityKey: string | null;
3712
+ durability: "durable" | "episodic" | "transient";
3713
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3714
+ contextEligible: boolean;
2705
3715
  entities: {
2706
3716
  type: string;
2707
3717
  key: string;
@@ -2711,6 +3721,7 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2711
3721
  }[];
2712
3722
  claims: {
2713
3723
  subjectEntityKey: string;
3724
+ assertedByEntityKey: string | null;
2714
3725
  predicate: string;
2715
3726
  objectEntityKey: string | null;
2716
3727
  validFrom?: unknown;
@@ -2721,17 +3732,17 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2721
3732
  validTo?: unknown;
2722
3733
  }>, {
2723
3734
  content: string;
3735
+ qualityContractVersion: 1;
3736
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3737
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
3738
+ validFrom: string | null;
3739
+ validTo: string | null;
2724
3740
  title: string;
2725
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3741
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2726
3742
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2727
3743
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2728
3744
  topicTags: string[];
2729
3745
  language: string;
2730
- validFrom: string | null;
2731
- validTo: string | null;
2732
- attributes: Record<string, unknown>;
2733
- candidateId: string;
2734
- recordKind: "fact" | "episode";
2735
3746
  evidence: {
2736
3747
  sourceObjectId: string;
2737
3748
  segmentId: string;
@@ -2739,6 +3750,16 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2739
3750
  endOffset: number;
2740
3751
  quotedText: string;
2741
3752
  }[];
3753
+ attributes: Record<string, unknown>;
3754
+ salience: "low" | "medium" | "high";
3755
+ evidenceConfidence: "low" | "medium" | "high";
3756
+ subjectEntityKey: string | null;
3757
+ candidateId: string;
3758
+ recordKind: "fact" | "episode";
3759
+ actorEntityKey: string | null;
3760
+ durability: "durable" | "episodic" | "transient";
3761
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3762
+ contextEligible: boolean;
2742
3763
  entities: {
2743
3764
  type: string;
2744
3765
  key: string;
@@ -2750,21 +3771,22 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2750
3771
  validFrom: string | null;
2751
3772
  validTo: string | null;
2752
3773
  subjectEntityKey: string;
3774
+ assertedByEntityKey: string | null;
2753
3775
  predicate: string;
2754
3776
  objectEntityKey: string | null;
2755
3777
  literalValue?: unknown;
2756
3778
  }[];
2757
3779
  }, {
2758
3780
  content: string;
3781
+ qualityContractVersion: 1;
3782
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3783
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
2759
3784
  title: string;
2760
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3785
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2761
3786
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2762
3787
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2763
3788
  topicTags: string[];
2764
3789
  language: string;
2765
- attributes: Record<string, unknown>;
2766
- candidateId: string;
2767
- recordKind: "fact" | "episode";
2768
3790
  evidence: {
2769
3791
  sourceObjectId: string;
2770
3792
  segmentId: string;
@@ -2772,6 +3794,16 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2772
3794
  endOffset: number;
2773
3795
  quotedText: string;
2774
3796
  }[];
3797
+ attributes: Record<string, unknown>;
3798
+ salience: "low" | "medium" | "high";
3799
+ evidenceConfidence: "low" | "medium" | "high";
3800
+ subjectEntityKey: string | null;
3801
+ candidateId: string;
3802
+ recordKind: "fact" | "episode";
3803
+ actorEntityKey: string | null;
3804
+ durability: "durable" | "episodic" | "transient";
3805
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3806
+ contextEligible: boolean;
2775
3807
  entities: {
2776
3808
  type: string;
2777
3809
  key: string;
@@ -2781,6 +3813,7 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2781
3813
  }[];
2782
3814
  claims: {
2783
3815
  subjectEntityKey: string;
3816
+ assertedByEntityKey: string | null;
2784
3817
  predicate: string;
2785
3818
  objectEntityKey: string | null;
2786
3819
  validFrom?: unknown;
@@ -2793,17 +3826,17 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2793
3826
  }, "strict", z.ZodTypeAny, {
2794
3827
  records: {
2795
3828
  content: string;
3829
+ qualityContractVersion: 1;
3830
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3831
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
3832
+ validFrom: string | null;
3833
+ validTo: string | null;
2796
3834
  title: string;
2797
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3835
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2798
3836
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2799
3837
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2800
3838
  topicTags: string[];
2801
3839
  language: string;
2802
- validFrom: string | null;
2803
- validTo: string | null;
2804
- attributes: Record<string, unknown>;
2805
- candidateId: string;
2806
- recordKind: "fact" | "episode";
2807
3840
  evidence: {
2808
3841
  sourceObjectId: string;
2809
3842
  segmentId: string;
@@ -2811,6 +3844,16 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2811
3844
  endOffset: number;
2812
3845
  quotedText: string;
2813
3846
  }[];
3847
+ attributes: Record<string, unknown>;
3848
+ salience: "low" | "medium" | "high";
3849
+ evidenceConfidence: "low" | "medium" | "high";
3850
+ subjectEntityKey: string | null;
3851
+ candidateId: string;
3852
+ recordKind: "fact" | "episode";
3853
+ actorEntityKey: string | null;
3854
+ durability: "durable" | "episodic" | "transient";
3855
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3856
+ contextEligible: boolean;
2814
3857
  entities: {
2815
3858
  type: string;
2816
3859
  key: string;
@@ -2822,6 +3865,7 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2822
3865
  validFrom: string | null;
2823
3866
  validTo: string | null;
2824
3867
  subjectEntityKey: string;
3868
+ assertedByEntityKey: string | null;
2825
3869
  predicate: string;
2826
3870
  objectEntityKey: string | null;
2827
3871
  literalValue?: unknown;
@@ -2830,15 +3874,15 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2830
3874
  }, {
2831
3875
  records: {
2832
3876
  content: string;
3877
+ qualityContractVersion: 1;
3878
+ authorshipClass: "unknown" | "bot" | "application" | "connected_user" | "other_human" | "system";
3879
+ admissionBasis: "self_authored" | "provider_structured_state" | "attributed_third_party" | "tool_execution" | "user_confirmed";
2833
3880
  title: string;
2834
- memoryType: "preference" | "decision" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
3881
+ memoryType: "decision" | "preference" | "commitment" | "goal" | "constraint" | "relationship" | "durable_fact";
2835
3882
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2836
3883
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2837
3884
  topicTags: string[];
2838
3885
  language: string;
2839
- attributes: Record<string, unknown>;
2840
- candidateId: string;
2841
- recordKind: "fact" | "episode";
2842
3886
  evidence: {
2843
3887
  sourceObjectId: string;
2844
3888
  segmentId: string;
@@ -2846,6 +3890,16 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2846
3890
  endOffset: number;
2847
3891
  quotedText: string;
2848
3892
  }[];
3893
+ attributes: Record<string, unknown>;
3894
+ salience: "low" | "medium" | "high";
3895
+ evidenceConfidence: "low" | "medium" | "high";
3896
+ subjectEntityKey: string | null;
3897
+ candidateId: string;
3898
+ recordKind: "fact" | "episode";
3899
+ actorEntityKey: string | null;
3900
+ durability: "durable" | "episodic" | "transient";
3901
+ destination: "durable_memory" | "episodic_memory" | "restricted_candidate" | "source_only" | "reject_noise";
3902
+ contextEligible: boolean;
2849
3903
  entities: {
2850
3904
  type: string;
2851
3905
  key: string;
@@ -2855,6 +3909,7 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2855
3909
  }[];
2856
3910
  claims: {
2857
3911
  subjectEntityKey: string;
3912
+ assertedByEntityKey: string | null;
2858
3913
  predicate: string;
2859
3914
  objectEntityKey: string | null;
2860
3915
  validFrom?: unknown;
@@ -2866,83 +3921,107 @@ export declare const memoryExtractionResultSchema: z.ZodObject<{
2866
3921
  }[];
2867
3922
  }>;
2868
3923
  export declare const memorySafetyDecisionSchema: z.ZodEffects<z.ZodObject<{
3924
+ authorshipStatus: z.ZodOptional<z.ZodEnum<["verified_sender_text", "quoted_or_forwarded", "uncertain"]>>;
2869
3925
  candidateId: z.ZodString;
2870
3926
  status: z.ZodEnum<["classified", "uncertain"]>;
3927
+ retentionStatus: z.ZodEnum<["memory", "source_only", "reject_noise", "uncertain"]>;
2871
3928
  sensitivityClass: z.ZodEnum<["standard", "personal", "restricted", "secret"]>;
2872
3929
  restrictedDataClasses: z.ZodArray<z.ZodEnum<["health", "biometric", "government_identity", "precise_location", "protected_trait", "minor", "detailed_personal_financial"]>, "many">;
2873
3930
  reason: z.ZodString;
2874
3931
  }, "strict", z.ZodTypeAny, {
2875
- status: "classified" | "uncertain";
3932
+ status: "uncertain" | "classified";
2876
3933
  reason: string;
2877
3934
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2878
3935
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2879
3936
  candidateId: string;
3937
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
3938
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2880
3939
  }, {
2881
- status: "classified" | "uncertain";
3940
+ status: "uncertain" | "classified";
2882
3941
  reason: string;
2883
3942
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2884
3943
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2885
3944
  candidateId: string;
3945
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
3946
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2886
3947
  }>, {
2887
- status: "classified" | "uncertain";
3948
+ status: "uncertain" | "classified";
2888
3949
  reason: string;
2889
3950
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2890
3951
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2891
3952
  candidateId: string;
3953
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
3954
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2892
3955
  }, {
2893
- status: "classified" | "uncertain";
3956
+ status: "uncertain" | "classified";
2894
3957
  reason: string;
2895
3958
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2896
3959
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2897
3960
  candidateId: string;
3961
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
3962
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2898
3963
  }>;
2899
3964
  export declare const memorySafetyResultSchema: z.ZodObject<{
2900
3965
  decisions: z.ZodArray<z.ZodEffects<z.ZodObject<{
3966
+ authorshipStatus: z.ZodOptional<z.ZodEnum<["verified_sender_text", "quoted_or_forwarded", "uncertain"]>>;
2901
3967
  candidateId: z.ZodString;
2902
3968
  status: z.ZodEnum<["classified", "uncertain"]>;
3969
+ retentionStatus: z.ZodEnum<["memory", "source_only", "reject_noise", "uncertain"]>;
2903
3970
  sensitivityClass: z.ZodEnum<["standard", "personal", "restricted", "secret"]>;
2904
3971
  restrictedDataClasses: z.ZodArray<z.ZodEnum<["health", "biometric", "government_identity", "precise_location", "protected_trait", "minor", "detailed_personal_financial"]>, "many">;
2905
3972
  reason: z.ZodString;
2906
3973
  }, "strict", z.ZodTypeAny, {
2907
- status: "classified" | "uncertain";
3974
+ status: "uncertain" | "classified";
2908
3975
  reason: string;
2909
3976
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2910
3977
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2911
3978
  candidateId: string;
3979
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
3980
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2912
3981
  }, {
2913
- status: "classified" | "uncertain";
3982
+ status: "uncertain" | "classified";
2914
3983
  reason: string;
2915
3984
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2916
3985
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2917
3986
  candidateId: string;
3987
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
3988
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2918
3989
  }>, {
2919
- status: "classified" | "uncertain";
3990
+ status: "uncertain" | "classified";
2920
3991
  reason: string;
2921
3992
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2922
3993
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2923
3994
  candidateId: string;
3995
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
3996
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2924
3997
  }, {
2925
- status: "classified" | "uncertain";
3998
+ status: "uncertain" | "classified";
2926
3999
  reason: string;
2927
4000
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2928
4001
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2929
4002
  candidateId: string;
4003
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
4004
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2930
4005
  }>, "many">;
2931
4006
  }, "strict", z.ZodTypeAny, {
2932
4007
  decisions: {
2933
- status: "classified" | "uncertain";
4008
+ status: "uncertain" | "classified";
2934
4009
  reason: string;
2935
4010
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2936
4011
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2937
4012
  candidateId: string;
4013
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
4014
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2938
4015
  }[];
2939
4016
  }, {
2940
4017
  decisions: {
2941
- status: "classified" | "uncertain";
4018
+ status: "uncertain" | "classified";
2942
4019
  reason: string;
2943
4020
  sensitivityClass: "standard" | "personal" | "restricted" | "secret";
2944
4021
  restrictedDataClasses: ("health" | "biometric" | "government_identity" | "precise_location" | "protected_trait" | "minor" | "detailed_personal_financial")[];
2945
4022
  candidateId: string;
4023
+ retentionStatus: "memory" | "source_only" | "reject_noise" | "uncertain";
4024
+ authorshipStatus?: "uncertain" | "verified_sender_text" | "quoted_or_forwarded" | undefined;
2946
4025
  }[];
2947
4026
  }>;
2948
4027
  export declare const memoryConsolidationResultSchema: z.ZodObject<{
@@ -2952,37 +4031,37 @@ export declare const memoryConsolidationResultSchema: z.ZodObject<{
2952
4031
  targetRecordId: z.ZodNullable<z.ZodString>;
2953
4032
  reason: z.ZodString;
2954
4033
  }, "strict", z.ZodTypeAny, {
2955
- action: "add" | "supersede" | "contradict" | "support" | "no_change";
2956
4034
  reason: string;
4035
+ action: "add" | "supersede" | "contradict" | "support" | "no_change";
2957
4036
  candidateId: string;
2958
4037
  targetRecordId: string | null;
2959
4038
  }, {
2960
- action: "add" | "supersede" | "contradict" | "support" | "no_change";
2961
4039
  reason: string;
4040
+ action: "add" | "supersede" | "contradict" | "support" | "no_change";
2962
4041
  candidateId: string;
2963
4042
  targetRecordId: string | null;
2964
4043
  }>, {
2965
- action: "add" | "supersede" | "contradict" | "support" | "no_change";
2966
4044
  reason: string;
4045
+ action: "add" | "supersede" | "contradict" | "support" | "no_change";
2967
4046
  candidateId: string;
2968
4047
  targetRecordId: string | null;
2969
4048
  }, {
2970
- action: "add" | "supersede" | "contradict" | "support" | "no_change";
2971
4049
  reason: string;
4050
+ action: "add" | "supersede" | "contradict" | "support" | "no_change";
2972
4051
  candidateId: string;
2973
4052
  targetRecordId: string | null;
2974
4053
  }>, "many">;
2975
4054
  }, "strict", z.ZodTypeAny, {
2976
4055
  decisions: {
2977
- action: "add" | "supersede" | "contradict" | "support" | "no_change";
2978
4056
  reason: string;
4057
+ action: "add" | "supersede" | "contradict" | "support" | "no_change";
2979
4058
  candidateId: string;
2980
4059
  targetRecordId: string | null;
2981
4060
  }[];
2982
4061
  }, {
2983
4062
  decisions: {
2984
- action: "add" | "supersede" | "contradict" | "support" | "no_change";
2985
4063
  reason: string;
4064
+ action: "add" | "supersede" | "contradict" | "support" | "no_change";
2986
4065
  candidateId: string;
2987
4066
  targetRecordId: string | null;
2988
4067
  }[];
@@ -2996,36 +4075,36 @@ export declare const memoryProfileResultSchema: z.ZodEffects<z.ZodObject<{
2996
4075
  content: z.ZodString;
2997
4076
  includedRecordVersionIds: z.ZodArray<z.ZodString, "many">;
2998
4077
  }, "strict", z.ZodTypeAny, {
2999
- content: string;
3000
4078
  key: string;
4079
+ content: string;
3001
4080
  includedRecordVersionIds: string[];
3002
4081
  }, {
3003
- content: string;
3004
4082
  key: string;
4083
+ content: string;
3005
4084
  includedRecordVersionIds: string[];
3006
4085
  }>, "many">;
3007
4086
  }, "strict", z.ZodTypeAny, {
3008
4087
  buckets: {
3009
- content: string;
3010
4088
  key: string;
4089
+ content: string;
3011
4090
  includedRecordVersionIds: string[];
3012
4091
  }[];
3013
4092
  }, {
3014
4093
  buckets: {
3015
- content: string;
3016
4094
  key: string;
4095
+ content: string;
3017
4096
  includedRecordVersionIds: string[];
3018
4097
  }[];
3019
4098
  }>, {
3020
4099
  buckets: {
3021
- content: string;
3022
4100
  key: string;
4101
+ content: string;
3023
4102
  includedRecordVersionIds: string[];
3024
4103
  }[];
3025
4104
  }, {
3026
4105
  buckets: {
3027
- content: string;
3028
4106
  key: string;
4107
+ content: string;
3029
4108
  includedRecordVersionIds: string[];
3030
4109
  }[];
3031
4110
  }>;
@@ -3035,40 +4114,40 @@ export declare const memoryProfileDeltaResultSchema: z.ZodEffects<z.ZodObject<{
3035
4114
  content: z.ZodString;
3036
4115
  includedRecordVersionIds: z.ZodArray<z.ZodString, "many">;
3037
4116
  }, "strict", z.ZodTypeAny, {
3038
- content: string;
3039
4117
  key: string;
4118
+ content: string;
3040
4119
  includedRecordVersionIds: string[];
3041
4120
  }, {
3042
- content: string;
3043
4121
  key: string;
4122
+ content: string;
3044
4123
  includedRecordVersionIds: string[];
3045
4124
  }>, "many">;
3046
4125
  removeBucketKeys: z.ZodArray<z.ZodString, "many">;
3047
4126
  }, "strict", z.ZodTypeAny, {
3048
4127
  buckets: {
3049
- content: string;
3050
4128
  key: string;
4129
+ content: string;
3051
4130
  includedRecordVersionIds: string[];
3052
4131
  }[];
3053
4132
  removeBucketKeys: string[];
3054
4133
  }, {
3055
4134
  buckets: {
3056
- content: string;
3057
4135
  key: string;
4136
+ content: string;
3058
4137
  includedRecordVersionIds: string[];
3059
4138
  }[];
3060
4139
  removeBucketKeys: string[];
3061
4140
  }>, {
3062
4141
  buckets: {
3063
- content: string;
3064
4142
  key: string;
4143
+ content: string;
3065
4144
  includedRecordVersionIds: string[];
3066
4145
  }[];
3067
4146
  removeBucketKeys: string[];
3068
4147
  }, {
3069
4148
  buckets: {
3070
- content: string;
3071
4149
  key: string;
4150
+ content: string;
3072
4151
  includedRecordVersionIds: string[];
3073
4152
  }[];
3074
4153
  removeBucketKeys: string[];
@@ -3084,10 +4163,12 @@ export declare const memoryExtractionJsonSchema: {
3084
4163
  readonly items: {
3085
4164
  readonly type: "object";
3086
4165
  readonly additionalProperties: false;
3087
- readonly required: readonly ["candidateId", "recordKind", "memoryType", "title", "content", "language", "sensitivityClass", "restrictedDataClasses", "topicTags", "validFrom", "validTo", "evidence", "entities", "claims", "attributes"];
4166
+ readonly required: readonly ["candidateId", "recordKind", "memoryType", "title", "content", "language", "sensitivityClass", "restrictedDataClasses", "topicTags", "validFrom", "validTo", "actorEntityKey", "subjectEntityKey", "authorshipClass", "admissionBasis", "durability", "salience", "evidenceConfidence", "destination", "contextEligible", "qualityContractVersion", "evidence", "entities", "claims", "attributes"];
3088
4167
  readonly properties: {
3089
4168
  readonly candidateId: {
3090
4169
  readonly type: "string";
4170
+ readonly minLength: 1;
4171
+ readonly maxLength: 120;
3091
4172
  };
3092
4173
  readonly recordKind: {
3093
4174
  readonly type: "string";
@@ -3099,12 +4180,18 @@ export declare const memoryExtractionJsonSchema: {
3099
4180
  };
3100
4181
  readonly title: {
3101
4182
  readonly type: "string";
4183
+ readonly minLength: 1;
4184
+ readonly maxLength: 260;
3102
4185
  };
3103
4186
  readonly content: {
3104
4187
  readonly type: "string";
4188
+ readonly minLength: 1;
4189
+ readonly maxLength: 200000;
3105
4190
  };
3106
4191
  readonly language: {
3107
4192
  readonly type: "string";
4193
+ readonly minLength: 1;
4194
+ readonly maxLength: 80;
3108
4195
  };
3109
4196
  readonly sensitivityClass: {
3110
4197
  readonly type: "string";
@@ -3125,6 +4212,49 @@ export declare const memoryExtractionJsonSchema: {
3125
4212
  readonly type: "string";
3126
4213
  };
3127
4214
  };
4215
+ readonly actorEntityKey: {
4216
+ readonly type: readonly ["string", "null"];
4217
+ readonly minLength: 1;
4218
+ readonly maxLength: 320;
4219
+ readonly description: "When non-null, must exactly match an entities[].key in this same record.";
4220
+ };
4221
+ readonly subjectEntityKey: {
4222
+ readonly type: readonly ["string", "null"];
4223
+ readonly minLength: 1;
4224
+ readonly maxLength: 320;
4225
+ readonly description: "When non-null, must exactly match an entities[].key in this same record.";
4226
+ };
4227
+ readonly authorshipClass: {
4228
+ readonly type: "string";
4229
+ readonly enum: readonly ["connected_user", "other_human", "bot", "application", "system", "unknown"];
4230
+ };
4231
+ readonly admissionBasis: {
4232
+ readonly type: "string";
4233
+ readonly enum: readonly ["self_authored", "provider_structured_state", "attributed_third_party", "tool_execution", "user_confirmed"];
4234
+ };
4235
+ readonly durability: {
4236
+ readonly type: "string";
4237
+ readonly enum: readonly ["durable", "episodic", "transient"];
4238
+ };
4239
+ readonly salience: {
4240
+ readonly type: "string";
4241
+ readonly enum: readonly ["low", "medium", "high"];
4242
+ };
4243
+ readonly evidenceConfidence: {
4244
+ readonly type: "string";
4245
+ readonly enum: readonly ["low", "medium", "high"];
4246
+ };
4247
+ readonly destination: {
4248
+ readonly type: "string";
4249
+ readonly enum: readonly ["durable_memory", "episodic_memory", "restricted_candidate", "source_only", "reject_noise"];
4250
+ };
4251
+ readonly contextEligible: {
4252
+ readonly type: "boolean";
4253
+ };
4254
+ readonly qualityContractVersion: {
4255
+ readonly type: "integer";
4256
+ readonly const: 1;
4257
+ };
3128
4258
  readonly validFrom: {
3129
4259
  readonly type: readonly ["string", "null"];
3130
4260
  readonly format: "date-time";
@@ -3144,9 +4274,13 @@ export declare const memoryExtractionJsonSchema: {
3144
4274
  readonly properties: {
3145
4275
  readonly sourceObjectId: {
3146
4276
  readonly type: "string";
4277
+ readonly minLength: 1;
4278
+ readonly maxLength: 320;
3147
4279
  };
3148
4280
  readonly segmentId: {
3149
4281
  readonly type: "string";
4282
+ readonly minLength: 1;
4283
+ readonly maxLength: 80;
3150
4284
  };
3151
4285
  readonly startOffset: {
3152
4286
  readonly type: "integer";
@@ -3158,12 +4292,15 @@ export declare const memoryExtractionJsonSchema: {
3158
4292
  };
3159
4293
  readonly quotedText: {
3160
4294
  readonly type: "string";
4295
+ readonly minLength: 1;
4296
+ readonly maxLength: 20000;
3161
4297
  };
3162
4298
  };
3163
4299
  };
3164
4300
  };
3165
4301
  readonly entities: {
3166
4302
  readonly type: "array";
4303
+ readonly maxItems: 50;
3167
4304
  readonly description: "Entities used by this record. Every entity key referenced by this record claims must be declared in this same array.";
3168
4305
  readonly items: {
3169
4306
  readonly type: "object";
@@ -3172,41 +4309,64 @@ export declare const memoryExtractionJsonSchema: {
3172
4309
  readonly properties: {
3173
4310
  readonly key: {
3174
4311
  readonly type: "string";
4312
+ readonly minLength: 1;
4313
+ readonly maxLength: 320;
3175
4314
  readonly description: "A key unique within this record and used by this record claims.";
3176
4315
  };
3177
4316
  readonly type: {
3178
4317
  readonly type: "string";
4318
+ readonly minLength: 1;
4319
+ readonly maxLength: 80;
3179
4320
  };
3180
4321
  readonly canonicalKey: {
3181
4322
  readonly type: "string";
4323
+ readonly minLength: 1;
4324
+ readonly maxLength: 320;
3182
4325
  };
3183
4326
  readonly displayName: {
3184
4327
  readonly type: readonly ["string", "null"];
4328
+ readonly minLength: 1;
4329
+ readonly maxLength: 320;
3185
4330
  };
3186
4331
  readonly attributes: {
3187
4332
  readonly type: "object";
3188
- readonly additionalProperties: true;
4333
+ readonly properties: {};
4334
+ readonly additionalProperties: false;
4335
+ readonly description: "Use the declared entity fields; source metadata is attached by the runtime.";
3189
4336
  };
3190
4337
  };
3191
4338
  };
3192
4339
  };
3193
4340
  readonly claims: {
3194
4341
  readonly type: "array";
4342
+ readonly maxItems: 100;
3195
4343
  readonly description: "Claims for this record. Entity references may only use keys declared in this same record entities array.";
3196
4344
  readonly items: {
3197
4345
  readonly type: "object";
3198
4346
  readonly additionalProperties: false;
3199
- readonly required: readonly ["subjectEntityKey", "predicate", "objectEntityKey", "literalValue", "validFrom", "validTo"];
4347
+ readonly required: readonly ["subjectEntityKey", "assertedByEntityKey", "predicate", "objectEntityKey", "literalValue", "validFrom", "validTo"];
3200
4348
  readonly properties: {
3201
4349
  readonly subjectEntityKey: {
3202
4350
  readonly type: "string";
4351
+ readonly minLength: 1;
4352
+ readonly maxLength: 320;
3203
4353
  readonly description: "Must exactly match an entities[].key in this same record.";
3204
4354
  };
4355
+ readonly assertedByEntityKey: {
4356
+ readonly type: readonly ["string", "null"];
4357
+ readonly minLength: 1;
4358
+ readonly maxLength: 320;
4359
+ readonly description: "When non-null, must exactly match an entities[].key in this same record.";
4360
+ };
3205
4361
  readonly predicate: {
3206
4362
  readonly type: "string";
4363
+ readonly minLength: 1;
4364
+ readonly maxLength: 120;
3207
4365
  };
3208
4366
  readonly objectEntityKey: {
3209
4367
  readonly type: readonly ["string", "null"];
4368
+ readonly minLength: 1;
4369
+ readonly maxLength: 320;
3210
4370
  readonly description: "When non-null, must exactly match an entities[].key in this same record.";
3211
4371
  };
3212
4372
  readonly literalValue: {
@@ -3216,10 +4376,6 @@ export declare const memoryExtractionJsonSchema: {
3216
4376
  readonly type: "number";
3217
4377
  }, {
3218
4378
  readonly type: "boolean";
3219
- }, {
3220
- readonly type: "object";
3221
- }, {
3222
- readonly type: "array";
3223
4379
  }, {
3224
4380
  readonly type: "null";
3225
4381
  }];
@@ -3237,7 +4393,9 @@ export declare const memoryExtractionJsonSchema: {
3237
4393
  };
3238
4394
  readonly attributes: {
3239
4395
  readonly type: "object";
3240
- readonly additionalProperties: true;
4396
+ readonly properties: {};
4397
+ readonly additionalProperties: false;
4398
+ readonly description: "Use the declared memory fields; source metadata is attached by the runtime.";
3241
4399
  };
3242
4400
  };
3243
4401
  };
@@ -3255,7 +4413,7 @@ export declare const memorySafetyJsonSchema: {
3255
4413
  readonly items: {
3256
4414
  readonly type: "object";
3257
4415
  readonly additionalProperties: false;
3258
- readonly required: readonly ["candidateId", "status", "sensitivityClass", "restrictedDataClasses", "reason"];
4416
+ readonly required: readonly ["candidateId", "status", "retentionStatus", "sensitivityClass", "restrictedDataClasses", "reason"];
3259
4417
  readonly properties: {
3260
4418
  readonly candidateId: {
3261
4419
  readonly type: "string";
@@ -3264,6 +4422,10 @@ export declare const memorySafetyJsonSchema: {
3264
4422
  readonly type: "string";
3265
4423
  readonly enum: readonly ["classified", "uncertain"];
3266
4424
  };
4425
+ readonly retentionStatus: {
4426
+ readonly type: "string";
4427
+ readonly enum: readonly ["memory", "source_only", "reject_noise", "uncertain"];
4428
+ };
3267
4429
  readonly sensitivityClass: {
3268
4430
  readonly type: "string";
3269
4431
  readonly enum: readonly ["standard", "personal", "restricted", "secret"];