diff --git a/static/scripts/chat.js b/static/scripts/chat.js index efe8641..3ddbfd3 100644 --- a/static/scripts/chat.js +++ b/static/scripts/chat.js @@ -236,7 +236,7 @@ function drawCompletedResponseMessageContents (parent, message) { async function drawStreamedMessageContents (parent, message) { let fullResponse = '' let current = document.createElement('p') - let newLine = true + let newLine = true parent.appendChild(current) const parser = new SSEParser(message.response[message.responseIndex]) @@ -248,7 +248,7 @@ async function drawStreamedMessageContents (parent, message) { const tokenString = escapeHtml(tokens.join('')) fullResponse += tokenString - + const lines = tokenString.split('\n') if (newLine) {