Attribution

What it is

Attribution is the rule that classifies every order in your store: did an engine recommendation help cause this purchase or not. Every order gets exactly one level — from strong evidence ("clicked a recommendation and bought that product") down to no evidence ("purchase with no engine touch").

How it is computed

When an order arrives, the engine searches the customer's recent history (30 days by default) for a recommendation touch: a recommendation-link click in an email, a recommendation marker from the store plugin (cookie), or a product view. The strength of what it finds decides the level:

LevelMeaning
Direct purchaseclicked a recommendation and bought that product within the hour
Later exact purchasearrived via a recommendation and bought that product later
Indirect same-sessionclicked a recommendation, bought a different product within the hour
Indirect laterclicked a recommendation, bought a different product later
View-assisted purchasea recommendation touch was found, but no click evidence
Influenced purchaseopened a recommendation campaign and bought in the window — not counted as engine revenue
Control purchaseno engine touch found

All levels except the last two make up engine revenue.

How to interpret it

  • The levels are a scale of evidence strength, not a "percentage" split. If an order is in engine revenue, its full amount counts there — not a fraction of it. (The level's weight is used internally for learning: stronger evidence teaches the engine more.)
  • "Influenced purchase" is deliberately zero-weighted: opening an email is not a reliable signal, because Apple's Mail Privacy Protection opens emails automatically. These are shown as a separate line but never counted as revenue.
  • A control purchase does NOT mean "the engine failed" — it is the baseline against which the engine's impact can be measured at all.

Common misreadings

  • "Why are so many orders in control?" — Smaily does not track links in recommendation fields the way it tracks normal campaign links, so some genuine recommendation clicks only register through the store plugin. Until the plugin is installed (or freshly after installing), classification leans conservatively toward control. This is intentional: we would rather understate the engine than overstate it.
  • "Lots of opens but little attributed revenue" — see the previous point and the "influenced purchase" note: opens do not prove impact.

Technical background

Classifier: lib/engine/attribution/classify.ts; levels and weights (1.0 / 0.7 / 0.5 / 0.3 / 0.2 / 0.0): lib/engine/attribution/types.ts (OUTCOME_SCORES). "Same session" = 1 hour. A cookie match counts as a click-equivalent (the recommendation parameter can only be picked up by clicking the link). The lookback window is configurable per tenant (tenant_settings.attribution_match_window_days, default 30 days).

Last updated: 2026-07-06