Skip to content

Configure Recommendation Models

⏱ 20 minutes intermediate
πŸ“œCorecommerce

A recommendation engine is only as good as its configuration. The default settings will produce results, but they will not reflect your business priorities. A fashion retailer wants recommendations that respect seasonality. A B2B knowledge base wants recommendations scoped to the visitor’s product line. A media site wants recommendations that balance recency with relevance.

Model configuration is where you translate business intent into algorithmic behavior. This guide shows you how to set up models, choose algorithms, and apply the rules that make recommendations work for your specific scenario.

  1. Create a recommendation model
  2. Select the right algorithm for your use case
  3. Configure business rules and content filters
  4. Test and validate the model output

A model defines a recommendation strategy β€” what to recommend, using which algorithm, subject to which rules.

  1. Navigate to Optimizely > Recommendations > Models
  2. Click Create Model
  3. Give the model a descriptive name that reflects its purpose (e.g., β€œProduct Page - Similar Items” or β€œBlog Footer - Related Articles”)
  4. Select the item catalog the model draws from:
    • Product catalog for product recommendations
    • Content catalog for article/page recommendations
  5. Save the model to proceed to algorithm selection

Naming convention tip: Use the format [Placement] - [Strategy]. This makes models easy to identify when you have several running across your site.

Each model uses one algorithm. Choose based on what you want to optimize.

AlgorithmHow it worksBest forData requirement
Collaborative filteringRecommends items that similar visitors engaged withEstablished sites with high traffic10,000+ interactions
Content-basedRecommends items with similar attributes (tags, categories, text)New sites, long-tail content, cold-start scenariosGood content metadata
HybridCombines collaborative and content-based signalsMost production use casesSome interaction data + good metadata
TrendingRanks items by recent popularityHomepages, category pages, new visitor fallback1 week of traffic data
Co-purchaseRecommends items frequently bought togetherCart pages, post-purchase emailsPurchase event data

To set the algorithm:

  1. Open your model
  2. Navigate to Algorithm Settings
  3. Select the algorithm type
  4. Adjust the algorithm-specific parameters:
    • Collaborative filtering: Set the similarity threshold (higher = more relevant but fewer results) and the lookback window (how far back to consider visitor behavior)
    • Content-based: Select which content attributes to match on (categories, tags, description text)
    • Hybrid: Set the weight balance between collaborative and content-based signals (e.g., 70/30)
    • Trending: Set the trending window (24 hours, 7 days, 30 days)

Business rules override or adjust algorithmic output to reflect business priorities.

Control which items can appear in recommendations:

RulePurposeExample
Exclude categoriesPrevent items from certain categoriesExclude β€œclearance” from premium product pages
Include onlyRestrict to specific categories or tagsOnly recommend from the same product line
Exclude viewedSkip items the visitor already sawPrevent showing the current article
Exclude purchasedSkip items the visitor already boughtAvoid recommending a product they just ordered
Date filterOnly recommend items published or updated within a windowFor news sites, only show articles from the last 30 days

To add rules:

  1. Open your model
  2. Navigate to Business Rules
  3. Click Add Rule
  4. Select the rule type and configure its parameters
  5. Set the rule priority (rules are evaluated in order; the first matching rule wins)

Sometimes you want the algorithm to consider items but give certain ones a nudge:

  • Boost β€” Increase the relevance score of items matching a criterion (e.g., boost new arrivals by 20%)
  • Pin β€” Force a specific item into a specific position (e.g., always show the latest product launch as the first recommendation)
  • Diversify β€” Ensure recommendations span multiple categories rather than clustering in one

Configure what happens when the model cannot generate enough recommendations (new visitor, insufficient data, or too many exclusions):

  1. Trending fallback β€” Fill remaining slots with trending items
  2. Editorial fallback β€” Show a curated list you maintain manually
  3. Empty β€” Show nothing (useful when irrelevant recommendations are worse than none)

Set the fallback in the model’s Fallback Settings section.

Before deploying a model to your live site, verify it produces sensible results.

Preview mode:

  1. Open your model
  2. Click Preview
  3. Select a test item (a product page or article) as context
  4. Review the recommended items the model returns
  5. Try different test items across categories to check diversity

Validation checklist:

CheckWhat to look forAction if it fails
RelevanceDo recommended items relate to the context item?Adjust algorithm weights or attribute matching
DiversityAre recommendations spread across categories?Add a diversity rule
FreshnessAre stale or outdated items appearing?Add a date filter rule
ExclusionsAre excluded items properly filtered?Verify exclusion rule configuration
FallbackWhat shows for a brand-new visitor?Configure trending or editorial fallback
CoverageAre niche items ever recommended, or only popular ones?Lower the popularity bias in algorithm settings

After validation:

  • Publish the model to make it available for embedding
  • Monitor performance metrics (CTR, revenue per recommendation) for the first two weeks
  • Iterate on rules based on real-world data β€” no model is perfect on the first configuration
IssueCauseFix
Model returns no resultsInsufficient behavioral dataWait for more traffic, or switch to content-based algorithm
Same items always recommendedPopularity bias in collaborative filteringAdd diversity rules or boost underrepresented categories
Irrelevant items appearingMetadata quality issuesImprove content tagging and categorization
Results not updatingModel retraining not runningCheck the retraining schedule in model settings