Installation
Python Version
Use Python 3.10 through 3.13 (>=3.10,<3.14). Python 3.14 and free-threaded
builds are not declared supported. Optional backends have their own platform and
wheel requirements; plyvel may need a native LevelDB development package
when built from source. In a notebook, install into the interpreter used by its
kernel, not an unrelated shell environment (Notebook Usage).
Choose only the features you use
Task |
Requirement |
Start here |
|---|---|---|
Array sampling, standalone reasoning or offline visualization |
|
Sampling for graph learning, Facts, Rules, and Explanations, Explore graphs and reasoning offline |
Store/query a graph with JSON or Pickle |
|
|
Add a binary payload codec |
Add |
|
Load Arrow or Polars tables |
Add |
|
Exchange NetworkX or static GEXF |
Add |
|
Import the supported offline RDF ontology fragment |
|
Extras are additive: gestaltdb[lmdb,msgpack] selects storage and codec
independently. backends and serializers are convenience bundles, not
required for every application. all additionally installs external benchmark
clients; it is not the default runtime recommendation and does not include the
separate rdf extra. Visualization rendering
requires neither the docs extra nor Node/npm; Jupyter itself is installed
separately if you want notebook display.
Install With uv
In your application project:
1uv add "gestaltdb[lmdb]"
For editable use of a local checkout:
1uv add --editable /path/to/gestaltdb
Install optional features only when you need them:
1uv add "/path/to/gestaltdb[leveldb,msgpack]"
2uv add "/path/to/gestaltdb[lmdb,protobuf]"
3uv add "/path/to/gestaltdb[backends,serializers]"
4uv add "/path/to/gestaltdb[fast-ingest]"
Install With pip
1python -m venv .venv
2. .venv/bin/activate
3python -m pip install --upgrade pip
4python -m pip install "gestaltdb[lmdb]"
The base package includes the Pickle and JSON serializers but no embedded KV backend. Install backend and serializer extras independently; extras are additive, so no backend/serializer combination extras are needed.
Array-native sampling from SamplerSnapshot.from_edge_arrays needs only the
base package (including NumPy), not a KV backend or a separate sampling extra.
For the database-backed filtering/sampling examples, install gestaltdb[lmdb].
See Graph sampling API and policy reference for a backend-free quickstart and
Property-Graph Filtering and Indexes for building a snapshot from an embedded database.
For a checkout, combine optional extras as follows:
1python -m pip install ".[leveldb,msgpack]"
2python -m pip install ".[lmdb,protobuf]"
3python -m pip install ".[rocksdb]"
4python -m pip install ".[backends,serializers]"
5python -m pip install ".[fast-ingest]"
6python -m pip install ".[msgpack,protobuf]"
7python -m pip install ".[all]"
GraphDB.create retains backend="pyrex" as its compatibility default,
so parameterless creation requires gestaltdb[rocksdb]. GestaltDB never
silently substitutes another backend; pass an installed backend explicitly.
Install From GitHub
1python -m pip install "gestaltdb[lmdb] @ git+https://github.com/mylonasc/gestaltdb.git"
This installs source, not the published wheel. Pin a reviewed commit when you need reproducible source installs; choose the extras required by your application.
Notebook Kernel Example
Use a Python version supported by your selected backend and register it with Jupyter:
1python -m pip install "gestaltdb[lmdb]" ipykernel
2python -m ipykernel install --user --name gestaltdb --display-name "GestaltDB"
Optional Dependencies
lmdbLMDB key-value backend.
leveldbLevelDB key-value backend through
plyvel.rocksdbRocksDB key-value backend through
pyrex-rocksdb>=0.7.1.backendsConvenience bundle containing the LMDB, LevelDB, and RocksDB backends.
arrowArrow array support through
pyarrowfor columnar ingestion helpers.polarsPolars DataFrame support for columnar ingestion helpers.
fast-ingestConvenience extra for
pyarrow,polars, andpyrex-rocksdb>=0.7.1.msgpackMessagePack serializer.
protobufProtobuf Struct serializer for JSON-like dictionaries.
serializersConvenience bundle containing MessagePack and Protobuf. Pickle and JSON need no extra.
bloomBloom-filter support through
pybloom-live.networkxMaterialized graph exchange and static GEXF loading; includes NetworkX and
defusedxml. Not automatic NetworkX algorithm dispatch over live storage.rdfOffline import of the selected RDF ontology fragment through RDFLib.
docsSphinx documentation build dependencies.
Pre-Release Installs
Pre-releases use standard Python version identifiers. Pip normally selects
stable releases; use --pre to allow available pre-release builds explicitly:
1python -m pip install --pre "gestaltdb[fast-ingest]"