feat: history chat

This commit is contained in:
archer
2023-04-23 16:06:16 +08:00
parent c2c73ed23c
commit 2774940851
12 changed files with 162 additions and 147 deletions

View File

@@ -26,6 +26,17 @@ export const postGPT3SendPrompt = ({
}))
});
/**
* 获取历史记录
*/
export const getChatHistory = () =>
GET<{ _id: string; title: string; modelId: string }[]>('/chat/getHistory');
/**
* 删除一条历史记录
*/
export const delChatHistoryById = (id: string) => GET(`/chat/removeHistory?id=${id}`);
/**
* 存储一轮对话
*/