Skip to content

Long-chat drift

What it looks like

The first twenty messages go well. Then the assistant starts to wander. It forgets a name the user gave early on. It slips back into a style you told it to avoid. It contradicts a decision made an hour ago. No error, no cut-off reply, just slow decline.

Why it happens

Two things are usually going on.

First, the history may be getting trimmed. If your framework drops old messages to stay under the context window, early facts are simply gone. That is truncation, covered in Truncation and lost instructions.

Second, even when everything fits, a long context is harder to use well. The model has to pick the right details out of a lot of text. Important facts from early in the chat now sit among hundreds of later messages, and they compete with everything that came after. Models are generally less reliable at finding one detail in a very long context than in a short one. Results vary by model, so test your own.

How to spot it

Fix checklist

  1. Keep a short running summary of key facts and decisions, and send it with each call.
  2. Repeat the most important rule near the end of the prompt, close to the new message.
  3. Trim old chatter yourself instead of sending the full history.
  4. Start a fresh session when the topic changes, carrying over only the summary.
  5. Test long sessions on purpose before release.

Lasting fix

  • COSMOS (in development): stop losing your fixes and decisions every time an AI session ends.
  • CM Sessions (in development): find any AI coding session on your machine and pick it back up.

Related on Solaro sites

  • LMNator : see how a model holds up when someone actually tests it.

See how much of the context window your chat history uses in the Context planner

Next

Trim history without losing the goal and Put the important instruction last.

All failure modes