newsfilter
← Interviews
AI Engineer12 min

Should This Merge? — Itamar Friedman, Qodo

Itamar Friedman

Conference Presentation, Keynote
  • The proliferation of AI code generation tools is causing an influx of multiple simultaneous Pull Requests (PRs), which degrades review SLAs and necessitates the automation of the bottleneck.
  • Current AI code review tools primarily identify specific findings but fail to provide a definitive decision on whether a PR should be merged; the proposed solution is a "merge risk" estimation feature.
  • To automate decision-making, AI models must be trained to distinguish between three scenarios: auto-approve, halt the PR, or escalate to human review for high-level judgment.
  • Automation targets must address the entire work package, acknowledging that while PRs are useful for atomic reversibility, the approval process for multi-PR packages must also be automated.
  • Merge risk assessment requires breaking down the evaluation into specific failure modes, including revertibility, recoverability, and the severity of potential failure.
  • The framework proposes three orthogonal metrics to estimate risk, which can be combined for higher accuracy than a single numeric score:
    • Potential Damage: Evaluates the severity of the impact based on the change type (e.g., shared transaction libraries vs. documentation).
    • Blast Radius: Assesses the reach of the change and its implicit impact on user stories and components.
    • Behavioral Complexity: Distinguishes between change size and intrinsic complexity (e.g., concurrency ordering, algorithmic shifts) that increases error probability for both humans and AI.
  • AI tools should provide senior-reviewer level descriptions (concise, one-sentence summaries per metric) rather than simple labels, including links to supporting evidence and actionable prompts to mitigate risk.
  • Risk estimation is an iterative process, not a one-time event; developers should be encouraged to re-engineer code to lower the estimated risk score before re-evaluation.
  • A three-lane automation strategy is recommended for achieving "Software Factory Level 4" automation:
    • Low Risk: Auto-approve to maximize throughput.
    • Medium Risk: Require human reviewer approval on the PR or work package.
    • High Risk: Mandate human review of the specification, plans, and code.
  • The approach rejects "self-scoring" by the coding agent due to inherent bias and compliance tendencies; risk estimation must be an independent, composable signal.
  • "Merge Risk" is distinct from other signals; a high-risk score does not automatically block a merge if all other findings (security, AI code review) are addressed, but unknown risk levels are treated as high risk.
  • Codo is presented as an interface that aggregates these metrics to provide a general risk score, high-level explanations of the three orthogonal factors, and detailed one-sentence summaries.
  • Future goals include moving the majority of PRs into the "green" (low risk) lane while minimizing "yellow" and "red" lanes, reducing the need for human judgment on routine decisions.