Skip to main content

Snowflake Loader

pip install llama-index-readers-snowflake

This loader connects to Snowflake (using SQLAlchemy under the hood). The user specifies a query and extracts Document objects corresponding to the results. You can use this loader to easily connect to a database on Snowflake and pass the documents into a GPTSQLStructStoreIndex from LlamaIndex.

Usage

Option 1: Pass your own SQLAlchemy Engine object of the database connection

Here's an example usage of the SnowflakeReader.

from llama_index.readers.snowflake import SnowflakeReader

reader = SnowflakeReader(
    engine=your_sqlalchemy_engine,
)

query = "SELECT * FROM your_table"

documents = reader.load_data(query=query)

Option 2: Pass the required parameters to esstablish Snowflake connection

Here's an example usage of the SnowflakeReader.

from llama_index.readers.snowflake import SnowflakeReader

reader = SnowflakeReader(
    account="your_account",
    user="your_user",
    password="your_password",
    database="your_database",
    schema="your_schema",
    warehouse="your_warehouse",
    role="your_role",  # Optional role setting
    proxy="http://proxusername:proxypassword@myproxy:port",  # Optional proxy setting
)

query = "SELECT * FROM your_table"

documents = reader.load_data(query=query)

Author

Godwin Paul Vincent

This loader is designed to be used as a way to load data into LlamaIndex.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

llama_index_readers_snowflake-0.5.0.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

llama_index_readers_snowflake-0.5.0-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file llama_index_readers_snowflake-0.5.0.tar.gz.

File metadata

  • Download URL: llama_index_readers_snowflake-0.5.0.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for llama_index_readers_snowflake-0.5.0.tar.gz
Algorithm Hash digest
SHA256 9441bcbf5755efbd297eec8d9f9375f7c435f5289f220573b83e80df760ae798
MD5 230acd63f0de2dbf56fcc3a4640c9dfb
BLAKE2b-256 994b49e9885f87625da2fdc6173653e7346a69471970bab26538689b44f8acf3

See more details on using hashes here.

File details

Details for the file llama_index_readers_snowflake-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: llama_index_readers_snowflake-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.9 {"installer":{"name":"uv","version":"0.10.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for llama_index_readers_snowflake-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 597a7b07ec9c95d7929ddf9b90123b36f086d32e03fb395cbcff290e4861825b
MD5 1ad94dc3d18e0f90f5fd49606d7a2a23
BLAKE2b-256 9c7cbe5d9abb40aa7b11cab544e8e594606dc6b1598730652b28534eedd6cd60

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.5.0 This release

2 files

0.4.1

2 files

0.4.0

2 files

0.3.0

2 files

0.2.0

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

0.0.1

2 files

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page