chore: change partial_offload field

This commit is contained in:
jialin
2024-09-10 16:33:39 +08:00
parent 93bda622d5
commit 7ba7f57b05
8 changed files with 12 additions and 13 deletions
@@ -175,7 +175,7 @@ const AdvanceConfig: React.FC<AdvanceConfigProps> = (props) => {
)}
<div style={{ paddingBottom: 22, paddingLeft: 10 }}>
<Form.Item<FormData>
name="partial_offload"
name="cpu_offloading"
valuePropName="checked"
style={{ padding: '0 10px', marginBottom: 0 }}
noStyle
+1 -1
View File
@@ -263,7 +263,7 @@ const DataForm: React.FC<DataFormProps> = forwardRef((props, ref) => {
replicas: 1,
source: props.source,
placement_strategy: 'spread',
partial_offload: false,
cpu_offloading: false,
scheduleType: 'auto',
distributed_inference_across_workers: false
}}
@@ -65,6 +65,7 @@ const SearchModel: React.FC<SearchInputProps> = (props) => {
if (modelSource === modelSourceMap.ollama_library_value) {
return;
}
console.log('handleOnSearchRepo', dataSource.loading);
axiosTokenRef.current?.abort?.();
axiosTokenRef.current = new AbortController();
if (dataSource.loading) return;
@@ -120,13 +121,10 @@ const SearchModel: React.FC<SearchInputProps> = (props) => {
[dataSource]
);
const handlerSearchModels = useCallback(
async (e: any) => {
searchInputRef.current = e.target.value;
handleOnSearchRepo();
},
[handleOnSearchRepo]
);
const handlerSearchModels = async (e: any) => {
searchInputRef.current = e.target.value;
handleOnSearchRepo();
};
const handleOnOpen = () => {
if (
+1 -1
View File
@@ -34,7 +34,7 @@ export interface FormData {
gpu_name: string;
};
placement_strategy?: string;
partial_offload?: boolean;
cpu_offloading?: boolean;
worker_selector?: object;
scheduleType?: string;
name: string;
@@ -24,6 +24,7 @@
left: 0;
right: 0;
z-index: 100;
padding-block: 0;
background-color: var(--color-white-1);
}
}