pub struct Autopilot { /* private fields */ }Expand description
An autopilot that acts on verdicts.
Dry-run by default, and deliberately so. The difference between a bot
that flags and a bot that removes people is one forgotten default, so the
default is the harmless one: it reports what it WOULD do until someone
writes .arm() and means it.
Implementations§
Source§impl Autopilot
impl Autopilot
Sourcepub fn min_proven(self, floor: u32) -> Self
pub fn min_proven(self, floor: u32) -> Self
How provable a conviction must be before this bot acts on it. Cannot go below 50: inference must never remove anyone unattended.
Sourcepub fn max_per_run(self, n: usize) -> Self
pub fn max_per_run(self, n: usize) -> Self
Ceiling per pass, so a bug cannot empty a community.
Sourcepub async fn run_once(&self) -> Result<AutopilotRun>
pub async fn run_once(&self) -> Result<AutopilotRun>
Evaluate once and act (or rehearse).
Auto Trait Implementations§
impl Forget for Autopilot
impl Freeze for Autopilot
impl Move for Autopilot
impl RefUnwindSafe for Autopilot
impl Send for Autopilot
impl Sync for Autopilot
impl Unpin for Autopilot
impl UnsafeUnpin for Autopilot
impl UnwindSafe for Autopilot
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more