refactor: deploy model
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
import { StatusMaps } from '@/config';
|
||||
import { EditOutlined } from '@ant-design/icons';
|
||||
import _ from 'lodash';
|
||||
import { backendOptionsMap } from './backend-parameters';
|
||||
|
||||
export const backendTipsList = [
|
||||
{
|
||||
@@ -41,18 +42,12 @@ export const localPathTipsList = [
|
||||
}
|
||||
];
|
||||
|
||||
export const backendOptionsMap = {
|
||||
llamaBox: 'llama-box',
|
||||
vllm: 'vllm',
|
||||
voxBox: 'vox-box',
|
||||
ascendMindie: 'ascend-mindie'
|
||||
};
|
||||
|
||||
export const backendLabelMap = {
|
||||
[backendOptionsMap.llamaBox]: 'llama-box',
|
||||
[backendOptionsMap.vllm]: 'vLLM',
|
||||
[backendOptionsMap.voxBox]: 'vox-box',
|
||||
[backendOptionsMap.ascendMindie]: 'Ascend MindIE'
|
||||
[backendOptionsMap.ascendMindie]: 'Ascend MindIE',
|
||||
[backendOptionsMap.custom]: 'Custom'
|
||||
};
|
||||
|
||||
export const backendParamsHolderTips = {
|
||||
@@ -135,11 +130,6 @@ export const sourceOptions = [
|
||||
value: modelSourceMap.huggingface_value,
|
||||
key: 'huggingface'
|
||||
},
|
||||
{
|
||||
label: 'Ollama Library',
|
||||
value: modelSourceMap.ollama_library_value,
|
||||
key: 'ollama_library'
|
||||
},
|
||||
{
|
||||
label: 'ModelScope',
|
||||
value: modelSourceMap.modelscope_value,
|
||||
@@ -198,6 +188,30 @@ export const status: any = {
|
||||
[InstanceStatusMap.Unreachable]: StatusMaps.error
|
||||
};
|
||||
|
||||
export const ScheduleValueMap = {
|
||||
Auto: 'auto',
|
||||
Manual: 'manual',
|
||||
SpecificGPUType: 'specific_gpu_type'
|
||||
};
|
||||
|
||||
export const scheduleList = [
|
||||
{
|
||||
label: 'models.form.scheduletype.auto',
|
||||
locale: true,
|
||||
value: ScheduleValueMap.Auto
|
||||
},
|
||||
{
|
||||
label: 'models.form.scheduletype.manual',
|
||||
value: ScheduleValueMap.Manual,
|
||||
locale: true
|
||||
}
|
||||
// {
|
||||
// label: 'models.form.scheduletype.gpuType',
|
||||
// value: ScheduleValueMap.SpecificGPUType,
|
||||
// locale: true
|
||||
// }
|
||||
];
|
||||
|
||||
export const ActionList = [
|
||||
{
|
||||
label: 'common.button.edit',
|
||||
@@ -414,7 +428,7 @@ export const defaultFormValues = {
|
||||
description: '',
|
||||
categories: null,
|
||||
env: {},
|
||||
scheduleType: 'auto',
|
||||
scheduleType: ScheduleValueMap.Auto,
|
||||
placement_strategy: 'spread',
|
||||
gpu_ids: null,
|
||||
gpu_selector: {},
|
||||
|
||||
Reference in New Issue
Block a user