@zero-library/chat-copilot 1.0.6 → 1.0.7
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/dist/index.cjs.js +2 -3
- package/dist/index.cjs.js.map +1 -1
- package/dist/index.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.esm.js +2 -3
- package/dist/index.esm.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -7,7 +7,8 @@ import { createRequest, RequestConfig, RenderControl } from '@zero-library/commo
|
|
|
7
7
|
type ConversationMemberEnum = 'user' | 'agent';
|
|
8
8
|
declare enum AgentTypeEnum {
|
|
9
9
|
DEFAULT = 0,
|
|
10
|
-
FLOW = 1
|
|
10
|
+
FLOW = 1,
|
|
11
|
+
AUTONOMOUS = 2
|
|
11
12
|
}
|
|
12
13
|
declare enum LibraryTypeEnum {
|
|
13
14
|
DEFAULT = 0
|
package/dist/index.d.ts
CHANGED
|
@@ -7,7 +7,8 @@ import { createRequest, RequestConfig, RenderControl } from '@zero-library/commo
|
|
|
7
7
|
type ConversationMemberEnum = 'user' | 'agent';
|
|
8
8
|
declare enum AgentTypeEnum {
|
|
9
9
|
DEFAULT = 0,
|
|
10
|
-
FLOW = 1
|
|
10
|
+
FLOW = 1,
|
|
11
|
+
AUTONOMOUS = 2
|
|
11
12
|
}
|
|
12
13
|
declare enum LibraryTypeEnum {
|
|
13
14
|
DEFAULT = 0
|
package/dist/index.esm.js
CHANGED
|
@@ -669,7 +669,7 @@ function createChatStore() {
|
|
|
669
669
|
if (config2?.conversationId) {
|
|
670
670
|
switchConversation(config2.conversationId);
|
|
671
671
|
} else {
|
|
672
|
-
if (config2.conversationStrategy === 1) {
|
|
672
|
+
if (config2.conversationStrategy === 1 && conversations.list.items.length > 0) {
|
|
673
673
|
switchConversation(conversations.list.items[0].key);
|
|
674
674
|
} else {
|
|
675
675
|
createConversation();
|
|
@@ -730,7 +730,6 @@ function createChatStore() {
|
|
|
730
730
|
spec: newSpec
|
|
731
731
|
});
|
|
732
732
|
await switchConversation(data);
|
|
733
|
-
config.hooks?.onAfterSwitchConversation?.(data);
|
|
734
733
|
};
|
|
735
734
|
const conversation = proxy({
|
|
736
735
|
/** 当前激活的会话信息 */
|
|
@@ -4210,7 +4209,7 @@ var FeaturesRenderer_default = ({ skillsBtn, knowledgeBtn }) => {
|
|
|
4210
4209
|
const chatStore = useChatStore();
|
|
4211
4210
|
const agentState = useSnapshot(chatStore.agent);
|
|
4212
4211
|
return /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
4213
|
-
/* @__PURE__ */ jsxs(
|
|
4212
|
+
agentState.agentInfo.agentType === 2 /* AUTONOMOUS */ && /* @__PURE__ */ jsxs(
|
|
4214
4213
|
Flex,
|
|
4215
4214
|
{
|
|
4216
4215
|
className: classNames2(styles_module_default2.resourceBtn, { [styles_module_default2.resourceBtnActive]: agentState.model.reasoning }),
|