feat(engine): add pickTopRankedOpportunitiesAtOrAboveScore helper#3360
Conversation
Compose generic ranker min-score filtering with a top-N cap for discovery callers that need threshold plus limit in one helper. Co-authored-by: Cursor <cursoragent@cursor.com>
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Warning 🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨🟨 ⏸️ Gittensory review result - manual review recommendedReview updated: 2026-07-05 04:58:02 UTC
⏸️ Suggested Action - Manual Review Review summary Nits — 5 non-blocking
Review context
Contributor next steps
Signal definitions
🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3360 +/- ##
=======================================
Coverage 93.88% 93.88%
=======================================
Files 281 282 +1
Lines 30566 30570 +4
Branches 11134 11136 +2
=======================================
+ Hits 28698 28702 +4
Misses 1211 1211
Partials 657 657
🚀 New features to boost your workflow:
|
Summary
pickTopRankedOpportunitiesAtOrAboveScore(candidates, minScore, limit)to@jsonbored/gittensory-engine: filters viarankOpportunitiesAtOrAboveScore, then returns the top N survivors.ranked-opportunity-top-min-score.ts— generic-ranker mirror of merged feat(engine): add pickTopMetadataOpportunitiesAtOrAboveScore helper #3340 metadata helper.Why no linked issue
Completes the generic discovery ranker toolkit (rank → threshold → top-N) without callers chaining helpers manually.
Conflict avoidance
Touches only
packages/gittensory-engine/src/ranked-opportunity-top-min-score.ts(new),packages/gittensory-engine/src/index.ts(one export line), andtest/unit/ranked-opportunity-top-min-score.test.ts(new). No overlap with open PRs (#3357 signals, #3356 enrichment, #3314 miner CLI, #3304 review holds, #3305 enrichment-wire).Codecov patch
Local
diff-coverreports 100% patch coverage onranked-opportunity-top-min-score.ts.Test plan
npm run build --workspace @jsonbored/gittensory-enginenpm run build:minernpx vitest run test/unit/ranked-opportunity-top-min-score.test.ts(6 tests)diff-cover coverage/lcov.info --compare-branch=main --fail-under=99→ 100%Made with Cursor