ML Pipeline with Snowpark & Snowflake

Integrate Snowpark (Snowflake’s Python framework) with Valohai to train and serve ML models inside Snowflake.


Overview

This example demonstrates:

  • Running Snowpark jobs from Valohai

  • Training and deploying models within Snowflake

  • Visualizing predictions in Snowpark Container Service


Steps

1

Data Loading

Load the data from a CSV to a Snowflake table called SOURCE_OF_TRUTH.

2

Model Training

Use the loaded data to train and test a model to predict insurance charges.

3

Mock Streaming Data

Use the some of the data in INCOMING_DATA_SOURCE and insert it to LANDING_TABLE to mock the process of data coming in.

4

Running Inference

Use the model to run inference on incoming data and save results.

5

Deploy a Streamlit app to Snowpark Container Service

Trigger a long running service in Snowpark Container Service to host the Streamlit app.


GitHub Repository

The repository walks you through the steps above:

Last updated

Was this helpful?