Snowflake adds AI evaluation and optimization for Cortex Functions
Snowflake has introduced native evaluation and optimization tools for Cortex AI Functions, helping teams compare models and prompts against quality and cost requirements before scaling AI workloads.
- Snowflake introduced native evaluation and optimization tools for Cortex AI Functions.
- AI_FUNCTION_EVALUATION measures quality, token usage and cost against labeled examples.
- AI_FUNCTION_OPTIMIZATION tests model, prompt and implementation combinations.
- Snowflake’s synthetic example reported a 0.98 score and 89% lower inference cost for an optimized Haiku candidate.
A lifecycle for building and improving AI functions
The tools are designed for AI data engineers working with applications that turn conversations and other multimodal data into summaries, recurring themes, fraud-risk flags and user preferences. Snowflake describes a four-stage workflow: Build, Evaluate, Optimize and Deploy.
The company gives the example of a friend-connection application that recommends a next action for user conversations. Such an application could use AI to identify a possible scam, suggest a date, recommend similar profiles or keep a conversation going.
Snowflake says custom AI functions are now generally available. Teams can package instructions and a model choice into reusable functions called through SQL, while managing access through Snowflake’s existing controls. This allows organizations to define the logic centrally rather than recreating it in each application.
Evaluation measures quality, usage and cost
AI_FUNCTION_EVALUATION, also generally available, tests AI functions against labeled examples. Snowflake says it reports output quality, token usage and cost, allowing teams to assess whether an implementation meets its requirements and estimate the cost per conversation before expanding to larger workloads.
Teams can select evaluation metrics suited to their task. In Snowflake’s example, the llm_judge method compares a function’s recommendations with expected actions. For fixed labels, the company says exact_match is another option.
The evaluation results establish a baseline for comparing alternative prompts, models and implementations. They can also help teams separate changes that appear promising from changes that produce better outputs.
Optimization searches model and prompt combinations
AI_FUNCTION_OPTIMIZATION automates the search for configurations that meet quality requirements at a lower inference cost, according to Snowflake. The product brings agentic optimization algorithms, including Snowflake’s CoCoEvolve and GEPA, into production workloads.
Using the models, evaluation data, scoring criteria and budget supplied by a team, the system tests alternative prompts, models and function implementations. Teams can configure an optimization through the Snowsight interface, with CoCo, or directly in SQL.
In Snowflake’s synthetic connection-app example, an optimized Haiku candidate achieved a validation score of 0.98, compared with 0.95 for the Opus baseline, at 89% lower inference cost. Snowflake says the scenario is hypothetical and does not predict or guarantee specific results or cost savings.
Snowflake: AI Functions Optimization: Higher Quality at Lower Cost
