I saw @dexhorthy interviewed by @GergelyOrosz recently - great chat, worth checking out
He talked about how AI coding sessions have a "trajectory"
I.e. the agent tends to pick up habits during the session. If it verifies the app by cURL once, it'll probably do it when you request the next change.
Sometimes you need to clear the context just to change trajectory.
I've even seen this when you have state that's retained across sessions. I've got a personal podcast generated from my feed. All previous podcast transcripts are available for it to view. So it picks up recurring catchphrases, and annoying traits. It's started over-focusing on meaningless metrics (wow, 400 bookmarks on this post!). My podcast is on a bad trajectory.
The "trajectory" metaphor gets really scary for codebases. Codebases are stateful - they accumulate state over sessions. So every codebase has a trajectory, and most trend down.
The only way to fix a bad trajectory is with better steering, and by changing the environment the agent works in.
Cool stuff. Thanks Dex