@memorylayerai/sdk 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs ADDED
@@ -0,0 +1,728 @@
1
+ "use strict";
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __esm = (fn, res) => function __init() {
7
+ return fn && (res = (0, fn[__getOwnPropNames(fn)[0]])(fn = 0)), res;
8
+ };
9
+ var __export = (target, all) => {
10
+ for (var name in all)
11
+ __defProp(target, name, { get: all[name], enumerable: true });
12
+ };
13
+ var __copyProps = (to, from, except, desc) => {
14
+ if (from && typeof from === "object" || typeof from === "function") {
15
+ for (let key of __getOwnPropNames(from))
16
+ if (!__hasOwnProp.call(to, key) && key !== except)
17
+ __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
18
+ }
19
+ return to;
20
+ };
21
+ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
22
+
23
+ // src/errors.ts
24
+ var MemoryLayerError, AuthenticationError, RateLimitError, ValidationError, NetworkError, APIError;
25
+ var init_errors = __esm({
26
+ "src/errors.ts"() {
27
+ "use strict";
28
+ MemoryLayerError = class _MemoryLayerError extends Error {
29
+ constructor(message, statusCode, requestId, details) {
30
+ super(message);
31
+ this.statusCode = statusCode;
32
+ this.requestId = requestId;
33
+ this.details = details;
34
+ this.name = "MemoryLayerError";
35
+ Object.setPrototypeOf(this, _MemoryLayerError.prototype);
36
+ }
37
+ };
38
+ AuthenticationError = class _AuthenticationError extends MemoryLayerError {
39
+ constructor(message, requestId) {
40
+ super(message, 401, requestId);
41
+ this.name = "AuthenticationError";
42
+ Object.setPrototypeOf(this, _AuthenticationError.prototype);
43
+ }
44
+ };
45
+ RateLimitError = class _RateLimitError extends MemoryLayerError {
46
+ constructor(message, retryAfter, requestId) {
47
+ super(message, 429, requestId);
48
+ this.retryAfter = retryAfter;
49
+ this.name = "RateLimitError";
50
+ Object.setPrototypeOf(this, _RateLimitError.prototype);
51
+ }
52
+ };
53
+ ValidationError = class _ValidationError extends MemoryLayerError {
54
+ constructor(message, errors, requestId) {
55
+ super(message, 400, requestId);
56
+ this.errors = errors;
57
+ this.name = "ValidationError";
58
+ Object.setPrototypeOf(this, _ValidationError.prototype);
59
+ }
60
+ };
61
+ NetworkError = class _NetworkError extends MemoryLayerError {
62
+ constructor(message, cause) {
63
+ super(message);
64
+ this.cause = cause;
65
+ this.name = "NetworkError";
66
+ Object.setPrototypeOf(this, _NetworkError.prototype);
67
+ }
68
+ };
69
+ APIError = class _APIError extends MemoryLayerError {
70
+ constructor(message, statusCode, requestId, details) {
71
+ super(message, statusCode, requestId, details);
72
+ this.name = "APIError";
73
+ Object.setPrototypeOf(this, _APIError.prototype);
74
+ }
75
+ };
76
+ }
77
+ });
78
+
79
+ // src/resources/memories.ts
80
+ var memories_exports = {};
81
+ __export(memories_exports, {
82
+ MemoriesResource: () => MemoriesResource
83
+ });
84
+ var MemoriesResource;
85
+ var init_memories = __esm({
86
+ "src/resources/memories.ts"() {
87
+ "use strict";
88
+ init_errors();
89
+ MemoriesResource = class {
90
+ constructor(httpClient) {
91
+ this.httpClient = httpClient;
92
+ }
93
+ /**
94
+ * Add a new memory
95
+ * @param request - Memory creation request
96
+ * @returns The created memory
97
+ */
98
+ async add(request) {
99
+ if (!request.content || request.content.trim().length === 0) {
100
+ throw new ValidationError(
101
+ "Memory content cannot be empty",
102
+ [{ field: "content", message: "Content is required and cannot be empty" }]
103
+ );
104
+ }
105
+ if (!request.projectId || request.projectId.trim().length === 0) {
106
+ throw new ValidationError(
107
+ "Project ID is required",
108
+ [{ field: "projectId", message: "Project ID is required" }]
109
+ );
110
+ }
111
+ return this.httpClient.request({
112
+ method: "POST",
113
+ path: "/v1/memories",
114
+ body: request
115
+ });
116
+ }
117
+ /**
118
+ * Get a memory by ID
119
+ * @param id - Memory ID
120
+ * @returns The memory
121
+ */
122
+ async get(id) {
123
+ if (!id || id.trim().length === 0) {
124
+ throw new ValidationError(
125
+ "Memory ID is required",
126
+ [{ field: "id", message: "Memory ID is required" }]
127
+ );
128
+ }
129
+ return this.httpClient.request({
130
+ method: "GET",
131
+ path: `/v1/memories/${id}`
132
+ });
133
+ }
134
+ /**
135
+ * Update a memory
136
+ * @param id - Memory ID
137
+ * @param request - Update request
138
+ * @returns The updated memory
139
+ */
140
+ async update(id, request) {
141
+ if (!id || id.trim().length === 0) {
142
+ throw new ValidationError(
143
+ "Memory ID is required",
144
+ [{ field: "id", message: "Memory ID is required" }]
145
+ );
146
+ }
147
+ if (!request.content && !request.metadata) {
148
+ throw new ValidationError(
149
+ "At least one of content or metadata must be provided",
150
+ [{ field: "request", message: "Nothing to update" }]
151
+ );
152
+ }
153
+ return this.httpClient.request({
154
+ method: "PATCH",
155
+ path: `/v1/memories/${id}`,
156
+ body: request
157
+ });
158
+ }
159
+ /**
160
+ * Delete a memory
161
+ * @param id - Memory ID
162
+ */
163
+ async delete(id) {
164
+ if (!id || id.trim().length === 0) {
165
+ throw new ValidationError(
166
+ "Memory ID is required",
167
+ [{ field: "id", message: "Memory ID is required" }]
168
+ );
169
+ }
170
+ await this.httpClient.request({
171
+ method: "DELETE",
172
+ path: `/v1/memories/${id}`
173
+ });
174
+ }
175
+ /**
176
+ * List memories
177
+ * @param request - List request with filters
178
+ * @returns Array of memories
179
+ */
180
+ async list(request) {
181
+ if (!request.projectId || request.projectId.trim().length === 0) {
182
+ throw new ValidationError(
183
+ "Project ID is required",
184
+ [{ field: "projectId", message: "Project ID is required" }]
185
+ );
186
+ }
187
+ const query = {
188
+ projectId: request.projectId
189
+ };
190
+ if (request.limit !== void 0) {
191
+ query.limit = request.limit.toString();
192
+ }
193
+ if (request.offset !== void 0) {
194
+ query.offset = request.offset.toString();
195
+ }
196
+ if (request.filter) {
197
+ query.filter = JSON.stringify(request.filter);
198
+ }
199
+ return this.httpClient.request({
200
+ method: "GET",
201
+ path: "/v1/memories",
202
+ query
203
+ });
204
+ }
205
+ };
206
+ }
207
+ });
208
+
209
+ // src/resources/search.ts
210
+ var search_exports = {};
211
+ __export(search_exports, {
212
+ SearchResource: () => SearchResource
213
+ });
214
+ var SearchResource;
215
+ var init_search = __esm({
216
+ "src/resources/search.ts"() {
217
+ "use strict";
218
+ init_errors();
219
+ SearchResource = class {
220
+ constructor(httpClient) {
221
+ this.httpClient = httpClient;
222
+ }
223
+ /**
224
+ * Search memories
225
+ * @param request - Search request
226
+ * @returns Search results
227
+ */
228
+ async search(request) {
229
+ if (!request.query || request.query.trim().length === 0) {
230
+ throw new ValidationError(
231
+ "Search query cannot be empty",
232
+ [{ field: "query", message: "Query is required and cannot be empty" }]
233
+ );
234
+ }
235
+ if (!request.projectId || request.projectId.trim().length === 0) {
236
+ throw new ValidationError(
237
+ "Project ID is required",
238
+ [{ field: "projectId", message: "Project ID is required" }]
239
+ );
240
+ }
241
+ const query = {
242
+ q: request.query,
243
+ projectId: request.projectId
244
+ };
245
+ if (request.limit !== void 0) {
246
+ query.limit = request.limit.toString();
247
+ }
248
+ if (request.threshold !== void 0) {
249
+ query.threshold = request.threshold.toString();
250
+ }
251
+ if (request.filter) {
252
+ query.filter = JSON.stringify(request.filter);
253
+ }
254
+ return this.httpClient.request({
255
+ method: "GET",
256
+ path: "/v1/search",
257
+ query
258
+ });
259
+ }
260
+ };
261
+ }
262
+ });
263
+
264
+ // src/resources/ingest.ts
265
+ var ingest_exports = {};
266
+ __export(ingest_exports, {
267
+ IngestResource: () => IngestResource
268
+ });
269
+ var IngestResource;
270
+ var init_ingest = __esm({
271
+ "src/resources/ingest.ts"() {
272
+ "use strict";
273
+ init_errors();
274
+ IngestResource = class {
275
+ constructor(httpClient) {
276
+ this.httpClient = httpClient;
277
+ }
278
+ /**
279
+ * Ingest a file
280
+ * @param request - File ingestion request
281
+ * @returns Ingestion response with created memory IDs
282
+ */
283
+ async file(request) {
284
+ if (!request.file) {
285
+ throw new ValidationError(
286
+ "File is required",
287
+ [{ field: "file", message: "File is required" }]
288
+ );
289
+ }
290
+ if (!request.projectId || request.projectId.trim().length === 0) {
291
+ throw new ValidationError(
292
+ "Project ID is required",
293
+ [{ field: "projectId", message: "Project ID is required" }]
294
+ );
295
+ }
296
+ const body = {
297
+ projectId: request.projectId,
298
+ metadata: request.metadata,
299
+ chunkSize: request.chunkSize,
300
+ chunkOverlap: request.chunkOverlap,
301
+ // In a real implementation, you'd convert the file to base64 or use FormData
302
+ file: request.file
303
+ };
304
+ return this.httpClient.request({
305
+ method: "POST",
306
+ path: "/v1/ingest/file",
307
+ body
308
+ });
309
+ }
310
+ /**
311
+ * Ingest text
312
+ * @param request - Text ingestion request
313
+ * @returns Ingestion response with created memory IDs
314
+ */
315
+ async text(request) {
316
+ if (!request.text || request.text.trim().length === 0) {
317
+ throw new ValidationError(
318
+ "Text cannot be empty",
319
+ [{ field: "text", message: "Text is required and cannot be empty" }]
320
+ );
321
+ }
322
+ if (!request.projectId || request.projectId.trim().length === 0) {
323
+ throw new ValidationError(
324
+ "Project ID is required",
325
+ [{ field: "projectId", message: "Project ID is required" }]
326
+ );
327
+ }
328
+ return this.httpClient.request({
329
+ method: "POST",
330
+ path: "/v1/ingest/text",
331
+ body: request
332
+ });
333
+ }
334
+ };
335
+ }
336
+ });
337
+
338
+ // src/resources/router.ts
339
+ var router_exports = {};
340
+ __export(router_exports, {
341
+ RouterResource: () => RouterResource
342
+ });
343
+ var RouterResource;
344
+ var init_router = __esm({
345
+ "src/resources/router.ts"() {
346
+ "use strict";
347
+ init_errors();
348
+ RouterResource = class {
349
+ constructor(httpClient) {
350
+ this.httpClient = httpClient;
351
+ }
352
+ /**
353
+ * Complete a router request (non-streaming)
354
+ * @param request - Router request
355
+ * @returns Router response
356
+ */
357
+ async complete(request) {
358
+ if (!request.messages || request.messages.length === 0) {
359
+ throw new ValidationError(
360
+ "Messages array cannot be empty",
361
+ [{ field: "messages", message: "At least one message is required" }]
362
+ );
363
+ }
364
+ if (!request.projectId || request.projectId.trim().length === 0) {
365
+ throw new ValidationError(
366
+ "Project ID is required",
367
+ [{ field: "projectId", message: "Project ID is required" }]
368
+ );
369
+ }
370
+ return this.httpClient.request({
371
+ method: "POST",
372
+ path: "/v1/router/complete",
373
+ body: {
374
+ ...request,
375
+ stream: false
376
+ }
377
+ });
378
+ }
379
+ /**
380
+ * Stream a router request
381
+ * @param request - Router request
382
+ * @returns Async iterable of stream chunks
383
+ */
384
+ async *stream(request) {
385
+ if (!request.messages || request.messages.length === 0) {
386
+ throw new ValidationError(
387
+ "Messages array cannot be empty",
388
+ [{ field: "messages", message: "At least one message is required" }]
389
+ );
390
+ }
391
+ if (!request.projectId || request.projectId.trim().length === 0) {
392
+ throw new ValidationError(
393
+ "Project ID is required",
394
+ [{ field: "projectId", message: "Project ID is required" }]
395
+ );
396
+ }
397
+ const stream = this.httpClient.stream({
398
+ method: "POST",
399
+ path: "/v1/router/complete",
400
+ body: {
401
+ ...request,
402
+ stream: true
403
+ }
404
+ });
405
+ try {
406
+ for await (const chunk of stream) {
407
+ yield chunk;
408
+ }
409
+ } catch (error) {
410
+ throw error;
411
+ }
412
+ }
413
+ };
414
+ }
415
+ });
416
+
417
+ // src/index.ts
418
+ var index_exports = {};
419
+ __export(index_exports, {
420
+ APIError: () => APIError,
421
+ AuthenticationError: () => AuthenticationError,
422
+ IngestResource: () => IngestResource,
423
+ MemoriesResource: () => MemoriesResource,
424
+ MemoryLayerClient: () => MemoryLayerClient,
425
+ MemoryLayerError: () => MemoryLayerError,
426
+ NetworkError: () => NetworkError,
427
+ RateLimitError: () => RateLimitError,
428
+ RouterResource: () => RouterResource,
429
+ SearchResource: () => SearchResource,
430
+ ValidationError: () => ValidationError
431
+ });
432
+ module.exports = __toCommonJS(index_exports);
433
+
434
+ // src/http-client.ts
435
+ init_errors();
436
+ var HTTPClient = class {
437
+ constructor(config, retryConfig) {
438
+ this.config = config;
439
+ this.baseURL = config.baseURL || "https://api.memorylayer.com";
440
+ this.retryConfig = {
441
+ maxRetries: config.maxRetries ?? 3,
442
+ initialDelay: config.retryDelay ?? 1e3,
443
+ maxDelay: 3e4,
444
+ backoffMultiplier: 2,
445
+ retryableStatusCodes: [429, 500, 502, 503, 504],
446
+ ...retryConfig
447
+ };
448
+ }
449
+ /**
450
+ * Make an HTTP request with retry logic
451
+ */
452
+ async request(options) {
453
+ let lastError = null;
454
+ for (let attempt = 0; attempt <= this.retryConfig.maxRetries; attempt++) {
455
+ try {
456
+ return await this.makeRequest(options);
457
+ } catch (error) {
458
+ lastError = error;
459
+ if (!this.shouldRetry(error, attempt)) {
460
+ throw error;
461
+ }
462
+ const delay = this.getRetryDelay(error, attempt);
463
+ this.config.logger?.debug(`Retrying request after ${delay}ms (attempt ${attempt + 1}/${this.retryConfig.maxRetries})`);
464
+ await this.sleep(delay);
465
+ }
466
+ }
467
+ throw lastError;
468
+ }
469
+ /**
470
+ * Make a streaming request
471
+ */
472
+ async *stream(options) {
473
+ const url = this.buildURL(options.path, options.query);
474
+ const headers = this.buildHeaders(options.headers);
475
+ try {
476
+ const response = await fetch(url, {
477
+ method: options.method,
478
+ headers,
479
+ body: options.body ? JSON.stringify(options.body) : void 0,
480
+ signal: AbortSignal.timeout(options.timeout || this.config.timeout || 6e4)
481
+ });
482
+ if (!response.ok) {
483
+ throw await this.handleErrorResponse(response);
484
+ }
485
+ if (!response.body) {
486
+ throw new NetworkError("Response body is null", new Error("No response body"));
487
+ }
488
+ const reader = response.body.getReader();
489
+ const decoder = new TextDecoder();
490
+ let buffer = "";
491
+ try {
492
+ while (true) {
493
+ const { done, value } = await reader.read();
494
+ if (done) {
495
+ break;
496
+ }
497
+ buffer += decoder.decode(value, { stream: true });
498
+ const lines = buffer.split("\n");
499
+ buffer = lines.pop() || "";
500
+ for (const line of lines) {
501
+ if (line.trim() === "") continue;
502
+ if (line.startsWith("data: ")) {
503
+ const data = line.slice(6);
504
+ if (data === "[DONE]") continue;
505
+ try {
506
+ yield JSON.parse(data);
507
+ } catch (e) {
508
+ this.config.logger?.warn("Failed to parse streaming chunk:", data);
509
+ }
510
+ }
511
+ }
512
+ }
513
+ } finally {
514
+ reader.releaseLock();
515
+ }
516
+ } catch (error) {
517
+ if (error instanceof MemoryLayerError) {
518
+ throw error;
519
+ }
520
+ throw new NetworkError("Streaming request failed", error);
521
+ }
522
+ }
523
+ /**
524
+ * Make the actual HTTP request
525
+ */
526
+ async makeRequest(options) {
527
+ const url = this.buildURL(options.path, options.query);
528
+ const headers = this.buildHeaders(options.headers);
529
+ try {
530
+ const response = await fetch(url, {
531
+ method: options.method,
532
+ headers,
533
+ body: options.body ? JSON.stringify(options.body) : void 0,
534
+ signal: AbortSignal.timeout(options.timeout || this.config.timeout || 3e4)
535
+ });
536
+ if (!response.ok) {
537
+ throw await this.handleErrorResponse(response);
538
+ }
539
+ return await response.json();
540
+ } catch (error) {
541
+ if (error instanceof MemoryLayerError) {
542
+ throw error;
543
+ }
544
+ throw new NetworkError("Request failed", error);
545
+ }
546
+ }
547
+ /**
548
+ * Build the full URL with query parameters
549
+ */
550
+ buildURL(path, query) {
551
+ const url = new URL(path, this.baseURL);
552
+ if (query) {
553
+ Object.entries(query).forEach(([key, value]) => {
554
+ url.searchParams.append(key, value);
555
+ });
556
+ }
557
+ return url.toString();
558
+ }
559
+ /**
560
+ * Build request headers
561
+ */
562
+ buildHeaders(additionalHeaders) {
563
+ return {
564
+ "Content-Type": "application/json",
565
+ "Authorization": `Bearer ${this.config.apiKey}`,
566
+ "X-SDK-Version": "0.1.0",
567
+ "X-API-Version": "v1",
568
+ ...this.config.headers,
569
+ ...additionalHeaders
570
+ };
571
+ }
572
+ /**
573
+ * Handle error responses from the API
574
+ */
575
+ async handleErrorResponse(response) {
576
+ const requestId = response.headers.get("x-request-id") || void 0;
577
+ let errorData;
578
+ try {
579
+ errorData = await response.json();
580
+ } catch {
581
+ errorData = { message: response.statusText };
582
+ }
583
+ const message = errorData.error?.message || errorData.message || "Unknown error";
584
+ const details = errorData.error?.details || errorData.details;
585
+ switch (response.status) {
586
+ case 401:
587
+ return new AuthenticationError(message, requestId);
588
+ case 429:
589
+ const retryAfter = parseInt(response.headers.get("retry-after") || "60", 10);
590
+ return new RateLimitError(message, retryAfter, requestId);
591
+ case 400:
592
+ const errors = errorData.error?.errors || [];
593
+ return new ValidationError(message, errors, requestId);
594
+ default:
595
+ return new APIError(message, response.status, requestId, details);
596
+ }
597
+ }
598
+ /**
599
+ * Determine if an error should be retried
600
+ */
601
+ shouldRetry(error, attempt) {
602
+ if (attempt >= this.retryConfig.maxRetries) {
603
+ return false;
604
+ }
605
+ if (error instanceof NetworkError) {
606
+ return true;
607
+ }
608
+ if (error instanceof RateLimitError) {
609
+ return true;
610
+ }
611
+ if (error.statusCode && this.retryConfig.retryableStatusCodes.includes(error.statusCode)) {
612
+ return true;
613
+ }
614
+ if (error.statusCode && error.statusCode >= 400 && error.statusCode < 500) {
615
+ return false;
616
+ }
617
+ return false;
618
+ }
619
+ /**
620
+ * Calculate retry delay with exponential backoff
621
+ */
622
+ getRetryDelay(error, attempt) {
623
+ if (error instanceof RateLimitError) {
624
+ return error.retryAfter * 1e3;
625
+ }
626
+ const exponentialDelay = this.retryConfig.initialDelay * Math.pow(this.retryConfig.backoffMultiplier, attempt);
627
+ const jitter = Math.random() * 0.1 * exponentialDelay;
628
+ const delay = Math.min(exponentialDelay + jitter, this.retryConfig.maxDelay);
629
+ return delay;
630
+ }
631
+ /**
632
+ * Sleep for a specified duration
633
+ */
634
+ sleep(ms) {
635
+ return new Promise((resolve) => setTimeout(resolve, ms));
636
+ }
637
+ };
638
+
639
+ // src/client.ts
640
+ init_errors();
641
+ var MemoryLayerClient = class {
642
+ constructor(config = {}) {
643
+ const apiKey = config.apiKey || process.env.MEMORYLAYER_API_KEY;
644
+ if (!apiKey) {
645
+ throw new ValidationError(
646
+ "API key is required. Provide it via config.apiKey or MEMORYLAYER_API_KEY environment variable.",
647
+ [{ field: "apiKey", message: "API key is required" }]
648
+ );
649
+ }
650
+ if (typeof apiKey !== "string" || apiKey.trim().length === 0) {
651
+ throw new ValidationError(
652
+ "API key must be a non-empty string",
653
+ [{ field: "apiKey", message: "API key must be a non-empty string" }]
654
+ );
655
+ }
656
+ const httpConfig = {
657
+ apiKey,
658
+ baseURL: config.baseURL,
659
+ timeout: config.timeout,
660
+ maxRetries: config.maxRetries,
661
+ retryDelay: config.retryDelay,
662
+ headers: config.headers,
663
+ logger: config.logger
664
+ };
665
+ this.httpClient = new HTTPClient(httpConfig);
666
+ }
667
+ /**
668
+ * Access memory operations
669
+ */
670
+ get memories() {
671
+ if (!this._memories) {
672
+ const { MemoriesResource: MemoriesResource2 } = (init_memories(), __toCommonJS(memories_exports));
673
+ this._memories = new MemoriesResource2(this.httpClient);
674
+ }
675
+ return this._memories;
676
+ }
677
+ /**
678
+ * Access search operations
679
+ */
680
+ get search() {
681
+ if (!this._search) {
682
+ const { SearchResource: SearchResource2 } = (init_search(), __toCommonJS(search_exports));
683
+ this._search = new SearchResource2(this.httpClient);
684
+ }
685
+ return this._search;
686
+ }
687
+ /**
688
+ * Access ingestion operations
689
+ */
690
+ get ingest() {
691
+ if (!this._ingest) {
692
+ const { IngestResource: IngestResource2 } = (init_ingest(), __toCommonJS(ingest_exports));
693
+ this._ingest = new IngestResource2(this.httpClient);
694
+ }
695
+ return this._ingest;
696
+ }
697
+ /**
698
+ * Access router operations
699
+ */
700
+ get router() {
701
+ if (!this._router) {
702
+ const { RouterResource: RouterResource2 } = (init_router(), __toCommonJS(router_exports));
703
+ this._router = new RouterResource2(this.httpClient);
704
+ }
705
+ return this._router;
706
+ }
707
+ };
708
+
709
+ // src/index.ts
710
+ init_errors();
711
+ init_memories();
712
+ init_search();
713
+ init_ingest();
714
+ init_router();
715
+ // Annotate the CommonJS export names for ESM import in node:
716
+ 0 && (module.exports = {
717
+ APIError,
718
+ AuthenticationError,
719
+ IngestResource,
720
+ MemoriesResource,
721
+ MemoryLayerClient,
722
+ MemoryLayerError,
723
+ NetworkError,
724
+ RateLimitError,
725
+ RouterResource,
726
+ SearchResource,
727
+ ValidationError
728
+ });