You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Allows saving/loading the index to/from disk, but for small datasets you can feed the index on-the-fly.
however I can't see any documentation about this. I'd like to store the index in a database (MongoDB) and query that.
FYI I'm looking at and evaluating the various full-text search libraries available for Node.js and the Browser and have only just found thinker-fts and from reading the documentation is looks quite good.
It would be nice to see a better online demo though. Fuse.js is excellent in this regard, but you don't need to go quite that far.
The text was updated successfully, but these errors were encountered:
By feeding the index on-the-fly, i mean running thinker.feed(...) with the full dataset like in the first example of the readme.
As the "feeding" is quite fast, saving a pre-calculated index to/from disk is only necessary for large datasets (~ >1000 full text documents) where it starts taking seconds, or for huge datasets minutes.
thinker.feed([[1,'Lorem','Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.'],[2,'Ipsum','Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.']]);
I think, you can run it one entry at a time too.
result.forEach((row)=>{thinker.feed([row])});
I will look into making a good online demo when i find some spare hours :)
You mention:
however I can't see any documentation about this. I'd like to store the index in a database (MongoDB) and query that.
FYI I'm looking at and evaluating the various full-text search libraries available for Node.js and the Browser and have only just found thinker-fts and from reading the documentation is looks quite good.
It would be nice to see a better online demo though. Fuse.js is excellent in this regard, but you don't need to go quite that far.
The text was updated successfully, but these errors were encountered: