Skip to main content
bash TV

How to Build an AI Code Review Agent - Daksh Gupta, Greptile

AI Engineer

12.2K views26 Oct 2026

YouTube

Daksh Gupta, co-founder of Greptile, which reviews about 1% of all pull requests on GitHub, shares what Greptile tells companies that want to build their own review agent. Starting from a simple sandbox-plus-webhook setup, he explains why it misses bugs, costs $3-25 per PR and floods you with nitpicks, then walks through the fixes: targeted prompts, a dataset of past incident PRs, model inversion (reviewing Claude-written code with GPT and vice versa catches about 10% more bugs), codebase context and a living wiki, autonomous testing in sandboxes with computer use, and routing cheaper models to most subtasks. Chapters 00:00 Intro: Greptile and why companies build their own 01:22 What makes a great review agent 02:38 The simple version: sandbox, agent, webhook 03:55 What goes wrong 06:02 Fix 1: Better prompts and fewer nitpicks 07:44 Fix 2: A dataset of historical PRs 09:02 Fix 3: Model inversion 11:04 Fix 4: Codebase context 12:36 Docs, tickets and a living wiki 14:26 Fix 5: Autonomous testing with computer use 16:05 Fix 6: Cheaper models for most subtasks Daksh Gupta, Greptile Join us in SF for the second annual AIE CODE summit: https://aie.codes our last flagship summit of 2026. Applications live now!

Join the discussion

Sign in to join the discussion

Sign in