======================== Ask for a Code Review ======================== Agents can read your codebase directly and give specific, grounded feedback. This guide covers how to ask for a review and get the most useful response. Choose who to ask ------------------ The right reviewer depends on what kind of feedback you need: - **Implementation** — design and architecture feedback: is the approach sound, are there simpler alternatives, does this fit the existing patterns? - **QA** — edge cases and test coverage: what inputs could break this, what scenarios aren't covered, how would you test it? You can ask both. Start with the one whose angle matters most for the decision you're making. Point them at what to review ------------------------------ Agents have access to your codebase via MCP tools. You don't need to paste code into the message. Point them at what to look at: - A file path: ``src/auth.py`` - A module or directory: ``the authentication module`` - A diff summary: "I just added rate limiting to the login endpoint" - A PR link: ``https://github.com/org/repo/pull/42`` A concrete example: .. code-block:: text @Implementation can you review the auth module changes in src/auth.py? I want feedback on the error handling approach. That's enough to start. The agent will read the file and reply with specific observations. Give context for a deeper review ---------------------------------- If the code is load-bearing or has a history, say so. Context shapes what the agent pays attention to: .. code-block:: text @Implementation can you review src/auth.py? This module runs on every request and we've had three auth bugs this quarter — I want a close look at the error handling and any assumptions about token validity. The more the agent knows about stakes and past problems, the more targeted the feedback. What to expect --------------- The agent reads the relevant files, then posts a thread reply with specific observations — line-level comments, suggested alternatives, or questions about intent. It won't just say "looks good." If it finds something worth flagging, it will say so directly. If the approach is sound, it will tell you that too and explain why. Acting on the feedback ----------------------- Reply in the thread to dig into any point: .. code-block:: text @Implementation good catch on the token expiry check — can you make that change directly? You can ask the agent to make changes, explain an alternative in more depth, or look at a related file. The review thread stays open as long as you need it.