diff options
| author | Adam Malczewski <[email protected]> | 2026-06-27 18:49:50 +0900 |
|---|---|---|
| committer | Adam Malczewski <[email protected]> | 2026-06-27 18:49:50 +0900 |
| commit | d19f75caca6f6ad49e95b83021cb4cf00a39297f (patch) | |
| tree | bc106b082cc492095d502be9702a65365acbbd2a /packages/wire | |
| parent | 87e85e026e54b1dc25b0648af298ab0a8a715701 (diff) | |
| download | dispatch-d19f75caca6f6ad49e95b83021cb4cf00a39297f.tar.gz dispatch-d19f75caca6f6ad49e95b83021cb4cf00a39297f.zip | |
feat(concurrency): add "queued" ConversationStatus — emit when request blocks on acquire, re-emit "active" when slot granted
Diffstat (limited to 'packages/wire')
| -rw-r--r-- | packages/wire/src/index.ts | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/packages/wire/src/index.ts b/packages/wire/src/index.ts index 16b7023..6d10e0f 100644 --- a/packages/wire/src/index.ts +++ b/packages/wire/src/index.ts @@ -527,12 +527,18 @@ export interface TurnSteeringEvent { /** * The lifecycle status of a conversation, used for tab persistence across - * devices. `active` = an agent is currently generating; `idle` = exists but not + * devices. `active` = an agent is currently generating; `queued` = the + * request is waiting in the per-provider concurrency queue for a slot (not yet + * generating — the FE shows a loading ring, not dots); `idle` = exists but not * generating; `closed` = user dismissed the tab (hidden from the tab bar, not * deleted). New conversations start as `idle`; transitions to `active` on * turn-start, back to `idle` on turn done/error, and to `closed` on user close. + * When the concurrency extension is loaded and a request blocks on + * `acquire()`, `queued` is broadcast (persisted status stays `active`); when + * the slot is granted, `active` is re-broadcast. A request that gets a slot + * immediately never emits `queued`. */ -export type ConversationStatus = "active" | "idle" | "closed"; +export type ConversationStatus = "active" | "queued" | "idle" | "closed"; /** * Metadata for a conversation, returned by `GET /conversations` (the list |
