Google Cloud Blog
Follow
AlloyDB AI Functions - now with revolutionary performance boosts and cost savings
AlloyDB is an AI-native database that intelligently processes data, offering features like vector search and natural language-to-SQL capabilities. It integrates foundation models like Gemini directly through AI functions, which bring Gemini’s world knowledge to your data. These functions transform unstructured data, like raw user feedback, into structured insights, eliminating the need for complex custom pipelines. For example, ai.generate can convert raw text into clean, structured JSON.New AI functions include ai.summarize, ai.agg_summarize, and ai.analyze_sentiment, which categorize emotional tone, condense text, and summarize multiple rows, respectively. AlloyDB has achieved significant performance and cost improvements in AI function processing through two key breakthroughs. Smart Batching for AI Functions intelligently groups AI function calls, deduplicating prompt overhead and boosting performance up to 2,400 times. AlloyDB automatically determines optimal batch sizes and handles retries.Optimized AI Functions, initially for ai.if, deploy a small, proxy model trained on your data, reducing external LLM calls dramatically. This can process up to 100,000 rows per second and cut costs by 6,000 times. AlloyDB trains this proxy model in the background when you use the PREPARE statement and automatically falls back to the LLM if accuracy is low. These optimizations allow users to process complex queries, such as filtering products based on specific numerical constraints, with unprecedented speed and cost efficiency.Users can get started with AlloyDB’s 30-day free trial and enable AI functions directly within their SQL queries. To maximize performance and cost savings, users can leverage optimized functions and smart batching. These advancements empower users to bring Gemini’s intelligence to their AlloyDB data efficiently.