QuestionQ77

Snowflake Gen AI & LLM Functions

Review this metadata from a SNOWFLAKE.CORTEX.COMPLETE function response:

Question Image

Which model parameters were used in the function?

  • A
  • B
  • C
  • D
Explanation

The usage block reports completion_tokens: 580, guardrails_tokens: 565, prompt_tokens: 61, and total_tokens: 1206, where total_tokens equals the sum of the other three. The presence of a nonzero guardrails_tokens value indicates that Cortex Guard (the guardrails parameter) was enabled for this call, since guardrails token accounting only occurs when guardrails is turned on. Also, since 580 completion tokens were generated, the max_tokens setting must have been high enough to permit that (4096), because a max_tokens value of 512 would have capped completion_tokens at or below 512. This combination — max_tokens set to 4096 and guardrails set to true — is consistent with Snowflake Cortex COMPLETE function options documented for controlling response length and enabling harmful-content filtering.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!