feat: add gpu_selector field

This commit is contained in:
jialin
2024-09-09 13:41:39 +08:00
parent dc4e83447d
commit c5f4083f66
6 changed files with 400 additions and 527 deletions
+7
View File
@@ -3,6 +3,7 @@ import { PipelineType } from '@huggingface/tasks';
import { request } from '@umijs/max';
import {
FormData,
GPUListItem,
ListItem,
ModelInstanceFormData,
ModelInstanceListItem
@@ -24,6 +25,12 @@ export async function queryModelsList(
});
}
export async function queryGPUList() {
return request<Global.PageResponse<GPUListItem>>(`/gpu-devices`, {
methos: 'GET'
});
}
export async function createModel(params: { data: FormData }) {
return request(`${MODELS_API}`, {
method: 'POST',