AgentPolicyForge: From Executable Environments to Policy Benchmarks and Adaptive Guards
Abstract
Customized agent deployments define policies over tools, resources, and execution conditions. Providing these policies in the task agent's prompt does not reliably prevent violations. Training a guard requires examples of tool calls that comply with or violate those policies. We introduce AgentPolicyForge, a framework that uses executable environments to construct policy benchmarks and iteratively train policy guards. With this framework, we construct PolicyGym, a dataset across ten policy families using 698 scenarios for training data generation and 254 separate held-out scenarios for human-reviewed test sets. Tool calls are executed and their outcomes recorded to help determine whether they comply with the policy. Every violating case uses a permitted tool, requiring checks of arguments, resources, and context rather than tool identity alone. The case construction process supports iterative guard training: an attacker generates requests using retrieved strategies, and the guard is fine-tuned on balanced, environment-verified examples. Training improves policy enforcement even with a fixed archive. Updating the archive further reduces in-domain attack success compared with keeping it fixed. We compare policy-aware task agent self-regulation with a trained policy guard. On PolicyGym, the final guard-based configuration achieves a 40-44% relative reduction in attack success rate and fewer benign rejections than policy prompting alone.
Create a lesson
Metadata
- Categories
- cs.AI, cs.CR, cs.LG
- Comments
- 20 pages, 2 figures
Related papers
From Point Clouds to Engineering Models: Benchmarking Agentic 3D Reconstruction in the Built Environment
Shared title terminologycs.AIChangyu Du, Stavros Nousias, Syed Salman Ahmed et al.
No Perfect Guardrail & No Perfect Guard: On the Decidability of Output Policies for Large Language Models
Shared title terminologycs.AIAhmed Amer, Loren Kinczel, Darrell D. E. Long
Layer-Level Control of Language Model Execution in Agent Frameworks
Shared title terminologycs.AIRan Guan, Yiqi Lin, Xiangxi Tian et al.
MetaSkill: Reusable Problem-Solving Methods for Adaptive Skill Orchestration in LLM Agents
Shared title terminologycs.AITianxing Wang, Mingming Zhao, Shuai Huang et al.
OmniDecisionBench: Evaluating and Benchmarking the Multimodal Jev-Style System One Decision Models
Shared title terminologycs.AITianxiang Gao, Jinzhe Li, Yue Zhou et al.
StudioBench: Benchmarking Agentic Multimodal Large Language Models for Productive Audiovisual Creation
Shared title terminologycs.AIXinglong Xu, Yuxia Zhu, Siyuan Li et al.