feat: report starter_action_picked from the TUI starter

Merged
RA
1mo ago
+204-2

Closes #1601

Stacked on #1513, review only the commits above it.

What

  • New starter_action_picked row: the action (prompt, open or done), prompt_index for a prompt, and workspace_id. Never the prompt text.
  • Both TUI starter dialogs (the post-link confirmation and /workspace, Get started) report each selection from onSelect. The helper lives in its own small module, so the TUI does not load the starter's builder.
  • The served starter now carries workspaceId, so a pick names the same workspace as its starter_shown row. The field is additive for the extension's chat.
  • The CLI link command prints the starter as text with no choice to make, so it reports nothing.

Why

The shown row says the starter was served. Nothing said what the user did with it, so the funnel could not tell use from dismissal.

Cost side effects

One row per selection, nothing on render.

Verification

  • bun test on the new test file and the starter tests: 38 pass, 0 fail. Removing the new workspace id from the starter fails the join test.
  • Typecheck clean. Marker Guard strict: no shared files modified.

Review contract

Claims:

  • C1. Each selection of a starter option in either TUI dialog tracks exactly one picked row.
  • C2. The row carries action, workspace id, session id and timestamp, plus prompt_index only for a prompt. No prompt text reaches it.
  • C3. In the post-link dialog, a selection made before the starter arrives tracks nothing.
  • C4. A pick's workspace id equals the workspace id of the shown row for the same served starter.
  • C5. A telemetry failure never blocks the selection's own effect.

Residuals:

  • R1. Dismissing a dialog with Esc reports nothing: it is not a selection.
  • R2. The session id is the TUI thread's telemetry context, as for the engine offer rows from the same file. It may not match the server's session.
  • R3. The row does not say which of the two TUI dialogs the pick came from.
  • R4. The extension's chat pick is not in this PR.

šŸ¤– Generated with Claude Code

https://claude.ai/code/session_01YNasdD5tQMNtzXsuMEy82X