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

FTS SearchService with AppSearch #186

Open
mickael-menu opened this issue May 28, 2021 · 0 comments
Open

FTS SearchService with AppSearch #186

mickael-menu opened this issue May 28, 2021 · 0 comments
Labels
enhancement New feature or request help wanted Extra attention is needed

Comments

@mickael-menu
Copy link
Member

mickael-menu commented May 28, 2021

Jetpack recently gained a new library to perform full-text search: AppSearch.

AppSearch is a high-performance on-device search library for managing locally stored, structured data. It contains APIs for indexing data and retrieving data using full-text search. Applications can use AppSearch to offer custom in-app search capabilities, allowing users to search for content even while offline.

Here's the presentation from Google I/O '21: https://youtu.be/xeQ9faYJktM?t=236

It could be useful to add a new implementation of SearchService using AppSearch to offer blazing-fast and cross-publications search.

Here's some ideas on the design of such feature:

  • A new FtsSession controller object holding an AppSearchSession and providing:
    • A way to index a given Publication. Could be useful for an app to pre-index all the publications in the background.
    • A method creating a new SearchServiceFactory which will interface a Publication and the FTS database.
  • If the publication was not already indexed, it should be indexed on-the-fly during the first search query.
  • Rely on the ContentResourceExtractor to get the text content out of any type of resource from the Publication. See StringSearchService for an example.
@mickael-menu mickael-menu added enhancement New feature or request help wanted Extra attention is needed labels May 28, 2021
@mickael-menu mickael-menu transferred this issue from readium/r2-shared-kotlin Jul 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant