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

[FEATURE] Simple auto-complete suggestions on kiwix dot org search bar #911

Open
Bigguysahaj opened this issue Mar 13, 2023 · 7 comments
Open

Comments

@Bigguysahaj
Copy link
Contributor

Bigguysahaj commented Mar 13, 2023

Currently, the search bar doesn't show auto-complete suggestions for the books displayed on the page.

image

I believe it would be a simple addition as it would help discoverability of different books offered amongst the 4000+ options.

My Approach

Initially, I was planning to implement a common trie-based javascript autocomplete solution as I have done in previous personal js projects. I will scrape all the book titles that come after <div id="book__title"> and before </div> ,then I'll add all the book results to a JSON file. Then I will get the autocomplete function to work on this.
Lemme know if my approach has any flaws or if could be better.

Problems

I am new to open source and working with large codebases is scary. So I hope I could get assistance with a few problems.

  • I read through the documentation and frankly I wasn't able to get the project working properly locally (could go in more depth about it if it's relevant).
  • What I'm currently doing is running index.html as it does show a functional enough search bar. Would adding autocorrect functionality this way is a correct approach?
    image
@Bigguysahaj Bigguysahaj changed the title [FEATURE] Simple auto-complete suggestions on kiwix dot org search bar. [FEATURE] Simple auto-complete suggestions on kiwix dot org search bar Mar 13, 2023
@Bigguysahaj
Copy link
Contributor Author

Should I work on this?

@kelson42
Copy link
Collaborator

For the moment, not convinced of the value of the feature. Maybe an explanation about the problem would help?

@kelson42 kelson42 self-assigned this Mar 14, 2023
@Bigguysahaj
Copy link
Contributor Author

Bigguysahaj commented Mar 14, 2023

I understand that the value this feature brings is not a lot.

How it helps is: I could type type "reve" to quickly see if a book on reverse engineering exists, instead of searching for it.

It's a simple feature I wanted to try contributing towards as my introduction to open source, before trying more complex contributions.

About the problem, I will try setting up the project again in a few hours and will let know if I'm still facing problems.

@mgautierfr
Copy link
Member

I read through the documentation and frankly I wasn't able to get the project working properly locally (could go in more depth about it if it's relevant).

Have you tried https://github.com/kiwix/kiwix-build ?

@veloman-yunkan
Copy link
Collaborator

For the moment, not convinced of the value of the feature.

@kelson42 I think that the feature will be valuable (e.g. will help to avoid missed search results due to typos). However it shouldn't be implemented as proposed in the ticket description. Instead the /suggest endpoint should be enhanced or a new endpoint (e.g. /catalog/v2/suggest) should be added.

@kelson42
Copy link
Collaborator

kelson42 commented Mar 14, 2023

@veloman-yunkan I understand now and agree. Would be probably great to rephrase this ticket in a new one.

@kelson42 kelson42 added this to the 12.1.0 milestone Mar 14, 2023
@Bigguysahaj
Copy link
Contributor Author

However it shouldn't be implemented as proposed in the ticket description. Instead the /suggest endpoint should be enhanced or a new endpoint (e.g. /catalog/v2/suggest) should be added.

@veloman-yunkan would you explain to me a little bit more about the /suggest idea? I would love to work on this.
If the skillset requires cpp or js, I'm familiar with them, I just have to get familiar with the codebase 🔥.

@kelson42 kelson42 modified the milestones: 12.1.0, 12.2.0 Apr 1, 2023
@kelson42 kelson42 modified the milestones: 12.3.0, 12.2.0, 13.0.0, 13.1.0 Jul 22, 2023
@kelson42 kelson42 modified the milestones: 13.2.0, 13.3.0 Jun 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants