mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
Bug fix for volcengine (#909)
### What problem does this PR solve? Bug fixes for the VolcEngine - Bug fix for front-end configuration code of VolcEngine - Bug fix for tokens counting logic of VolcEngine ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) --------- Co-authored-by: 海贼宅 <stu_xyx@163.com>
This commit is contained in:
@ -102,7 +102,7 @@ const ModelCard = ({ item, clickApiKey }: IModelCardProps) => {
|
||||
<Col span={12} className={styles.factoryOperationWrapper}>
|
||||
<Space size={'middle'}>
|
||||
<Button onClick={handleApiKeyClick}>
|
||||
{isLocalLlmFactory(item.name) ? t('addTheModel') : 'API-Key'}
|
||||
{isLocalLlmFactory(item.name) || item.name === 'VolcEngine' ? t('addTheModel') : 'API-Key'}
|
||||
<SettingOutlined />
|
||||
</Button>
|
||||
<Button onClick={handleShowMoreClick}>
|
||||
@ -181,11 +181,13 @@ const UserSettingModel = () => {
|
||||
(llmFactory: string) => {
|
||||
if (isLocalLlmFactory(llmFactory)) {
|
||||
showLlmAddingModal(llmFactory);
|
||||
} else if (llmFactory === 'VolcEngine') {
|
||||
showVolcAddingModal('VolcEngine');
|
||||
} else {
|
||||
showApiKeyModal({ llm_factory: llmFactory });
|
||||
}
|
||||
},
|
||||
[showApiKeyModal, showLlmAddingModal],
|
||||
[showApiKeyModal, showLlmAddingModal, showVolcAddingModal],
|
||||
);
|
||||
|
||||
const handleAddModel = (llmFactory: string) => () => {
|
||||
|
||||
Reference in New Issue
Block a user