Mix and Boost

Mix and boost is a powerful feature in SPARQUE Desk that enables you to fine-tune the behavior of your boost rules in a user-friendly way. It allows you to adjust the weights of different boosting parameters and immediately see how these changes impact your search or recommendation results.

Key Features

  • Interactive weight adjustment:
    Modify the weights of individual boost rules using intuitive sliders or input fields, without the need to write code or manually update configuration files.
  • Real-time preview:
    Instantly preview the effect of your adjustments on the result set. This feature helps you understand how different weights influence the ranking or relevance of the results.
  • Optimized rule tuning:
    Perfect for testing and optimizing complex boost scenarios: Whether you are working with product attributes, user signals, or contextual factors, mix and boost can help you find the right balance.

When to Use

Use mix and boost when:

  • You want to experiment with boost rule configurations
  • You need to visualize the impact of weight changes before applying them
  • You are fine-tuning relevance for specific use cases or campaigns

Benefits

Mix and boost enhances your workflow by:

  • Speeding up the tuning process by removing the need for manual deployments
  • Encouraging experimentation and data-driven decision-making
  • Delivering more relevant, customized results to users

Setup

SPARQUE Desk Requirements

In SPARQUE Desk, the strategy must be prepared to ensure the mix and boost feature integrates seamlessly with SPARQUE Hub. In this guide, we will test the boost rules for a search results endpoint. We will adjust the search strategy so that users within SPARQUE Hub can adjust the weights for orderhistory-total, orderhistory-user & cart-crosssell.

Build the strategy in SPARQUE Desk as shown below:
Strategy prepared for mix and boost

  1. Include a dataset named hub.
  2. Filter on the class boost-rule to retrieve all boost rules configured within SPARQUE Hub.
  3. Filter the results where the property paramName matches boost-search.
    boost-search is the incoming parameter passed through by SPARQUE Hub.
  4. Rank the configured weights using Rank by Double.
  5. Apply a Transform prob with INVERSE selected as transformation to obtain natural scores.
  6. Include an Extract Strings block using inputName to get the names as strings with a score (which will represent the configured score).
  7. Configure an if-then-else block: If a parameter is sent via SPARQUE Hub to SPARQUE Desk, use the testing weights coming from SPARQUE Hub. Otherwise, use the saved weights present in the dataset hub.
  8. Configure a Mix Named Inputs block using the following settings:
    Mix and boost: Mix named inputs
    • Incoming line 1 represents the weights for orderhistory-total.
    • Incoming line 2 represents the weights for orderhistory-user.
    • Incoming line 3 represents the weights for cart-crosssell.
      The Mix Named Inputs block takes the weights configured in the dataset or sent via SPARQUE Hub.
  9. Create a snapshot of the strategy.
  10. Connect the strategy to the search endpoint.

SPARQUE Hub Requirements

Now that SPARQUE Desk is set up, the next step is to preconfigure the weights within SPARQUE Hub.


Mix and boost homepage
  1. Create a mix and boost rule:
    1. In Sparque Hub, switch to Search | Mix and boost.
    2. Click + Edit Mix & Boost Rules and + Add Boost Rule.
    3. Select an API from the drop-down list.
      This is the API where the search strategy with the snapshot is connected. Ensure the parameter name matches exactly with the parameter configured in SPARQUE Desk (e.g., boost-search). Additionally, the input name should align with the incoming lines configured in SPARQUE Desk (orderhistory-total, orderhistory-user and cart-crosssell). Mix and boost rules
    4. Click Save.
    5. Click Back.
  2. Select the appropriate configuration (e.g., default).
  3. Click Save & Continue.
  4. Choose the correct API (e.g., shop) and the corresponding endpoint (e.g., search).
    Mix and boost: Select your API to boost

    Optionally, you can select multiple endpoints if your mix and boost endpoint is part of a stacked endpoint.
  5. Click Save & Continue.
  6. Test the endpoint by adjusting the boost values:
    1. View the comparison between Boosted Results (based on weights configured in the mix and boost editor in SPARQUE Hub) and Original Results (based on saved weights in the dataset).
    2. Inspect SPARQUE Desk attributes such as name, identifier, and probability. Click Expand to view additional attributes. Mix and boost: Adjust boost values
  7. If satisfied with the new weights, click Save Boost Adjustments.
    This updates the dataset hub. Once the API is updated, the new scores will be applied.