Skip to main content

validate_assertion_promotion

Function validate_assertion_promotion 

Source
pub fn validate_assertion_promotion(
    current: &ContextualAssertion,
    target_type: StatementType,
    target_verification: VerificationStatus,
    human_adjudicator_did: Option<&str>,
    corroborating: &[ContextualAssertion],
) -> Result<ContextualAssertion, String>
Expand description

Validate a proposed transition in StatementType or VerificationStatus:

  1. An Inference or Allegation can NEVER be promoted to an Observation (an observation is direct primary witness/device data, never synthesized by repetition).
  2. Repetition or multiple dependent inferences sharing a root_source_id NEVER auto-promote an Allegation or Inference into an AdjudicatedFinding or Verified status.
  3. Promoting to StatementType::AdjudicatedFinding or VerificationStatus::Adjudicated requires an explicit human_adjudicator_did and at least one independent corroborating record (or formal human adjudication record).