@copilotkit/runtime 1.5.15-next.3 → 1.5.15-next.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.
Files changed (52) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/__snapshots__/schema/schema.graphql +26 -0
  3. package/dist/{chunk-WPJHMQDF.mjs → chunk-6AZ56PM7.mjs} +2 -2
  4. package/dist/{chunk-KPOZF6JI.mjs → chunk-AKPE4ICY.mjs} +2 -2
  5. package/dist/{chunk-EV3MMEAZ.mjs → chunk-IARJ7RBP.mjs} +513 -295
  6. package/dist/chunk-IARJ7RBP.mjs.map +1 -0
  7. package/dist/{chunk-I2OII4XX.mjs → chunk-NKM2XMY5.mjs} +2 -2
  8. package/dist/{copilot-runtime-e6c34790.d.ts → copilot-runtime-a113045f.d.ts} +13 -1
  9. package/dist/{groq-adapter-acb6ed0b.d.ts → groq-adapter-248058e8.d.ts} +1 -1
  10. package/dist/index.d.ts +3 -3
  11. package/dist/index.js +787 -571
  12. package/dist/index.js.map +1 -1
  13. package/dist/index.mjs +4 -4
  14. package/dist/{langserve-9614171f.d.ts → langserve-9580bd66.d.ts} +16 -2
  15. package/dist/lib/index.d.ts +3 -3
  16. package/dist/lib/index.js +787 -571
  17. package/dist/lib/index.js.map +1 -1
  18. package/dist/lib/index.mjs +4 -4
  19. package/dist/lib/integrations/index.d.ts +3 -3
  20. package/dist/lib/integrations/index.js +500 -319
  21. package/dist/lib/integrations/index.js.map +1 -1
  22. package/dist/lib/integrations/index.mjs +4 -4
  23. package/dist/lib/integrations/nest/index.d.ts +2 -2
  24. package/dist/lib/integrations/nest/index.js +500 -319
  25. package/dist/lib/integrations/nest/index.js.map +1 -1
  26. package/dist/lib/integrations/nest/index.mjs +2 -2
  27. package/dist/lib/integrations/node-express/index.d.ts +2 -2
  28. package/dist/lib/integrations/node-express/index.js +500 -319
  29. package/dist/lib/integrations/node-express/index.js.map +1 -1
  30. package/dist/lib/integrations/node-express/index.mjs +2 -2
  31. package/dist/lib/integrations/node-http/index.d.ts +2 -2
  32. package/dist/lib/integrations/node-http/index.js +500 -319
  33. package/dist/lib/integrations/node-http/index.js.map +1 -1
  34. package/dist/lib/integrations/node-http/index.mjs +1 -1
  35. package/dist/service-adapters/index.d.ts +3 -3
  36. package/package.json +3 -3
  37. package/src/agents/langgraph/event-source.ts +14 -2
  38. package/src/agents/langgraph/events.ts +12 -1
  39. package/src/graphql/inputs/generate-copilot-response.input.ts +4 -0
  40. package/src/graphql/inputs/meta-event.input.ts +17 -0
  41. package/src/graphql/resolvers/copilot.resolver.ts +67 -22
  42. package/src/graphql/types/copilot-response.type.ts +6 -0
  43. package/src/graphql/types/meta-events.type.ts +31 -0
  44. package/src/lib/runtime/copilot-runtime.ts +4 -0
  45. package/src/lib/runtime/remote-action-constructors.ts +5 -1
  46. package/src/lib/runtime/remote-actions.ts +2 -0
  47. package/src/lib/runtime/remote-lg-action.ts +35 -8
  48. package/src/service-adapters/events.ts +20 -1
  49. package/dist/chunk-EV3MMEAZ.mjs.map +0 -1
  50. /package/dist/{chunk-WPJHMQDF.mjs.map → chunk-6AZ56PM7.mjs.map} +0 -0
  51. /package/dist/{chunk-KPOZF6JI.mjs.map → chunk-AKPE4ICY.mjs.map} +0 -0
  52. /package/dist/{chunk-I2OII4XX.mjs.map → chunk-NKM2XMY5.mjs.map} +0 -0
package/dist/lib/index.js CHANGED
@@ -44,7 +44,7 @@ var require_package = __commonJS({
44
44
  publishConfig: {
45
45
  access: "public"
46
46
  },
47
- version: "1.5.15-next.3",
47
+ version: "1.5.15-next.5",
48
48
  sideEffects: false,
49
49
  main: "./dist/index.js",
50
50
  module: "./dist/index.mjs",
@@ -87,7 +87,7 @@ var require_package = __commonJS({
87
87
  "@langchain/community": "^0.0.53",
88
88
  "@langchain/core": "^0.3.13",
89
89
  "@langchain/google-gauth": "^0.1.0",
90
- "@langchain/langgraph-sdk": "^0.0.16",
90
+ "@langchain/langgraph-sdk": "^0.0.36",
91
91
  "@langchain/openai": "^0.0.28",
92
92
  "class-transformer": "^0.5.1",
93
93
  express: "^4.19.2",
@@ -1254,7 +1254,12 @@ var LangGraphEventTypes;
1254
1254
  LangGraphEventTypes2["OnCopilotKitEmitMessage"] = "on_copilotkit_emit_message";
1255
1255
  LangGraphEventTypes2["OnCopilotKitEmitToolCall"] = "on_copilotkit_emit_tool_call";
1256
1256
  LangGraphEventTypes2["OnCustomEvent"] = "on_custom_event";
1257
+ LangGraphEventTypes2["OnInterrupt"] = "on_interrupt";
1257
1258
  })(LangGraphEventTypes || (LangGraphEventTypes = {}));
1259
+ var MetaEventNames;
1260
+ (function(MetaEventNames2) {
1261
+ MetaEventNames2["LangGraphInterruptEvent"] = "LangGraphInterruptEvent";
1262
+ })(MetaEventNames || (MetaEventNames = {}));
1258
1263
  var CustomEventNames;
1259
1264
  (function(CustomEventNames2) {
1260
1265
  CustomEventNames2["CopilotKitManuallyEmitMessage"] = "copilotkit_manually_emit_message";
@@ -1351,6 +1356,13 @@ var RemoteLangGraphEventSource = class {
1351
1356
  shouldEmitMessages = acc.event.metadata["copilotkit:emit-messages"];
1352
1357
  }
1353
1358
  }
1359
+ if (acc.event.event === LangGraphEventTypes.OnInterrupt) {
1360
+ events.push({
1361
+ type: RuntimeEventTypes.MetaEvent,
1362
+ name: RuntimeMetaEventName.LangGraphInterruptEvent,
1363
+ value: acc.event.value
1364
+ });
1365
+ }
1354
1366
  const responseMetadata = this.getResponseMetadata(acc.event);
1355
1367
  if ((responseMetadata == null ? void 0 : responseMetadata.finish_reason) === "tool_calls" && this.shouldEmitToolCall(shouldEmitToolCalls, acc.lastToolCallName)) {
1356
1368
  events.push({
@@ -1518,6 +1530,74 @@ var ActionInputAvailability;
1518
1530
  description: "The availability of the frontend action"
1519
1531
  });
1520
1532
 
1533
+ // src/graphql/types/meta-events.type.ts
1534
+ var import_type_graphql2 = require("type-graphql");
1535
+ function _ts_decorate(decorators, target, key, desc) {
1536
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
1537
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
1538
+ r = Reflect.decorate(decorators, target, key, desc);
1539
+ else
1540
+ for (var i = decorators.length - 1; i >= 0; i--)
1541
+ if (d = decorators[i])
1542
+ r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
1543
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
1544
+ }
1545
+ __name(_ts_decorate, "_ts_decorate");
1546
+ function _ts_metadata(k, v) {
1547
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
1548
+ return Reflect.metadata(k, v);
1549
+ }
1550
+ __name(_ts_metadata, "_ts_metadata");
1551
+ var MetaEventName;
1552
+ (function(MetaEventName2) {
1553
+ MetaEventName2["LangGraphInterruptEvent"] = "LangGraphInterruptEvent";
1554
+ })(MetaEventName || (MetaEventName = {}));
1555
+ (0, import_type_graphql2.registerEnumType)(MetaEventName, {
1556
+ name: "MetaEventName",
1557
+ description: "Meta event types"
1558
+ });
1559
+ var BaseMetaEvent = class {
1560
+ type = "MetaEvent";
1561
+ name;
1562
+ };
1563
+ __name(BaseMetaEvent, "BaseMetaEvent");
1564
+ _ts_decorate([
1565
+ (0, import_type_graphql2.Field)(() => String),
1566
+ _ts_metadata("design:type", String)
1567
+ ], BaseMetaEvent.prototype, "type", void 0);
1568
+ _ts_decorate([
1569
+ (0, import_type_graphql2.Field)(() => MetaEventName),
1570
+ _ts_metadata("design:type", String)
1571
+ ], BaseMetaEvent.prototype, "name", void 0);
1572
+ BaseMetaEvent = _ts_decorate([
1573
+ (0, import_type_graphql2.InterfaceType)()
1574
+ ], BaseMetaEvent);
1575
+ var LangGraphInterruptEvent = class {
1576
+ name = "LangGraphInterruptEvent";
1577
+ value;
1578
+ response;
1579
+ };
1580
+ __name(LangGraphInterruptEvent, "LangGraphInterruptEvent");
1581
+ _ts_decorate([
1582
+ (0, import_type_graphql2.Field)(() => MetaEventName),
1583
+ _ts_metadata("design:type", typeof MetaEventName === "undefined" || false ? Object : "LangGraphInterruptEvent")
1584
+ ], LangGraphInterruptEvent.prototype, "name", void 0);
1585
+ _ts_decorate([
1586
+ (0, import_type_graphql2.Field)(() => String),
1587
+ _ts_metadata("design:type", String)
1588
+ ], LangGraphInterruptEvent.prototype, "value", void 0);
1589
+ _ts_decorate([
1590
+ (0, import_type_graphql2.Field)(() => String, {
1591
+ nullable: true
1592
+ }),
1593
+ _ts_metadata("design:type", String)
1594
+ ], LangGraphInterruptEvent.prototype, "response", void 0);
1595
+ LangGraphInterruptEvent = _ts_decorate([
1596
+ (0, import_type_graphql2.ObjectType)({
1597
+ implements: BaseMetaEvent
1598
+ })
1599
+ ], LangGraphInterruptEvent);
1600
+
1521
1601
  // src/lib/runtime/remote-lg-action.ts
1522
1602
  async function execute(args) {
1523
1603
  return new ReadableStream({
@@ -1532,8 +1612,8 @@ async function execute(args) {
1532
1612
  }
1533
1613
  __name(execute, "execute");
1534
1614
  async function streamEvents(controller, args) {
1535
- var _a, _b, _c, _d, _e, _f;
1536
- const { deploymentUrl, langsmithApiKey, threadId: argsInitialThreadId, agent, nodeName: initialNodeName, state: initialState, messages, actions, logger: logger2, properties } = args;
1615
+ var _a, _b, _c, _d, _e, _f, _g, _h;
1616
+ const { deploymentUrl, langsmithApiKey, threadId: argsInitialThreadId, agent, nodeName: initialNodeName, state: initialState, messages, actions, logger: logger2, properties, metaEvents } = args;
1537
1617
  let nodeName = initialNodeName;
1538
1618
  let state = initialState;
1539
1619
  const { name, assistantId: initialAssistantId } = agent;
@@ -1579,7 +1659,8 @@ async function streamEvents(controller, args) {
1579
1659
  logger2.error(e, `Error event thrown: ${e.message}`);
1580
1660
  }
1581
1661
  state = langGraphDefaultMergeState(state, formattedMessages, actions, name);
1582
- if (mode === "continue") {
1662
+ const lgInterruptEvent = metaEvents == null ? void 0 : metaEvents.find((ev) => ev.name === MetaEventName.LangGraphInterruptEvent);
1663
+ if (mode === "continue" && !lgInterruptEvent) {
1583
1664
  await client.threads.updateState(threadId, {
1584
1665
  values: state,
1585
1666
  asNode: nodeName
@@ -1612,13 +1693,21 @@ async function streamEvents(controller, args) {
1612
1693
  let emitIntermediateStateUntilEnd = null;
1613
1694
  let shouldExit = false;
1614
1695
  let externalRunId = null;
1615
- const streamResponse2 = client.runs.stream(threadId, assistantId, {
1696
+ const payload = {
1616
1697
  input: streamInput,
1617
1698
  streamMode: [
1618
1699
  "events",
1619
- "values"
1620
- ]
1621
- });
1700
+ "values",
1701
+ "updates"
1702
+ ],
1703
+ command: void 0
1704
+ };
1705
+ if (lgInterruptEvent == null ? void 0 : lgInterruptEvent.response) {
1706
+ payload.command = {
1707
+ resume: lgInterruptEvent.response
1708
+ };
1709
+ }
1710
+ const streamResponse2 = client.runs.stream(threadId, assistantId, payload);
1622
1711
  const emit = /* @__PURE__ */ __name((message) => controller.enqueue(new TextEncoder().encode(message)), "emit");
1623
1712
  let latestStateValues = {};
1624
1713
  let updatedState = state;
@@ -1631,12 +1720,22 @@ async function streamEvents(controller, args) {
1631
1720
  if (![
1632
1721
  "events",
1633
1722
  "values",
1634
- "error"
1723
+ "error",
1724
+ "updates"
1635
1725
  ].includes(chunk.event))
1636
1726
  continue;
1637
1727
  if (chunk.event === "error") {
1638
1728
  throw new Error(`Error event thrown: ${chunk.data.message}`);
1639
1729
  }
1730
+ if (chunk.event === "updates" && chunk.data.__interrupt__) {
1731
+ emit(JSON.stringify({
1732
+ event: LangGraphEventTypes.OnInterrupt,
1733
+ value: chunk.data.__interrupt__[0].value
1734
+ }) + "\n");
1735
+ continue;
1736
+ }
1737
+ if (chunk.event === "updates")
1738
+ continue;
1640
1739
  if (chunk.event === "values") {
1641
1740
  latestStateValues = chunk.data;
1642
1741
  continue;
@@ -1717,8 +1816,9 @@ async function streamEvents(controller, args) {
1717
1816
  emit(JSON.stringify(event) + "\n");
1718
1817
  }
1719
1818
  state = await client.threads.getState(threadId);
1720
- const isEndNode = state.next.length === 0;
1721
- nodeName = Object.keys(state.metadata.writes)[0];
1819
+ const interrupts = (_h = (_g = state.tasks) == null ? void 0 : _g[0]) == null ? void 0 : _h.interrupts;
1820
+ nodeName = interrupts ? nodeName : Object.keys(state.metadata.writes)[0];
1821
+ const isEndNode = state.next.length === 0 && !interrupts;
1722
1822
  telemetry_client_default.capture("oss.runtime.agent_execution_stream_ended", streamInfo);
1723
1823
  emit(getStateSyncEvent({
1724
1824
  threadId,
@@ -1999,7 +2099,7 @@ function constructLGCRemoteAction({ endpoint, graphqlContext, logger: logger2, m
1999
2099
  parameters: [],
2000
2100
  handler: async (_args) => {
2001
2101
  },
2002
- langGraphAgentHandler: async ({ name, actionInputsWithoutAgents, threadId, nodeName, additionalMessages = [] }) => {
2102
+ langGraphAgentHandler: async ({ name, actionInputsWithoutAgents, threadId, nodeName, additionalMessages = [], metaEvents }) => {
2003
2103
  var _a;
2004
2104
  logger2.debug({
2005
2105
  actionName: agent.name
@@ -2019,7 +2119,9 @@ function constructLGCRemoteAction({ endpoint, graphqlContext, logger: logger2, m
2019
2119
  }
2020
2120
  try {
2021
2121
  const response = await execute({
2022
- logger: logger2,
2122
+ logger: logger2.child({
2123
+ component: "remote-actions.remote-lg-action.streamEvents"
2124
+ }),
2023
2125
  deploymentUrl: endpoint.deploymentUrl,
2024
2126
  langsmithApiKey: endpoint.langsmithApiKey,
2025
2127
  agent,
@@ -2035,7 +2137,8 @@ function constructLGCRemoteAction({ endpoint, graphqlContext, logger: logger2, m
2035
2137
  name: action.name,
2036
2138
  description: action.description,
2037
2139
  parameters: JSON.parse(action.jsonSchema)
2038
- }))
2140
+ })),
2141
+ metaEvents
2039
2142
  });
2040
2143
  const eventSource = new RemoteLangGraphEventSource();
2041
2144
  streamResponse(response, eventSource.eventStream$);
@@ -2115,7 +2218,7 @@ function constructRemoteActions({ json, url, onBeforeRequest, graphqlContext, lo
2115
2218
  parameters: [],
2116
2219
  handler: async (_args) => {
2117
2220
  },
2118
- langGraphAgentHandler: async ({ name, actionInputsWithoutAgents, threadId, nodeName, additionalMessages = [] }) => {
2221
+ langGraphAgentHandler: async ({ name, actionInputsWithoutAgents, threadId, nodeName, additionalMessages = [], metaEvents }) => {
2119
2222
  var _a;
2120
2223
  logger2.debug({
2121
2224
  actionName: agent.name
@@ -2152,7 +2255,8 @@ function constructRemoteActions({ json, url, onBeforeRequest, graphqlContext, lo
2152
2255
  name: action.name,
2153
2256
  description: action.description,
2154
2257
  parameters: JSON.parse(action.jsonSchema)
2155
- }))
2258
+ })),
2259
+ metaEvents
2156
2260
  })
2157
2261
  });
2158
2262
  if (!response.ok) {
@@ -2400,8 +2504,8 @@ __name(getRuntimeInstanceTelemetryInfo, "getRuntimeInstanceTelemetryInfo");
2400
2504
  var telemetry_client_default = telemetryClient;
2401
2505
 
2402
2506
  // src/graphql/types/base/index.ts
2403
- var import_type_graphql2 = require("type-graphql");
2404
- function _ts_decorate(decorators, target, key, desc) {
2507
+ var import_type_graphql3 = require("type-graphql");
2508
+ function _ts_decorate2(decorators, target, key, desc) {
2405
2509
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
2406
2510
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
2407
2511
  r = Reflect.decorate(decorators, target, key, desc);
@@ -2411,27 +2515,27 @@ function _ts_decorate(decorators, target, key, desc) {
2411
2515
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
2412
2516
  return c > 3 && r && Object.defineProperty(target, key, r), r;
2413
2517
  }
2414
- __name(_ts_decorate, "_ts_decorate");
2415
- function _ts_metadata(k, v) {
2518
+ __name(_ts_decorate2, "_ts_decorate");
2519
+ function _ts_metadata2(k, v) {
2416
2520
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
2417
2521
  return Reflect.metadata(k, v);
2418
2522
  }
2419
- __name(_ts_metadata, "_ts_metadata");
2523
+ __name(_ts_metadata2, "_ts_metadata");
2420
2524
  var BaseMessageInput = class {
2421
2525
  id;
2422
2526
  createdAt;
2423
2527
  };
2424
2528
  __name(BaseMessageInput, "BaseMessageInput");
2425
- _ts_decorate([
2426
- (0, import_type_graphql2.Field)(() => String),
2427
- _ts_metadata("design:type", String)
2529
+ _ts_decorate2([
2530
+ (0, import_type_graphql3.Field)(() => String),
2531
+ _ts_metadata2("design:type", String)
2428
2532
  ], BaseMessageInput.prototype, "id", void 0);
2429
- _ts_decorate([
2430
- (0, import_type_graphql2.Field)(() => Date),
2431
- _ts_metadata("design:type", typeof Date === "undefined" ? Object : Date)
2533
+ _ts_decorate2([
2534
+ (0, import_type_graphql3.Field)(() => Date),
2535
+ _ts_metadata2("design:type", typeof Date === "undefined" ? Object : Date)
2432
2536
  ], BaseMessageInput.prototype, "createdAt", void 0);
2433
- BaseMessageInput = _ts_decorate([
2434
- (0, import_type_graphql2.InputType)()
2537
+ BaseMessageInput = _ts_decorate2([
2538
+ (0, import_type_graphql3.InputType)()
2435
2539
  ], BaseMessageInput);
2436
2540
 
2437
2541
  // src/graphql/types/converted/index.ts
@@ -2560,7 +2664,13 @@ var RuntimeEventTypes;
2560
2664
  RuntimeEventTypes2["ActionExecutionEnd"] = "ActionExecutionEnd";
2561
2665
  RuntimeEventTypes2["ActionExecutionResult"] = "ActionExecutionResult";
2562
2666
  RuntimeEventTypes2["AgentStateMessage"] = "AgentStateMessage";
2667
+ RuntimeEventTypes2["MetaEvent"] = "MetaEvent";
2563
2668
  })(RuntimeEventTypes || (RuntimeEventTypes = {}));
2669
+ var RuntimeMetaEventName;
2670
+ (function(RuntimeMetaEventName2) {
2671
+ RuntimeMetaEventName2["LangGraphInterruptEvent"] = "LangGraphInterruptEvent";
2672
+ RuntimeMetaEventName2["LangGraphInterruptResumeEvent"] = "LangGraphInterruptResumeEvent";
2673
+ })(RuntimeMetaEventName || (RuntimeMetaEventName = {}));
2564
2674
  var RuntimeEventSubject = class extends import_rxjs2.ReplaySubject {
2565
2675
  constructor() {
2566
2676
  super();
@@ -3106,7 +3216,7 @@ please use an LLM adapter instead.`
3106
3216
  }
3107
3217
  async processAgentRequest(request) {
3108
3218
  var _a;
3109
- const { messages: rawMessages, outputMessagesPromise, graphqlContext, agentSession, threadId: threadIdFromRequest } = request;
3219
+ const { messages: rawMessages, outputMessagesPromise, graphqlContext, agentSession, threadId: threadIdFromRequest, metaEvents } = request;
3110
3220
  const { agentName, nodeName } = agentSession;
3111
3221
  const threadId = threadIdFromRequest ?? agentSession.threadId;
3112
3222
  const serverSideActions = await this.getServerSideActions(request);
@@ -3138,7 +3248,8 @@ please use an LLM adapter instead.`
3138
3248
  name: agentName,
3139
3249
  threadId,
3140
3250
  nodeName,
3141
- actionInputsWithoutAgents
3251
+ actionInputsWithoutAgents,
3252
+ metaEvents
3142
3253
  });
3143
3254
  eventSource.stream(async (eventStream$) => {
3144
3255
  (0, import_rxjs3.from)(stream).subscribe({
@@ -3248,18 +3359,18 @@ function resolveEndpointType(endpoint) {
3248
3359
  __name(resolveEndpointType, "resolveEndpointType");
3249
3360
 
3250
3361
  // src/lib/integrations/shared.ts
3251
- var import_type_graphql24 = require("type-graphql");
3362
+ var import_type_graphql26 = require("type-graphql");
3252
3363
 
3253
3364
  // src/graphql/resolvers/copilot.resolver.ts
3254
- var import_type_graphql18 = require("type-graphql");
3365
+ var import_type_graphql20 = require("type-graphql");
3255
3366
  var import_rxjs4 = require("rxjs");
3256
3367
 
3257
3368
  // src/graphql/inputs/generate-copilot-response.input.ts
3258
- var import_type_graphql12 = require("type-graphql");
3369
+ var import_type_graphql14 = require("type-graphql");
3259
3370
 
3260
3371
  // src/graphql/inputs/message.input.ts
3261
- var import_type_graphql3 = require("type-graphql");
3262
- function _ts_decorate2(decorators, target, key, desc) {
3372
+ var import_type_graphql4 = require("type-graphql");
3373
+ function _ts_decorate3(decorators, target, key, desc) {
3263
3374
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3264
3375
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3265
3376
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3269,12 +3380,12 @@ function _ts_decorate2(decorators, target, key, desc) {
3269
3380
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3270
3381
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3271
3382
  }
3272
- __name(_ts_decorate2, "_ts_decorate");
3273
- function _ts_metadata2(k, v) {
3383
+ __name(_ts_decorate3, "_ts_decorate");
3384
+ function _ts_metadata3(k, v) {
3274
3385
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3275
3386
  return Reflect.metadata(k, v);
3276
3387
  }
3277
- __name(_ts_metadata2, "_ts_metadata");
3388
+ __name(_ts_metadata3, "_ts_metadata");
3278
3389
  var MessageInput = class extends BaseMessageInput {
3279
3390
  textMessage;
3280
3391
  actionExecutionMessage;
@@ -3282,32 +3393,32 @@ var MessageInput = class extends BaseMessageInput {
3282
3393
  agentStateMessage;
3283
3394
  };
3284
3395
  __name(MessageInput, "MessageInput");
3285
- _ts_decorate2([
3286
- (0, import_type_graphql3.Field)(() => TextMessageInput, {
3396
+ _ts_decorate3([
3397
+ (0, import_type_graphql4.Field)(() => TextMessageInput, {
3287
3398
  nullable: true
3288
3399
  }),
3289
- _ts_metadata2("design:type", typeof TextMessageInput === "undefined" ? Object : TextMessageInput)
3400
+ _ts_metadata3("design:type", typeof TextMessageInput === "undefined" ? Object : TextMessageInput)
3290
3401
  ], MessageInput.prototype, "textMessage", void 0);
3291
- _ts_decorate2([
3292
- (0, import_type_graphql3.Field)(() => ActionExecutionMessageInput, {
3402
+ _ts_decorate3([
3403
+ (0, import_type_graphql4.Field)(() => ActionExecutionMessageInput, {
3293
3404
  nullable: true
3294
3405
  }),
3295
- _ts_metadata2("design:type", typeof ActionExecutionMessageInput === "undefined" ? Object : ActionExecutionMessageInput)
3406
+ _ts_metadata3("design:type", typeof ActionExecutionMessageInput === "undefined" ? Object : ActionExecutionMessageInput)
3296
3407
  ], MessageInput.prototype, "actionExecutionMessage", void 0);
3297
- _ts_decorate2([
3298
- (0, import_type_graphql3.Field)(() => ResultMessageInput, {
3408
+ _ts_decorate3([
3409
+ (0, import_type_graphql4.Field)(() => ResultMessageInput, {
3299
3410
  nullable: true
3300
3411
  }),
3301
- _ts_metadata2("design:type", typeof ResultMessageInput === "undefined" ? Object : ResultMessageInput)
3412
+ _ts_metadata3("design:type", typeof ResultMessageInput === "undefined" ? Object : ResultMessageInput)
3302
3413
  ], MessageInput.prototype, "resultMessage", void 0);
3303
- _ts_decorate2([
3304
- (0, import_type_graphql3.Field)(() => AgentStateMessageInput, {
3414
+ _ts_decorate3([
3415
+ (0, import_type_graphql4.Field)(() => AgentStateMessageInput, {
3305
3416
  nullable: true
3306
3417
  }),
3307
- _ts_metadata2("design:type", typeof AgentStateMessageInput === "undefined" ? Object : AgentStateMessageInput)
3418
+ _ts_metadata3("design:type", typeof AgentStateMessageInput === "undefined" ? Object : AgentStateMessageInput)
3308
3419
  ], MessageInput.prototype, "agentStateMessage", void 0);
3309
- MessageInput = _ts_decorate2([
3310
- (0, import_type_graphql3.InputType)()
3420
+ MessageInput = _ts_decorate3([
3421
+ (0, import_type_graphql4.InputType)()
3311
3422
  ], MessageInput);
3312
3423
  var TextMessageInput = class {
3313
3424
  content;
@@ -3315,22 +3426,22 @@ var TextMessageInput = class {
3315
3426
  role;
3316
3427
  };
3317
3428
  __name(TextMessageInput, "TextMessageInput");
3318
- _ts_decorate2([
3319
- (0, import_type_graphql3.Field)(() => String),
3320
- _ts_metadata2("design:type", String)
3429
+ _ts_decorate3([
3430
+ (0, import_type_graphql4.Field)(() => String),
3431
+ _ts_metadata3("design:type", String)
3321
3432
  ], TextMessageInput.prototype, "content", void 0);
3322
- _ts_decorate2([
3323
- (0, import_type_graphql3.Field)(() => String, {
3433
+ _ts_decorate3([
3434
+ (0, import_type_graphql4.Field)(() => String, {
3324
3435
  nullable: true
3325
3436
  }),
3326
- _ts_metadata2("design:type", String)
3437
+ _ts_metadata3("design:type", String)
3327
3438
  ], TextMessageInput.prototype, "parentMessageId", void 0);
3328
- _ts_decorate2([
3329
- (0, import_type_graphql3.Field)(() => MessageRole),
3330
- _ts_metadata2("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
3439
+ _ts_decorate3([
3440
+ (0, import_type_graphql4.Field)(() => MessageRole),
3441
+ _ts_metadata3("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
3331
3442
  ], TextMessageInput.prototype, "role", void 0);
3332
- TextMessageInput = _ts_decorate2([
3333
- (0, import_type_graphql3.InputType)()
3443
+ TextMessageInput = _ts_decorate3([
3444
+ (0, import_type_graphql4.InputType)()
3334
3445
  ], TextMessageInput);
3335
3446
  var ActionExecutionMessageInput = class {
3336
3447
  name;
@@ -3339,29 +3450,29 @@ var ActionExecutionMessageInput = class {
3339
3450
  scope;
3340
3451
  };
3341
3452
  __name(ActionExecutionMessageInput, "ActionExecutionMessageInput");
3342
- _ts_decorate2([
3343
- (0, import_type_graphql3.Field)(() => String),
3344
- _ts_metadata2("design:type", String)
3453
+ _ts_decorate3([
3454
+ (0, import_type_graphql4.Field)(() => String),
3455
+ _ts_metadata3("design:type", String)
3345
3456
  ], ActionExecutionMessageInput.prototype, "name", void 0);
3346
- _ts_decorate2([
3347
- (0, import_type_graphql3.Field)(() => String),
3348
- _ts_metadata2("design:type", String)
3457
+ _ts_decorate3([
3458
+ (0, import_type_graphql4.Field)(() => String),
3459
+ _ts_metadata3("design:type", String)
3349
3460
  ], ActionExecutionMessageInput.prototype, "arguments", void 0);
3350
- _ts_decorate2([
3351
- (0, import_type_graphql3.Field)(() => String, {
3461
+ _ts_decorate3([
3462
+ (0, import_type_graphql4.Field)(() => String, {
3352
3463
  nullable: true
3353
3464
  }),
3354
- _ts_metadata2("design:type", String)
3465
+ _ts_metadata3("design:type", String)
3355
3466
  ], ActionExecutionMessageInput.prototype, "parentMessageId", void 0);
3356
- _ts_decorate2([
3357
- (0, import_type_graphql3.Field)(() => String, {
3467
+ _ts_decorate3([
3468
+ (0, import_type_graphql4.Field)(() => String, {
3358
3469
  nullable: true,
3359
3470
  deprecationReason: "This field will be removed in a future version"
3360
3471
  }),
3361
- _ts_metadata2("design:type", typeof String === "undefined" ? Object : String)
3472
+ _ts_metadata3("design:type", typeof String === "undefined" ? Object : String)
3362
3473
  ], ActionExecutionMessageInput.prototype, "scope", void 0);
3363
- ActionExecutionMessageInput = _ts_decorate2([
3364
- (0, import_type_graphql3.InputType)()
3474
+ ActionExecutionMessageInput = _ts_decorate3([
3475
+ (0, import_type_graphql4.InputType)()
3365
3476
  ], ActionExecutionMessageInput);
3366
3477
  var ResultMessageInput = class {
3367
3478
  actionExecutionId;
@@ -3370,26 +3481,26 @@ var ResultMessageInput = class {
3370
3481
  result;
3371
3482
  };
3372
3483
  __name(ResultMessageInput, "ResultMessageInput");
3373
- _ts_decorate2([
3374
- (0, import_type_graphql3.Field)(() => String),
3375
- _ts_metadata2("design:type", String)
3484
+ _ts_decorate3([
3485
+ (0, import_type_graphql4.Field)(() => String),
3486
+ _ts_metadata3("design:type", String)
3376
3487
  ], ResultMessageInput.prototype, "actionExecutionId", void 0);
3377
- _ts_decorate2([
3378
- (0, import_type_graphql3.Field)(() => String),
3379
- _ts_metadata2("design:type", String)
3488
+ _ts_decorate3([
3489
+ (0, import_type_graphql4.Field)(() => String),
3490
+ _ts_metadata3("design:type", String)
3380
3491
  ], ResultMessageInput.prototype, "actionName", void 0);
3381
- _ts_decorate2([
3382
- (0, import_type_graphql3.Field)(() => String, {
3492
+ _ts_decorate3([
3493
+ (0, import_type_graphql4.Field)(() => String, {
3383
3494
  nullable: true
3384
3495
  }),
3385
- _ts_metadata2("design:type", String)
3496
+ _ts_metadata3("design:type", String)
3386
3497
  ], ResultMessageInput.prototype, "parentMessageId", void 0);
3387
- _ts_decorate2([
3388
- (0, import_type_graphql3.Field)(() => String),
3389
- _ts_metadata2("design:type", String)
3498
+ _ts_decorate3([
3499
+ (0, import_type_graphql4.Field)(() => String),
3500
+ _ts_metadata3("design:type", String)
3390
3501
  ], ResultMessageInput.prototype, "result", void 0);
3391
- ResultMessageInput = _ts_decorate2([
3392
- (0, import_type_graphql3.InputType)()
3502
+ ResultMessageInput = _ts_decorate3([
3503
+ (0, import_type_graphql4.InputType)()
3393
3504
  ], ResultMessageInput);
3394
3505
  var AgentStateMessageInput = class {
3395
3506
  threadId;
@@ -3402,48 +3513,48 @@ var AgentStateMessageInput = class {
3402
3513
  active;
3403
3514
  };
3404
3515
  __name(AgentStateMessageInput, "AgentStateMessageInput");
3405
- _ts_decorate2([
3406
- (0, import_type_graphql3.Field)(() => String),
3407
- _ts_metadata2("design:type", String)
3516
+ _ts_decorate3([
3517
+ (0, import_type_graphql4.Field)(() => String),
3518
+ _ts_metadata3("design:type", String)
3408
3519
  ], AgentStateMessageInput.prototype, "threadId", void 0);
3409
- _ts_decorate2([
3410
- (0, import_type_graphql3.Field)(() => String),
3411
- _ts_metadata2("design:type", String)
3520
+ _ts_decorate3([
3521
+ (0, import_type_graphql4.Field)(() => String),
3522
+ _ts_metadata3("design:type", String)
3412
3523
  ], AgentStateMessageInput.prototype, "agentName", void 0);
3413
- _ts_decorate2([
3414
- (0, import_type_graphql3.Field)(() => MessageRole),
3415
- _ts_metadata2("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
3524
+ _ts_decorate3([
3525
+ (0, import_type_graphql4.Field)(() => MessageRole),
3526
+ _ts_metadata3("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
3416
3527
  ], AgentStateMessageInput.prototype, "role", void 0);
3417
- _ts_decorate2([
3418
- (0, import_type_graphql3.Field)(() => String),
3419
- _ts_metadata2("design:type", String)
3528
+ _ts_decorate3([
3529
+ (0, import_type_graphql4.Field)(() => String),
3530
+ _ts_metadata3("design:type", String)
3420
3531
  ], AgentStateMessageInput.prototype, "state", void 0);
3421
- _ts_decorate2([
3422
- (0, import_type_graphql3.Field)(() => Boolean),
3423
- _ts_metadata2("design:type", Boolean)
3532
+ _ts_decorate3([
3533
+ (0, import_type_graphql4.Field)(() => Boolean),
3534
+ _ts_metadata3("design:type", Boolean)
3424
3535
  ], AgentStateMessageInput.prototype, "running", void 0);
3425
- _ts_decorate2([
3426
- (0, import_type_graphql3.Field)(() => String),
3427
- _ts_metadata2("design:type", String)
3536
+ _ts_decorate3([
3537
+ (0, import_type_graphql4.Field)(() => String),
3538
+ _ts_metadata3("design:type", String)
3428
3539
  ], AgentStateMessageInput.prototype, "nodeName", void 0);
3429
- _ts_decorate2([
3430
- (0, import_type_graphql3.Field)(() => String),
3431
- _ts_metadata2("design:type", String)
3540
+ _ts_decorate3([
3541
+ (0, import_type_graphql4.Field)(() => String),
3542
+ _ts_metadata3("design:type", String)
3432
3543
  ], AgentStateMessageInput.prototype, "runId", void 0);
3433
- _ts_decorate2([
3434
- (0, import_type_graphql3.Field)(() => Boolean),
3435
- _ts_metadata2("design:type", Boolean)
3544
+ _ts_decorate3([
3545
+ (0, import_type_graphql4.Field)(() => Boolean),
3546
+ _ts_metadata3("design:type", Boolean)
3436
3547
  ], AgentStateMessageInput.prototype, "active", void 0);
3437
- AgentStateMessageInput = _ts_decorate2([
3438
- (0, import_type_graphql3.InputType)()
3548
+ AgentStateMessageInput = _ts_decorate3([
3549
+ (0, import_type_graphql4.InputType)()
3439
3550
  ], AgentStateMessageInput);
3440
3551
 
3441
3552
  // src/graphql/inputs/frontend.input.ts
3442
- var import_type_graphql5 = require("type-graphql");
3553
+ var import_type_graphql6 = require("type-graphql");
3443
3554
 
3444
3555
  // src/graphql/inputs/action.input.ts
3445
- var import_type_graphql4 = require("type-graphql");
3446
- function _ts_decorate3(decorators, target, key, desc) {
3556
+ var import_type_graphql5 = require("type-graphql");
3557
+ function _ts_decorate4(decorators, target, key, desc) {
3447
3558
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3448
3559
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3449
3560
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3453,12 +3564,12 @@ function _ts_decorate3(decorators, target, key, desc) {
3453
3564
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3454
3565
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3455
3566
  }
3456
- __name(_ts_decorate3, "_ts_decorate");
3457
- function _ts_metadata3(k, v) {
3567
+ __name(_ts_decorate4, "_ts_decorate");
3568
+ function _ts_metadata4(k, v) {
3458
3569
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3459
3570
  return Reflect.metadata(k, v);
3460
3571
  }
3461
- __name(_ts_metadata3, "_ts_metadata");
3572
+ __name(_ts_metadata4, "_ts_metadata");
3462
3573
  var ActionInput = class {
3463
3574
  name;
3464
3575
  description;
@@ -3466,30 +3577,30 @@ var ActionInput = class {
3466
3577
  available;
3467
3578
  };
3468
3579
  __name(ActionInput, "ActionInput");
3469
- _ts_decorate3([
3470
- (0, import_type_graphql4.Field)(() => String),
3471
- _ts_metadata3("design:type", String)
3580
+ _ts_decorate4([
3581
+ (0, import_type_graphql5.Field)(() => String),
3582
+ _ts_metadata4("design:type", String)
3472
3583
  ], ActionInput.prototype, "name", void 0);
3473
- _ts_decorate3([
3474
- (0, import_type_graphql4.Field)(() => String),
3475
- _ts_metadata3("design:type", String)
3584
+ _ts_decorate4([
3585
+ (0, import_type_graphql5.Field)(() => String),
3586
+ _ts_metadata4("design:type", String)
3476
3587
  ], ActionInput.prototype, "description", void 0);
3477
- _ts_decorate3([
3478
- (0, import_type_graphql4.Field)(() => String),
3479
- _ts_metadata3("design:type", String)
3588
+ _ts_decorate4([
3589
+ (0, import_type_graphql5.Field)(() => String),
3590
+ _ts_metadata4("design:type", String)
3480
3591
  ], ActionInput.prototype, "jsonSchema", void 0);
3481
- _ts_decorate3([
3482
- (0, import_type_graphql4.Field)(() => ActionInputAvailability, {
3592
+ _ts_decorate4([
3593
+ (0, import_type_graphql5.Field)(() => ActionInputAvailability, {
3483
3594
  nullable: true
3484
3595
  }),
3485
- _ts_metadata3("design:type", typeof ActionInputAvailability === "undefined" ? Object : ActionInputAvailability)
3596
+ _ts_metadata4("design:type", typeof ActionInputAvailability === "undefined" ? Object : ActionInputAvailability)
3486
3597
  ], ActionInput.prototype, "available", void 0);
3487
- ActionInput = _ts_decorate3([
3488
- (0, import_type_graphql4.InputType)()
3598
+ ActionInput = _ts_decorate4([
3599
+ (0, import_type_graphql5.InputType)()
3489
3600
  ], ActionInput);
3490
3601
 
3491
3602
  // src/graphql/inputs/frontend.input.ts
3492
- function _ts_decorate4(decorators, target, key, desc) {
3603
+ function _ts_decorate5(decorators, target, key, desc) {
3493
3604
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3494
3605
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3495
3606
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3499,46 +3610,46 @@ function _ts_decorate4(decorators, target, key, desc) {
3499
3610
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3500
3611
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3501
3612
  }
3502
- __name(_ts_decorate4, "_ts_decorate");
3503
- function _ts_metadata4(k, v) {
3613
+ __name(_ts_decorate5, "_ts_decorate");
3614
+ function _ts_metadata5(k, v) {
3504
3615
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3505
3616
  return Reflect.metadata(k, v);
3506
3617
  }
3507
- __name(_ts_metadata4, "_ts_metadata");
3618
+ __name(_ts_metadata5, "_ts_metadata");
3508
3619
  var FrontendInput = class {
3509
3620
  toDeprecate_fullContext;
3510
3621
  actions;
3511
3622
  url;
3512
3623
  };
3513
3624
  __name(FrontendInput, "FrontendInput");
3514
- _ts_decorate4([
3515
- (0, import_type_graphql5.Field)(() => String, {
3625
+ _ts_decorate5([
3626
+ (0, import_type_graphql6.Field)(() => String, {
3516
3627
  nullable: true
3517
3628
  }),
3518
- _ts_metadata4("design:type", String)
3629
+ _ts_metadata5("design:type", String)
3519
3630
  ], FrontendInput.prototype, "toDeprecate_fullContext", void 0);
3520
- _ts_decorate4([
3521
- (0, import_type_graphql5.Field)(() => [
3631
+ _ts_decorate5([
3632
+ (0, import_type_graphql6.Field)(() => [
3522
3633
  ActionInput
3523
3634
  ]),
3524
- _ts_metadata4("design:type", Array)
3635
+ _ts_metadata5("design:type", Array)
3525
3636
  ], FrontendInput.prototype, "actions", void 0);
3526
- _ts_decorate4([
3527
- (0, import_type_graphql5.Field)(() => String, {
3637
+ _ts_decorate5([
3638
+ (0, import_type_graphql6.Field)(() => String, {
3528
3639
  nullable: true
3529
3640
  }),
3530
- _ts_metadata4("design:type", String)
3641
+ _ts_metadata5("design:type", String)
3531
3642
  ], FrontendInput.prototype, "url", void 0);
3532
- FrontendInput = _ts_decorate4([
3533
- (0, import_type_graphql5.InputType)()
3643
+ FrontendInput = _ts_decorate5([
3644
+ (0, import_type_graphql6.InputType)()
3534
3645
  ], FrontendInput);
3535
3646
 
3536
3647
  // src/graphql/inputs/cloud.input.ts
3537
- var import_type_graphql7 = require("type-graphql");
3648
+ var import_type_graphql8 = require("type-graphql");
3538
3649
 
3539
3650
  // src/graphql/inputs/cloud-guardrails.input.ts
3540
- var import_type_graphql6 = require("type-graphql");
3541
- function _ts_decorate5(decorators, target, key, desc) {
3651
+ var import_type_graphql7 = require("type-graphql");
3652
+ function _ts_decorate6(decorators, target, key, desc) {
3542
3653
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3543
3654
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3544
3655
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3548,52 +3659,52 @@ function _ts_decorate5(decorators, target, key, desc) {
3548
3659
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3549
3660
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3550
3661
  }
3551
- __name(_ts_decorate5, "_ts_decorate");
3552
- function _ts_metadata5(k, v) {
3662
+ __name(_ts_decorate6, "_ts_decorate");
3663
+ function _ts_metadata6(k, v) {
3553
3664
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3554
3665
  return Reflect.metadata(k, v);
3555
3666
  }
3556
- __name(_ts_metadata5, "_ts_metadata");
3667
+ __name(_ts_metadata6, "_ts_metadata");
3557
3668
  var GuardrailsRuleInput = class {
3558
3669
  allowList = [];
3559
3670
  denyList = [];
3560
3671
  };
3561
3672
  __name(GuardrailsRuleInput, "GuardrailsRuleInput");
3562
- _ts_decorate5([
3563
- (0, import_type_graphql6.Field)(() => [
3673
+ _ts_decorate6([
3674
+ (0, import_type_graphql7.Field)(() => [
3564
3675
  String
3565
3676
  ], {
3566
3677
  nullable: true
3567
3678
  }),
3568
- _ts_metadata5("design:type", Array)
3679
+ _ts_metadata6("design:type", Array)
3569
3680
  ], GuardrailsRuleInput.prototype, "allowList", void 0);
3570
- _ts_decorate5([
3571
- (0, import_type_graphql6.Field)(() => [
3681
+ _ts_decorate6([
3682
+ (0, import_type_graphql7.Field)(() => [
3572
3683
  String
3573
3684
  ], {
3574
3685
  nullable: true
3575
3686
  }),
3576
- _ts_metadata5("design:type", Array)
3687
+ _ts_metadata6("design:type", Array)
3577
3688
  ], GuardrailsRuleInput.prototype, "denyList", void 0);
3578
- GuardrailsRuleInput = _ts_decorate5([
3579
- (0, import_type_graphql6.InputType)()
3689
+ GuardrailsRuleInput = _ts_decorate6([
3690
+ (0, import_type_graphql7.InputType)()
3580
3691
  ], GuardrailsRuleInput);
3581
3692
  var GuardrailsInput = class {
3582
3693
  inputValidationRules;
3583
3694
  };
3584
3695
  __name(GuardrailsInput, "GuardrailsInput");
3585
- _ts_decorate5([
3586
- (0, import_type_graphql6.Field)(() => GuardrailsRuleInput, {
3696
+ _ts_decorate6([
3697
+ (0, import_type_graphql7.Field)(() => GuardrailsRuleInput, {
3587
3698
  nullable: false
3588
3699
  }),
3589
- _ts_metadata5("design:type", typeof GuardrailsRuleInput === "undefined" ? Object : GuardrailsRuleInput)
3700
+ _ts_metadata6("design:type", typeof GuardrailsRuleInput === "undefined" ? Object : GuardrailsRuleInput)
3590
3701
  ], GuardrailsInput.prototype, "inputValidationRules", void 0);
3591
- GuardrailsInput = _ts_decorate5([
3592
- (0, import_type_graphql6.InputType)()
3702
+ GuardrailsInput = _ts_decorate6([
3703
+ (0, import_type_graphql7.InputType)()
3593
3704
  ], GuardrailsInput);
3594
3705
 
3595
3706
  // src/graphql/inputs/cloud.input.ts
3596
- function _ts_decorate6(decorators, target, key, desc) {
3707
+ function _ts_decorate7(decorators, target, key, desc) {
3597
3708
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3598
3709
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3599
3710
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3603,29 +3714,29 @@ function _ts_decorate6(decorators, target, key, desc) {
3603
3714
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3604
3715
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3605
3716
  }
3606
- __name(_ts_decorate6, "_ts_decorate");
3607
- function _ts_metadata6(k, v) {
3717
+ __name(_ts_decorate7, "_ts_decorate");
3718
+ function _ts_metadata7(k, v) {
3608
3719
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3609
3720
  return Reflect.metadata(k, v);
3610
3721
  }
3611
- __name(_ts_metadata6, "_ts_metadata");
3722
+ __name(_ts_metadata7, "_ts_metadata");
3612
3723
  var CloudInput = class {
3613
3724
  guardrails;
3614
3725
  };
3615
3726
  __name(CloudInput, "CloudInput");
3616
- _ts_decorate6([
3617
- (0, import_type_graphql7.Field)(() => GuardrailsInput, {
3727
+ _ts_decorate7([
3728
+ (0, import_type_graphql8.Field)(() => GuardrailsInput, {
3618
3729
  nullable: true
3619
3730
  }),
3620
- _ts_metadata6("design:type", typeof GuardrailsInput === "undefined" ? Object : GuardrailsInput)
3731
+ _ts_metadata7("design:type", typeof GuardrailsInput === "undefined" ? Object : GuardrailsInput)
3621
3732
  ], CloudInput.prototype, "guardrails", void 0);
3622
- CloudInput = _ts_decorate6([
3623
- (0, import_type_graphql7.InputType)()
3733
+ CloudInput = _ts_decorate7([
3734
+ (0, import_type_graphql8.InputType)()
3624
3735
  ], CloudInput);
3625
3736
 
3626
3737
  // src/graphql/inputs/forwarded-parameters.input.ts
3627
- var import_type_graphql8 = require("type-graphql");
3628
- function _ts_decorate7(decorators, target, key, desc) {
3738
+ var import_type_graphql9 = require("type-graphql");
3739
+ function _ts_decorate8(decorators, target, key, desc) {
3629
3740
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3630
3741
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3631
3742
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3635,12 +3746,12 @@ function _ts_decorate7(decorators, target, key, desc) {
3635
3746
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3636
3747
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3637
3748
  }
3638
- __name(_ts_decorate7, "_ts_decorate");
3639
- function _ts_metadata7(k, v) {
3749
+ __name(_ts_decorate8, "_ts_decorate");
3750
+ function _ts_metadata8(k, v) {
3640
3751
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3641
3752
  return Reflect.metadata(k, v);
3642
3753
  }
3643
- __name(_ts_metadata7, "_ts_metadata");
3754
+ __name(_ts_metadata8, "_ts_metadata");
3644
3755
  var ForwardedParametersInput = class {
3645
3756
  model;
3646
3757
  maxTokens;
@@ -3650,51 +3761,51 @@ var ForwardedParametersInput = class {
3650
3761
  temperature;
3651
3762
  };
3652
3763
  __name(ForwardedParametersInput, "ForwardedParametersInput");
3653
- _ts_decorate7([
3654
- (0, import_type_graphql8.Field)(() => String, {
3764
+ _ts_decorate8([
3765
+ (0, import_type_graphql9.Field)(() => String, {
3655
3766
  nullable: true
3656
3767
  }),
3657
- _ts_metadata7("design:type", String)
3768
+ _ts_metadata8("design:type", String)
3658
3769
  ], ForwardedParametersInput.prototype, "model", void 0);
3659
- _ts_decorate7([
3660
- (0, import_type_graphql8.Field)(() => Number, {
3770
+ _ts_decorate8([
3771
+ (0, import_type_graphql9.Field)(() => Number, {
3661
3772
  nullable: true
3662
3773
  }),
3663
- _ts_metadata7("design:type", Number)
3774
+ _ts_metadata8("design:type", Number)
3664
3775
  ], ForwardedParametersInput.prototype, "maxTokens", void 0);
3665
- _ts_decorate7([
3666
- (0, import_type_graphql8.Field)(() => [
3776
+ _ts_decorate8([
3777
+ (0, import_type_graphql9.Field)(() => [
3667
3778
  String
3668
3779
  ], {
3669
3780
  nullable: true
3670
3781
  }),
3671
- _ts_metadata7("design:type", Array)
3782
+ _ts_metadata8("design:type", Array)
3672
3783
  ], ForwardedParametersInput.prototype, "stop", void 0);
3673
- _ts_decorate7([
3674
- (0, import_type_graphql8.Field)(() => String, {
3784
+ _ts_decorate8([
3785
+ (0, import_type_graphql9.Field)(() => String, {
3675
3786
  nullable: true
3676
3787
  }),
3677
- _ts_metadata7("design:type", typeof String === "undefined" ? Object : String)
3788
+ _ts_metadata8("design:type", typeof String === "undefined" ? Object : String)
3678
3789
  ], ForwardedParametersInput.prototype, "toolChoice", void 0);
3679
- _ts_decorate7([
3680
- (0, import_type_graphql8.Field)(() => String, {
3790
+ _ts_decorate8([
3791
+ (0, import_type_graphql9.Field)(() => String, {
3681
3792
  nullable: true
3682
3793
  }),
3683
- _ts_metadata7("design:type", String)
3794
+ _ts_metadata8("design:type", String)
3684
3795
  ], ForwardedParametersInput.prototype, "toolChoiceFunctionName", void 0);
3685
- _ts_decorate7([
3686
- (0, import_type_graphql8.Field)(() => Number, {
3796
+ _ts_decorate8([
3797
+ (0, import_type_graphql9.Field)(() => Number, {
3687
3798
  nullable: true
3688
3799
  }),
3689
- _ts_metadata7("design:type", Number)
3800
+ _ts_metadata8("design:type", Number)
3690
3801
  ], ForwardedParametersInput.prototype, "temperature", void 0);
3691
- ForwardedParametersInput = _ts_decorate7([
3692
- (0, import_type_graphql8.InputType)()
3802
+ ForwardedParametersInput = _ts_decorate8([
3803
+ (0, import_type_graphql9.InputType)()
3693
3804
  ], ForwardedParametersInput);
3694
3805
 
3695
3806
  // src/graphql/inputs/agent-session.input.ts
3696
- var import_type_graphql9 = require("type-graphql");
3697
- function _ts_decorate8(decorators, target, key, desc) {
3807
+ var import_type_graphql10 = require("type-graphql");
3808
+ function _ts_decorate9(decorators, target, key, desc) {
3698
3809
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3699
3810
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3700
3811
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3704,41 +3815,41 @@ function _ts_decorate8(decorators, target, key, desc) {
3704
3815
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3705
3816
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3706
3817
  }
3707
- __name(_ts_decorate8, "_ts_decorate");
3708
- function _ts_metadata8(k, v) {
3818
+ __name(_ts_decorate9, "_ts_decorate");
3819
+ function _ts_metadata9(k, v) {
3709
3820
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3710
3821
  return Reflect.metadata(k, v);
3711
3822
  }
3712
- __name(_ts_metadata8, "_ts_metadata");
3823
+ __name(_ts_metadata9, "_ts_metadata");
3713
3824
  var AgentSessionInput = class {
3714
3825
  agentName;
3715
3826
  threadId;
3716
3827
  nodeName;
3717
3828
  };
3718
3829
  __name(AgentSessionInput, "AgentSessionInput");
3719
- _ts_decorate8([
3720
- (0, import_type_graphql9.Field)(() => String),
3721
- _ts_metadata8("design:type", String)
3830
+ _ts_decorate9([
3831
+ (0, import_type_graphql10.Field)(() => String),
3832
+ _ts_metadata9("design:type", String)
3722
3833
  ], AgentSessionInput.prototype, "agentName", void 0);
3723
- _ts_decorate8([
3724
- (0, import_type_graphql9.Field)(() => String, {
3834
+ _ts_decorate9([
3835
+ (0, import_type_graphql10.Field)(() => String, {
3725
3836
  nullable: true
3726
3837
  }),
3727
- _ts_metadata8("design:type", String)
3838
+ _ts_metadata9("design:type", String)
3728
3839
  ], AgentSessionInput.prototype, "threadId", void 0);
3729
- _ts_decorate8([
3730
- (0, import_type_graphql9.Field)(() => String, {
3840
+ _ts_decorate9([
3841
+ (0, import_type_graphql10.Field)(() => String, {
3731
3842
  nullable: true
3732
3843
  }),
3733
- _ts_metadata8("design:type", String)
3844
+ _ts_metadata9("design:type", String)
3734
3845
  ], AgentSessionInput.prototype, "nodeName", void 0);
3735
- AgentSessionInput = _ts_decorate8([
3736
- (0, import_type_graphql9.InputType)()
3846
+ AgentSessionInput = _ts_decorate9([
3847
+ (0, import_type_graphql10.InputType)()
3737
3848
  ], AgentSessionInput);
3738
3849
 
3739
3850
  // src/graphql/inputs/agent-state.input.ts
3740
- var import_type_graphql10 = require("type-graphql");
3741
- function _ts_decorate9(decorators, target, key, desc) {
3851
+ var import_type_graphql11 = require("type-graphql");
3852
+ function _ts_decorate10(decorators, target, key, desc) {
3742
3853
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3743
3854
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3744
3855
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3748,32 +3859,32 @@ function _ts_decorate9(decorators, target, key, desc) {
3748
3859
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3749
3860
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3750
3861
  }
3751
- __name(_ts_decorate9, "_ts_decorate");
3752
- function _ts_metadata9(k, v) {
3862
+ __name(_ts_decorate10, "_ts_decorate");
3863
+ function _ts_metadata10(k, v) {
3753
3864
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3754
3865
  return Reflect.metadata(k, v);
3755
3866
  }
3756
- __name(_ts_metadata9, "_ts_metadata");
3867
+ __name(_ts_metadata10, "_ts_metadata");
3757
3868
  var AgentStateInput = class {
3758
3869
  agentName;
3759
3870
  state;
3760
3871
  };
3761
3872
  __name(AgentStateInput, "AgentStateInput");
3762
- _ts_decorate9([
3763
- (0, import_type_graphql10.Field)(() => String),
3764
- _ts_metadata9("design:type", String)
3873
+ _ts_decorate10([
3874
+ (0, import_type_graphql11.Field)(() => String),
3875
+ _ts_metadata10("design:type", String)
3765
3876
  ], AgentStateInput.prototype, "agentName", void 0);
3766
- _ts_decorate9([
3767
- (0, import_type_graphql10.Field)(() => String),
3768
- _ts_metadata9("design:type", String)
3877
+ _ts_decorate10([
3878
+ (0, import_type_graphql11.Field)(() => String),
3879
+ _ts_metadata10("design:type", String)
3769
3880
  ], AgentStateInput.prototype, "state", void 0);
3770
- AgentStateInput = _ts_decorate9([
3771
- (0, import_type_graphql10.InputType)()
3881
+ AgentStateInput = _ts_decorate10([
3882
+ (0, import_type_graphql11.InputType)()
3772
3883
  ], AgentStateInput);
3773
3884
 
3774
3885
  // src/graphql/inputs/extensions.input.ts
3775
- var import_type_graphql11 = require("type-graphql");
3776
- function _ts_decorate10(decorators, target, key, desc) {
3886
+ var import_type_graphql12 = require("type-graphql");
3887
+ function _ts_decorate11(decorators, target, key, desc) {
3777
3888
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3778
3889
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3779
3890
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3783,48 +3894,95 @@ function _ts_decorate10(decorators, target, key, desc) {
3783
3894
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3784
3895
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3785
3896
  }
3786
- __name(_ts_decorate10, "_ts_decorate");
3787
- function _ts_metadata10(k, v) {
3897
+ __name(_ts_decorate11, "_ts_decorate");
3898
+ function _ts_metadata11(k, v) {
3788
3899
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3789
3900
  return Reflect.metadata(k, v);
3790
3901
  }
3791
- __name(_ts_metadata10, "_ts_metadata");
3902
+ __name(_ts_metadata11, "_ts_metadata");
3792
3903
  var ExtensionsInput = class {
3793
3904
  openaiAssistantAPI;
3794
3905
  };
3795
3906
  __name(ExtensionsInput, "ExtensionsInput");
3796
- _ts_decorate10([
3797
- (0, import_type_graphql11.Field)(() => OpenAIApiAssistantAPIInput, {
3907
+ _ts_decorate11([
3908
+ (0, import_type_graphql12.Field)(() => OpenAIApiAssistantAPIInput, {
3798
3909
  nullable: true
3799
3910
  }),
3800
- _ts_metadata10("design:type", typeof OpenAIApiAssistantAPIInput === "undefined" ? Object : OpenAIApiAssistantAPIInput)
3911
+ _ts_metadata11("design:type", typeof OpenAIApiAssistantAPIInput === "undefined" ? Object : OpenAIApiAssistantAPIInput)
3801
3912
  ], ExtensionsInput.prototype, "openaiAssistantAPI", void 0);
3802
- ExtensionsInput = _ts_decorate10([
3803
- (0, import_type_graphql11.InputType)()
3913
+ ExtensionsInput = _ts_decorate11([
3914
+ (0, import_type_graphql12.InputType)()
3804
3915
  ], ExtensionsInput);
3805
3916
  var OpenAIApiAssistantAPIInput = class {
3806
3917
  runId;
3807
3918
  threadId;
3808
3919
  };
3809
3920
  __name(OpenAIApiAssistantAPIInput, "OpenAIApiAssistantAPIInput");
3810
- _ts_decorate10([
3811
- (0, import_type_graphql11.Field)(() => String, {
3921
+ _ts_decorate11([
3922
+ (0, import_type_graphql12.Field)(() => String, {
3812
3923
  nullable: true
3813
3924
  }),
3814
- _ts_metadata10("design:type", String)
3925
+ _ts_metadata11("design:type", String)
3815
3926
  ], OpenAIApiAssistantAPIInput.prototype, "runId", void 0);
3816
- _ts_decorate10([
3817
- (0, import_type_graphql11.Field)(() => String, {
3927
+ _ts_decorate11([
3928
+ (0, import_type_graphql12.Field)(() => String, {
3818
3929
  nullable: true
3819
3930
  }),
3820
- _ts_metadata10("design:type", String)
3931
+ _ts_metadata11("design:type", String)
3821
3932
  ], OpenAIApiAssistantAPIInput.prototype, "threadId", void 0);
3822
- OpenAIApiAssistantAPIInput = _ts_decorate10([
3823
- (0, import_type_graphql11.InputType)()
3933
+ OpenAIApiAssistantAPIInput = _ts_decorate11([
3934
+ (0, import_type_graphql12.InputType)()
3824
3935
  ], OpenAIApiAssistantAPIInput);
3825
3936
 
3937
+ // src/graphql/inputs/meta-event.input.ts
3938
+ var import_type_graphql13 = require("type-graphql");
3939
+ function _ts_decorate12(decorators, target, key, desc) {
3940
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3941
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3942
+ r = Reflect.decorate(decorators, target, key, desc);
3943
+ else
3944
+ for (var i = decorators.length - 1; i >= 0; i--)
3945
+ if (d = decorators[i])
3946
+ r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3947
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
3948
+ }
3949
+ __name(_ts_decorate12, "_ts_decorate");
3950
+ function _ts_metadata12(k, v) {
3951
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3952
+ return Reflect.metadata(k, v);
3953
+ }
3954
+ __name(_ts_metadata12, "_ts_metadata");
3955
+ var MetaEventInput = class {
3956
+ type = "MetaEvent";
3957
+ name;
3958
+ value;
3959
+ response;
3960
+ };
3961
+ __name(MetaEventInput, "MetaEventInput");
3962
+ _ts_decorate12([
3963
+ (0, import_type_graphql13.Field)(() => String),
3964
+ _ts_metadata12("design:type", String)
3965
+ ], MetaEventInput.prototype, "type", void 0);
3966
+ _ts_decorate12([
3967
+ (0, import_type_graphql13.Field)(() => MetaEventName),
3968
+ _ts_metadata12("design:type", typeof MetaEventName === "undefined" ? Object : MetaEventName)
3969
+ ], MetaEventInput.prototype, "name", void 0);
3970
+ _ts_decorate12([
3971
+ (0, import_type_graphql13.Field)(() => String),
3972
+ _ts_metadata12("design:type", String)
3973
+ ], MetaEventInput.prototype, "value", void 0);
3974
+ _ts_decorate12([
3975
+ (0, import_type_graphql13.Field)(() => String, {
3976
+ nullable: true
3977
+ }),
3978
+ _ts_metadata12("design:type", String)
3979
+ ], MetaEventInput.prototype, "response", void 0);
3980
+ MetaEventInput = _ts_decorate12([
3981
+ (0, import_type_graphql13.InputType)()
3982
+ ], MetaEventInput);
3983
+
3826
3984
  // src/graphql/inputs/generate-copilot-response.input.ts
3827
- function _ts_decorate11(decorators, target, key, desc) {
3985
+ function _ts_decorate13(decorators, target, key, desc) {
3828
3986
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3829
3987
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3830
3988
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3834,24 +3992,24 @@ function _ts_decorate11(decorators, target, key, desc) {
3834
3992
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3835
3993
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3836
3994
  }
3837
- __name(_ts_decorate11, "_ts_decorate");
3838
- function _ts_metadata11(k, v) {
3995
+ __name(_ts_decorate13, "_ts_decorate");
3996
+ function _ts_metadata13(k, v) {
3839
3997
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3840
3998
  return Reflect.metadata(k, v);
3841
3999
  }
3842
- __name(_ts_metadata11, "_ts_metadata");
4000
+ __name(_ts_metadata13, "_ts_metadata");
3843
4001
  var GenerateCopilotResponseMetadataInput = class {
3844
4002
  requestType;
3845
4003
  };
3846
4004
  __name(GenerateCopilotResponseMetadataInput, "GenerateCopilotResponseMetadataInput");
3847
- _ts_decorate11([
3848
- (0, import_type_graphql12.Field)(() => CopilotRequestType, {
4005
+ _ts_decorate13([
4006
+ (0, import_type_graphql14.Field)(() => CopilotRequestType, {
3849
4007
  nullable: true
3850
4008
  }),
3851
- _ts_metadata11("design:type", typeof CopilotRequestType === "undefined" ? Object : CopilotRequestType)
4009
+ _ts_metadata13("design:type", typeof CopilotRequestType === "undefined" ? Object : CopilotRequestType)
3852
4010
  ], GenerateCopilotResponseMetadataInput.prototype, "requestType", void 0);
3853
- GenerateCopilotResponseMetadataInput = _ts_decorate11([
3854
- (0, import_type_graphql12.InputType)()
4011
+ GenerateCopilotResponseMetadataInput = _ts_decorate13([
4012
+ (0, import_type_graphql14.InputType)()
3855
4013
  ], GenerateCopilotResponseMetadataInput);
3856
4014
  var GenerateCopilotResponseInput = class {
3857
4015
  metadata;
@@ -3865,84 +4023,93 @@ var GenerateCopilotResponseInput = class {
3865
4023
  agentState;
3866
4024
  agentStates;
3867
4025
  extensions;
4026
+ metaEvents;
3868
4027
  };
3869
4028
  __name(GenerateCopilotResponseInput, "GenerateCopilotResponseInput");
3870
- _ts_decorate11([
3871
- (0, import_type_graphql12.Field)(() => GenerateCopilotResponseMetadataInput, {
4029
+ _ts_decorate13([
4030
+ (0, import_type_graphql14.Field)(() => GenerateCopilotResponseMetadataInput, {
3872
4031
  nullable: false
3873
4032
  }),
3874
- _ts_metadata11("design:type", typeof GenerateCopilotResponseMetadataInput === "undefined" ? Object : GenerateCopilotResponseMetadataInput)
4033
+ _ts_metadata13("design:type", typeof GenerateCopilotResponseMetadataInput === "undefined" ? Object : GenerateCopilotResponseMetadataInput)
3875
4034
  ], GenerateCopilotResponseInput.prototype, "metadata", void 0);
3876
- _ts_decorate11([
3877
- (0, import_type_graphql12.Field)(() => String, {
4035
+ _ts_decorate13([
4036
+ (0, import_type_graphql14.Field)(() => String, {
3878
4037
  nullable: true
3879
4038
  }),
3880
- _ts_metadata11("design:type", String)
4039
+ _ts_metadata13("design:type", String)
3881
4040
  ], GenerateCopilotResponseInput.prototype, "threadId", void 0);
3882
- _ts_decorate11([
3883
- (0, import_type_graphql12.Field)(() => String, {
4041
+ _ts_decorate13([
4042
+ (0, import_type_graphql14.Field)(() => String, {
3884
4043
  nullable: true
3885
4044
  }),
3886
- _ts_metadata11("design:type", String)
4045
+ _ts_metadata13("design:type", String)
3887
4046
  ], GenerateCopilotResponseInput.prototype, "runId", void 0);
3888
- _ts_decorate11([
3889
- (0, import_type_graphql12.Field)(() => [
4047
+ _ts_decorate13([
4048
+ (0, import_type_graphql14.Field)(() => [
3890
4049
  MessageInput
3891
4050
  ]),
3892
- _ts_metadata11("design:type", Array)
4051
+ _ts_metadata13("design:type", Array)
3893
4052
  ], GenerateCopilotResponseInput.prototype, "messages", void 0);
3894
- _ts_decorate11([
3895
- (0, import_type_graphql12.Field)(() => FrontendInput),
3896
- _ts_metadata11("design:type", typeof FrontendInput === "undefined" ? Object : FrontendInput)
4053
+ _ts_decorate13([
4054
+ (0, import_type_graphql14.Field)(() => FrontendInput),
4055
+ _ts_metadata13("design:type", typeof FrontendInput === "undefined" ? Object : FrontendInput)
3897
4056
  ], GenerateCopilotResponseInput.prototype, "frontend", void 0);
3898
- _ts_decorate11([
3899
- (0, import_type_graphql12.Field)(() => CloudInput, {
4057
+ _ts_decorate13([
4058
+ (0, import_type_graphql14.Field)(() => CloudInput, {
3900
4059
  nullable: true
3901
4060
  }),
3902
- _ts_metadata11("design:type", typeof CloudInput === "undefined" ? Object : CloudInput)
4061
+ _ts_metadata13("design:type", typeof CloudInput === "undefined" ? Object : CloudInput)
3903
4062
  ], GenerateCopilotResponseInput.prototype, "cloud", void 0);
3904
- _ts_decorate11([
3905
- (0, import_type_graphql12.Field)(() => ForwardedParametersInput, {
4063
+ _ts_decorate13([
4064
+ (0, import_type_graphql14.Field)(() => ForwardedParametersInput, {
3906
4065
  nullable: true
3907
4066
  }),
3908
- _ts_metadata11("design:type", typeof ForwardedParametersInput === "undefined" ? Object : ForwardedParametersInput)
4067
+ _ts_metadata13("design:type", typeof ForwardedParametersInput === "undefined" ? Object : ForwardedParametersInput)
3909
4068
  ], GenerateCopilotResponseInput.prototype, "forwardedParameters", void 0);
3910
- _ts_decorate11([
3911
- (0, import_type_graphql12.Field)(() => AgentSessionInput, {
4069
+ _ts_decorate13([
4070
+ (0, import_type_graphql14.Field)(() => AgentSessionInput, {
3912
4071
  nullable: true
3913
4072
  }),
3914
- _ts_metadata11("design:type", typeof AgentSessionInput === "undefined" ? Object : AgentSessionInput)
4073
+ _ts_metadata13("design:type", typeof AgentSessionInput === "undefined" ? Object : AgentSessionInput)
3915
4074
  ], GenerateCopilotResponseInput.prototype, "agentSession", void 0);
3916
- _ts_decorate11([
3917
- (0, import_type_graphql12.Field)(() => AgentStateInput, {
4075
+ _ts_decorate13([
4076
+ (0, import_type_graphql14.Field)(() => AgentStateInput, {
3918
4077
  nullable: true
3919
4078
  }),
3920
- _ts_metadata11("design:type", typeof AgentStateInput === "undefined" ? Object : AgentStateInput)
4079
+ _ts_metadata13("design:type", typeof AgentStateInput === "undefined" ? Object : AgentStateInput)
3921
4080
  ], GenerateCopilotResponseInput.prototype, "agentState", void 0);
3922
- _ts_decorate11([
3923
- (0, import_type_graphql12.Field)(() => [
4081
+ _ts_decorate13([
4082
+ (0, import_type_graphql14.Field)(() => [
3924
4083
  AgentStateInput
3925
4084
  ], {
3926
4085
  nullable: true
3927
4086
  }),
3928
- _ts_metadata11("design:type", Array)
4087
+ _ts_metadata13("design:type", Array)
3929
4088
  ], GenerateCopilotResponseInput.prototype, "agentStates", void 0);
3930
- _ts_decorate11([
3931
- (0, import_type_graphql12.Field)(() => ExtensionsInput, {
4089
+ _ts_decorate13([
4090
+ (0, import_type_graphql14.Field)(() => ExtensionsInput, {
3932
4091
  nullable: true
3933
4092
  }),
3934
- _ts_metadata11("design:type", typeof ExtensionsInput === "undefined" ? Object : ExtensionsInput)
4093
+ _ts_metadata13("design:type", typeof ExtensionsInput === "undefined" ? Object : ExtensionsInput)
3935
4094
  ], GenerateCopilotResponseInput.prototype, "extensions", void 0);
3936
- GenerateCopilotResponseInput = _ts_decorate11([
3937
- (0, import_type_graphql12.InputType)()
4095
+ _ts_decorate13([
4096
+ (0, import_type_graphql14.Field)(() => [
4097
+ MetaEventInput
4098
+ ], {
4099
+ nullable: true
4100
+ }),
4101
+ _ts_metadata13("design:type", Array)
4102
+ ], GenerateCopilotResponseInput.prototype, "metaEvents", void 0);
4103
+ GenerateCopilotResponseInput = _ts_decorate13([
4104
+ (0, import_type_graphql14.InputType)()
3938
4105
  ], GenerateCopilotResponseInput);
3939
4106
 
3940
4107
  // src/graphql/types/copilot-response.type.ts
3941
- var import_type_graphql16 = require("type-graphql");
4108
+ var import_type_graphql18 = require("type-graphql");
3942
4109
 
3943
4110
  // src/graphql/types/message-status.type.ts
3944
- var import_type_graphql13 = require("type-graphql");
3945
- function _ts_decorate12(decorators, target, key, desc) {
4111
+ var import_type_graphql15 = require("type-graphql");
4112
+ function _ts_decorate14(decorators, target, key, desc) {
3946
4113
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3947
4114
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
3948
4115
  r = Reflect.decorate(decorators, target, key, desc);
@@ -3952,58 +4119,58 @@ function _ts_decorate12(decorators, target, key, desc) {
3952
4119
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
3953
4120
  return c > 3 && r && Object.defineProperty(target, key, r), r;
3954
4121
  }
3955
- __name(_ts_decorate12, "_ts_decorate");
3956
- function _ts_metadata12(k, v) {
4122
+ __name(_ts_decorate14, "_ts_decorate");
4123
+ function _ts_metadata14(k, v) {
3957
4124
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
3958
4125
  return Reflect.metadata(k, v);
3959
4126
  }
3960
- __name(_ts_metadata12, "_ts_metadata");
4127
+ __name(_ts_metadata14, "_ts_metadata");
3961
4128
  var MessageStatusCode;
3962
4129
  (function(MessageStatusCode2) {
3963
4130
  MessageStatusCode2["Pending"] = "pending";
3964
4131
  MessageStatusCode2["Success"] = "success";
3965
4132
  MessageStatusCode2["Failed"] = "failed";
3966
4133
  })(MessageStatusCode || (MessageStatusCode = {}));
3967
- (0, import_type_graphql13.registerEnumType)(MessageStatusCode, {
4134
+ (0, import_type_graphql15.registerEnumType)(MessageStatusCode, {
3968
4135
  name: "MessageStatusCode"
3969
4136
  });
3970
4137
  var BaseMessageStatus = /* @__PURE__ */ __name(class BaseMessageStatus2 {
3971
4138
  code;
3972
4139
  }, "BaseMessageStatus");
3973
- _ts_decorate12([
3974
- (0, import_type_graphql13.Field)(() => MessageStatusCode),
3975
- _ts_metadata12("design:type", String)
4140
+ _ts_decorate14([
4141
+ (0, import_type_graphql15.Field)(() => MessageStatusCode),
4142
+ _ts_metadata14("design:type", String)
3976
4143
  ], BaseMessageStatus.prototype, "code", void 0);
3977
- BaseMessageStatus = _ts_decorate12([
3978
- (0, import_type_graphql13.ObjectType)()
4144
+ BaseMessageStatus = _ts_decorate14([
4145
+ (0, import_type_graphql15.ObjectType)()
3979
4146
  ], BaseMessageStatus);
3980
4147
  var PendingMessageStatus = class extends BaseMessageStatus {
3981
4148
  code = "pending";
3982
4149
  };
3983
4150
  __name(PendingMessageStatus, "PendingMessageStatus");
3984
- PendingMessageStatus = _ts_decorate12([
3985
- (0, import_type_graphql13.ObjectType)()
4151
+ PendingMessageStatus = _ts_decorate14([
4152
+ (0, import_type_graphql15.ObjectType)()
3986
4153
  ], PendingMessageStatus);
3987
4154
  var SuccessMessageStatus = class extends BaseMessageStatus {
3988
4155
  code = "success";
3989
4156
  };
3990
4157
  __name(SuccessMessageStatus, "SuccessMessageStatus");
3991
- SuccessMessageStatus = _ts_decorate12([
3992
- (0, import_type_graphql13.ObjectType)()
4158
+ SuccessMessageStatus = _ts_decorate14([
4159
+ (0, import_type_graphql15.ObjectType)()
3993
4160
  ], SuccessMessageStatus);
3994
4161
  var FailedMessageStatus = class extends BaseMessageStatus {
3995
4162
  code = "failed";
3996
4163
  reason;
3997
4164
  };
3998
4165
  __name(FailedMessageStatus, "FailedMessageStatus");
3999
- _ts_decorate12([
4000
- (0, import_type_graphql13.Field)(() => String),
4001
- _ts_metadata12("design:type", String)
4166
+ _ts_decorate14([
4167
+ (0, import_type_graphql15.Field)(() => String),
4168
+ _ts_metadata14("design:type", String)
4002
4169
  ], FailedMessageStatus.prototype, "reason", void 0);
4003
- FailedMessageStatus = _ts_decorate12([
4004
- (0, import_type_graphql13.ObjectType)()
4170
+ FailedMessageStatus = _ts_decorate14([
4171
+ (0, import_type_graphql15.ObjectType)()
4005
4172
  ], FailedMessageStatus);
4006
- var MessageStatusUnion = (0, import_type_graphql13.createUnionType)({
4173
+ var MessageStatusUnion = (0, import_type_graphql15.createUnionType)({
4007
4174
  name: "MessageStatus",
4008
4175
  types: () => [
4009
4176
  PendingMessageStatus,
@@ -4014,8 +4181,8 @@ var MessageStatusUnion = (0, import_type_graphql13.createUnionType)({
4014
4181
 
4015
4182
  // src/graphql/types/response-status.type.ts
4016
4183
  var import_graphql_scalars = require("graphql-scalars");
4017
- var import_type_graphql14 = require("type-graphql");
4018
- function _ts_decorate13(decorators, target, key, desc) {
4184
+ var import_type_graphql16 = require("type-graphql");
4185
+ function _ts_decorate15(decorators, target, key, desc) {
4019
4186
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4020
4187
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4021
4188
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4025,30 +4192,30 @@ function _ts_decorate13(decorators, target, key, desc) {
4025
4192
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4026
4193
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4027
4194
  }
4028
- __name(_ts_decorate13, "_ts_decorate");
4029
- function _ts_metadata13(k, v) {
4195
+ __name(_ts_decorate15, "_ts_decorate");
4196
+ function _ts_metadata15(k, v) {
4030
4197
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
4031
4198
  return Reflect.metadata(k, v);
4032
4199
  }
4033
- __name(_ts_metadata13, "_ts_metadata");
4200
+ __name(_ts_metadata15, "_ts_metadata");
4034
4201
  var ResponseStatusCode;
4035
4202
  (function(ResponseStatusCode2) {
4036
4203
  ResponseStatusCode2["Pending"] = "pending";
4037
4204
  ResponseStatusCode2["Success"] = "success";
4038
4205
  ResponseStatusCode2["Failed"] = "failed";
4039
4206
  })(ResponseStatusCode || (ResponseStatusCode = {}));
4040
- (0, import_type_graphql14.registerEnumType)(ResponseStatusCode, {
4207
+ (0, import_type_graphql16.registerEnumType)(ResponseStatusCode, {
4041
4208
  name: "ResponseStatusCode"
4042
4209
  });
4043
4210
  var BaseResponseStatus = /* @__PURE__ */ __name(class BaseResponseStatus2 {
4044
4211
  code;
4045
4212
  }, "BaseResponseStatus");
4046
- _ts_decorate13([
4047
- (0, import_type_graphql14.Field)(() => ResponseStatusCode),
4048
- _ts_metadata13("design:type", String)
4213
+ _ts_decorate15([
4214
+ (0, import_type_graphql16.Field)(() => ResponseStatusCode),
4215
+ _ts_metadata15("design:type", String)
4049
4216
  ], BaseResponseStatus.prototype, "code", void 0);
4050
- BaseResponseStatus = _ts_decorate13([
4051
- (0, import_type_graphql14.InterfaceType)({
4217
+ BaseResponseStatus = _ts_decorate15([
4218
+ (0, import_type_graphql16.InterfaceType)({
4052
4219
  resolveType(value) {
4053
4220
  if (value.code === "success") {
4054
4221
  return SuccessResponseStatus;
@@ -4060,14 +4227,14 @@ BaseResponseStatus = _ts_decorate13([
4060
4227
  return void 0;
4061
4228
  }
4062
4229
  }),
4063
- (0, import_type_graphql14.ObjectType)()
4230
+ (0, import_type_graphql16.ObjectType)()
4064
4231
  ], BaseResponseStatus);
4065
4232
  var PendingResponseStatus = class extends BaseResponseStatus {
4066
4233
  code = "pending";
4067
4234
  };
4068
4235
  __name(PendingResponseStatus, "PendingResponseStatus");
4069
- PendingResponseStatus = _ts_decorate13([
4070
- (0, import_type_graphql14.ObjectType)({
4236
+ PendingResponseStatus = _ts_decorate15([
4237
+ (0, import_type_graphql16.ObjectType)({
4071
4238
  implements: BaseResponseStatus
4072
4239
  })
4073
4240
  ], PendingResponseStatus);
@@ -4075,8 +4242,8 @@ var SuccessResponseStatus = class extends BaseResponseStatus {
4075
4242
  code = "success";
4076
4243
  };
4077
4244
  __name(SuccessResponseStatus, "SuccessResponseStatus");
4078
- SuccessResponseStatus = _ts_decorate13([
4079
- (0, import_type_graphql14.ObjectType)({
4245
+ SuccessResponseStatus = _ts_decorate15([
4246
+ (0, import_type_graphql16.ObjectType)({
4080
4247
  implements: BaseResponseStatus
4081
4248
  })
4082
4249
  ], SuccessResponseStatus);
@@ -4086,7 +4253,7 @@ var FailedResponseStatusReason;
4086
4253
  FailedResponseStatusReason2["MESSAGE_STREAM_INTERRUPTED"] = "MESSAGE_STREAM_INTERRUPTED";
4087
4254
  FailedResponseStatusReason2["UNKNOWN_ERROR"] = "UNKNOWN_ERROR";
4088
4255
  })(FailedResponseStatusReason || (FailedResponseStatusReason = {}));
4089
- (0, import_type_graphql14.registerEnumType)(FailedResponseStatusReason, {
4256
+ (0, import_type_graphql16.registerEnumType)(FailedResponseStatusReason, {
4090
4257
  name: "FailedResponseStatusReason"
4091
4258
  });
4092
4259
  var FailedResponseStatus = class extends BaseResponseStatus {
@@ -4095,22 +4262,22 @@ var FailedResponseStatus = class extends BaseResponseStatus {
4095
4262
  details = null;
4096
4263
  };
4097
4264
  __name(FailedResponseStatus, "FailedResponseStatus");
4098
- _ts_decorate13([
4099
- (0, import_type_graphql14.Field)(() => FailedResponseStatusReason),
4100
- _ts_metadata13("design:type", String)
4265
+ _ts_decorate15([
4266
+ (0, import_type_graphql16.Field)(() => FailedResponseStatusReason),
4267
+ _ts_metadata15("design:type", String)
4101
4268
  ], FailedResponseStatus.prototype, "reason", void 0);
4102
- _ts_decorate13([
4103
- (0, import_type_graphql14.Field)(() => import_graphql_scalars.GraphQLJSON, {
4269
+ _ts_decorate15([
4270
+ (0, import_type_graphql16.Field)(() => import_graphql_scalars.GraphQLJSON, {
4104
4271
  nullable: true
4105
4272
  }),
4106
- _ts_metadata13("design:type", typeof Record === "undefined" ? Object : Record)
4273
+ _ts_metadata15("design:type", typeof Record === "undefined" ? Object : Record)
4107
4274
  ], FailedResponseStatus.prototype, "details", void 0);
4108
- FailedResponseStatus = _ts_decorate13([
4109
- (0, import_type_graphql14.ObjectType)({
4275
+ FailedResponseStatus = _ts_decorate15([
4276
+ (0, import_type_graphql16.ObjectType)({
4110
4277
  implements: BaseResponseStatus
4111
4278
  })
4112
4279
  ], FailedResponseStatus);
4113
- var ResponseStatusUnion = (0, import_type_graphql14.createUnionType)({
4280
+ var ResponseStatusUnion = (0, import_type_graphql16.createUnionType)({
4114
4281
  name: "ResponseStatus",
4115
4282
  types: () => [
4116
4283
  PendingResponseStatus,
@@ -4120,8 +4287,8 @@ var ResponseStatusUnion = (0, import_type_graphql14.createUnionType)({
4120
4287
  });
4121
4288
 
4122
4289
  // src/graphql/types/extensions-response.type.ts
4123
- var import_type_graphql15 = require("type-graphql");
4124
- function _ts_decorate14(decorators, target, key, desc) {
4290
+ var import_type_graphql17 = require("type-graphql");
4291
+ function _ts_decorate16(decorators, target, key, desc) {
4125
4292
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4126
4293
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4127
4294
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4131,48 +4298,48 @@ function _ts_decorate14(decorators, target, key, desc) {
4131
4298
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4132
4299
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4133
4300
  }
4134
- __name(_ts_decorate14, "_ts_decorate");
4135
- function _ts_metadata14(k, v) {
4301
+ __name(_ts_decorate16, "_ts_decorate");
4302
+ function _ts_metadata16(k, v) {
4136
4303
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
4137
4304
  return Reflect.metadata(k, v);
4138
4305
  }
4139
- __name(_ts_metadata14, "_ts_metadata");
4306
+ __name(_ts_metadata16, "_ts_metadata");
4140
4307
  var ExtensionsResponse = class {
4141
4308
  openaiAssistantAPI;
4142
4309
  };
4143
4310
  __name(ExtensionsResponse, "ExtensionsResponse");
4144
- _ts_decorate14([
4145
- (0, import_type_graphql15.Field)(() => OpenAIApiAssistantAPIResponse, {
4311
+ _ts_decorate16([
4312
+ (0, import_type_graphql17.Field)(() => OpenAIApiAssistantAPIResponse, {
4146
4313
  nullable: true
4147
4314
  }),
4148
- _ts_metadata14("design:type", typeof OpenAIApiAssistantAPIResponse === "undefined" ? Object : OpenAIApiAssistantAPIResponse)
4315
+ _ts_metadata16("design:type", typeof OpenAIApiAssistantAPIResponse === "undefined" ? Object : OpenAIApiAssistantAPIResponse)
4149
4316
  ], ExtensionsResponse.prototype, "openaiAssistantAPI", void 0);
4150
- ExtensionsResponse = _ts_decorate14([
4151
- (0, import_type_graphql15.ObjectType)()
4317
+ ExtensionsResponse = _ts_decorate16([
4318
+ (0, import_type_graphql17.ObjectType)()
4152
4319
  ], ExtensionsResponse);
4153
4320
  var OpenAIApiAssistantAPIResponse = class {
4154
4321
  runId;
4155
4322
  threadId;
4156
4323
  };
4157
4324
  __name(OpenAIApiAssistantAPIResponse, "OpenAIApiAssistantAPIResponse");
4158
- _ts_decorate14([
4159
- (0, import_type_graphql15.Field)(() => String, {
4325
+ _ts_decorate16([
4326
+ (0, import_type_graphql17.Field)(() => String, {
4160
4327
  nullable: true
4161
4328
  }),
4162
- _ts_metadata14("design:type", String)
4329
+ _ts_metadata16("design:type", String)
4163
4330
  ], OpenAIApiAssistantAPIResponse.prototype, "runId", void 0);
4164
- _ts_decorate14([
4165
- (0, import_type_graphql15.Field)(() => String, {
4331
+ _ts_decorate16([
4332
+ (0, import_type_graphql17.Field)(() => String, {
4166
4333
  nullable: true
4167
4334
  }),
4168
- _ts_metadata14("design:type", String)
4335
+ _ts_metadata16("design:type", String)
4169
4336
  ], OpenAIApiAssistantAPIResponse.prototype, "threadId", void 0);
4170
- OpenAIApiAssistantAPIResponse = _ts_decorate14([
4171
- (0, import_type_graphql15.ObjectType)()
4337
+ OpenAIApiAssistantAPIResponse = _ts_decorate16([
4338
+ (0, import_type_graphql17.ObjectType)()
4172
4339
  ], OpenAIApiAssistantAPIResponse);
4173
4340
 
4174
4341
  // src/graphql/types/copilot-response.type.ts
4175
- function _ts_decorate15(decorators, target, key, desc) {
4342
+ function _ts_decorate17(decorators, target, key, desc) {
4176
4343
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4177
4344
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4178
4345
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4182,32 +4349,32 @@ function _ts_decorate15(decorators, target, key, desc) {
4182
4349
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4183
4350
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4184
4351
  }
4185
- __name(_ts_decorate15, "_ts_decorate");
4186
- function _ts_metadata15(k, v) {
4352
+ __name(_ts_decorate17, "_ts_decorate");
4353
+ function _ts_metadata17(k, v) {
4187
4354
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
4188
4355
  return Reflect.metadata(k, v);
4189
4356
  }
4190
- __name(_ts_metadata15, "_ts_metadata");
4357
+ __name(_ts_metadata17, "_ts_metadata");
4191
4358
  var BaseMessageOutput = class {
4192
4359
  id;
4193
4360
  createdAt;
4194
4361
  status;
4195
4362
  };
4196
4363
  __name(BaseMessageOutput, "BaseMessageOutput");
4197
- _ts_decorate15([
4198
- (0, import_type_graphql16.Field)(() => String),
4199
- _ts_metadata15("design:type", String)
4364
+ _ts_decorate17([
4365
+ (0, import_type_graphql18.Field)(() => String),
4366
+ _ts_metadata17("design:type", String)
4200
4367
  ], BaseMessageOutput.prototype, "id", void 0);
4201
- _ts_decorate15([
4202
- (0, import_type_graphql16.Field)(() => Date),
4203
- _ts_metadata15("design:type", typeof Date === "undefined" ? Object : Date)
4368
+ _ts_decorate17([
4369
+ (0, import_type_graphql18.Field)(() => Date),
4370
+ _ts_metadata17("design:type", typeof Date === "undefined" ? Object : Date)
4204
4371
  ], BaseMessageOutput.prototype, "createdAt", void 0);
4205
- _ts_decorate15([
4206
- (0, import_type_graphql16.Field)(() => MessageStatusUnion),
4207
- _ts_metadata15("design:type", Object)
4372
+ _ts_decorate17([
4373
+ (0, import_type_graphql18.Field)(() => MessageStatusUnion),
4374
+ _ts_metadata17("design:type", Object)
4208
4375
  ], BaseMessageOutput.prototype, "status", void 0);
4209
- BaseMessageOutput = _ts_decorate15([
4210
- (0, import_type_graphql16.InterfaceType)({
4376
+ BaseMessageOutput = _ts_decorate17([
4377
+ (0, import_type_graphql18.InterfaceType)({
4211
4378
  resolveType(value) {
4212
4379
  if (value.hasOwnProperty("content")) {
4213
4380
  return TextMessageOutput;
@@ -4217,6 +4384,8 @@ BaseMessageOutput = _ts_decorate15([
4217
4384
  return ResultMessageOutput;
4218
4385
  } else if (value.hasOwnProperty("state")) {
4219
4386
  return AgentStateMessageOutput;
4387
+ } else if (value.name === MetaEventName.LangGraphInterruptEvent) {
4388
+ return LangGraphInterruptEvent;
4220
4389
  }
4221
4390
  return void 0;
4222
4391
  }
@@ -4228,24 +4397,24 @@ var TextMessageOutput = class {
4228
4397
  parentMessageId;
4229
4398
  };
4230
4399
  __name(TextMessageOutput, "TextMessageOutput");
4231
- _ts_decorate15([
4232
- (0, import_type_graphql16.Field)(() => MessageRole),
4233
- _ts_metadata15("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
4400
+ _ts_decorate17([
4401
+ (0, import_type_graphql18.Field)(() => MessageRole),
4402
+ _ts_metadata17("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
4234
4403
  ], TextMessageOutput.prototype, "role", void 0);
4235
- _ts_decorate15([
4236
- (0, import_type_graphql16.Field)(() => [
4404
+ _ts_decorate17([
4405
+ (0, import_type_graphql18.Field)(() => [
4237
4406
  String
4238
4407
  ]),
4239
- _ts_metadata15("design:type", Array)
4408
+ _ts_metadata17("design:type", Array)
4240
4409
  ], TextMessageOutput.prototype, "content", void 0);
4241
- _ts_decorate15([
4242
- (0, import_type_graphql16.Field)(() => String, {
4410
+ _ts_decorate17([
4411
+ (0, import_type_graphql18.Field)(() => String, {
4243
4412
  nullable: true
4244
4413
  }),
4245
- _ts_metadata15("design:type", String)
4414
+ _ts_metadata17("design:type", String)
4246
4415
  ], TextMessageOutput.prototype, "parentMessageId", void 0);
4247
- TextMessageOutput = _ts_decorate15([
4248
- (0, import_type_graphql16.ObjectType)({
4416
+ TextMessageOutput = _ts_decorate17([
4417
+ (0, import_type_graphql18.ObjectType)({
4249
4418
  implements: BaseMessageOutput
4250
4419
  })
4251
4420
  ], TextMessageOutput);
@@ -4256,31 +4425,31 @@ var ActionExecutionMessageOutput = class {
4256
4425
  parentMessageId;
4257
4426
  };
4258
4427
  __name(ActionExecutionMessageOutput, "ActionExecutionMessageOutput");
4259
- _ts_decorate15([
4260
- (0, import_type_graphql16.Field)(() => String),
4261
- _ts_metadata15("design:type", String)
4428
+ _ts_decorate17([
4429
+ (0, import_type_graphql18.Field)(() => String),
4430
+ _ts_metadata17("design:type", String)
4262
4431
  ], ActionExecutionMessageOutput.prototype, "name", void 0);
4263
- _ts_decorate15([
4264
- (0, import_type_graphql16.Field)(() => String, {
4432
+ _ts_decorate17([
4433
+ (0, import_type_graphql18.Field)(() => String, {
4265
4434
  nullable: true,
4266
4435
  deprecationReason: "This field will be removed in a future version"
4267
4436
  }),
4268
- _ts_metadata15("design:type", String)
4437
+ _ts_metadata17("design:type", String)
4269
4438
  ], ActionExecutionMessageOutput.prototype, "scope", void 0);
4270
- _ts_decorate15([
4271
- (0, import_type_graphql16.Field)(() => [
4439
+ _ts_decorate17([
4440
+ (0, import_type_graphql18.Field)(() => [
4272
4441
  String
4273
4442
  ]),
4274
- _ts_metadata15("design:type", Array)
4443
+ _ts_metadata17("design:type", Array)
4275
4444
  ], ActionExecutionMessageOutput.prototype, "arguments", void 0);
4276
- _ts_decorate15([
4277
- (0, import_type_graphql16.Field)(() => String, {
4445
+ _ts_decorate17([
4446
+ (0, import_type_graphql18.Field)(() => String, {
4278
4447
  nullable: true
4279
4448
  }),
4280
- _ts_metadata15("design:type", String)
4449
+ _ts_metadata17("design:type", String)
4281
4450
  ], ActionExecutionMessageOutput.prototype, "parentMessageId", void 0);
4282
- ActionExecutionMessageOutput = _ts_decorate15([
4283
- (0, import_type_graphql16.ObjectType)({
4451
+ ActionExecutionMessageOutput = _ts_decorate17([
4452
+ (0, import_type_graphql18.ObjectType)({
4284
4453
  implements: BaseMessageOutput
4285
4454
  })
4286
4455
  ], ActionExecutionMessageOutput);
@@ -4290,20 +4459,20 @@ var ResultMessageOutput = class {
4290
4459
  result;
4291
4460
  };
4292
4461
  __name(ResultMessageOutput, "ResultMessageOutput");
4293
- _ts_decorate15([
4294
- (0, import_type_graphql16.Field)(() => String),
4295
- _ts_metadata15("design:type", String)
4462
+ _ts_decorate17([
4463
+ (0, import_type_graphql18.Field)(() => String),
4464
+ _ts_metadata17("design:type", String)
4296
4465
  ], ResultMessageOutput.prototype, "actionExecutionId", void 0);
4297
- _ts_decorate15([
4298
- (0, import_type_graphql16.Field)(() => String),
4299
- _ts_metadata15("design:type", String)
4466
+ _ts_decorate17([
4467
+ (0, import_type_graphql18.Field)(() => String),
4468
+ _ts_metadata17("design:type", String)
4300
4469
  ], ResultMessageOutput.prototype, "actionName", void 0);
4301
- _ts_decorate15([
4302
- (0, import_type_graphql16.Field)(() => String),
4303
- _ts_metadata15("design:type", String)
4470
+ _ts_decorate17([
4471
+ (0, import_type_graphql18.Field)(() => String),
4472
+ _ts_metadata17("design:type", String)
4304
4473
  ], ResultMessageOutput.prototype, "result", void 0);
4305
- ResultMessageOutput = _ts_decorate15([
4306
- (0, import_type_graphql16.ObjectType)({
4474
+ ResultMessageOutput = _ts_decorate17([
4475
+ (0, import_type_graphql18.ObjectType)({
4307
4476
  implements: BaseMessageOutput
4308
4477
  })
4309
4478
  ], ResultMessageOutput);
@@ -4318,40 +4487,40 @@ var AgentStateMessageOutput = class {
4318
4487
  running;
4319
4488
  };
4320
4489
  __name(AgentStateMessageOutput, "AgentStateMessageOutput");
4321
- _ts_decorate15([
4322
- (0, import_type_graphql16.Field)(() => String),
4323
- _ts_metadata15("design:type", String)
4490
+ _ts_decorate17([
4491
+ (0, import_type_graphql18.Field)(() => String),
4492
+ _ts_metadata17("design:type", String)
4324
4493
  ], AgentStateMessageOutput.prototype, "threadId", void 0);
4325
- _ts_decorate15([
4326
- (0, import_type_graphql16.Field)(() => String),
4327
- _ts_metadata15("design:type", String)
4494
+ _ts_decorate17([
4495
+ (0, import_type_graphql18.Field)(() => String),
4496
+ _ts_metadata17("design:type", String)
4328
4497
  ], AgentStateMessageOutput.prototype, "agentName", void 0);
4329
- _ts_decorate15([
4330
- (0, import_type_graphql16.Field)(() => String),
4331
- _ts_metadata15("design:type", String)
4498
+ _ts_decorate17([
4499
+ (0, import_type_graphql18.Field)(() => String),
4500
+ _ts_metadata17("design:type", String)
4332
4501
  ], AgentStateMessageOutput.prototype, "nodeName", void 0);
4333
- _ts_decorate15([
4334
- (0, import_type_graphql16.Field)(() => String),
4335
- _ts_metadata15("design:type", String)
4502
+ _ts_decorate17([
4503
+ (0, import_type_graphql18.Field)(() => String),
4504
+ _ts_metadata17("design:type", String)
4336
4505
  ], AgentStateMessageOutput.prototype, "runId", void 0);
4337
- _ts_decorate15([
4338
- (0, import_type_graphql16.Field)(() => Boolean),
4339
- _ts_metadata15("design:type", Boolean)
4506
+ _ts_decorate17([
4507
+ (0, import_type_graphql18.Field)(() => Boolean),
4508
+ _ts_metadata17("design:type", Boolean)
4340
4509
  ], AgentStateMessageOutput.prototype, "active", void 0);
4341
- _ts_decorate15([
4342
- (0, import_type_graphql16.Field)(() => MessageRole),
4343
- _ts_metadata15("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
4510
+ _ts_decorate17([
4511
+ (0, import_type_graphql18.Field)(() => MessageRole),
4512
+ _ts_metadata17("design:type", typeof MessageRole === "undefined" ? Object : MessageRole)
4344
4513
  ], AgentStateMessageOutput.prototype, "role", void 0);
4345
- _ts_decorate15([
4346
- (0, import_type_graphql16.Field)(() => String),
4347
- _ts_metadata15("design:type", String)
4514
+ _ts_decorate17([
4515
+ (0, import_type_graphql18.Field)(() => String),
4516
+ _ts_metadata17("design:type", String)
4348
4517
  ], AgentStateMessageOutput.prototype, "state", void 0);
4349
- _ts_decorate15([
4350
- (0, import_type_graphql16.Field)(() => Boolean),
4351
- _ts_metadata15("design:type", Boolean)
4518
+ _ts_decorate17([
4519
+ (0, import_type_graphql18.Field)(() => Boolean),
4520
+ _ts_metadata17("design:type", Boolean)
4352
4521
  ], AgentStateMessageOutput.prototype, "running", void 0);
4353
- AgentStateMessageOutput = _ts_decorate15([
4354
- (0, import_type_graphql16.ObjectType)({
4522
+ AgentStateMessageOutput = _ts_decorate17([
4523
+ (0, import_type_graphql18.ObjectType)({
4355
4524
  implements: BaseMessageOutput
4356
4525
  })
4357
4526
  ], AgentStateMessageOutput);
@@ -4361,36 +4530,45 @@ var CopilotResponse = class {
4361
4530
  runId;
4362
4531
  messages;
4363
4532
  extensions;
4533
+ metaEvents;
4364
4534
  };
4365
4535
  __name(CopilotResponse, "CopilotResponse");
4366
- _ts_decorate15([
4367
- (0, import_type_graphql16.Field)(() => String),
4368
- _ts_metadata15("design:type", String)
4536
+ _ts_decorate17([
4537
+ (0, import_type_graphql18.Field)(() => String),
4538
+ _ts_metadata17("design:type", String)
4369
4539
  ], CopilotResponse.prototype, "threadId", void 0);
4370
- _ts_decorate15([
4371
- (0, import_type_graphql16.Field)(() => ResponseStatusUnion),
4372
- _ts_metadata15("design:type", Object)
4540
+ _ts_decorate17([
4541
+ (0, import_type_graphql18.Field)(() => ResponseStatusUnion),
4542
+ _ts_metadata17("design:type", Object)
4373
4543
  ], CopilotResponse.prototype, "status", void 0);
4374
- _ts_decorate15([
4375
- (0, import_type_graphql16.Field)({
4544
+ _ts_decorate17([
4545
+ (0, import_type_graphql18.Field)({
4376
4546
  nullable: true
4377
4547
  }),
4378
- _ts_metadata15("design:type", String)
4548
+ _ts_metadata17("design:type", String)
4379
4549
  ], CopilotResponse.prototype, "runId", void 0);
4380
- _ts_decorate15([
4381
- (0, import_type_graphql16.Field)(() => [
4550
+ _ts_decorate17([
4551
+ (0, import_type_graphql18.Field)(() => [
4382
4552
  BaseMessageOutput
4383
4553
  ]),
4384
- _ts_metadata15("design:type", Array)
4554
+ _ts_metadata17("design:type", Array)
4385
4555
  ], CopilotResponse.prototype, "messages", void 0);
4386
- _ts_decorate15([
4387
- (0, import_type_graphql16.Field)(() => ExtensionsResponse, {
4556
+ _ts_decorate17([
4557
+ (0, import_type_graphql18.Field)(() => ExtensionsResponse, {
4388
4558
  nullable: true
4389
4559
  }),
4390
- _ts_metadata15("design:type", typeof ExtensionsResponse === "undefined" ? Object : ExtensionsResponse)
4560
+ _ts_metadata17("design:type", typeof ExtensionsResponse === "undefined" ? Object : ExtensionsResponse)
4391
4561
  ], CopilotResponse.prototype, "extensions", void 0);
4392
- CopilotResponse = _ts_decorate15([
4393
- (0, import_type_graphql16.ObjectType)()
4562
+ _ts_decorate17([
4563
+ (0, import_type_graphql18.Field)(() => [
4564
+ BaseMetaEvent
4565
+ ], {
4566
+ nullable: true
4567
+ }),
4568
+ _ts_metadata17("design:type", Array)
4569
+ ], CopilotResponse.prototype, "metaEvents", void 0);
4570
+ CopilotResponse = _ts_decorate17([
4571
+ (0, import_type_graphql18.ObjectType)()
4394
4572
  ], CopilotResponse);
4395
4573
 
4396
4574
  // src/graphql/resolvers/copilot.resolver.ts
@@ -4436,8 +4614,8 @@ __name(UnknownErrorResponse, "UnknownErrorResponse");
4436
4614
  var import_shared14 = require("@copilotkit/shared");
4437
4615
 
4438
4616
  // src/graphql/types/agents-response.type.ts
4439
- var import_type_graphql17 = require("type-graphql");
4440
- function _ts_decorate16(decorators, target, key, desc) {
4617
+ var import_type_graphql19 = require("type-graphql");
4618
+ function _ts_decorate18(decorators, target, key, desc) {
4441
4619
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4442
4620
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4443
4621
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4447,49 +4625,49 @@ function _ts_decorate16(decorators, target, key, desc) {
4447
4625
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4448
4626
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4449
4627
  }
4450
- __name(_ts_decorate16, "_ts_decorate");
4451
- function _ts_metadata16(k, v) {
4628
+ __name(_ts_decorate18, "_ts_decorate");
4629
+ function _ts_metadata18(k, v) {
4452
4630
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
4453
4631
  return Reflect.metadata(k, v);
4454
4632
  }
4455
- __name(_ts_metadata16, "_ts_metadata");
4633
+ __name(_ts_metadata18, "_ts_metadata");
4456
4634
  var Agent = class {
4457
4635
  id;
4458
4636
  name;
4459
4637
  description;
4460
4638
  };
4461
4639
  __name(Agent, "Agent");
4462
- _ts_decorate16([
4463
- (0, import_type_graphql17.Field)(() => String),
4464
- _ts_metadata16("design:type", String)
4640
+ _ts_decorate18([
4641
+ (0, import_type_graphql19.Field)(() => String),
4642
+ _ts_metadata18("design:type", String)
4465
4643
  ], Agent.prototype, "id", void 0);
4466
- _ts_decorate16([
4467
- (0, import_type_graphql17.Field)(() => String),
4468
- _ts_metadata16("design:type", String)
4644
+ _ts_decorate18([
4645
+ (0, import_type_graphql19.Field)(() => String),
4646
+ _ts_metadata18("design:type", String)
4469
4647
  ], Agent.prototype, "name", void 0);
4470
- _ts_decorate16([
4471
- (0, import_type_graphql17.Field)(() => String),
4472
- _ts_metadata16("design:type", String)
4648
+ _ts_decorate18([
4649
+ (0, import_type_graphql19.Field)(() => String),
4650
+ _ts_metadata18("design:type", String)
4473
4651
  ], Agent.prototype, "description", void 0);
4474
- Agent = _ts_decorate16([
4475
- (0, import_type_graphql17.ObjectType)()
4652
+ Agent = _ts_decorate18([
4653
+ (0, import_type_graphql19.ObjectType)()
4476
4654
  ], Agent);
4477
4655
  var AgentsResponse = class {
4478
4656
  agents;
4479
4657
  };
4480
4658
  __name(AgentsResponse, "AgentsResponse");
4481
- _ts_decorate16([
4482
- (0, import_type_graphql17.Field)(() => [
4659
+ _ts_decorate18([
4660
+ (0, import_type_graphql19.Field)(() => [
4483
4661
  Agent
4484
4662
  ]),
4485
- _ts_metadata16("design:type", Array)
4663
+ _ts_metadata18("design:type", Array)
4486
4664
  ], AgentsResponse.prototype, "agents", void 0);
4487
- AgentsResponse = _ts_decorate16([
4488
- (0, import_type_graphql17.ObjectType)()
4665
+ AgentsResponse = _ts_decorate18([
4666
+ (0, import_type_graphql19.ObjectType)()
4489
4667
  ], AgentsResponse);
4490
4668
 
4491
4669
  // src/graphql/resolvers/copilot.resolver.ts
4492
- function _ts_decorate17(decorators, target, key, desc) {
4670
+ function _ts_decorate19(decorators, target, key, desc) {
4493
4671
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4494
4672
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4495
4673
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4499,12 +4677,12 @@ function _ts_decorate17(decorators, target, key, desc) {
4499
4677
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4500
4678
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4501
4679
  }
4502
- __name(_ts_decorate17, "_ts_decorate");
4503
- function _ts_metadata17(k, v) {
4680
+ __name(_ts_decorate19, "_ts_decorate");
4681
+ function _ts_metadata19(k, v) {
4504
4682
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
4505
4683
  return Reflect.metadata(k, v);
4506
4684
  }
4507
- __name(_ts_metadata17, "_ts_metadata");
4685
+ __name(_ts_metadata19, "_ts_metadata");
4508
4686
  function _ts_param(paramIndex, decorator) {
4509
4687
  return function(target, key) {
4510
4688
  decorator(target, key, paramIndex);
@@ -4558,7 +4736,7 @@ var CopilotResolver = class {
4558
4736
  };
4559
4737
  }
4560
4738
  async generateCopilotResponse(ctx, data, properties) {
4561
- var _a, _b, _c;
4739
+ var _a, _b, _c, _d;
4562
4740
  telemetry_client_default.capture("oss.runtime.copilot_request_created", {
4563
4741
  "cloud.guardrails.enabled": ((_a = data.cloud) == null ? void 0 : _a.guardrails) !== void 0,
4564
4742
  requestType: data.metadata.requestType
@@ -4629,16 +4807,68 @@ var CopilotResolver = class {
4629
4807
  agentSession: data.agentSession,
4630
4808
  agentStates: data.agentStates,
4631
4809
  url: data.frontend.url,
4632
- extensions: data.extensions
4810
+ extensions: data.extensions,
4811
+ metaEvents: data.metaEvents
4633
4812
  });
4634
4813
  logger2.debug("Event source created, creating response");
4814
+ const eventStream = eventSource.processRuntimeEvents({
4815
+ serverSideActions,
4816
+ guardrailsResult$: ((_d = data.cloud) == null ? void 0 : _d.guardrails) ? guardrailsResult$ : null,
4817
+ actionInputsWithoutAgents: actionInputsWithoutAgents.filter(
4818
+ // TODO-AGENTS: do not exclude ALL server side actions
4819
+ (action) => !serverSideActions.find((serverSideAction) => serverSideAction.name == action.name)
4820
+ ),
4821
+ threadId
4822
+ }).pipe(
4823
+ // shareReplay() ensures that later subscribers will see the whole stream instead of
4824
+ // just the events that were emitted after the subscriber was added.
4825
+ (0, import_rxjs4.shareReplay)(),
4826
+ (0, import_rxjs4.finalize)(() => {
4827
+ logger2.debug("Event stream finalized");
4828
+ })
4829
+ );
4635
4830
  const response = {
4636
4831
  threadId,
4637
4832
  runId,
4638
4833
  status: (0, import_rxjs4.firstValueFrom)(responseStatus$),
4639
4834
  extensions,
4835
+ metaEvents: new import_graphql_yoga.Repeater(async (push, stop) => {
4836
+ let eventStreamSubscription;
4837
+ eventStreamSubscription = eventStream.subscribe({
4838
+ next: async (event) => {
4839
+ if (event.type != RuntimeEventTypes.MetaEvent) {
4840
+ return;
4841
+ }
4842
+ switch (event.name) {
4843
+ case RuntimeMetaEventName.LangGraphInterruptEvent:
4844
+ push((0, import_class_transformer3.plainToInstance)(LangGraphInterruptEvent, {
4845
+ type: event.type,
4846
+ name: event.name,
4847
+ value: event.value
4848
+ }));
4849
+ break;
4850
+ }
4851
+ },
4852
+ error: (err) => {
4853
+ logger2.error({
4854
+ err
4855
+ }, "Error in meta events stream");
4856
+ responseStatus$.next(new UnknownErrorResponse({
4857
+ description: `An unknown error has occurred in the event stream`
4858
+ }));
4859
+ eventStreamSubscription == null ? void 0 : eventStreamSubscription.unsubscribe();
4860
+ stop();
4861
+ },
4862
+ complete: async () => {
4863
+ logger2.debug("Meta events stream completed");
4864
+ responseStatus$.next(new SuccessResponseStatus());
4865
+ eventStreamSubscription == null ? void 0 : eventStreamSubscription.unsubscribe();
4866
+ stop();
4867
+ }
4868
+ });
4869
+ }),
4640
4870
  messages: new import_graphql_yoga.Repeater(async (pushMessage, stopStreamingMessages) => {
4641
- var _a2, _b2;
4871
+ var _a2;
4642
4872
  logger2.debug("Messages repeater created");
4643
4873
  if ((_a2 = data.cloud) == null ? void 0 : _a2.guardrails) {
4644
4874
  logger2 = logger2.child({
@@ -4687,26 +4917,12 @@ var CopilotResolver = class {
4687
4917
  });
4688
4918
  }
4689
4919
  let eventStreamSubscription;
4690
- const eventStream = eventSource.processRuntimeEvents({
4691
- serverSideActions,
4692
- guardrailsResult$: ((_b2 = data.cloud) == null ? void 0 : _b2.guardrails) ? guardrailsResult$ : null,
4693
- actionInputsWithoutAgents: actionInputsWithoutAgents.filter(
4694
- // TODO-AGENTS: do not exclude ALL server side actions
4695
- (action) => !serverSideActions.find((serverSideAction) => serverSideAction.name == action.name)
4696
- ),
4697
- threadId
4698
- }).pipe(
4699
- // shareReplay() ensures that later subscribers will see the whole stream instead of
4700
- // just the events that were emitted after the subscriber was added.
4701
- (0, import_rxjs4.shareReplay)(),
4702
- (0, import_rxjs4.finalize)(() => {
4703
- logger2.debug("Event stream finalized");
4704
- })
4705
- );
4706
4920
  logger2.debug("Event stream created, subscribing to event stream");
4707
4921
  eventStreamSubscription = eventStream.subscribe({
4708
4922
  next: async (event) => {
4709
4923
  switch (event.type) {
4924
+ case RuntimeEventTypes.MetaEvent:
4925
+ break;
4710
4926
  case RuntimeEventTypes.TextMessageStart:
4711
4927
  const textMessageContentStream = eventStream.pipe(
4712
4928
  // skip until this message start event
@@ -4912,38 +5128,38 @@ var CopilotResolver = class {
4912
5128
  }
4913
5129
  };
4914
5130
  __name(CopilotResolver, "CopilotResolver");
4915
- _ts_decorate17([
4916
- (0, import_type_graphql18.Query)(() => String),
4917
- _ts_metadata17("design:type", Function),
4918
- _ts_metadata17("design:paramtypes", []),
4919
- _ts_metadata17("design:returntype", Promise)
5131
+ _ts_decorate19([
5132
+ (0, import_type_graphql20.Query)(() => String),
5133
+ _ts_metadata19("design:type", Function),
5134
+ _ts_metadata19("design:paramtypes", []),
5135
+ _ts_metadata19("design:returntype", Promise)
4920
5136
  ], CopilotResolver.prototype, "hello", null);
4921
- _ts_decorate17([
4922
- (0, import_type_graphql18.Query)(() => AgentsResponse),
4923
- _ts_param(0, (0, import_type_graphql18.Ctx)()),
4924
- _ts_metadata17("design:type", Function),
4925
- _ts_metadata17("design:paramtypes", [
5137
+ _ts_decorate19([
5138
+ (0, import_type_graphql20.Query)(() => AgentsResponse),
5139
+ _ts_param(0, (0, import_type_graphql20.Ctx)()),
5140
+ _ts_metadata19("design:type", Function),
5141
+ _ts_metadata19("design:paramtypes", [
4926
5142
  typeof GraphQLContext === "undefined" ? Object : GraphQLContext
4927
5143
  ]),
4928
- _ts_metadata17("design:returntype", Promise)
5144
+ _ts_metadata19("design:returntype", Promise)
4929
5145
  ], CopilotResolver.prototype, "availableAgents", null);
4930
- _ts_decorate17([
4931
- (0, import_type_graphql18.Mutation)(() => CopilotResponse),
4932
- _ts_param(0, (0, import_type_graphql18.Ctx)()),
4933
- _ts_param(1, (0, import_type_graphql18.Arg)("data")),
4934
- _ts_param(2, (0, import_type_graphql18.Arg)("properties", () => import_graphql_scalars2.GraphQLJSONObject, {
5146
+ _ts_decorate19([
5147
+ (0, import_type_graphql20.Mutation)(() => CopilotResponse),
5148
+ _ts_param(0, (0, import_type_graphql20.Ctx)()),
5149
+ _ts_param(1, (0, import_type_graphql20.Arg)("data")),
5150
+ _ts_param(2, (0, import_type_graphql20.Arg)("properties", () => import_graphql_scalars2.GraphQLJSONObject, {
4935
5151
  nullable: true
4936
5152
  })),
4937
- _ts_metadata17("design:type", Function),
4938
- _ts_metadata17("design:paramtypes", [
5153
+ _ts_metadata19("design:type", Function),
5154
+ _ts_metadata19("design:paramtypes", [
4939
5155
  typeof GraphQLContext === "undefined" ? Object : GraphQLContext,
4940
5156
  typeof GenerateCopilotResponseInput === "undefined" ? Object : GenerateCopilotResponseInput,
4941
5157
  typeof CopilotRequestContextProperties === "undefined" ? Object : CopilotRequestContextProperties
4942
5158
  ]),
4943
- _ts_metadata17("design:returntype", Promise)
5159
+ _ts_metadata19("design:returntype", Promise)
4944
5160
  ], CopilotResolver.prototype, "generateCopilotResponse", null);
4945
- CopilotResolver = _ts_decorate17([
4946
- (0, import_type_graphql18.Resolver)(() => CopilotResponse)
5161
+ CopilotResolver = _ts_decorate19([
5162
+ (0, import_type_graphql20.Resolver)(() => CopilotResponse)
4947
5163
  ], CopilotResolver);
4948
5164
 
4949
5165
  // src/lib/integrations/shared.ts
@@ -4978,13 +5194,13 @@ function createLogger(options) {
4978
5194
  __name(createLogger, "createLogger");
4979
5195
 
4980
5196
  // src/graphql/resolvers/state.resolver.ts
4981
- var import_type_graphql21 = require("type-graphql");
4982
- var import_type_graphql22 = require("type-graphql");
4983
5197
  var import_type_graphql23 = require("type-graphql");
5198
+ var import_type_graphql24 = require("type-graphql");
5199
+ var import_type_graphql25 = require("type-graphql");
4984
5200
 
4985
5201
  // src/graphql/types/load-agent-state-response.type.ts
4986
- var import_type_graphql19 = require("type-graphql");
4987
- function _ts_decorate18(decorators, target, key, desc) {
5202
+ var import_type_graphql21 = require("type-graphql");
5203
+ function _ts_decorate20(decorators, target, key, desc) {
4988
5204
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
4989
5205
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
4990
5206
  r = Reflect.decorate(decorators, target, key, desc);
@@ -4994,12 +5210,12 @@ function _ts_decorate18(decorators, target, key, desc) {
4994
5210
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
4995
5211
  return c > 3 && r && Object.defineProperty(target, key, r), r;
4996
5212
  }
4997
- __name(_ts_decorate18, "_ts_decorate");
4998
- function _ts_metadata18(k, v) {
5213
+ __name(_ts_decorate20, "_ts_decorate");
5214
+ function _ts_metadata20(k, v) {
4999
5215
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
5000
5216
  return Reflect.metadata(k, v);
5001
5217
  }
5002
- __name(_ts_metadata18, "_ts_metadata");
5218
+ __name(_ts_metadata20, "_ts_metadata");
5003
5219
  var LoadAgentStateResponse = class {
5004
5220
  threadId;
5005
5221
  threadExists;
@@ -5007,29 +5223,29 @@ var LoadAgentStateResponse = class {
5007
5223
  messages;
5008
5224
  };
5009
5225
  __name(LoadAgentStateResponse, "LoadAgentStateResponse");
5010
- _ts_decorate18([
5011
- (0, import_type_graphql19.Field)(() => String),
5012
- _ts_metadata18("design:type", String)
5226
+ _ts_decorate20([
5227
+ (0, import_type_graphql21.Field)(() => String),
5228
+ _ts_metadata20("design:type", String)
5013
5229
  ], LoadAgentStateResponse.prototype, "threadId", void 0);
5014
- _ts_decorate18([
5015
- (0, import_type_graphql19.Field)(() => Boolean),
5016
- _ts_metadata18("design:type", Boolean)
5230
+ _ts_decorate20([
5231
+ (0, import_type_graphql21.Field)(() => Boolean),
5232
+ _ts_metadata20("design:type", Boolean)
5017
5233
  ], LoadAgentStateResponse.prototype, "threadExists", void 0);
5018
- _ts_decorate18([
5019
- (0, import_type_graphql19.Field)(() => String),
5020
- _ts_metadata18("design:type", String)
5234
+ _ts_decorate20([
5235
+ (0, import_type_graphql21.Field)(() => String),
5236
+ _ts_metadata20("design:type", String)
5021
5237
  ], LoadAgentStateResponse.prototype, "state", void 0);
5022
- _ts_decorate18([
5023
- (0, import_type_graphql19.Field)(() => String),
5024
- _ts_metadata18("design:type", String)
5238
+ _ts_decorate20([
5239
+ (0, import_type_graphql21.Field)(() => String),
5240
+ _ts_metadata20("design:type", String)
5025
5241
  ], LoadAgentStateResponse.prototype, "messages", void 0);
5026
- LoadAgentStateResponse = _ts_decorate18([
5027
- (0, import_type_graphql19.ObjectType)()
5242
+ LoadAgentStateResponse = _ts_decorate20([
5243
+ (0, import_type_graphql21.ObjectType)()
5028
5244
  ], LoadAgentStateResponse);
5029
5245
 
5030
5246
  // src/graphql/inputs/load-agent-state.input.ts
5031
- var import_type_graphql20 = require("type-graphql");
5032
- function _ts_decorate19(decorators, target, key, desc) {
5247
+ var import_type_graphql22 = require("type-graphql");
5248
+ function _ts_decorate21(decorators, target, key, desc) {
5033
5249
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5034
5250
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
5035
5251
  r = Reflect.decorate(decorators, target, key, desc);
@@ -5039,31 +5255,31 @@ function _ts_decorate19(decorators, target, key, desc) {
5039
5255
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5040
5256
  return c > 3 && r && Object.defineProperty(target, key, r), r;
5041
5257
  }
5042
- __name(_ts_decorate19, "_ts_decorate");
5043
- function _ts_metadata19(k, v) {
5258
+ __name(_ts_decorate21, "_ts_decorate");
5259
+ function _ts_metadata21(k, v) {
5044
5260
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
5045
5261
  return Reflect.metadata(k, v);
5046
5262
  }
5047
- __name(_ts_metadata19, "_ts_metadata");
5263
+ __name(_ts_metadata21, "_ts_metadata");
5048
5264
  var LoadAgentStateInput = class {
5049
5265
  threadId;
5050
5266
  agentName;
5051
5267
  };
5052
5268
  __name(LoadAgentStateInput, "LoadAgentStateInput");
5053
- _ts_decorate19([
5054
- (0, import_type_graphql20.Field)(() => String),
5055
- _ts_metadata19("design:type", String)
5269
+ _ts_decorate21([
5270
+ (0, import_type_graphql22.Field)(() => String),
5271
+ _ts_metadata21("design:type", String)
5056
5272
  ], LoadAgentStateInput.prototype, "threadId", void 0);
5057
- _ts_decorate19([
5058
- (0, import_type_graphql20.Field)(() => String),
5059
- _ts_metadata19("design:type", String)
5273
+ _ts_decorate21([
5274
+ (0, import_type_graphql22.Field)(() => String),
5275
+ _ts_metadata21("design:type", String)
5060
5276
  ], LoadAgentStateInput.prototype, "agentName", void 0);
5061
- LoadAgentStateInput = _ts_decorate19([
5062
- (0, import_type_graphql20.InputType)()
5277
+ LoadAgentStateInput = _ts_decorate21([
5278
+ (0, import_type_graphql22.InputType)()
5063
5279
  ], LoadAgentStateInput);
5064
5280
 
5065
5281
  // src/graphql/resolvers/state.resolver.ts
5066
- function _ts_decorate20(decorators, target, key, desc) {
5282
+ function _ts_decorate22(decorators, target, key, desc) {
5067
5283
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
5068
5284
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function")
5069
5285
  r = Reflect.decorate(decorators, target, key, desc);
@@ -5073,12 +5289,12 @@ function _ts_decorate20(decorators, target, key, desc) {
5073
5289
  r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5074
5290
  return c > 3 && r && Object.defineProperty(target, key, r), r;
5075
5291
  }
5076
- __name(_ts_decorate20, "_ts_decorate");
5077
- function _ts_metadata20(k, v) {
5292
+ __name(_ts_decorate22, "_ts_decorate");
5293
+ function _ts_metadata22(k, v) {
5078
5294
  if (typeof Reflect === "object" && typeof Reflect.metadata === "function")
5079
5295
  return Reflect.metadata(k, v);
5080
5296
  }
5081
- __name(_ts_metadata20, "_ts_metadata");
5297
+ __name(_ts_metadata22, "_ts_metadata");
5082
5298
  function _ts_param2(paramIndex, decorator) {
5083
5299
  return function(target, key) {
5084
5300
  decorator(target, key, paramIndex);
@@ -5097,19 +5313,19 @@ var StateResolver = class {
5097
5313
  }
5098
5314
  };
5099
5315
  __name(StateResolver, "StateResolver");
5100
- _ts_decorate20([
5101
- (0, import_type_graphql23.Query)(() => LoadAgentStateResponse),
5102
- _ts_param2(0, (0, import_type_graphql22.Ctx)()),
5103
- _ts_param2(1, (0, import_type_graphql21.Arg)("data")),
5104
- _ts_metadata20("design:type", Function),
5105
- _ts_metadata20("design:paramtypes", [
5316
+ _ts_decorate22([
5317
+ (0, import_type_graphql25.Query)(() => LoadAgentStateResponse),
5318
+ _ts_param2(0, (0, import_type_graphql24.Ctx)()),
5319
+ _ts_param2(1, (0, import_type_graphql23.Arg)("data")),
5320
+ _ts_metadata22("design:type", Function),
5321
+ _ts_metadata22("design:paramtypes", [
5106
5322
  typeof GraphQLContext === "undefined" ? Object : GraphQLContext,
5107
5323
  typeof LoadAgentStateInput === "undefined" ? Object : LoadAgentStateInput
5108
5324
  ]),
5109
- _ts_metadata20("design:returntype", Promise)
5325
+ _ts_metadata22("design:returntype", Promise)
5110
5326
  ], StateResolver.prototype, "loadAgentState", null);
5111
- StateResolver = _ts_decorate20([
5112
- (0, import_type_graphql21.Resolver)(() => LoadAgentStateResponse)
5327
+ StateResolver = _ts_decorate22([
5328
+ (0, import_type_graphql23.Resolver)(() => LoadAgentStateResponse)
5113
5329
  ], StateResolver);
5114
5330
 
5115
5331
  // src/lib/integrations/shared.ts
@@ -5133,7 +5349,7 @@ async function createContext(initialContext, copilotKitContext, contextLogger, p
5133
5349
  __name(createContext, "createContext");
5134
5350
  function buildSchema(options = {}) {
5135
5351
  logger.debug("Building GraphQL schema...");
5136
- const schema = (0, import_type_graphql24.buildSchemaSync)({
5352
+ const schema = (0, import_type_graphql26.buildSchemaSync)({
5137
5353
  resolvers: [
5138
5354
  CopilotResolver,
5139
5355
  StateResolver