Skip to content

tracing: trace waterfall + summary prompt + chat tab all lose data after each agent turn #896

Description

@sahrizvi

The trace UI (/traces in the TUI) drops most of the conversation data after every agent turn. Three observable symptoms in a normal multi-turn session on altimate-default:

  1. Waterfall view collapses to the system-prompt span after each agent turn. Real session has many tool calls and generations; trace file on disk has 1 root span and metadata: {} once the turn completes.
  2. Summary tab shows "What was asked / No prompt recorded" even when a real user prompt was typed.
  3. Chat tab shows only the last user message in multi-turn sessions. Earlier user turns render as their assistant responses but the user's "▶ You" bubbles are missing.

Repro

Open a TUI session, send a couple of messages with tool-using replies (e.g. "list directories", then "okay, how about patches"), open /traces, watch the file:

ls -la ~/.local/share/altimate-code/traces/ses_<id>.json
jq '{spans: (.spans | length), metadata, summary}' ~/.local/share/altimate-code/traces/ses_<id>.json

Before the fix: spans: 1, metadata: {}, summary counters at 0/null, regardless of how much activity the DB shows for the session. The viewer's chat tab shows only one ▶ You bubble for the latest prompt.

Scope

Closed by the fix in this PR. Filing for traceability so the merge cleanly closes a tracked symptom report.

Activity

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

Metadata

Metadata

Assignees

Labels

bugSomething isn't working

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions