Automated code analysis plays a key role in improving code quality and compliance. https://docs.aws.amazon.com/codeguru/latest/reviewer-ug/welcome.html provides automated recommendations that can assist developers in identifying defects and deviation from coding best practices.
While CodeGuru Reviewer can provide automated code analysis and recommendations, Bedrock offers a low-friction environment that enables you to gain insights on the CodeGuru recommendations and to find creative ways to remediate your code.
Build a Bedrock prompt using three elements, as illustrated in the screenshot below: The source code copied from CodeCommit The CodeGuru Reviewer recommendation A request to refactor the code to address the code analysis finding
At this point, the developer has learned a lot about the code, SQL injection attacks and the CodeGuru Reviewer recommendation.