  Recently, real-world recommendation systems need to deal with millions of
candidates. It is extremely challenging to conduct sophisticated end-to-end
algorithms on the entire corpus due to the tremendous computation costs.
Therefore, conventional recommendation systems usually contain two modules. The
matching module focuses on the coverage, which aims to efficiently retrieve
hundreds of items from large corpora, while the ranking module generates
specific ranks for these items. Recommendation diversity is an essential factor
that impacts user experience. Most efforts have explored recommendation
diversity in ranking, while the matching module should take more responsibility
for diversity. In this paper, we propose a novel Heterogeneous graph neural
network framework for diversified recommendation (GraphDR) in matching to
improve both recommendation accuracy and diversity. Specifically, GraphDR
builds a huge heterogeneous preference network to record different types of
user preferences, and conduct a field-level heterogeneous graph attention
network for node aggregation. We also innovatively conduct a
neighbor-similarity based loss to balance both recommendation accuracy and
diversity for the diversified matching task. In experiments, we conduct
extensive online and offline evaluations on a real-world recommendation system
with various accuracy and diversity metrics and achieve significant
improvements. We also conduct model analyses and case study for a better
understanding of our model. Moreover, GraphDR has been deployed on a well-known
recommendation system, which affects millions of users. The source code will be
released.
