Repository navigation
fix(search): hashes and commit trailers are not identifiers - #111
Merged
Merged
Conversation
Found by the external benchmark on sqlalchemy: the tool scored 0/40 at hit@5
while the same tool with neighbours shown scored 18. Not a ranking problem -
`_identifiers` took the Gerrit `Change-Id` (a 40-char hash) as the first
identifier, the gate counted `Iaf8be... = 0` occurrences in the source, and every
commit carrying one abstained.
Before: identifiers: Iaf8be4a9..., _ConnectionRecord.__close, run_scenario, Fixed
verdict: abstain (0.00)
After: identifiers: _ConnectionRecord.__close, run_scenario, AnyIO, ...
verdict: answer (0.75), gold at row 2
The fix drops hashes (32+ hex, with or without the Gerrit `I` prefix) and commit
trailers (fixed, fixes, issue, issues, closes, resolves, changelog) from
`_identifiers`. `close` is deliberately kept: it is a real method name.
Measured:
sqlalchemy, 40 commits hit@5 before -> after
tool 0 -> 11
neighbours 18 -> 19
search 18 -> 18
grep 20 -> 20
B1 dev (71 solvable) 19 / 38 / 22 / 2 -> identical
The tool is still below grep on that external repo after the fix, so the
small/medium-repo conclusion stands; what changed is that the abstain is no
longer systematic.
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
fix(search): hashes and commit trailers are not identifiers
Found by the external benchmark on sqlalchemy: the tool scored 0/40 at hit@5
while the same tool with neighbours shown scored 18. Not a ranking problem -
_identifierstook the GerritChange-Id(a 40-char hash) as the firstidentifier, the gate counted
Iaf8be... = 0occurrences in the source, and everycommit carrying one abstained.
Before: identifiers: Iaf8be4a9..., _ConnectionRecord.__close, run_scenario, Fixed
verdict: abstain (0.00)
After: identifiers: _ConnectionRecord.__close, run_scenario, AnyIO, ...
verdict: answer (0.75), gold at row 2
The fix drops hashes (32+ hex, with or without the Gerrit
Iprefix) and committrailers (fixed, fixes, issue, issues, closes, resolves, changelog) from
_identifiers.closeis deliberately kept: it is a real method name.Measured:
The tool is still below grep on that external repo after the fix, so the
small/medium-repo conclusion stands; what changed is that the abstain is no
longer systematic.