4 ms·
>the client would download the index That doesn't sound like too bad of an idea, given the state of js these days. Yes, you can cut off irrelevant terms, thos
by marcuslager 9y ago
>the client would download the index
That doesn't sound like too bad of an idea, given the state of js these days.
Yes, you can cut off irrelevant terms, those with low tf-idf score (the, a, is, are...) or you could filter out stopwords. Or both. Me personally, I would never remove low-scoring terms. Consider the state of the word "is". It's mostly irrelevant, unless you are searching for information about a certain terrorist group.
One small index type (as in number of bytes) is a trie. Another is a huffman tree. They store each term less than once.
- jimktrains2 9y agoThe disadvantage(?) of a trie is that you can't rank by relevance.
- marcuslager 9y agoThere is no such disadvantage. Scoring usually comes after the index (tree) lookup. Once you have terms you can weight them. The trie is just a lookup mechanism.