Skip to main content

kglite-datasets

Docs PyPI crates.io License: MIT

Fetch-build-cache dataset loaders for kglite — pull a public registry, build it into a queryable kglite KnowledgeGraph, cache the result. Extracted from kglite::datasets into a standalone crate + wheel so the kglite engine links zero network code.

Bundled sources:

  • SEC EDGAR — quarterly index, bulk submissions, per-form fetchers, XBRL company facts.
  • Sodir — Norwegian Offshore Directorate registry.
  • Wikidata — dump download / cache orchestration (heavy ingestion stays engine-side).

Install

pip install kglite-datasets      # ships the loaders + Python interface; pulls kglite

The single wheel bundles the Rust loaders and the Python interface; the graph engine is reused from kglite (a runtime dependency), not forked.

Usage

Each loader fetches its source, builds it into a kglite KnowledgeGraph, and caches the result under a workdir — returning a graph ready to query:

# SEC EDGAR — name a form, a company, a span:
from kglite_datasets.sec import SEC
g = SEC.fetch(workdir, "13F-HR", "TSLA", years=2, user_agent="Name email@dom")

# Sodir (Norwegian Offshore Directorate):
from kglite_datasets import sodir
g = sodir.open(workdir)

# Wikidata truthy dump (cache-managed download + N-Triples build):
from kglite_datasets import wikidata
g = wikidata.open(workdir)

g.cypher_query("MATCH (c:Company) RETURN c.name LIMIT 5")

Importing sec never drags in sodir/wikidata's optional stack (lazy submodules), so the SEC path stays light.

Rust

Rust embedders use the crate-root modules directly (they mirror kglite's former api::datasets::<loader> surface): kglite_datasets::{sec, sodir, wikidata}.

Status

Alpha — extraction complete. Followed the codingest handover playbook: copy → prove parity → freeze goldens + bench baseline (while kglite still had its in-tree copy) → kglite removed its loaders (2026-07-16). With the in-tree copy gone, the frozen goldens (tests/goldens/) and the frozen bench baseline (benchmarks/baseline.json) are the sole oracles carrying that verified-correct authority forward.

Development

make gate        # CI-equivalent local gate: lint · build · test · determinism · bench-smoke
make lint        # cargo fmt --check + clippy -D warnings (+ ruff if installed)
make develop     # maturin develop — build the extension into the active venv
make pytest      # offline Python suite (live-API tests behind the `live` marker)

The Rust workspace: crates/kglite-datasets (engine-free loaders) + crates/kglite-datasets-py (PyO3 wrapper → the wheel). Loaders fetch → parse → emit CSV/blueprint/dump; the graph build reuses kglite's from_blueprint / load_ntriples. All tests are offline (recorded HTTP fixtures); live-API smokes are opt-in.

Links

Badges and links point at the initial 0.1.0 release; there are no prior published versions.

License

MIT © Kristian dF Kollsgård

Download files

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

Source Distribution

kglite_datasets-0.1.11.tar.gz (239.2 kB view details)

Uploaded Source

Built Distributions

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

kglite_datasets-0.1.11-cp310-abi3-win_amd64.whl (1.9 MB view details)

Uploaded CPython 3.10+Windows x86-64

kglite_datasets-0.1.11-cp310-abi3-manylinux_2_28_aarch64.whl (1.9 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.28+ ARM64

kglite_datasets-0.1.11-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (2.0 MB view details)

Uploaded CPython 3.10+manylinux: glibc 2.17+ x86-64

kglite_datasets-0.1.11-cp310-abi3-macosx_11_0_arm64.whl (1.8 MB view details)

Uploaded CPython 3.10+macOS 11.0+ ARM64

kglite_datasets-0.1.11-cp310-abi3-macosx_10_12_x86_64.whl (1.9 MB view details)

Uploaded CPython 3.10+macOS 10.12+ x86-64

File details

Details for the file kglite_datasets-0.1.11.tar.gz.

File metadata

  • Download URL: kglite_datasets-0.1.11.tar.gz
  • Upload date:
  • Size: 239.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for kglite_datasets-0.1.11.tar.gz
Algorithm Hash digest
SHA256 c7252810d545938de7292c136087e54a57b65dbc3a4b41b776a2d31838f3c5db
MD5 defe4b8c863a5dca1b4a93118dde2916
BLAKE2b-256 40e36295b438b2a6f0a250c79f962f2bba94a3469c362983c6ed2038a9898410

See more details on using hashes here.

Provenance

The following attestation bundles were made for kglite_datasets-0.1.11.tar.gz:

Publisher: release.yml on kkollsga/kglite-datasets

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kglite_datasets-0.1.11-cp310-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for kglite_datasets-0.1.11-cp310-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 774427ccd1677953fb8085f6d05df597321205beaa0bd1ad4f97902655266f55
MD5 012c70e784c4e1c9b36e266fc6859ab6
BLAKE2b-256 3022586ea4717da4ebaff1f9a6e40d591117dae3103764423ea3d52dbe34c2f0

See more details on using hashes here.

Provenance

The following attestation bundles were made for kglite_datasets-0.1.11-cp310-abi3-win_amd64.whl:

Publisher: release.yml on kkollsga/kglite-datasets

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kglite_datasets-0.1.11-cp310-abi3-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for kglite_datasets-0.1.11-cp310-abi3-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 5bb8a4a085942a46d576261eb1bd13e6e677b33253f1ead3f2a0eab34057570b
MD5 641784d5f496224063953d2674f5a632
BLAKE2b-256 b931d96cd1ed7a056b137c817c620b6e97b1905333cbfc878c94e629f2bae043

See more details on using hashes here.

Provenance

The following attestation bundles were made for kglite_datasets-0.1.11-cp310-abi3-manylinux_2_28_aarch64.whl:

Publisher: release.yml on kkollsga/kglite-datasets

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kglite_datasets-0.1.11-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for kglite_datasets-0.1.11-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 1f56e42d51601ddc2d9da842756a5de583abd9eb1b927d94210ce76c39092be3
MD5 8823b156ce4037ffaccb6435704d2ed2
BLAKE2b-256 8c14aa91e53919428ba37797a6f3b0089d4fb1381056d6e7a298637b2a73c7ba

See more details on using hashes here.

Provenance

The following attestation bundles were made for kglite_datasets-0.1.11-cp310-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on kkollsga/kglite-datasets

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kglite_datasets-0.1.11-cp310-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for kglite_datasets-0.1.11-cp310-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ad5162af01e2f8eac73d90cb813a8c8331319980300822795f0bbc3dc208e220
MD5 5d8076708d2a19ca6bf9f7cc6eaf98f5
BLAKE2b-256 9acd8131de1655fbc997e03cb07f0bf27ef0a6e4ef8ff8934cc1146d7e57903d

See more details on using hashes here.

Provenance

The following attestation bundles were made for kglite_datasets-0.1.11-cp310-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on kkollsga/kglite-datasets

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kglite_datasets-0.1.11-cp310-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for kglite_datasets-0.1.11-cp310-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 1124655d9a86d276916e4c367fbfb4620e3f43ee68098306a65584420a8ec934
MD5 ce55f195207659f152c52103d9a698cc
BLAKE2b-256 0941303360985443b4e3abc8c330055cfcd37bfb13e755e73257cd3c0ea89113

See more details on using hashes here.

Provenance

The following attestation bundles were made for kglite_datasets-0.1.11-cp310-abi3-macosx_10_12_x86_64.whl:

Publisher: release.yml on kkollsga/kglite-datasets

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

0.1.15

6 files

0.1.14

6 files

0.1.13

6 files

0.1.12

6 files

This release

0.1.11 This release

6 files

0.1.10

6 files

0.1.9

6 files

0.1.8

6 files

0.1.7

6 files

0.1.6

6 files

0.1.5

6 files

0.1.4

6 files

0.1.3

6 files

0.1.2

6 files

0.1.1

6 files

0.1.0

5 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page