arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2505.00560cs.IR
收藏

通过动态剪枝子项嵌入实现百万级物品的高效推荐

Efficient Recommendation with Millions of Items by Dynamic Pruning of Sub-Item Embeddings

Aleksandr V. Petrov, Craig Macdonald, Nicola Tonellotto

AI总结:

针对大规模物品目录导致序列推荐模型推理慢的问题,提出动态剪枝算法 RecJPQPrune,在保证 top K 推荐效果无损的前提下,无需 GPU 和 ANN 技术即可在 10 毫秒内完成 200 万物品评分。

摘要:

庞大的物品目录是部署现代序列推荐模型的一大挑战,因为这会导致模型的内存占用巨大并增加推理延迟。解决该问题的一种有前景的方法是 RecJPQ,它用子项嵌入替代物品嵌入。然而,缓慢的推理仍然是个问题,因为寻找得分最高的物品通常需要对目录中的所有物品进行评分,这对于庞大的目录可能不可行。通过借鉴文档检索中的动态剪枝概念,我们提出了 RecJPQPrune 动态剪枝算法,能够在不计算目录中所有物品得分的情况下,高效地找到得分最高的物品。我们的 RecJPQPrune 算法在排名 K 之前是安全的,因为它在理论上保证了没有任何潜在的高分物品会被排除在最终的 top K 推荐列表之外,从而确保对效果没有影响。我们在两个大型数据集和三个推荐模型上的实验证明了使用 RecJPQPrune 可实现的效率:例如,在包含 2.2M 物品的 Tmall 数据集上,与 Transformer Default 基线相比,我们可以将模型评分的中位时间减少 64 倍,与一种名为 PQTopK 的最新评分方法相比减少了 5.3 倍。总体而言,本文展示了基于 Transformer 的推荐模型在文献中未曾报道过的目录规模下的有效且高效的推理。实际上,我们的 RecJPQPrune 算法可以在不使用 GPU 且不依赖近似最近邻(ANN)技术的情况下,在 10 毫秒内对 200 万个物品进行评分。

英文摘要:

A large item catalogue is a major challenge for deploying modern sequential recommender models, since it makes the memory footprint of the model large and increases inference latency. One promising approach to address this is RecJPQ, which replaces item embeddings with sub-item embeddings. However, slow inference remains problematic because finding the top highest-scored items usually requires scoring all items in the catalogue, which may not be feasible for large catalogues. By adapting dynamic pruning concepts from document retrieval, we propose the RecJPQPrune dynamic pruning algorithm to efficiently find the top highest-scored items without computing the scores of all items in the catalogue. Our RecJPQPrune algorithm is safe-up-to-rank K since it theoretically guarantees that no potentially high-scored item is excluded from the final top K recommendation list, thereby ensuring no impact on effectiveness. Our experiments on two large datasets and three recommendation models demonstrate the efficiency achievable using RecJPQPrune: for instance, on the Tmall dataset with 2.2M items, we can reduce the median model scoring time by 64 times compared to the Transformer Default baseline, and 5.3 times compared to a recent scoring approach called PQTopK. Overall, this paper demonstrates the effective and efficient inference of Transformer-based recommendation models at catalogue scales not previously reported in the literature. Indeed, our RecJPQPrune algorithm can score 2 million items in under 10 milliseconds without GPUs, and without relying on Approximate Nearest Neighbour (ANN) techniques.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑