eCommerce search
You go to an eCommerce engine to find and buy products from a catalog of available products. These products comprise many metadata fields – size, color, brand, and so on – along with longer fields like title, product description, and reviews. The engine’s primary job is to retrieve the most relevant results, which brings revenue. Site designers employ many tools to build a good relevance function – from embedded, numerical values, to ML models based on user behavior.
To improve the end-user experience, eCommerce sites frequently add faceted search. The engine provides a bucketed count for the values in various fields (size, color, and so on) – and the UI gives the user a clickable list that they use to narrow the results.
Some types of e-commerce search depend heavily on personalization and recommendations. If a shopper searches for “dresses”, the search engine should find dresses that the customer might be interested in, even though the query itself is very open-ended. Similarity metrics like k-nearest neighbor (k-NN) help with that.
Curated data set search
Search of a curated data set like an enterprise document repository (clinical trial data, legal briefs, real estate, and so on). Search engines contain linguistic rules and other language-specific features that help them to break down large blocks of text into component terms (words from a field or large block of text) for matching. Its rich query language enables searching these large blocks of text for combinations of terms, like “long sleeveless dress”. But the engine doesn’t retrieve everything that matches: it uses relevance scoring to rank and sort documents and return only the best matches.
Query offload
Search engines contain specialized data structures to facilitate high-volume, low-latency search. The most important of these structures is the inverted index, which maps individual terms to a list of documents that contain those terms. Because of these data structures, search engines outperform relational databases for query processing. The trade-off is that search engines are not relational. It’s common to see a tandem relational database and search engine. You use the relational database to serve application data, and a search engine to provide low-latency, relevant search across that data.