Skip to content

Commit

Permalink
update:更新传入的消息
Browse files Browse the repository at this point in the history
  • Loading branch information
nowscott committed Jul 27, 2024
1 parent 376a073 commit 88fa63f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/pages/ChatPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ const ChatPage = () => {
setAiMessageMid(newAiMessageId);
const formatMessage = (msg) => `${msg.role === 'user' ? 'user' : 'AI'}: ${msg.content}`;
const chatHistory = messages.map(formatMessage).join('\n');
const fullPrompt = `消息记录: ${chatHistory}\n用户: ${prompt}`;
const fullPrompt = `chatHistory: ${chatHistory}\nuser: ${prompt}`;
setIsMessageComplete(false);
setSubmittedPrompt(fullPrompt);
setShouldSubmit(true);
Expand Down

0 comments on commit 88fa63f

Please sign in to comment.