This demo does the following:
- Records audio from the default microphone
- Does speech to text transcription
- Pipes those words to Snowflake using Snowpipe Streaming
- Has a DT that aggregates words and their counts
- Has a DT that uses the aforementioned DT with an ads table to determine what ads to show to the user
Set up a role that has create database/warehouse, ex:
use role accountadmin;
create or replace role tjones_summit_rl;
grant create database on account to role tjones_summit_rl;
grant create warehouse on account to role tjones_summit_rl;
grant role tjones_summit_rl to user tjones;
Set up a private/public keypair for the user by following these instructions.
Create a profile.json with the following attributes:
user: Login Name or Name of Userurl: The account URL, exhttps://account.snowflakecomputing.comaccount: Name of the accountprivate_key: The private key contents, without headersport: Port to use, use443for secure connectionshost: Account URL, exaccount.snowflakecomputing.comrole: The role to use, extjones_summit_rl
Create the following directories locally:
mkdir audio;
mkdir audio_raw;
Build the Client SDK driver:
mvn clean install;
Set the following environment variables:
SNOW_ACCOUNT: The name of the account, exaccountSNOW_ROLE: The name of the role to use, extjones_summit_rlSNOW_USER: Login Name or Name of UserSNOW_PW: Password of the user.
Set up the Python virtual environment:
python -m venv venv;
source venv/bin/activate;
pip install -r requirements.txt
Run the demo, either via Python or the run_demo.sh script:
python summit_demo.py -nopython
OR
./run_demo.sh