How Shopify Uses LLMs to Reconcile Inconsistent Product Options for AI Shopping Agents
Shopify engineer Andrei Danilchenko explains a two-stage pipeline that builds a shared product vocabulary from merchant evidence and applies it to standardize options across listings, plus an Option Mining component that recovers missing choices from titles and metafields when merchants describe variants in separate listings.
When an AI shopping agent encounters four listings for the same shirt from different stores, it sees "Color: Black," "Colour: Black," "Style: Black/M," and "Couleur: Noir." A human reading these side by side recognizes they describe the same choice. An agent comparing thousands of such listings needs a systematic way to reconcile them. Shopify's engineering team describes how they built that system.
The central design decision is to separate vocabulary construction from application. Rather than asking a large language model to produce a clean list of standardized names in one pass, Shopify divides the work into two jobs: first building and reviewing shared meanings from merchant evidence, then applying those mappings to product variants. The construction process must make equivalent terms meet without forcing distinct properties together.
The Build pipeline starts by aggregating merchant-provided option names and their observed values, grouped by product category. This grouping matters: a "Size" field on clothing and a "Size" field on a storage device should not compete for the same interpretation simply because their names match. Category context narrows the question before the LLM considers plausible meanings. The existing Standard Product Taxonomy, which Shopify has open-sourced, enters here as a starting vocabulary rather than a fixed endpoint. The LLM can reuse an existing attribute, propose a missing one, or reject unsuitable input. This makes extension an explicit decision rather than an automatic outcome.
A key insight is establishing the property before interpreting the answer. Resolving the attribute first gives values a meaning and a type. A clothing size needs its sizing system. A package weight needs a number and a unit. A color can use named values. Treating them all as labels would hide information needed later. One pass still leaves duplicates because evidence is processed in batches, and two batches can propose different names for the same missing property. The system therefore compares new attribute proposals within each category before resolving their values, using text embeddings to retrieve plausible matches and then LLM judgment to confirm equivalence.