Skip to content

LLM-generated PR + commit content lack context #1504

@adboio

Description

@adboio

problem

we make isolated LLM calls to generate PR title/body and commit messages.

these generations lack context - they use only the diff to write content.

this often results in misinformed PR descriptions. see PostHog/posthog#53451 for example:

  • one-line change to add LIMIT 50000 to a query
  • the intent was to override the implicit default LIMIT 100 that is applied to hogql queries
  • the agent in posthog code was fully aware of this intent
  • BUT the original generated PR description said something along the lines of "adding a limit to prevent unbounded queries" (which was actually the opposite of my goal)

desired solution

some way to pass more context to the content generators. ideally the agent just does it.. but imo it'd be a cleaner UX if those prompts/responses didn't end up in the chat logs, so i'm not 100% sure what the best option is.

maybe some sort of sub-task that forks -> summarizes/compacts -> reads summary + diff to generate?

Metadata

Metadata

Assignees

Labels

EnhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions