Beyond Aggregate Risk: Role-Stratified Conformal Risk Control for LLM Tool Calls

Md Ashikur Rahman, Md Arifur Rahman, Niamul Hassan Samin, Khandaker Rifah Tasnia, Sifat Rahman Ahona +1 more
7/27/2026
cs.LGcs.AIcs.CL

No confident code implementation found for this paper.

Abstract

Language-model agents act through structured tool calls whose arguments carry different risks. Untrusted content may safely influence an email body but should not determine a recipient, account, command, or credential. Existing statistical methods typically control risk over the entire action, allowing failures in rare, high-risk fields to be obscured by benign arguments. We introduce role-stratified per-field conformal risk control, a calibration layer that wraps any per-field detector and sets separate thresholds and risk budgets for semantic argument roles. For a role with prevalence $p_r$, aggregate-only certification must use an effective budget of $αp_r$ to guarantee role-specific risk $α$, whereas role-stratified calibration certifies each sufficiently sampled role directly with a finite-sample guarantee; rarer roles are handled by pooled certification. Across AgentDojo and InjecAgent with six language models, the empirical utility gap tracks this predicted price of coarseness, and our method achieves the most consistent role-specific budget compliance under model and attack transfer, detector noise, gradual drift, unseen tool suites, and adaptive attacks. It provides formal per-role guarantees under exchangeability or after recalibration, and empirical compliance under frozen distribution shift. These results suggest that structured tool calls should be certified at the semantic-role level, not the whole action.

View on arXivView PDF

Code Implementations

No confident code match yet

We couldn't find an author-owned or strongly-evidenced community implementation for this paper. Any repos shown below are weak matches — verify before relying on them.

No code implementations found yet.

Know of an implementation? Let us know in the comments below!

Similar Papers

Cite this paper

@article{rahman2026beyond,
  title  = {Beyond Aggregate Risk: Role-Stratified Conformal Risk Control for LLM Tool Calls},
  author = {Md Ashikur Rahman and Md Arifur Rahman and Niamul Hassan Samin and Khandaker Rifah Tasnia and Sifat Rahman Ahona and Juena Ahmed Noshin},
  year   = {2026},
  eprint = {2607.24343},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2607.24343v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2607.24343.svg)](https://codeofpaper.com/paper/2607.24343)

Discussion