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

CAFE:面向大规模推荐模型的紧凑、自适应且快速的嵌入

CAFE: Towards Compact, Adaptive, and Fast Embedding for Large-scale Recommendation Models

Institute of Computational Social Science, Peking University (Qingdao)(北京大学(青岛)计算社会科学研究院)

Hailin Zhang, Zirui Liu, Boxuan Chen, Yikai Zhao, Tong Zhao, Tong Yang, Bin Cui

AI总结:

本文提出 CAFE 嵌入压缩框架,通过 HotSketch 实时捕获热特征并分配唯一嵌入,对非热特征采用多级哈希嵌入共享,在满足内存效率、低延迟和适应动态数据分布的同时显著提升了推荐模型性能。

摘要:

近期,深度学习推荐模型(DLRMs)中嵌入表不断增长的内存需求,给模型训练和部署带来了巨大挑战。现有的嵌入压缩方案无法同时满足三个关键设计要求:内存效率、低延迟以及对动态数据分布的适应性。本文提出了 CAFE,一个紧凑、自适应且快速的嵌入压缩框架,以解决上述要求。CAFE 的设计理念是动态地将更多内存资源分配给重要特征(称为热特征),并将较少的内存分配给不重要的特征。在 CAFE 中,我们提出了一种名为 HotSketch 的快速且轻量级的草图数据结构,用于捕获特征重要性并实时报告热特征。对于每个被报告的热特征,我们为其分配唯一的嵌入。对于非热特征,我们允许通过使用哈希嵌入技术让多个特征共享一个嵌入。在我们的设计理念指导下,我们进一步提出了一个多级哈希嵌入框架,以优化非热特征的嵌入表。我们从理论上分析了 HotSketch 的准确性,并分析了模型在偏差下的收敛性。大量实验表明,CAFE 显著优于现有的嵌入压缩方法,在 10000x 的压缩率下,于 Criteo Kaggle 数据集和 CriteoTB 数据集上分别取得了 3.92% 和 3.68% 的更优测试 AUC。CAFE 的源代码已在 GitHub 上提供。

英文摘要:

Recently, the growing memory demands of embedding tables in Deep Learning Recommendation Models (DLRMs) pose great challenges for model training and deployment. Existing embedding compression solutions cannot simultaneously meet three key design requirements: memory efficiency, low latency, and adaptability to dynamic data distribution. This paper presents CAFE, a Compact, Adaptive, and Fast Embedding compression framework that addresses the above requirements. The design philosophy of CAFE is to dynamically allocate more memory resources to important features (called hot features), and allocate less memory to unimportant ones. In CAFE, we propose a fast and lightweight sketch data structure, named HotSketch, to capture feature importance and report hot features in real time. For each reported hot feature, we assign it a unique embedding. For the non-hot features, we allow multiple features to share one embedding by using hash embedding technique. Guided by our design philosophy, we further propose a multi-level hash embedding framework to optimize the embedding tables of non-hot features. We theoretically analyze the accuracy of HotSketch, and analyze the model convergence against deviation. Extensive experiments show that CAFE significantly outperforms existing embedding compression methods, yielding 3.92% and 3.68% superior testing AUC on Criteo Kaggle dataset and CriteoTB dataset at a compression ratio of 10000x. The source codes of CAFE are available at GitHub.

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

↑