pub struct AdversarialPolicyConfig {
pub enabled: bool,
pub policy_provider: String,
pub policy_file: Option<String>,
pub fail_open: bool,
pub timeout_ms: u64,
pub exempt_tools: Vec<String>,
}Expand description
Configuration for the LLM-based adversarial policy agent.
Fields§
§enabled: boolEnable the adversarial policy agent. Default: false.
policy_provider: StringProvider name from [[llm.providers]] for the policy validation LLM.
Should reference a fast, cheap model (e.g. gpt-4o-mini).
Empty string = fall back to the default provider.
policy_file: Option<String>Path to a plain-text policy file. Each non-empty, non-comment line is one policy.
fail_open: boolWhether to allow tool calls when the policy LLM fails (timeout/error).
Default: false (fail-closed / deny on error).
Setting this to true trades security for availability. Use only in
deployments where the declarative PolicyEnforcer already covers hard rules.
timeout_ms: u64Timeout in milliseconds for a single policy LLM call. Default: 3000.
exempt_tools: Vec<String>Tool names that are always allowed through the adversarial policy gate, regardless of policy content. Covers internal agent operations that are not externally visible side effects.
Trait Implementations§
Source§impl Clone for AdversarialPolicyConfig
impl Clone for AdversarialPolicyConfig
Source§fn clone(&self) -> AdversarialPolicyConfig
fn clone(&self) -> AdversarialPolicyConfig
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more