@kernl-sdk/ai 0.3.3 → 0.3.5
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 +23 -0
- package/dist/convert/__tests__/stream.test.js +1 -1
- package/dist/convert/__tests__/ui-stream.test.js +1 -1
- package/dist/convert/stream.d.ts.map +1 -1
- package/dist/convert/stream.js +3 -1
- package/package.json +4 -4
- package/src/convert/__tests__/stream.test.ts +1 -1
- package/src/convert/__tests__/ui-stream.test.ts +1 -1
- package/src/convert/stream.ts +4 -1
package/.turbo/turbo-build.log
CHANGED
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,28 @@
|
|
|
1
1
|
# @kernl/ai
|
|
2
2
|
|
|
3
|
+
## 0.3.5
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [830b52a]
|
|
8
|
+
- @kernl-sdk/shared@0.4.0
|
|
9
|
+
- @kernl-sdk/protocol@0.4.2
|
|
10
|
+
- @kernl-sdk/retrieval@0.1.8
|
|
11
|
+
|
|
12
|
+
## 0.3.4
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- bb6ac60: Add lifecycle hooks for observing agent execution
|
|
17
|
+
- New events: `thread.start`, `thread.stop`, `model.call.start`, `model.call.end`, `tool.call.start`, `tool.call.end`
|
|
18
|
+
- Subscribe via `agent.on()` or `kernl.on()` for global hooks
|
|
19
|
+
- Fixed error propagation in thread execution
|
|
20
|
+
- Normalized `ErrorEvent.error` to always be an `Error` instance
|
|
21
|
+
|
|
22
|
+
- Updated dependencies [bb6ac60]
|
|
23
|
+
- @kernl-sdk/protocol@0.4.1
|
|
24
|
+
- @kernl-sdk/retrieval@0.1.7
|
|
25
|
+
|
|
3
26
|
## 0.3.3
|
|
4
27
|
|
|
5
28
|
### Patch Changes
|
|
@@ -267,7 +267,7 @@ describe("STREAM_PART codec", () => {
|
|
|
267
267
|
const result = STREAM_PART.decode(part);
|
|
268
268
|
expect(result).toEqual({
|
|
269
269
|
kind: "error",
|
|
270
|
-
error: "Connection failed",
|
|
270
|
+
error: new Error("Connection failed"),
|
|
271
271
|
});
|
|
272
272
|
});
|
|
273
273
|
it("should decode raw event", () => {
|
|
@@ -428,7 +428,7 @@ describe("toUIMessageStream", () => {
|
|
|
428
428
|
it("should handle errors in stream", async () => {
|
|
429
429
|
const events = [
|
|
430
430
|
{ kind: "text-start", id: "text-1" },
|
|
431
|
-
{ kind: "error", error: "Network timeout" },
|
|
431
|
+
{ kind: "error", error: new Error("Network timeout") },
|
|
432
432
|
];
|
|
433
433
|
async function* generateEvents() {
|
|
434
434
|
for (const event of events) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"stream.d.ts","sourceRoot":"","sources":["../../src/convert/stream.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EACL,KAAK,wBAAwB,EAI9B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kBAAkB,CAAC;AAIlE;;GAEG;AACH,wBAAuB,aAAa,CAClC,MAAM,EAAE,cAAc,CAAC,yBAAyB,CAAC,GAChD,aAAa,CAAC,wBAAwB,CAAC,CAgBzC;AAED;;GAEG;AACH,eAAO,MAAM,WAAW,EAAE,KAAK,CAC7B,wBAAwB,GAAG,IAAI,EAC/B,yBAAyB,
|
|
1
|
+
{"version":3,"file":"stream.d.ts","sourceRoot":"","sources":["../../src/convert/stream.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,uBAAuB,CAAC;AACnD,OAAO,EACL,KAAK,wBAAwB,EAI9B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,kBAAkB,CAAC;AAIlE;;GAEG;AACH,wBAAuB,aAAa,CAClC,MAAM,EAAE,cAAc,CAAC,yBAAyB,CAAC,GAChD,aAAa,CAAC,wBAAwB,CAAC,CAgBzC;AAED;;GAEG;AACH,eAAO,MAAM,WAAW,EAAE,KAAK,CAC7B,wBAAwB,GAAG,IAAI,EAC/B,yBAAyB,CAoJ1B,CAAC"}
|
package/dist/convert/stream.js
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kernl-sdk/ai",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.5",
|
|
4
4
|
"description": "Vercel AI SDK adapter for kernl",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"kernl",
|
|
@@ -68,9 +68,9 @@
|
|
|
68
68
|
"vitest": "^4.0.8"
|
|
69
69
|
},
|
|
70
70
|
"dependencies": {
|
|
71
|
-
"@kernl-sdk/protocol": "0.4.
|
|
72
|
-
"@kernl-sdk/
|
|
73
|
-
"@kernl-sdk/
|
|
71
|
+
"@kernl-sdk/protocol": "0.4.2",
|
|
72
|
+
"@kernl-sdk/retrieval": "0.1.8",
|
|
73
|
+
"@kernl-sdk/shared": "^0.4.0"
|
|
74
74
|
},
|
|
75
75
|
"scripts": {
|
|
76
76
|
"build": "tsc && tsc-alias --resolve-full-paths",
|
|
@@ -520,7 +520,7 @@ describe("toUIMessageStream", () => {
|
|
|
520
520
|
it("should handle errors in stream", async () => {
|
|
521
521
|
const events: LanguageModelStreamEvent[] = [
|
|
522
522
|
{ kind: "text-start", id: "text-1" },
|
|
523
|
-
{ kind: "error", error: "Network timeout" },
|
|
523
|
+
{ kind: "error", error: new Error("Network timeout") },
|
|
524
524
|
];
|
|
525
525
|
|
|
526
526
|
async function* generateEvents() {
|
package/src/convert/stream.ts
CHANGED