CACTUSDB: Unlock Co-Optimization Opportunities for SQL and AI/ML Inferences
Lixi Zhou, Kanchan Chowdhury, Lulu Xie, Jaykumar Tandel, Hong Guan, Zhiwei Fan, Xinwei Fu, Jia Zou

TL;DR
CactusDB is a system that unifies and optimizes SQL and AI/ML inference queries in databases, achieving significant speedups by supporting multiple co-optimization techniques through a novel IR and MCTS-based optimizer.
Contribution
It introduces CactusDB, a system that supports all major co-optimization techniques for SQL and AI/ML inferences using a three-level IR and a Monte-Carlo Tree Search optimizer.
Findings
Up to 441x speedup over existing systems.
Supports diverse inference workloads efficiently.
Effectively explores large optimization search spaces.
Abstract
There is a growing demand for supporting inference queries that combine Structured Query Language (SQL) and Artificial Intelligence / Machine Learning (AI/ML) model inferences in database systems, to avoid data denormalization and transfer, facilitate management, and alleviate privacy concerns. Co-optimization techniques for executing inference queries in database systems without accuracy loss fall into four categories: (O1) Relational algebra optimization treating AI/ML models as black-box user-defined functions (UDFs); (O2) Factorized AI/ML inferences; (O3) Tensor-relational transformation; and (O4) General cross-optimization techniques. However, we found none of the existing database systems support all these techniques simultaneously, resulting in suboptimal performance. In this work, we identify two key challenges to address the above problem: (1) the difficulty of unifying all…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsAdvanced Database Systems and Queries · Cloud Computing and Resource Management · Data Management and Algorithms
