Feat: Support vLLM #4316 (#5395)

### What problem does this PR solve?
Feat: Support vLLM #4316

### Type of change


- [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
balibabu
2025-02-26 18:33:43 +08:00
committed by GitHub
parent fefea3a2a5
commit d9dd1171a3
9 changed files with 235 additions and 115 deletions

View File

@ -1,3 +1,4 @@
import { LLMFactory } from '@/constants/llm';
import { IFactory } from '@/interfaces/database/llm';
import isObject from 'lodash/isObject';
import snakeCase from 'lodash/snakeCase';
@ -36,12 +37,12 @@ export const formatNumberWithThousandsSeparator = (numberStr: string) => {
};
const orderFactoryList = [
'OpenAI',
'Moonshot',
"PPIO",
'ZHIPU-AI',
'Ollama',
'Xinference',
LLMFactory.OpenAI,
LLMFactory.Moonshot,
LLMFactory.PPIO,
LLMFactory.ZhipuAI,
LLMFactory.Ollama,
LLMFactory.Xinference,
];
export const sortLLmFactoryListBySpecifiedOrder = (list: IFactory[]) => {