Repository navigation
Description
Summary
When the agent is busy, new messages wait in the shared message queue until the next turn. Right now the only sign of this is the queue box above the input. It shows plain dim lines with a 3-space indent, and has no header, no icon and no hint of where each entry came from. So it's easy to miss that something was queued, and a message you typed looks the same as a background job result.
Add a queue indicator to the status bar below the input. It is highlighted while the queue has entries and shows what is waiting, in FIFO order. Also give each line in the queue box a marker for its source.
Where queued messages come from
Every entry lands on MessageQueueService (internal/conversation/message_queue.go):
| Source | Enqueued by | RequestID |
|---|---|---|
| Composer (typed while the agent was busy) | ChatMessageProcessor.processChatMessage in internal/presentation/tui/handlers/chat_message_processor.go |
queued-<unixnano> |
| Background job results and notes: A2A task, background shell, subagent | Supervisor.enqueue in internal/scheduler/jobs/supervisor.go. The body starts with a [<Kind> Completed/Failed: <label>] header, e.g. [A2A Task Completed: ...] |
system |
| Host UI over stdin (headless only, never shown in the TUI) | internal/presentation/headless/control.go |
stdin |
QueuedMessage (internal/conversation/domain/queue.go) has no source field. Today the only way to tell entries apart is the RequestID string plus the message text. QueueBoxView.formatMessagePreview (internal/presentation/tui/components/queue_box_view.go) only detects the [A2A Task ... prefix, so shell and subagent results show up as a truncated body.
Proposed UI
- Status bar (
InputStatusBar.buildIndicatorPartsininternal/presentation/tui/components/input_status_bar.go): add a new segment such as☰ 3 queued, or split by source like☰ 2 you · 1 A2A. Show it only when the queue has entries, and draw it in the themeaccentcolor so it stands out from the dim indicators (indicatorPart.coloralready supports this). It follows the same pattern as the existing⚙ 1 A2A · 2 shellsjobs segment. - Queue box: prefix each line with a source marker, oldest first, so you can see both the FIFO order and whether a line is your message or an agent/job result.
- Icon: shadcn icons (lucide) are SVGs, so they can't render in a terminal. Nerd Font glyphs aren't guaranteed to be installed either. Use a plain Unicode glyph instead, kept in
internal/presentation/tui/styles/icons/icons.gonext to✓,✗and⎇. Some options are☰,≡and⇶, and the final pick is up to the implementer.
Acceptance Criteria
- Each queued entry knows its source (composer, A2A task, background shell, subagent). The source is set when the entry is enqueued, not guessed from the message text.
- While the queue has at least one entry, the status bar below the input shows a queue indicator (icon + count) in the
accentcolor. It disappears once the queue is empty. - The indicator updates as soon as a composer message or a background job result is enqueued or drained, without waiting for another keypress.
- Each line in the queue box has a source marker, so a message you typed looks different from an A2A, shell or subagent result. Every job result collapses to its one-line
[<Kind> Completed/Failed: <label>]header (today only A2A does). - New
chat.status_bar.indicators.queuetoggle (defaulttrue), documented with the other indicators indocs/configuration-reference.md. - The icon renders in a default terminal font and adds no new dependency or Nerd Font requirement.
- Unit tests:
InputStatusBarshows the indicator only when the queue is non-empty, andQueueBoxViewrenders a different marker for each source.
Notes
InputStatusBarhas no queue reference yet. Pass it the queue the same wayInputView.SetMessageQueuereceives it.Enqueuenever setsQueuedAt, so it is always the zero time. This feature doesn't need it, but it has to be set if the UI ever shows how long an entry has been waiting.- Related bug that probably deserves its own issue: arrow-up (
InputView.navigateHistoryUpininternal/presentation/tui/components/input_view.go) dequeues the head of the queue whatever its source. If a background job result is first in line, it gets pulled into the input box and removed from the queue. Non-text entries (e.g. messages with images) are dequeued and dropped. Once entries carry a source, arrow-up should only restore composer entries.
Original request
Would be cool to see some icon add below the input that looks like a queue FIFO highlighted so it's visible that a message entered the queue, some queue message will arrive from A2A agents some queue message will arrive from the composer, all of them should be visible in the bottle icon, use shadcn icons or something from charm that looks nice.
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsDone
Activity
[-][FEATURE] Style queue messages better[/-][+][FEATURE] Show a queue indicator below the input and mark queued messages by source[/+]edenreich commentedon Sep 27, 2026
@infer please implement this issue, and create a demo of the queue indicator once it works.
For the demo: the demo terminal has no provider API keys, so build the CLI and run
infer chatagainst the mock gateway (INFER_GATEWAY_MOCK=true, withINFER_GATEWAY_MOCK_SCENARIOSpointing at a scenario file under /tmp if you need a slow turn). Then send a second message while the agent is still busy, so the☰queue indicator in the status bar and the source markers in the queue box are visible.inference-gateway-maintainer commentedon Sep 27, 2026
Model:
ollama_cloud/glm-5.3-flash· View JobTodos
Pull Request
#1355
The agent hit the job's time limit before finishing, so it was stopped to salvage its work. Its committed changes were pushed; the draft pull request is linked above.
delay_msis supported per turn. Now let me check the e2e tmux harness - it can drive the TUI programmatically with the mock gateway:Model:
ollama_cloud/glm-5.3-flash· Exit Code:0· Duration: 23m 44sTokens: 11,532,462 in · 62,082 out · 11,594,544 total (103 requests)
Tool calls: 163 total · 100% success rate
Traces
Stats
Triggered by edenreich · Infer Action · OSS
inference-gateway-releaser commentedon Sep 27, 2026
🎉 This issue has been resolved in version 0.213.0 🎉
The release is available on:
Your semantic-release bot 📦🚀