Why and how to start new AI sessions frequently
A tip for saving tokens and working with AI agents more comfortably, in case you haven’t built a convenient harness yet. How do you keep the context from growing too large?
Unless you’re an experienced AI user, I don’t recommend the /compact command in Claude Code or Codex: you risk losing important information. And don’t wait for the agent to compact the context automatically either: that happens once 50%+ of the model’s context window is full, and by then the quality of its answers has already dropped noticeably.
Start a new session as soon as you feel the context holds a lot that is irrelevant to your next prompts. If you can’t feel it yet, check with the /context command in Claude Code or /status in Codex.
To avoid writing a starting prompt by hand every time, ask Claude in the old session:
Write a handoff
or
Let’s continue in a new session
The second one also makes it write a temporary handoff.md file with everything needed to continue.
One drawback: if you sometimes go back to old sessions, titles like “Handoff reading” make them impossible to tell apart. So it’s often better to ask the agent for a starting prompt in a code block instead.
So a long task is usually a sequence of several sessions. If you have your own harness, let it tell you when it’s time to switch. If not, use any of these options, and you won’t have to rack your brain over carrying context from one session to the next.