@mastra/convex 1.6.1 → 1.7.1-alpha.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/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/index.cjs +14 -6
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +14 -6
- package/dist/index.js.map +1 -1
- package/dist/server/index.cjs +1 -1
- package/dist/server/index.js +1 -1
- package/dist/server/observational-memory.d.ts.map +1 -1
- package/dist/server/storage.d.ts.map +1 -1
- package/dist/{server-D5fx5hYY.cjs → server-Beo8LSQH.cjs} +17 -3
- package/dist/server-Beo8LSQH.cjs.map +1 -0
- package/dist/{server-DEhttoZL.js → server-tA7rePdW.js} +17 -3
- package/dist/server-tA7rePdW.js.map +1 -0
- package/dist/storage/db/index.d.ts +7 -1
- package/dist/storage/db/index.d.ts.map +1 -1
- package/dist/storage/domains/memory/index.d.ts +1 -0
- package/dist/storage/domains/memory/index.d.ts.map +1 -1
- package/dist/storage/domains/schedules/index.d.ts +2 -2
- package/dist/storage/domains/schedules/index.d.ts.map +1 -1
- package/dist/storage/types.d.ts +6 -0
- package/dist/storage/types.d.ts.map +1 -1
- package/package.json +5 -5
- package/dist/server-D5fx5hYY.cjs.map +0 -1
- package/dist/server-DEhttoZL.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as mastraCache, i as mastraStorage, n as mastraNativeVectorMutation, r as mastraNativeVectorQuery, t as mastraNativeVectorAction } from "./server-
|
|
1
|
+
import { a as mastraCache, i as mastraStorage, n as mastraNativeVectorMutation, r as mastraNativeVectorQuery, t as mastraNativeVectorAction } from "./server-tA7rePdW.js";
|
|
2
2
|
import { TABLE_BACKGROUND_TASKS, TABLE_CHANNEL_CONFIG, TABLE_CHANNEL_INSTALLATIONS, TABLE_MESSAGES, TABLE_OBSERVATIONAL_MEMORY, TABLE_RESOURCES, TABLE_SCHEDULES, TABLE_SCHEDULE_TRIGGERS, TABLE_SCORERS, TABLE_THREADS, TABLE_WORKFLOW_SNAPSHOT, defineMastraNativeVectorTable, mastraBackgroundTasksTable, mastraCacheListItemsTable, mastraCacheTable, mastraChannelConfigTable, mastraChannelInstallationsTable, mastraDocumentsTable, mastraMessagesTable, mastraObservationalMemoryTable, mastraResourcesTable, mastraScheduleTriggersTable, mastraSchedulesTable, mastraScoresTable, mastraThreadsTable, mastraVectorIndexesTable, mastraVectorsTable, mastraWorkflowSnapshotsTable } from "./schema.js";
|
|
3
3
|
import { MastraServerCache } from "@mastra/core/cache";
|
|
4
4
|
import { BackgroundTasksStorage, ChannelsStorage, MastraCompositeStore, MemoryStorage, SchedulesStorage, ScoresStorage, TABLE_BACKGROUND_TASKS as TABLE_BACKGROUND_TASKS$1, TABLE_CHANNEL_CONFIG as TABLE_CHANNEL_CONFIG$1, TABLE_CHANNEL_INSTALLATIONS as TABLE_CHANNEL_INSTALLATIONS$1, TABLE_MESSAGES as TABLE_MESSAGES$1, TABLE_RESOURCES as TABLE_RESOURCES$1, TABLE_SCHEDULES as TABLE_SCHEDULES$1, TABLE_SCHEDULE_TRIGGERS as TABLE_SCHEDULE_TRIGGERS$1, TABLE_SCORERS as TABLE_SCORERS$1, TABLE_THREADS as TABLE_THREADS$1, TABLE_WORKFLOW_SNAPSHOT as TABLE_WORKFLOW_SNAPSHOT$1, WorkflowsStorage, calculatePagination, createStorageErrorId, createVectorErrorId, filterByDateRange, normalizePerPage, normalizeScheduleTarget, safelyParseJSON, storageMessageMatchesMetadataFilter, validateStorageMetadataFilter } from "@mastra/core/storage";
|
|
@@ -434,7 +434,7 @@ var ConvexDB = class extends MastraBase {
|
|
|
434
434
|
limit
|
|
435
435
|
});
|
|
436
436
|
}
|
|
437
|
-
async updateScheduleNextFire({ id, expectedNextFireAt, newNextFireAt, lastFireAt, lastRunId }) {
|
|
437
|
+
async updateScheduleNextFire({ id, expectedNextFireAt, newNextFireAt, lastFireAt, lastRunId, newStatus }) {
|
|
438
438
|
return this.client.callStorage({
|
|
439
439
|
op: "updateScheduleNextFire",
|
|
440
440
|
tableName: TABLE_SCHEDULES$1,
|
|
@@ -442,7 +442,8 @@ var ConvexDB = class extends MastraBase {
|
|
|
442
442
|
expectedNextFireAt,
|
|
443
443
|
newNextFireAt,
|
|
444
444
|
lastFireAt,
|
|
445
|
-
lastRunId
|
|
445
|
+
lastRunId,
|
|
446
|
+
newStatus
|
|
446
447
|
});
|
|
447
448
|
}
|
|
448
449
|
async updateSchedule({ id, patch }) {
|
|
@@ -979,6 +980,7 @@ function parseStoredOMRecord(doc) {
|
|
|
979
980
|
var MemoryConvex = class extends MemoryStorage {
|
|
980
981
|
supportsPartialThreadUpdate = true;
|
|
981
982
|
supportsObservationalMemory = true;
|
|
983
|
+
supportsObservationalMemoryHistorySearch = true;
|
|
982
984
|
#db;
|
|
983
985
|
constructor(config) {
|
|
984
986
|
super();
|
|
@@ -1451,7 +1453,12 @@ var MemoryConvex = class extends MemoryStorage {
|
|
|
1451
1453
|
limit,
|
|
1452
1454
|
from: options?.from ? options.from.toISOString() : void 0,
|
|
1453
1455
|
to: options?.to ? options.to.toISOString() : void 0,
|
|
1454
|
-
offset: options?.offset ?? void 0
|
|
1456
|
+
offset: options?.offset ?? void 0,
|
|
1457
|
+
groupId: options?.groupId,
|
|
1458
|
+
recordId: options?.recordId,
|
|
1459
|
+
beforeGeneration: options?.beforeGeneration,
|
|
1460
|
+
afterGeneration: options?.afterGeneration,
|
|
1461
|
+
sortDirection: options?.sortDirection
|
|
1455
1462
|
})).map((doc) => parseStoredOMRecord(doc));
|
|
1456
1463
|
}
|
|
1457
1464
|
async initializeObservationalMemory(input) {
|
|
@@ -1957,13 +1964,14 @@ var SchedulesConvex = class extends SchedulesStorage {
|
|
|
1957
1964
|
patch: updates
|
|
1958
1965
|
}));
|
|
1959
1966
|
}
|
|
1960
|
-
async updateScheduleNextFire(id, expectedNextFireAt, newNextFireAt, lastFireAt, lastRunId) {
|
|
1967
|
+
async updateScheduleNextFire(id, expectedNextFireAt, newNextFireAt, lastFireAt, lastRunId, newStatus) {
|
|
1961
1968
|
return this.#db.updateScheduleNextFire({
|
|
1962
1969
|
id,
|
|
1963
1970
|
expectedNextFireAt,
|
|
1964
1971
|
newNextFireAt,
|
|
1965
1972
|
lastFireAt,
|
|
1966
|
-
lastRunId
|
|
1973
|
+
lastRunId,
|
|
1974
|
+
newStatus
|
|
1967
1975
|
});
|
|
1968
1976
|
}
|
|
1969
1977
|
async deleteSchedule(id) {
|