← Lab /AI/ML

Agentic RL framework improves interprocedural vulnerability detection accuracy

VulAgentRL achieves higher pairwise-correct detection rates than baselines while making fewer tool calls

AI/ML arXiv 29 Jul 2026 Method Prototype evidence

Published as “Graph Is the Verifier: Agentic Reinforcement Learning for Interprocedural Vulnerability Detection”

Why it matters

The method enables more accurate, evidence-grounded vulnerability detection with reduced tool-call overhead, making large-scale code auditing more practical.

Summary

VulAgentRL achieves the highest pairwise-correct rate (0.378) and accuracy (0.633) among all evaluated baselines, while using fewer tool calls. It does this by treating a Code Property Graph both as a queryable tool at inference time and as an exact verifier of the evidence cited by the policy, enabling a composite reward that rewards grounded verdicts. A warm-start via teacher-distilled supervised fine-tuning is required because reinforcement learning alone cannot learn tool-use behavior. The approach outperforms frontier models and prior agentic detectors on both in-distribution and out-of-distribution corpora, and remains robust under severe class imbalance.

What they found 2

  1. VulAgentRL (SFT + RL) attains a pair-wise-correct rate of 0.378 and accuracy of 0.633, surpassing the best baseline.

    “VulAgentRL SFT + RL 0.378 0.633”

  2. 71.7% of vulnerable functions need interprocedural evidence beyond the function body to be classified correctly.

    “Real-world vulnerabilities often span multiple functions, yet most learning-based detectors classify each function in isolation: on a sample of real CVEs, we find that 71.7% of vulnerable functions require evidence from outside the function to be classified correctly.”

Caveats 1

  • the SFT warm-start is structurally required, since GRPO cannot bootstrap tool-use behavior it never samples.

What’s new here 4

  • Uses a Code Property Graph simultaneously as a query interface and as a precise evidence verifier for reward computation.
  • Introduces a composite reward that includes verdict correctness, evidence-node grounding, and CWE classification, avoiding brittle textual matching.
  • Demonstrates that supervised fine-tuning is a structural prerequisite for RL to acquire tool-use behavior in this setting.
  • Shows consistent gains across repository-level splits, out-of-distribution data, and extreme class-imbalance ratios.