Update DCR prompt to include full files
What does this MR do and why?
- This MR updates the DCR prompt to send full files attached at the bottom of the prompt
- Prompt changes are behind the feature flag,
duo_code_review_full_file
- Feature flag rollout issue: [Feature flag] Rollout of `duo_code_review_full... (#537556 - closed)
How to set up and validate locally
Prerequisites:
- Make sure the AI features are enabled locally using this guide
- Enable
duo_code_review_full_file
feature flag for the user - Open a MR with some files where context from full files in one-go is relevant such as adding a duplicate method with the same name.
- Assign
GitLabDuo
as a reviewer either by commenting/assign_reviewer @GitLabDuo
or selectGitLabDuo
from the reviewers dropdown.
Validate:
-
Make sure GitLabDuo
works as expected withoutduo_code_review_full_file
being enabled. -
Enable duo_code_review_full_file
and make sureGitLabDuo
calls out adding a method with a duplicated name (btw this context wouldn't be present in the diffs so it's a great test case to test). -
Make sure there are no unwanted comments from GitLabDuo
.
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Related to #510266 (closed)