High severityresource
Power BI Refresh Error:
CORTEX_FUNCTION_QUOTA_EXCEEDED
What does this error mean?
A Snowflake Cortex AI function call was rejected because the account has exceeded its monthly token or request quota for AI/ML functions.
Common causes
- 1High-volume batch processing using SNOWFLAKE.CORTEX.COMPLETE() or EMBED_TEXT() exhausted the monthly token quota
- 2Multiple users running large-scale AI queries simultaneously depleted the quota faster than expected
- 3The account is on a tier with lower Cortex AI token limits (Standard vs Business Critical)
- 4An automated pipeline is running Cortex functions more frequently than planned
How to fix it
- 1Step 1: Check current Cortex usage in SNOWFLAKE.ACCOUNT_USAGE.CORTEX_FUNCTIONS_USAGE_HISTORY.
- 2Step 2: Contact Snowflake support or your account team to request a quota increase.
- 3Step 3: Add quota checks to automated pipelines: query usage history before running large Cortex batch jobs.
- 4Step 4: Optimize token usage by truncating input text to the minimum needed for the task.
- 5Step 5: Consider caching Cortex AI results in a table to avoid redundant calls on the same input.