-
Notifications
You must be signed in to change notification settings - Fork 38
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
Should not put exact matches first #63
Comments
This may be your own opinion but not the usual use case. If people type a module name, they expect to get a link to it as the first result. Read #48 for more information. |
@sindresorhus given that autosuggest and the package's page don't yet exist, finding a specific module, that's really bad, would be near impossible. As I see it, npms isn't just about discovering. I use npms as a easy way to find the documentation I'm using and so when I write a name I want that exact package. Nonetheless, I agree that in that case and others, it may lead to some misguidance. Maybe we could distinguish the bad package to indicate that it just shows up because of the exact name match. |
Looks like those are just cases of the metric analysis being off, not for artificially placing exact matches at the top. I agree
So your argument is not being able to find a really bad module. 😲
You go to npms.io, write package name, press enter, click package name, instead of just: |
I use Maybe |
I agree with @sindresorhus, chances are I'm looking for a popular/quality module, rather than the exact match. Perhaps you could check the "difference" between popularity (stars/forks/deps) between two matching modules and order by that? I think it'd solve cases like this one. |
@sindresorhus you have said that, exact word matching as the first result is wrong but in the case of the mithril package it's fine. How then would you suggest changing the npms ecosystem to handle both cases AND the use-case that @atduarte and @jamestalmage have? |
My use case would be pretty easily resolved with the redirect url I just mentioned, I think @atduarte's would too.
Having a poor first result is annoying, but it is not as annoying as not being able to find your module when you type in the name exactly. Without elevating exact matches
Let's be honest.
I think that sounds like a reasonable solution. I make it smaller somehow: Remove all but the first line of the listing? Slightly smaller font? Maybe just a simple one line sentence in a small italicized font near the top of the listing:
@satazor, @atduarte - Are you logging what people actually click and comparing it to your top rated result? |
I'm writing this on my phone because my laptop is being repaired, so I will be short. I will elaborate a more comprehensive reply once it is repaired. Mithril has a bad quality and maintenance score because the actual issues and other stuff we use to measure is on a different repository than the one written in the package.json (which they call development repository). I don't know why they do this, branches could have been used instead. I don't know if we need to handle this case in the analyzer.. I would prefer not to add complexity the code to solve edge cases. |
Why not allow the selection of how you want results handed to you? Kind of weird to not be able to order-by any of the metrics.
I think it's funny we're debating which should be shown when obviously it's a subjective matter and can even change from search to search. Literally everything else on the web has a way to order by something. |
Having given up on searching at If I wanted an exact match I'd just go to |
@Qix- You can't compare it to Ebay. They serve a completely different market and needs. Google doesn't have sorting choices. The |
I'm noticing some mix opinions about this. I think we can make it work for both. The API search endpoint would just return the list of packages ordered as they should, according to score and relevance. A list of packages that match exactly the name, separately. On the web UI, these packages could show up on the right or, like @jamestalmage suggested, on the top of the list but with a different, much smaller size. This solution would allow to keep the results list as it should, with the best packages first. While allowing people looking for a specific "unknown" package to find it, without having to know the package's page address. I'm just not so sure about how it could work on apps such as npm-search or on integrations such as this: https://github.com/boneskull/alfred-npms. |
I'm with @sindresorhus on this one. In case of other packages like |
For the record this happened today: https://twitter.com/fishrock123/status/748159392793694209 |
At |
After thinking a lot about this, it's better to keep it this way since most people agree this is the right way to do it. They actually complain about npmjs exactly because of this. Still, we should improve the UI and highlight the exact-match differently in case it's not the best module. We need to come up with a good way to do this. |
I don't care if a module matches what I wrote. I want the best one.
For example, https://npms.io/search?term=electron 99% of people would want the second result
electron-prebuilt
, not an obscure and unmaintained CLI framework with much lower score.The text was updated successfully, but these errors were encountered: