You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Bug: steering injection pulls from Queue-immediacy items; DefaultInputQueue should default to Immediate #49
TryDequeueNextImmediateOrQueued consumes items from both ImmediateandQueue-immediacy queues. Steering injection at a tool-result boundary should only ever pull Immediate items. Queue-immediacy items are semantically "hold this until the current run completes and submit as the next independent turn"; pulling them mid-run via the steering path bypasses that intent.
Normal user text typed into the chat input goes to DefaultInputQueue (via AgentChat.EnqueueUserMessage → DefaultInputQueue). The expected UX is that a message sent while the agent is in the middle of a tool loop gets injected at the next tool-result boundary as steering — i.e., Immediate semantics. With Queue semantics it would not be consumed by TryDequeueNextImmediate at all (and after fixing Bug 1, it also would not be consumed by steering injection even with the old TryDequeueNextImmediateOrQueued).
Fix: change the default immediacy to Immediate:
Immediacy=AgentInputQueueImmediacy.Immediate,
Users who want to explicitly hold a message until the current run finishes can use a Queue- or Held-immediacy queue explicitly; that should not be the default.
Fixed in commit 83187c5: DefaultInputQueue now uses Immediate immediacy; ToolResultSteeringMiddleware.InjectQueuedIfToolResult now calls TryDequeueNextImmediate to only inject Immediate-immediacy items at tool boundaries.
Result: Implementation found, all verification criteria satisfied, tests present and green.
Bug 1 — \ToolResultSteeringMiddleware.InjectQueuedIfToolResult\ now calls \TryDequeueNextImmediate\ (not \TryDequeueNextImmediateOrQueued), so Queue-immediacy items are not consumed at tool-result boundaries. Covered by new test \QueueImmediacy_ItemsNotInjected_AtToolBoundary.
Bug 2 — \DefaultInputQueue\ is now created with \Immediacy = AgentInputQueueImmediacy.Immediate. Covered by updated test \Constructor_DefaultQueueStartsImmediate_AndImmediateQueueStartsImmediate\ in \AgentChatTests.
Activity
JoshuaRowePhantom commentedon Jun 25, 2026
Fixed in commit 83187c5: DefaultInputQueue now uses Immediate immediacy; ToolResultSteeringMiddleware.InjectQueuedIfToolResult now calls TryDequeueNextImmediate to only inject Immediate-immediacy items at tool boundaries.
Fix steering queue immediacy bugs
Inject steering messages at tool-boundary in the running item, not af…
JoshuaRowePhantom commentedon Jun 30, 2026
Verification passed
Checked: Commit 83187c5 ("Fix steering queue immediacy bugs") on the \eatures\ branch, files:
Result: Implementation found, all verification criteria satisfied, tests present and green.
Bug 1 — \ToolResultSteeringMiddleware.InjectQueuedIfToolResult\ now calls \TryDequeueNextImmediate\ (not \TryDequeueNextImmediateOrQueued), so Queue-immediacy items are not consumed at tool-result boundaries. Covered by new test \QueueImmediacy_ItemsNotInjected_AtToolBoundary.
Bug 2 — \DefaultInputQueue\ is now created with \Immediacy = AgentInputQueueImmediacy.Immediate. Covered by updated test \Constructor_DefaultQueueStartsImmediate_AndImmediateQueueStartsImmediate\ in \AgentChatTests.