Join Bridgewater State University for a Website Search Webinar on Dec. 10 | REGISTER NOW

September 05, 2023

Tyler Huff

|

6 min. read

Relevance Models in SearchStax Studio are designed to improve the overall search experience by fine-tuning how Studio responds to search queries. Before diving into the configurations, set your goals. What defines a “relevant” result for your users? Whether you want to give higher priority to more recent content, content from a specific author, or those containing specific keywords, these goals will guide your customization.

Preliminary Steps: Assessing Available Fields

Before you begin, review the available fields in your schema. Knowing the type of each field, whether it’s textual, numerical, or date, is essential as this understanding will guide the kind of rules and boosts you set up later.

Fields are usually categorized into two types:

  • text_general: This type is often used for full-text search and supports various text transformations like stemming and tokenization.
  • string: This type is for exact matching and is strongly discouraged for most use-cases as it might not provide the flexibility needed for a good search experience.

Understanding the type of each field is crucial for setting up effective rules and boosts.

Navigating to Relevance Modeling Screen

To access the Relevance Modeling features, you’ll either create a new model or modify an existing one. If you’re creating a new model, ensure you use a descriptive, unique name for easy identification later on.

Model Details Screen

Upon accessing the Relevance Model, you’ll find various tabs:

  • Search Fields Tab
  • Global Filters Tab
  • Ranking Tab
  • Rules Tab
  • Promotions Tab

Precedence of Features

It’s crucial to know that these features are applied in a specific order: Global Filters come first, followed by Ranking, Rules, and finally Promotions.

Search Fields Tab

Overview

The Search Fields Tab is essential for shaping your Relevance Model in Studio. It allows you to specify which fields Studio will scan when a search query is made.

Key Fields

  • Title: Crucial for immediate user recognition.
  • Summary/Description: Provides a snapshot of content.
  • Author and Tags: Helpful for context and narrowing search.

Usage

To add a field, click its name in the list of available fields. To remove, click the ‘X’ next to the field name.

Impact

  • Broadening Scope: More fields yield more hits, widening the result set.
  • Focused Relevance: Fewer fields offer more targeted results.

Global Filters Tab

Overview

The Global Filters Tab in Studio lets you set universal constraints that influence all search queries.

Key Concepts

  • Include Filters: Define criteria that search results must meet.
  • Exclude Filters: Specify what will be omitted from search results.

Usage

Select a Search Field, input a Value, and then click the (+) button to add a filter. To delete a filter, click the corresponding ‘X’.

Impact

  • Data Partitioning: Use filters to partition your data into searchable segments. This makes searches more efficient by limiting the scope of what Studio needs to scan.
  • Focused Segmentation: Partition data based on various attributes like time, category, or user roles for more targeted search results.

Ranking Tab

Overview

The Ranking Tab in Studio empowers you to fine-tune the relevance scores of search results. You have the flexibility to apply boosts based on specific search fields, field values, or even custom functions for more nuanced adjustments.

Key Concepts

  • Search Field Boost: Elevate the relevance of items where a match occurs in a specific field.
  • Field Value Boost: Boost the relevance of items containing specific field values.
  • Function Boost: Utilize custom functions to create more complex boosting logic.

Usage

  1. Boost by Search Field: 
  • Select “Search Field” from the options and choose the specific field you want to boost.
  • Use the slider to adjust the boost multiplier.

    2.
    Boost by Field Value: 
  • Select “Field Value” and input both the field name and value you wish to boost.
  • Use the slider or input fields to specify the boost.3.

    Boost by Function: 

  • Select “Function” and input a custom function that returns a numerical value.
  • This function will dictate the boost applied to each item. 

Adjust the sliders or directly enter values in input fields to set the boost multipliers. The higher the multiplier, the more prominently the result will appear in search listings.

Impact

  • Precision Control: Adjusting the ranking allows you to closely align search results with your business priorities, ensuring that the most relevant items appear at the top.
  • Enhanced User Experience: By boosting certain fields or values, you can guide users to the most valuable and relevant content, thereby improving their experience.

Rules Tab

Overview

The Rules Tab in Studio’s Model Details screen is a powerful feature that enables you to fine-tune the search experience for your users. By creating rules, you can modify the search results based on specific triggers or conditions.

Different Types of Actions

There are four primary actions that a rule can take when a specific trigger is met. You can use these actions individually or in any combination:

  1. Replace Search Term: Modify the search query by replacing the trigger phrase or word with another term.
  2. Filter on a Field Value: Apply dynamic filtering to the search results based on a field value.
  3. Boost Using a Field Value: Increase the relevance score of specific search results based on the value of a particular field.
  4. Boost Using a Function: Apply a mathematical function to boost certain results based on a dynamic condition.

Creating Rules

To create a new rule, navigate to the Rules Tab and select the ‘Add Rule’ option. This will open up a form where you can specify the conditions and actions for the rule.

Example Rule: Python Query

Context

In this example, we’ll consider a simple use case where a user enters the query “Python”.

Actions and Configurations

  • Trigger: The rule will be triggered when the search query contains the word “Python.”

Actions to Take

  1. Replace Search Term
    • Value: Python
    • Action: Replace “Python” with “Programming” to widen the search scope.
  2. Filter on a Field Value
    • Value: Scripting Language
    • Search Field: summary
    • Action: Only show results that have “Scripting Language” in their summary, eliminating irrelevant results.
  3. Boost Using a Field Value
    • Value: Python
    • Search Field: tags
    • Ranking Boost: 50
    • Action: Increase the relevance score of documents that have the term “Python” in their tags.
  4. Boost Using a Function
    • Function: ms(date)
    • Action: Prioritize newer documents in the search results.

Impact

  • Precision: Users searching for “Python” will more likely get programming-related content, reducing irrelevant search results.
  • Relevance: The rule also helps to surface the most current and relevant information by giving a higher weight to newer documents.

Promotions Tab

Introduction

Promotions are one of the most powerful features you have at your disposal. It allows you to curate a list of search results and promote specific items to the top of the list, ensuring that the most critical or relevant information gains maximum visibility. This feature gives you control over the search experience, allowing you to guide your users to what matters most.

Types of Promotions

You can set up different types of promotions to customize the search experience:

  1. Simple Promotions: These are internal promotions. You specify a query that will trigger this promotion and then select items from your own indexed content to promote.
  2. External Promotions: These allow you to highlight external content, such as event sites or partner pages.

Creating Promotions

To set up a promotion, go to the Promotions Tab and click on ‘Create’. This will prompt you to configure the promotion’s trigger and specify which items should be promoted.

Trigger Types

The trigger for a promotion can be set up in one of two ways:

  • Exact Match: The promotion will only be triggered if the query exactly matches the trigger phrase.
  • Contains: The promotion will be triggered if the query contains the trigger phrase or word.

The choice between these two options depends on how broad or narrow you want the trigger to be. An exact match will be more restrictive but more targeted, while a “contains” condition will capture a broader set of queries.

Impact

With the Promotions Tab, you’re in the driver’s seat:

  • Visibility: Promoted items appear at the top, ensuring that they are seen by most users.
  • User Guidance: You can guide users to critical or high-value information without them even knowing it’s a promoted item unless you choose to disclose this.

Transparency

You can choose whether or not to disclose to users that an item has been promoted. For instance, each promoted result can optionally contain a special field value like [elevated]:true.

Final Steps: Saving and Publishing

Once you have configured your Relevance Model, make sure to save your settings. If you’re ready to apply the changes, go ahead and publish the model.

How to Use: Use the ‘Save Draft’ and ‘Publish’ buttons at the bottom of the screen to finalize your settings.

This guide should cover all the necessary aspects of creating a well-tuned Relevance Model in SearchStax Studio. With these settings, you can significantly enhance the user search experience, ensuring that the most pertinent and useful results are presented to the end-user.

By Tyler Huff

Solutions Engineer in Pre/Post Sales

"With these settings, you can significantly enhance the user search experience, ensuring that the most pertinent and useful results are presented to the end-user..."

You might also like: