Skip to main content

Module relational

Module relational 

Source
Expand description

Generic relational scoring terminal over the common operator tree.

One terminal scores any operator tree and retains a signed score per terminal row; the operator decides WHICH rows exist, the terminal decides WHAT each row scores and publishes signed deltas through IncrementalConstraint. Arity lives entirely in the operator tree, so one terminal serves every depth.

Re-exports§

pub use grouped_weights::DirectComplementAdapter;
pub use grouped_weights::GroupAdapter;
pub use grouped_weights::GroupedJoinAdapter;
pub use grouped_weights::OptionalComplementAdapter;

Structs§

DirectComplementAdapter
Adapts a (&K, &R) weight to complemented rows over groups keyed by K.
GroupAdapter
Adapts a (&K, &R) group weight to rows of a GroupNode with key K and collector result R.
GroupedJoinAdapter
Adapts a (&K, &R, &B) weight to rows joining a grouped row (key K, result R) with a B entity.
OperatorScorer
Scores one named terminal over a shared operator: its constraint identity, impact, row weight and the unsigned score it retained for each row. Built by SharedOperatorBuilder::first_named and named.
OperatorTerminal
Scoring terminal over a concrete operator tree, independent of row arity. Weight closures borrow the complete row; retention stores unsigned row weights (the impact is applied when they are summed), never entities or solution references.
OptionalComplementAdapter
Like DirectComplementAdapter, for groups keyed by Option<K>.
ScorerChain
Two scorer sets over one operator, scored left then right: the chain a shared terminal grows by one OperatorScorer per named terminal.
SharedOperatorBuilder
Builder holding a terminal’s impact and weight until it is named.
SharedOperatorTerminal
Scoring terminal that owns one operator tree and scores it for several named constraints.

Traits§

AdaptWeight
Turns an authored weight W into a RowWeight for operator O’s rows.
OperatorScorerSet
The named terminals scoring one shared operator.
RowWeight
Unsigned score of one row of operator O; the terminal applies the impact.