Semantic Vector Retrieval and I2I Recall Optimization in Xianyu Search
Xianyu search recall stage upgraded from simple text matching to semantic vector retrieval using DSSM with Electra‑Small, query graph attention, and behavior‑based I2I, adding structured attributes and OCR tags, improving AUC to 0.824 and HitRate@10 to 90.1%, boosting purchase metrics by up to 4%.
The recall stage is the foundation of Xianyu's search funnel, yet it historically relied on simple text matching and limited field extensions, restricting both relevance and personalization.
To enrich item representations, structured attributes (category, CPV), image‑derived OCR tags, and I2I migration information (similar items via swing techniques) were added, along with other predictive tags.
Analysis revealed two major gaps: (1) query‑side recall still used strict term matching without semantic flexibility, and (2) the system lacked personalized recall, often discarding potentially relevant items.
In response, a semantic vector recall was introduced. The model follows a DSSM architecture with an Electra‑Small encoder (≈47 M parameters). Query towers incorporate neighboring queries (Q2Q) via a self‑attention module, and missing Q2Q signals are randomly masked to handle long‑tail queries.
Two loss functions were explored:
Classic Triple loss: loss = loss_fun(scores, labels)
InfoNCE loss with temperature scaling for better generalization.
Data construction focuses on relevance: positive samples are high‑CTR items under the same query, while negatives include random batch items, same‑category neighbors, low‑exposure items, and term‑replacement queries.
Graph Query Attention builds a query graph by concatenating the top‑3 similar queries (Swing Q2Q) and feeding them to the query tower with distinct segment IDs, enabling direct attention between the key query and its graph context.
Online deployment leverages the Ha3 vector engine. Indexes are refreshed daily (full T+1) and incrementally via SARO pipelines for item status changes. Multi‑path recall combines inverted, vector, and I2I engines, each with configurable recall quotas.
Behavior‑based I2I (Q2I2I) was further added: a query retrieves a trigger item (online top exposure or offline historical stats), which then maps to candidate items via recommendation or “you may also like” logs. This pipeline boosted 7‑day per‑user purchase‑seller metrics by up to +4 % but required strict relevance filters (category, core term, dynamic thresholds) to control bad‑case rates.
Experimental results show AUC improvements from 0.78 to 0.824 and HitRate@10 gains from 80.7 % to 90.1 % across various model variants. The trade‑off between relevance and efficiency remains a key focus, with future work targeting soft relevance constraints, multimodal fusion, and more robust personalization.
Xianyu Technology
Official account of the Xianyu technology team
How this landed with the community
Was this worth your time?
0 Comments
Thoughtful readers leave field notes, pushback, and hard-won operational detail here.