Refactoring becomes a collaborative code-review tactic when AI identifies an improvement, proposes the change inline, and lets the team decide whether to integrate it. A reviewer can point to a specific concern; an author can use the same capability as a first review of their own pull request. section 13.3 section 13.6
Choose the level of assistance that fits the pull request and your team’s confidence:
- Target a selected region with a natural-language request, such as asking What The Diff to register code as a singleton; review and accept the generated change with one click. section 13.3
- Ask Qodo’s /improve command for maintainability improvements or overlooked best practices; use --extended when a larger pull request needs segmented, proportionate suggestions. section 13.3
- Keep human judgment in the loop: validate context and nuance, avoid treating suggestions as approval decisions, and introduce the capability cautiously. section 13.6
A practical review exchange
A reviewer notices that a pull-request change could be improved but cannot yet articulate the exact edit. They comment on the relevant lines with a focused refactoring request. The AI proposes an inline patch; the author reviews it, adjusts it if needed, and integrates it only after human validation. The author could have run the same improvement command before requesting review. section 13.3 section 13.6
Figure 13.3 What The Diff generated suggestion to register selected code as a singleton
Inspect the generated suggestion for registering selected code as a singleton. section 13.3
Figure 13.4 Output of Qodo /improve command with the --extended flag
Inspect how Qodo’s extended improvement command segments a larger pull request and generates proportionate suggestions. section 13.3





















