coderabbitai / ai-pr-reviewer

AI-based Pull Request Summarizer and Reviewer with Chat Capabilities.
https://coderabbit.ai
MIT License
1.41k stars 256 forks source link

Add support for GH suggestions #496

Closed Tradunsky closed 7 months ago

Tradunsky commented 8 months ago

Right now the code change suggestions are formatted with git patch format. You can only copy paste the change and use git patch apply to have it on PR.

image

GitHub PR supports faster code suggestions: select the code frame, click on suggestions or type:

image

which turns into a prompt message with buttons to commit changes:

image
guritfaq commented 7 months ago

The problem is that committable suggestions become unreadable beyond a few lines, which is why we provide a copyable diff. We have, however, recently added committable suggestions along with a diff to our Pro version. Pro uses a different prompt from OSS.

Tradunsky commented 7 months ago

@guritfaq Do you think it would be enough to slightly modify the prompt to reformat the diff into GH suggestions?

I understand that a Pro version would have more robust features and it does make sense to have Pro version extend beyond standard offering. Just want to clarify that at this stage we are looking for Proof of Value for AI assisted code review, primarily it means that the base offering should be helpful and deliver on its purpose. When PoV is done, it does make sense to invest further into Pro version.

I primarily see a missing opportunity here to proof value, because it is additional effort to comprehend and utilize the diff suggestions. In some cases, it would be just faster for people to post code suggestions to each other than dedicating time to diff decoding.

guritfaq commented 7 months ago

@Tradunsky Excuse the late reply. Committable suggestions were in the OSS and can be found in the commit history. The challenge is that our pro version has significantly diverged from the OSS, including the prompts and it is hard to move the changes over. We will eventually roll these changes over to OSS but that will take some time.

We offer a free trial for the Pro version and can extend it if needed.