Dear All and to whom it may concern,
Greetings.
Google AI Studio becomes ridiculously slow and lags to the point where you cannot even type properly let alone waiting for an answer to generate. This happens after some tokens reach 50K onwards. This happens in every new prompt. It works quickly initially but then becomes unbearable as the context grows. I am using Gemini-flash 1.5 on latest chrome browser both on Windows and MacOS environments. So, this is not a fluke. I am starting to suspect that this is being done deliberately. My conscience says otherwise because I hope those in charge have a conscience too. Can somebody offer a solution here? I know for sure there are others in the same space. Please accept the best of all my regards despite the situation.
By the way, yes, the first lags are starting to appear for me already at 5000-7000 tokens, and unbearable ones already at 25, this appeared quite a long time ago, as I remember
Same problem. However, it looks like the lags are also affected by the number of messages, not just the number of tokens. If you create a new prompt and transfer the history from the previous prompt to it as a text file, the lags will disappear for a while
It would be interesting to see a reply from someone from google on the matter. Is it done on purpose? We will get an answer if there is no reply.
Fellow developers have come up with the answer: the browser gets bogged down by an unconscionable abuse of the element. The problem has been reported to Google in this post - AI Studio crashing - milions of DOM <span>
Hello, thanks. My use case is fairly simple. I input some text in the system instructions (copy from word and paste). In the main chat, I upload a research paper as pdf and ask a question (typing most of the time). After I get an answer, I upload another paper pdf and ask same question. The lagging starts after this or may be another pdf. The lagging happens in every new chat prompt when a certain amount of tokens have been reached. There is no crashing but unbearable user experience in the form of serious lags. Your referred post mentions browser crashing which I have not faced since repeated daily usage for a month now. The lagging has become worse since the latest gemini updates last week or so.
I know tje solution, visit my post
i got same problem. But, just need to turn off “google dev” where we check “html” (F12). got spam <span> in that so just need to turn off it. its work on me
Hey folks! We shipped a change that should resolve this. Please let us know if you are still seeing issues.
Thanks Logan for looking into this. I will check on Windows and Mac and let you know how it goes.
I haven’t noticed any issues today so you seem to have done the trick! I had to keep a text file of my chat history just to keep it going prior. Thanks a bunch!
Hey there, there is still lag, I have tested in Windows 11, Google Chrome. after 7900 tokens, two responses from Gemini Pro, I get lag while typing.
i stil have the same problem
thanks, would you please explain more how do do it?
@Logan_Kilpatrick and all, two observations (i use on both platforms):
- no lag observed on windows and chrome since last 2-3 weeks
- lag still observed on macOS and chrome
to whom it may concern, thanks for looking into it.
chrome://flags
Overlay Scrollbars → Enabled
No more lag when typing or getting the output in Google AI Studio
This seems to have fixed the problem for me. I type quickly, and apparently every single letter that gets typed toggles the scrollbars to be visible for me. I haven’t checked it in code, this is just the behavior that I am seeing, but perhaps this needs to be debounced? Anyway, just changing this one flag (on Vivaldi no less) has fixed the issue for me, even in a 1.1M+ token prompt. Thank you @Roland !!!
(EDIT: The lag also occurs in Chrome proper on my machine. The difference with that flag on is night and day.)