pub struct VerifyCatalog { /* private fields */ }Expand description
Local catalog binding verifier ids, probes, and cited ground truth.
Implementations§
Source§impl VerifyCatalog
impl VerifyCatalog
Sourcepub fn register_verifier(&mut self, id: Symbol, verifier: Verifier)
pub fn register_verifier(&mut self, id: Symbol, verifier: Verifier)
Registers or replaces a verifier by stable id.
Sourcepub fn register_probe(
&mut self,
intent: Symbol,
probe: VerifyProbe,
) -> Result<ContentId>
pub fn register_probe( &mut self, intent: Symbol, probe: VerifyProbe, ) -> Result<ContentId>
Registers a probe for an intent name and returns its content id.
Sourcepub fn insert_probe(
&mut self,
intent: Symbol,
id: ContentId,
probe: VerifyProbe,
)
pub fn insert_probe( &mut self, intent: Symbol, id: ContentId, probe: VerifyProbe, )
Inserts a probe with an explicit content id.
Sourcepub fn probe_ids_for(&self, intent: &Symbol) -> Vec<ContentId>
pub fn probe_ids_for(&self, intent: &Symbol) -> Vec<ContentId>
Returns probe ids attached to intent.
Sourcepub fn insert_evidence(&mut self, cite: impl Into<String>, value: Expr)
pub fn insert_evidence(&mut self, cite: impl Into<String>, value: Expr)
Stores cited evidence by Given id, URI, or content-id string.
Sourcepub fn insert_content_evidence(&mut self, id: &ContentId, value: Expr)
pub fn insert_content_evidence(&mut self, id: &ContentId, value: Expr)
Stores cited evidence under its canonical content-id string.
Sourcepub fn verify_answer(
&self,
cx: &mut Cx,
intent: &CompiledIntent,
answer: &Expr,
) -> Result<VerifyReport>
pub fn verify_answer( &self, cx: &mut Cx, intent: &CompiledIntent, answer: &Expr, ) -> Result<VerifyReport>
Runs the intent’s required verifiers against a decoded answer.
Sourcepub fn verify_probe(
&self,
cx: &mut Cx,
intent: &CompiledIntent,
probe: &VerifyProbe,
) -> Result<VerifyReport>
pub fn verify_probe( &self, cx: &mut Cx, intent: &CompiledIntent, probe: &VerifyProbe, ) -> Result<VerifyReport>
Runs a concrete probe using only the verifiers named by the probe.
Sourcepub fn verify_intent_probes(
&self,
cx: &mut Cx,
intent: &CompiledIntent,
) -> Result<VerifyReport>
pub fn verify_intent_probes( &self, cx: &mut Cx, intent: &CompiledIntent, ) -> Result<VerifyReport>
Runs every probe named by the intent and fails closed when proof is missing or incomplete.
Trait Implementations§
Source§impl Clone for VerifyCatalog
impl Clone for VerifyCatalog
Source§fn clone(&self) -> VerifyCatalog
fn clone(&self) -> VerifyCatalog
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 VerifyCatalog
impl Debug for VerifyCatalog
Source§impl Default for VerifyCatalog
impl Default for VerifyCatalog
Source§fn default() -> VerifyCatalog
fn default() -> VerifyCatalog
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for VerifyCatalog
impl RefUnwindSafe for VerifyCatalog
impl Send for VerifyCatalog
impl Sync for VerifyCatalog
impl Unpin for VerifyCatalog
impl UnsafeUnpin for VerifyCatalog
impl UnwindSafe for VerifyCatalog
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