@mastra/elasticsearch 0.0.0 → 1.0.0-beta.3

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/CHANGELOG.md CHANGED
@@ -1,5 +1,55 @@
1
1
  # @mastra/elasticsearch
2
2
 
3
+ ## 1.0.0-beta.3
4
+
5
+ ### Patch Changes
6
+
7
+ - Standardize error IDs across all storage and vector stores using centralized helper functions (`createStorageErrorId` and `createVectorErrorId`). This ensures consistent error ID patterns (`MASTRA_STORAGE_{STORE}_{OPERATION}_{STATUS}` and `MASTRA_VECTOR_{STORE}_{OPERATION}_{STATUS}`) across the codebase for better error tracking and debugging. ([#10913](https://github.com/mastra-ai/mastra/pull/10913))
8
+
9
+ - Updated dependencies [[`3076c67`](https://github.com/mastra-ai/mastra/commit/3076c6778b18988ae7d5c4c5c466366974b2d63f), [`85d7ee1`](https://github.com/mastra-ai/mastra/commit/85d7ee18ff4e14d625a8a30ec6656bb49804989b), [`c6c1092`](https://github.com/mastra-ai/mastra/commit/c6c1092f8fbf76109303f69e000e96fd1960c4ce), [`81dc110`](https://github.com/mastra-ai/mastra/commit/81dc11008d147cf5bdc8996ead1aa61dbdebb6fc), [`7aedb74`](https://github.com/mastra-ai/mastra/commit/7aedb74883adf66af38e270e4068fd42e7a37036), [`8f02d80`](https://github.com/mastra-ai/mastra/commit/8f02d800777397e4b45d7f1ad041988a8b0c6630), [`d7aad50`](https://github.com/mastra-ai/mastra/commit/d7aad501ce61646b76b4b511e558ac4eea9884d0), [`ce0a73a`](https://github.com/mastra-ai/mastra/commit/ce0a73abeaa75b10ca38f9e40a255a645d50ebfb), [`a02e542`](https://github.com/mastra-ai/mastra/commit/a02e542d23179bad250b044b17ff023caa61739f), [`a372c64`](https://github.com/mastra-ai/mastra/commit/a372c640ad1fd12e8f0613cebdc682fc156b4d95), [`8846867`](https://github.com/mastra-ai/mastra/commit/8846867ffa9a3746767618e314bebac08eb77d87), [`42a42cf`](https://github.com/mastra-ai/mastra/commit/42a42cf3132b9786feecbb8c13c583dce5b0e198), [`ae08bf0`](https://github.com/mastra-ai/mastra/commit/ae08bf0ebc6a4e4da992b711c4a389c32ba84cf4), [`21735a7`](https://github.com/mastra-ai/mastra/commit/21735a7ef306963554a69a89b44f06c3bcd85141), [`1d877b8`](https://github.com/mastra-ai/mastra/commit/1d877b8d7b536a251c1a7a18db7ddcf4f68d6f8b)]:
10
+ - @mastra/core@1.0.0-beta.7
11
+
12
+ ## 1.0.0-beta.2
13
+
14
+ ### Minor Changes
15
+
16
+ - Add ElasticSearch vector store support ([#10741](https://github.com/mastra-ai/mastra/pull/10741))
17
+
18
+ New `@mastra/elasticsearch` package providing vector similarity search using ElasticSearch 8.x+ with `dense_vector` fields.
19
+
20
+ ```typescript
21
+ import { ElasticSearchVector } from '@mastra/elasticsearch';
22
+
23
+ const vectorDB = new ElasticSearchVector({
24
+ url: 'http://localhost:9200',
25
+ id: 'my-vectors',
26
+ });
27
+
28
+ await vectorDB.createIndex({
29
+ indexName: 'embeddings',
30
+ dimension: 1536,
31
+ metric: 'cosine',
32
+ });
33
+
34
+ await vectorDB.upsert({
35
+ indexName: 'embeddings',
36
+ vectors: [embedding],
37
+ metadata: [{ source: 'doc.pdf' }],
38
+ });
39
+
40
+ const results = await vectorDB.query({
41
+ indexName: 'embeddings',
42
+ queryVector: queryEmbedding,
43
+ topK: 10,
44
+ filter: { source: 'doc.pdf' },
45
+ });
46
+ ```
47
+
48
+ ### Patch Changes
49
+
50
+ - Updated dependencies [[`ac0d2f4`](https://github.com/mastra-ai/mastra/commit/ac0d2f4ff8831f72c1c66c2be809706d17f65789), [`1a0d3fc`](https://github.com/mastra-ai/mastra/commit/1a0d3fc811482c9c376cdf79ee615c23bae9b2d6), [`85a628b`](https://github.com/mastra-ai/mastra/commit/85a628b1224a8f64cd82ea7f033774bf22df7a7e), [`c237233`](https://github.com/mastra-ai/mastra/commit/c23723399ccedf7f5744b3f40997b79246bfbe64), [`15f9e21`](https://github.com/mastra-ai/mastra/commit/15f9e216177201ea6e3f6d0bfb063fcc0953444f), [`ff94dea`](https://github.com/mastra-ai/mastra/commit/ff94dea935f4e34545c63bcb6c29804732698809), [`5b2ff46`](https://github.com/mastra-ai/mastra/commit/5b2ff4651df70c146523a7fca773f8eb0a2272f8), [`db41688`](https://github.com/mastra-ai/mastra/commit/db4168806d007417e2e60b4f68656dca4e5f40c9), [`5ca599d`](https://github.com/mastra-ai/mastra/commit/5ca599d0bb59a1595f19f58473fcd67cc71cef58), [`bff1145`](https://github.com/mastra-ai/mastra/commit/bff114556b3cbadad9b2768488708f8ad0e91475), [`5c8ca24`](https://github.com/mastra-ai/mastra/commit/5c8ca247094e0cc2cdbd7137822fb47241f86e77), [`e191844`](https://github.com/mastra-ai/mastra/commit/e1918444ca3f80e82feef1dad506cd4ec6e2875f), [`22553f1`](https://github.com/mastra-ai/mastra/commit/22553f11c63ee5e966a9c034a349822249584691), [`7237163`](https://github.com/mastra-ai/mastra/commit/72371635dbf96a87df4b073cc48fc655afbdce3d), [`2500740`](https://github.com/mastra-ai/mastra/commit/2500740ea23da067d6e50ec71c625ab3ce275e64), [`873ecbb`](https://github.com/mastra-ai/mastra/commit/873ecbb517586aa17d2f1e99283755b3ebb2863f), [`4f9bbe5`](https://github.com/mastra-ai/mastra/commit/4f9bbe5968f42c86f4930b8193de3c3c17e5bd36), [`02e51fe`](https://github.com/mastra-ai/mastra/commit/02e51feddb3d4155cfbcc42624fd0d0970d032c0), [`8f3fa3a`](https://github.com/mastra-ai/mastra/commit/8f3fa3a652bb77da092f913ec51ae46e3a7e27dc), [`cd29ad2`](https://github.com/mastra-ai/mastra/commit/cd29ad23a255534e8191f249593849ed29160886), [`bdf4d8c`](https://github.com/mastra-ai/mastra/commit/bdf4d8cdc656d8a2c21d81834bfa3bfa70f56c16), [`854e3da`](https://github.com/mastra-ai/mastra/commit/854e3dad5daac17a91a20986399d3a51f54bf68b), [`ce18d38`](https://github.com/mastra-ai/mastra/commit/ce18d38678c65870350d123955014a8432075fd9), [`cccf9c8`](https://github.com/mastra-ai/mastra/commit/cccf9c8b2d2dfc1a5e63919395b83d78c89682a0), [`61a5705`](https://github.com/mastra-ai/mastra/commit/61a570551278b6743e64243b3ce7d73de915ca8a), [`db70a48`](https://github.com/mastra-ai/mastra/commit/db70a48aeeeeb8e5f92007e8ede52c364ce15287), [`f0fdc14`](https://github.com/mastra-ai/mastra/commit/f0fdc14ee233d619266b3d2bbdeea7d25cfc6d13), [`db18bc9`](https://github.com/mastra-ai/mastra/commit/db18bc9c3825e2c1a0ad9a183cc9935f6691bfa1), [`9b37b56`](https://github.com/mastra-ai/mastra/commit/9b37b565e1f2a76c24f728945cc740c2b09be9da), [`41a23c3`](https://github.com/mastra-ai/mastra/commit/41a23c32f9877d71810f37e24930515df2ff7a0f), [`5d171ad`](https://github.com/mastra-ai/mastra/commit/5d171ad9ef340387276b77c2bb3e83e83332d729), [`f03ae60`](https://github.com/mastra-ai/mastra/commit/f03ae60500fe350c9d828621006cdafe1975fdd8), [`d1e74a0`](https://github.com/mastra-ai/mastra/commit/d1e74a0a293866dece31022047f5dbab65a304d0), [`39e7869`](https://github.com/mastra-ai/mastra/commit/39e7869bc7d0ee391077ce291474d8a84eedccff), [`5761926`](https://github.com/mastra-ai/mastra/commit/57619260c4a2cdd598763abbacd90de594c6bc76), [`c900fdd`](https://github.com/mastra-ai/mastra/commit/c900fdd504c41348efdffb205cfe80d48c38fa33), [`604a79f`](https://github.com/mastra-ai/mastra/commit/604a79fecf276e26a54a3fe01bb94e65315d2e0e), [`887f0b4`](https://github.com/mastra-ai/mastra/commit/887f0b4746cdbd7cb7d6b17ac9f82aeb58037ea5), [`2562143`](https://github.com/mastra-ai/mastra/commit/256214336b4faa78646c9c1776612393790d8784), [`ef11a61`](https://github.com/mastra-ai/mastra/commit/ef11a61920fa0ed08a5b7ceedd192875af119749)]:
51
+ - @mastra/core@1.0.0-beta.6
52
+
3
53
  ## 1.0.0-beta.1
4
54
 
5
55
  ### Major Changes
package/LICENSE.md ADDED
@@ -0,0 +1,15 @@
1
+ # Apache License 2.0
2
+
3
+ Copyright (c) 2025 Kepler Software, Inc.
4
+
5
+ Licensed under the Apache License, Version 2.0 (the "License");
6
+ you may not use this file except in compliance with the License.
7
+ You may obtain a copy of the License at
8
+
9
+ http://www.apache.org/licenses/LICENSE-2.0
10
+
11
+ Unless required by applicable law or agreed to in writing, software
12
+ distributed under the License is distributed on an "AS IS" BASIS,
13
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ See the License for the specific language governing permissions and
15
+ limitations under the License.
package/dist/index.cjs CHANGED
@@ -2,6 +2,7 @@
2
2
 
3
3
  var elasticsearch = require('@elastic/elasticsearch');
4
4
  var error = require('@mastra/core/error');
5
+ var storage = require('@mastra/core/storage');
5
6
  var vector = require('@mastra/core/vector');
6
7
  var filter = require('@mastra/core/vector/filter');
7
8
 
@@ -391,7 +392,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
391
392
  async createIndex({ indexName, dimension, metric = "cosine" }) {
392
393
  if (!Number.isInteger(dimension) || dimension <= 0) {
393
394
  throw new error.MastraError({
394
- id: "STORAGE_ELASTICSEARCH_VECTOR_CREATE_INDEX_INVALID_ARGS",
395
+ id: storage.createVectorErrorId("ELASTICSEARCH", "CREATE_INDEX", "INVALID_ARGS"),
395
396
  domain: error.ErrorDomain.STORAGE,
396
397
  category: error.ErrorCategory.USER,
397
398
  text: "Dimension must be a positive integer",
@@ -422,7 +423,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
422
423
  }
423
424
  throw new error.MastraError(
424
425
  {
425
- id: "STORAGE_ELASTICSEARCH_VECTOR_CREATE_INDEX_FAILED",
426
+ id: storage.createVectorErrorId("ELASTICSEARCH", "CREATE_INDEX", "FAILED"),
426
427
  domain: error.ErrorDomain.STORAGE,
427
428
  category: error.ErrorCategory.THIRD_PARTY,
428
429
  details: { indexName, dimension, metric }
@@ -444,7 +445,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
444
445
  } catch (error$1) {
445
446
  throw new error.MastraError(
446
447
  {
447
- id: "STORAGE_ELASTICSEARCH_VECTOR_LIST_INDEXES_FAILED",
448
+ id: storage.createVectorErrorId("ELASTICSEARCH", "LIST_INDEXES", "FAILED"),
448
449
  domain: error.ErrorDomain.STORAGE,
449
450
  category: error.ErrorCategory.THIRD_PARTY
450
451
  },
@@ -463,7 +464,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
463
464
  } catch (infoError) {
464
465
  const mastraError = new error.MastraError(
465
466
  {
466
- id: "STORAGE_ELASTICSEARCH_VECTOR_VALIDATE_INDEX_FETCH_FAILED",
467
+ id: storage.createVectorErrorId("ELASTICSEARCH", "VALIDATE_INDEX", "FETCH_FAILED"),
467
468
  text: `Index "${indexName}" already exists, but failed to fetch index info for dimension check.`,
468
469
  domain: error.ErrorDomain.STORAGE,
469
470
  category: error.ErrorCategory.SYSTEM,
@@ -488,7 +489,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
488
489
  }
489
490
  } else if (info) {
490
491
  const mastraError = new error.MastraError({
491
- id: "STORAGE_ELASTICSEARCH_VECTOR_VALIDATE_INDEX_DIMENSION_MISMATCH",
492
+ id: storage.createVectorErrorId("ELASTICSEARCH", "VALIDATE_INDEX", "DIMENSION_MISMATCH"),
492
493
  text: `Index "${indexName}" already exists with ${existingDim} dimensions, but ${dimension} dimensions were requested`,
493
494
  domain: error.ErrorDomain.STORAGE,
494
495
  category: error.ErrorCategory.USER,
@@ -533,7 +534,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
533
534
  }
534
535
  const mastraError = new error.MastraError(
535
536
  {
536
- id: "STORAGE_ELASTICSEARCH_VECTOR_DELETE_INDEX_FAILED",
537
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_INDEX", "FAILED"),
537
538
  domain: error.ErrorDomain.STORAGE,
538
539
  category: error.ErrorCategory.THIRD_PARTY,
539
540
  details: { indexName }
@@ -608,7 +609,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
608
609
  const failedItemDetails = failedItems.map((item) => `${item.id}: ${item.error?.reason || item.error?.type || JSON.stringify(item.error)}`).join("; ");
609
610
  const mastraError = new error.MastraError(
610
611
  {
611
- id: "STORAGE_ELASTICSEARCH_VECTOR_BULK_PARTIAL_FAILURE",
612
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPSERT", "BULK_PARTIAL_FAILURE"),
612
613
  text: `Bulk upsert partially failed: ${failedItems.length} of ${response.items.length} operations failed. Failed items: ${failedItemDetails}`,
613
614
  domain: error.ErrorDomain.STORAGE,
614
615
  category: error.ErrorCategory.THIRD_PARTY,
@@ -633,7 +634,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
633
634
  } catch (error$1) {
634
635
  throw new error.MastraError(
635
636
  {
636
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPSERT_FAILED",
637
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPSERT", "FAILED"),
637
638
  domain: error.ErrorDomain.STORAGE,
638
639
  category: error.ErrorCategory.THIRD_PARTY,
639
640
  details: { indexName, vectorCount: vectors?.length || 0 }
@@ -685,7 +686,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
685
686
  } catch (error$1) {
686
687
  throw new error.MastraError(
687
688
  {
688
- id: "STORAGE_ELASTICSEARCH_VECTOR_QUERY_FAILED",
689
+ id: storage.createVectorErrorId("ELASTICSEARCH", "QUERY", "FAILED"),
689
690
  domain: error.ErrorDomain.STORAGE,
690
691
  category: error.ErrorCategory.THIRD_PARTY,
691
692
  details: { indexName, topK }
@@ -730,7 +731,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
730
731
  const { indexName, update } = params;
731
732
  if ("id" in params && "filter" in params && params.id && params.filter) {
732
733
  throw new error.MastraError({
733
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPDATE_INVALID_ARGS",
734
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPDATE_VECTOR", "MUTUALLY_EXCLUSIVE"),
734
735
  domain: error.ErrorDomain.STORAGE,
735
736
  category: error.ErrorCategory.USER,
736
737
  text: "id and filter are mutually exclusive",
@@ -739,7 +740,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
739
740
  }
740
741
  if (!update.vector && !update.metadata) {
741
742
  throw new error.MastraError({
742
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPDATE_NO_UPDATES",
743
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPDATE_VECTOR", "NO_UPDATES"),
743
744
  domain: error.ErrorDomain.STORAGE,
744
745
  category: error.ErrorCategory.USER,
745
746
  text: "No updates provided",
@@ -748,7 +749,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
748
749
  }
749
750
  if ("filter" in params && params.filter && Object.keys(params.filter).length === 0) {
750
751
  throw new error.MastraError({
751
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPDATE_INVALID_ARGS",
752
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPDATE_VECTOR", "EMPTY_FILTER"),
752
753
  domain: error.ErrorDomain.STORAGE,
753
754
  category: error.ErrorCategory.USER,
754
755
  text: "Cannot update with empty filter",
@@ -761,7 +762,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
761
762
  await this.updateVectorsByFilter(indexName, params.filter, update);
762
763
  } else {
763
764
  throw new error.MastraError({
764
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPDATE_MISSING_PARAMS",
765
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPDATE_VECTOR", "NO_TARGET"),
765
766
  domain: error.ErrorDomain.STORAGE,
766
767
  category: error.ErrorCategory.USER,
767
768
  text: "Either id or filter must be provided",
@@ -788,7 +789,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
788
789
  } catch (error$1) {
789
790
  throw new error.MastraError(
790
791
  {
791
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPDATE_VECTOR_FAILED",
792
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPDATE_VECTOR", "FAILED"),
792
793
  domain: error.ErrorDomain.STORAGE,
793
794
  category: error.ErrorCategory.USER,
794
795
  details: {
@@ -825,7 +826,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
825
826
  } catch (error$1) {
826
827
  throw new error.MastraError(
827
828
  {
828
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPDATE_VECTOR_FAILED",
829
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPDATE_VECTOR", "FAILED"),
829
830
  domain: error.ErrorDomain.STORAGE,
830
831
  category: error.ErrorCategory.THIRD_PARTY,
831
832
  details: {
@@ -867,7 +868,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
867
868
  } catch (error$1) {
868
869
  throw new error.MastraError(
869
870
  {
870
- id: "STORAGE_ELASTICSEARCH_VECTOR_UPDATE_BY_FILTER_FAILED",
871
+ id: storage.createVectorErrorId("ELASTICSEARCH", "UPDATE_VECTOR_BY_FILTER", "FAILED"),
871
872
  domain: error.ErrorDomain.STORAGE,
872
873
  category: error.ErrorCategory.THIRD_PARTY,
873
874
  details: {
@@ -899,7 +900,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
899
900
  }
900
901
  throw new error.MastraError(
901
902
  {
902
- id: "STORAGE_ELASTICSEARCH_VECTOR_DELETE_VECTOR_FAILED",
903
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_VECTOR", "FAILED"),
903
904
  domain: error.ErrorDomain.STORAGE,
904
905
  category: error.ErrorCategory.THIRD_PARTY,
905
906
  details: {
@@ -914,7 +915,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
914
915
  async deleteVectors({ indexName, filter, ids }) {
915
916
  if (ids && filter) {
916
917
  throw new error.MastraError({
917
- id: "STORAGE_ELASTICSEARCH_VECTOR_DELETE_VECTORS_INVALID_ARGS",
918
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_VECTORS", "MUTUALLY_EXCLUSIVE"),
918
919
  domain: error.ErrorDomain.STORAGE,
919
920
  category: error.ErrorCategory.USER,
920
921
  text: "ids and filter are mutually exclusive",
@@ -923,7 +924,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
923
924
  }
924
925
  if (!ids && !filter) {
925
926
  throw new error.MastraError({
926
- id: "STORAGE_ELASTICSEARCH_VECTOR_DELETE_VECTORS_INVALID_ARGS",
927
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_VECTORS", "NO_TARGET"),
927
928
  domain: error.ErrorDomain.STORAGE,
928
929
  category: error.ErrorCategory.USER,
929
930
  text: "Either filter or ids must be provided",
@@ -932,7 +933,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
932
933
  }
933
934
  if (ids && ids.length === 0) {
934
935
  throw new error.MastraError({
935
- id: "STORAGE_ELASTICSEARCH_VECTOR_DELETE_VECTORS_INVALID_ARGS",
936
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_VECTORS", "EMPTY_IDS"),
936
937
  domain: error.ErrorDomain.STORAGE,
937
938
  category: error.ErrorCategory.USER,
938
939
  text: "Cannot delete with empty ids array",
@@ -941,7 +942,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
941
942
  }
942
943
  if (filter && Object.keys(filter).length === 0) {
943
944
  throw new error.MastraError({
944
- id: "STORAGE_ELASTICSEARCH_VECTOR_DELETE_VECTORS_INVALID_ARGS",
945
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_VECTORS", "EMPTY_FILTER"),
945
946
  domain: error.ErrorDomain.STORAGE,
946
947
  category: error.ErrorCategory.USER,
947
948
  text: "Cannot delete with empty filter",
@@ -986,7 +987,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
986
987
  const failedItemDetails = failedItems.map((item) => `${item.id}: ${item.error?.reason || item.error?.type || JSON.stringify(item.error)}`).join("; ");
987
988
  const mastraError = new error.MastraError(
988
989
  {
989
- id: "STORAGE_ELASTICSEARCH_VECTOR_BULK_DELETE_PARTIAL_FAILURE",
990
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_VECTORS", "BULK_PARTIAL_FAILURE"),
990
991
  text: `Bulk delete partially failed: ${failedItems.length} of ${response.items.length} operations failed. Failed items: ${failedItemDetails}`,
991
992
  domain: error.ErrorDomain.STORAGE,
992
993
  category: error.ErrorCategory.THIRD_PARTY,
@@ -1019,7 +1020,7 @@ var ElasticSearchVector = class extends vector.MastraVector {
1019
1020
  if (error$1 instanceof error.MastraError) throw error$1;
1020
1021
  throw new error.MastraError(
1021
1022
  {
1022
- id: "STORAGE_ELASTICSEARCH_VECTOR_DELETE_VECTORS_FAILED",
1023
+ id: storage.createVectorErrorId("ELASTICSEARCH", "DELETE_VECTORS", "FAILED"),
1023
1024
  domain: error.ErrorDomain.STORAGE,
1024
1025
  category: error.ErrorCategory.THIRD_PARTY,
1025
1026
  details: {