@copilotkit/runtime 1.10.6-next.4 → 1.10.6-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.
- package/CHANGELOG.md +8 -0
- package/dist/{chunk-F7IANE7Z.mjs → chunk-27JKTS6P.mjs} +8 -2
- package/dist/chunk-27JKTS6P.mjs.map +1 -0
- package/dist/{chunk-RA6S32TD.mjs → chunk-6V4Z6IB4.mjs} +2 -2
- package/dist/{chunk-LPILCDAF.mjs → chunk-A7TXER2E.mjs} +2 -2
- package/dist/{chunk-MESW37CD.mjs → chunk-EVYK3FHD.mjs} +2 -2
- package/dist/{chunk-K3NXT234.mjs → chunk-FKLQWEI2.mjs} +9 -7
- package/dist/chunk-FKLQWEI2.mjs.map +1 -0
- package/dist/{chunk-IDGTM3MH.mjs → chunk-LLDZKRZZ.mjs} +2 -2
- package/dist/index.js +14 -6
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +6 -6
- package/dist/lib/index.js +14 -6
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/index.mjs +6 -6
- package/dist/lib/integrations/index.js +1 -1
- package/dist/lib/integrations/index.js.map +1 -1
- package/dist/lib/integrations/index.mjs +5 -5
- package/dist/lib/integrations/nest/index.js +1 -1
- package/dist/lib/integrations/nest/index.js.map +1 -1
- package/dist/lib/integrations/nest/index.mjs +3 -3
- package/dist/lib/integrations/node-express/index.js +1 -1
- package/dist/lib/integrations/node-express/index.js.map +1 -1
- package/dist/lib/integrations/node-express/index.mjs +3 -3
- package/dist/lib/integrations/node-http/index.js +1 -1
- package/dist/lib/integrations/node-http/index.js.map +1 -1
- package/dist/lib/integrations/node-http/index.mjs +2 -2
- package/dist/service-adapters/index.js +7 -1
- package/dist/service-adapters/index.js.map +1 -1
- package/dist/service-adapters/index.mjs +1 -1
- package/package.json +2 -2
- package/src/lib/runtime/agui-action.ts +8 -4
- package/src/lib/runtime/copilot-runtime.ts +2 -1
- package/src/lib/runtime/remote-actions.ts +2 -8
- package/src/service-adapters/events.ts +1 -0
- package/src/service-adapters/langchain/utils.ts +8 -1
- package/dist/chunk-F7IANE7Z.mjs.map +0 -1
- package/dist/chunk-K3NXT234.mjs.map +0 -1
- /package/dist/{chunk-RA6S32TD.mjs.map → chunk-6V4Z6IB4.mjs.map} +0 -0
- /package/dist/{chunk-LPILCDAF.mjs.map → chunk-A7TXER2E.mjs.map} +0 -0
- /package/dist/{chunk-MESW37CD.mjs.map → chunk-EVYK3FHD.mjs.map} +0 -0
- /package/dist/{chunk-IDGTM3MH.mjs.map → chunk-LLDZKRZZ.mjs.map} +0 -0
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
getCommonConfig,
|
|
3
3
|
getRuntimeInstanceTelemetryInfo,
|
|
4
4
|
telemetry_client_default
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-FKLQWEI2.mjs";
|
|
6
6
|
import {
|
|
7
7
|
__name
|
|
8
8
|
} from "./chunk-FHD4JECV.mjs";
|
|
@@ -77,4 +77,4 @@ export {
|
|
|
77
77
|
config,
|
|
78
78
|
copilotRuntimeNextJSPagesRouterEndpoint
|
|
79
79
|
};
|
|
80
|
-
//# sourceMappingURL=chunk-
|
|
80
|
+
//# sourceMappingURL=chunk-LLDZKRZZ.mjs.map
|
package/dist/index.js
CHANGED
|
@@ -44,7 +44,7 @@ var require_package = __commonJS({
|
|
|
44
44
|
publishConfig: {
|
|
45
45
|
access: "public"
|
|
46
46
|
},
|
|
47
|
-
version: "1.10.6-next.
|
|
47
|
+
version: "1.10.6-next.5",
|
|
48
48
|
sideEffects: false,
|
|
49
49
|
main: "./dist/index.js",
|
|
50
50
|
module: "./dist/index.mjs",
|
|
@@ -594,6 +594,7 @@ function convertMessageToLangChainMessage(message) {
|
|
|
594
594
|
__name(convertMessageToLangChainMessage, "convertMessageToLangChainMessage");
|
|
595
595
|
function convertActionInputToLangChainTool(actionInput) {
|
|
596
596
|
return new import_tools.DynamicStructuredTool({
|
|
597
|
+
...actionInput,
|
|
597
598
|
name: actionInput.name,
|
|
598
599
|
description: actionInput.description,
|
|
599
600
|
schema: (0, import_shared5.convertJsonSchemaToZodSchema)(JSON.parse(actionInput.jsonSchema), true),
|
|
@@ -628,7 +629,12 @@ __name(maybeSendActionExecutionResultIsMessage, "maybeSendActionExecutionResultI
|
|
|
628
629
|
async function streamLangChainResponse({ result, eventStream$, actionExecution }) {
|
|
629
630
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l;
|
|
630
631
|
if (typeof result === "string") {
|
|
631
|
-
if (!actionExecution) {
|
|
632
|
+
if (!actionExecution || (actionExecution == null ? void 0 : actionExecution.returnDirect)) {
|
|
633
|
+
eventStream$.sendActionExecutionResult({
|
|
634
|
+
actionExecutionId: actionExecution.id,
|
|
635
|
+
actionName: actionExecution.name,
|
|
636
|
+
result
|
|
637
|
+
});
|
|
632
638
|
eventStream$.sendTextMessage((0, import_shared5.randomId)(), result);
|
|
633
639
|
} else {
|
|
634
640
|
eventStream$.sendActionExecutionResult({
|
|
@@ -5038,7 +5044,8 @@ please use an LLM adapter instead.`
|
|
|
5038
5044
|
const serverSideActionsInput = serverSideActions.map((action) => ({
|
|
5039
5045
|
name: action.name,
|
|
5040
5046
|
description: action.description,
|
|
5041
|
-
jsonSchema: JSON.stringify((0, import_shared18.actionParametersToJsonSchema)(action.parameters))
|
|
5047
|
+
jsonSchema: JSON.stringify((0, import_shared18.actionParametersToJsonSchema)(action.parameters)),
|
|
5048
|
+
additionalConfig: action.additionalConfig
|
|
5042
5049
|
}));
|
|
5043
5050
|
const actionInputs = flattenToolCallsNoDuplicates([
|
|
5044
5051
|
...serverSideActionsInput,
|
|
@@ -6472,7 +6479,7 @@ function constructAGUIRemoteAction({ logger: logger2, messages, agentStates, age
|
|
|
6472
6479
|
name: agent.agentId,
|
|
6473
6480
|
description: agent.description,
|
|
6474
6481
|
parameters: [],
|
|
6475
|
-
handler: async (
|
|
6482
|
+
handler: async () => {
|
|
6476
6483
|
},
|
|
6477
6484
|
remoteAgentHandler: async ({ actionInputsWithoutAgents, threadId }) => {
|
|
6478
6485
|
var _a;
|
|
@@ -6949,7 +6956,7 @@ var RuntimeEventSource = class {
|
|
|
6949
6956
|
};
|
|
6950
6957
|
__name(RuntimeEventSource, "RuntimeEventSource");
|
|
6951
6958
|
async function executeAction(eventStream$, guardrailsResult$, action, actionArguments, actionExecutionParentMessageId, actionExecutionId, actionInputsWithoutAgents, threadId) {
|
|
6952
|
-
var _a;
|
|
6959
|
+
var _a, _b;
|
|
6953
6960
|
if (guardrailsResult$) {
|
|
6954
6961
|
const { status } = await (0, import_rxjs4.firstValueFrom)(guardrailsResult$);
|
|
6955
6962
|
if (status === "denied") {
|
|
@@ -7030,7 +7037,8 @@ async function executeAction(eventStream$, guardrailsResult$, action, actionArgu
|
|
|
7030
7037
|
eventStream$,
|
|
7031
7038
|
actionExecution: {
|
|
7032
7039
|
name: action.name,
|
|
7033
|
-
id: actionExecutionId
|
|
7040
|
+
id: actionExecutionId,
|
|
7041
|
+
returnDirect: (_b = action.additionalConfig) == null ? void 0 : _b.returnDirect
|
|
7034
7042
|
}
|
|
7035
7043
|
});
|
|
7036
7044
|
} catch (e) {
|