LlamaIndex Readers Integration: Structured-Data
The function 'StructuredDataReader' supports reading files in JSON, JSONL, CSV, and XLSX formats. It provides parameters 'col_index' and 'col_metadata' to differentiate between columns that should be written into the document's main text and additional metadata.
Install package
pip install llama-index-readers-structured-data
Or install locally:
pip install -e llama-index-integrations/readers/llama-index-readers-structured-data
Usage
- for single document:
from pathlib import Path
from llama_index.readers.structured_data.base import StructuredDataReader
parser = StructuredDataReader(col_index=["col1", "col2"], col_metadata=0)
documents = parser.load_data(Path("your/file/path.json"))
- for dictory of documents:
from pathlib import Path
from llama_index.core import SimpleDirectoryReader
from llama_index.readers.structured_data.base import StructuredDataReader
parser = StructuredDataReader(col_index=[1, -1], col_metadata="col3")
file_extractor = {
".xlsx": parser,
".csv": parser,
".json": parser,
".jsonl": parser,
}
documents = SimpleDirectoryReader(
"your/dic/path", file_extractor=file_extractor
).load_data()
Metadata
Release files for llama-index-readers-structured-data 0.6.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| llama_index_readers_structured_data-0.6.0.tar.gz | 4.8 kB | Without provenance | Details for llama_index_readers_structured_data-0.6.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| llama_index_readers_structured_data-0.6.0-py3-none-any.whl | Python 3 | none | any | Details for llama_index_readers_structured_data-0.6.0-py3-none-any.whl |
Total release size: 9.3 kB
Release files / llama_index_readers_structured_data-0.6.0.tar.gz
| Download URL | llama_index_readers_structured_data-0.6.0.tar.gz |
|---|---|
| Size | 4.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bb4099ec8d4948938ee3141f2c3f5c13ee2c8d53e2616053e29b029e62d4aaf5
|
|
BLAKE2b-256 checksum How to use checksums |
c502985acde8236fe397e03bf476fc645a9b64abc07ebedaad859964d6635ba6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","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}
|
Release files / llama_index_readers_structured_data-0.6.0-py3-none-any.whl
| Download URL | llama_index_readers_structured_data-0.6.0-py3-none-any.whl |
|---|---|
| Size | 4.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dea278c2c1d23cb138ac34969ab179ac4094a38219298b45244a08d6b2f4f1eb
|
|
BLAKE2b-256 checksum How to use checksums |
8e7476010a2ae3f15abec4402ac4da6cb3406dddcaabb9c0311d8ec065c24f18
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.7 {"installer":{"name":"uv","version":"0.12.7","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}
|
Security for llama-index-readers-structured-data 0.6.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.