@mastra/lance 0.0.0-fix-generate-title-20250616171351 → 0.0.0-fix-fetching-workflow-snapshots-20250625000954

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,21 +1,108 @@
1
1
  # @mastra/lance
2
2
 
3
- ## 0.0.0-fix-generate-title-20250616171351
3
+ ## 0.0.0-fix-fetching-workflow-snapshots-20250625000954
4
+
5
+ ### Minor Changes
6
+
7
+ - 8a3bfd2: Update peerdeps to latest core
8
+
9
+ ### Patch Changes
10
+
11
+ - d8f2d19: Add updateMessages API to storage classes (only support for PG and LibSQL for now) and to memory class. Additionally allow for metadata to be saved in the content field of a message.
12
+ - 0fb9d64: [MASTRA-4018] Update saveMessages in storage adapters to upsert messages
13
+ - 2097952: [MASTRA-4021] Fix PG getMessages and update messageLimit for all storage adapters
14
+ - 144eb0b: [MASTRA-3669] Metadata Filter Types
15
+ - 0e17048: Throw mastra errors in storage packages
16
+ - Updated dependencies [15e9d26]
17
+ - Updated dependencies [d1baedb]
18
+ - Updated dependencies [d8f2d19]
19
+ - Updated dependencies [4d21bf2]
20
+ - Updated dependencies [07d6d88]
21
+ - Updated dependencies [9d52b17]
22
+ - Updated dependencies [2097952]
23
+ - Updated dependencies [792c4c0]
24
+ - Updated dependencies [5d74aab]
25
+ - Updated dependencies [a8b194f]
26
+ - Updated dependencies [4fb0cc2]
27
+ - Updated dependencies [d2a7a31]
28
+ - Updated dependencies [502fe05]
29
+ - Updated dependencies [144eb0b]
30
+ - Updated dependencies [8ba1b51]
31
+ - Updated dependencies [4efcfa0]
32
+ - Updated dependencies [0e17048]
33
+ - @mastra/core@0.0.0-fix-fetching-workflow-snapshots-20250625000954
34
+
35
+ ## 0.2.0-alpha.3
36
+
37
+ ### Minor Changes
38
+
39
+ - 8a3bfd2: Update peerdeps to latest core
40
+
41
+ ### Patch Changes
42
+
43
+ - Updated dependencies [792c4c0]
44
+ - Updated dependencies [502fe05]
45
+ - Updated dependencies [4efcfa0]
46
+ - @mastra/core@0.10.7-alpha.3
47
+
48
+ ## 0.1.3-alpha.2
49
+
50
+ ### Patch Changes
51
+
52
+ - 0fb9d64: [MASTRA-4018] Update saveMessages in storage adapters to upsert messages
53
+ - 144eb0b: [MASTRA-3669] Metadata Filter Types
54
+ - Updated dependencies [15e9d26]
55
+ - Updated dependencies [07d6d88]
56
+ - Updated dependencies [5d74aab]
57
+ - Updated dependencies [144eb0b]
58
+ - @mastra/core@0.10.7-alpha.2
59
+
60
+ ## 0.1.3-alpha.1
61
+
62
+ ### Patch Changes
63
+
64
+ - 2097952: [MASTRA-4021] Fix PG getMessages and update messageLimit for all storage adapters
65
+ - 0e17048: Throw mastra errors in storage packages
66
+ - Updated dependencies [d1baedb]
67
+ - Updated dependencies [4d21bf2]
68
+ - Updated dependencies [2097952]
69
+ - Updated dependencies [4fb0cc2]
70
+ - Updated dependencies [d2a7a31]
71
+ - Updated dependencies [0e17048]
72
+ - @mastra/core@0.10.7-alpha.1
73
+
74
+ ## 0.1.3-alpha.0
75
+
76
+ ### Patch Changes
77
+
78
+ - d8f2d19: Add updateMessages API to storage classes (only support for PG and LibSQL for now) and to memory class. Additionally allow for metadata to be saved in the content field of a message.
79
+ - Updated dependencies [d8f2d19]
80
+ - Updated dependencies [9d52b17]
81
+ - Updated dependencies [8ba1b51]
82
+ - @mastra/core@0.10.7-alpha.0
83
+
84
+ ## 0.1.2
4
85
 
5
86
  ### Patch Changes
6
87
 
7
88
  - 63f6b7d: dependencies updates:
8
89
  - Updated dependency [`@lancedb/lancedb@^0.18.2` ↗︎](https://www.npmjs.com/package/@lancedb/lancedb/v/0.18.2) (from `^0.18.1`, in `dependencies`)
9
90
  - Updated dependencies [63f6b7d]
10
- - Updated dependencies [9d56287]
91
+ - Updated dependencies [12a95fc]
92
+ - Updated dependencies [4b0f8a6]
93
+ - Updated dependencies [51264a5]
94
+ - Updated dependencies [8e6f677]
95
+ - Updated dependencies [d70c420]
11
96
  - Updated dependencies [ee9af57]
12
97
  - Updated dependencies [36f1c36]
98
+ - Updated dependencies [2a16996]
13
99
  - Updated dependencies [10d352e]
100
+ - Updated dependencies [9589624]
14
101
  - Updated dependencies [53d3c37]
15
102
  - Updated dependencies [751c894]
16
103
  - Updated dependencies [577ce3a]
17
104
  - Updated dependencies [9260b3a]
18
- - @mastra/core@0.0.0-fix-generate-title-20250616171351
105
+ - @mastra/core@0.10.6
19
106
 
20
107
  ## 0.1.2-alpha.0
21
108
 
@@ -1,6 +1,7 @@
1
1
  import { ArrayOperator } from '@mastra/core/vector/filter';
2
2
  import { BaseFilterTranslator } from '@mastra/core/vector/filter';
3
3
  import { BasicOperator } from '@mastra/core/vector/filter';
4
+ import type { BlacklistedRootOperators } from '@mastra/core/vector/filter';
4
5
  import type { ConnectionOptions } from '@lancedb/lancedb';
5
6
  import type { CreateIndexParams } from '@mastra/core';
6
7
  import type { CreateTableOptions } from '@lancedb/lancedb';
@@ -10,11 +11,14 @@ import type { DescribeIndexParams } from '@mastra/core';
10
11
  import type { EvalRow } from '@mastra/core/storage';
11
12
  import type { IndexStats } from '@mastra/core';
12
13
  import { LogicalOperator } from '@mastra/core/vector/filter';
14
+ import type { LogicalOperatorValueMap } from '@mastra/core/vector/filter';
15
+ import type { MastraMessageContentV2 } from '@mastra/core/agent';
13
16
  import type { MastraMessageV1 } from '@mastra/core/memory';
14
17
  import type { MastraMessageV2 } from '@mastra/core/memory';
15
18
  import { MastraStorage } from '@mastra/core/storage';
16
19
  import { MastraVector } from '@mastra/core/vector';
17
20
  import { NumericOperator } from '@mastra/core/vector/filter';
21
+ import type { OperatorValueMap } from '@mastra/core/vector/filter';
18
22
  import type { PaginationInfo } from '@mastra/core/storage';
19
23
  import type { QueryResult } from '@mastra/core';
20
24
  import type { QueryVectorParams } from '@mastra/core';
@@ -52,13 +56,15 @@ declare interface IVFConfig {
52
56
  lists?: number;
53
57
  }
54
58
 
59
+ declare type LanceBlacklisted = BlacklistedRootOperators | '$like' | '$notLike' | '$contains';
60
+
55
61
  declare interface LanceCreateIndexParams extends CreateIndexParams {
56
62
  indexConfig?: LanceIndexConfig;
57
63
  tableName?: string;
58
64
  }
59
65
 
60
- export declare class LanceFilterTranslator extends BaseFilterTranslator {
61
- translate(filter: VectorFilter): string;
66
+ export declare class LanceFilterTranslator extends BaseFilterTranslator<LanceVectorFilter, string> {
67
+ translate(filter: LanceVectorFilter): string;
62
68
  private processFilter;
63
69
  private processLogicalOperator;
64
70
  private processNestedObject;
@@ -93,7 +99,13 @@ declare interface LanceIndexConfig extends IndexConfig {
93
99
  numSubVectors?: number;
94
100
  }
95
101
 
96
- declare interface LanceQueryVectorParams extends QueryVectorParams {
102
+ declare type LanceOperatorValueMap = OperatorValueMap & {
103
+ $like: string;
104
+ $notLike: string;
105
+ $contains: string;
106
+ };
107
+
108
+ declare interface LanceQueryVectorParams extends QueryVectorParams<LanceVectorFilter> {
97
109
  tableName: string;
98
110
  columns?: string[];
99
111
  includeAllColumns?: boolean;
@@ -124,6 +136,7 @@ declare class LanceStorage extends MastraStorage {
124
136
  * ```
125
137
  */
126
138
  static create(name: string, uri: string, options?: ConnectionOptions): Promise<LanceStorage>;
139
+ private getPrimaryKeys;
127
140
  /**
128
141
  * @internal
129
142
  * Private constructor to enforce using the create factory method
@@ -309,6 +322,15 @@ declare class LanceStorage extends MastraStorage {
309
322
  getMessagesPaginated(_args: StorageGetMessagesArg): Promise<PaginationInfo & {
310
323
  messages: MastraMessageV1[] | MastraMessageV2[];
311
324
  }>;
325
+ updateMessages(_args: {
326
+ messages: Partial<Omit<MastraMessageV2, 'createdAt'>> & {
327
+ id: string;
328
+ content?: {
329
+ metadata?: MastraMessageContentV2['metadata'];
330
+ content?: MastraMessageContentV2['content'];
331
+ };
332
+ }[];
333
+ }): Promise<MastraMessageV2[]>;
312
334
  }
313
335
  export { LanceStorage }
314
336
  export { LanceStorage as LanceStorage_alias_1 }
@@ -317,7 +339,9 @@ declare interface LanceUpsertVectorParams extends UpsertVectorParams {
317
339
  tableName: string;
318
340
  }
319
341
 
320
- declare class LanceVectorStore extends MastraVector {
342
+ export declare type LanceVectorFilter = VectorFilter<keyof LanceOperatorValueMap, LanceOperatorValueMap, LogicalOperatorValueMap, LanceBlacklisted>;
343
+
344
+ declare class LanceVectorStore extends MastraVector<LanceVectorFilter> {
321
345
  private lanceClient;
322
346
  /**
323
347
  * Creates a new instance of LanceVectorStore
@@ -1,6 +1,7 @@
1
1
  import { ArrayOperator } from '@mastra/core/vector/filter';
2
2
  import { BaseFilterTranslator } from '@mastra/core/vector/filter';
3
3
  import { BasicOperator } from '@mastra/core/vector/filter';
4
+ import type { BlacklistedRootOperators } from '@mastra/core/vector/filter';
4
5
  import type { ConnectionOptions } from '@lancedb/lancedb';
5
6
  import type { CreateIndexParams } from '@mastra/core';
6
7
  import type { CreateTableOptions } from '@lancedb/lancedb';
@@ -10,11 +11,14 @@ import type { DescribeIndexParams } from '@mastra/core';
10
11
  import type { EvalRow } from '@mastra/core/storage';
11
12
  import type { IndexStats } from '@mastra/core';
12
13
  import { LogicalOperator } from '@mastra/core/vector/filter';
14
+ import type { LogicalOperatorValueMap } from '@mastra/core/vector/filter';
15
+ import type { MastraMessageContentV2 } from '@mastra/core/agent';
13
16
  import type { MastraMessageV1 } from '@mastra/core/memory';
14
17
  import type { MastraMessageV2 } from '@mastra/core/memory';
15
18
  import { MastraStorage } from '@mastra/core/storage';
16
19
  import { MastraVector } from '@mastra/core/vector';
17
20
  import { NumericOperator } from '@mastra/core/vector/filter';
21
+ import type { OperatorValueMap } from '@mastra/core/vector/filter';
18
22
  import type { PaginationInfo } from '@mastra/core/storage';
19
23
  import type { QueryResult } from '@mastra/core';
20
24
  import type { QueryVectorParams } from '@mastra/core';
@@ -52,13 +56,15 @@ declare interface IVFConfig {
52
56
  lists?: number;
53
57
  }
54
58
 
59
+ declare type LanceBlacklisted = BlacklistedRootOperators | '$like' | '$notLike' | '$contains';
60
+
55
61
  declare interface LanceCreateIndexParams extends CreateIndexParams {
56
62
  indexConfig?: LanceIndexConfig;
57
63
  tableName?: string;
58
64
  }
59
65
 
60
- export declare class LanceFilterTranslator extends BaseFilterTranslator {
61
- translate(filter: VectorFilter): string;
66
+ export declare class LanceFilterTranslator extends BaseFilterTranslator<LanceVectorFilter, string> {
67
+ translate(filter: LanceVectorFilter): string;
62
68
  private processFilter;
63
69
  private processLogicalOperator;
64
70
  private processNestedObject;
@@ -93,7 +99,13 @@ declare interface LanceIndexConfig extends IndexConfig {
93
99
  numSubVectors?: number;
94
100
  }
95
101
 
96
- declare interface LanceQueryVectorParams extends QueryVectorParams {
102
+ declare type LanceOperatorValueMap = OperatorValueMap & {
103
+ $like: string;
104
+ $notLike: string;
105
+ $contains: string;
106
+ };
107
+
108
+ declare interface LanceQueryVectorParams extends QueryVectorParams<LanceVectorFilter> {
97
109
  tableName: string;
98
110
  columns?: string[];
99
111
  includeAllColumns?: boolean;
@@ -124,6 +136,7 @@ declare class LanceStorage extends MastraStorage {
124
136
  * ```
125
137
  */
126
138
  static create(name: string, uri: string, options?: ConnectionOptions): Promise<LanceStorage>;
139
+ private getPrimaryKeys;
127
140
  /**
128
141
  * @internal
129
142
  * Private constructor to enforce using the create factory method
@@ -309,6 +322,15 @@ declare class LanceStorage extends MastraStorage {
309
322
  getMessagesPaginated(_args: StorageGetMessagesArg): Promise<PaginationInfo & {
310
323
  messages: MastraMessageV1[] | MastraMessageV2[];
311
324
  }>;
325
+ updateMessages(_args: {
326
+ messages: Partial<Omit<MastraMessageV2, 'createdAt'>> & {
327
+ id: string;
328
+ content?: {
329
+ metadata?: MastraMessageContentV2['metadata'];
330
+ content?: MastraMessageContentV2['content'];
331
+ };
332
+ }[];
333
+ }): Promise<MastraMessageV2[]>;
312
334
  }
313
335
  export { LanceStorage }
314
336
  export { LanceStorage as LanceStorage_alias_1 }
@@ -317,7 +339,9 @@ declare interface LanceUpsertVectorParams extends UpsertVectorParams {
317
339
  tableName: string;
318
340
  }
319
341
 
320
- declare class LanceVectorStore extends MastraVector {
342
+ export declare type LanceVectorFilter = VectorFilter<keyof LanceOperatorValueMap, LanceOperatorValueMap, LogicalOperatorValueMap, LanceBlacklisted>;
343
+
344
+ declare class LanceVectorStore extends MastraVector<LanceVectorFilter> {
321
345
  private lanceClient;
322
346
  /**
323
347
  * Creates a new instance of LanceVectorStore