Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Chat Error: prompt is too long: 200000 tokens > 199999 maximum #1322

Closed
kc0tlh opened this issue Nov 1, 2024 · 147 comments
Closed

Chat Error: prompt is too long: 200000 tokens > 199999 maximum #1322

kc0tlh opened this issue Nov 1, 2024 · 147 comments

Comments

@kc0tlh
Copy link
Collaborator

kc0tlh commented Nov 1, 2024

📣 Issue Resolved: this fix has been merged into production and bolt.new now supports projects up to 2.5x larger!

Thank you to everyone in the thread above providing workarounds and helping each other. This is MUCH MUCH appreciated, as we are currently in the process of training our newly hired support staff, and working out of a backlog on the [email protected]/[email protected] email inbox (we will respond to EVERY SINGLE request).

If you are still looking for support for other issues, please start with our newly launched support center 🎉


What does this error message mean?
This error message means that your project has become too large for Bolt to sync the entire project with the AI.

As described in issue #678, Bolt.new syncs both the chat history & file system with the AI's memory. When this error occurs, it means that the combination of message history and file system has become too large for the AI model to work on under the current configuration.

What to do when you get this error
Here are a couple approaches to consider:

  • Clear the chat history to free up some space in the context window
    This will only help if the chat history is filling a major portion of the context window (IE it is very long). As of 11/19/24, the way to clear chat history is to open your project in StackBlitz, Fork it, and re-open in Bolt.

  • Reduce the Size of your project
    This could be accomplished by breaking a large app into smaller chunks, and glueing it all back together outside of Bolt later. For example, separate backend and frontend into separate projects is a common developer pattern. This could be challenging for less experienced developers.

  • ADVANCED USERS ONLY: .bolt/ignore
    In every bolt project, if you open it in StackBlitz you can edit a file called .bolt/ignore, and in this file you can list out any folders or folders that should be excluded from the AI context window. For example, here is our vite react starter’s ignore files: https://stackblitz.com/edit/vite-shadcn?file=.bolt%2Fignore. Any files listed there will be completely invisible to the AI, and will clear up space in the context window. You’ll need to edit the .bolt/ignore file in StackBlitz and then reopen the project in bolt for the changes to take effect. Please note: hiding files from the AI can have unintended consequences as it is no longer aware of your entire project. This approach is very powerful, but is only recommended for advanced users who can make informed decisions about what can safely be excluded, and understand/resolve issues that may arise from this approach.

What are we doing about this?
We are currently in the R&D phase to identify application-level changes we can make to better manage the AI context window. Our current approach has the benefit of making Bolt.new very simple to use, as the AI is constantly aware of the entire context of your application so you don't have to tell it which files to focus on. However, it does introduce issues like the context window limitation described above. Stay tuned to this issue for future updates!

@Welexon
Copy link

Welexon commented Nov 3, 2024

same issue for me, over and over again. prompt is too long: 201843 tokens > 200000 maximum. i have not received any refund and bought 30 mill tokens, now to test again. still same issue. I even tried forking. I kindly ask for a refund, my entire project has halted. I sent an email about refund today.

user: Welexon
https://bolt.new/~/sb1-g7m98y

@behnod24
Copy link

behnod24 commented Nov 3, 2024

Hello, I get the same error, could you please fix this issue? I could not do anything because of this issue.

Thank you for your efforts and supports.

@tuanvuvo
Copy link

tuanvuvo commented Nov 3, 2024

same as me. can not work when just secord request blocked of this

@heliusmaximus08
Copy link

same issue. this is really sad

@paydayrich
Copy link

@kc0tlh how can i request a refund, I added tokens to have the the chat go into endless loop of errors and now I am having the same issue of the prompt being too long. my project has been stuck for 3 days.

@danthemank
Copy link

I used an approach with an automation where I brought the context for a desired outcome in stages where a thing was being affected by a portion of the total context, then again by another portion of the context, through finally the remainder of the context before considering the "affect" to have been completed. Maybe there's merit to an approach like this here?

Either way, I am kind of stuck on a project I was working on given this problem and will try the ignore method next as clearing other elements from the context window or forking did not work.

Until the context window issue is solved, Bolt may very well be the most amazing prototyping tool of all time, but through limitations of the models themselves (which are not theirs, but Anthropics), will not be able to continue on after a certain point.

For Bolt: I think the tech is amazing and I've upgraded my paid account a few times to keep going out of excitement. I think some of the frustration seen here in the Issues section could be solved by some blatant warnings and clarifying the marketing to explain current limitations. Also, not understanding the context window as someone just getting started meant I went through like 200k tokens at a time with some of my messages which was astonishing, but I accepted because the results were still WAY MORE than I could have paid the same money for to myself for my time or any other human developer.

To anyone else, these people are trying to make a great tool. I'm sure you can imagine they don't want problems. Don't be a jerk.

@Habartru
Copy link

Habartru commented Nov 6, 2024

This is a very strange behavior of BOLT developers! First of all, you do not warn that at one point the system may stop working! Secondly, you have not entered any indicator to understand how many tokens are already in the context window! Thirdly, you didn't even bother to make some kind of cleaning tool. Fourth, and most importantly! Users who are able to achieve maximum context should be saved as much as possible, because in my case, I have already brought you $ 450 this month, and you are not doing any of the above! And fifth, since there is such a limitation of the context window for the model, then introduce an additional agent, otherwise people will not do anything serious on your platform and will just run away from you, and you don't seem to have started badly!!!!! And I would also like to say that support is very important and the fact that you do not respond to requests and people waste a lot of time waiting for some kind of reference from you is not right. So you spit in their face... It's a shame, of course. You could get better, but apparently you don't need it!

This was referenced Nov 17, 2024
@bigblackcoder
Copy link

ATTENTION: SOLVED!! Prompt is too long limitation bug!

Well <@501636911002157066> @bolt.new and my fellow Bolt builders, I've solved the issue of the the prompt too long bug for larger development projects. First, use the recommended https://30d61b3c.bolt-cnr.pages.dev/ URL.

Now for me, when I went to the dev URL, none of my files were there! So i user my creative thinking and promlem solving skills. So I copy my folder URL identifier for example: sb1-uz4pwq and put it together like this: https://30d61b3c.bolt-cnr.pages.dev/~/sb1-uz4pwx (not the real file but an example) And I got it get pass the bug and continue with my development pass the 200k token limit! (@stackblitz, you can hook me up with some incentives of my membership. Haha! )

FYI: You must used the dev URL your file number in order for it to work, otherwise you are going to be stuck like chuck!
Screenshot 2024-11-17 at 10 08 11 PM

@endocytosis
Copy link
Collaborator

endocytosis commented Nov 18, 2024

Update: Engineering has released an update to support project of larger sizes! This should significantly reduce "prompt too long" errors. We appreciate your patience as the team continues to ship improvements!

@Rnijland
Copy link

Well i read it was fixed, but currently i`m getting this error when trying even a single line prompt. Also a huge chunk of my application is suddenly gone, 4 million tokens thrown out of the window. And this is not the first time....

How can we develop and have a peace of mind that our whole app or complete sections wont be deleted when we load the project next time. However, its still consuming tons of tokens with each try. I love this system, but im getting scared to use it.

sad

@Rnijland
Copy link

Rnijland commented Nov 19, 2024

https://30d61b3c.bolt-cnr.pages.dev/~/

And to add to that, i used the new url: https://30d61b3c.bolt-cnr.pages.dev/~/thecodenotwanttosharepublic

sometimes after a reload it allows 1 or 2 prompts. And then stops. It almost always happens when it throws an error and you press fix problems. This is considered a new chat with the new url i think, but the platform refuses to work!

Last time i already burned 12 million tokens or more to get netlify working. I made a work around with a paid netlify account, and put the stackblitz code base into a github on my pc, where i can commit to netlify and then deploy ( which is an insane headache with how you market your services). Deploying is absolute HELL. Or updating the code through github etc.

But the worst is this token crap, we pay good money for this products, so SIMPLE stuff like this should work. A simple "Clear prompt memory" would suffice! Then we can just click and start over. Shouldn`t be too hard to implement right?

Or is this issue caused by pressing the fix problem button, that just loads an INSANE amount of text that immediately hits the max prompt size? I`m very confused on what is happening. I just started today with this project, and maybe a few hours in since the START of the dev of the project.

While with another project a few weeks ago i was able to work days on it with much larger prompts. What the heck is happening, and how to fix this ASAP.

@tperoulas
Copy link

I just opened my project in https://30d61b3c.bolt-cnr.pages.dev/ and I still get the error "This project exceeds the total supported prompt size. To see how to resolve this, visit https://bolt.fyi/prompt-too-long."

@kc0tlh
Copy link
Collaborator Author

kc0tlh commented Nov 20, 2024

📣 Update Complete: this fix has been merged into production and bolt.new now supports projects up to 2.5x larger!

Thank you to everyone in the thread above providing workarounds and helping each other. This is MUCH MUCH appreciated, as we are currently in the process of training our newly hired support staff, and working out of a backlog on the [email protected]/[email protected] email inbox (we will respond to EVERY SINGLE request).

If you are still looking for support for other issues, please start with our newly launched support center 🎉

CC: @dukuo @alvaroprs8 @cp5337 @nullsoft8411 @StackShipping @avxobro @danthemank @wundulla @kmlacr @heliusmaximus08 @tuanvuvo @behnod24 @Welexon @gfakx @callo451 @smartguyio @meso3988 @ifemuyiwaojo @Okleeqo @venutrue @harielxavier

@kc0tlh kc0tlh closed this as completed Nov 20, 2024
@skuudy30
Copy link

@kc0tlh Great news ! You're the best

That would be really nice if you be able to manage IA to not rework entire code.

When we got large files like firebase.ts and add new exports or make some modifications, IA erase files and we using like 2M tokens to regenerate properly all exports...

That's an example

Regards team !

@kc0tlh
Copy link
Collaborator Author

kc0tlh commented Nov 20, 2024

@skuudy30 please subscribe to #678 for updates on that exact feature (which I believe we are launching on our YouTube livestream tomorrow).

@skuudy30
Copy link

Insane ! @skuudy30 thanks a lot i'll follow

@StackShipping
Copy link

StackShipping commented Nov 21, 2024

@kc0tlh When can we expect the refunds to be processed since after three emails to your hello email adres still no reply!

@codewithtyler
Copy link

@kc0tlh When can we expect the refunds to be processed since after three emails to your hello email adres still no reply!

If you haven't already please reach out to TheTiGuR in the #discussions channel of the Discord. He'll ask for you the email you used to login to Bolt and will forward your info along to the right person.

@Habartru
Copy link

Guys! What have you done!? Why did the bolt become so blunt??? Now he doesn't ask me several times if I want to continue, if I'm ready, if I agree... What is it? Each such answer of mine, consisting of 2 words, burns 200,000 tokens. Why is that? Today is just a terrible day. I burned 20,000,000 tokens and didn't make any progress. He constantly forgets what he is doing, rewrites the same files several times, even if you tell him that you need some other edits... Well, what is it? What should I do about it?!?

@everspader
Copy link

Each such answer of mine, consisting of 2 words, burns 200,000 tokens

I thought this was happening to me only. I managed to but 10 Million tokens in one day just we some changes to a project. Every little change was 200k tokens regardless if I explicitly prompted Bolt to only show me the changes.

@ifemuyiwaojo
Copy link

ifemuyiwaojo commented Nov 22, 2024 via email

@d3lm
Copy link
Contributor

d3lm commented Nov 25, 2024

Hey @honzabit 👋 Thanks for your question! We've implemented several improvements that now allow for approximately 2.5x larger conversations without any additional cost to you. This means you can have longer chat sessions, work with more project files, and attach larger files while maintaining the same performance and quality you're used to.

To break this down a bit:

  • Your conversations (chat messages, project files, attachments) can now be significantly larger
  • The system manages memory more efficiently behind the scenes
  • There's no impact on pricing or quality
  • Everything works seamlessly without you having to change anything on your end

Since you're a power user (250M tokens in 2 weeks is impressive!), you'll especially benefit from these optimizations as they allow for more extensive and complex interactions within a single session.

@tperoulas
Copy link

I'm still getting "This project exceeds the total supported prompt size. To see how to resolve this, visit https://bolt.fyi/prompt-too-long."

@jwdeon06
Copy link

i am getting this error and the work around is not working for me. Same feeling as most people here, I love the potential and have something I want to deploy as beta but am now stuck. I am debating just going back to WP for now.

@codewithtyler
Copy link

i am getting this error and the work around is not working for me. Same feeling as most people here, I love the potential and have something I want to deploy as beta but am now stuck. I am debating just going back to WP for now.

Is it giving you the exact error listed above or is the amount 500000? This will help the team know if there is still a problem with the original issue or if your project has hit the new limit.

@jwdeon06
Copy link

This is what I get:
This project exceeds the total supported prompt size. To see how to resolve this, visit https://bolt.fyi/prompt-too-long.

@julio-hm
Copy link

justo acabo de actualizar la suscripción a PRO 50 porque pensaba que era genial lo que estaba desarrollando pero justo después de hacer la actualización de suscripción me metió en un bucle de errores y ahora dice que el proyecto es muy grande, creo que me ha decepcionado y amablemente me gustaria pedir un reembolso, que lastima porque creo que tiene mucho potencial esta plataforma

@etheuer
Copy link

etheuer commented Nov 29, 2024

Clear the chat history to free up some space in the context window
This will only help if the chat history is filling a major portion of the context window (IE it is very long). As of 11/19/24, the way to clear chat history is to open your project in StackBlitz, Fork it, and re-open in Bolt.

I did exactly this but how to "reopen in Bolt"? When in Stackblitz, after forking I went back to the bolt and the full chat was still there, then I deleted the chat and the application in Bolt is vanished. Then I went back to Stackblitz, clicked on "Try Bolt.new" and it went to Bolt home, and it loaded the "Want do you want to build" screen. On stackblitz I can still see the app but theres is no "open in bolt.new" button anymore.

@M5054
Copy link

M5054 commented Nov 29, 2024

Large Project Size Alert This project seems to be quite large in size, which increases token usage per message. To learn how to reduce token consumption and optimize your project can i do something for this ?

@StackShipping
Copy link

@kc0tlh When can we expect the refunds to be processed since after three emails to your hello email adres still no reply!

If you haven't already please reach out to TheTiGuR in the #discussions channel of the Discord. He'll ask for you the email you used to login to Bolt and will forward your info along to the right person.

@kc0tlh

I guess the refunds where just a lie. I lost $200 and ended with nothing to show for, only continues loops of continues loops of achieving nothing but hitting 200k tokens memorty walls or whatever.

Are you going to refund me or was it just a lie since I send 3 emails, I contacted thetigur. I just don't believe it anymore!

Waiting for you guys your reply. Otherwise will make a youtube video with my experience.

@harielxavier
Copy link

harielxavier commented Nov 30, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests