@mastra/server 0.16.0-alpha.0 → 0.16.0-alpha.1
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 +11 -0
- package/dist/{chunk-SYTNLFZL.cjs → chunk-I77CGJTZ.cjs} +41 -19
- package/dist/chunk-I77CGJTZ.cjs.map +1 -0
- package/dist/{chunk-WOWRGMZ7.js → chunk-SADDGXIU.js} +41 -19
- package/dist/{chunk-SYTNLFZL.cjs.map → chunk-SADDGXIU.js.map} +1 -1
- package/dist/server/handlers/agent-builder.cjs +16 -16
- package/dist/server/handlers/agent-builder.js +1 -1
- package/dist/server/handlers.cjs +2 -2
- package/dist/server/handlers.js +1 -1
- package/package.json +5 -5
- package/dist/chunk-WOWRGMZ7.js.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
# @mastra/server
|
|
2
2
|
|
|
3
|
+
## 0.16.0-alpha.1
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- 376913a: Update peerdeps of @mastra/core
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [8fbf79e]
|
|
12
|
+
- @mastra/core@0.16.0-alpha.1
|
|
13
|
+
|
|
3
14
|
## 0.16.0-alpha.0
|
|
4
15
|
|
|
5
16
|
### Patch Changes
|
|
@@ -8599,23 +8599,45 @@ var Memory = class extends memory.MastraMemory {
|
|
|
8599
8599
|
})
|
|
8600
8600
|
);
|
|
8601
8601
|
}
|
|
8602
|
-
|
|
8603
|
-
|
|
8604
|
-
|
|
8605
|
-
|
|
8606
|
-
|
|
8607
|
-
|
|
8608
|
-
|
|
8609
|
-
|
|
8610
|
-
|
|
8611
|
-
|
|
8612
|
-
|
|
8613
|
-
|
|
8614
|
-
|
|
8615
|
-
|
|
8616
|
-
|
|
8617
|
-
|
|
8618
|
-
|
|
8602
|
+
let rawMessages;
|
|
8603
|
+
if (selectBy?.pagination) {
|
|
8604
|
+
const paginatedResult = await this.storage.getMessagesPaginated({
|
|
8605
|
+
threadId,
|
|
8606
|
+
resourceId,
|
|
8607
|
+
format: "v2",
|
|
8608
|
+
selectBy: {
|
|
8609
|
+
...selectBy,
|
|
8610
|
+
...vectorResults?.length ? {
|
|
8611
|
+
include: vectorResults.map((r) => ({
|
|
8612
|
+
id: r.metadata?.message_id,
|
|
8613
|
+
threadId: r.metadata?.thread_id,
|
|
8614
|
+
withNextMessages: typeof vectorConfig.messageRange === "number" ? vectorConfig.messageRange : vectorConfig.messageRange.after,
|
|
8615
|
+
withPreviousMessages: typeof vectorConfig.messageRange === "number" ? vectorConfig.messageRange : vectorConfig.messageRange.before
|
|
8616
|
+
}))
|
|
8617
|
+
} : {}
|
|
8618
|
+
},
|
|
8619
|
+
threadConfig: config
|
|
8620
|
+
});
|
|
8621
|
+
rawMessages = paginatedResult.messages;
|
|
8622
|
+
} else {
|
|
8623
|
+
rawMessages = await this.storage.getMessages({
|
|
8624
|
+
threadId,
|
|
8625
|
+
resourceId,
|
|
8626
|
+
format: "v2",
|
|
8627
|
+
selectBy: {
|
|
8628
|
+
...selectBy,
|
|
8629
|
+
...vectorResults?.length ? {
|
|
8630
|
+
include: vectorResults.map((r) => ({
|
|
8631
|
+
id: r.metadata?.message_id,
|
|
8632
|
+
threadId: r.metadata?.thread_id,
|
|
8633
|
+
withNextMessages: typeof vectorConfig.messageRange === "number" ? vectorConfig.messageRange : vectorConfig.messageRange.after,
|
|
8634
|
+
withPreviousMessages: typeof vectorConfig.messageRange === "number" ? vectorConfig.messageRange : vectorConfig.messageRange.before
|
|
8635
|
+
}))
|
|
8636
|
+
} : {}
|
|
8637
|
+
},
|
|
8638
|
+
threadConfig: config
|
|
8639
|
+
});
|
|
8640
|
+
}
|
|
8619
8641
|
const list = new agent.MessageList({ threadId, resourceId }).add(rawMessages, "memory");
|
|
8620
8642
|
return {
|
|
8621
8643
|
get messages() {
|
|
@@ -15680,5 +15702,5 @@ exports.startAsyncAgentBuilderActionHandler = startAsyncAgentBuilderActionHandle
|
|
|
15680
15702
|
exports.streamAgentBuilderActionHandler = streamAgentBuilderActionHandler;
|
|
15681
15703
|
exports.streamVNextAgentBuilderActionHandler = streamVNextAgentBuilderActionHandler;
|
|
15682
15704
|
exports.watchAgentBuilderActionHandler = watchAgentBuilderActionHandler;
|
|
15683
|
-
//# sourceMappingURL=chunk-
|
|
15684
|
-
//# sourceMappingURL=chunk-
|
|
15705
|
+
//# sourceMappingURL=chunk-I77CGJTZ.cjs.map
|
|
15706
|
+
//# sourceMappingURL=chunk-I77CGJTZ.cjs.map
|