-
Notifications
You must be signed in to change notification settings - Fork 5
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: output context limit reached -> roles must alternate between \"user\" and \"assistant\", but found multiple \"assistant\" roles in a row"}}", further input doesn't work #11
Comments
Correction: if I delete the Claude Chat buffer and open a new one, it works again. |
Thank you for this plugin, by the way! |
You can also manually update whatever is at the end of the buffer to restore the alternating flow. If you can share exactly how last few lines of the buffer look like, we can consider how to handle this better. |
Just encountered this again. This time I was focused on another buffer while Claude was outputting. It ended up appending You: to the buffer I was browsing instead of the Claude Chat buffer. And then the Chat stopped working. Here's a direct copy paste, starting with the end of the last Claude output:
|
Ah, interesting, so somehow "The buttons at the bottom are cut off" line is missing a "You:" prefix. And I assume you reposted the line with the prefix rather than coming back to the previous line and adding the prefix there? So the dialog ended up with two Claude: lines in a row. I think in the future it would be nice to do two things:
|
It seems to always happen when claude cuts itself off due to max output size. Here's another example, beginning with some cut off output from Claude:
|
Wow that never happenned to me, interesting! (PR would be welcome. Also just to be clear, is the workaround to fix the output in the buffer clear?) P.S. you may want to increase the 2048 max_tokens limit |
that's correct, as I had my cursor in another buffer when the output finished, so it dumped the You: there instead of the claude chat |
Thanks for the tip about the max_tokens limit. Yeah once it starts erroring, the only fix I've found is to delete the buffer. |
You don't need to delete the whole buffer, you can just edit the last lines of it as appropriate to fix the issue manually. |
When the max token issue happens, I try to close the ` block and write You: continue but it doesn't work
|
A claude chat response seemed to reach the output context limit, so I asked it to continue, and I got:
Now all my message result in this response. cx results in
The only solution I can find is to restart vim
The text was updated successfully, but these errors were encountered: