Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

obithelight/cortex-agent-api-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

11 Commits

Repository files navigation

Build an LLM Agent in 5 minutes

Overview

This repository shows you how to build an LLM using Snowflake's API.

Screenshot 2025年03月07日 at 12 04 05 AM

Instructions

  1. Clone this repo.

  2. Sign up for an account here. Activate your account and you should see a welcome screen.

  3. Go to Projects -> Worksheets -> Click Create SQL Worksheet

  4. Copy and paste the entire setup.sql into the worksheet and hit run. It might take a couple of minutes for Step 9 to finish! You should see the following response: Stage area MODELS successfully created.

  5. Go to Data -> Add Data -> Click Load files into a Stage.

  6. Upload the sales_metrics_model.yaml file. Make sure to select SALES_INTELLIGENCE.DATA as your database + schema and MODELS as your 'Stage'.

Screenshot 2025年03月06日 at 11 47 56 PM
  1. Create a folder called .streamlit and a file called secrets.toml inside.

  2. Click on your name in the bottom left corner, and select Connect a tool to Snowflake. Use the dialog to fill out your information, replacing values in [] like so:

[snowflake]
account = "[Account Identifier]"
user = "[User Name]"
password = "[Same as when you signed up. Be careful here and don't check this in to GitHub!"
role = "[Role]"
host = "[Account/Server URL]"
  1. Run pip install -r requirements.txt to make sure you have all the dependencies working.

  2. Run streamlit run streamlit.app and you should see a chat assistant ready to work with you! Try a few prompts:

  • "What was the total sales volume last year?" should output a SQL query and an interpretation of your request.
  • "Summarize the call with TechCorp Inc" should give you a summary of the call transcript.

About

Build an LLM Agent

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 100.0%

AltStyle によって変換されたページ (->オリジナル) /