Skip to content
Lucas Lessa
Voltar para as notícias
SnowflakeGAImpacto: Médio

Automatic Response Caching for Snowflake Cortex AI Functions

Snowflake Cortex AI now reuses results from identical AI_COMPLETE calls within a single query, lowering costs and latency.

O que mudou

Snowflake Cortex AI now automatically caches AI_COMPLETE calls. When a query executes identical calls more than once, the platform reuses the stored result instead of running inference again, with no extra charge for cache hits.

Use cases

Imagine you process a large table with multiple rows containing identical text or prompts for tasks like summarization or classification:

  • Lower token costs in queries with repeated rows.
  • Speed up query execution when running AI at scale.

How to use

No action is required. Caching works automatically on a best-effort basis for text calls to the AI_COMPLETE function within a single query.

SELECT AI_COMPLETE(
  'my-model',
  'Summarize this text: Scheduled maintenance next Sunday.'
) AS response
FROM my_table;

What happens in this code:

  1. Snowflake sends the text to the chosen model via AI_COMPLETE.
  2. If identical calls occur within the same execution, the engine reuses the cached result.
  3. The query returns faster and consumes fewer credits for the repeated calls.

Limitations and requirements

  • Response caching applies to AI_COMPLETE text calls.
  • Caching is best effort and scoped to a single query.
Ver nota oficial do Snowflake

Response caching for Cortex AI Functions

Resumo e explicação gerados por IA a partir da release note oficial. Em caso de dúvida, a documentação oficial da plataforma prevalece.

Relacionadas