From the course: Building AI Agents with Snowflake
Unlock this course with a free trial
Join today to access over 25,300 courses taught by industry experts.
Creating your semantic view - Snowflake Tutorial
From the course: Building AI Agents with Snowflake
Creating your semantic view
Our agents need to query structured data, but they don't understand your business. They don't know what win rate means or how to calculate it. That's where semantic views come in. A semantic view is a business context layer that maps your business terms to database tables. Let's build one and see how it works. I'm in Snowflake. I'm going to go ahead and click on AI and ML, then Cortex Analyst. This is where we're going to build a semantic view. I'm going to go ahead and create the view on top right, create semantic view. First, we need to choose where to store the semantic view. We're going to select the Sales Intelligence database, then the data schema. I'll name this Sales Metrics View. For description, I'll write semantic view for B2B sales metrics and deal analysis. This next screen lets us provide context. You can add example SQL queries here if you have them, but we will just skip through for now. The important part is selecting our data source. Under select tables, click add…