Original Reddit post

Claude Code currently stops an active task immediately when the 5-hour usage limit is reached, even when the task may be close to completion. After the limit resets, continuing the old session can require Claude to process a huge amount of previous context again. The prompt cache may already be cold, so a large part of the new usage window gets wasted rereading the old session before useful work can continue. There seems to be a much simpler solution: allow the currently running task to borrow a limited amount from the next 5-hour window. For example: Allow the active task to borrow up to 10-20% of the next window. Deduct exactly that amount from the next window. Do not allow new tasks to be started during the borrowed period. Optionally prevent new subagents from being created. Apply both a token cap and a time cap. If the borrowed allowance is exhausted, automatically create a compact checkpoint and stop safely. Example: Suppose the current task needs another 100,000 tokens to finish. If Claude stops now, resuming several hours later might require: 300,000 tokens to process the old context again 100,000 tokens to finish the task Total: 400,000 tokens. With quota borrowing: borrow 100,000 tokens from the next window finish the task immediately deduct those 100,000 tokens from the next window The user receives no extra total quota. The quota is only shifted slightly forward. This should reduce Anthropic’s inference costs, preserve warm prompt caches, reduce wasted subscription usage, and make long autonomous Claude Code tasks much more reliable. Has Anthropic discussed anything like this, or is there a technical reason the quota system cannot support it? submitted by /u/The_nameless_hunter

Originally posted by u/The_nameless_hunter on r/ClaudeCode