pub struct SelfHealingConfig {
pub enabled: bool,
pub max_attempts: usize,
pub min_confidence: f64,
pub cache_healed: bool,
pub max_context_bytes: usize,
pub include_screenshot: bool,
}Expand description
Configuration for self-healing behavior.
Fields§
§enabled: boolEnable self-healing.
max_attempts: usizeMaximum healing attempts per selector.
min_confidence: f64Minimum confidence required to try a suggested selector.
cache_healed: boolWhether to cache healed selectors for future use.
max_context_bytes: usizeMaximum HTML context bytes to include in diagnosis.
include_screenshot: boolWhether to include screenshot in diagnosis requests.
Implementations§
Source§impl SelfHealingConfig
impl SelfHealingConfig
Sourcepub fn enabled() -> SelfHealingConfig
pub fn enabled() -> SelfHealingConfig
Create a new config with healing enabled.
Sourcepub fn with_max_attempts(self, max: usize) -> SelfHealingConfig
pub fn with_max_attempts(self, max: usize) -> SelfHealingConfig
Set max attempts.
Sourcepub fn with_min_confidence(self, conf: f64) -> SelfHealingConfig
pub fn with_min_confidence(self, conf: f64) -> SelfHealingConfig
Set minimum confidence.
Sourcepub fn with_cache(self, cache: bool) -> SelfHealingConfig
pub fn with_cache(self, cache: bool) -> SelfHealingConfig
Set whether to cache healed selectors.
Sourcepub fn with_max_context(self, bytes: usize) -> SelfHealingConfig
pub fn with_max_context(self, bytes: usize) -> SelfHealingConfig
Set max context bytes.
Trait Implementations§
Source§impl Clone for SelfHealingConfig
impl Clone for SelfHealingConfig
Source§fn clone(&self) -> SelfHealingConfig
fn clone(&self) -> SelfHealingConfig
Returns a duplicate of the value. Read more
1.0.0 · 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 SelfHealingConfig
impl Debug for SelfHealingConfig
Source§impl Default for SelfHealingConfig
impl Default for SelfHealingConfig
Source§fn default() -> SelfHealingConfig
fn default() -> SelfHealingConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for SelfHealingConfig
impl<'de> Deserialize<'de> for SelfHealingConfig
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<SelfHealingConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<SelfHealingConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for SelfHealingConfig
impl PartialEq for SelfHealingConfig
Source§impl Serialize for SelfHealingConfig
impl Serialize for SelfHealingConfig
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for SelfHealingConfig
Auto Trait Implementations§
impl Freeze for SelfHealingConfig
impl RefUnwindSafe for SelfHealingConfig
impl Send for SelfHealingConfig
impl Sync for SelfHealingConfig
impl Unpin for SelfHealingConfig
impl UnsafeUnpin for SelfHealingConfig
impl UnwindSafe for SelfHealingConfig
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