Hi all. Using ChatGPT has become very laggy for me, and I’m not talking about sending prompts to the server and waiting for a reply. I’m talking about using the actual web app has become very slow/unresponsive. Things like typing text into the message box and scrolling up/down between past messages are now untenable, requiring 5, 10, or 20+ seconds to complete (or they simply hang indefinitely). Refreshing the browser page hangs indefinitely at times as well. Does anyone know how to resolve this? Just to be clear, waiting for responses from the web server also requires a very long time–and times out in a lot of cases. But at the moment it is easier to contend with than the UI lag.
All of the above issues occur when I use Google Chrome. When I switch to Edge, all issues are gone
Obviously the problem is that chat window renders whole chat. So the more messages you have the more HTML nodes you have and this causes the lag.
They should ask ChatGPT to optimize the rendering of the chat window and render only last 5-10 messages instead and when you scroll up it would load next 5-10 messages. I am pretty sure ChatGPT can give code for this no matter which front-end frameworks they use
I can confirm the same is happening on Safari. Ridiculously slow. Freezing mid-answer to a point I must quit the browser. I tried chrome but the problem persists. On iPad tough, it runs as fast usual. IMO, performance problems began concurrently with the Microsoft announcement.
i use this and has made my life so much easier lol:
// Function to remove old messages
function removeOldMessages() {
// Select all message containers
const messageContainers = document.querySelectorAll('div[data-testid^="conversation-turn-"]');
// Log the number of messages found
console.log(`Total messages found: ${messageContainers.length}`);
// Check if there are more than 5 messages
if (messageContainers.length > 5) {
// Calculate the number of messages to remove
const messagesToRemove = messageContainers.length - 5;
// Log the number of messages being removed
console.log(`Removing ${messagesToRemove} old messages.`);
// Remove the old messages
for (let i = 0; i < messagesToRemove; i++) {
messageContainers[i].remove();
// Log each removal
console.log(`Removed message ${i + 1}`);
}
} else {
console.log('No messages to remove.');
}
}
// Call the function initially to clean up old messages
removeOldMessages();
// Set an interval to repeatedly call the function every 5 seconds
setInterval(removeOldMessages, 5000);