@lobehub/lobehub 2.0.0-next.1 → 2.0.0-next.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 +27 -0
- package/changelog/v1.json +9 -0
- package/package.json +1 -1
- package/packages/model-runtime/src/core/openaiCompatibleFactory/createImage.ts +1 -1
- package/packages/model-runtime/src/core/openaiCompatibleFactory/index.test.ts +33 -3
- package/src/app/(backend)/oidc/consent/route.ts +0 -1
- package/src/features/AgentSetting/AgentPlugin/index.tsx +20 -12
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,33 @@
|
|
|
2
2
|
|
|
3
3
|
# Changelog
|
|
4
4
|
|
|
5
|
+
## [Version 2.0.0-next.2](https://github.com/lobehub/lobe-chat/compare/v2.0.0-next.1...v2.0.0-next.2)
|
|
6
|
+
|
|
7
|
+
<sup>Released on **2025-10-30**</sup>
|
|
8
|
+
|
|
9
|
+
#### 🐛 Bug Fixes
|
|
10
|
+
|
|
11
|
+
- **misc**: Hide marketplace link from Plugin List when market disabled, OIDC error when connecting to self-host instance, only include input_fidelity parameter for gpt-image-1..
|
|
12
|
+
|
|
13
|
+
<br/>
|
|
14
|
+
|
|
15
|
+
<details>
|
|
16
|
+
<summary><kbd>Improvements and Fixes</kbd></summary>
|
|
17
|
+
|
|
18
|
+
#### What's fixed
|
|
19
|
+
|
|
20
|
+
- **misc**: Hide marketplace link from Plugin List when market disabled, closes [#9929](https://github.com/lobehub/lobe-chat/issues/9929) ([e303979](https://github.com/lobehub/lobe-chat/commit/e303979))
|
|
21
|
+
- **misc**: OIDC error when connecting to self-host instance, closes [#9916](https://github.com/lobehub/lobe-chat/issues/9916) ([7a2ca19](https://github.com/lobehub/lobe-chat/commit/7a2ca19))
|
|
22
|
+
- **misc**: Only include input_fidelity parameter for gpt-image-1., closes [#9920](https://github.com/lobehub/lobe-chat/issues/9920) ([65dbc63](https://github.com/lobehub/lobe-chat/commit/65dbc63))
|
|
23
|
+
|
|
24
|
+
</details>
|
|
25
|
+
|
|
26
|
+
<div align="right">
|
|
27
|
+
|
|
28
|
+
[](#readme-top)
|
|
29
|
+
|
|
30
|
+
</div>
|
|
31
|
+
|
|
5
32
|
## [Version 2.0.0-next.1](https://github.com/lobehub/lobe-chat/compare/v1.143.0-next.2...v2.0.0-next.1)
|
|
6
33
|
|
|
7
34
|
<sup>Released on **2025-10-30**</sup>
|
package/changelog/v1.json
CHANGED
|
@@ -1,4 +1,13 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"children": {
|
|
4
|
+
"fixes": [
|
|
5
|
+
"Hide marketplace link from Plugin List when market disabled, OIDC error when connecting to self-host instance, only include input_fidelity parameter for gpt-image-1.."
|
|
6
|
+
]
|
|
7
|
+
},
|
|
8
|
+
"date": "2025-10-30",
|
|
9
|
+
"version": "2.0.0-next.2"
|
|
10
|
+
},
|
|
2
11
|
{
|
|
3
12
|
"children": {
|
|
4
13
|
"features": [
|
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.2",
|
|
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",
|
|
@@ -67,7 +67,7 @@ async function generateByImageMode(
|
|
|
67
67
|
const defaultInput = {
|
|
68
68
|
n: 1,
|
|
69
69
|
...(model.includes('dall-e') ? { response_format: 'b64_json' } : {}),
|
|
70
|
-
...(isImageEdit ? { input_fidelity: 'high' } : {}),
|
|
70
|
+
...(isImageEdit && model === 'gpt-image-1' ? { input_fidelity: 'high' } : {}),
|
|
71
71
|
};
|
|
72
72
|
|
|
73
73
|
const options = cleanObject({
|
|
@@ -1254,7 +1254,6 @@ describe('LobeOpenAICompatibleFactory', () => {
|
|
|
1254
1254
|
);
|
|
1255
1255
|
expect(instance['client'].images.edit).toHaveBeenCalledWith({
|
|
1256
1256
|
image: expect.any(File),
|
|
1257
|
-
input_fidelity: 'high',
|
|
1258
1257
|
mask: 'https://example.com/mask.jpg',
|
|
1259
1258
|
model: 'dall-e-2',
|
|
1260
1259
|
n: 1,
|
|
@@ -1301,7 +1300,6 @@ describe('LobeOpenAICompatibleFactory', () => {
|
|
|
1301
1300
|
|
|
1302
1301
|
expect(instance['client'].images.edit).toHaveBeenCalledWith({
|
|
1303
1302
|
image: [mockFile1, mockFile2],
|
|
1304
|
-
input_fidelity: 'high',
|
|
1305
1303
|
model: 'dall-e-2',
|
|
1306
1304
|
n: 1,
|
|
1307
1305
|
prompt: 'Merge these images',
|
|
@@ -1330,6 +1328,39 @@ describe('LobeOpenAICompatibleFactory', () => {
|
|
|
1330
1328
|
'Failed to convert image URLs to File objects: Error: Failed to download image',
|
|
1331
1329
|
);
|
|
1332
1330
|
});
|
|
1331
|
+
|
|
1332
|
+
it('should include input_fidelity parameter for gpt-image-1 model', async () => {
|
|
1333
|
+
const mockResponse = {
|
|
1334
|
+
data: [{ b64_json: 'gpt-image-edited-base64' }],
|
|
1335
|
+
};
|
|
1336
|
+
|
|
1337
|
+
const mockFile = new File(['content'], 'test-image.jpg', { type: 'image/jpeg' });
|
|
1338
|
+
|
|
1339
|
+
vi.mocked(openaiHelpers.convertImageUrlToFile).mockResolvedValue(mockFile);
|
|
1340
|
+
vi.spyOn(instance['client'].images, 'edit').mockResolvedValue(mockResponse as any);
|
|
1341
|
+
|
|
1342
|
+
const payload = {
|
|
1343
|
+
model: 'gpt-image-1',
|
|
1344
|
+
params: {
|
|
1345
|
+
imageUrl: 'https://example.com/image.jpg',
|
|
1346
|
+
prompt: 'Edit this image with gpt-image-1',
|
|
1347
|
+
},
|
|
1348
|
+
};
|
|
1349
|
+
|
|
1350
|
+
const result = await (instance as any).createImage(payload);
|
|
1351
|
+
|
|
1352
|
+
expect(instance['client'].images.edit).toHaveBeenCalledWith({
|
|
1353
|
+
image: expect.any(File),
|
|
1354
|
+
input_fidelity: 'high',
|
|
1355
|
+
model: 'gpt-image-1',
|
|
1356
|
+
n: 1,
|
|
1357
|
+
prompt: 'Edit this image with gpt-image-1',
|
|
1358
|
+
});
|
|
1359
|
+
|
|
1360
|
+
expect(result).toEqual({
|
|
1361
|
+
imageUrl: 'data:image/png;base64,gpt-image-edited-base64',
|
|
1362
|
+
});
|
|
1363
|
+
});
|
|
1333
1364
|
});
|
|
1334
1365
|
|
|
1335
1366
|
describe('error handling', () => {
|
|
@@ -1431,7 +1462,6 @@ describe('LobeOpenAICompatibleFactory', () => {
|
|
|
1431
1462
|
expect(instance['client'].images.edit).toHaveBeenCalledWith({
|
|
1432
1463
|
customParam: 'should remain unchanged',
|
|
1433
1464
|
image: expect.any(File),
|
|
1434
|
-
input_fidelity: 'high',
|
|
1435
1465
|
model: 'dall-e-2',
|
|
1436
1466
|
n: 1,
|
|
1437
1467
|
prompt: 'Test prompt',
|
|
@@ -34,7 +34,7 @@ const AgentPlugin = memo(() => {
|
|
|
34
34
|
s.toggleAgentPlugin,
|
|
35
35
|
]);
|
|
36
36
|
|
|
37
|
-
const { showDalle } = useServerConfigStore(featureFlagsSelectors);
|
|
37
|
+
const { showDalle, showMarket } = useServerConfigStore(featureFlagsSelectors);
|
|
38
38
|
const installedPlugins = useToolStore(toolSelectors.metaList(showDalle), isEqual);
|
|
39
39
|
|
|
40
40
|
const { isLoading } = useFetchInstalledPlugins();
|
|
@@ -112,16 +112,18 @@ const AgentPlugin = memo(() => {
|
|
|
112
112
|
/>
|
|
113
113
|
</Tooltip>
|
|
114
114
|
) : null}
|
|
115
|
-
|
|
116
|
-
<
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
e
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
115
|
+
{showMarket ? (
|
|
116
|
+
<Tooltip title={t('plugin.store')}>
|
|
117
|
+
<Button
|
|
118
|
+
icon={Store}
|
|
119
|
+
onClick={(e) => {
|
|
120
|
+
e.stopPropagation();
|
|
121
|
+
setShowStore(true);
|
|
122
|
+
}}
|
|
123
|
+
size={'small'}
|
|
124
|
+
/>
|
|
125
|
+
</Tooltip>
|
|
126
|
+
) : null}
|
|
125
127
|
</Space.Compact>
|
|
126
128
|
);
|
|
127
129
|
|
|
@@ -149,7 +151,13 @@ const AgentPlugin = memo(() => {
|
|
|
149
151
|
);
|
|
150
152
|
|
|
151
153
|
const plugin: FormGroupItemType = {
|
|
152
|
-
children: isLoading
|
|
154
|
+
children: isLoading
|
|
155
|
+
? loadingSkeleton
|
|
156
|
+
: isEmpty
|
|
157
|
+
? showMarket
|
|
158
|
+
? empty
|
|
159
|
+
: []
|
|
160
|
+
: [...deprecatedList, ...list],
|
|
153
161
|
extra,
|
|
154
162
|
title: t('settingPlugin.title'),
|
|
155
163
|
};
|