# Creating a Recommender

### 🧠 Creating a New Recommender

To create a recommender, follow these steps:

1. Navigate to Experience > **Recommenders**.
2. Click "**Add Product Recommender**" to open the recommender builder.
3. Give your recommender a title in the **Recommender Name** field.
4. Define how many products the recommender will display in the **Max Recommended Products** field.

{% hint style="info" %}
You can increase or decrease this using the input field or arrows, or by typing a number in the field.
{% endhint %}

### ⚙️ Recommender Configuration

To define which products should be included in the recommender, click on **Add** **rule**. This will open the rule setup panel.

<details>

<summary>Rule Title</summary>

Give your rule a descriptive name to clarify its purpose. This is especially useful when using multiple rules.

</details>

<details>

<summary>Slot Allocation per Rule (Max Slots)</summary>

Here you can define how many of the allotted slots this rule should account for. There are two use cases on how to set this up:

**Full Slot Allocation:** Keep the slot number the same as in the Setup page. All the available slots will be filled by this rule, unless there are not enough products to fulfill this (for example if the recommender should show 10 products, but only 6 match the criteria). In this use case, we recommend setting up a secondary fallback rule with less conditions to make sure the recommender displays the correct number of products.

**Partial Slot Allocation:** Set a custom slot limit for the rule (e.g., 5 out of 10 total). Use this to split recommendations across different rule types (for example to recommend different types of products).

</details>

<details>

<summary>Define the Recommendation Criteria (Product Recommendation Filter)</summary>

You can define criteria for products to be included in the recommender. You can filter products based on attributes by using **Conditions** (for example, "Product Category \[equal to] Apparel").

To apply multiple filters at the same time, add a **Condition Group** instead.

</details>

<details>

<summary>Dynamic Conditions</summary>

**Same as product on page**

For more dynamic recommendations, you can select the “**Same as product on page**” option when adding a value to the selected property.

As an example, if you’d like to recommend products of a similar colour as the one displayed on the Product Detail Page the recommender is shown on, this is the condition that should be applied: Product Colour \[equal to] Same as product on page.

**Match with visitor property**

If you have set up visitor properties, you can personalise recommendations based on a visitor's saved preferences or answers.

To do this, type `{{visitor.property_key}}` in the match value field, replacing `property_key` with the key of your visitor property.

***Example***

* If you have a visitor property key `preferred_style` that stores the visitor's style preference in session, you can filter products to match it:

> Product Style \[equal to] `{{visitor.preferred_style}}`

* This will show products where the style matches what the visitor previously selected.

{% hint style="info" %}
**Tips:**

* The property key must match exactly as it appears in your visitor properties setup (found under Settings → Visitor Properties)
* This works well with Product Finder answers that are linked to visitor properties
* You can use this with any filter operator (equal to, contains, etc.), in addition to multi-conditional rules
  {% endhint %}

</details>

<details>

<summary>Ranking Points - Manual Points</summary>

You can add ranking points to prioritise specific products. Click **Add Ranking Rule** to create a ranking-based prioritisation and define the weight of points, as well as the condition(s) required for a product to receive the points.

For example:

* Set the condition (e.g., Product Category \[equal to] Sneakers)
* Assign points (e.g., 5 points)
* Products meeting this rule will be prioritised in display order.

</details>

<details>

<summary>Ranking Points - Mapped Points</summary>

You can also use **Mapped** ranking points. To do so, you will need to create a product property with the points you’d like to assign, and then assign points to products by adding a corresponding value for each product. This can be added to your own product feed, or you can use Crobox’s built-in solutions (ideal for a smaller amount of products).

You can find guides on how to create a Property, and how to use Product Data Enrichment below:CommentShare feedback on the editor

* [manage-and-transform-product-properties](https://docs.crobox.com/how-to-guides/product-data/manage-and-transform-product-properties "mention")
* [manual-data-enrichment](https://docs.crobox.com/how-to-guides/product-data/manual-data-enrichment "mention")

</details>

<details>

<summary>Sorting Rules</summary>

To determine how products are ordered within the recommender, click on Add sorting rule. You can then select an attribute to sort on, for example "Product Ranking Points" or “Product Property Price”, and choose between High to Low or Low to High for the order.

</details>

<details>

<summary>Rule Preview</summary>

Click "**Preview**" to see which products will be recommended based on the specific rule set.

</details>

### 🔧 Managing Multiple Rules & Preview

You can add multiple rules to a single recommender, either to act as fallback rules in case the first rule cannot fill all the slots, or to show different recommendation sets (see [Slot Allocation per Rule](#slot-allocation-per-rule-max-slots) section).

You can create a new rule from scratch, or click on the three-dot menu next to an existing rule to Duplicate and adjust.

{% hint style="info" %}
Use the "Move Slot Up/Down" buttons to rearrange rule order, which you can find by clicking on the three dot menu next to a rule.
{% endhint %}

To see which products are recommended based on **all** the rules you set up, click on the **Preview** button at the bottom of the page. Keep in mind that you first need to save any changes made to the rules for the preview to be accurate.
