Rank
Order items by score
Mechanism
Deterministic Sort. Applies a caller-supplied ScoringFunction to every element in the input Set and returns a List ordered by Score. Uses Select to truncate to Top-K when requested.
Invariants
- Conservation: Output set is a subset of Input set.
- Monotonicity: For all i, Score(Output[i]) >= Score(Output[i+1]).
Failure modes
- Score Indeterminacy: Multiple items have identical scores.
- Incomparability: Scoring function returns values that cannot be strictly ordered.
Where this came from
—
Builds on
- Select composes_with
- ScoringFunction accepts
Used by
- Abduction references
- BeamSearch references
- Prioritize composes_with
Identity
- Ref:
Rank#67c6 - Hash: sema:Rank#mh:SHA-256:67c6fb568c5fdcfbd0de64b8a5413e943378d421dee9d5614c827e3c539bde3f
- Library: bootstrap 0.11.0, root a6a3d1ff0f98
- License: Not stated; check the repository