Skip to content

Claude local-command and synthetic transcript rows render as user prompt rows #338

Closed

Description

@Juliusolsson05

Problem

Claude transcript rows generated by local commands and resume/model-switch scaffolding can render in the main feed as if they were normal conversation content.

Evidence

Bundle:

~/.config/agent-code/debug-bundles/manual/2026-06-22T12-46-15-717-c973322e

Note:

"Once again, we are so often spitting out commandds in to the user prompts somehow"

Raw transcript evidence from:

~/.claude/projects/-Users-juliusolsson-Desktop-Development-senea/fd3799da-01af-4aa2-a601-0aeedb970516.jsonl

  • Line 2329: isMeta: true local-command caveat, correctly hidden by feed visibility.
  • Line 2330: non-meta user row with <command-name>/compact</command-name>..., rendered as a visible user prompt row.
  • Line 2331: non-meta user row with <local-command-stdout>Compacted...</local-command-stdout>, also rendered as a visible user prompt row.
  • Feed debug shows only the caveat hidden as meta_filtered; command/stdout rows are added as visible entries.

Suspected Cause

Feed visibility uses a weaker synthetic-row predicate than other prompt surfaces.

visibleDecisionForEntry in src/renderer/src/features/feed/model/renderModel.ts filters non-conversation entries and isMeta === true, but does not apply the stronger Claude prompt predicate already used by:

  • src/renderer/src/features/workspace/lib/latestUserPrompts.ts
  • src/main/sessionIndex.ts

Those paths skip Claude user rows without permissionMode and skip text starting with <, catching <command-name>, <local-command-stdout>, <environment_context>, etc.

Expected

Local-command caveats, command envelopes, command stdout, environment context, and other synthetic prompt scaffolding should not render as normal user prompt rows.

Suggested Fix Direction

Centralize a shared visible-conversation-row or synthetic-Claude-user-row predicate and use it in feed projection. Add a debug reason such as synthetic_user_filtered so saved bundles explain the decision.

Activity

  1. added a commit that references this issue on Jul 6, 2026
  2. Juliusolsson05 commented on Jul 7, 2026

    @Juliusolsson05
    OwnerAuthor

    Fixed by the ledger's committed collector (#425): isSyntheticClaudeUserRow (src/renderer/src/rendering/observations/committed.ts) filters <command-name> / <local-command-stdout> / <environment_context> synthetic Claude user rows with the decision reason synthetic-user-filtered, verified by the #338-named test in committed.test.ts. The ledger is now the sole feed decision core (#483). Closing.

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

    bugSomething isn't workingprovider:claudeAffects Claude Code integration

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions