@mastra/mssql 0.3.0-alpha.0 → 0.3.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/.turbo/turbo-build.log +1 -1
- package/CHANGELOG.md +14 -0
- package/dist/index.cjs +28 -23
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +28 -23
- package/dist/index.js.map +1 -1
- package/dist/storage/domains/memory/index.d.ts +1 -1
- package/dist/storage/domains/scores/index.d.ts +1 -1
- package/dist/storage/domains/scores/index.d.ts.map +1 -1
- package/dist/storage/domains/traces/index.d.ts +1 -1
- package/dist/storage/domains/workflows/index.d.ts +1 -1
- package/package.json +5 -4
- package/src/storage/domains/scores/index.ts +29 -28
- package/tsup.config.ts +2 -7
package/.turbo/turbo-build.log
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @mastra/mssql
|
|
2
2
|
|
|
3
|
+
## 0.3.0-alpha.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- 2871020: update safelyParseJSON to check for value of param when handling parse
|
|
8
|
+
- 4a406ec: fixes TypeScript declaration file imports to ensure proper ESM compatibility
|
|
9
|
+
- Updated dependencies [cb36de0]
|
|
10
|
+
- Updated dependencies [a82b851]
|
|
11
|
+
- Updated dependencies [41a0a0e]
|
|
12
|
+
- Updated dependencies [2871020]
|
|
13
|
+
- Updated dependencies [4a406ec]
|
|
14
|
+
- Updated dependencies [5d377e5]
|
|
15
|
+
- @mastra/core@0.13.0-alpha.2
|
|
16
|
+
|
|
3
17
|
## 0.3.0-alpha.0
|
|
4
18
|
|
|
5
19
|
### Minor Changes
|
package/dist/index.cjs
CHANGED
|
@@ -1387,28 +1387,17 @@ function parseJSON(jsonString) {
|
|
|
1387
1387
|
}
|
|
1388
1388
|
}
|
|
1389
1389
|
function transformScoreRow(row) {
|
|
1390
|
-
let input = void 0;
|
|
1391
|
-
let output = void 0;
|
|
1392
|
-
let preprocessStepResult = void 0;
|
|
1393
|
-
let analyzeStepResult = void 0;
|
|
1394
|
-
if (row.input) {
|
|
1395
|
-
input = parseJSON(row.input);
|
|
1396
|
-
}
|
|
1397
|
-
if (row.output) {
|
|
1398
|
-
output = parseJSON(row.output);
|
|
1399
|
-
}
|
|
1400
|
-
if (row.preprocessStepResult) {
|
|
1401
|
-
preprocessStepResult = parseJSON(row.preprocessStepResult);
|
|
1402
|
-
}
|
|
1403
|
-
if (row.analyzeStepResult) {
|
|
1404
|
-
analyzeStepResult = parseJSON(row.analyzeStepResult);
|
|
1405
|
-
}
|
|
1406
1390
|
return {
|
|
1407
1391
|
...row,
|
|
1408
|
-
input,
|
|
1409
|
-
|
|
1410
|
-
preprocessStepResult,
|
|
1411
|
-
analyzeStepResult,
|
|
1392
|
+
input: parseJSON(row.input),
|
|
1393
|
+
scorer: parseJSON(row.scorer),
|
|
1394
|
+
preprocessStepResult: parseJSON(row.preprocessStepResult),
|
|
1395
|
+
analyzeStepResult: parseJSON(row.analyzeStepResult),
|
|
1396
|
+
metadata: parseJSON(row.metadata),
|
|
1397
|
+
output: parseJSON(row.output),
|
|
1398
|
+
additionalContext: parseJSON(row.additionalContext),
|
|
1399
|
+
runtimeContext: parseJSON(row.runtimeContext),
|
|
1400
|
+
entity: parseJSON(row.entity),
|
|
1412
1401
|
createdAt: row.createdAt,
|
|
1413
1402
|
updatedAt: row.updatedAt
|
|
1414
1403
|
};
|
|
@@ -1453,16 +1442,32 @@ var ScoresMSSQL = class extends storage.ScoresStorage {
|
|
|
1453
1442
|
async saveScore(score) {
|
|
1454
1443
|
try {
|
|
1455
1444
|
const scoreId = crypto.randomUUID();
|
|
1456
|
-
const {
|
|
1445
|
+
const {
|
|
1446
|
+
scorer,
|
|
1447
|
+
preprocessStepResult,
|
|
1448
|
+
analyzeStepResult,
|
|
1449
|
+
metadata,
|
|
1450
|
+
input,
|
|
1451
|
+
output,
|
|
1452
|
+
additionalContext,
|
|
1453
|
+
runtimeContext,
|
|
1454
|
+
entity,
|
|
1455
|
+
...rest
|
|
1456
|
+
} = score;
|
|
1457
1457
|
await this.operations.insert({
|
|
1458
1458
|
tableName: storage.TABLE_SCORERS,
|
|
1459
1459
|
record: {
|
|
1460
1460
|
id: scoreId,
|
|
1461
1461
|
...rest,
|
|
1462
|
-
input: JSON.stringify(input),
|
|
1463
|
-
output: JSON.stringify(output),
|
|
1462
|
+
input: JSON.stringify(input) || "",
|
|
1463
|
+
output: JSON.stringify(output) || "",
|
|
1464
1464
|
preprocessStepResult: preprocessStepResult ? JSON.stringify(preprocessStepResult) : null,
|
|
1465
1465
|
analyzeStepResult: analyzeStepResult ? JSON.stringify(analyzeStepResult) : null,
|
|
1466
|
+
metadata: metadata ? JSON.stringify(metadata) : null,
|
|
1467
|
+
additionalContext: additionalContext ? JSON.stringify(additionalContext) : null,
|
|
1468
|
+
runtimeContext: runtimeContext ? JSON.stringify(runtimeContext) : null,
|
|
1469
|
+
entity: entity ? JSON.stringify(entity) : null,
|
|
1470
|
+
scorer: scorer ? JSON.stringify(scorer) : null,
|
|
1466
1471
|
createdAt: (/* @__PURE__ */ new Date()).toISOString(),
|
|
1467
1472
|
updatedAt: (/* @__PURE__ */ new Date()).toISOString()
|
|
1468
1473
|
}
|