@copilotkit/runtime 1.5.18-next.0 → 1.5.18-next.2
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 +15 -0
- package/dist/{chunk-ODCQ3OFD.mjs → chunk-6LFPAZDL.mjs} +79 -28
- package/dist/chunk-6LFPAZDL.mjs.map +1 -0
- package/dist/{chunk-26Q5XHVQ.mjs → chunk-BMKRXGMW.mjs} +2 -2
- package/dist/{chunk-EQFWYZKN.mjs → chunk-BNJW4KHS.mjs} +2 -2
- package/dist/{chunk-QGFYSFTM.mjs → chunk-KZ3RUNSQ.mjs} +2 -2
- package/dist/index.js +98 -47
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -4
- package/dist/lib/index.js +98 -47
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/index.mjs +4 -4
- package/dist/lib/integrations/index.js +7 -2
- package/dist/lib/integrations/index.js.map +1 -1
- package/dist/lib/integrations/index.mjs +4 -4
- package/dist/lib/integrations/nest/index.js +7 -2
- package/dist/lib/integrations/nest/index.js.map +1 -1
- package/dist/lib/integrations/nest/index.mjs +2 -2
- package/dist/lib/integrations/node-express/index.js +7 -2
- package/dist/lib/integrations/node-express/index.js.map +1 -1
- package/dist/lib/integrations/node-express/index.mjs +2 -2
- package/dist/lib/integrations/node-http/index.js +7 -2
- package/dist/lib/integrations/node-http/index.js.map +1 -1
- package/dist/lib/integrations/node-http/index.mjs +1 -1
- package/package.json +2 -2
- package/src/graphql/resolvers/state.resolver.ts +6 -1
- package/src/lib/runtime/copilot-runtime.ts +35 -15
- package/src/lib/runtime/remote-action-constructors.ts +17 -2
- package/src/lib/runtime/remote-actions.ts +5 -1
- package/src/lib/runtime/remote-lg-action.ts +1 -1
- package/dist/chunk-ODCQ3OFD.mjs.map +0 -1
- /package/dist/{chunk-26Q5XHVQ.mjs.map → chunk-BMKRXGMW.mjs.map} +0 -0
- /package/dist/{chunk-EQFWYZKN.mjs.map → chunk-BNJW4KHS.mjs.map} +0 -0
- /package/dist/{chunk-QGFYSFTM.mjs.map → chunk-KZ3RUNSQ.mjs.map} +0 -0
package/dist/lib/index.mjs
CHANGED
|
@@ -3,13 +3,13 @@ import {
|
|
|
3
3
|
config,
|
|
4
4
|
copilotRuntimeNextJSAppRouterEndpoint,
|
|
5
5
|
copilotRuntimeNextJSPagesRouterEndpoint
|
|
6
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-KZ3RUNSQ.mjs";
|
|
7
7
|
import {
|
|
8
8
|
copilotRuntimeNestEndpoint
|
|
9
|
-
} from "../chunk-
|
|
9
|
+
} from "../chunk-BMKRXGMW.mjs";
|
|
10
10
|
import {
|
|
11
11
|
copilotRuntimeNodeExpressEndpoint
|
|
12
|
-
} from "../chunk-
|
|
12
|
+
} from "../chunk-BNJW4KHS.mjs";
|
|
13
13
|
import {
|
|
14
14
|
CopilotRuntime,
|
|
15
15
|
addCustomHeaderPlugin,
|
|
@@ -21,7 +21,7 @@ import {
|
|
|
21
21
|
getCommonConfig,
|
|
22
22
|
langGraphPlatformEndpoint,
|
|
23
23
|
resolveEndpointType
|
|
24
|
-
} from "../chunk-
|
|
24
|
+
} from "../chunk-6LFPAZDL.mjs";
|
|
25
25
|
import {
|
|
26
26
|
GoogleGenerativeAIAdapter,
|
|
27
27
|
GroqAdapter,
|
|
@@ -44,7 +44,7 @@ var require_package = __commonJS({
|
|
|
44
44
|
publishConfig: {
|
|
45
45
|
access: "public"
|
|
46
46
|
},
|
|
47
|
-
version: "1.5.18-next.
|
|
47
|
+
version: "1.5.18-next.2",
|
|
48
48
|
sideEffects: false,
|
|
49
49
|
main: "./dist/index.js",
|
|
50
50
|
module: "./dist/index.mjs",
|
|
@@ -2539,7 +2539,12 @@ var StateResolver = class {
|
|
|
2539
2539
|
const agents = await ctx._copilotkit.runtime.discoverAgentsFromEndpoints(ctx);
|
|
2540
2540
|
const agent = agents.find((agent2) => agent2.name === data.agentName);
|
|
2541
2541
|
if (!agent) {
|
|
2542
|
-
|
|
2542
|
+
return {
|
|
2543
|
+
threadId: data.threadId || "",
|
|
2544
|
+
threadExists: false,
|
|
2545
|
+
state: JSON.stringify({}),
|
|
2546
|
+
messages: JSON.stringify([])
|
|
2547
|
+
};
|
|
2543
2548
|
}
|
|
2544
2549
|
const state = await ctx._copilotkit.runtime.loadAgentState(ctx, data.threadId, data.agentName);
|
|
2545
2550
|
return state;
|