mirror of
https://github.com/lobehub/lobehub.git
synced 2026-03-27 13:29:15 +07:00
🐛 fix(provider-config): update isFetchOnClient Switch component (#11215)
* 🐛 fix(provider-config): remove unused isFetchOnClient state and update Switch component * ♻️ refactor: 移除 Claude 3 Opus 模型,添加 Doubao Seed 1.8 模型的启用状态 * 🐛 fix(volcengine): 更新 Doubao Seed 1.8 部署名称
This commit is contained in:
@@ -292,36 +292,6 @@ const anthropicChatModels: AIChatModelCard[] = [
|
||||
},
|
||||
type: 'chat',
|
||||
},
|
||||
{
|
||||
abilities: {
|
||||
functionCall: true,
|
||||
vision: true,
|
||||
},
|
||||
contextWindowTokens: 200_000,
|
||||
description:
|
||||
'Claude 3 Opus is Anthropic’s most powerful model for highly complex tasks, excelling in performance, intelligence, fluency, and comprehension.',
|
||||
displayName: 'Claude 3 Opus',
|
||||
id: 'claude-3-opus-20240229',
|
||||
maxOutput: 4096,
|
||||
pricing: {
|
||||
units: [
|
||||
{ name: 'textInput_cacheRead', rate: 1.5, strategy: 'fixed', unit: 'millionTokens' },
|
||||
{ name: 'textInput', rate: 15, strategy: 'fixed', unit: 'millionTokens' },
|
||||
{ name: 'textOutput', rate: 75, strategy: 'fixed', unit: 'millionTokens' },
|
||||
{
|
||||
lookup: { prices: { '1h': 30, '5m': 18.75 }, pricingParams: ['ttl'] },
|
||||
name: 'textInput_cacheWrite',
|
||||
strategy: 'lookup',
|
||||
unit: 'millionTokens',
|
||||
},
|
||||
],
|
||||
},
|
||||
releasedAt: '2024-02-29',
|
||||
settings: {
|
||||
extendParams: ['disableContextCaching'],
|
||||
},
|
||||
type: 'chat',
|
||||
},
|
||||
];
|
||||
|
||||
export const allModels = [...anthropicChatModels];
|
||||
|
||||
@@ -10,12 +10,13 @@ const doubaoChatModels: AIChatModelCard[] = [
|
||||
vision: true,
|
||||
},
|
||||
config: {
|
||||
deploymentName: 'doubao-seed-1-8-251215',
|
||||
deploymentName: 'doubao-seed-1-8-251228',
|
||||
},
|
||||
contextWindowTokens: 256_000,
|
||||
description:
|
||||
'Doubao-Seed-1.8 有着更强的多模态理解能力和 Agent 能力,支持文本/图片/视频输入与上下文缓存,可在复杂任务中提供更出色的表现。',
|
||||
displayName: 'Doubao Seed 1.8',
|
||||
enabled: true,
|
||||
id: 'doubao-seed-1.8',
|
||||
maxOutput: 64_000,
|
||||
pricing: {
|
||||
|
||||
@@ -150,7 +150,6 @@ const ProviderConfig = memo<ProviderConfigProps>(
|
||||
enabled,
|
||||
isLoading,
|
||||
configUpdating,
|
||||
isFetchOnClient,
|
||||
enableResponseApi,
|
||||
isProviderEndpointNotEmpty,
|
||||
isProviderApiKeyNotEmpty,
|
||||
@@ -160,7 +159,6 @@ const ProviderConfig = memo<ProviderConfigProps>(
|
||||
aiProviderSelectors.isProviderEnabled(id)(s),
|
||||
aiProviderSelectors.isAiProviderConfigLoading(id)(s),
|
||||
aiProviderSelectors.isProviderConfigUpdating(id)(s),
|
||||
aiProviderSelectors.isProviderFetchOnClient(id)(s),
|
||||
aiProviderSelectors.isProviderEnableResponseApi(id)(s),
|
||||
aiProviderSelectors.isActiveProviderEndpointNotEmpty(s),
|
||||
aiProviderSelectors.isActiveProviderApiKeyNotEmpty(s),
|
||||
@@ -301,11 +299,7 @@ const ProviderConfig = memo<ProviderConfigProps>(
|
||||
(showEndpoint && isProviderEndpointNotEmpty) ||
|
||||
(showApiKey && isProviderApiKeyNotEmpty));
|
||||
const clientFetchItem = showClientFetch && {
|
||||
children: isLoading ? (
|
||||
<SkeletonSwitch />
|
||||
) : (
|
||||
<Switch checked={isFetchOnClient} disabled={configUpdating} />
|
||||
),
|
||||
children: isLoading ? <SkeletonSwitch /> : <Switch loading={configUpdating} />,
|
||||
desc: t('providerModels.config.fetchOnClient.desc'),
|
||||
label: t('providerModels.config.fetchOnClient.title'),
|
||||
minWidth: undefined,
|
||||
|
||||
Reference in New Issue
Block a user