@lobehub/lobehub 2.0.0-next.276 → 2.0.0-next.278
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/.cursor/rules/db-migrations.mdc +1 -1
- package/.cursor/rules/debug-usage.mdc +7 -5
- package/.cursor/rules/desktop-controller-tests.mdc +2 -1
- package/.cursor/rules/desktop-feature-implementation.mdc +9 -5
- package/.cursor/rules/desktop-local-tools-implement.mdc +67 -66
- package/.cursor/rules/desktop-menu-configuration.mdc +21 -9
- package/.cursor/rules/desktop-window-management.mdc +17 -2
- package/.cursor/rules/drizzle-schema-style-guide.mdc +6 -6
- package/.cursor/rules/hotkey.mdc +1 -0
- package/.cursor/rules/i18n.mdc +1 -0
- package/.cursor/rules/project-structure.mdc +16 -3
- package/.cursor/rules/react.mdc +17 -5
- package/.cursor/rules/recent-data-usage.mdc +2 -1
- package/.cursor/rules/testing-guide/testing-guide.mdc +262 -238
- package/.cursor/rules/testing-guide/zustand-store-action-test.mdc +1 -1
- package/.cursor/rules/zustand-action-patterns.mdc +1 -1
- package/.cursor/rules/zustand-slice-organization.mdc +4 -4
- package/CHANGELOG.md +51 -0
- package/CLAUDE.md +1 -1
- package/GEMINI.md +1 -1
- package/changelog/v1.json +14 -0
- package/docs/development/database-schema.dbml +16 -0
- package/locales/en-US/chat.json +24 -0
- package/locales/en-US/setting.json +11 -0
- package/locales/zh-CN/chat.json +24 -0
- package/locales/zh-CN/setting.json +11 -0
- package/package.json +1 -1
- package/packages/builtin-tool-group-agent-builder/src/client/Inspector/BatchCreateAgents/index.tsx +2 -2
- package/packages/builtin-tool-group-agent-builder/src/client/Inspector/UpdateGroup/index.tsx +56 -56
- package/packages/builtin-tool-group-agent-builder/src/client/Render/BatchCreateAgents.tsx +3 -2
- package/packages/builtin-tool-group-agent-builder/src/executor.ts +2 -1
- package/packages/business/const/src/index.ts +3 -0
- package/packages/database/migrations/0069_add_topic_shares_table.sql +22 -0
- package/packages/database/migrations/meta/0069_snapshot.json +9704 -0
- package/packages/database/migrations/meta/_journal.json +7 -0
- package/packages/database/src/models/__tests__/topicShare.test.ts +318 -0
- package/packages/database/src/models/topicShare.ts +177 -0
- package/packages/database/src/schemas/topic.ts +44 -2
- package/packages/types/src/agentCronJob/index.ts +19 -23
- package/packages/types/src/conversation.ts +5 -0
- package/packages/types/src/serverConfig.ts +1 -0
- package/packages/types/src/topic/topic.ts +46 -0
- package/src/app/[variants]/(main)/agent/_layout/Sidebar/Cron/Actions.tsx +31 -0
- package/src/app/[variants]/(main)/agent/_layout/Sidebar/Cron/CronTopicGroup.tsx +10 -6
- package/src/app/[variants]/(main)/agent/_layout/Sidebar/Cron/index.tsx +7 -11
- package/src/app/[variants]/(main)/agent/_layout/Sidebar/Cron/useDropdownMenu.tsx +102 -0
- package/src/app/[variants]/(main)/agent/cron/[cronId]/CronConfig.ts +179 -0
- package/src/app/[variants]/(main)/agent/cron/[cronId]/features/CronJobContentEditor.tsx +111 -0
- package/src/app/[variants]/(main)/agent/cron/[cronId]/features/CronJobHeader.tsx +45 -0
- package/src/app/[variants]/(main)/agent/cron/[cronId]/features/CronJobSaveButton.tsx +31 -0
- package/src/app/[variants]/(main)/agent/cron/[cronId]/features/CronJobScheduleConfig.tsx +213 -0
- package/src/app/[variants]/(main)/agent/cron/[cronId]/index.tsx +186 -344
- package/src/app/[variants]/(main)/agent/features/Conversation/Header/ShareButton/index.tsx +24 -9
- package/src/app/[variants]/(main)/agent/profile/features/AgentCronJobs/index.tsx +42 -97
- package/src/app/[variants]/(main)/agent/profile/features/ProfileEditor/index.tsx +4 -20
- package/src/app/[variants]/(main)/community/features/UserAvatar/index.tsx +15 -5
- package/src/app/[variants]/(main)/group/_layout/Sidebar/GroupConfig/AgentProfilePopup.tsx +1 -6
- package/src/app/[variants]/(main)/group/features/Conversation/Header/ShareButton/index.tsx +26 -9
- package/src/app/[variants]/(main)/image/_layout/ConfigPanel/components/AspectRatioSelect/index.tsx +1 -2
- package/src/app/[variants]/(main)/image/_layout/ConfigPanel/components/ImageNum.tsx +54 -173
- package/src/app/[variants]/(main)/image/_layout/ConfigPanel/components/ResolutionSelect.tsx +22 -67
- package/src/app/[variants]/(mobile)/router/mobileRouter.config.tsx +18 -0
- package/src/app/[variants]/router/desktopRouter.config.tsx +18 -0
- package/src/app/[variants]/share/t/[id]/SharedMessageList.tsx +54 -0
- package/src/app/[variants]/share/t/[id]/_layout/index.tsx +170 -0
- package/src/app/[variants]/share/t/[id]/features/Portal/index.tsx +66 -0
- package/src/app/[variants]/share/t/[id]/index.tsx +112 -0
- package/src/app/robots.tsx +1 -1
- package/src/business/client/BusinessMobileRoutes.tsx +1 -1
- package/src/features/Conversation/ChatList/index.tsx +12 -5
- package/src/features/Conversation/Messages/AssistantGroup/Tool/Render/index.tsx +8 -4
- package/src/features/Conversation/Messages/AssistantGroup/Tool/index.tsx +15 -10
- package/src/features/Conversation/Messages/AssistantGroup/Tools.tsx +3 -1
- package/src/features/Conversation/Messages/AssistantGroup/components/ContentBlock.tsx +3 -2
- package/src/features/Conversation/Messages/AssistantGroup/components/GroupItem.tsx +2 -2
- package/src/features/Conversation/Messages/Supervisor/components/ContentBlock.tsx +25 -26
- package/src/features/Conversation/Messages/Supervisor/components/Group.tsx +4 -2
- package/src/features/Conversation/Messages/Tool/Tool/index.tsx +16 -12
- package/src/features/Conversation/Messages/Tool/index.tsx +20 -11
- package/src/features/Conversation/Messages/index.tsx +1 -1
- package/src/features/Conversation/store/slices/data/action.ts +2 -1
- package/src/features/SharePopover/index.tsx +215 -0
- package/src/features/SharePopover/style.ts +10 -0
- package/src/libs/next/proxy/define-config.ts +4 -1
- package/src/locales/default/chat.ts +26 -0
- package/src/proxy.ts +1 -0
- package/src/server/globalConfig/index.ts +1 -0
- package/src/server/routers/lambda/__tests__/message.test.ts +152 -0
- package/src/server/routers/lambda/__tests__/share.test.ts +227 -0
- package/src/server/routers/lambda/__tests__/topic.test.ts +174 -0
- package/src/server/routers/lambda/index.ts +2 -0
- package/src/server/routers/lambda/message.ts +37 -4
- package/src/server/routers/lambda/share.ts +55 -0
- package/src/server/routers/lambda/topic.ts +45 -0
- package/src/services/chatGroup/index.ts +1 -4
- package/src/services/message/index.ts +1 -0
- package/src/services/topic/index.ts +16 -0
- package/src/store/serverConfig/selectors.ts +1 -0
|
@@ -16,7 +16,7 @@ Main interfaces exposed for UI component consumption:
|
|
|
16
16
|
|
|
17
17
|
- Naming: Verb form (`createTopic`, `sendMessage`, `updateTopicTitle`)
|
|
18
18
|
- Responsibilities: Parameter validation, flow orchestration, calling internal actions
|
|
19
|
-
- Example:
|
|
19
|
+
- Example: `src/store/chat/slices/topic/action.ts`
|
|
20
20
|
|
|
21
21
|
```typescript
|
|
22
22
|
// Public Action example
|
|
@@ -105,7 +105,7 @@ export const initialTopicState: ChatTopicState = {
|
|
|
105
105
|
};
|
|
106
106
|
```
|
|
107
107
|
|
|
108
|
-
|
|
108
|
+
1. `reducer.ts` (复杂状态使用):
|
|
109
109
|
- 定义纯函数 reducer,处理同步状态转换
|
|
110
110
|
- 使用 `immer` 确保不可变更新
|
|
111
111
|
|
|
@@ -151,7 +151,7 @@ export const topicReducer = (state: ChatTopic[] = [], payload: ChatTopicDispatch
|
|
|
151
151
|
};
|
|
152
152
|
```
|
|
153
153
|
|
|
154
|
-
|
|
154
|
+
1. `selectors.ts`:
|
|
155
155
|
- 提供状态查询和计算函数
|
|
156
156
|
- 供 UI 组件使用的状态订阅接口
|
|
157
157
|
- 重要: 使用 `export const xxxSelectors` 模式聚合所有 selectors
|
|
@@ -186,7 +186,7 @@ export const topicSelectors = {
|
|
|
186
186
|
|
|
187
187
|
当 slice 的 actions 过于复杂时,可以拆分到子目录:
|
|
188
188
|
|
|
189
|
-
```
|
|
189
|
+
```plaintext
|
|
190
190
|
src/store/chat/slices/aiChat/
|
|
191
191
|
├── actions/
|
|
192
192
|
│ ├── generateAIChat.ts # AI 对话生成
|
|
@@ -204,7 +204,7 @@ src/store/chat/slices/aiChat/
|
|
|
204
204
|
|
|
205
205
|
管理多种内置工具的状态:
|
|
206
206
|
|
|
207
|
-
```
|
|
207
|
+
```plaintext
|
|
208
208
|
src/store/chat/slices/builtinTool/
|
|
209
209
|
├── actions/
|
|
210
210
|
│ ├── dalle.ts # DALL-E 图像生成
|
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,57 @@
|
|
|
2
2
|
|
|
3
3
|
# Changelog
|
|
4
4
|
|
|
5
|
+
## [Version 2.0.0-next.278](https://github.com/lobehub/lobe-chat/compare/v2.0.0-next.277...v2.0.0-next.278)
|
|
6
|
+
|
|
7
|
+
<sup>Released on **2026-01-13**</sup>
|
|
8
|
+
|
|
9
|
+
#### ✨ Features
|
|
10
|
+
|
|
11
|
+
- **share**: Add topic sharing functionality.
|
|
12
|
+
|
|
13
|
+
<br/>
|
|
14
|
+
|
|
15
|
+
<details>
|
|
16
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
|
17
|
+
|
|
18
|
+
#### What's improved
|
|
19
|
+
|
|
20
|
+
- **share**: Add topic sharing functionality, closes [#11448](https://github.com/lobehub/lobe-chat/issues/11448) ([ddca165](https://github.com/lobehub/lobe-chat/commit/ddca165))
|
|
21
|
+
|
|
22
|
+
</details>
|
|
23
|
+
|
|
24
|
+
<div align="right">
|
|
25
|
+
|
|
26
|
+
[](#readme-top)
|
|
27
|
+
|
|
28
|
+
</div>
|
|
29
|
+
|
|
30
|
+
## [Version 2.0.0-next.277](https://github.com/lobehub/lobe-chat/compare/v2.0.0-next.276...v2.0.0-next.277)
|
|
31
|
+
|
|
32
|
+
<sup>Released on **2026-01-13**</sup>
|
|
33
|
+
|
|
34
|
+
#### ✨ Features
|
|
35
|
+
|
|
36
|
+
- **misc**: Update the community user layout action button, update the cron job visiual way.
|
|
37
|
+
|
|
38
|
+
<br/>
|
|
39
|
+
|
|
40
|
+
<details>
|
|
41
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
|
42
|
+
|
|
43
|
+
#### What's improved
|
|
44
|
+
|
|
45
|
+
- **misc**: Update the community user layout action button, closes [#11472](https://github.com/lobehub/lobe-chat/issues/11472) ([2dd6d42](https://github.com/lobehub/lobe-chat/commit/2dd6d42))
|
|
46
|
+
- **misc**: Update the cron job visiual way, closes [#11466](https://github.com/lobehub/lobe-chat/issues/11466) ([63d81de](https://github.com/lobehub/lobe-chat/commit/63d81de))
|
|
47
|
+
|
|
48
|
+
</details>
|
|
49
|
+
|
|
50
|
+
<div align="right">
|
|
51
|
+
|
|
52
|
+
[](#readme-top)
|
|
53
|
+
|
|
54
|
+
</div>
|
|
55
|
+
|
|
5
56
|
## [Version 2.0.0-next.276](https://github.com/lobehub/lobe-chat/compare/v2.0.0-next.275...v2.0.0-next.276)
|
|
6
57
|
|
|
7
58
|
<sup>Released on **2026-01-13**</sup>
|
package/CLAUDE.md
CHANGED
|
@@ -34,7 +34,7 @@ see @.cursor/rules/typescript.mdc
|
|
|
34
34
|
|
|
35
35
|
### Testing
|
|
36
36
|
|
|
37
|
-
- **Required Rule**: read
|
|
37
|
+
- **Required Rule**: read `.cursor/rules/testing-guide/testing-guide.mdc` before writing tests
|
|
38
38
|
- **Command**:
|
|
39
39
|
- web: `bunx vitest run --silent='passed-only' '[file-path-pattern]'`
|
|
40
40
|
- packages(eg: database): `cd packages/database && bunx vitest run --silent='passed-only' '[file-path-pattern]'`
|
package/GEMINI.md
CHANGED
|
@@ -34,7 +34,7 @@ see @.cursor/rules/typescript.mdc
|
|
|
34
34
|
|
|
35
35
|
### Testing
|
|
36
36
|
|
|
37
|
-
- **Required Rule**: read
|
|
37
|
+
- **Required Rule**: read `.cursor/rules/testing-guide/testing-guide.mdc` before writing tests
|
|
38
38
|
- **Command**:
|
|
39
39
|
- web: `bunx vitest run --silent='passed-only' '[file-path-pattern]'`
|
|
40
40
|
- packages(eg: database): `cd packages/database && bunx vitest run --silent='passed-only' '[file-path-pattern]'`
|
package/changelog/v1.json
CHANGED
|
@@ -1,4 +1,18 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"children": {},
|
|
4
|
+
"date": "2026-01-13",
|
|
5
|
+
"version": "2.0.0-next.278"
|
|
6
|
+
},
|
|
7
|
+
{
|
|
8
|
+
"children": {
|
|
9
|
+
"features": [
|
|
10
|
+
"Update the community user layout action button, update the cron job visiual way."
|
|
11
|
+
]
|
|
12
|
+
},
|
|
13
|
+
"date": "2026-01-13",
|
|
14
|
+
"version": "2.0.0-next.277"
|
|
15
|
+
},
|
|
2
16
|
{
|
|
3
17
|
"children": {},
|
|
4
18
|
"date": "2026-01-13",
|
|
@@ -1093,6 +1093,22 @@ table topic_documents {
|
|
|
1093
1093
|
}
|
|
1094
1094
|
}
|
|
1095
1095
|
|
|
1096
|
+
table topic_shares {
|
|
1097
|
+
id text [pk, not null]
|
|
1098
|
+
topic_id text [not null]
|
|
1099
|
+
user_id text [not null]
|
|
1100
|
+
visibility text [not null, default: 'private']
|
|
1101
|
+
page_view_count integer [not null, default: 0]
|
|
1102
|
+
accessed_at "timestamp with time zone" [not null, default: `now()`]
|
|
1103
|
+
created_at "timestamp with time zone" [not null, default: `now()`]
|
|
1104
|
+
updated_at "timestamp with time zone" [not null, default: `now()`]
|
|
1105
|
+
|
|
1106
|
+
indexes {
|
|
1107
|
+
topic_id [name: 'topic_shares_topic_id_unique', unique]
|
|
1108
|
+
user_id [name: 'topic_shares_user_id_idx']
|
|
1109
|
+
}
|
|
1110
|
+
}
|
|
1111
|
+
|
|
1096
1112
|
table topics {
|
|
1097
1113
|
id text [pk, not null]
|
|
1098
1114
|
title text
|
package/locales/en-US/chat.json
CHANGED
|
@@ -253,6 +253,8 @@
|
|
|
253
253
|
"sessionGroup.sorting": "Group sorting updating...",
|
|
254
254
|
"sessionGroup.tooLong": "Group name length should be between 1-20",
|
|
255
255
|
"shareModal.copy": "Copy",
|
|
256
|
+
"shareModal.copyLink": "Copy Link",
|
|
257
|
+
"shareModal.copyLinkSuccess": "Link copied",
|
|
256
258
|
"shareModal.download": "Download Screenshot",
|
|
257
259
|
"shareModal.downloadError": "Download failed",
|
|
258
260
|
"shareModal.downloadFile": "Download File",
|
|
@@ -268,12 +270,26 @@
|
|
|
268
270
|
"shareModal.imageType": "Image Format",
|
|
269
271
|
"shareModal.includeTool": "Include Skill messages",
|
|
270
272
|
"shareModal.includeUser": "Include User Messages",
|
|
273
|
+
"shareModal.link": "Link",
|
|
274
|
+
"shareModal.link.linkHint": "Anyone with the link can view this topic",
|
|
275
|
+
"shareModal.link.noTopic": "Start a conversation first to share",
|
|
276
|
+
"shareModal.link.permissionLink": "Anyone with the link",
|
|
277
|
+
"shareModal.link.permissionPrivate": "Private",
|
|
278
|
+
"shareModal.link.privateHint": "Only you can access this link",
|
|
279
|
+
"shareModal.link.updateError": "Failed to update sharing settings",
|
|
280
|
+
"shareModal.link.visibilityUpdated": "Visibility updated",
|
|
271
281
|
"shareModal.loadingPdf": "Loading PDF...",
|
|
272
282
|
"shareModal.noPdfData": "No PDF data available",
|
|
273
283
|
"shareModal.pdf": "PDF",
|
|
274
284
|
"shareModal.pdfErrorDescription": "An error occurred while generating the PDF, please try again",
|
|
275
285
|
"shareModal.pdfGenerationError": "PDF generation failed",
|
|
276
286
|
"shareModal.pdfReady": "PDF is ready",
|
|
287
|
+
"shareModal.popover.moreOptions": "More share options",
|
|
288
|
+
"shareModal.popover.privacyWarning.confirm": "I understand, continue",
|
|
289
|
+
"shareModal.popover.privacyWarning.content": "Please ensure the conversation does not contain any private or sensitive information before sharing. LobeHub is not responsible for any security issues that may arise from sharing.",
|
|
290
|
+
"shareModal.popover.privacyWarning.title": "Privacy Notice",
|
|
291
|
+
"shareModal.popover.title": "Share Topic",
|
|
292
|
+
"shareModal.popover.visibility": "Visibility",
|
|
277
293
|
"shareModal.regeneratePdf": "Regenerate PDF",
|
|
278
294
|
"shareModal.screenshot": "Screenshot",
|
|
279
295
|
"shareModal.settings": "Export Settings",
|
|
@@ -286,6 +302,14 @@
|
|
|
286
302
|
"shareModal.withPluginInfo": "Include Skill Information",
|
|
287
303
|
"shareModal.withRole": "Include Message Role",
|
|
288
304
|
"shareModal.withSystemRole": "Include Agent Profile",
|
|
305
|
+
"sharePage.error.forbidden.subtitle": "This share is private and not accessible.",
|
|
306
|
+
"sharePage.error.forbidden.title": "Access Denied",
|
|
307
|
+
"sharePage.error.notFound.subtitle": "This topic does not exist or has been removed.",
|
|
308
|
+
"sharePage.error.notFound.title": "Topic Not Found",
|
|
309
|
+
"sharePage.error.unauthorized.action": "Sign In",
|
|
310
|
+
"sharePage.error.unauthorized.subtitle": "Please sign in to view this shared topic.",
|
|
311
|
+
"sharePage.error.unauthorized.title": "Sign In Required",
|
|
312
|
+
"sharePageDisclaimer": "This content is shared by a user and does not represent the views of LobeHub. LobeHub is not responsible for any consequences arising from this shared content.",
|
|
289
313
|
"stt.action": "Voice Input",
|
|
290
314
|
"stt.loading": "Recognizing...",
|
|
291
315
|
"stt.prettifying": "Polishing...",
|
|
@@ -3,10 +3,16 @@
|
|
|
3
3
|
"about.title": "About",
|
|
4
4
|
"advancedSettings": "Advanced Settings",
|
|
5
5
|
"agentCronJobs.addJob": "Add Scheduled Task",
|
|
6
|
+
"agentCronJobs.clearTopics": "Clear Execution Results",
|
|
7
|
+
"agentCronJobs.clearTopicsFailed": "Failed to clear execution results",
|
|
8
|
+
"agentCronJobs.confirmClearTopics": "Are you sure you want to clear {{count}} execution result(s)? This action cannot be undone.",
|
|
6
9
|
"agentCronJobs.confirmDelete": "Are you sure you want to delete this scheduled task?",
|
|
10
|
+
"agentCronJobs.confirmDeleteCronJob": "Are you sure you want to delete this scheduled task and all its execution results? This action cannot be undone.",
|
|
7
11
|
"agentCronJobs.content": "Task Content",
|
|
8
12
|
"agentCronJobs.create": "Create",
|
|
9
13
|
"agentCronJobs.createSuccess": "Scheduled task created successfully",
|
|
14
|
+
"agentCronJobs.deleteCronJob": "Delete Scheduled Task",
|
|
15
|
+
"agentCronJobs.deleteFailed": "Failed to delete scheduled task",
|
|
10
16
|
"agentCronJobs.deleteJob": "Delete Task",
|
|
11
17
|
"agentCronJobs.deleteSuccess": "Scheduled task deleted successfully",
|
|
12
18
|
"agentCronJobs.description": "Automate your agent with scheduled executions",
|
|
@@ -25,6 +31,7 @@
|
|
|
25
31
|
"agentCronJobs.form.validation.nameRequired": "Task name is required",
|
|
26
32
|
"agentCronJobs.interval.12hours": "Every 12 hours",
|
|
27
33
|
"agentCronJobs.interval.1hour": "Every hour",
|
|
34
|
+
"agentCronJobs.interval.2hours": "Every 2 hours",
|
|
28
35
|
"agentCronJobs.interval.30min": "Every 30 minutes",
|
|
29
36
|
"agentCronJobs.interval.6hours": "Every 6 hours",
|
|
30
37
|
"agentCronJobs.interval.daily": "Daily",
|
|
@@ -36,7 +43,11 @@
|
|
|
36
43
|
"agentCronJobs.noExecutionResults": "No execution results",
|
|
37
44
|
"agentCronJobs.remainingExecutions": "Remaining: {{count}}",
|
|
38
45
|
"agentCronJobs.save": "Save",
|
|
46
|
+
"agentCronJobs.saveAsNew": "Save as New Scheduled Task",
|
|
39
47
|
"agentCronJobs.schedule": "Schedule",
|
|
48
|
+
"agentCronJobs.scheduleType.daily": "Daily",
|
|
49
|
+
"agentCronJobs.scheduleType.hourly": "Hourly",
|
|
50
|
+
"agentCronJobs.scheduleType.weekly": "Weekly",
|
|
40
51
|
"agentCronJobs.status.depleted": "Depleted",
|
|
41
52
|
"agentCronJobs.status.disabled": "Disabled",
|
|
42
53
|
"agentCronJobs.status.enabled": "Enabled",
|
package/locales/zh-CN/chat.json
CHANGED
|
@@ -253,6 +253,8 @@
|
|
|
253
253
|
"sessionGroup.sorting": "正在更新排序…",
|
|
254
254
|
"sessionGroup.tooLong": "分组名称长度需为 1–20 个字符",
|
|
255
255
|
"shareModal.copy": "复制",
|
|
256
|
+
"shareModal.copyLink": "复制链接",
|
|
257
|
+
"shareModal.copyLinkSuccess": "链接已复制",
|
|
256
258
|
"shareModal.download": "下载截图",
|
|
257
259
|
"shareModal.downloadError": "下载失败,请检查网络后重试",
|
|
258
260
|
"shareModal.downloadFile": "下载文件",
|
|
@@ -268,12 +270,26 @@
|
|
|
268
270
|
"shareModal.imageType": "图片格式",
|
|
269
271
|
"shareModal.includeTool": "包含技能消息",
|
|
270
272
|
"shareModal.includeUser": "包含用户消息",
|
|
273
|
+
"shareModal.link": "链接",
|
|
274
|
+
"shareModal.link.linkHint": "任何拿到链接的人都可以查看此话题",
|
|
275
|
+
"shareModal.link.noTopic": "先开始对话,才能分享",
|
|
276
|
+
"shareModal.link.permissionLink": "有链接即可访问",
|
|
277
|
+
"shareModal.link.permissionPrivate": "私密",
|
|
278
|
+
"shareModal.link.privateHint": "仅你自己可以访问此链接",
|
|
279
|
+
"shareModal.link.updateError": "更新分享设置失败",
|
|
280
|
+
"shareModal.link.visibilityUpdated": "可见性已更新",
|
|
271
281
|
"shareModal.loadingPdf": "正在加载 PDF…",
|
|
272
282
|
"shareModal.noPdfData": "暂无 PDF 数据",
|
|
273
283
|
"shareModal.pdf": "PDF",
|
|
274
284
|
"shareModal.pdfErrorDescription": "生成 PDF 时出错,请重试或联系支持",
|
|
275
285
|
"shareModal.pdfGenerationError": "PDF 生成失败",
|
|
276
286
|
"shareModal.pdfReady": "PDF 已准备就绪",
|
|
287
|
+
"shareModal.popover.moreOptions": "更多分享方式",
|
|
288
|
+
"shareModal.popover.privacyWarning.confirm": "我已了解,继续",
|
|
289
|
+
"shareModal.popover.privacyWarning.content": "分享前请确保对话中不包含任何隐私或敏感信息。因分享而可能产生的任何安全问题,LobeHub 概不负责。",
|
|
290
|
+
"shareModal.popover.privacyWarning.title": "隐私提醒",
|
|
291
|
+
"shareModal.popover.title": "分享话题",
|
|
292
|
+
"shareModal.popover.visibility": "可见性",
|
|
277
293
|
"shareModal.regeneratePdf": "重新生成 PDF",
|
|
278
294
|
"shareModal.screenshot": "截图",
|
|
279
295
|
"shareModal.settings": "导出设置",
|
|
@@ -286,6 +302,14 @@
|
|
|
286
302
|
"shareModal.withPluginInfo": "包含技能信息",
|
|
287
303
|
"shareModal.withRole": "包含消息角色",
|
|
288
304
|
"shareModal.withSystemRole": "包含助理档案",
|
|
305
|
+
"sharePage.error.forbidden.subtitle": "此分享为私密状态,无法访问。",
|
|
306
|
+
"sharePage.error.forbidden.title": "无权访问",
|
|
307
|
+
"sharePage.error.notFound.subtitle": "该话题不存在或已被删除。",
|
|
308
|
+
"sharePage.error.notFound.title": "话题不存在",
|
|
309
|
+
"sharePage.error.unauthorized.action": "登录",
|
|
310
|
+
"sharePage.error.unauthorized.subtitle": "请登录后查看此分享话题。",
|
|
311
|
+
"sharePage.error.unauthorized.title": "需要登录",
|
|
312
|
+
"sharePageDisclaimer": "此内容由用户分享,不代表 LobeHub 观点。LobeHub 不对该分享内容产生的任何后果承担责任。",
|
|
289
313
|
"stt.action": "语音输入",
|
|
290
314
|
"stt.loading": "识别中…",
|
|
291
315
|
"stt.prettifying": "润色中…",
|
|
@@ -3,10 +3,16 @@
|
|
|
3
3
|
"about.title": "关于",
|
|
4
4
|
"advancedSettings": "进阶配置",
|
|
5
5
|
"agentCronJobs.addJob": "添加定时任务",
|
|
6
|
+
"agentCronJobs.clearTopics": "清空执行结果",
|
|
7
|
+
"agentCronJobs.clearTopicsFailed": "清空执行结果失败",
|
|
8
|
+
"agentCronJobs.confirmClearTopics": "确定要清空 {{count}} 条执行结果吗?此操作不可撤销。",
|
|
6
9
|
"agentCronJobs.confirmDelete": "确定要删除此定时任务吗?",
|
|
10
|
+
"agentCronJobs.confirmDeleteCronJob": "确定要删除此定时任务及其所有执行结果吗?此操作不可撤销。",
|
|
7
11
|
"agentCronJobs.content": "任务内容",
|
|
8
12
|
"agentCronJobs.create": "创建",
|
|
9
13
|
"agentCronJobs.createSuccess": "定时任务创建成功",
|
|
14
|
+
"agentCronJobs.deleteCronJob": "删除定时任务",
|
|
15
|
+
"agentCronJobs.deleteFailed": "删除定时任务失败",
|
|
10
16
|
"agentCronJobs.deleteJob": "删除任务",
|
|
11
17
|
"agentCronJobs.deleteSuccess": "定时任务删除成功",
|
|
12
18
|
"agentCronJobs.description": "通过定时执行自动化您的智能体",
|
|
@@ -25,6 +31,7 @@
|
|
|
25
31
|
"agentCronJobs.form.validation.nameRequired": "任务名称不能为空",
|
|
26
32
|
"agentCronJobs.interval.12hours": "每12小时",
|
|
27
33
|
"agentCronJobs.interval.1hour": "每小时",
|
|
34
|
+
"agentCronJobs.interval.2hours": "每2小时",
|
|
28
35
|
"agentCronJobs.interval.30min": "每30分钟",
|
|
29
36
|
"agentCronJobs.interval.6hours": "每6小时",
|
|
30
37
|
"agentCronJobs.interval.daily": "每日",
|
|
@@ -36,7 +43,11 @@
|
|
|
36
43
|
"agentCronJobs.noExecutionResults": "无执行结果",
|
|
37
44
|
"agentCronJobs.remainingExecutions": "剩余:{{count}}",
|
|
38
45
|
"agentCronJobs.save": "保存",
|
|
46
|
+
"agentCronJobs.saveAsNew": "保存为新定时任务",
|
|
39
47
|
"agentCronJobs.schedule": "计划",
|
|
48
|
+
"agentCronJobs.scheduleType.daily": "每日",
|
|
49
|
+
"agentCronJobs.scheduleType.hourly": "每小时",
|
|
50
|
+
"agentCronJobs.scheduleType.weekly": "每周",
|
|
40
51
|
"agentCronJobs.status.depleted": "已耗尽",
|
|
41
52
|
"agentCronJobs.status.disabled": "已禁用",
|
|
42
53
|
"agentCronJobs.status.enabled": "已启用",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lobehub/lobehub",
|
|
3
|
-
"version": "2.0.0-next.
|
|
3
|
+
"version": "2.0.0-next.278",
|
|
4
4
|
"description": "LobeHub - an open-source,comprehensive AI Agent framework that supports speech synthesis, multimodal, and extensible Function Call plugin system. Supports one-click free deployment of your private ChatGPT/LLM web application.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"framework",
|
package/packages/builtin-tool-group-agent-builder/src/client/Inspector/BatchCreateAgents/index.tsx
CHANGED
|
@@ -18,8 +18,8 @@ const styles = createStaticStyles(({ css, cssVar: cv }) => ({
|
|
|
18
18
|
align-items: center;
|
|
19
19
|
`,
|
|
20
20
|
count: css`
|
|
21
|
-
color: ${cv.colorTextSecondary};
|
|
22
21
|
font-size: 12px;
|
|
22
|
+
color: ${cv.colorTextSecondary};
|
|
23
23
|
`,
|
|
24
24
|
root: css`
|
|
25
25
|
overflow: hidden;
|
|
@@ -83,8 +83,8 @@ export const BatchCreateAgentsInspector = memo<
|
|
|
83
83
|
<div className={styles.avatarGroup}>
|
|
84
84
|
{displayInfo.displayAgents.map((agent, index) => (
|
|
85
85
|
<Avatar
|
|
86
|
-
key={index}
|
|
87
86
|
avatar={agent.avatar}
|
|
87
|
+
key={index}
|
|
88
88
|
shape={'square'}
|
|
89
89
|
size={20}
|
|
90
90
|
title={agent.title}
|
package/packages/builtin-tool-group-agent-builder/src/client/Inspector/UpdateGroup/index.tsx
CHANGED
|
@@ -17,70 +17,70 @@ const styles = createStaticStyles(({ css }) => ({
|
|
|
17
17
|
`,
|
|
18
18
|
}));
|
|
19
19
|
|
|
20
|
-
export const UpdateGroupInspector = memo<
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
export const UpdateGroupInspector = memo<
|
|
21
|
+
BuiltinInspectorProps<UpdateGroupParams, UpdateGroupState>
|
|
22
|
+
>(({ args, partialArgs, isArgumentsStreaming, isLoading, pluginState }) => {
|
|
23
|
+
const { t } = useTranslation('plugin');
|
|
23
24
|
|
|
24
|
-
|
|
25
|
-
|
|
25
|
+
const config = args?.config || partialArgs?.config;
|
|
26
|
+
const meta = args?.meta || partialArgs?.meta;
|
|
26
27
|
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
}
|
|
34
|
-
if (config?.openingQuestions !== undefined) {
|
|
35
|
-
fields.push(t('builtins.lobe-group-agent-builder.inspector.openingQuestions'));
|
|
36
|
-
}
|
|
37
|
-
// Meta fields
|
|
38
|
-
if (meta?.title !== undefined) {
|
|
39
|
-
fields.push(t('builtins.lobe-group-agent-builder.inspector.title'));
|
|
40
|
-
}
|
|
41
|
-
if (meta?.description !== undefined) {
|
|
42
|
-
fields.push(t('builtins.lobe-group-agent-builder.inspector.description'));
|
|
43
|
-
}
|
|
44
|
-
if (meta?.avatar !== undefined) {
|
|
45
|
-
fields.push(t('builtins.lobe-group-agent-builder.inspector.avatar'));
|
|
46
|
-
}
|
|
47
|
-
if (meta?.backgroundColor !== undefined) {
|
|
48
|
-
fields.push(t('builtins.lobe-group-agent-builder.inspector.backgroundColor'));
|
|
49
|
-
}
|
|
50
|
-
return fields.length > 0 ? fields.join(', ') : '';
|
|
51
|
-
}, [config, meta, t]);
|
|
52
|
-
|
|
53
|
-
// Initial streaming state
|
|
54
|
-
if (isArgumentsStreaming && !displayText) {
|
|
55
|
-
return (
|
|
56
|
-
<div className={cx(inspectorTextStyles.root, shinyTextStyles.shinyText)}>
|
|
57
|
-
<span>{t('builtins.lobe-group-agent-builder.apiName.updateGroup')}</span>
|
|
58
|
-
</div>
|
|
59
|
-
);
|
|
28
|
+
// Build display text from updated fields
|
|
29
|
+
const displayText = useMemo(() => {
|
|
30
|
+
const fields: string[] = [];
|
|
31
|
+
// Config fields
|
|
32
|
+
if (config?.openingMessage !== undefined) {
|
|
33
|
+
fields.push(t('builtins.lobe-group-agent-builder.inspector.openingMessage'));
|
|
60
34
|
}
|
|
35
|
+
if (config?.openingQuestions !== undefined) {
|
|
36
|
+
fields.push(t('builtins.lobe-group-agent-builder.inspector.openingQuestions'));
|
|
37
|
+
}
|
|
38
|
+
// Meta fields
|
|
39
|
+
if (meta?.title !== undefined) {
|
|
40
|
+
fields.push(t('builtins.lobe-group-agent-builder.inspector.title'));
|
|
41
|
+
}
|
|
42
|
+
if (meta?.description !== undefined) {
|
|
43
|
+
fields.push(t('builtins.lobe-group-agent-builder.inspector.description'));
|
|
44
|
+
}
|
|
45
|
+
if (meta?.avatar !== undefined) {
|
|
46
|
+
fields.push(t('builtins.lobe-group-agent-builder.inspector.avatar'));
|
|
47
|
+
}
|
|
48
|
+
if (meta?.backgroundColor !== undefined) {
|
|
49
|
+
fields.push(t('builtins.lobe-group-agent-builder.inspector.backgroundColor'));
|
|
50
|
+
}
|
|
51
|
+
return fields.length > 0 ? fields.join(', ') : '';
|
|
52
|
+
}, [config, meta, t]);
|
|
61
53
|
|
|
62
|
-
|
|
63
|
-
|
|
54
|
+
// Initial streaming state
|
|
55
|
+
if (isArgumentsStreaming && !displayText) {
|
|
64
56
|
return (
|
|
65
|
-
<div
|
|
66
|
-
className={cx(
|
|
67
|
-
inspectorTextStyles.root,
|
|
68
|
-
(isArgumentsStreaming || isLoading) && shinyTextStyles.shinyText,
|
|
69
|
-
)}
|
|
70
|
-
>
|
|
57
|
+
<div className={cx(inspectorTextStyles.root, shinyTextStyles.shinyText)}>
|
|
71
58
|
<span>{t('builtins.lobe-group-agent-builder.apiName.updateGroup')}</span>
|
|
72
|
-
{displayText && (
|
|
73
|
-
<>
|
|
74
|
-
: <span className={highlightTextStyles.primary}>{displayText}</span>
|
|
75
|
-
</>
|
|
76
|
-
)}
|
|
77
|
-
{!isLoading && isSuccess && (
|
|
78
|
-
<Check className={styles.statusIcon} color={cssVar.colorSuccess} size={14} />
|
|
79
|
-
)}
|
|
80
59
|
</div>
|
|
81
60
|
);
|
|
82
|
-
}
|
|
83
|
-
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
const isSuccess = pluginState?.success;
|
|
64
|
+
|
|
65
|
+
return (
|
|
66
|
+
<div
|
|
67
|
+
className={cx(
|
|
68
|
+
inspectorTextStyles.root,
|
|
69
|
+
(isArgumentsStreaming || isLoading) && shinyTextStyles.shinyText,
|
|
70
|
+
)}
|
|
71
|
+
>
|
|
72
|
+
<span>{t('builtins.lobe-group-agent-builder.apiName.updateGroup')}</span>
|
|
73
|
+
{displayText && (
|
|
74
|
+
<>
|
|
75
|
+
: <span className={highlightTextStyles.primary}>{displayText}</span>
|
|
76
|
+
</>
|
|
77
|
+
)}
|
|
78
|
+
{!isLoading && isSuccess && (
|
|
79
|
+
<Check className={styles.statusIcon} color={cssVar.colorSuccess} size={14} />
|
|
80
|
+
)}
|
|
81
|
+
</div>
|
|
82
|
+
);
|
|
83
|
+
});
|
|
84
84
|
|
|
85
85
|
UpdateGroupInspector.displayName = 'UpdateGroupInspector';
|
|
86
86
|
|
|
@@ -11,9 +11,10 @@ import type { BatchCreateAgentsParams, BatchCreateAgentsState } from '../../type
|
|
|
11
11
|
|
|
12
12
|
const styles = createStaticStyles(({ css, cssVar }) => ({
|
|
13
13
|
container: css`
|
|
14
|
-
padding: 4px
|
|
15
|
-
|
|
14
|
+
padding-block: 4px;
|
|
15
|
+
padding-inline: 16px;
|
|
16
16
|
border-radius: 8px;
|
|
17
|
+
background: ${cssVar.colorFillQuaternary};
|
|
17
18
|
`,
|
|
18
19
|
description: css`
|
|
19
20
|
overflow: hidden;
|
|
@@ -238,7 +238,8 @@ class GroupAgentBuilderExecutor extends BaseExecutor<typeof GroupAgentBuilderApi
|
|
|
238
238
|
|
|
239
239
|
if (!agentId) {
|
|
240
240
|
return {
|
|
241
|
-
content:
|
|
241
|
+
content:
|
|
242
|
+
'No agent found. Please provide an agentId or ensure supervisor context is available.',
|
|
242
243
|
error: { message: 'No agent found', type: 'NoAgentContext' },
|
|
243
244
|
success: false,
|
|
244
245
|
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
CREATE TABLE IF NOT EXISTS "topic_shares" (
|
|
2
|
+
"id" text PRIMARY KEY NOT NULL,
|
|
3
|
+
"topic_id" text NOT NULL,
|
|
4
|
+
"user_id" text NOT NULL,
|
|
5
|
+
"visibility" text DEFAULT 'private' NOT NULL,
|
|
6
|
+
"page_view_count" integer DEFAULT 0 NOT NULL,
|
|
7
|
+
"accessed_at" timestamp with time zone DEFAULT now() NOT NULL,
|
|
8
|
+
"created_at" timestamp with time zone DEFAULT now() NOT NULL,
|
|
9
|
+
"updated_at" timestamp with time zone DEFAULT now() NOT NULL
|
|
10
|
+
);
|
|
11
|
+
--> statement-breakpoint
|
|
12
|
+
DO $$ BEGIN
|
|
13
|
+
ALTER TABLE "topic_shares" ADD CONSTRAINT "topic_shares_topic_id_topics_id_fk" FOREIGN KEY ("topic_id") REFERENCES "public"."topics"("id") ON DELETE cascade ON UPDATE no action;
|
|
14
|
+
EXCEPTION WHEN duplicate_object THEN NULL; END $$;
|
|
15
|
+
--> statement-breakpoint
|
|
16
|
+
DO $$ BEGIN
|
|
17
|
+
ALTER TABLE "topic_shares" ADD CONSTRAINT "topic_shares_user_id_users_id_fk" FOREIGN KEY ("user_id") REFERENCES "public"."users"("id") ON DELETE cascade ON UPDATE no action;
|
|
18
|
+
EXCEPTION WHEN duplicate_object THEN NULL; END $$;
|
|
19
|
+
--> statement-breakpoint
|
|
20
|
+
CREATE UNIQUE INDEX IF NOT EXISTS "topic_shares_topic_id_unique" ON "topic_shares" USING btree ("topic_id");
|
|
21
|
+
--> statement-breakpoint
|
|
22
|
+
CREATE INDEX IF NOT EXISTS "topic_shares_user_id_idx" ON "topic_shares" USING btree ("user_id");
|