Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

boost graphql types in results #659

Merged
merged 1 commit into from
Oct 19, 2023
Merged

boost graphql types in results #659

merged 1 commit into from
Oct 19, 2023

Conversation

keegancsmith
Copy link
Member

Because "type" in scip-ctags matches so much we can't boost it as high as we do for classes/structs in our language specific boosting. In the case of GraphQL this is useful to boost.

Note: This work was guided by experimentation locally. Still need to set up a more robust way to track the effects of ranking changes.

Test Plan: A search like "type User" in the sourcegraph codebase now includes results from the schema.graphql files.

Because "type" in scip-ctags matches so much we can't boost it as high
as we do for classes/structs in our language specific boosting. In the
case of GraphQL this is useful to boost.

Test Plan: A search like "type User" in the sourcegraph codebase now
includes results from the schema.graphql files.
@keegancsmith keegancsmith requested a review from a team October 18, 2023 19:12
Copy link
Member

@jtibshirani jtibshirani left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense to me as an isolated change.

As you said, it'd be nice to have more of a framework for making these changes. I've also been pondering if there's a better way to unify things across languages, it's a bit tricky to have custom score factors per language.

@keegancsmith
Copy link
Member Author

As you said, it'd be nice to have more of a framework for making these changes.

Yeah I think this is key. I may hack on simple snapshot testing here.

I've also been pondering if there's a better way to unify things across languages, it's a bit tricky to have custom score factors per language.

I think the problem here is that even though things have the same "concept" in different languages, the importance is language specific. My thinking here is we should put some work in to ensure equal footing so for example we don't constantly have go as the top result just because that is what we care about. Additionally I think a little bit of work providing a variety of results will go a long way here as well (so it isn't just strictly sorted on score).

@keegancsmith keegancsmith merged commit 081cd03 into main Oct 19, 2023
8 checks passed
@keegancsmith keegancsmith deleted the k/boost-graphql branch October 19, 2023 06:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants