newestAssistantEmpty reports whether the turn's final assistant message carried neither text nor a structured tool call. A clean finish always has a summary and a continuing turn always has a tool call, so an empty newest assistant message is always an anomaly: the model stopped mid-task, or its cal
(history []chmctx.Message)
| 993 | } |
| 994 | m.finalizeTurn(outcome) |
| 995 | m.endTurn() |
| 996 | return m.fireQueued() |
| 997 | } |
| 998 | |
| 999 | // fireQueued auto-submits a prompt the user queued mid-turn, once the turn has |
| 1000 | // wound down to idle. Reached only from the natural finish path (here, after |
| 1001 | // finalizeTurn/endTurn); a Ctrl+C or stream-error abort routes through abortTurn |
| 1002 | // and never gets here, so an interrupt leaves the slot for a manual send. No-op |
| 1003 | // when nothing is queued. The expanded send goes to the LLM, the collapsed echo |
| 1004 | // to scrollback, exactly as a typed submit; the recall entry carries the expanded |
| 1005 | // text (no chip), matching disk-loaded history. |
| 1006 | func (m Model) fireQueued() (tea.Model, tea.Cmd) { |
no outgoing calls