Category-Specific CNN for Visual-aware CTR Prediction at JD.com

Hu Liu, Jing Lu, Hao Yang, Xiwei Zhao, Sulong Xu, Hao Peng, Zehua Zhang, Wenjie Niu, Xiaokun Zhu, Yongjun Bao, Weipeng Yan · DOI

TL;DR

Researchers from JD.com introduce Category-Specific CNN (CSCNN), a novel deep learning architecture that incorporates product category knowledge directly into early CNN layers via attention mechanisms to improve click-through rate (CTR) prediction. By decoupling heavy image feature extraction into an offline pipeline and utilizing an online lookup table, the system achieves significant revenue lifts on a 10-billion-scale production dataset while maintaining a strict sub-20ms serving latency.

What Problem Does This Paper Address?

In e-commerce advertising, an attractive image can drastically improve an advertisement's Click-Through Rate (CTR). To leverage this, modern recommendation systems use Convolutional Neural Networks (CNNs) to extract visual features from ad images.

However, standard architectures suffer from two major flaws:

  1. Suboptimal Late Fusion: Existing systems typically use off-the-shelf CNNs to extract image features independently, only combining them with non-visual features (like product category) at the very end of the network. Because the CNN is "blind" to the category, it wastes its limited representational capacity extracting irrelevant features (e.g., looking for dress patterns on a smartphone image).
  2. The Industrial Latency Wall: Training CNNs end-to-end on billions of production-scale interaction logs is computationally prohibitive. Furthermore, serving these heavy models online must happen within a razor-thin latency window (typically <20ms), making real-time CNN inference impossible.

Methods

The authors propose Category-Specific CNN (CSCNN), which shifts from a late-fusion to an early-fusion architecture by integrating category priors directly into the convolutional layers.

The overall CTR prediction system architecture, combining offline CSCNN feature extraction with an online lookup table and a Deep & Cross Network (DCN).

1. Category-Specific Attention Modules

For any given convolutional layer, CSCNN applies two light-weighted attention modules sequentially:

  • Channel-wise Attention ($M_c$): Determines what visual features to focus on. It applies max and average pooling to the feature map, concatenates the result with a learned category embedding ($A^k_c$), and passes it through a shared multi-layer perceptron (MLP) to modulate the channels.
  • Spatial Attention ($M_s$): Determines where to focus. To prevent a massive explosion of parameters from high-resolution spatial tensors, the network learns a downscaled category spatial prior ($A'^k_s$) and uses linear interpolation to resize it before applying a $7\times7$ convolutional filter.
Figure 3: Modules of our proposed Category-Specific CNN: Channel-wise Attention (top) and Spatial Attention (bottom).

2. Production-Scale Infrastructure

To make end-to-end training and real-time serving viable, the authors engineered a decoupled system:

  • Offline Training Trick: Impressions are batched by Ad ID. The image embedding for a specific ad is computed only once per batch and broadcasted across its corresponding impressions, reducing the CNN computational bottleneck.
  • Online Lookup Table: Instead of running the CNN online, the well-trained CSCNN pre-computes and dumps visual features into a 20 GB lookup table. The online system simply performs a fast key-value lookup based on the Ad ID.

Datasets

The model was evaluated on two primary sources:

  • Amazon Benchmark Datasets: Three widely used public datasets containing product reviews and metadata: Fashion (64k users, 234k items), Women (97k users, 347k items), and Men (34k users, 110k items).
  • JD.com Production Dataset: A massive, real-world dataset consisting of 15 billion interaction logs spanning 32 days, encompassing 200 million users, 20 million items, and 3,310 distinct product categories.

Key Insights and Ideas

  • Category as a Visual Prior: Product categories provide strong geometric and stylistic constraints. Informing the CNN of the category early acts as a powerful regularizer, allowing the model to ignore background noise and focus on category-defining visual patterns.
  • Decoupling Inference from Serving: The paper demonstrates that you do not need to run deep vision networks in real-time to reap their benefits online. Pre-computing embeddings offline and serving them via lookup tables completely sidesteps the online latency barrier.
  • Attention Adaptability: The category-conditioned early fusion mechanism is backbone-agnostic. The authors successfully integrated it into both standard ResNet18 and Inception V1 architectures, yielding consistent performance improvements.

Key Results

  • Benchmark Superiority: CSCNN outperformed all state-of-the-art late-fusion baselines (such as VBPR, DVBPR, Sherlock, and DeepStyle) across all three Amazon datasets under both point-wise and pair-wise loss configurations.
  • Production Performance: On JD's 10-billion-scale dataset, adding CSCNN to a baseline Deep & Cross Network (DCN) improved the offline Area Under the ROC Curve (AUC) by +0.0086. In the context of JD.com, every 1‰ (0.001) increase in offline AUC translates to roughly \$6 million in additional advertising revenue.
  • Online A/B Testing: Deployed live in JD's search advertising system serving hundreds of millions of active users, CSCNN achieved a +3.22% CTR gain and a +2.46% eCPM (Effective Cost Per Mille) gain, while successfully reducing the Cost Per Click (CPC) by 0.62%.
  • System Efficiency: The training infrastructure completed a full run over the 10-billion-scale dataset within 24 hours using 28 P40 GPUs. Online serving latency (tp99) remained safely below 20ms on CPU.

Limitations and Future Work

Because the image embeddings must be pre-computed offline to satisfy strict latency constraints, the CNN cannot utilize dynamic, real-time features such as the user's immediate search query or real-time user context.

The authors note that future work will explore incorporating other static, visual-related item attributes—such as brand ID, shop ID, and specific product keywords—into the early-fusion attention pipeline to further refine the visual representations.

Summary updated

BibTeX
@misc{liu2020category,
  author = {Hu Liu and Jing Lu and Hao Yang and Xiwei Zhao and Sulong Xu and Hao Peng and Zehua Zhang and Wenjie Niu and Xiaokun Zhu and Yongjun Bao and Weipeng Yan},
  title = {{Category-Specific CNN for Visual-aware CTR Prediction at JD.com}},
  year = {2020},
  eprint = {2006.10337},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2006.10337},
}
Figure