Snooze a thread until provider limits reset #8920
vitalyiegorov
started this conversation in
Ideas
Replies: 2 comments
|
Implementation is up as a small PR: #9012 — typed |
0 replies
|
Update on #9012: since #9507 landed, every client already receives each provider's usage windows with reset times on the provider snapshot, so the PR is now client-only (no contract, server, or migration change) and covers both places you reach for a snooze:
Both are built from one shared preset, so they can never disagree on the wake time.
|
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment



Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
When Claude or Codex hits a usage limit mid-turn, the thread just stops and leaves one muted line behind. It still sits in the inbox looking like live work, and the reset time is now yours to remember.
Today: a stalled thread and a timestamp you have to hold in your head.
Offer a one-tap snooze next to that line, prefilled with the reset time the provider already sends us. The thread drops into the snoozed shelf and comes back exactly when the limits do (one minute past reset, so clock skew can't wake it early). Nothing auto-resumes — snooze stays visibility-only, same as today. Claude and Codex only; Cursor, Grok and OpenCode don't report a usable reset time, so no offer there.
Snooze already accepts an arbitrary wake time. This just fills it in.
Proposed: the same notice, with a quiet inline action.
Sketch:
packages/contracts/src/providerRuntime.ts:707—account.rate-limits.updatedcarriesrateLimits: Schema.Unknownand has no consumers. Give it a typed shape withresetsAt; both adapters already forward it (ClaudeAdapter.ts:3548,CodexAdapter.ts:1416), and both SDKs type a reset epoch — optional on Claude's side, so the offer only renders when it's present.resetsAton thread state in the read model.snoozeThread(threadRef, resetsAt + 60s)(apps/web/src/hooks/useThreadActions.ts:657) behindcanSnooze. No scheduler needed; wake is derived fromsnoozedUntil.A typed
resetsAtis also exactly what an auto-resume scheduler like #8577's would need to read, so none of this is throwaway if that lands later.Prior art: #8401, #8577 and #6796 all propose auto-resume, and #6513 is the same complaint in bug-report form — four independent asks for this pain. Auto-resume is a bigger design question this doesn't need to resolve; this is the smallest piece that's useful on its own and doesn't preempt it.
Happy to send it as a small PR (contract, adapter typing, one web component) if you want it.
All reactions