AuthorityWeightedTrustScorer

open class AuthorityWeightedTrustScorer constructor(weights: Map<AuthorityTier, Double> = DEFAULT_WEIGHTS, unknownScore: Double = DEFAULT_UNKNOWN_SCORE) : TrustScorer

A TrustScorer that scores a proposition purely by the authority of its source: more authoritative tiers get a higher trust score. This is the natural step up from NeutralTrustScorer for consumers who want "trust the source" behaviour without writing their own model.

The tier-to-score mapping is fully configurable — pass your own weights to retune it, or rely on the DEFAULT_WEIGHTS below. A tier that is missing from the map (or a null tier, e.g. when authority could not be resolved) scores unknownScore. Conflict type is ignored by default; subclasses can override score to factor it in. Every score is clamped to [0.0, 1.0] so a mis-tuned map can never produce an out-of-range value.

Constructors

Link copied to clipboard
constructor(weights: Map<AuthorityTier, Double> = DEFAULT_WEIGHTS, unknownScore: Double = DEFAULT_UNKNOWN_SCORE)

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
open override fun score(proposition: Proposition, authorityTier: AuthorityTier?, conflictType: ConflictType?): Double

Score the trustworthiness of a proposition.

open fun score(proposition: Proposition): Double

Score a proposition when you have no authority or conflict context to pass.

open fun score(proposition: Proposition, authorityTier: AuthorityTier?): Double

Score a proposition given its authority tier but no conflict context.