feat: 知识库匹配模式选择

This commit is contained in:
archer
2023-04-12 00:44:01 +08:00
parent 1fe5cd751a
commit c605964fa8
11 changed files with 102 additions and 41 deletions

View File

@@ -114,8 +114,7 @@ const Chat = ({ chatId }: { chatId: string }) => {
async (prompts: ChatSiteItemType) => {
const urlMap: Record<string, string> = {
[ChatModelNameEnum.GPT35]: '/api/chat/chatGpt',
[ChatModelNameEnum.VECTOR_GPT]: '/api/chat/vectorGpt',
[ChatModelNameEnum.GPT3]: '/api/chat/gpt3'
[ChatModelNameEnum.VECTOR_GPT]: '/api/chat/vectorGpt'
};
if (!urlMap[chatData.modelName]) return Promise.reject('找不到模型');