Add workflow rename; Fix: userselect chatId unrefresh (#2672)

* feat: workflow node support rename

* perf: push data to training queue

* fix: userselect chatId unrefresh
This commit is contained in:
Archer
2024-09-11 15:27:47 +08:00
committed by GitHub
parent 11cbcca2d4
commit 02bf400bf3
14 changed files with 144 additions and 188 deletions

View File

@@ -130,7 +130,6 @@ const Chat = ({
const completionChatId = chatId || getNanoid();
// Just send a user prompt
const histories = messages.slice(-1);
const { responseText, responseData } = await streamFetch({
data: {
messages: histories,
@@ -146,10 +145,8 @@ const Chat = ({
const newTitle = getChatTitleFromChatMessage(GPTMessages2Chats(histories)[0]);
// new chat
if (completionChatId !== chatId) {
if (controller.signal.reason !== 'leave') {
onChangeChatId(completionChatId, true);
}
if (completionChatId !== chatId && controller.signal.reason !== 'leave') {
onChangeChatId(completionChatId, true);
}
loadHistories();