Skip to content

session: replay presents generated interruption bookkeeping as assistant speech #1617

Description

@santoshkumarradha

What happened

Resuming the actual reimbursement workflow in PR #1607 revision fd6256012 displayed [incomplete tool call dropped when you steered] as an ordinary assistant reply. The preceding live conversation had been interrupted while tool arguments were streaming. This string is generated by the engine, not spoken to the person by the model.

Replication

Build with make build and open bin/codeaf chat --model deepseek/deepseek-v4.1-flash --one-model --no-host with an OpenRouter key. Ask for a feature that writes files, then send a correction while a write call is still forming. Close and resume that same saved conversation. If the interrupted response contained a partial tool call, the saved assistant message contains the engine-generated dropped-call annotation; replay currently renders it as human-facing prose.

The deterministic regression should interrupt a response containing both an intended-human partial update and a forming tool, persist it, reload the journal, and inspect the shared display entries. Preserve the human update and provider-facing explanation while keeping generated bookkeeping out of normal conversation prose.

Where

keepSteeredPartial and cutDroppedCallNote in internal/session/loop.go append bookkeeping to assistant text. Display/replay classifies the entire tool-free assistant message as an answer. The analogous reader-handoff annotation uses the same path.

The fix

Carry the distinction between model speech and engine-generated interruption bookkeeping at its source. Preserve provider context and records; live, resumed, task and nested presentation must keep intended-human text readable and place operational details behind disclosure. Do not hide arbitrary assistant text using a prose heuristic.

Acceptance

  • e2e: Resume the same meaningful real workflow after steering during a forming call; the user correction and intended-human updates remain, with no generated dropped-call annotation presented as a normal answer.
  • e2e: Continue to a working report and preserve exact-revision recordings and model audit.
  • Unit: Mixed human text plus generated interruption context, tool-only interruptions, reader handoff, replay, and genuine quoted text retain their proper audiences.

Related to #1605 and PR #1607. No duplicate issue for the dropped-call display annotation was found.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:chatThe v3 surface a person sits in front of (internal/tui3)area:sessionThe engine — turns, tasks, the toolbelt, checkpointsbugSomething the code does that it should not

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions