Skip to content

feat(signals): view agent-proposed fix as a diff#2207

Draft
Twixes wants to merge 1 commit into
mainfrom
posthog-code/signals-proposed-fix-patch
Draft

feat(signals): view agent-proposed fix as a diff#2207
Twixes wants to merge 1 commit into
mainfrom
posthog-code/signals-proposed-fix-patch

Conversation

@Twixes
Copy link
Copy Markdown
Member

@Twixes Twixes commented May 19, 2026

Problem

When the signals research agent flags a report as actionable, we want to see its proposed fix as a diff inside PostHog Code — without spinning the sandbox back up.

Changes

  • Fetch the PROPOSED_FIX_PATCH artefact for a signal report
  • Unpack the JSON envelope {base_sha, base_ref, stats, patch} and render patch in the built-in diff viewer
  • Stats banner (files / +lines / -lines) above the diff
  • Drift indicator when base_sha no longer matches current origin/main
  • Graceful empty state when the artefact isn't there yet (not actionable, or still running)

(Fill me in once it lands.)

How did you test this?

I'm an agent — nothing tested yet.

Publish to changelog?

no


Pairs with https://github.com/PostHog/posthog PR for the producer side.

Created with PostHog Code

Generated-By: PostHog Code
Task-Id: 12875c31-f8d4-46cc-8f47-074a32b01b71
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant