Skip to main content

llama-index readers huggingface fs integration

Project description

Hugging Face FS Loader

This loader uses Hugging Face Hub's Filesystem API (> 0.14) to load datasets.

Besides the existing load_data function, you may also choose to use load_dicts and load_df.

Usage

To use this loader, you need to pass in a path to a Hugging Face dataset.

from pathlib import Path
from llama_index import download_loader

HuggingFaceFSReader = download_loader("HuggingFaceFSReader")

# load documents
loader = HuggingFaceFSReader()
documents = loader.load_data("datasets/dair-ai/emotion/data/data.jsonl.gz")

# load dicts
dicts = loader.load_dicts("datasets/dair-ai/emotion/data/data.jsonl.gz")

# load df
df = loader.load_df("datasets/dair-ai/emotion/data/data.jsonl.gz")

This loader is designed to be used as a way to load data into LlamaIndex and/or subsequently used as a Tool in a LangChain Agent. See here for examples.

Project details


Download files

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

Source Distribution

Built Distribution

File details

Details for the file llama_index_readers_huggingface_fs-0.1.2.tar.gz.

File metadata

File hashes

Hashes for llama_index_readers_huggingface_fs-0.1.2.tar.gz
Algorithm Hash digest
SHA256 a38cee197f0291ab4376c79642fc488aef60a37304ff26c37cff27e6aa2a181b
MD5 008addd9bdfd33c630d6be6eeb274593
BLAKE2b-256 e37e251d2f84242b2cb440d8c95e0bccc398951272da678b6dd634f09e0826d9

See more details on using hashes here.

File details

Details for the file llama_index_readers_huggingface_fs-0.1.2-py3-none-any.whl.

File metadata

File hashes

Hashes for llama_index_readers_huggingface_fs-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 c76364fb8aae8dd919dabb21bfcaf3787ebd0e2b204148b88c6d5d86e7604465
MD5 0c6877be8ebe2623d270874d6ca9d6b9
BLAKE2b-256 248a9ecddb57a9918328e7d31231e10e2ea45a9c5dde565568a6ca8c259b5ed3

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page