@lobehub/lobehub 2.1.1 → 2.1.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 +25 -0
- package/README.md +1 -1
- package/README.zh-CN.md +1 -1
- package/apps/desktop/src/main/controllers/McpInstallCtr.ts +10 -10
- package/apps/desktop/src/main/controllers/NetworkProxyCtr.ts +6 -6
- package/apps/desktop/src/main/controllers/RemoteServerSyncCtr.ts +2 -2
- package/changelog/v2.json +9 -0
- package/docs/changelog/2025-03-02-new-models.mdx +1 -1
- package/docs/changelog/2025-03-02-new-models.zh-CN.mdx +1 -1
- package/docs/changelog/2025-04-06-exports.mdx +1 -1
- package/docs/changelog/2025-04-06-exports.zh-CN.mdx +1 -1
- package/docs/changelog/2025-05-08-desktop-app.mdx +2 -2
- package/docs/changelog/2025-05-08-desktop-app.zh-CN.mdx +2 -2
- package/docs/changelog/2025-06-08-claude-4.mdx +1 -1
- package/docs/changelog/2025-06-08-claude-4.zh-CN.mdx +1 -1
- package/docs/changelog/2025-07-08-mcp-market.mdx +1 -1
- package/docs/changelog/2025-07-08-mcp-market.zh-CN.mdx +1 -1
- package/docs/changelog/2025-08-08-image-generation.mdx +1 -1
- package/docs/changelog/2025-08-08-image-generation.zh-CN.mdx +1 -1
- package/docs/changelog/2025-09-08-gemini.mdx +1 -1
- package/docs/changelog/2025-09-08-gemini.zh-CN.mdx +1 -1
- package/docs/changelog/2025-10-08-python.mdx +1 -1
- package/docs/changelog/2025-10-08-python.zh-CN.mdx +1 -1
- package/docs/changelog/2025-11-08-comfy-ui.mdx +1 -1
- package/docs/changelog/2025-11-08-comfy-ui.zh-CN.mdx +1 -1
- package/docs/changelog/2025-12-20-mcp.mdx +1 -1
- package/docs/changelog/2025-12-20-mcp.zh-CN.mdx +1 -1
- package/docs/development/basic/add-new-authentication-providers.zh-CN.mdx +1 -1
- package/docs/development/basic/add-new-image-model.mdx +3 -3
- package/docs/development/basic/add-new-image-model.zh-CN.mdx +3 -3
- package/docs/development/basic/chat-api.mdx +10 -10
- package/docs/development/basic/chat-api.zh-CN.mdx +10 -10
- package/docs/development/basic/feature-development.mdx +4 -4
- package/docs/development/basic/feature-development.zh-CN.mdx +4 -4
- package/docs/development/basic/setup-development.mdx +4 -4
- package/docs/development/basic/setup-development.zh-CN.mdx +4 -4
- package/docs/development/internationalization/add-new-locale.mdx +1 -1
- package/docs/development/internationalization/add-new-locale.zh-CN.mdx +1 -1
- package/docs/development/internationalization/internationalization-implementation.mdx +5 -5
- package/docs/development/internationalization/internationalization-implementation.zh-CN.mdx +5 -5
- package/docs/development/others/lighthouse.mdx +8 -8
- package/docs/development/others/lighthouse.zh-CN.mdx +8 -8
- package/docs/development/start.mdx +3 -3
- package/docs/development/start.zh-CN.mdx +3 -3
- package/docs/self-hosting/advanced/feature-flags.mdx +1 -1
- package/docs/self-hosting/advanced/feature-flags.zh-CN.mdx +1 -1
- package/docs/self-hosting/advanced/knowledge-base.mdx +2 -2
- package/docs/self-hosting/advanced/knowledge-base.zh-CN.mdx +2 -2
- package/docs/self-hosting/advanced/online-search.mdx +1 -1
- package/docs/self-hosting/advanced/online-search.zh-CN.mdx +1 -1
- package/docs/self-hosting/advanced/redis/upstash.mdx +3 -3
- package/docs/self-hosting/advanced/redis/upstash.zh-CN.mdx +3 -3
- package/docs/self-hosting/advanced/redis.mdx +6 -6
- package/docs/self-hosting/advanced/redis.zh-CN.mdx +6 -6
- package/docs/self-hosting/advanced/s3/rustfs.mdx +116 -116
- package/docs/self-hosting/advanced/s3/rustfs.zh-CN.mdx +116 -117
- package/docs/self-hosting/advanced/upstream-sync.zh-CN.mdx +5 -5
- package/docs/self-hosting/auth/email.mdx +70 -0
- package/docs/self-hosting/auth/email.zh-CN.mdx +70 -0
- package/docs/self-hosting/{advanced/auth → auth}/legacy.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/legacy.zh-CN.mdx +5 -5
- package/docs/self-hosting/{advanced/auth → auth}/next-auth/casdoor.zh-CN.mdx +3 -3
- package/docs/self-hosting/{advanced/auth → auth}/next-auth/keycloak.zh-CN.mdx +2 -2
- package/docs/self-hosting/{advanced/auth → auth}/next-auth/logto.zh-CN.mdx +2 -2
- package/docs/self-hosting/{advanced/auth → auth}/providers/apple.mdx +6 -6
- package/docs/self-hosting/{advanced/auth → auth}/providers/apple.zh-CN.mdx +6 -6
- package/docs/self-hosting/{advanced/auth → auth}/providers/auth0.mdx +12 -12
- package/docs/self-hosting/{advanced/auth → auth}/providers/auth0.zh-CN.mdx +12 -12
- package/docs/self-hosting/{advanced/auth → auth}/providers/authelia.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/authelia.zh-CN.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/authentik.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/authentik.zh-CN.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/casdoor.mdx +8 -8
- package/docs/self-hosting/{advanced/auth → auth}/providers/casdoor.zh-CN.mdx +7 -7
- package/docs/self-hosting/{advanced/auth → auth}/providers/cloudflare-zero-trust.mdx +7 -7
- package/docs/self-hosting/{advanced/auth → auth}/providers/cloudflare-zero-trust.zh-CN.mdx +6 -6
- package/docs/self-hosting/{advanced/auth → auth}/providers/cognito.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/cognito.zh-CN.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/feishu.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/feishu.zh-CN.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/generic-oidc.mdx +12 -12
- package/docs/self-hosting/{advanced/auth → auth}/providers/generic-oidc.zh-CN.mdx +12 -12
- package/docs/self-hosting/{advanced/auth → auth}/providers/github.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/github.zh-CN.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/google.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/google.zh-CN.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/keycloak.mdx +11 -11
- package/docs/self-hosting/{advanced/auth → auth}/providers/keycloak.zh-CN.mdx +11 -11
- package/docs/self-hosting/{advanced/auth → auth}/providers/logto.mdx +8 -8
- package/docs/self-hosting/{advanced/auth → auth}/providers/logto.zh-CN.mdx +7 -7
- package/docs/self-hosting/{advanced/auth → auth}/providers/microsoft.mdx +11 -11
- package/docs/self-hosting/{advanced/auth → auth}/providers/microsoft.zh-CN.mdx +11 -11
- package/docs/self-hosting/{advanced/auth → auth}/providers/okta.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/okta.zh-CN.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/wechat.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/wechat.zh-CN.mdx +10 -10
- package/docs/self-hosting/{advanced/auth → auth}/providers/zitadel.mdx +13 -13
- package/docs/self-hosting/{advanced/auth → auth}/providers/zitadel.zh-CN.mdx +13 -13
- package/docs/self-hosting/{advanced/auth.mdx → auth.mdx} +12 -81
- package/docs/self-hosting/{advanced/auth.zh-CN.mdx → auth.zh-CN.mdx} +11 -80
- package/docs/self-hosting/environment-variables/redis.mdx +1 -1
- package/docs/self-hosting/environment-variables/redis.zh-CN.mdx +1 -1
- package/docs/self-hosting/environment-variables.mdx +1 -1
- package/docs/self-hosting/faq/no-v1-suffix.mdx +3 -3
- package/docs/self-hosting/faq/no-v1-suffix.zh-CN.mdx +3 -3
- package/docs/self-hosting/{advanced → migration/v2}/auth/clerk-to-betterauth.mdx +7 -7
- package/docs/self-hosting/{advanced → migration/v2}/auth/clerk-to-betterauth.zh-CN.mdx +7 -7
- package/docs/self-hosting/{advanced → migration/v2}/auth/migration-internals.mdx +2 -2
- package/docs/self-hosting/{advanced → migration/v2}/auth/migration-internals.zh-CN.mdx +2 -2
- package/docs/self-hosting/{advanced → migration/v2}/auth/nextauth-to-betterauth.mdx +11 -11
- package/docs/self-hosting/{advanced → migration/v2}/auth/nextauth-to-betterauth.zh-CN.mdx +11 -11
- package/docs/self-hosting/migration/v2/breaking-changes.mdx +1 -1
- package/docs/self-hosting/migration/v2/breaking-changes.zh-CN.mdx +1 -1
- package/docs/self-hosting/platform/docker-compose.zh-CN.mdx +4 -4
- package/docs/self-hosting/platform/docker.mdx +5 -5
- package/docs/self-hosting/platform/docker.zh-CN.mdx +10 -10
- package/docs/self-hosting/platform/dokploy.mdx +1 -1
- package/docs/self-hosting/platform/dokploy.zh-CN.mdx +5 -5
- package/docs/self-hosting/platform/sealos.mdx +12 -12
- package/docs/self-hosting/platform/sealos.zh-CN.mdx +17 -17
- package/docs/self-hosting/platform/vercel.zh-CN.mdx +4 -4
- package/docs/self-hosting/start.mdx +3 -3
- package/docs/self-hosting/start.zh-CN.mdx +4 -4
- package/locales/en-US/auth.json +1 -1
- package/locales/en-US/authError.json +1 -0
- package/locales/en-US/metadata.json +1 -1
- package/locales/zh-CN/authError.json +1 -0
- package/package.json +1 -1
- package/src/app/[variants]/(auth)/auth-error/page.tsx +4 -2
- package/src/app/[variants]/(auth)/signin/SignInEmailStep.tsx +1 -1
- package/src/app/[variants]/(auth)/signin/SignInPasswordStep.tsx +1 -1
- package/src/libs/better-auth/sso/providers/feishu.ts +15 -14
- package/src/libs/better-auth/sso/providers/wechat.ts +6 -3
- package/src/libs/next/proxy/define-config.ts +1 -0
- package/src/locales/default/auth.ts +1 -1
- package/src/locales/default/authError.ts +2 -0
- package/src/locales/default/metadata.ts +1 -1
- package/src/server/ld.ts +1 -1
- /package/docs/self-hosting/{advanced/auth → auth}/clerk.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/clerk.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/auth0.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/auth0.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/authelia.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/authelia.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/authentik.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/authentik.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/casdoor.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/cloudflare-zero-trust.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/cloudflare-zero-trust.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/github.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/github.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/google.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/google.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/keycloak.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/logto.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/microsoft-entra-id.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/microsoft-entra-id.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/okta.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/okta.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/wechat.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/wechat.zh-CN.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/zitadel.mdx +0 -0
- /package/docs/self-hosting/{advanced/auth → auth}/next-auth/zitadel.zh-CN.mdx +0 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,31 @@
|
|
|
2
2
|
|
|
3
3
|
# Changelog
|
|
4
4
|
|
|
5
|
+
### [Version 2.1.2](https://github.com/lobehub/lobe-chat/compare/v2.1.1...v2.1.2)
|
|
6
|
+
|
|
7
|
+
<sup>Released on **2026-01-30**</sup>
|
|
8
|
+
|
|
9
|
+
#### 🐛 Bug Fixes
|
|
10
|
+
|
|
11
|
+
- **misc**: Fix feishu sso provider.
|
|
12
|
+
|
|
13
|
+
<br/>
|
|
14
|
+
|
|
15
|
+
<details>
|
|
16
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
|
17
|
+
|
|
18
|
+
#### What's fixed
|
|
19
|
+
|
|
20
|
+
- **misc**: Fix feishu sso provider, closes [#11970](https://github.com/lobehub/lobe-chat/issues/11970) ([ffd9fff](https://github.com/lobehub/lobe-chat/commit/ffd9fff))
|
|
21
|
+
|
|
22
|
+
</details>
|
|
23
|
+
|
|
24
|
+
<div align="right">
|
|
25
|
+
|
|
26
|
+
[](#readme-top)
|
|
27
|
+
|
|
28
|
+
</div>
|
|
29
|
+
|
|
5
30
|
### [Version 2.1.1](https://github.com/lobehub/lobe-chat/compare/v2.1.0...v2.1.1)
|
|
6
31
|
|
|
7
32
|
<sup>Released on **2026-01-30**</sup>
|
package/README.md
CHANGED
|
@@ -37,7 +37,7 @@ We’re building the world’s largest human–agent co-evolving network.
|
|
|
37
37
|
[![][share-mastodon-shield]][share-mastodon-link]
|
|
38
38
|
[![][share-linkedin-shield]][share-linkedin-link]
|
|
39
39
|
|
|
40
|
-
<sup>Agent
|
|
40
|
+
<sup>Agent teammates that grow with you</sup>
|
|
41
41
|
|
|
42
42
|
[![][github-trending-shield]][github-trending-url]
|
|
43
43
|
|
package/README.zh-CN.md
CHANGED
|
@@ -35,7 +35,7 @@ LobeHub 是一个工作与生活空间,用于发现、构建并与会随着您
|
|
|
35
35
|
[![][share-weibo-shield]][share-weibo-link]
|
|
36
36
|
[![][share-mastodon-shield]][share-mastodon-link]
|
|
37
37
|
|
|
38
|
-
<sup>Agent
|
|
38
|
+
<sup>Agent teammates that grow with you</sup>
|
|
39
39
|
|
|
40
40
|
[![][github-trending-shield]][github-trending-url]
|
|
41
41
|
[![][github-hello-shield]][github-hello-url]
|
|
@@ -59,14 +59,14 @@ interface McpInstallParams {
|
|
|
59
59
|
*/
|
|
60
60
|
export default class McpInstallController extends ControllerModule {
|
|
61
61
|
/**
|
|
62
|
-
*
|
|
63
|
-
* @param parsedData
|
|
64
|
-
* @returns
|
|
62
|
+
* Handle MCP plugin installation request
|
|
63
|
+
* @param parsedData Parsed protocol data
|
|
64
|
+
* @returns Whether processing succeeded
|
|
65
65
|
*/
|
|
66
66
|
@protocolHandler('install')
|
|
67
67
|
public async handleInstallRequest(parsedData: McpInstallParams): Promise<boolean> {
|
|
68
68
|
try {
|
|
69
|
-
//
|
|
69
|
+
// Extract required fields from parameters
|
|
70
70
|
const { id, schema: schemaParam, marketId } = parsedData;
|
|
71
71
|
|
|
72
72
|
if (!id) {
|
|
@@ -76,11 +76,11 @@ export default class McpInstallController extends ControllerModule {
|
|
|
76
76
|
return false;
|
|
77
77
|
}
|
|
78
78
|
|
|
79
|
-
//
|
|
79
|
+
// Map protocol source
|
|
80
80
|
|
|
81
81
|
const isOfficialMarket = marketId === 'lobehub';
|
|
82
82
|
|
|
83
|
-
//
|
|
83
|
+
// For official marketplace, schema is optional; for third-party marketplace, schema is required
|
|
84
84
|
if (!isOfficialMarket && !schemaParam) {
|
|
85
85
|
logger.warn(`🔧 [McpInstall] Schema is required for third-party marketplace:`, {
|
|
86
86
|
marketId,
|
|
@@ -90,7 +90,7 @@ export default class McpInstallController extends ControllerModule {
|
|
|
90
90
|
|
|
91
91
|
let mcpSchema: McpSchema | undefined;
|
|
92
92
|
|
|
93
|
-
//
|
|
93
|
+
// If schema parameter is provided, parse and validate
|
|
94
94
|
if (schemaParam) {
|
|
95
95
|
try {
|
|
96
96
|
mcpSchema = JSON.parse(schemaParam);
|
|
@@ -104,7 +104,7 @@ export default class McpInstallController extends ControllerModule {
|
|
|
104
104
|
return false;
|
|
105
105
|
}
|
|
106
106
|
|
|
107
|
-
//
|
|
107
|
+
// Verify identifier matches id parameter
|
|
108
108
|
if (mcpSchema.identifier !== id) {
|
|
109
109
|
logger.error(`🔧 [McpInstall] Schema identifier does not match URL id parameter:`, {
|
|
110
110
|
schemaId: mcpSchema.identifier,
|
|
@@ -122,7 +122,7 @@ export default class McpInstallController extends ControllerModule {
|
|
|
122
122
|
pluginVersion: mcpSchema?.version || 'Unknown',
|
|
123
123
|
});
|
|
124
124
|
|
|
125
|
-
//
|
|
125
|
+
// Broadcast installation request to frontend
|
|
126
126
|
const installRequest = {
|
|
127
127
|
marketId,
|
|
128
128
|
pluginId: id,
|
|
@@ -136,7 +136,7 @@ export default class McpInstallController extends ControllerModule {
|
|
|
136
136
|
pluginName: installRequest.schema?.name || 'Unknown',
|
|
137
137
|
});
|
|
138
138
|
|
|
139
|
-
//
|
|
139
|
+
// Broadcast to frontend via app instance
|
|
140
140
|
if (this.app?.browserManager) {
|
|
141
141
|
this.app.browserManager.broadcastToWindow('app', 'mcpInstallRequest', installRequest);
|
|
142
142
|
logger.debug(`🔧 [McpInstall] Install request broadcasted successfully`);
|
|
@@ -88,7 +88,7 @@ export default class NetworkProxyCtr extends ControllerModule {
|
|
|
88
88
|
}
|
|
89
89
|
|
|
90
90
|
/**
|
|
91
|
-
*
|
|
91
|
+
* Test proxy connection
|
|
92
92
|
*/
|
|
93
93
|
@IpcMethod()
|
|
94
94
|
async testProxyConnection(url: string): Promise<{ message?: string; success: boolean }> {
|
|
@@ -108,7 +108,7 @@ export default class NetworkProxyCtr extends ControllerModule {
|
|
|
108
108
|
}
|
|
109
109
|
|
|
110
110
|
/**
|
|
111
|
-
*
|
|
111
|
+
* Test specified proxy configuration
|
|
112
112
|
*/
|
|
113
113
|
@IpcMethod()
|
|
114
114
|
async testProxyConfig({
|
|
@@ -131,17 +131,17 @@ export default class NetworkProxyCtr extends ControllerModule {
|
|
|
131
131
|
}
|
|
132
132
|
|
|
133
133
|
/**
|
|
134
|
-
*
|
|
134
|
+
* Apply initial proxy settings
|
|
135
135
|
*/
|
|
136
136
|
async beforeAppReady(): Promise<void> {
|
|
137
137
|
try {
|
|
138
|
-
//
|
|
138
|
+
// Get stored proxy settings
|
|
139
139
|
const networkProxy = this.app.storeManager.get(
|
|
140
140
|
'networkProxy',
|
|
141
141
|
defaultProxySettings,
|
|
142
142
|
) as NetworkProxySettings;
|
|
143
143
|
|
|
144
|
-
//
|
|
144
|
+
// Validate configuration
|
|
145
145
|
const validation = ProxyConfigValidator.validate(networkProxy);
|
|
146
146
|
if (!validation.isValid) {
|
|
147
147
|
logger.warn('Invalid stored proxy configuration, using defaults:', validation.errors);
|
|
@@ -158,7 +158,7 @@ export default class NetworkProxyCtr extends ControllerModule {
|
|
|
158
158
|
});
|
|
159
159
|
} catch (error) {
|
|
160
160
|
logger.error('Failed to apply initial proxy settings:', error);
|
|
161
|
-
//
|
|
161
|
+
// Use default settings on error
|
|
162
162
|
try {
|
|
163
163
|
await ProxyDispatcherManager.applyProxySettings(defaultProxySettings);
|
|
164
164
|
logger.info('Fallback to default proxy settings');
|
|
@@ -162,7 +162,7 @@ export default class RemoteServerSyncCtr extends ControllerModule {
|
|
|
162
162
|
});
|
|
163
163
|
});
|
|
164
164
|
|
|
165
|
-
// 5.
|
|
165
|
+
// 5. Listen for request errors (e.g., DNS resolution failure)
|
|
166
166
|
clientReq.on('error', (error) => {
|
|
167
167
|
logger.error(`${logPrefix} Error forwarding request:`, error);
|
|
168
168
|
if (sender.isDestroyed()) return;
|
|
@@ -196,7 +196,7 @@ export default class RemoteServerSyncCtr extends ControllerModule {
|
|
|
196
196
|
delete requestHeaders['connection']; // Often causes issues
|
|
197
197
|
// delete requestHeaders['content-length']; // Let node handle it based on body
|
|
198
198
|
|
|
199
|
-
//
|
|
199
|
+
// Read proxy configuration
|
|
200
200
|
const proxyConfig = this.app.storeManager.get('networkProxy', defaultProxySettings);
|
|
201
201
|
|
|
202
202
|
let agent;
|
package/changelog/v2.json
CHANGED
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# Seamless DeepSeek R1 Integration, Unlock a New Chain-of-Thought Experience
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
LobeHub completed its largest AI ecosystem expansion ever in February, delivering a more powerful and flexible AI chat experience.
|
|
13
13
|
|
|
14
14
|
## 🌟 Major Updates
|
|
15
15
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# Seamless DeepSeek R1 Integration, Unlock a New Chain-of-Thought Experience
|
|
11
11
|
|
|
12
|
-
In March,
|
|
12
|
+
In March, LobeHub continued to refine the user experience—adding practical features like customizable hotkeys and data export, while further expanding the AI provider ecosystem.
|
|
13
13
|
|
|
14
14
|
## 🌟 Key Updates
|
|
15
15
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Brand-New Design Style and Desktop App Release ✨
|
|
3
|
-
description:
|
|
3
|
+
description: LobeHub officially launches the desktop app, delivering a more modern and smoother experience.
|
|
4
4
|
tags:
|
|
5
5
|
- Desktop App
|
|
6
6
|
- LobeHub
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# Brand-New Design Style and Desktop App Release ✨
|
|
11
11
|
|
|
12
|
-
In April,
|
|
12
|
+
In April, LobeHub shipped a major visual upgrade with the brand-new Lobe UI v2 design system, and officially released the desktop app—bringing a more modern and fluid experience.
|
|
13
13
|
|
|
14
14
|
## 🌟 Major Updates
|
|
15
15
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: 全新设计风格与桌面端发布 ✨
|
|
3
|
-
description:
|
|
3
|
+
description: LobeHub 正式发布桌面端应用,带来更现代、更流畅的使用体验
|
|
4
4
|
tags:
|
|
5
5
|
- 桌面端
|
|
6
6
|
- LobeHub
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# 全新设计风格与桌面端发布 ✨
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
LobeHub 在四月完成重大视觉升级,推出全新 Lobe UI v2 设计系统,并正式发布桌面端应用,带来更现代、更流畅的使用体验。
|
|
13
13
|
|
|
14
14
|
## 🌟 重大更新
|
|
15
15
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# Prompt Variables and Claude 4 Reasoning Model Support 🚀
|
|
11
11
|
|
|
12
|
-
From May to June,
|
|
12
|
+
From May to June, LobeHub continued to refine core capabilities—introducing a prompt-variables system, adding support for Claude 4 reasoning models, and expanding search and crawling across multiple AI providers.
|
|
13
13
|
|
|
14
14
|
## 🌟 Key Updates
|
|
15
15
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# MCP Marketplace and Search Provider Expansion 🔍
|
|
11
11
|
|
|
12
|
-
From June to July,
|
|
12
|
+
From June to July, LobeHub launched the MCP plugin marketplace, added support for multiple search providers, and integrated Amazon Cognito and Google SSO—continuing to improve both user experience and the developer ecosystem.
|
|
13
13
|
|
|
14
14
|
## 🌟 Major Updates
|
|
15
15
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# AI Image Generation and Desktop Enhancements 🎨
|
|
11
11
|
|
|
12
|
-
From July to August,
|
|
12
|
+
From July to August, LobeHub introduced AI image generation, added support for multiple providers, and continued improving the desktop experience and authentication system.
|
|
13
13
|
|
|
14
14
|
## 🌟 Major Updates
|
|
15
15
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# Gemini Image Generation and Non-Streaming Mode Support 🎨
|
|
11
11
|
|
|
12
|
-
From August to September,
|
|
12
|
+
From August to September, LobeHub added Gemini 2.5 Flash Image generation, introduced non-streaming response mode support, and expanded provider and model support across the ecosystem.
|
|
13
13
|
|
|
14
14
|
## 🌟 Major Updates
|
|
15
15
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# Claude Sonnet 4.5 and Built-in Python Plugin 🐍
|
|
11
11
|
|
|
12
|
-
From September to October,
|
|
12
|
+
From September to October, LobeHub added support for Claude Sonnet 4.5, introduced a built-in Python plugin, and improved chat list navigation and rich text editing.
|
|
13
13
|
|
|
14
14
|
## 🌟 Key Updates
|
|
15
15
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# ComfyUI Integration and Knowledge Base Improvements ⭐
|
|
11
11
|
|
|
12
|
-
From October to November,
|
|
12
|
+
From October to November, LobeHub integrated ComfyUI workflows, added support for multiple AI providers and models, and continued to improve the knowledge base and overall user experience.
|
|
13
13
|
|
|
14
14
|
## 🌟 Key Updates
|
|
15
15
|
|
|
@@ -10,7 +10,7 @@ tags:
|
|
|
10
10
|
|
|
11
11
|
# MCP Cloud Endpoints and Model Library Expansion 🔌
|
|
12
12
|
|
|
13
|
-
In November,
|
|
13
|
+
In November, LobeHub continued to improve model support and user experience by adding multiple AI providers and enhancing knowledge base capabilities.
|
|
14
14
|
|
|
15
15
|
## 🌟 Key Updates
|
|
16
16
|
|
|
@@ -12,7 +12,7 @@ tags:
|
|
|
12
12
|
|
|
13
13
|
LobeHub 使用 [Auth.js v5](https://authjs.dev/) 作为外部身份验证服务。Auth.js 是一个开源的身份验证库,它提供了一种简单的方式来实现身份验证和授权功能。本文档将介绍如何使用 Auth.js 来实现新的身份验证方式。
|
|
14
14
|
|
|
15
|
-
|
|
15
|
+
LobeHub 使用 [Better Auth](https://www.better-auth.com) 作为身份验证服务。本文档介绍如何添加新的 SSO 身份验证提供商。
|
|
16
16
|
|
|
17
17
|
为了在 LobeHub 中添加新的身份验证提供者(例如添加 Okta),你需要完成以下步骤:
|
|
18
18
|
|
|
@@ -11,7 +11,7 @@ tags:
|
|
|
11
11
|
|
|
12
12
|
# Adding New Image Models
|
|
13
13
|
|
|
14
|
-
> Learn more about the AI image generation modal design in the [AI Image Generation Modal Design Discussion](https://github.com/lobehub/
|
|
14
|
+
> Learn more about the AI image generation modal design in the [AI Image Generation Modal Design Discussion](https://github.com/lobehub/lobehub/discussions/7442)
|
|
15
15
|
|
|
16
16
|
## Parameter Standardization
|
|
17
17
|
|
|
@@ -65,7 +65,7 @@ For image generation models that are not compatible with OpenAI format, you need
|
|
|
65
65
|
|
|
66
66
|
### Method 1: Using OpenAI Compatible Factory
|
|
67
67
|
|
|
68
|
-
Most Providers use `openaiCompatibleFactory` for OpenAI compatibility. You can pass in a custom `createImage` function (reference [PR #8534](https://github.com/lobehub/
|
|
68
|
+
Most Providers use `openaiCompatibleFactory` for OpenAI compatibility. You can pass in a custom `createImage` function (reference [PR #8534](https://github.com/lobehub/lobehub/pull/8534)).
|
|
69
69
|
|
|
70
70
|
**Implementation Steps**:
|
|
71
71
|
|
|
@@ -124,7 +124,7 @@ export const LobeProviderAI = openaiCompatibleFactory({
|
|
|
124
124
|
|
|
125
125
|
### Method 2: Direct Implementation in Provider Class
|
|
126
126
|
|
|
127
|
-
If your Provider has an independent class implementation, you can directly add the `createImage` method in the class (reference [PR #8503](https://github.com/lobehub/
|
|
127
|
+
If your Provider has an independent class implementation, you can directly add the `createImage` method in the class (reference [PR #8503](https://github.com/lobehub/lobehub/pull/8503)).
|
|
128
128
|
|
|
129
129
|
**Implementation Steps**:
|
|
130
130
|
|
|
@@ -9,7 +9,7 @@ tags:
|
|
|
9
9
|
|
|
10
10
|
# 添加新的图像模型
|
|
11
11
|
|
|
12
|
-
> 了解更多关于 AI 绘画模态的设计,请参考 [AI 绘画模态设计讨论](https://github.com/lobehub/
|
|
12
|
+
> 了解更多关于 AI 绘画模态的设计,请参考 [AI 绘画模态设计讨论](https://github.com/lobehub/lobehub/discussions/7442)
|
|
13
13
|
|
|
14
14
|
## 参数标准化
|
|
15
15
|
|
|
@@ -63,7 +63,7 @@ const zhipuImageModels: AIImageModelCard[] = [
|
|
|
63
63
|
|
|
64
64
|
### 方式一:使用 OpenAI Compatible Factory
|
|
65
65
|
|
|
66
|
-
大部分 Provider 都使用 `openaiCompatibleFactory` 来兼容 OpenAI,可以通过传入自定义的 `createImage` 函数(参考 [PR #8534](https://github.com/lobehub/
|
|
66
|
+
大部分 Provider 都使用 `openaiCompatibleFactory` 来兼容 OpenAI,可以通过传入自定义的 `createImage` 函数(参考 [PR #8534](https://github.com/lobehub/lobehub/pull/8534))。
|
|
67
67
|
|
|
68
68
|
**实现步骤**:
|
|
69
69
|
|
|
@@ -122,7 +122,7 @@ export const LobeProviderAI = openaiCompatibleFactory({
|
|
|
122
122
|
|
|
123
123
|
### 方式二:在 Provider 类中直接实现
|
|
124
124
|
|
|
125
|
-
如果你的 Provider 有独立的类实现,可以直接在类中添加 `createImage` 方法(参考 [PR #8503](https://github.com/lobehub/
|
|
125
|
+
如果你的 Provider 有独立的类实现,可以直接在类中添加 `createImage` 方法(参考 [PR #8503](https://github.com/lobehub/lobehub/pull/8503))。
|
|
126
126
|
|
|
127
127
|
**实现步骤**:
|
|
128
128
|
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
---
|
|
2
|
-
title:
|
|
2
|
+
title: LobeHub API Client-Server Interaction Logic
|
|
3
3
|
description: >-
|
|
4
|
-
Explore the client-server interaction logic of
|
|
4
|
+
Explore the client-server interaction logic of LobeHub API, including event
|
|
5
5
|
sequences.
|
|
6
6
|
tags:
|
|
7
|
-
-
|
|
7
|
+
- LobeHub API
|
|
8
8
|
- Client-Server Interaction
|
|
9
9
|
- Event Sequences
|
|
10
10
|
- API Logic
|
|
11
11
|
---
|
|
12
12
|
|
|
13
|
-
#
|
|
13
|
+
# LobeHub API Client-Server Interaction Logic
|
|
14
14
|
|
|
15
|
-
This document explains the implementation logic of
|
|
15
|
+
This document explains the implementation logic of LobeHub API in client-server interactions, including event sequences and core components involved.
|
|
16
16
|
|
|
17
17
|
## Interaction Sequence Diagram
|
|
18
18
|
|
|
@@ -201,7 +201,7 @@ sequenceDiagram
|
|
|
201
201
|
|
|
202
202
|
## AgentRuntime Overview
|
|
203
203
|
|
|
204
|
-
AgentRuntime is a core abstraction layer in
|
|
204
|
+
AgentRuntime is a core abstraction layer in LobeHub that encapsulates a unified interface for interacting with different AI model providers. Its main responsibilities and features include:
|
|
205
205
|
|
|
206
206
|
1. **Unified Abstraction Layer**: AgentRuntime provides a unified interface that hides the implementation details and differences between various AI provider APIs (such as OpenAI, Anthropic, Bedrock, etc.).
|
|
207
207
|
|
|
@@ -244,7 +244,7 @@ AgentRuntime is a core abstraction layer in Lobe Chat that encapsulates a unifie
|
|
|
244
244
|
|
|
245
245
|
**Adapter Implementation Examples**:
|
|
246
246
|
|
|
247
|
-
1. **OpenRouter Adapter**: OpenRouter is a unified API that allows access to AI models from multiple providers.
|
|
247
|
+
1. **OpenRouter Adapter**: OpenRouter is a unified API that allows access to AI models from multiple providers. LobeHub implements support for OpenRouter through an adapter:
|
|
248
248
|
|
|
249
249
|
```ts
|
|
250
250
|
// OpenRouter adapter implementation
|
|
@@ -258,7 +258,7 @@ AgentRuntime is a core abstraction layer in Lobe Chat that encapsulates a unifie
|
|
|
258
258
|
apiKey: options.apiKey,
|
|
259
259
|
baseURL: OPENROUTER_BASE_URL,
|
|
260
260
|
defaultHeaders: {
|
|
261
|
-
'HTTP-Referer': 'https://github.com/lobehub/
|
|
261
|
+
'HTTP-Referer': 'https://github.com/lobehub/lobehub',
|
|
262
262
|
'X-Title': 'LobeHub',
|
|
263
263
|
},
|
|
264
264
|
});
|
|
@@ -267,7 +267,7 @@ AgentRuntime is a core abstraction layer in Lobe Chat that encapsulates a unifie
|
|
|
267
267
|
|
|
268
268
|
// Implement chat functionality
|
|
269
269
|
async chat(payload: ChatCompletionCreateParamsBase, options?: RequestOptions) {
|
|
270
|
-
// Convert
|
|
270
|
+
// Convert LobeHub request format to OpenRouter format
|
|
271
271
|
// Handle model mapping, message format, etc.
|
|
272
272
|
return this.client.chat.completions.create(
|
|
273
273
|
{
|
|
@@ -282,7 +282,7 @@ AgentRuntime is a core abstraction layer in Lobe Chat that encapsulates a unifie
|
|
|
282
282
|
}
|
|
283
283
|
```
|
|
284
284
|
|
|
285
|
-
2. **Google Gemini Adapter**: Gemini is Google's large language model.
|
|
285
|
+
2. **Google Gemini Adapter**: Gemini is Google's large language model. LobeHub supports Gemini series models through a dedicated adapter:
|
|
286
286
|
|
|
287
287
|
```ts
|
|
288
288
|
import { GoogleGenerativeAI } from '@google/generative-ai';
|
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
---
|
|
2
|
-
title:
|
|
3
|
-
description: 深入了解
|
|
2
|
+
title: LobeHub API 前后端交互逻辑
|
|
3
|
+
description: 深入了解 LobeHub API 的前后端交互实现逻辑和核心组件。
|
|
4
4
|
tags:
|
|
5
|
-
-
|
|
5
|
+
- LobeHub API
|
|
6
6
|
- 前后端交互
|
|
7
7
|
- 事件序列
|
|
8
8
|
- 核心组件
|
|
9
9
|
---
|
|
10
10
|
|
|
11
|
-
#
|
|
11
|
+
# LobeHub API 前后端交互逻辑
|
|
12
12
|
|
|
13
|
-
本文档说明了
|
|
13
|
+
本文档说明了 LobeHub API 在前后端交互中的实现逻辑,包括事件序列和涉及的核心组件。
|
|
14
14
|
|
|
15
15
|
## 交互时序图
|
|
16
16
|
|
|
@@ -199,7 +199,7 @@ sequenceDiagram
|
|
|
199
199
|
|
|
200
200
|
## AgentRuntime 说明
|
|
201
201
|
|
|
202
|
-
AgentRuntime 是
|
|
202
|
+
AgentRuntime 是 LobeHub 中的一个核心抽象层,它封装了与不同 AI 模型提供商交互的统一接口。其主要职责和特点包括:
|
|
203
203
|
|
|
204
204
|
1. **统一抽象层**:AgentRuntime 提供了一个统一的接口,隐藏了不同 AI 提供商 API 的实现细节差异(如 OpenAI、Anthropic、Bedrock 等)。
|
|
205
205
|
|
|
@@ -242,7 +242,7 @@ AgentRuntime 是 Lobe Chat 中的一个核心抽象层,它封装了与不同 A
|
|
|
242
242
|
|
|
243
243
|
**适配器实现示例**:
|
|
244
244
|
|
|
245
|
-
1. **OpenRouter 适配器**:OpenRouter 是一个统一 API,可以通过它访问多个模型提供商的 AI 模型。
|
|
245
|
+
1. **OpenRouter 适配器**:OpenRouter 是一个统一 API,可以通过它访问多个模型提供商的 AI 模型。LobeHub 通过适配器实现对 OpenRouter 的支持:
|
|
246
246
|
|
|
247
247
|
```ts
|
|
248
248
|
// OpenRouter 适配器实现
|
|
@@ -256,7 +256,7 @@ AgentRuntime 是 Lobe Chat 中的一个核心抽象层,它封装了与不同 A
|
|
|
256
256
|
apiKey: options.apiKey,
|
|
257
257
|
baseURL: OPENROUTER_BASE_URL,
|
|
258
258
|
defaultHeaders: {
|
|
259
|
-
'HTTP-Referer': 'https://github.com/lobehub/
|
|
259
|
+
'HTTP-Referer': 'https://github.com/lobehub/lobehub',
|
|
260
260
|
'X-Title': 'LobeHub',
|
|
261
261
|
},
|
|
262
262
|
});
|
|
@@ -265,7 +265,7 @@ AgentRuntime 是 Lobe Chat 中的一个核心抽象层,它封装了与不同 A
|
|
|
265
265
|
|
|
266
266
|
// 实现聊天功能
|
|
267
267
|
async chat(payload: ChatCompletionCreateParamsBase, options?: RequestOptions) {
|
|
268
|
-
// 将
|
|
268
|
+
// 将 LobeHub 的请求格式转换为 OpenRouter 格式
|
|
269
269
|
// 处理模型映射、消息格式等
|
|
270
270
|
return this.client.chat.completions.create(
|
|
271
271
|
{
|
|
@@ -280,7 +280,7 @@ AgentRuntime 是 Lobe Chat 中的一个核心抽象层,它封装了与不同 A
|
|
|
280
280
|
}
|
|
281
281
|
```
|
|
282
282
|
|
|
283
|
-
2. **Google Gemini 适配器**:Gemini 是 Google 的大语言模型,
|
|
283
|
+
2. **Google Gemini 适配器**:Gemini 是 Google 的大语言模型,LobeHub 通过专门的适配器支持 Gemini 系列模型:
|
|
284
284
|
|
|
285
285
|
```ts
|
|
286
286
|
import { GoogleGenerativeAI } from '@google/generative-ai';
|