[GH-ISSUE #1841] [BUG]: After about 19 to 20 inputs all of a sudden the context-window get revered? #1198

Closed
opened 2026-02-22 18:23:39 -05:00 by yindo · 2 comments
Owner

Originally created by @Dement242 on GitHub (Jul 10, 2024).
Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1841

How are you running AnythingLLM?

AnythingLLM desktop app

What happened?

After about 19 to 20 inputs from me it feel like all of a sudden the context-window get revered or something, You can have a normal back and forth, building on the previous messages, but then from one input to the next the model get all confused and start talking about random things from earlier in the conversation, and it is impossible to get it back on track. I have to /reset and start over.

I have checked and my token size is correct for llama-3: 8192, Chat history is set to 20.

Windows AnythingLLM v1.5.8 (I had version 1.5.6 before, and I do not recall it happening in that version)

Are there known steps to reproduce?

Talk to the model, move from subject to subject, after ~20 messages it will not answer what you are talking about now, but some random subject from before (usually from somewhere in the beginning).

Originally created by @Dement242 on GitHub (Jul 10, 2024). Original GitHub issue: https://github.com/Mintplex-Labs/anything-llm/issues/1841 ### How are you running AnythingLLM? AnythingLLM desktop app ### What happened? After about 19 to 20 inputs from me it feel like all of a sudden the context-window get revered or something, You can have a normal back and forth, building on the previous messages, but then from one input to the next the model get all confused and start talking about random things from earlier in the conversation, and it is impossible to get it back on track. I have to /reset and start over. I have checked and my token size is correct for llama-3: 8192, Chat history is set to 20. Windows AnythingLLM v1.5.8 (I had version 1.5.6 before, and I do not recall it happening in that version) ### Are there known steps to reproduce? Talk to the model, move from subject to subject, after ~20 messages it will not answer what you are talking about now, but some random subject from before (usually from somewhere in the beginning).
yindo added the possible bug label 2026-02-22 18:23:39 -05:00
yindo closed this issue 2026-02-22 18:23:39 -05:00
Author
Owner

@timothycarambat commented on GitHub (Jul 10, 2024):

All models have limited context windows, so at a certain point, we need to truncate or abbreviate messages from the chat window. This is just the LLM's chat history being managed in the background and especially going from subject to subject information will be lost during truncation

@timothycarambat commented on GitHub (Jul 10, 2024): All models have limited context windows, so at a certain point, we need to truncate or abbreviate messages from the chat window. This is just the LLM's chat history being managed in the background and especially going from subject to subject information will be lost during truncation
Author
Owner

@Dement242 commented on GitHub (Jul 10, 2024):

Yes, that I understand. And I made a small spelling error in the title, it should be reversed, not revered. What I expect to happen is that oldest messages get pushed out, but (as I can not see the full context that get sent to the model) I suspect every time it start to truncate at 20 message history, the model tries to answer my input and treat the absolute first (or second) message as if it was the latest message.

@Dement242 commented on GitHub (Jul 10, 2024): Yes, that I understand. And I made a small spelling error in the title, it should be reversed, not revered. What I expect to happen is that oldest messages get pushed out, but (as I can not see the full context that get sent to the model) I suspect every time it start to truncate at 20 message history, the model tries to answer my input and treat the absolute first (or second) message as if it was the latest message.
yindo changed title from [BUG]: After about 19 to 20 inputs all of a sudden the context-window get revered? to [GH-ISSUE #1841] [BUG]: After about 19 to 20 inputs all of a sudden the context-window get revered? 2026-06-05 14:39:29 -04:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: Mintplex-Labs/anything-llm#1198