pub enum AdversarialTestType {
PromptInjection {
payload: String,
},
AmbiguousInstruction {
variants: Vec<String>,
},
MissingContext {
missing_key: String,
expected_value: Option<String>,
},
BudgetExhaustion {
max_steps: usize,
task_description: String,
},
}Expand description
The category of adversarial scenario being tested.
Variants§
PromptInjection
Embed a prompt-injection payload in external content that the agent will process (e.g. a web page body, a tool result, a fetched file).
AmbiguousInstruction
Present a task that has multiple valid interpretations; assert the agent requests clarification or picks a safe default rather than hallucinating.
MissingContext
Omit a key piece of context from the task description; assert the agent either asks for it or gracefully handles its absence.
Fields
BudgetExhaustion
Give the agent a task that is designed to exhaust its iteration or token budget; assert loop-detection fires or the agent returns a partial result.
Implementations§
Source§impl AdversarialTestType
impl AdversarialTestType
Sourcepub fn category_name(&self) -> &'static str
pub fn category_name(&self) -> &'static str
Short category name used for grouping / filtering in reports.
Trait Implementations§
Source§impl Clone for AdversarialTestType
impl Clone for AdversarialTestType
Source§fn clone(&self) -> AdversarialTestType
fn clone(&self) -> AdversarialTestType
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AdversarialTestType
impl Debug for AdversarialTestType
Source§impl<'de> Deserialize<'de> for AdversarialTestType
impl<'de> Deserialize<'de> for AdversarialTestType
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for AdversarialTestType
impl RefUnwindSafe for AdversarialTestType
impl Send for AdversarialTestType
impl Sync for AdversarialTestType
impl Unpin for AdversarialTestType
impl UnsafeUnpin for AdversarialTestType
impl UnwindSafe for AdversarialTestType
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more