How to continue Claude session task after hitting token limit mid-way (instead of restarting from scratch)?
I've integrated an MCP (Model Context Protocol) server with Claude to run automated QA testing on Android applications. The problem is that after completing roughly half the test cases, Claude runs out of tokens/hits usage limits, and I have no clean way to resume from where it left off , I end up having to start the whole testing run over again.
What I'm trying to figure out:
Is there a way to persist the current task state (test progress, findings, current step) somewhere external, so a fresh Claude session can pick up exactly where the previous one stopped instead of starting from 0%?
Has anyone tried "handing off" a task between two separate Claude instances, for example, running one Claude instance inside a VM, giving it access to the current project state, and having it continue work that another instance left at, say, 20% completion?
Basically I want to treat the task state as external/persistent rather than living only inside one chat session's context window, so I can swap in a new Claude account when the old one runs out of usage, without losing progress.
Would appreciate any pointers — especially from people who've built long-running or multi-session agent workflows with Claude/MCP, or anyone using a checkpoint/handoff pattern for similar automation tasks.
Tech stack: Claude + MCP server for Android QA automation.