refactor(sdk-go): order scoring.go declarations alphabetically - #514
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (1)
WalkthroughThe ChangesRelevance method reorder
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
d5a78c1 to
3582d38
Compare
There was a problem hiding this comment.
Pull request overview
This PR refactors sdk/go/scoring.go by reordering top-level declarations to match the Go SDK’s apparent file organization convention: exported entry points first, followed by unexported helpers in alphabetical order. No functional logic is changed; the KnowledgeUnit.relevance method and its doc comment are moved to the end of the file.
Changes:
- Moved
KnowledgeUnit.relevance(...)belowjaccardSimilarity(...)to achieve alphabetical ordering of unexported declarations. - Kept all method contents and documentation unchanged (pure positional move).
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Move the relevance method to the end of the file so top-level declarations follow the package convention used in store.go and options.go: the exported entry point first, then unexported declarations in alphabetical order. Pure positional move of the method and its doc comment; no logic change.
3582d38 to
09b6587
Compare
Summary
Reorders the top-level declarations in
sdk/go/scoring.goso they follow the package's existing convention (as instore.goandoptions.go): the exported entry point first, then unexported declarations in alphabetical order.The
relevancemethod was previously hoisted directly afterRankCandidates(top-down grouping). It now sits at the end of the file, giving the order:RankCandidates→anyMatch→applyConfirmation→applyFlag→jaccardSimilarity→relevanceThis is a pure positional move of the method and its doc comment — no logic changes.
Verification
make lint— 0 issuesmake test— full SDK suite passesgo build ./...— cleanSummary by CodeRabbit