@mastra/libsql 1.22.1-alpha.0 → 1.22.2-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/CHANGELOG.md +18 -0
- package/dist/docs/SKILL.md +1 -1
- package/dist/docs/assets/SOURCE_MAP.json +1 -1
- package/dist/index.cjs +14 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +15 -3
- package/dist/index.js.map +1 -1
- package/dist/storage/domains/knowledge/index.d.ts.map +1 -1
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# @mastra/libsql
|
|
2
2
|
|
|
3
|
+
## 1.22.2-alpha.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Fixed the store package failing to load when installed with `@mastra/core` older than 1.63.1, and corrected the minimum supported core version. ([#22548](https://github.com/mastra-ai/mastra/pull/22548))
|
|
8
|
+
|
|
9
|
+
- Updated dependencies [[`0a9d29c`](https://github.com/mastra-ai/mastra/commit/0a9d29c0c4dbbaa6afc1c8146cdd41759cbd4002)]:
|
|
10
|
+
- @mastra/core@1.63.2-alpha.0
|
|
11
|
+
|
|
12
|
+
## 1.22.1
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- Add an optional bounded description field to knowledge nodes across storage adapters, written through a dedicated curator tool. Part of an unreleased experimental memory feature. ([#21830](https://github.com/mastra-ai/mastra/pull/21830))
|
|
17
|
+
|
|
18
|
+
- Updated dependencies [[`bae1502`](https://github.com/mastra-ai/mastra/commit/bae150254b06a4da6964d7c137af97f336362359), [`0885364`](https://github.com/mastra-ai/mastra/commit/0885364c2fc7fa31febcfc444fc1ba5231ac1257), [`b8cb683`](https://github.com/mastra-ai/mastra/commit/b8cb683ba66499df254ddd1f7edd8cae3f89d2e7), [`078affd`](https://github.com/mastra-ai/mastra/commit/078affdaea57ac5e95a77e9e7b197d1878190684), [`9e3403e`](https://github.com/mastra-ai/mastra/commit/9e3403e9868240cb18841898e84cf008ebd7a87e), [`791bf5e`](https://github.com/mastra-ai/mastra/commit/791bf5e81cd27e2e1cff66122f1380ab8a3dda41)]:
|
|
19
|
+
- @mastra/core@1.63.1
|
|
20
|
+
|
|
3
21
|
## 1.22.1-alpha.0
|
|
4
22
|
|
|
5
23
|
### Patch Changes
|
package/dist/docs/SKILL.md
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -5786,6 +5786,18 @@ var HarnessLibSQL = class HarnessLibSQL extends _mastra_core_storage.HarnessStor
|
|
|
5786
5786
|
};
|
|
5787
5787
|
//#endregion
|
|
5788
5788
|
//#region src/storage/domains/knowledge/index.ts
|
|
5789
|
+
let assertDescriptionWithinBound;
|
|
5790
|
+
async function assertKnowledgeDescriptionWithinBoundCompat(description) {
|
|
5791
|
+
let assertWithinBound = assertDescriptionWithinBound;
|
|
5792
|
+
if (!assertWithinBound) {
|
|
5793
|
+
const resolvedAssert = (await import("@mastra/core/storage")).assertKnowledgeDescriptionWithinBound ?? ((value) => {
|
|
5794
|
+
if (value !== void 0 && value.length > 400) throw new Error("Knowledge node description exceeds the 400 UTF-16 code unit limit");
|
|
5795
|
+
});
|
|
5796
|
+
assertDescriptionWithinBound = resolvedAssert;
|
|
5797
|
+
assertWithinBound = resolvedAssert;
|
|
5798
|
+
}
|
|
5799
|
+
assertWithinBound(description);
|
|
5800
|
+
}
|
|
5789
5801
|
const visibleSql = `(scopeKey = ? OR substr(?, 1, length(scopeKey) + 1) = scopeKey || char(31))`;
|
|
5790
5802
|
function parseJson$3(value) {
|
|
5791
5803
|
if (typeof value === "string") return JSON.parse(value);
|
|
@@ -5951,7 +5963,7 @@ var KnowledgeLibSQL = class extends _mastra_core_storage.KnowledgeStorage {
|
|
|
5951
5963
|
});
|
|
5952
5964
|
}
|
|
5953
5965
|
async createNode(input) {
|
|
5954
|
-
|
|
5966
|
+
await assertKnowledgeDescriptionWithinBoundCompat(input.description);
|
|
5955
5967
|
const scope = (0, _mastra_core_storage.canonicalizeKnowledgeScope)(input.scope);
|
|
5956
5968
|
return this.#transaction(async (tx) => {
|
|
5957
5969
|
const existing = await this.#getNodeByName(tx, input.name, scope);
|
|
@@ -6039,7 +6051,7 @@ var KnowledgeLibSQL = class extends _mastra_core_storage.KnowledgeStorage {
|
|
|
6039
6051
|
})).rows.map(parseNode);
|
|
6040
6052
|
}
|
|
6041
6053
|
async updateNode(input) {
|
|
6042
|
-
|
|
6054
|
+
await assertKnowledgeDescriptionWithinBoundCompat(input.description);
|
|
6043
6055
|
return this.#transaction(async (tx) => {
|
|
6044
6056
|
const existing = await this.#getNode(tx, input.id);
|
|
6045
6057
|
if (!existing) throw new _mastra_core_storage.KnowledgeNotFoundError("node", input.id);
|