In this guide, you'll learn how to build a Data Agent for Snowflake Intelligence using Snowflake Cortex AI that can intelligently respond to questions by reasoning over both structured and unstructured data.

We'll use a custom dataset focused on bikes and skis. This dataset is intentionally artificial, ensuring that no external LLM has prior knowledge of it. This gives us a clean and controlled environment to test and evaluate our data agent. By the end of the session, you'll have a working AI-powered agent capable of understanding and retrieving insights across diverse data types — all securely within Snowflake.

NOTE: Snowflake Intelligence is in Public Preview as of August 2025.

What is Snowflake Intelligence?

Snowflake Intelligence is an agentic AI solution, enabling business users to directly and securely interact with their organization's structured and unstructured data using natural language. Snowflake Intelligence provides:

What You Will Learn

What You Will Build

A Data Agent that can intelligently respond to questions by reasoning over both structured and unstructured data.

What You Will Need

To complete this lab, you'll need to create a Snowflake account.

  1. Click on this link to create a free trial account.
  2. Complete the first page of the form on the page.
  3. On the next section of the form, be sure to set the Snowflake edition to Enterprise (Most popular)).
  4. Select AWS – Amazon Web Services as the cloud provider.
  5. Select US West (Oregon) as the region.
  6. Complete the rest of the form and click Get started.

trial

This SQL script sets up roles, databases, schemas, integrations, and stages in Snowflake. Here's a summary of the objects being created:

Role:
  - snowflake_intelligence_admin (Privileges: create integrations, databases, use warehouse)

Databases:
  - snowflake_intelligence
  - dash_cortex_agents

Schemas:
  - snowflake_intelligence.agents
  - dash_cortex_agents.data

Privileges:
  - Grants to allow agent creation on the snowflake_intelligence.agents schema

API Integration:
  - git_api_integration (For accessing GitHub via HTTPS)

Git Repository:
  - git_repo (Links to a specific GitHub repository)

Stage:
  - docs (With Snowflake SSE encryption and directory enabled)

Data Copy:
  - Copies files from the Git repo into the docs stage

Notification Integration:
  - email_integration

Stored Procedure:
  - send_email

We will use Snowflake Notebook to setup the Cortex Analyst and Cortex Search tools that will be used by the data agent in Snowflake Intelligence.

Let's get started!

The semantic model maps business terminology to the structured data and adds contextual meaning. It allows Cortex Analyst to generate the correct SQL for a question asked in natural language.

Open the semantic model

Test the semantic model

Let's ask these analytical questions to test the semantic file:

Cortex Analyst and Cortex Search Integration

Using Cortex Analyst integration with Cortex Search, we can improve the retrieval of possible values of a column without listing them all in the semantic model file. Let's try it as an example for the ARTICLE NAMES.

Let's see what happens if we ask this question.

- Q. What are the total sales for the carvers?

At this point, you may see this response:

I apologize, but I'm not sure what 'carvers' refers to in the context of this data. The term 'carvers' could potentially refer to a specific article name, brand, or category, but it's not clear from your question which dimension you're referring to or if this value exists in our sales data.

Now let's integrate the ARTICLE_NAME dimension with the DASH_CORTEX_AGENTS.DATA.ARTICLE_NAME_SEARCH Cortex Search Service we created in the Notebook.

Now let's ask the same question again.

- Q. What are the total sales for the carvers?

Notice that Cortex Analyst is now able to provide the right answer because of the Cortex Search integration. Also note that we asked for "Carvers", but the literal article name is "Carver Skis."

Now that we have the tools ready, we can create a Data Agent for Snowflake Intelligence.

Create Agent

An agent is an intelligent entity within Snowflake Intelligence that acts on behalf of the user. Agents are configured with specific tools and orchestration logic to answer questions and perform tasks on top of your data.

Note that you can create multiple agents for various use cases and/or business teams in your organization.

Add Instructions

Add the following starter questions under Sample questions:

Add Tools

Tools are the capabilities an agent can use to accomplish a task. Think of them as the agent's skillset and note that you can add one or more of each of the following tools.

Launch Snowflake Intelligence

Open Snowflake Intelligence and make sure you're signed into the right account. If you're not sure, click on your name in the bottom left » Sign out and sign back in. Also note that your role should be set to SNOWFLAKE_INTELLIGENCE_ADMIN.

Now, let's ask the following questions.

Unstructured Data

These are questions where the answers can be found in the PDF documents and image descriptions.

- Q. What is the guarantee of the premium bike?

In this case, we can see how it cites the warranty information extracted from the PDF file.

- Q. What is the length of the carver skis?

Since we have processed images, the extracted descriptions can also be used by Cortex Agents to answer questions.

- Q. Is there any brand in the frame of the downhill bike?

Structured Data

These are analytical questions where the answers can be found in structured data stored in Snowflake tables.

- Q. Show me monthly sales revenue trends by product category over the past 2 years.

- Q. How many carvers are we selling per year in the North region?

Notice that all 3 tables are used to answer this question.

- Q. How many infant bikes are we selling per month?

- Q. What are the top 5 customers buying the carvers?

Congratulations! You've learned how to securely build data agents and agentic application in Snowflake.

What You Learned

Related Resources