-
-
Notifications
You must be signed in to change notification settings - Fork 47
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
Option to filter out duplicates in suggestions #276
Comments
As an example — attempt a title-search for "mexico" in the search box/textfield in the top-right of... Presents 2 UX challenges...
|
@maneeshpm My thoughs about this problem have evolved since I have written the ticket. Here is I believe a better approach to solve it:
That way we are almost sure to avoid suggestion duplicates and we trust Xapian ranking algorithm. |
I'm not against that, but two points to notice :
It is probably possible to ask xapian to regroup the result by url, or even just ensure that url is unique. |
I'm talking about suggestions in general and the system based on Xapian. The special case of Kiwix-serve is not much of interest for me at this stage. It's way of working is "wrong" and needs to be fixed, see kiwix/kiwix-tools#205.
Yes, I don't believe this is something necessary (but I'm not happy about that either).
Yes, this will be inefficient in that case - so we might have two similar titles pointing ultimatively the same non-redirect article.
If Xapian can do that then I vote for this approach obviously. @maneeshpm this is on you ;) |
I agree with your approach @mgautierfr. The results are returned as a |
@mgautierfr @kelson42 It seems that using a keymaker is supported only on sorting right now, but not on collapsing mset. Doing it directly using Xapian is not possible. So we need a custom solution to this. |
@maneeshpm So if we store the path as value then it will work? If "yes", then we should do so and secure back compatibility. |
If we store the path as a value, it will be as easy as setting the collapse key to the valueslot of path. We should probably do that for future zims. I am figuring out a way to ensure backward compatibility as well. |
@maneeshpm I would associate a key metadata "value_store" to the database and act according to its presence/value. Secure that you access this metadata in lazy mode so you don't have to access the xapian file each time you need to check the value. |
We should be able to avoid duplicates in suggestions search. Currently and most of the time, it returns many time the same article (partly via multiple redirects). This is not only useless but limit in addition the number of alternatives proposed.
I would propose to:
The text was updated successfully, but these errors were encountered: