I Stopped Trusting AI Agents With Tools. So I Built a Gatekeeper
说明与用途
为 AI 代理构建了一个确定性权限引擎,使用上下文风险评估来评估工具调用。通过 83 个真实代理和 10 个框架的现场测试验证了其有效性,防止了未授权操作。
问题
AI agents often have binary allow/deny permissions, leading to over-privileged actions or approval fatigue, and mock agents hide real integration problems.
结果
Implemented a deterministic, contextual permission engine that prevented unauthorized tool usage across 83 real agents and 10 frameworks, achieving 100% pass rate in field tests and exposing 7 real integration bugs that would have been missed with mock agents.
工作流
- Define policy and architecture before coding
- Build adapters for 10 agent frameworks
- Create 30 decision and adversarial scenarios
- Run 83 real agents through 2,490 test cases
- Collect audit logs and decision explanations
- Iterate on adapters until all pass
- Publish engine and adapters to PyPI
- Deploy with shadow mode for tuning
- Enforce policy in production
- Monitor and audit decisions
证据
83 real agents across 10 frameworks. A covering design that cut a 12-day test matrix into one afternoon.
2,490 tests green. 83/83 agents passed.
The engine is deterministic. The LLM proposes, policy disposes.
- 记录日期: 2026-09-15T21:30:23.831Z