Introduction
Modern online advertising systems utilize a multi-stage funnel to select the most relevant ads for users from a massive database. This process typically begins with Retrieval, where millions of candidates are narrowed down to thousands, followed by Pre-ranking, Ranking, and Reranking stages.
While later stages can afford complex models like Wide & Deep or IPNN to capture intricate feature interactions, the retrieval stage is strictly constrained by latency. Industry-standard "dual-tower" models maintain efficiency by keeping user and ad features separate until a final inner product. However, this architectural choice creates a "retrieval gap," as the model cannot account for specific user-ad feature interactions early in the funnel.
The HitMatch Framework
To bridge this gap, researchers from Tencent developed the HitMatch framework. This approach integrates complex feature interactions directly into the retrieval stage without sacrificing the millisecond-level speed required for production.
The framework enhances the traditional dual-tower architecture with two primary modules:
- Implicit Interaction (IPNN): An Inner Product-based Neural Network captures subtle dependencies. By computing interaction terms separately for user and ad towers and concatenating them, the system preserves the speed of the dual-tower structure.
- Explicit Interaction (HitMatch): This module captures historical user-ad overlaps (e.g., specific category clicks). It functions similarly to the "Wide" component in Wide & Deep models but is optimized for the retrieval scale.
Additionally, the training process utilizes a refined LambdaRank loss function that incorporates expected revenue (eCPM). This "Value-Aware" approach ensures the model optimizes for business outcomes rather than just click probability.
GPU-Powered Optimization
The core technical innovation lies in the GPU-powered compressed inverted list designed to handle the HitMatch module's computational load. Standard sparse matrix libraries (like cuSPARSE) proved insufficient for scanning millions of ads in real-time.
The custom operator achieves high performance through:
- Block-based Grouping: Ad indices are grouped to ensure a uniform workload across GPU threads.
- Data Compression: A specialized 24-bit header and 8-bit offset format minimizes memory bandwidth bottlenecks.
- Load Balancing: A "Merge-path" algorithm ensures synchronized thread completion, maximizing hardware utilization.
While building the GPU index takes approximately 224ms, this cost is amortized across hundreds of thousands of queries, making it viable for high-traffic environments.
Experimental Results
The system was evaluated using massive real-world datasets from Tencent’s WeChat ecosystem, including WeChat Channels and Moments.
Performance and Efficiency
- Throughput: The custom GPU operator reached 1904 QPS, representing a 7x speedup over standard cuSPARSE implementations.
- Latency: The entire HitMatch operation for millions of ads completes in under 500 microseconds on an NVIDIA Tesla T4.
- Accuracy: Offline metrics showed a 2.62% improvement in GAUC and a 5.21% increase in Recall@5 compared to the baseline dual-tower model.
Online Business Impact
A/B testing in live production environments confirmed the framework's effectiveness:
- WeChat Moments: Observed a +1.58% increase in Gross Merchandise Volume (GMV).
- WeChat Channels: Achieved a +1.49% GMV gain and a +2.5% improvement in Recall@100.
Conclusion and Limitations
The HitMatch framework demonstrates that the "retrieval gap" can be closed through specialized engineering and hardware-aware modeling. By redesigning data structures for GPU acceleration, complex feature interactions can be moved "up-funnel," significantly improving both retrieval accuracy and business metrics.
However, the system requires a few minutes to update the feature-to-ad mapping matrix, which may limit its use for extremely "fresh" content. Furthermore, performance gains are tightly coupled with specific GPU architectures, requiring hardware-specific tuning for different generations.
Summary updated