优化批量查询架构,让亿级推荐系统毫秒响应
An Enhanced Batch Query Architecture in Real-time Recommendation
- 采用缓存行感知的探测方法优化哈希结构,提升批量查询吞吐
- 支持NVMe两级存储,实现热冷数据分离,资源消耗显著降低
- 适用于大规模实时推荐系统,尤其适合需要动态更新的场景
在网站和应用的工业级推荐系统中,需在毫秒内从百亿级内容池中召回并预测用户感兴趣的前N项结果。为应对持续增长的数据并提升实时推荐性能,我们设计并实现了高性能的批量查询架构。通过缓存行感知的探测方法优化哈希结构,增强合并哈希效果,并在此基础上构建混合存储键值服务。实验表明,该方法在批量查询吞吐上显著优于传统哈希表,结合并行优化后可达到随机内存访问吞吐的90%。支持NVMe,采用两级存储管理热/冷数据,明显降低资源开销。系统还支持动态更新、自动属性与特征嵌入表分片,以及创新的一致性协议,提升实时增量学习效果。该架构已在bilibili推荐系统部署超过一年,服务数亿用户,模型计算量提升10倍,资源增长极小,同时保持系统实时性能。
原文摘要 · Abstract (English)
In industrial recommendation systems on websites and apps, it is essential to recall and predict top-n results relevant to user interests from a content pool of billions within milliseconds. To cope with continuous data growth and improve real-time recommendation performance, we have designed and implemented a high-performance batch query architecture for real-time recommendation systems. Our contributions include optimizing hash structures with a cacheline-aware probing method to enhance coalesced hashing, as well as the implementation of a hybrid storage key-value service built upon it. Our experiments indicate this approach significantly surpasses conventional hash tables in batch query throughput, achieving up to 90% of the query throughput of random memory access when incorporating parallel optimization. The support for NVMe, integrating two-tier storage for hot and cold data, notably reduces resource consumption. Additionally, the system facilitates dynamic updates, automated sharding of attributes and feature embedding tables, and introduces innovative protocols for consistency in batch queries, thereby enhancing the effectiveness of real-time incremental learning updates. This architecture has been deployed and in use in the bilibili recommendation system for over a year, a video content community with hundreds of millions of users, supporting 10x increase in model computation with minimal resource growth, improving outcomes while preserving the system's real-time performance.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。