Search engines are absolutely ubiquitous today. They function as springboards for our online journeys, as well as tools to find products and content on online stores and media websites. Regardless of their purpose, however, all search engines that aim to find results quickly have to rely on something called an index.
What exactly is an index, though?
Well, typically, the data that a search engine needs to retrieve results from is stored within one or more databases, but simply scanning the contents of a database is an inefficient and slow way to look for items. Thus, what happens behind the scenes is that a search engine first goes through the database(s), parses the records in it, and stores the data in them in an easy-to-search form within a structure called an index.
Thus, when a search engine needs to process a query and return some search results, what it actually goes through is an index. Searching through an index is much faster than searching through an equivalent amount of raw data: this is why indices are so important for search engines to function.
But what if you have multiple databases or multiple indices behind the scenes for your ecommerce store? How can your site search engine deal with that? The most common way is through something called federated search. Let’s learn more about it, and the various scenarios where it’s commonly used.
What is federated search, and how is it useful?
Federated search is a technique that makes it possible for multiple sources of data to be searched through with a single query and a single user interface. In other words, even if your business requires you to create and maintain multiple databases and/or indices, you can still ensure that your site visitors can search through all your content through a single search bar.
There are several common kinds of contexts where federated search is essential. For instance, enterprise search typically has to work in a federated manner, given that companies will typically have several different databases (customers, business partners, employees, products, payroll, etc.), each of which will contain data in different formats.
Another important domain where federated search is often vital is ecommerce and retail. As a simple example, suppose that several products in an online store have documentation, blog articles, FAQs or demo videos associated with them; moreover, suppose that each such content type is stored in a different database, and that different content types need to be presented in a distinct way in the search results so as to keep things clear for users. In such a scenario, federated search would be the way to go.
Two more scenarios where federated search is useful are:
- Aggregator sites that enable people to carry out bookings for flights/hotels/events.
- Media streaming platforms or content websites that provide one-stop access to media/content from various music companies/artists/publishers.
In both the above cases, the search interface on the site in question will likely need to access various different indices/databases and then present the results produced using a unified interface.
The 4 approaches to federated search
Depending on your search and business goals, you can choose one of the 4 types of federated search:
1. Search time merging (or query time merging)
Search time merging involves sending a user's search query to multiple indexed sources simultaneously. Each source processes the query independently and returns its results to the search system.
The search system then combines and ranks the results from all sources, presenting a unified list of results to the user. This approach is highly efficient in providing up-to-date information but may be slower than other methods due to the time required to process queries across multiple sources.
As an example, Kayak is a metasearch engine for travel that employs search time merging to deliver comprehensive search results. When users search for flights or accommodations, Kayak simultaneously sends the query to multiple travel websites, such as airline and hotel booking platforms. It then aggregates the results in a single list, enabling users to compare prices, amenities, and schedules from different sources efficiently.
2. Index time merging
In index time merging, the search system combines and indexes information from multiple sources before a user submits a query. When users search, they query a single, unified index rather than multiple sources. This approach offers faster search results since the system doesn't need to query each source in real-time. However, it requires more effort to maintain the index and can result in less up-to-date information compared to search time merging.
Google's custom search engine exemplifies index time merging. Website owners can create a custom search engine that indexes content from specific websites. By creating a unified index from multiple sources, Google ensures that users searching through the custom search engine query this single, consolidated index rather than multiple sources. This method offers faster search results and a streamlined user experience.
3. Hybrid federated search
Hybrid federated search combines elements of both search time merging and index time merging. This approach can involve creating a unified index for some sources while querying others in real-time. Hybrid federated search offers a balance between the speed of index time merging and the up-to-date information provided by search time merging. It is particularly useful when dealing with a mix of static and dynamic content sources.
Ecommerce platforms like Amazon can use hybrid federated search to deliver relevant search results to users. For example, product information and customer reviews can be indexed and merged for faster search results, while real-time querying of external sources like pricing and inventory data can ensure the most up-to-date information is displayed. This combination of approaches enables Amazon to deliver accurate and efficient search results to users.
4. Federated search interface
A federated search interface uses a single search interface to query multiple sources without merging the results. Instead, the user receives results from each source separately, allowing them to easily identify the origin of the information. This method is useful when the user needs to see results from different sources separately, but it can be less efficient and may require more effort to compare and analyze results.
An example of this kind of federated search can be seen at the WorldWideScience.org portal. The website employs a federated search interface to provide access to scientific information from databases and portals worldwide.
When users enter a search query, the system queries multiple sources, such as national libraries, research institutions, and government databases. The results are displayed separately for each source, enabling users to identify and compare information from different origins easily. While this approach may not be as efficient as merging results, it provides valuable context and transparency to users.
Let’s look at some use cases of federated search in ecommerce and retail.
3 use cases for federated search in ecommerce and retail
1. Disparate Product Categories
Many online stores specialize in a particular niche and sell a relatively small number of different product types. For instance, a store might only sell t-shirts, shoes, or swimwear. For such stores, storing all of their product data in a single database is not a problem.
However, it’s also quite common for online stores to sell many different kinds of products. In such cases, the sorts of details that are relevant to each kind of product can be different enough to warrant the use of a separate database for each product type (e.g. think of the difference between the relevant properties of bags and shoes, or of headphones and mobile chargers). Given this, it makes sense to use federated search in such a scenario.
Similarly, if an ecommerce business aims to expand and add new product lines, brands or categories, federated search can enable it to do so without having to worry about breaking the store’s site search
2. Minimizing the security risks that come with multiple search engines
If your online store has multiple databases/indices but does not use federated search, then the only realistic option before you is to incorporate different instances of a search engine (or different search engines altogether) on different pages.
This is not just a cumbersome situation to manage, but can actually put your business and your customers at risk. Search engines can be an entry point for hackers to gain unauthorized access to information regarding your products or possibly even your site visitors.
By using federated search, you can make the attack surface of your store smaller, thus leading to greater security and peace of mind.
3. Offering seamless omnichannel experiences
For a business that operates a brick-and-mortar store as well as a corresponding online store, it may make sense to keep the brick-and-mortar product database separate from the online store’s product database. However, when a customer looks for a product in the online store, you ideally want the search results to query both databases at once, since a product can usually be picked up from the physical store and dispatched to the buyer.
Once again, in such a multi-database scenario, federated search is exactly what you need to ensure a smooth experience for your customers and maximize sales for your business.
Federated search: a trusty solution for common ecommerce quandaries
Thus, many kinds of growing pains that ecommerce stores might experience can be relatively easily mitigated by making use of federated search. By providing your customers with a single, easy-to-use search interface, you can keep them insulated from index-related messiness happening under the hood while giving them a great search experience.
If you’re looking for a powerful search engine for your ecommerce store, look no further than Zevi. Zevi uses Natural Language Processing (NLP) to understand users’ search intent and produce highly relevant results. Try our Shopify App, or reach out to us today for a free demo!