Snowflake Tools

The Snowflake Tools allow DinoAI to explore your Snowflake account β€” listing databases, schemas, tables, and columns β€” and to analyse the performance of specific queries in depth. This gives DinoAI the context it needs to help you write accurate SQL, build dbt models, and diagnose cost or performance issues, all without leaving Paradime.

plug-circle-plus

Requires a Snowflake connection. These tools are only available when your workspace is connected to Snowflake. See your workspace settings to configure a Snowflake credential.

Capabilities

The Snowflake Tools give DinoAI the following abilities:

  • List all databases in your Snowflake account

  • List all schemas within a given database

  • List all tables within a given database and schema, including row counts, size in bytes, and creation timestamps

  • Inspect column names, types, and comments for any table using DESCRIBE TABLE

  • Retrieve comprehensive performance statistics for a specific query, including execution plan operator stats, bytes scanned, spill metrics, cache efficiency, and queue times

Using the Snowflake Tools

  1. Open DinoAI in the right panel of the Code IDE

  2. Describe what you want to explore or investigate (e.g., a table name, a Snowflake query ID, or a question about performance)

  3. Add your prompt describing what you want DinoAI to do with that information

  4. Grant permission when DinoAI asks to access your Snowflake account

  5. Review the results and implement DinoAI's suggested actions

Example Use Cases

Generating a dbt Source File

Prompt

Result: DinoAI runs DESCRIBE TABLE RAW.PUBLIC.ORDERS, fetches all column names, types, and comments, and produces a ready-to-use sources.yml file with the correct structure and any available column descriptions pre-filled.

Diagnosing a Slow Query

Prompt

Result: DinoAI queries SNOWFLAKE.ACCOUNT_USAGE.QUERY_HISTORY for overall metrics (total elapsed time, compilation time, bytes scanned, cache hit rate, spill to local/remote storage) and GET_QUERY_OPERATOR_STATS() for step-level operator statistics. It then surfaces the bottleneck β€” such as excessive remote spillage or a large join β€” and recommends optimisations.

Exploring an Unfamiliar Database

Prompt

Result: DinoAI lists all schemas in the database, then lists the tables within each (including row counts and sizes), giving you a complete picture before writing queries or building models.

Working with Other Tools

The Snowflake Tools work well alongside DinoAI's other capabilities:

  • Combine with the dbt Tools to inspect Snowflake source tables and immediately scaffold dbt models or source definitions

  • Combine with the Catalog Search Tool to cross-reference Snowflake table structure with existing dbt model documentation

  • Combine with the Column Level Lineage Tool to trace how a specific column flows from a raw Snowflake table through your dbt transformations

Best Practices

  • Use uppercase identifiers β€” Snowflake stores unquoted identifiers in uppercase; DinoAI normalises identifiers to uppercase automatically, but being consistent in your prompts avoids confusion

  • Use the three-part identifier β€” Snowflake tables are referenced as DATABASE.SCHEMA.TABLE; providing all three parts helps DinoAI navigate directly to the right resource

  • Provide a valid UUID for performance queries β€” The query performance tool requires a valid Snowflake query UUID; you can find this in the Snowflake Query History UI or in query logs

  • Check permissions β€” DinoAI surfaces a [ERROR] if it cannot access a resource; confirm your Snowflake role has access to SNOWFLAKE.ACCOUNT_USAGE for performance queries and the necessary privileges on target databases

Last updated

Was this helpful?