@lobehub/chat 1.35.5 → 1.35.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/CHANGELOG.md +50 -0
- package/README.md +3 -3
- package/README.zh-CN.md +3 -3
- package/changelog/v1.json +14 -0
- package/package.json +2 -1
- package/src/config/modelProviders/huggingface.ts +6 -0
- package/src/database/server/models/user.ts +33 -1
package/CHANGELOG.md
CHANGED
@@ -2,6 +2,56 @@
|
|
2
2
|
|
3
3
|
# Changelog
|
4
4
|
|
5
|
+
### [Version 1.35.7](https://github.com/lobehub/lobe-chat/compare/v1.35.6...v1.35.7)
|
6
|
+
|
7
|
+
<sup>Released on **2024-12-03**</sup>
|
8
|
+
|
9
|
+
<br/>
|
10
|
+
|
11
|
+
<details>
|
12
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
13
|
+
|
14
|
+
</details>
|
15
|
+
|
16
|
+
<div align="right">
|
17
|
+
|
18
|
+
[](#readme-top)
|
19
|
+
|
20
|
+
</div>
|
21
|
+
|
22
|
+
### [Version 1.35.6](https://github.com/lobehub/lobe-chat/compare/v1.35.5...v1.35.6)
|
23
|
+
|
24
|
+
<sup>Released on **2024-12-02**</sup>
|
25
|
+
|
26
|
+
#### ♻ Code Refactoring
|
27
|
+
|
28
|
+
- **misc**: Add user server api key method in the server mode.
|
29
|
+
|
30
|
+
#### 💄 Styles
|
31
|
+
|
32
|
+
- **misc**: Add QwQ 32B Preview model.
|
33
|
+
|
34
|
+
<br/>
|
35
|
+
|
36
|
+
<details>
|
37
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
38
|
+
|
39
|
+
#### Code refactoring
|
40
|
+
|
41
|
+
- **misc**: Add user server api key method in the server mode, closes [#4870](https://github.com/lobehub/lobe-chat/issues/4870) ([875463a](https://github.com/lobehub/lobe-chat/commit/875463a))
|
42
|
+
|
43
|
+
#### Styles
|
44
|
+
|
45
|
+
- **misc**: Add QwQ 32B Preview model, closes [#4867](https://github.com/lobehub/lobe-chat/issues/4867) ([edd93e0](https://github.com/lobehub/lobe-chat/commit/edd93e0))
|
46
|
+
|
47
|
+
</details>
|
48
|
+
|
49
|
+
<div align="right">
|
50
|
+
|
51
|
+
[](#readme-top)
|
52
|
+
|
53
|
+
</div>
|
54
|
+
|
5
55
|
### [Version 1.35.5](https://github.com/lobehub/lobe-chat/compare/v1.35.4...v1.35.5)
|
6
56
|
|
7
57
|
<sup>Released on **2024-12-02**</sup>
|
package/README.md
CHANGED
@@ -287,12 +287,12 @@ Our marketplace is not just a showcase platform but also a collaborative space.
|
|
287
287
|
|
288
288
|
| Recent Submits | Description |
|
289
289
|
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
290
|
+
| [Daily Doctor](https://chat-preview.lobehub.com/market?agent=yunchat-docter)<br/><sup>By **[yuyun2000](https://github.com/yuyun2000)** on **2024-11-30**</sup> | Specializes in surgical diagnosis and personalized health management<br/>`general-medicine` `surgery` `health-consultation` `personalized-treatment` `medical-education` |
|
291
|
+
| [Python Artisan](https://chat-preview.lobehub.com/market?agent=yunchat)<br/><sup>By **[yuyun2000](https://github.com/yuyun2000)** on **2024-11-30**</sup> | Expert in Python development and deep learning, skilled in tool selection and code optimization<br/>`python-development` `deep-learning` `code-optimization` `security-review` `project-planning` |
|
290
292
|
| [AI Assistant for Course Content and Teaching Guidelines](https://chat-preview.lobehub.com/market?agent=course-prep-teaching-guide-ai)<br/><sup>By **[HNaga](https://github.com/HNaga)** on **2024-11-29**</sup> | This AI assistant is designed to help educators and instructors prepare comprehensive course content and provide practical teaching guidelines. It leverages advanced NLP capabilities to generate lesson plans, suggest engaging teaching strategies, and offer insights into educational best practices.<br/>`education` `teaching` `course-design` `content-creation` `ai-assistance` `curriculum-development` `instructional-design` |
|
291
293
|
| [Backend Development Assistant](https://chat-preview.lobehub.com/market?agent=backend-assistant)<br/><sup>By **[zeno980](https://github.com/zeno980)** on **2024-11-26**</sup> | Skilled in backend development tasks<br/>`backend-development` `ai-technology` `web-applications` `spring` `sql` |
|
292
|
-
| [Bilingual Dictionary Expert](https://chat-preview.lobehub.com/market?agent=english-chinese-dictionary-expert)<br/><sup>By **[swarfte](https://github.com/swarfte)** on **2024-11-26**</sup> | Expert in bilingual English-Chinese vocabulary translation and analysis<br/>`translation` `language-learning` `vocabulary` `dictionary` |
|
293
|
-
| [SSC Incremental](https://chat-preview.lobehub.com/market?agent=great-for-analysis-coding-and-rubber-ducking)<br/><sup>By **[Base03](https://github.com/Base03)** on **2024-11-26**</sup> | Claude minus the Reddit<br/>`technology` `analysis` `software` `ai` `research` |
|
294
294
|
|
295
|
-
> 📊 Total agents: [<kbd>**
|
295
|
+
> 📊 Total agents: [<kbd>**450**</kbd> ](https://github.com/lobehub/lobe-chat-agents)
|
296
296
|
|
297
297
|
<!-- AGENT LIST -->
|
298
298
|
|
package/README.zh-CN.md
CHANGED
@@ -276,12 +276,12 @@ LobeChat 的插件生态系统是其核心功能的重要扩展,它极大地
|
|
276
276
|
|
277
277
|
| 最近新增 | 助手说明 |
|
278
278
|
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
279
|
+
| [日常医生](https://chat-preview.lobehub.com/market?agent=yunchat-docter)<br/><sup>By **[yuyun2000](https://github.com/yuyun2000)** on **2024-11-30**</sup> | 擅长外科诊疗与个性化健康管理<br/>`全科医学` `外科` `健康咨询` `个性化治疗` `医学教育` |
|
280
|
+
| [Python 智匠](https://chat-preview.lobehub.com/market?agent=yunchat)<br/><sup>By **[yuyun2000](https://github.com/yuyun2000)** on **2024-11-30**</sup> | 精通 Python 开发与深度学习,擅长工具选择与代码优化<br/>`python开发` `深度学习` `代码优化` `安全审查` `项目规划` |
|
279
281
|
| [课程内容和教学指南的 AI 助手](https://chat-preview.lobehub.com/market?agent=course-prep-teaching-guide-ai)<br/><sup>By **[HNaga](https://github.com/HNaga)** on **2024-11-29**</sup> | 这个 AI 助手旨在帮助教育工作者和讲师准备全面的课程内容并提供实用的教学指南。它利用先进的自然语言处理能力生成课程计划,建议引人入胜的教学策略,并提供教育最佳实践的见解。<br/>`教育` `教学` `课程设计` `内容创作` `人工智能助手` `课程开发` `教学设计` |
|
280
282
|
| [后端开发助手](https://chat-preview.lobehub.com/market?agent=backend-assistant)<br/><sup>By **[zeno980](https://github.com/zeno980)** on **2024-11-26**</sup> | 擅长后端开发任务<br/>`后端开发` `ai技术` `web应用` `spring` `sql` |
|
281
|
-
| [双语词典专家](https://chat-preview.lobehub.com/market?agent=english-chinese-dictionary-expert)<br/><sup>By **[swarfte](https://github.com/swarfte)** on **2024-11-26**</sup> | 双语英语 - 中文词汇翻译和分析专家<br/>`翻译` `语言学习` `词汇` `词典` |
|
282
|
-
| [SSC 增量](https://chat-preview.lobehub.com/market?agent=great-for-analysis-coding-and-rubber-ducking)<br/><sup>By **[Base03](https://github.com/Base03)** on **2024-11-26**</sup> | Claude 减去 Reddit<br/>`技术` `分析` `软件` `人工智能` `研究` |
|
283
283
|
|
284
|
-
> 📊 Total agents: [<kbd>**
|
284
|
+
> 📊 Total agents: [<kbd>**450**</kbd> ](https://github.com/lobehub/lobe-chat-agents)
|
285
285
|
|
286
286
|
<!-- AGENT LIST -->
|
287
287
|
|
package/changelog/v1.json
CHANGED
@@ -1,4 +1,18 @@
|
|
1
1
|
[
|
2
|
+
{
|
3
|
+
"children": {},
|
4
|
+
"date": "2024-12-03",
|
5
|
+
"version": "1.35.7"
|
6
|
+
},
|
7
|
+
{
|
8
|
+
"children": {
|
9
|
+
"improvements": [
|
10
|
+
"Add QwQ 32B Preview model."
|
11
|
+
]
|
12
|
+
},
|
13
|
+
"date": "2024-12-02",
|
14
|
+
"version": "1.35.6"
|
15
|
+
},
|
2
16
|
{
|
3
17
|
"children": {
|
4
18
|
"improvements": [
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@lobehub/chat",
|
3
|
-
"version": "1.35.
|
3
|
+
"version": "1.35.7",
|
4
4
|
"description": "Lobe Chat - an open-source, high-performance chatbot 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",
|
@@ -236,6 +236,7 @@
|
|
236
236
|
"zustand-utils": "^1.3.2"
|
237
237
|
},
|
238
238
|
"devDependencies": {
|
239
|
+
"@browserbasehq/stagehand": "1.3.0",
|
239
240
|
"@commitlint/cli": "^19.5.0",
|
240
241
|
"@edge-runtime/vm": "^4.0.3",
|
241
242
|
"@huggingface/tasks": "^0.12.22",
|
@@ -27,6 +27,12 @@ const HuggingFace: ModelProviderCard = {
|
|
27
27
|
id: 'Qwen/Qwen2.5-Coder-32B-Instruct',
|
28
28
|
tokens: 32_768,
|
29
29
|
},
|
30
|
+
{
|
31
|
+
description: 'Qwen QwQ 是由 Qwen 团队开发的实验研究模型,专注于提升AI推理能力。',
|
32
|
+
displayName: 'QwQ 32B Preview',
|
33
|
+
id: 'Qwen/QwQ-32B-Preview',
|
34
|
+
tokens: 32_768,
|
35
|
+
},
|
30
36
|
{
|
31
37
|
displayName: 'Phi 3.5 mini instruct',
|
32
38
|
id: 'microsoft/Phi-3.5-mini-instruct',
|
@@ -5,7 +5,7 @@ import { DeepPartial } from 'utility-types';
|
|
5
5
|
import { serverDB } from '@/database/server/core/db';
|
6
6
|
import { KeyVaultsGateKeeper } from '@/server/modules/KeyVaultsEncrypt';
|
7
7
|
import { UserGuide, UserPreference } from '@/types/user';
|
8
|
-
import { UserSettings } from '@/types/user/settings';
|
8
|
+
import { UserKeyVaults, UserSettings } from '@/types/user/settings';
|
9
9
|
import { merge } from '@/utils/merge';
|
10
10
|
|
11
11
|
import { NewUser, UserItem, userSettings, users } from '../schemas/lobechat';
|
@@ -105,6 +105,38 @@ export class UserModel {
|
|
105
105
|
};
|
106
106
|
};
|
107
107
|
|
108
|
+
static getUserApiKeys = async (id: string) => {
|
109
|
+
const result = await serverDB
|
110
|
+
.select({
|
111
|
+
settingsKeyVaults: userSettings.keyVaults,
|
112
|
+
})
|
113
|
+
.from(userSettings)
|
114
|
+
.where(eq(userSettings.id, id));
|
115
|
+
|
116
|
+
if (!result || !result[0]) {
|
117
|
+
throw new UserNotFoundError();
|
118
|
+
}
|
119
|
+
|
120
|
+
const state = result[0];
|
121
|
+
|
122
|
+
// Decrypt keyVaults
|
123
|
+
let decryptKeyVaults = {};
|
124
|
+
if (state.settingsKeyVaults) {
|
125
|
+
const gateKeeper = await KeyVaultsGateKeeper.initWithEnvKey();
|
126
|
+
const { wasAuthentic, plaintext } = await gateKeeper.decrypt(state.settingsKeyVaults);
|
127
|
+
|
128
|
+
if (wasAuthentic) {
|
129
|
+
try {
|
130
|
+
decryptKeyVaults = JSON.parse(plaintext);
|
131
|
+
} catch (e) {
|
132
|
+
console.error(`Failed to parse keyVaults ,userId: ${id}. Error:`, e);
|
133
|
+
}
|
134
|
+
}
|
135
|
+
}
|
136
|
+
|
137
|
+
return decryptKeyVaults as UserKeyVaults;
|
138
|
+
};
|
139
|
+
|
108
140
|
async updateUser(id: string, value: Partial<UserItem>) {
|
109
141
|
return serverDB
|
110
142
|
.update(users)
|