Many applications and websites faced with the challenge of finding “related items” like:
- Related articles in a blog
- Related products in a shop
- And so on
How to determine related item?
In the comparison of text object – related items determined based on the percentage of text similarity. For instance if text A similar more than on 80% to text B then both text object are related to each other.
How IndexDen can help?
Recently IndexDen added new feature to the API – quorum operator. With quorum operator you could match those documents that pass a given threshold of given words.
For example: search query like “the world is a wonderful place”/3 will match all documents that have at least 3 of the 6 specified words.
Ok, lets try real example with IndexDen.
To continue this article on “Fuzzy Search – find what I meant, not what I said!” we’re at IndexDen developed a new fuzzy searching query operator.
First I want to summarize IndexDen Fuzzy searching tools:
- Autocomplete service that allows you to see words from you corpus as you start typing them;
- Stemming (english and russian) allows you to find documents with linguistically similar words. For instance when you’re searching for “dogs” you will find documents which contain word “dog” or if you’re searching for word “running” you will find documents which contain “run”, “runner” and other similar words;
This is all good tools which helps a lot, but what if you’re searching for very specific phrase which are not exists in any document. For instance you’re search for “pear pie by grandma recipe”, there is a great chance that no documents will be matched by such specific query.
To solve this problem in the original IndexTank API, you need to perform two or more queries with less search terms each time. This is very expensive, because each query take time and with latency of 200ms – three queries will take about 600ms of overall response time.
That’s why we’re now releasing a third tool for this need: quorum operator which will solve a problem described above. This feature allow match those documents that pass a given threshold of given words. Example:
$index->search(' "pear pie by grandma recipe"/3 ');
Will match all documents that have at least 3 of the 5 specified words.
In conclusion I want to say that this is great addition to the IndexDen API, because it allow using only one query to get a bunch of relevant results.
If you think this is what your search solution needs or just want to try it out, join us!