Use policy scoring weights in release search #74
Reference in New Issue
Block a user
Delete Branch "issue/68-core-scoring-wire"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Replaces the search endpoint placeholder with
arr-corescoring and hydrates score weights from the policy row.\n\nCloses #68.Reviewed
cd9e22e. One finding, on the line below.@@ -476,0 +488,4 @@let score = score(policy,Candidate::PreGrab(&parsed),release.size.unwrap_or_default(),release.size.unwrap_or_default()turns an unknown size into 0 bytes, and the size term then interpolates up from the band floor: with the seeded weights and the 2160p band that is1000 * (0 - 8GiB) / 14GiB = -571, where the old localscore()returned a neutral 0 forNone.The floor rule abstains when the size is unknown (
crates/arr-core/src/policy.rs:226needsSome(size)), so a sizeless release stays eligible but now sorts near the bottom of the eligible bucket.Apply the size term only when the size is known — skip the size component for
Nonerather than scoring it as a zero-byte file.Reviewed
68e404e. No findings — the sizeless case now drops the size term and the new test pins it.