BERT -based similarity learning for product matching (2020)

Abstract: Product matching, i.e., being able to infer the product being sold for a merchant-created offer, is crucial for any e-commerce marketplace, enabling product-based navigation, price comparisons, product reviews, etc. This problem proves a challenging task, mostly due to the extent of product catalog, data heterogeneity, missing product representants, and varying levels of data quality. Moreover, new products are being introduced every day, making it difficult to cast the problem as a classification task. In this work, we apply BERT-based models in a similarity learning setup to solve the product matching problem. We provide a thorough ablation study, showing the impact of architecture and training objective choices. Application of transformer-based architectures and proper sampling techniques significantly boosts performance for a range of e-commerce domains, allowing for production deployment.

## introduction with more and more retailers moving their business online the number of items available on e-commerce marketplaces, such as amazon, alibaba or allegro.pl, grows exponentially. in an environment with hundreds of millions of items listed for sale every day, providing a satisfactory search and purchase experience brings many challenges. one such huge challenge for e-commerce portals is introducing product-based experience, both for the buyers and for the merchants. from the buyer's perspective, this means facilitating the search process by grouping offers that refer to the same real-world product while being sold by different merchants. merchants, on the other hand, benefit by having access to a high-quality product catalog, which allows them to speed up the listing process and provide the buyers with more complete product descriptions. achieving product-based experience in any e-commerce portal is only made possible by being able to automatically find offers of the same product. this process is often called product matching. product matching in e-commerce is a non-trivial task mostly because of the large number of products, their high heterogeneity, missing product representants, and varying levels of data quality. for a more detailed overview of challenges that make product matching hard, we refer the reader to @xcite . classical approaches to product matching and its generalization (entity matching) often rely on rulebased methods and hand-crafted features such as string similarity measures @xcite @xcite . recent advances of deep learning in natural language processing (nlp) sparked increasing interest in end-to-end deep learning approaches both for entity matching @xcite and product matching @xcite @xcite . here, we follow this trend and present our experiences with leveraging transformer-based neural language models @xcite combined with the similarity learning setup for product matching. while transformer architectures have been very recently applied to entity matching @xcite , to the best of our knowledge, we are the first to apply them specifically for the product matching problem in e-commerce. aside from architectural choices, we show that sampling techniques tailored to the product matching domain prove to be crucial in the progress of similarity learning. the contributions of our paper are as follows: this work is organized as follows. section 2 introduces the product matching problem. section 3 describes our approach. in section 4 we present the experiments and results. section 5 briefly reviews the related work on product matching. finally, we discuss the challenges and conclude our work in section 6. ## product matching product matching aims at identifying offers of the same product across many merchants selling it in an e-commerce portal and integrating the information into a single entry in a product catalog. an offer is an instance of a specific good described by vendor-provided information. this information may include but is not limited to, title, its text description, attributes, category, and photos. a product represents a manufacturer's description of a good and is described similarly. at a typical e-commerce marketplace, one may find many offers of the same product. also, not all products need to have offer representatives (e.g. legacy or yet unmatched products). recent papers mostly focus on using only the information contained in the titles or using both titles and attributes @xcite . in this work, in addition to using the title and attributes information, we also make use of the category, i.e., an identifier of a set of goods of the same type. ## product matching with similarity learning in this work, we interpret the product matching problem as a similarity learning task. this approach allows us to cast product matching problem as a zero-shot learning problem, in result avoiding re-training the model on the introduction of new products or product categories. ## experiments and results in this section we present our experimental results, focusing on different aspects of the training pipeline. after briefly introducing the datasets and the baselines, we show different trade-offs that cover both the architectural choices for the model, and the batch construction strategies. ## conclusions in this work, we leverage the transformer architecture combined with the similarity learning approach to solve the product matching task in e-commerce. we show that finetuning even general-purpose transformers yields models that perform significantly better than other similarity learning baselines such as starspace. these models can be further improved by employing bert models pretrained on domainspecific data. our experiments emphasize the importance of the employed batch construction strategy. particularly, in our specific problem setup, a tailored batch construction strategy called category hard proved to significantly improve the percentage of active triplets and consequently the model performance. one particular challenge that we encountered during our work with the product matching problem, and one which we believe has not been adequately addressed in the product matching literature is concept drift. this problem, also called covariate shift or nonstationarity, refers to the change in the relationship between input and output variables over time. in the case of product matching, it ultimately leads to a gradual drop in accuracy of the predicted product matches. apart from the degradation of the model performance, another important issue arising from concept drift is the difficulty of evaluating new model versions. for a stationary problem, the standard procedure involves preparing a potentially costly humanannotated dataset once and using it for comparing the subsequent model version. unfortunately, this is not a viable strategy if the test set cannot be fixed. we plan to investigate the concept drift problem in our future work.