@copilotkit/runtime 1.4.8-no-pino-redact.1 → 1.5.0-coagents-v0-3.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 +20 -5
- package/__snapshots__/schema/schema.graphql +7 -9
- package/dist/{chunk-OKQVDDJ2.mjs → chunk-4AYRDPWK.mjs} +285 -63
- package/dist/chunk-4AYRDPWK.mjs.map +1 -0
- package/dist/{chunk-APVJZO3R.mjs → chunk-7BOO3OFP.mjs} +2 -2
- package/dist/{chunk-OSWF5QDO.mjs → chunk-GSTWFOZF.mjs} +2 -2
- package/dist/{chunk-M74ZTUCC.mjs → chunk-OMAAKIJQ.mjs} +2 -2
- package/dist/{chunk-36AYTJIE.mjs → chunk-PXS4SBRF.mjs} +447 -321
- package/dist/chunk-PXS4SBRF.mjs.map +1 -0
- package/dist/{chunk-B74M7FXG.mjs → chunk-RFF5IIZJ.mjs} +3 -2
- package/dist/chunk-RFF5IIZJ.mjs.map +1 -0
- package/dist/{copilot-runtime-12e7ac40.d.ts → copilot-runtime-2e46a7b6.d.ts} +2 -2
- package/dist/graphql/types/converted/index.d.ts +1 -1
- package/dist/graphql/types/converted/index.js +2 -1
- package/dist/graphql/types/converted/index.js.map +1 -1
- package/dist/graphql/types/converted/index.mjs +1 -1
- package/dist/{groq-adapter-24abe931.d.ts → groq-adapter-7bf6824b.d.ts} +1 -1
- package/dist/{index-10b1c870.d.ts → index-ff3fbc33.d.ts} +7 -8
- package/dist/index.d.ts +5 -5
- package/dist/index.js +824 -473
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +10 -6
- package/dist/index.mjs.map +1 -1
- package/dist/{langserve-f021ab9c.d.ts → langserve-f318db89.d.ts} +53 -14
- package/dist/lib/index.d.ts +4 -4
- package/dist/lib/index.js +729 -452
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/index.mjs +6 -6
- package/dist/lib/integrations/index.d.ts +4 -4
- package/dist/lib/integrations/index.js +79 -31
- package/dist/lib/integrations/index.js.map +1 -1
- package/dist/lib/integrations/index.mjs +6 -6
- package/dist/lib/integrations/nest/index.d.ts +3 -3
- package/dist/lib/integrations/nest/index.js +79 -31
- package/dist/lib/integrations/nest/index.js.map +1 -1
- package/dist/lib/integrations/nest/index.mjs +4 -4
- package/dist/lib/integrations/node-express/index.d.ts +3 -3
- package/dist/lib/integrations/node-express/index.js +79 -31
- package/dist/lib/integrations/node-express/index.js.map +1 -1
- package/dist/lib/integrations/node-express/index.mjs +4 -4
- package/dist/lib/integrations/node-http/index.d.ts +3 -3
- package/dist/lib/integrations/node-http/index.js +79 -31
- package/dist/lib/integrations/node-http/index.js.map +1 -1
- package/dist/lib/integrations/node-http/index.mjs +3 -3
- package/dist/service-adapters/index.d.ts +36 -5
- package/dist/service-adapters/index.js +285 -61
- package/dist/service-adapters/index.js.map +1 -1
- package/dist/service-adapters/index.mjs +5 -1
- package/package.json +2 -2
- package/src/agents/langgraph/event-source.ts +140 -148
- package/src/agents/langgraph/events.ts +1 -1
- package/src/graphql/inputs/message.input.ts +15 -3
- package/src/graphql/resolvers/copilot.resolver.ts +32 -6
- package/src/graphql/types/converted/index.ts +4 -3
- package/src/graphql/types/copilot-response.type.ts +12 -3
- package/src/graphql/types/enums.ts +0 -11
- package/src/lib/logger.ts +4 -0
- package/src/lib/runtime/copilot-runtime.ts +1 -7
- package/src/lib/runtime/remote-action-constructors.ts +64 -58
- package/src/lib/runtime/remote-actions.ts +1 -0
- package/src/lib/runtime/remote-lg-action.ts +159 -140
- package/src/service-adapters/anthropic/anthropic-adapter.ts +16 -6
- package/src/service-adapters/conversion.ts +2 -1
- package/src/service-adapters/events.ts +118 -54
- package/src/service-adapters/experimental/empty/empty-adapter.ts +33 -0
- package/src/service-adapters/experimental/ollama/ollama-adapter.ts +7 -3
- package/src/service-adapters/groq/groq-adapter.ts +23 -8
- package/src/service-adapters/index.ts +7 -1
- package/src/service-adapters/langchain/utils.ts +55 -32
- package/src/service-adapters/openai/openai-adapter.ts +22 -9
- package/src/service-adapters/openai/openai-assistant-adapter.ts +22 -8
- package/src/service-adapters/unify/unify-adapter.ts +28 -11
- package/dist/chunk-36AYTJIE.mjs.map +0 -1
- package/dist/chunk-B74M7FXG.mjs.map +0 -1
- package/dist/chunk-OKQVDDJ2.mjs.map +0 -1
- /package/dist/{chunk-APVJZO3R.mjs.map → chunk-7BOO3OFP.mjs.map} +0 -0
- /package/dist/{chunk-OSWF5QDO.mjs.map → chunk-GSTWFOZF.mjs.map} +0 -0
- /package/dist/{chunk-M74ZTUCC.mjs.map → chunk-OMAAKIJQ.mjs.map} +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as graphql_yoga from 'graphql-yoga';
|
|
2
|
-
import { d as CreateCopilotRuntimeServerOptions, G as GraphQLContext } from '../../../copilot-runtime-
|
|
2
|
+
import { d as CreateCopilotRuntimeServerOptions, G as GraphQLContext } from '../../../copilot-runtime-2e46a7b6.js';
|
|
3
3
|
import '@copilotkit/shared';
|
|
4
|
-
import '../../../langserve-
|
|
5
|
-
import '../../../index-
|
|
4
|
+
import '../../../langserve-f318db89.js';
|
|
5
|
+
import '../../../index-ff3fbc33.js';
|
|
6
6
|
import '../../../graphql/types/base/index.js';
|
|
7
7
|
import 'rxjs';
|
|
8
8
|
import 'graphql';
|
|
@@ -44,7 +44,7 @@ var require_package = __commonJS({
|
|
|
44
44
|
publishConfig: {
|
|
45
45
|
access: "public"
|
|
46
46
|
},
|
|
47
|
-
version: "1.
|
|
47
|
+
version: "1.5.0-coagents-v0-3.0",
|
|
48
48
|
sideEffects: false,
|
|
49
49
|
main: "./dist/index.js",
|
|
50
50
|
module: "./dist/index.mjs",
|
|
@@ -151,12 +151,6 @@ var MessageRole;
|
|
|
151
151
|
MessageRole2["system"] = "system";
|
|
152
152
|
MessageRole2["tool"] = "tool";
|
|
153
153
|
})(MessageRole || (MessageRole = {}));
|
|
154
|
-
var ActionExecutionScope;
|
|
155
|
-
(function(ActionExecutionScope2) {
|
|
156
|
-
ActionExecutionScope2["server"] = "server";
|
|
157
|
-
ActionExecutionScope2["client"] = "client";
|
|
158
|
-
ActionExecutionScope2["passThrough"] = "passThrough";
|
|
159
|
-
})(ActionExecutionScope || (ActionExecutionScope = {}));
|
|
160
154
|
var CopilotRequestType;
|
|
161
155
|
(function(CopilotRequestType2) {
|
|
162
156
|
CopilotRequestType2["Chat"] = "Chat";
|
|
@@ -175,10 +169,6 @@ var ActionInputAvailability;
|
|
|
175
169
|
name: "MessageRole",
|
|
176
170
|
description: "The role of the message"
|
|
177
171
|
});
|
|
178
|
-
(0, import_type_graphql.registerEnumType)(ActionExecutionScope, {
|
|
179
|
-
name: "ActionExecutionScope",
|
|
180
|
-
description: "The scope of the action"
|
|
181
|
-
});
|
|
182
172
|
(0, import_type_graphql.registerEnumType)(CopilotRequestType, {
|
|
183
173
|
name: "CopilotRequestType",
|
|
184
174
|
description: "The type of Copilot request"
|
|
@@ -276,6 +266,7 @@ MessageInput = _ts_decorate2([
|
|
|
276
266
|
], MessageInput);
|
|
277
267
|
var TextMessageInput = class {
|
|
278
268
|
content;
|
|
269
|
+
parentMessageId;
|
|
279
270
|
role;
|
|
280
271
|
};
|
|
281
272
|
__name(TextMessageInput, "TextMessageInput");
|
|
@@ -283,6 +274,12 @@ _ts_decorate2([
|
|
|
283
274
|
(0, import_type_graphql3.Field)(() => String),
|
|
284
275
|
_ts_metadata2("design:type", String)
|
|
285
276
|
], TextMessageInput.prototype, "content", void 0);
|
|
277
|
+
_ts_decorate2([
|
|
278
|
+
(0, import_type_graphql3.Field)(() => String, {
|
|
279
|
+
nullable: true
|
|
280
|
+
}),
|
|
281
|
+
_ts_metadata2("design:type", String)
|
|
282
|
+
], TextMessageInput.prototype, "parentMessageId", void 0);
|
|
286
283
|
_ts_decorate2([
|
|
287
284
|
(0, import_type_graphql3.Field)(() => MessageRole),
|
|
288
285
|
_ts_metadata2("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
|
|
@@ -293,6 +290,7 @@ TextMessageInput = _ts_decorate2([
|
|
|
293
290
|
var ActionExecutionMessageInput = class {
|
|
294
291
|
name;
|
|
295
292
|
arguments;
|
|
293
|
+
parentMessageId;
|
|
296
294
|
scope;
|
|
297
295
|
};
|
|
298
296
|
__name(ActionExecutionMessageInput, "ActionExecutionMessageInput");
|
|
@@ -305,8 +303,17 @@ _ts_decorate2([
|
|
|
305
303
|
_ts_metadata2("design:type", String)
|
|
306
304
|
], ActionExecutionMessageInput.prototype, "arguments", void 0);
|
|
307
305
|
_ts_decorate2([
|
|
308
|
-
(0, import_type_graphql3.Field)(() =>
|
|
309
|
-
|
|
306
|
+
(0, import_type_graphql3.Field)(() => String, {
|
|
307
|
+
nullable: true
|
|
308
|
+
}),
|
|
309
|
+
_ts_metadata2("design:type", String)
|
|
310
|
+
], ActionExecutionMessageInput.prototype, "parentMessageId", void 0);
|
|
311
|
+
_ts_decorate2([
|
|
312
|
+
(0, import_type_graphql3.Field)(() => String, {
|
|
313
|
+
nullable: true,
|
|
314
|
+
deprecationReason: "This field will be removed in a future version"
|
|
315
|
+
}),
|
|
316
|
+
_ts_metadata2("design:type", typeof String === "undefined" ? Object : String)
|
|
310
317
|
], ActionExecutionMessageInput.prototype, "scope", void 0);
|
|
311
318
|
ActionExecutionMessageInput = _ts_decorate2([
|
|
312
319
|
(0, import_type_graphql3.InputType)()
|
|
@@ -314,6 +321,7 @@ ActionExecutionMessageInput = _ts_decorate2([
|
|
|
314
321
|
var ResultMessageInput = class {
|
|
315
322
|
actionExecutionId;
|
|
316
323
|
actionName;
|
|
324
|
+
parentMessageId;
|
|
317
325
|
result;
|
|
318
326
|
};
|
|
319
327
|
__name(ResultMessageInput, "ResultMessageInput");
|
|
@@ -325,6 +333,12 @@ _ts_decorate2([
|
|
|
325
333
|
(0, import_type_graphql3.Field)(() => String),
|
|
326
334
|
_ts_metadata2("design:type", String)
|
|
327
335
|
], ResultMessageInput.prototype, "actionName", void 0);
|
|
336
|
+
_ts_decorate2([
|
|
337
|
+
(0, import_type_graphql3.Field)(() => String, {
|
|
338
|
+
nullable: true
|
|
339
|
+
}),
|
|
340
|
+
_ts_metadata2("design:type", String)
|
|
341
|
+
], ResultMessageInput.prototype, "parentMessageId", void 0);
|
|
328
342
|
_ts_decorate2([
|
|
329
343
|
(0, import_type_graphql3.Field)(() => String),
|
|
330
344
|
_ts_metadata2("design:type", String)
|
|
@@ -1047,6 +1061,7 @@ BaseMessageOutput = _ts_decorate13([
|
|
|
1047
1061
|
var TextMessageOutput = class {
|
|
1048
1062
|
role;
|
|
1049
1063
|
content;
|
|
1064
|
+
parentMessageId;
|
|
1050
1065
|
};
|
|
1051
1066
|
__name(TextMessageOutput, "TextMessageOutput");
|
|
1052
1067
|
_ts_decorate13([
|
|
@@ -1059,6 +1074,12 @@ _ts_decorate13([
|
|
|
1059
1074
|
]),
|
|
1060
1075
|
_ts_metadata13("design:type", Array)
|
|
1061
1076
|
], TextMessageOutput.prototype, "content", void 0);
|
|
1077
|
+
_ts_decorate13([
|
|
1078
|
+
(0, import_type_graphql14.Field)(() => String, {
|
|
1079
|
+
nullable: true
|
|
1080
|
+
}),
|
|
1081
|
+
_ts_metadata13("design:type", String)
|
|
1082
|
+
], TextMessageOutput.prototype, "parentMessageId", void 0);
|
|
1062
1083
|
TextMessageOutput = _ts_decorate13([
|
|
1063
1084
|
(0, import_type_graphql14.ObjectType)({
|
|
1064
1085
|
implements: BaseMessageOutput
|
|
@@ -1068,6 +1089,7 @@ var ActionExecutionMessageOutput = class {
|
|
|
1068
1089
|
name;
|
|
1069
1090
|
scope;
|
|
1070
1091
|
arguments;
|
|
1092
|
+
parentMessageId;
|
|
1071
1093
|
};
|
|
1072
1094
|
__name(ActionExecutionMessageOutput, "ActionExecutionMessageOutput");
|
|
1073
1095
|
_ts_decorate13([
|
|
@@ -1075,8 +1097,11 @@ _ts_decorate13([
|
|
|
1075
1097
|
_ts_metadata13("design:type", String)
|
|
1076
1098
|
], ActionExecutionMessageOutput.prototype, "name", void 0);
|
|
1077
1099
|
_ts_decorate13([
|
|
1078
|
-
(0, import_type_graphql14.Field)(() =>
|
|
1079
|
-
|
|
1100
|
+
(0, import_type_graphql14.Field)(() => String, {
|
|
1101
|
+
nullable: true,
|
|
1102
|
+
deprecationReason: "This field will be removed in a future version"
|
|
1103
|
+
}),
|
|
1104
|
+
_ts_metadata13("design:type", String)
|
|
1080
1105
|
], ActionExecutionMessageOutput.prototype, "scope", void 0);
|
|
1081
1106
|
_ts_decorate13([
|
|
1082
1107
|
(0, import_type_graphql14.Field)(() => [
|
|
@@ -1084,6 +1109,12 @@ _ts_decorate13([
|
|
|
1084
1109
|
]),
|
|
1085
1110
|
_ts_metadata13("design:type", Array)
|
|
1086
1111
|
], ActionExecutionMessageOutput.prototype, "arguments", void 0);
|
|
1112
|
+
_ts_decorate13([
|
|
1113
|
+
(0, import_type_graphql14.Field)(() => String, {
|
|
1114
|
+
nullable: true
|
|
1115
|
+
}),
|
|
1116
|
+
_ts_metadata13("design:type", String)
|
|
1117
|
+
], ActionExecutionMessageOutput.prototype, "parentMessageId", void 0);
|
|
1087
1118
|
ActionExecutionMessageOutput = _ts_decorate13([
|
|
1088
1119
|
(0, import_type_graphql14.ObjectType)({
|
|
1089
1120
|
implements: BaseMessageOutput
|
|
@@ -1235,13 +1266,14 @@ var TextMessage = class extends Message {
|
|
|
1235
1266
|
type = "TextMessage";
|
|
1236
1267
|
content;
|
|
1237
1268
|
role;
|
|
1269
|
+
parentMessageId;
|
|
1238
1270
|
};
|
|
1239
1271
|
__name(TextMessage, "TextMessage");
|
|
1240
1272
|
var ActionExecutionMessage = class extends Message {
|
|
1241
1273
|
type = "ActionExecutionMessage";
|
|
1242
1274
|
name;
|
|
1243
1275
|
arguments;
|
|
1244
|
-
|
|
1276
|
+
parentMessageId;
|
|
1245
1277
|
};
|
|
1246
1278
|
__name(ActionExecutionMessage, "ActionExecutionMessage");
|
|
1247
1279
|
var ResultMessage = class extends Message {
|
|
@@ -1325,6 +1357,7 @@ __name(getRuntimeInstanceTelemetryInfo, "getRuntimeInstanceTelemetryInfo");
|
|
|
1325
1357
|
var telemetry_client_default = telemetryClient;
|
|
1326
1358
|
|
|
1327
1359
|
// src/service-adapters/events.ts
|
|
1360
|
+
var import_class_transformer = require("class-transformer");
|
|
1328
1361
|
var RuntimeEventTypes;
|
|
1329
1362
|
(function(RuntimeEventTypes2) {
|
|
1330
1363
|
RuntimeEventTypes2["TextMessageStart"] = "TextMessageStart";
|
|
@@ -1339,7 +1372,7 @@ var RuntimeEventTypes;
|
|
|
1339
1372
|
|
|
1340
1373
|
// src/graphql/resolvers/copilot.resolver.ts
|
|
1341
1374
|
var import_graphql_scalars2 = require("graphql-scalars");
|
|
1342
|
-
var
|
|
1375
|
+
var import_class_transformer2 = require("class-transformer");
|
|
1343
1376
|
var import_graphql = require("graphql");
|
|
1344
1377
|
|
|
1345
1378
|
// src/utils/failed-response-status-reasons.ts
|
|
@@ -1537,7 +1570,7 @@ var CopilotResolver = class {
|
|
|
1537
1570
|
reason: `Interrupted due to Guardrails validation failure. Reason: ${result.reason}`
|
|
1538
1571
|
});
|
|
1539
1572
|
outputMessages = [
|
|
1540
|
-
(0,
|
|
1573
|
+
(0, import_class_transformer2.plainToInstance)(TextMessage, {
|
|
1541
1574
|
id: (0, import_shared4.randomId)(),
|
|
1542
1575
|
createdAt: /* @__PURE__ */ new Date(),
|
|
1543
1576
|
content: result.reason,
|
|
@@ -1586,12 +1619,15 @@ var CopilotResolver = class {
|
|
|
1586
1619
|
// skip until this message start event
|
|
1587
1620
|
(0, import_rxjs3.skipWhile)((e) => e !== event),
|
|
1588
1621
|
// take until the message end event
|
|
1589
|
-
(0, import_rxjs3.takeWhile)((e) => e.type
|
|
1622
|
+
(0, import_rxjs3.takeWhile)((e) => !(e.type === RuntimeEventTypes.TextMessageEnd && e.messageId == event.messageId)),
|
|
1623
|
+
// filter out any other message events or message ids
|
|
1624
|
+
(0, import_rxjs3.filter)((e) => e.type == RuntimeEventTypes.TextMessageContent && e.messageId == event.messageId)
|
|
1590
1625
|
);
|
|
1591
1626
|
const streamingTextStatus = new import_rxjs3.Subject();
|
|
1592
1627
|
const messageId = event.messageId;
|
|
1593
1628
|
pushMessage({
|
|
1594
1629
|
id: messageId,
|
|
1630
|
+
parentMessageId: event.parentMessageId,
|
|
1595
1631
|
status: (0, import_rxjs3.firstValueFrom)(streamingTextStatus),
|
|
1596
1632
|
createdAt: /* @__PURE__ */ new Date(),
|
|
1597
1633
|
role: MessageRole.assistant,
|
|
@@ -1604,7 +1640,7 @@ var CopilotResolver = class {
|
|
|
1604
1640
|
reason,
|
|
1605
1641
|
messageId: messageId2
|
|
1606
1642
|
}, "Text streaming interrupted");
|
|
1607
|
-
streamingTextStatus.next((0,
|
|
1643
|
+
streamingTextStatus.next((0, import_class_transformer2.plainToInstance)(FailedMessageStatus, {
|
|
1608
1644
|
reason
|
|
1609
1645
|
}));
|
|
1610
1646
|
responseStatus$.next(new MessageStreamInterruptedResponse({
|
|
@@ -1637,7 +1673,7 @@ var CopilotResolver = class {
|
|
|
1637
1673
|
streamingTextStatus.next(new SuccessMessageStatus());
|
|
1638
1674
|
stopStreamingText();
|
|
1639
1675
|
textSubscription == null ? void 0 : textSubscription.unsubscribe();
|
|
1640
|
-
outputMessages.push((0,
|
|
1676
|
+
outputMessages.push((0, import_class_transformer2.plainToInstance)(TextMessage, {
|
|
1641
1677
|
id: messageId,
|
|
1642
1678
|
createdAt: /* @__PURE__ */ new Date(),
|
|
1643
1679
|
content: textChunks.join(""),
|
|
@@ -1650,14 +1686,20 @@ var CopilotResolver = class {
|
|
|
1650
1686
|
break;
|
|
1651
1687
|
case RuntimeEventTypes.ActionExecutionStart:
|
|
1652
1688
|
logger2.debug("Action execution start event received");
|
|
1653
|
-
const actionExecutionArgumentStream = eventStream.pipe(
|
|
1689
|
+
const actionExecutionArgumentStream = eventStream.pipe(
|
|
1690
|
+
(0, import_rxjs3.skipWhile)((e) => e !== event),
|
|
1691
|
+
// take until the action execution end event
|
|
1692
|
+
(0, import_rxjs3.takeWhile)((e) => !(e.type === RuntimeEventTypes.ActionExecutionEnd && e.actionExecutionId == event.actionExecutionId)),
|
|
1693
|
+
// filter out any other action execution events or action execution ids
|
|
1694
|
+
(0, import_rxjs3.filter)((e) => e.type == RuntimeEventTypes.ActionExecutionArgs && e.actionExecutionId == event.actionExecutionId)
|
|
1695
|
+
);
|
|
1654
1696
|
const streamingArgumentsStatus = new import_rxjs3.Subject();
|
|
1655
1697
|
pushMessage({
|
|
1656
1698
|
id: event.actionExecutionId,
|
|
1699
|
+
parentMessageId: event.parentMessageId,
|
|
1657
1700
|
status: (0, import_rxjs3.firstValueFrom)(streamingArgumentsStatus),
|
|
1658
1701
|
createdAt: /* @__PURE__ */ new Date(),
|
|
1659
1702
|
name: event.actionName,
|
|
1660
|
-
scope: event.scope,
|
|
1661
1703
|
arguments: new import_graphql_yoga.Repeater(async (pushArgumentsChunk, stopStreamingArguments) => {
|
|
1662
1704
|
logger2.debug("Action execution argument stream created");
|
|
1663
1705
|
const argumentChunks = [];
|
|
@@ -1673,7 +1715,7 @@ var CopilotResolver = class {
|
|
|
1673
1715
|
logger2.error({
|
|
1674
1716
|
err
|
|
1675
1717
|
}, "Error in action execution argument stream");
|
|
1676
|
-
streamingArgumentsStatus.next((0,
|
|
1718
|
+
streamingArgumentsStatus.next((0, import_class_transformer2.plainToInstance)(FailedMessageStatus, {
|
|
1677
1719
|
reason: "An unknown error has occurred in the action execution argument stream"
|
|
1678
1720
|
}));
|
|
1679
1721
|
stopStreamingArguments();
|
|
@@ -1684,11 +1726,10 @@ var CopilotResolver = class {
|
|
|
1684
1726
|
streamingArgumentsStatus.next(new SuccessMessageStatus());
|
|
1685
1727
|
stopStreamingArguments();
|
|
1686
1728
|
actionExecutionArgumentSubscription == null ? void 0 : actionExecutionArgumentSubscription.unsubscribe();
|
|
1687
|
-
outputMessages.push((0,
|
|
1729
|
+
outputMessages.push((0, import_class_transformer2.plainToInstance)(ActionExecutionMessage, {
|
|
1688
1730
|
id: event.actionExecutionId,
|
|
1689
1731
|
createdAt: /* @__PURE__ */ new Date(),
|
|
1690
1732
|
name: event.actionName,
|
|
1691
|
-
scope: event.scope,
|
|
1692
1733
|
arguments: argumentChunks.join("")
|
|
1693
1734
|
}));
|
|
1694
1735
|
}
|
|
@@ -1701,15 +1742,15 @@ var CopilotResolver = class {
|
|
|
1701
1742
|
result: event.result
|
|
1702
1743
|
}, "Action execution result event received");
|
|
1703
1744
|
pushMessage({
|
|
1704
|
-
id:
|
|
1745
|
+
id: "result-" + event.actionExecutionId,
|
|
1705
1746
|
status: new SuccessMessageStatus(),
|
|
1706
1747
|
createdAt: /* @__PURE__ */ new Date(),
|
|
1707
1748
|
actionExecutionId: event.actionExecutionId,
|
|
1708
1749
|
actionName: event.actionName,
|
|
1709
1750
|
result: event.result
|
|
1710
1751
|
});
|
|
1711
|
-
outputMessages.push((0,
|
|
1712
|
-
id:
|
|
1752
|
+
outputMessages.push((0, import_class_transformer2.plainToInstance)(ResultMessage, {
|
|
1753
|
+
id: "result-" + event.actionExecutionId,
|
|
1713
1754
|
createdAt: /* @__PURE__ */ new Date(),
|
|
1714
1755
|
actionExecutionId: event.actionExecutionId,
|
|
1715
1756
|
actionName: event.actionName,
|
|
@@ -1733,7 +1774,7 @@ var CopilotResolver = class {
|
|
|
1733
1774
|
role: MessageRole.assistant,
|
|
1734
1775
|
createdAt: /* @__PURE__ */ new Date()
|
|
1735
1776
|
});
|
|
1736
|
-
outputMessages.push((0,
|
|
1777
|
+
outputMessages.push((0, import_class_transformer2.plainToInstance)(AgentStateMessage, {
|
|
1737
1778
|
id: (0, import_shared4.randomId)(),
|
|
1738
1779
|
threadId: event.threadId,
|
|
1739
1780
|
agentName: event.agentName,
|
|
@@ -1815,7 +1856,14 @@ function createLogger(options) {
|
|
|
1815
1856
|
colorize: true
|
|
1816
1857
|
});
|
|
1817
1858
|
const logger2 = (0, import_pino.default)({
|
|
1818
|
-
level: process.env.LOG_LEVEL || level || "error"
|
|
1859
|
+
level: process.env.LOG_LEVEL || level || "error",
|
|
1860
|
+
redact: {
|
|
1861
|
+
paths: [
|
|
1862
|
+
"pid",
|
|
1863
|
+
"hostname"
|
|
1864
|
+
],
|
|
1865
|
+
remove: true
|
|
1866
|
+
}
|
|
1819
1867
|
}, stream);
|
|
1820
1868
|
if (component) {
|
|
1821
1869
|
return logger2.child({
|