Schema:

ACCOUNT_USAGE

CORTEX_DOCUMENT_PROCESSING_USAGE_HISTORY view

This Account Usage view displays document processing function activity, including PARSE_DOCUMENT (SNOWFLAKE.CORTEX), AI_EXTRACT, and <model_build_name>!PREDICT calls. It shows pages processed and credits used, aggregated hourly by function and model. The view includes metadata such as the following:

  • Warehouse ID
  • Execution timestamps
  • Function names
  • Model names

Columns

Column NameData TypeDescription
QUERY_IDVARCHARA unique identifier for the SQL query
CREDITS_USEDNUMBER(38,9)The number of credits billed for Cortex Document processing functions for the specified query
START_TIMETIMESTAMP_LTZStart of the hourly time range in which the query usage took place.
END_TIMETIMESTAMP_LTZEnd of the hourly time range in which the query usage took place.
FUNCTION_NAMETEXTThe name of the Cortex Document processing function
MODEL_NAMETEXTThe name of the model
OPERATION_NAMETEXT
The name of the operation

Valid values:

  • inference
  • train
PAGE_COUNTNUMBERThe number of pages processed
DOCUMENT_COUNTNUMBERThe number of documents processed
FEATURE_COUNTNUMBERThe number of data values defined for document processing operations that involve entry extraction

Usage notes

  • The view provides up-to-date credit usage for an account within the last 365 days (1 year).
  • Credit rate usage is based on the number of messages processed, as outlined in the Snowflake Service Consumption Table.