@dudousxd/nestjs-agent-core 0.28.0 → 0.29.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/genui/index.d.cts +1 -1
- package/dist/genui/index.d.ts +1 -1
- package/dist/guardrails/index.d.cts +2 -2
- package/dist/guardrails/index.d.ts +2 -2
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +4 -4
- package/dist/index.d.ts +4 -4
- package/dist/index.js.map +1 -1
- package/dist/{processors-nr6jwLAh.d.cts → processors-3FixaBnr.d.cts} +1 -1
- package/dist/{processors-Bhn6ehMM.d.ts → processors-BrGKQgLf.d.ts} +1 -1
- package/dist/{tool-BJ5jVoH2.d.cts → tool-CON4ZOrD.d.cts} +23 -0
- package/dist/{tool-BJ5jVoH2.d.ts → tool-CON4ZOrD.d.ts} +23 -0
- package/package.json +1 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-
|
|
1
|
+
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-CON4ZOrD.cjs';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* The two seams that see a turn's traffic to and from the model: an {@link InputProcessor} rewrites
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-
|
|
1
|
+
import { M as ModelMessage, A as Actor, d as ToolCallRequest } from './tool-CON4ZOrD.js';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* The two seams that see a turn's traffic to and from the model: an {@link InputProcessor} rewrites
|
|
@@ -544,6 +544,17 @@ type AgentStreamEvent = {
|
|
|
544
544
|
kind: 'title';
|
|
545
545
|
title: string;
|
|
546
546
|
}
|
|
547
|
+
/**
|
|
548
|
+
* Host-defined facts about the message being streamed (the model that answered, how long it took,
|
|
549
|
+
* the error it ended with), merged into the client message's `metadata`. The persisted
|
|
550
|
+
* counterpart is `StoredMessage.metadata`, so a reload reads the same values. The library's own
|
|
551
|
+
* loop never writes it; a runner that is not this library's loop uses it for what its store keeps
|
|
552
|
+
* per message.
|
|
553
|
+
*/
|
|
554
|
+
| {
|
|
555
|
+
kind: 'message-metadata';
|
|
556
|
+
metadata: Record<string, unknown>;
|
|
557
|
+
}
|
|
547
558
|
/**
|
|
548
559
|
* Someone stopped this run. The stream's LAST frame, written by the runner that settled the
|
|
549
560
|
* cancel, immediately before a normal `end()` — never a `fail()`, because a cancel is not an
|
|
@@ -853,6 +864,11 @@ interface ToolCallRequest {
|
|
|
853
864
|
* (defensively treated as `read` wherever a definite value is required).
|
|
854
865
|
*/
|
|
855
866
|
kind?: ToolKind;
|
|
867
|
+
/**
|
|
868
|
+
* The call this one ran inside (a code-mode `execute`, a delegated agent) — the same `parentId`
|
|
869
|
+
* the live `tool-input-*` frames carried, so a reloaded thread nests the call where the stream did.
|
|
870
|
+
*/
|
|
871
|
+
parentId?: string;
|
|
856
872
|
}
|
|
857
873
|
/** Result of running a tool. */
|
|
858
874
|
interface ToolResult {
|
|
@@ -1215,6 +1231,13 @@ interface StoredMessage {
|
|
|
1215
1231
|
* nobody rated it, or on a store that does not record feedback.
|
|
1216
1232
|
*/
|
|
1217
1233
|
feedback?: MessageFeedback;
|
|
1234
|
+
/**
|
|
1235
|
+
* Host-defined facts about the message (which model answered, how long it took, the error a turn
|
|
1236
|
+
* ended with, …) — what a runner that is not this library's loop streamed as a
|
|
1237
|
+
* `message-metadata` frame. Replayed into the client message's `metadata`, under the library's
|
|
1238
|
+
* own keys (`usage`, `feedback`, `createdAt` win on a clash). Never read by the library itself.
|
|
1239
|
+
*/
|
|
1240
|
+
metadata?: Record<string, unknown>;
|
|
1218
1241
|
createdAt: string;
|
|
1219
1242
|
}
|
|
1220
1243
|
/** A thumbs-up/down on one message, with an optional free-text comment. */
|
|
@@ -544,6 +544,17 @@ type AgentStreamEvent = {
|
|
|
544
544
|
kind: 'title';
|
|
545
545
|
title: string;
|
|
546
546
|
}
|
|
547
|
+
/**
|
|
548
|
+
* Host-defined facts about the message being streamed (the model that answered, how long it took,
|
|
549
|
+
* the error it ended with), merged into the client message's `metadata`. The persisted
|
|
550
|
+
* counterpart is `StoredMessage.metadata`, so a reload reads the same values. The library's own
|
|
551
|
+
* loop never writes it; a runner that is not this library's loop uses it for what its store keeps
|
|
552
|
+
* per message.
|
|
553
|
+
*/
|
|
554
|
+
| {
|
|
555
|
+
kind: 'message-metadata';
|
|
556
|
+
metadata: Record<string, unknown>;
|
|
557
|
+
}
|
|
547
558
|
/**
|
|
548
559
|
* Someone stopped this run. The stream's LAST frame, written by the runner that settled the
|
|
549
560
|
* cancel, immediately before a normal `end()` — never a `fail()`, because a cancel is not an
|
|
@@ -853,6 +864,11 @@ interface ToolCallRequest {
|
|
|
853
864
|
* (defensively treated as `read` wherever a definite value is required).
|
|
854
865
|
*/
|
|
855
866
|
kind?: ToolKind;
|
|
867
|
+
/**
|
|
868
|
+
* The call this one ran inside (a code-mode `execute`, a delegated agent) — the same `parentId`
|
|
869
|
+
* the live `tool-input-*` frames carried, so a reloaded thread nests the call where the stream did.
|
|
870
|
+
*/
|
|
871
|
+
parentId?: string;
|
|
856
872
|
}
|
|
857
873
|
/** Result of running a tool. */
|
|
858
874
|
interface ToolResult {
|
|
@@ -1215,6 +1231,13 @@ interface StoredMessage {
|
|
|
1215
1231
|
* nobody rated it, or on a store that does not record feedback.
|
|
1216
1232
|
*/
|
|
1217
1233
|
feedback?: MessageFeedback;
|
|
1234
|
+
/**
|
|
1235
|
+
* Host-defined facts about the message (which model answered, how long it took, the error a turn
|
|
1236
|
+
* ended with, …) — what a runner that is not this library's loop streamed as a
|
|
1237
|
+
* `message-metadata` frame. Replayed into the client message's `metadata`, under the library's
|
|
1238
|
+
* own keys (`usage`, `feedback`, `createdAt` win on a clash). Never read by the library itself.
|
|
1239
|
+
*/
|
|
1240
|
+
metadata?: Record<string, unknown>;
|
|
1218
1241
|
createdAt: string;
|
|
1219
1242
|
}
|
|
1220
1243
|
/** A thumbs-up/down on one message, with an optional free-text comment. */
|