AI Cross-Selling Manual.

How to set up market-basket analysis with AI scoring, review suggestions and write only sensible assignments to native Shopware cross-selling.

System requirements

Shopware 6 with a populated order history if you want to use the „Co-purchases" source. AI scoring needs an API key with the relevant provider. Scheduled analysis requires a running Shopware scheduler or worker.

Note: The plugin writes into native Shopware cross-selling. It adds no blocks of its own to the storefront and replaces no Shopware feature.

Installation

Install and activate the plugin, then clear the Shopware cache. The Cross-Selling area is then available in the admin.

Opening the plugin

You will find it in the admin under Settings, in the Cross-Selling area. From there you reach the three working areas: managing profiles, running an analysis and reviewing suggestions.

What the plugin does

The plugin suggests matching products for cross-selling. It evaluates order history and catalog, scores the pairs with AI if you want, and you decide which ones are accepted. Accepted suggestions end up in a native Shopware cross-selling block on the product page.

The process always has three steps:

  1. Analyse - generates suggestions and does not change the sets in the shop yet.
  2. Accept - adds the product to the cross-selling block.
  3. Live in the shop - the block is visible to customers.
Important: An analysis on its own changes nothing in the shop. Only accepting writes assignments. Accepting is additive: the product is added to the existing block of the same name, never twice, and nothing is ever removed automatically.

The seven sources

Suggestions come from these sources. Each can be enabled per profile and combined freely.

Co-purchases
Products frequently bought together, from order history. Needs purchases. Controlled by „Min. co-purchases" and „Min. confidence". Example: camera and memory card, because both were often in the same basket.
Same categories
Products in the same categories. Controlled by „Min. shared categories" (default 2). Example: two items that both sit in „Hiking" and „Backpacks".
Same properties
Matching property values, e.g. brand or series. Controlled by „Min. shared properties" (default 2).
Same manufacturer
Products from the same brand.
Category bestsellers (fallback)
Best-selling products of the category. Ensures coverage even without purchase history, but weighted lower than real matches. Needs maintained sales figures (product.sales).
Semantic similarity (AI embeddings)
Products that are related in substance, found via embeddings built from name, description and manufacturer. Works without purchases, shared categories or maintained properties - ideal when data is thin. Requirement: embeddings have to be generated once (see Generating embeddings). Anthropic does not offer embeddings; use OpenAI, Mistral or Gemini. Example: a trekking pole and a hiking boot, because the texts describe the same use case.
Viewed together
Products that visitors looked at within the same visit. Needs no orders and works for new products too. Controlled by „Minimum shared views" and „Maximum suggestions per product". Recording has to be switched on in the settings. Example: tent and sleeping bag, because both were viewed in the same visit.

What a profile is

A profile is a complete preset and maps to its own cross-selling group in the shop. Each profile has its own sources, thresholds, scope, AI usage and auto-accept. The profile name is also the title of the block in the shop.

For example: one profile „Frequently bought together" based on co-purchases, and one profile „Matching accessories" based on shared properties. Each creates its own block on the product page.

Creating a profile

Under Settings, Cross-Selling, „Add profile" or „Edit". In the modal you set the name, the sources including their minimum values, the scope, AI and thresholds, and auto-accept.

Do not forget: Profile changes only take effect once you press „Save" at the bottom of the settings tab.

Sources in the profile

Two fields control how strictly the catalog-based sources match.

Min. shared categories Default 2
For „Same categories" only: this many categories must overlap.
Min. shared properties Default 2
For „Same properties" only: this many property values must match.

Thresholds and AI

Min. co-purchases Default 3
How often two products must have been bought together for the pair to count - an absolute number, not a percentage. Example: 3 = the pair appeared together in at least 3 orders. Higher = only robust pairs; lower = rare combinations too.
Min. confidence Default 0.1
Share of A-orders that also contained B (0 to 1). Example: 0.1 = B was present in at least 10% of orders with A. Higher = only strong „buyers of A also buy B" links.
AI scoring Default off
Scores each pair with AI, detects complement vs. similar item, gives a short rationale and a score (0 to 100). Needs an API key for the chosen provider.
Exclude substitutes Default on
Keeps only genuine complements and filters out substitutes (replacements). Example: camera and memory card stays, camera and another camera is dropped. Only works with AI scoring enabled.
Min. shared categories Default 2
For the „Same categories" source only: this many categories must overlap.
Min. shared properties Default 2
For the „Same properties" source only: this many property values must match.
Minimum shared views Default 3
For „Viewed together" only: how often two products must have been viewed together within the same visit.
Maximum suggestions per product Default 5
For „Viewed together" only: how many of the most frequently co-viewed products per item are used.
The minimum wins: the minimum count per product raises the configured maximum when needed. Setting three as the lower bound and two as the upper one yields three - the lower bound takes precedence.

Scope and output

Time window Default 365 days
How far the order history for „Co-purchases" reaches back. Example: 365 = last year only; shorter emphasises current trends, longer uses more data.
Max. suggestions per product Default 8
Upper cap on good matches per source product. Example: 8 = at most 8 items in the block. On the storefront slider 4 to 8 usually works best.
Minimum per product Default 0
If the sources return fewer, the list is topped up with category bestsellers until the number is reached. Raises the maximum if needed. 0 = no top-up.
Active products only Default on
Ignores inactive or hidden products as source and as suggestions.
Products without cross-selling only Default off
Only suggests for products that have no block yet - good for filling gaps without touching existing ones.
Update existing Default off
Allows adding to already maintained assignments instead of skipping them.
Shop / sales channel Default all
Optionally ties the profile to one shop: only products visible there count and suggestions are assigned to that channel. „All channels" = the choice from the analysis dialog.
Exclude manufacturers Default none
Selected manufacturers are never suggested as cross-selling.
Visibility per sales channel: if you tie a profile to a sales channel, only products visible in that channel are considered, and the suggestions are assigned to it as well. If the setting stays on "All channels", the channel from the analysis dialog applies.

Auto-accept

Auto-accept is set per profile. One profile can roll out automatically while another stays manual.

Auto-accept Default off
Accepts suggestions automatically without manual review - set per profile. One profile can roll out automatically while another stays manual.
Above score Default 80
Only suggestions with at least this AI score (0 to 100) are auto-accepted. Recommendation: since cross-selling is customer-facing, set it high (80+).
AI complements only Default on
Auto-accept only for pairs the AI classified as genuine complements.
Activate block automatically Default on
Activates the generated cross-selling block directly in the shop.
Mutual assignment Default on
Assigns A to B and B to A, instead of one direction only.
Write to variants Default off
Also writes assignments to product variants, not just the main product.

Setting up AI scoring

Supported providers are OpenAI (ChatGPT), Anthropic (Claude), Mistral and Gemini. Enter an API key, pick a model and verify it with „Test connection".

The AI scores every pair, classifies it as a complement or a similar item and returns a short rationale plus a score from 0 to 100. With „Exclude substitutes" only genuine complements make it into the suggestions.

Example: A camera and a memory card is a complement and stays. A camera and another camera is a substitute and is filtered out.

Running an analysis

Manually via the „Start analysis" button, where you choose the profile or all active profiles and the sales channel. Or from the console:

bin/console staw:cross-selling:analyze bin/console staw:cross-selling:analyze --profile="Matching accessories" bin/console staw:cross-selling:analyze --channel=<salesChannelId>

Pairs that have already been decided, meaning accepted or rejected, are not suggested again. After the analysis the view jumps to the new open suggestions automatically.

Reviewing and accepting suggestions

In the review pool you filter by status, min. score, sales channel and group. Accept individual suggestions with „Accept" or dismiss them with „Rejected". „Accept all" respects the active filters, so it can act on a single group only.

The badges on each suggestion show source, group and score, plus an „auto" badge for automatically accepted ones. „Remove" takes an assignment back out of the shop.

Automation and cron

Under Settings, „Automation", you enable scheduled analysis and pick the interval. This requires a running Shopware scheduler or worker. The automation status shows the last and next run, the task status and how many assignments were accepted automatically.

*/5 * * * * cd /path/to/shopware && php bin/console scheduled-task:run --no-wait >/dev/null 2>&1 0 3 * * * cd /path/to/shopware && php bin/console staw:cross-selling:analyze >/dev/null 2>&1
Note: An analysis alone does not update the sets, not even via cron. Only accepting does. With auto-accept enabled, cron maintains the sets by itself.

Setting up viewed together

This source evaluates which products visitors looked at within the same visit. It needs neither orders nor well-maintained categories and therefore produces suggestions for new products as well.

Under Settings, Viewed together, switch on Recording active. Without it no data accumulates. The status below shows recorded pairs, counted views, products with data and the last entry.

Products considered per visit Default 6
How many recently viewed products are paired with the current one. Higher values yield more data but looser relationships.
Count variants towards the main product Default on
Views of individual variants roll up to the main product instead of being scattered.
Retention Default 365 days
Older pairs are removed during the scheduled run, as are pairs of deleted products.

Recording is kept separate per sales channel, detects bots and writes a single query per page view. Counters from a previously used table are carried over on update, so the source does not start from zero.

Data protection: Only product pairs with a counter are stored. No personal data and no visitor profiles are created.

Then enable the source in the profile and run an analysis. Expect a few days of lead time until enough views have accumulated.

Generating embeddings

The "semantic similarity" source needs an embedding vector per product. It is generated once and refreshed when products change. Without this step the source returns no suggestions.

In the admin: Settings, then Cross-Selling, section Embeddings, button "Update embeddings". The status shows how many products are covered and how many are still pending.

On the console:

bin/console staw:cross-selling:embeddings
bin/console staw:cross-selling:embeddings --limit=1000
bin/console staw:cross-selling:embeddings --force

Repeat runs skip unchanged products, so they cost almost nothing. You need an API key with the chosen provider: OpenAI, Mistral or Gemini. Anthropic does not offer embeddings - you can still use Anthropic for scoring the pairs themselves.

Order of steps: generate embeddings first, then enable the "semantic similarity" source in the profile, then run an analysis.

Cleanup

„Cleanup" removes open suggestions that no longer belong to any current profile, for example after renaming or deleting a profile. Accepted and rejected suggestions are left untouched.

Tips from practice

  • Cross-selling is customer-facing. For auto-accept, set a high threshold, for example from score 80, and ideally allow AI complements only.
  • The bestseller fallback needs product.sales to be populated. Shopware counts sold quantities automatically, but a brand-new shop has no bestsellers yet.
  • Give the fallback its own profile. It then sits in its own group and can be controlled separately.

Troubleshooting

The analysis finds nothing

The message names the reason per source. Common causes are a value set too high for „Min. shared categories", no shared manufacturer, or the „products without cross-selling only" option removing all candidates.

No suggestions despite many orders

Check „Min. co-purchases" and „Min. confidence". Both filter before the AI scores anything. The time window may also be too short.

Viewed together returns nothing

First check whether recording is active under Settings, Viewed together. Without it no data accumulates. If recording was switched on only recently, the counted views may not yet reach the minimum set in the profile.

Scheduled analysis does not run

Without a running scheduler or worker the task never starts. The automation status shows the last and next run.

Support

If you have questions about setup, connecting an AI provider or cross-selling strategy, we are happy to help. Get in touch via the contact page or write to info@stoneandwater.online.

All settings

Every setting of the plugin with its default value and explanation, in the same order as in the administration. The texts come straight from the plugin (version 1.3.19).

Interface (AI provider)

Provider, model and key for the AI scoring plus the connection test.

ProviderDefault: ChatGPT (OpenAI)

AI provider used to score the cross-selling suggestions.

API keyDefault: empty

Your API key for the selected provider. Stored in the Shopware configuration.

ModelDefault: depends on the provider

Model of the selected provider.

Viewed together

Records in the shop which products are viewed together within one visit. Only product pairs with a counter are stored, no personal data.

Tracking activeDefault: off

Increments the pairs on every product page view. Without tracking, no new data is collected.

Products considered per visitDefault: 6

How many recently viewed products are paired with the current one. Higher values deliver more data, but looser relationships.

Count variants towards the main productDefault: on

Otherwise the counters spread across sizes and colours and never reach a meaningful level.

Keep data (days)Default: 365

Older pairs with few views are removed automatically. Frequent pairs are kept.

Cart & checkout

Shows accepted cross-selling assignments as a recommendation strip during checkout. Candidates are collected over all cart products, weighted by score and shown without items already in the cart.

Show on the cart pageDefault: off

Recommendation strip below the cart table.

Show in the offcanvas cartDefault: off

Compact strip in the side cart, one product per view.

Show on the order confirm pageDefault: off

Caution: distraction right before purchase can lower conversion. Suitable for B2B shops with supplementary demand.

Number of slides: cart pageDefault: 6

1 to 12 products for this position.

Number of slides: offcanvas cartDefault: 3

1 to 12 products for this position.

Number of slides: confirm pageDefault: 6

1 to 12 products for this position.

Strip headlineDefault: empty

Empty = default text per language ("Goes well with your order").

Automation

Which sources and thresholds are analysed is chosen directly when you click "Start analysis". The automatic analysis uses the same selection.

Write cross-selling to variants as wellDefault: off

Replicates the main article sliders as real records on all variants - for ERP and third-party systems reading the cross-selling tables directly. Kept in sync automatically on every accept/remove.

Analyse automaticallyDefault: off

Run analysis automatically in the background on a schedule (Shopware scheduler).

IntervalDefault: Weekly

How often the automatic analysis runs. Choose daily, weekly or monthly.

Creating and editing profiles

Profiles: each profile is its own cross-selling block with sources, thresholds and scope.

Name (title in the shop)Default: empty

Name of the profile. It appears in the shop as the title of the cross-selling block, such as matching accessories.

Shop / sales channelDefault: all

Calculate this profile only for this shop - only products visible there are considered. "All channels" uses the selection from the analysis dialog.

ActiveDefault: on

Included in "All active profiles" and in automatic runs.

Co-purchasesDefault: on

Frequently bought together. Needs order history.

Min. co-purchasesDefault: 3

In how many orders two products must appear together at least to count as a pair.

Same categoriesDefault: off

Works without orders too.

Min. shared categoriesDefault: 2

How many categories two products must share at least.

Same propertiesDefault: off

e.g. brand, series.

Min. shared propertiesDefault: 2

How many properties two products must share at least.

Same manufacturerDefault: off

Products of the same brand.

Category bestsellers (fallback)Default: off

Suggests each product the best-selling products of its category. Guarantees coverage without purchase history. Weighted lower than real matches.

Viewed togetherDefault: off

Uses visitor behaviour: products that were viewed together within one visit. Works without orders and also covers new products. Tracking must be enabled in the settings.

Minimum number of shared viewsDefault: 3

How often two products must at least have been viewed in the same visit.

Maximum suggestions per productDefault: 5

How many of the most frequently co-viewed products are suggested per product.

Only products without cross-sellingDefault: off

Fill gaps specifically.

Update existing suggestionsDefault: off

Open suggestions are re-scored on every analysis, and new candidates (e.g. from newly enabled sources) can displace weaker open suggestions. Accepted assignments are never touched. Off: existing ones stay unchanged and only count towards the maximum - no more are added.

Replace weaker assignmentsDefault: off

With a limited number of suggestions, new candidates also compete against already accepted assignments: on accepting, the lowest-scored assignment yields to a better candidate and returns to the review pool. Rejected pairs stay blocked.

Only better suggestionsDefault: off

Products with already accepted assignments only receive suggestions whose score is above the weakest accepted assignment. Prevents weaker fill candidates from piling up right after accepting. Works well together with "Replace weaker assignments".

Lock replaced productsDefault: on

Assignments displaced during replacing are marked as rejected and never suggested again. Off: they return to the review pool as open suggestions.

Write assignments to variants as wellDefault: off

When accepting in this profile, the cross-selling blocks are automatically replicated to all variants (for ERP integrations). Applies in addition to the global setting.

Only active productsDefault: on

Ignore inactive products that are not visible in the shop.

Exclude manufacturersDefault: none

Products from these manufacturers are not suggested as cross-selling in this profile.

Use AI scoringDefault: off

Scores pairs, detects complement/similar, rationales. Slower.

Exclude substitutesDefault: on

Only effective with AI scoring.

Accept automaticallyDefault: off

After every analysis (manual and via cron), suggestions of this profile at or above the score are accepted into the group automatically - visible in the shop right away.

From score (0-100)Default: 80

From which score between 0 and 100 a suggestion is accepted automatically by auto-acceptance.

Only AI complements automaticallyDefault: on

Only pairs the AI recognised as genuine complements. Plain category/manufacturer matches without AI stay for manual review. Recommended.

New cross-sellings active immediatelyDefault: on

Accepted assignments of this profile are visible in the shop immediately.

Assign both waysDefault: on

On acceptance the cross-selling is created on both products: source points to target and target back to source.

Min. confidence (0-1)Default: 0.1

Minimum share of the orders containing the first product that also contain the second. 0.1 means 10 percent. Applies to the shared purchases source.

Max. suggestions per productDefault: 8

Maximum number of suggestions a product gets in this profile.

Minimum per product (0 = off)Default: 0

If the chosen sources return fewer than the minimum, the list is topped up with category bestsellers until the number is reached. Raises the maximum if needed.

Block position on the product (0 = automatic)Default: 0

Controls where this profile's cross-selling group appears on the product (1 = top). Takes effect on the next accept, also for existing blocks. 0 appends new blocks at the end.

Time window in days (0 = all)Default: 365

How far back the order history analysed for shared purchases reaches. 0 analyses all orders.

Through the store or directly from us.

Two routes, the same feature set - pick whichever suits your setup.

Directly from Stone & Water

Available right now

Monthly14,99 €
Best valueYearly134,99 €25 % cheaper

All prices net, plus VAT.

You buy the licence directly from us and get an invoice from us. Install by upload in the admin without SSH, updates through our licensing platform, support straight from the developer.

Ask us directly +49 2555 9997342

Shopware Store

In preparation

The plugin will be listed in the official Shopware Community Store. Installation and automatic updates then run through the plugin manager, billing through your Shopware account. We will link it here as soon as it is live.

Better cross-selling?

Back to Cross-Selling.

Find all details on the product page. We are happy to help with AI setup and strategy.