Snowflake Cortex 및 노트북 소개

Snowflake에서 시작하는 생성형 AI

James Cha-Earley

Senior Developer Advocate, Snowflake

강사를 소개합니다!

 

$$

James Cha-Earley

  • Snowflake 수석 개발자 옹호자

 

강사 사진

Snowflake에서 시작하는 생성형 AI

Snowflake Cortex

Snowflake Cortex AI

  • 프로덕션급 AI를 손쉽게 활용
1 이미지 출처: https://www.snowflake.com/en/product/features/cortex/
Snowflake에서 시작하는 생성형 AI

Cortex AI

$$

  • SQL, Python, 노트북 간 네이티브 통합

$$

  • Snowflake 내 실험부터 운영까지

$$

  • 거버넌스, 정책, 관측 가능성 내장

Snowflake 로고 아이콘

Snowflake에서 시작하는 생성형 AI

코스 데이터

코스 데이터 쿼리로 상위 10개 행 표시 - date, rating, description, hotel_name, city, country, language

Snowflake에서 시작하는 생성형 AI

템플릿 코드

템플릿 Python 및 SQL 코드가 있는 노트북

Snowflake에서 시작하는 생성형 AI

데이터 쿼리

열 설명: date, rating, description, hotel_name, city, country, language 및 데이터 유형

Snowflake에서 시작하는 생성형 AI

Python 변수 주입

  • SQL 쿼리에 대입할 Python 변수 만들기

target_location이라는 Python 변수 생성 후 Cancun 값 할당

Snowflake에서 시작하는 생성형 AI

Python 변수 주입

Python 변수를 SQL 쿼리에 주입

Snowflake에서 시작하는 생성형 AI

Cortex 설정

Cortex 설정

Snowflake에서 시작하는 생성형 AI

텍스트 요약

from snowflake.cortex import summarize

review = """ I was very impressed with this hotel, especially the service. They make you feel special and you feel like everything is possible. Special shout out to the Kidz Club staff. Our daughter is very picky and for the first time, she begged to go back there. They have a great supervision and they let the kids do fun activities such as cooking classes and crafting. The food was really good (buffet offered a different choice everyday). The all-inclusive program is really worth the price, and the beach was beautiful! """
Snowflake에서 시작하는 생성형 AI

텍스트 요약

result = summarize(text=review)

print(result)

$$

The hotel delivered excellent service with outstanding Kidz Club staff who engaged 
even picky children through supervised activities. The daily buffet offered good
variety, and the all-inclusive program plus beautiful beach provided great value.
Snowflake에서 시작하는 생성형 AI

SQL 셀에서 Cortex 사용

SQL 셀에서 summarize 실행

$$

  • SQL 셀에서는 import 불필요

$$

  • 여러 함수를 연결하려면 Python 셀 사용
Snowflake에서 시작하는 생성형 AI

연습해 봅시다!

Snowflake에서 시작하는 생성형 AI

Preparing Video For Download...