@copilotkit/runtime 1.8.5-next.0 → 1.8.5-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 +13 -0
- package/dist/{chunk-ZAWWOAJA.mjs → chunk-7VNWCLG4.mjs} +2 -2
- package/dist/{chunk-6IREOCWG.mjs → chunk-A4MGCX6X.mjs} +14 -3
- package/dist/chunk-A4MGCX6X.mjs.map +1 -0
- package/dist/{chunk-KVSFR2VO.mjs → chunk-A7E5UM7B.mjs} +2 -2
- package/dist/{chunk-JAIFEOWJ.mjs → chunk-PJX3FQOX.mjs} +2 -2
- package/dist/index.js +13 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -4
- package/dist/lib/index.js +13 -2
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/index.mjs +4 -4
- package/dist/lib/integrations/index.js +1 -1
- package/dist/lib/integrations/index.js.map +1 -1
- package/dist/lib/integrations/index.mjs +4 -4
- 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 +2 -2
- 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 +2 -2
- 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 +1 -1
- package/package.json +2 -2
- package/src/lib/runtime/remote-lg-action.ts +12 -1
- package/dist/chunk-6IREOCWG.mjs.map +0 -1
- /package/dist/{chunk-ZAWWOAJA.mjs.map → chunk-7VNWCLG4.mjs.map} +0 -0
- /package/dist/{chunk-KVSFR2VO.mjs.map → chunk-A7E5UM7B.mjs.map} +0 -0
- /package/dist/{chunk-JAIFEOWJ.mjs.map → chunk-PJX3FQOX.mjs.map} +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# @copilotkit/runtime
|
|
2
2
|
|
|
3
|
+
## 1.8.5-next.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- @copilotkit/shared@1.8.5-next.2
|
|
8
|
+
|
|
9
|
+
## 1.8.5-next.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- d0e8a1e: - fix: fix duplicate messages on regenerate
|
|
14
|
+
- @copilotkit/shared@1.8.5-next.1
|
|
15
|
+
|
|
3
16
|
## 1.8.5-next.0
|
|
4
17
|
|
|
5
18
|
### Patch Changes
|
|
@@ -2,7 +2,7 @@ import {
|
|
|
2
2
|
copilotRuntimeNodeHttpEndpoint,
|
|
3
3
|
getRuntimeInstanceTelemetryInfo,
|
|
4
4
|
telemetry_client_default
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-A4MGCX6X.mjs";
|
|
6
6
|
import {
|
|
7
7
|
__name
|
|
8
8
|
} from "./chunk-FHD4JECV.mjs";
|
|
@@ -22,4 +22,4 @@ __name(copilotRuntimeNestEndpoint, "copilotRuntimeNestEndpoint");
|
|
|
22
22
|
export {
|
|
23
23
|
copilotRuntimeNestEndpoint
|
|
24
24
|
};
|
|
25
|
-
//# sourceMappingURL=chunk-
|
|
25
|
+
//# sourceMappingURL=chunk-7VNWCLG4.mjs.map
|
|
@@ -39,7 +39,7 @@ var require_package = __commonJS({
|
|
|
39
39
|
publishConfig: {
|
|
40
40
|
access: "public"
|
|
41
41
|
},
|
|
42
|
-
version: "1.8.5-next.
|
|
42
|
+
version: "1.8.5-next.2",
|
|
43
43
|
sideEffects: false,
|
|
44
44
|
main: "./dist/index.js",
|
|
45
45
|
module: "./dist/index.mjs",
|
|
@@ -1688,6 +1688,7 @@ import { createHash } from "crypto";
|
|
|
1688
1688
|
import { isValidUUID, randomUUID } from "@copilotkit/shared";
|
|
1689
1689
|
import { parse as parsePartialJson } from "partial-json";
|
|
1690
1690
|
import { parseJson } from "@copilotkit/shared";
|
|
1691
|
+
import { RemoveMessage } from "@langchain/core/messages";
|
|
1691
1692
|
var activeInterruptEvent = false;
|
|
1692
1693
|
async function execute(args) {
|
|
1693
1694
|
return new ReadableStream({
|
|
@@ -2070,10 +2071,20 @@ function langGraphDefaultMergeState(state, messages, actions, agentName) {
|
|
|
2070
2071
|
}
|
|
2071
2072
|
const existingMessages = state.messages || [];
|
|
2072
2073
|
const existingMessageIds = new Set(existingMessages.map((message) => message.id));
|
|
2074
|
+
const messageIds = new Set(messages.map((message) => message.id));
|
|
2075
|
+
let removedMessages = [];
|
|
2076
|
+
if (messages.length < existingMessages.length) {
|
|
2077
|
+
removedMessages = existingMessages.filter((m) => !messageIds.has(m.id)).map((m) => new RemoveMessage({
|
|
2078
|
+
id: m.id
|
|
2079
|
+
}));
|
|
2080
|
+
}
|
|
2073
2081
|
const newMessages = messages.filter((message) => !existingMessageIds.has(message.id));
|
|
2074
2082
|
return {
|
|
2075
2083
|
...state,
|
|
2076
|
-
messages:
|
|
2084
|
+
messages: [
|
|
2085
|
+
...removedMessages,
|
|
2086
|
+
...newMessages
|
|
2087
|
+
],
|
|
2077
2088
|
copilotkit: {
|
|
2078
2089
|
actions
|
|
2079
2090
|
}
|
|
@@ -4591,4 +4602,4 @@ export {
|
|
|
4591
4602
|
getCommonConfig,
|
|
4592
4603
|
copilotRuntimeNodeHttpEndpoint
|
|
4593
4604
|
};
|
|
4594
|
-
//# sourceMappingURL=chunk-
|
|
4605
|
+
//# sourceMappingURL=chunk-A4MGCX6X.mjs.map
|