Compare commits

...

2 Commits

Author SHA1 Message Date
d394bc0857 Merge pull request 'fix: display user messages in chat interface' (#48) from fix/display-user-messages into main 2026-04-10 06:04:23 +02:00
shokollm
dfa806ab53 fix: add user's message to frontend chat store when sending
Previously, only the assistant's response was added to the frontend store.
Now both user and assistant messages are stored, so the conversation
displays correctly in the chat interface.
2026-04-10 04:00:51 +00:00

View File

@@ -44,6 +44,9 @@
isSending = true; isSending = true;
// Add user's message immediately
addMessage({ role: 'user', content: message });
try { try {
const response = await api.bots.chat(botId, message); const response = await api.bots.chat(botId, message);
addMessage({ role: 'assistant', content: response.response }); addMessage({ role: 'assistant', content: response.response });