@copilotkit/react-core 1.9.3 → 1.10.0-next.1
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 +36 -0
- package/dist/chunk-2IDV5OHF.mjs +11 -0
- package/dist/chunk-2IDV5OHF.mjs.map +1 -0
- package/dist/{chunk-36MGCCPZ.mjs → chunk-4CFY3CON.mjs} +2 -2
- package/dist/{chunk-SP4LFJSS.mjs → chunk-4XVBXDCX.mjs} +2 -2
- package/dist/chunk-4XVBXDCX.mjs.map +1 -0
- package/dist/{chunk-BVK7PLK6.mjs → chunk-DF4YG4PF.mjs} +2 -2
- package/dist/{chunk-CUAFWKTQ.mjs → chunk-JZQOCH4A.mjs} +2 -2
- package/dist/{chunk-MEAIJ7V2.mjs → chunk-KV25ZRMH.mjs} +3 -3
- package/dist/{chunk-5BSUSFHM.mjs → chunk-LNAQ7JG3.mjs} +2 -2
- package/dist/{chunk-FN3UA2ZE.mjs → chunk-NXCJELW7.mjs} +3 -3
- package/dist/{chunk-GIMSRCVW.mjs → chunk-OMVNJ7S3.mjs} +149 -10
- package/dist/chunk-OMVNJ7S3.mjs.map +1 -0
- package/dist/{chunk-BSAVFYRQ.mjs → chunk-PYULBXCD.mjs} +2 -2
- package/dist/{chunk-VDADWRS3.mjs → chunk-Q6FZZJ5A.mjs} +2 -2
- package/dist/{chunk-KIXKBJUV.mjs → chunk-RGKZCCPA.mjs} +2 -2
- package/dist/{chunk-H56XI6TM.mjs → chunk-VM7CVIET.mjs} +3 -3
- package/dist/chunk-VM7CVIET.mjs.map +1 -0
- package/dist/{chunk-UBPKEQ7Z.mjs → chunk-VOMGRGWT.mjs} +94 -22
- package/dist/chunk-VOMGRGWT.mjs.map +1 -0
- package/dist/{chunk-NJA5ZLAZ.mjs → chunk-WUORFPJ7.mjs} +2 -2
- package/dist/chunk-WUORFPJ7.mjs.map +1 -0
- package/dist/{chunk-DKZTPL66.mjs → chunk-XGRBCWK6.mjs} +5 -2
- package/dist/chunk-XGRBCWK6.mjs.map +1 -0
- package/dist/components/copilot-provider/copilot-messages.js +4 -1
- package/dist/components/copilot-provider/copilot-messages.js.map +1 -1
- package/dist/components/copilot-provider/copilot-messages.mjs +2 -2
- package/dist/components/copilot-provider/copilotkit-props.d.ts +2 -1
- package/dist/components/copilot-provider/copilotkit.d.ts +2 -1
- package/dist/components/copilot-provider/copilotkit.js +8 -2
- package/dist/components/copilot-provider/copilotkit.js.map +1 -1
- package/dist/components/copilot-provider/copilotkit.mjs +4 -3
- package/dist/components/copilot-provider/index.d.ts +2 -1
- package/dist/components/copilot-provider/index.js +8 -2
- package/dist/components/copilot-provider/index.js.map +1 -1
- package/dist/components/copilot-provider/index.mjs +4 -3
- package/dist/components/index.d.ts +2 -1
- package/dist/components/index.js +8 -2
- package/dist/components/index.js.map +1 -1
- package/dist/components/index.mjs +4 -3
- package/dist/context/copilot-context.d.ts +2 -1
- package/dist/context/copilot-context.js +4 -1
- package/dist/context/copilot-context.js.map +1 -1
- package/dist/context/copilot-context.mjs +1 -1
- package/dist/context/index.d.ts +1 -1
- package/dist/context/index.js +4 -1
- package/dist/context/index.js.map +1 -1
- package/dist/context/index.mjs +1 -1
- package/dist/{copilot-context-3ab4fdf5.d.ts → copilot-context-bd88d30d.d.ts} +21 -1
- package/dist/hooks/index.d.ts +5 -5
- package/dist/hooks/index.js +492 -153
- package/dist/hooks/index.js.map +1 -1
- package/dist/hooks/index.mjs +17 -16
- package/dist/hooks/use-chat.d.ts +6 -1
- package/dist/hooks/use-chat.js +4 -1
- package/dist/hooks/use-chat.js.map +1 -1
- package/dist/hooks/use-chat.mjs +2 -2
- package/dist/hooks/use-coagent-state-render.js +4 -1
- package/dist/hooks/use-coagent-state-render.js.map +1 -1
- package/dist/hooks/use-coagent-state-render.mjs +2 -2
- package/dist/hooks/use-coagent.d.ts +4 -4
- package/dist/hooks/use-coagent.js +426 -44
- package/dist/hooks/use-coagent.js.map +1 -1
- package/dist/hooks/use-coagent.mjs +8 -6
- package/dist/hooks/use-copilot-action.d.ts +1 -1
- package/dist/hooks/use-copilot-action.js +4 -1
- package/dist/hooks/use-copilot-action.js.map +1 -1
- package/dist/hooks/use-copilot-action.mjs +2 -2
- package/dist/hooks/use-copilot-additional-instructions.js +4 -1
- package/dist/hooks/use-copilot-additional-instructions.js.map +1 -1
- package/dist/hooks/use-copilot-additional-instructions.mjs +2 -2
- package/dist/hooks/use-copilot-authenticated-action.js +4 -1
- package/dist/hooks/use-copilot-authenticated-action.js.map +1 -1
- package/dist/hooks/use-copilot-authenticated-action.mjs +3 -3
- package/dist/hooks/use-copilot-chat.d.ts +43 -6
- package/dist/hooks/use-copilot-chat.js +442 -64
- package/dist/hooks/use-copilot-chat.js.map +1 -1
- package/dist/hooks/use-copilot-chat.mjs +7 -5
- package/dist/hooks/use-copilot-readable.js +4 -1
- package/dist/hooks/use-copilot-readable.js.map +1 -1
- package/dist/hooks/use-copilot-readable.mjs +2 -2
- package/dist/hooks/use-langgraph-interrupt-render.js +4 -1
- package/dist/hooks/use-langgraph-interrupt-render.js.map +1 -1
- package/dist/hooks/use-langgraph-interrupt-render.mjs +2 -2
- package/dist/hooks/use-langgraph-interrupt.d.ts +4 -3
- package/dist/hooks/use-langgraph-interrupt.js +451 -71
- package/dist/hooks/use-langgraph-interrupt.js.map +1 -1
- package/dist/hooks/use-langgraph-interrupt.mjs +8 -6
- package/dist/hooks/use-make-copilot-document-readable.js +4 -1
- package/dist/hooks/use-make-copilot-document-readable.js.map +1 -1
- package/dist/hooks/use-make-copilot-document-readable.mjs +2 -2
- package/dist/index.d.ts +2 -1
- package/dist/index.js +421 -200
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +24 -18
- package/dist/lib/copilot-task.d.ts +2 -1
- package/dist/lib/copilot-task.js.map +1 -1
- package/dist/lib/copilot-task.mjs +5 -4
- package/dist/lib/index.d.ts +2 -1
- package/dist/lib/index.js.map +1 -1
- package/dist/lib/index.mjs +5 -4
- package/dist/types/interrupt-action.d.ts +3 -2
- package/dist/utils/extract.d.ts +1 -1
- package/dist/utils/extract.js.map +1 -1
- package/dist/utils/extract.mjs +4 -3
- package/dist/utils/index.d.ts +4 -3
- package/dist/utils/index.js +144 -0
- package/dist/utils/index.js.map +1 -1
- package/dist/utils/index.mjs +10 -4
- package/dist/utils/suggestions-constants.d.ts +9 -0
- package/dist/utils/suggestions-constants.js +35 -0
- package/dist/utils/suggestions-constants.js.map +1 -0
- package/dist/utils/suggestions-constants.mjs +8 -0
- package/dist/utils/suggestions-constants.mjs.map +1 -0
- package/dist/utils/suggestions.d.ts +11 -0
- package/dist/utils/suggestions.js +343 -0
- package/dist/utils/suggestions.js.map +1 -0
- package/dist/utils/suggestions.mjs +22 -0
- package/dist/utils/suggestions.mjs.map +1 -0
- package/package.json +3 -3
- package/src/components/copilot-provider/copilotkit.tsx +4 -0
- package/src/context/copilot-context.tsx +6 -0
- package/src/hooks/use-chat.ts +4 -0
- package/src/hooks/use-coagent.ts +2 -2
- package/src/hooks/use-copilot-action.ts +1 -1
- package/src/hooks/use-copilot-chat.ts +197 -21
- package/src/utils/index.ts +3 -0
- package/src/utils/suggestions-constants.ts +8 -0
- package/src/utils/suggestions.ts +208 -0
- package/dist/chunk-DKZTPL66.mjs.map +0 -1
- package/dist/chunk-GIMSRCVW.mjs.map +0 -1
- package/dist/chunk-H56XI6TM.mjs.map +0 -1
- package/dist/chunk-NJA5ZLAZ.mjs.map +0 -1
- package/dist/chunk-SP4LFJSS.mjs.map +0 -1
- package/dist/chunk-UBPKEQ7Z.mjs.map +0 -1
- /package/dist/{chunk-36MGCCPZ.mjs.map → chunk-4CFY3CON.mjs.map} +0 -0
- /package/dist/{chunk-BVK7PLK6.mjs.map → chunk-DF4YG4PF.mjs.map} +0 -0
- /package/dist/{chunk-CUAFWKTQ.mjs.map → chunk-JZQOCH4A.mjs.map} +0 -0
- /package/dist/{chunk-MEAIJ7V2.mjs.map → chunk-KV25ZRMH.mjs.map} +0 -0
- /package/dist/{chunk-5BSUSFHM.mjs.map → chunk-LNAQ7JG3.mjs.map} +0 -0
- /package/dist/{chunk-FN3UA2ZE.mjs.map → chunk-NXCJELW7.mjs.map} +0 -0
- /package/dist/{chunk-BSAVFYRQ.mjs.map → chunk-PYULBXCD.mjs.map} +0 -0
- /package/dist/{chunk-VDADWRS3.mjs.map → chunk-Q6FZZJ5A.mjs.map} +0 -0
- /package/dist/{chunk-KIXKBJUV.mjs.map → chunk-RGKZCCPA.mjs.map} +0 -0
package/dist/hooks/index.mjs
CHANGED
|
@@ -1,42 +1,43 @@
|
|
|
1
1
|
import "../chunk-CQPYJIBH.mjs";
|
|
2
|
-
import {
|
|
3
|
-
useLangGraphInterruptRender
|
|
4
|
-
} from "../chunk-VDADWRS3.mjs";
|
|
5
2
|
import {
|
|
6
3
|
useLangGraphInterrupt
|
|
7
|
-
} from "../chunk-
|
|
4
|
+
} from "../chunk-KV25ZRMH.mjs";
|
|
8
5
|
import {
|
|
9
6
|
useMakeCopilotDocumentReadable
|
|
10
|
-
} from "../chunk-
|
|
7
|
+
} from "../chunk-4CFY3CON.mjs";
|
|
11
8
|
import {
|
|
12
9
|
useCoAgentStateRender
|
|
13
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-RGKZCCPA.mjs";
|
|
14
11
|
import {
|
|
15
12
|
runAgent,
|
|
16
13
|
startAgent,
|
|
17
14
|
stopAgent,
|
|
18
15
|
useCoAgent
|
|
19
|
-
} from "../chunk-
|
|
16
|
+
} from "../chunk-VM7CVIET.mjs";
|
|
20
17
|
import {
|
|
21
18
|
useCopilotAdditionalInstructions
|
|
22
|
-
} from "../chunk-
|
|
19
|
+
} from "../chunk-DF4YG4PF.mjs";
|
|
23
20
|
import {
|
|
24
21
|
useCopilotAuthenticatedAction_c
|
|
25
|
-
} from "../chunk-
|
|
22
|
+
} from "../chunk-NXCJELW7.mjs";
|
|
26
23
|
import {
|
|
27
24
|
useCopilotAction
|
|
28
|
-
} from "../chunk-
|
|
25
|
+
} from "../chunk-WUORFPJ7.mjs";
|
|
29
26
|
import {
|
|
30
27
|
useCopilotChat
|
|
31
|
-
} from "../chunk-
|
|
32
|
-
import
|
|
28
|
+
} from "../chunk-VOMGRGWT.mjs";
|
|
29
|
+
import {
|
|
30
|
+
useLangGraphInterruptRender
|
|
31
|
+
} from "../chunk-Q6FZZJ5A.mjs";
|
|
32
|
+
import "../chunk-4XVBXDCX.mjs";
|
|
33
33
|
import "../chunk-4CEQJ2X6.mjs";
|
|
34
34
|
import {
|
|
35
35
|
useCopilotReadable
|
|
36
|
-
} from "../chunk-
|
|
37
|
-
import "../chunk-
|
|
36
|
+
} from "../chunk-LNAQ7JG3.mjs";
|
|
37
|
+
import "../chunk-OMVNJ7S3.mjs";
|
|
38
|
+
import "../chunk-PYULBXCD.mjs";
|
|
38
39
|
import "../chunk-SGF6C7I6.mjs";
|
|
39
|
-
import "../chunk-
|
|
40
|
+
import "../chunk-2IDV5OHF.mjs";
|
|
40
41
|
import "../chunk-PMAFHQ7P.mjs";
|
|
41
42
|
import "../chunk-5FHSUKQL.mjs";
|
|
42
43
|
import "../chunk-RKTVJRK7.mjs";
|
|
@@ -49,7 +50,7 @@ import "../chunk-O7ARI5CV.mjs";
|
|
|
49
50
|
import "../chunk-YAF2LATQ.mjs";
|
|
50
51
|
import "../chunk-57K2ZJ5F.mjs";
|
|
51
52
|
import "../chunk-YPSGKPDA.mjs";
|
|
52
|
-
import "../chunk-
|
|
53
|
+
import "../chunk-XGRBCWK6.mjs";
|
|
53
54
|
import "../chunk-DCTJZ742.mjs";
|
|
54
55
|
import "../chunk-SKC7AJIV.mjs";
|
|
55
56
|
export {
|
package/dist/hooks/use-chat.d.ts
CHANGED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { FunctionCallHandler, CoAgentStateRenderHandler } from '@copilotkit/shared';
|
|
3
3
|
import { Message, TextMessage, ForwardedParametersInput, ExtensionsInput } from '@copilotkit/runtime-client-gql';
|
|
4
|
-
import { c as CopilotApiConfig, A as AgentSession, L as LangGraphInterruptAction, d as LangGraphInterruptActionSetter } from '../copilot-context-
|
|
4
|
+
import { c as CopilotApiConfig, A as AgentSession, L as LangGraphInterruptAction, d as LangGraphInterruptActionSetter } from '../copilot-context-bd88d30d.js';
|
|
5
5
|
import { FrontendAction } from '../types/frontend-action.js';
|
|
6
6
|
import { CoagentState } from '../types/coagent-state.js';
|
|
7
|
+
import '../context/copilot-messages-context.js';
|
|
7
8
|
import './use-tree.js';
|
|
8
9
|
import '../types/document-pointer.js';
|
|
9
10
|
import '../types/chat-suggestion-configuration.js';
|
|
@@ -134,6 +135,10 @@ interface AppendMessageOptions {
|
|
|
134
135
|
* Whether to run the chat completion after appending the message. Defaults to `true`.
|
|
135
136
|
*/
|
|
136
137
|
followUp?: boolean;
|
|
138
|
+
/**
|
|
139
|
+
* Whether to clear the suggestions after appending the message. Defaults to `true`.
|
|
140
|
+
*/
|
|
141
|
+
clearSuggestions?: boolean;
|
|
137
142
|
}
|
|
138
143
|
declare function useChat(options: UseChatOptions): UseChatHelpers;
|
|
139
144
|
|
package/dist/hooks/use-chat.js
CHANGED
|
@@ -186,7 +186,10 @@ var emptyCopilotContext = {
|
|
|
186
186
|
langGraphInterruptAction: null,
|
|
187
187
|
setLangGraphInterruptAction: () => null,
|
|
188
188
|
removeLangGraphInterruptAction: () => null,
|
|
189
|
-
onError: void 0
|
|
189
|
+
onError: void 0,
|
|
190
|
+
suggestions: [],
|
|
191
|
+
setSuggestions: () => {
|
|
192
|
+
}
|
|
190
193
|
};
|
|
191
194
|
var CopilotContext = import_react.default.createContext(emptyCopilotContext);
|
|
192
195
|
function useCopilotContext() {
|