@voltagent/core 1.1.24 → 1.1.25
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/index.d.mts +4 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +7 -1
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -1
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -3500,6 +3500,10 @@ type OperationContext = {
|
|
|
3500
3500
|
startTime: Date;
|
|
3501
3501
|
/** Cancellation error to be thrown when operation is aborted */
|
|
3502
3502
|
cancellationError?: CancellationError;
|
|
3503
|
+
/** Input provided to the agent operation (string, UIMessages, or BaseMessages) */
|
|
3504
|
+
input?: string | UIMessage[] | BaseMessage[];
|
|
3505
|
+
/** Output generated by the agent operation (text or object) */
|
|
3506
|
+
output?: string | object;
|
|
3503
3507
|
};
|
|
3504
3508
|
/**
|
|
3505
3509
|
* Specific information related to a tool execution error.
|
package/dist/index.d.ts
CHANGED
|
@@ -3500,6 +3500,10 @@ type OperationContext = {
|
|
|
3500
3500
|
startTime: Date;
|
|
3501
3501
|
/** Cancellation error to be thrown when operation is aborted */
|
|
3502
3502
|
cancellationError?: CancellationError;
|
|
3503
|
+
/** Input provided to the agent operation (string, UIMessages, or BaseMessages) */
|
|
3504
|
+
input?: string | UIMessage[] | BaseMessage[];
|
|
3505
|
+
/** Output generated by the agent operation (text or object) */
|
|
3506
|
+
output?: string | object;
|
|
3503
3507
|
};
|
|
3504
3508
|
/**
|
|
3505
3509
|
* Specific information related to a tool execution error.
|
package/dist/index.js
CHANGED
|
@@ -11414,6 +11414,7 @@ var Agent = class {
|
|
|
11414
11414
|
this.setTraceContextUsage(oc.traceContext, result.usage);
|
|
11415
11415
|
oc.traceContext.setOutput(result.text);
|
|
11416
11416
|
oc.traceContext.end("completed");
|
|
11417
|
+
oc.output = result.text;
|
|
11417
11418
|
const returnValue = Object.assign(
|
|
11418
11419
|
Object.create(Object.getPrototypeOf(result)),
|
|
11419
11420
|
// Preserve prototype chain
|
|
@@ -11536,6 +11537,7 @@ var Agent = class {
|
|
|
11536
11537
|
this.setTraceContextUsage(oc.traceContext, finalResult.totalUsage);
|
|
11537
11538
|
oc.traceContext.setOutput(finalResult.text);
|
|
11538
11539
|
oc.traceContext.end("completed");
|
|
11540
|
+
oc.output = finalResult.text;
|
|
11539
11541
|
const usage = convertUsage(finalResult.totalUsage);
|
|
11540
11542
|
await this.getMergedHooks(options).onEnd?.({
|
|
11541
11543
|
conversationId: oc.conversationId || "",
|
|
@@ -11748,6 +11750,7 @@ var Agent = class {
|
|
|
11748
11750
|
this.setTraceContextUsage(oc.traceContext, result.usage);
|
|
11749
11751
|
oc.traceContext.setOutput(result.object);
|
|
11750
11752
|
oc.traceContext.end("completed");
|
|
11753
|
+
oc.output = result.object;
|
|
11751
11754
|
await this.getMergedHooks(options).onEnd?.({
|
|
11752
11755
|
conversationId: oc.conversationId || "",
|
|
11753
11756
|
agent: this,
|
|
@@ -11901,6 +11904,7 @@ var Agent = class {
|
|
|
11901
11904
|
this.setTraceContextUsage(oc.traceContext, finalResult.usage);
|
|
11902
11905
|
oc.traceContext.setOutput(finalResult.object);
|
|
11903
11906
|
oc.traceContext.end("completed");
|
|
11907
|
+
oc.output = finalResult.object;
|
|
11904
11908
|
await this.getMergedHooks(options).onEnd?.({
|
|
11905
11909
|
conversationId: oc.conversationId || "",
|
|
11906
11910
|
agent: this,
|
|
@@ -12084,7 +12088,9 @@ var Agent = class {
|
|
|
12084
12088
|
parentAgentId: options?.parentAgentId,
|
|
12085
12089
|
traceContext,
|
|
12086
12090
|
startTime: startTimeDate,
|
|
12087
|
-
elicitation: elicitationHandler
|
|
12091
|
+
elicitation: elicitationHandler,
|
|
12092
|
+
input,
|
|
12093
|
+
output: void 0
|
|
12088
12094
|
};
|
|
12089
12095
|
}
|
|
12090
12096
|
getConversationBuffer(oc) {
|