Python SDK for EigenLake Cloud
Project description
EigenLake Python Client
Python SDK for EigenLake Cloud.
Install
pip install eigenlake
Quickstart
import eigenlake
from eigenlake import schema as s
with eigenlake.connect(
url="https://api.eigenlake.dev",
api_key="<sk_sbx_your_api_key_here>",
) as client:
schema, index_options = (
s.SchemaBuilder(additional_properties=False)
.add("document_id", s.string(required=True, filterable=True))
.add("text", s.string(filterable=False))
.add("created_at", s.datetime(filterable=True))
.build()
)
idx = client.indexes.create_or_get(
namespace="demo-namespace",
index="demo-index",
dimensions=128,
schema=schema,
index_options=index_options,
)
record_id = idx.records.add(
properties={"document_id": "doc-1", "text": "hello"},
vector=[0.1] * 128,
)
result = idx.search.nearest(
vector=[0.1] * 128,
limit=3,
)
print(record_id, result)
Agent Query
import eigenlake
with eigenlake.connect(url="https://api.eigenlake.dev", api_key="<sk_sbx_your_api_key_here>") as client:
idx = client.indexes.open(namespace="demo-automotive", index="automotive-fault-clustering")
result = idx.agent.query("show me recent battery failures")
print(result["filter"])
Docs
- Documentation source:
docs/ - Docs site config:
mkdocs.yml
pip install -e ".[docs]"
mkdocs serve
Docs will be available at http://127.0.0.1:8000.
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
eigenlake-0.2.3.tar.gz
(13.7 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file eigenlake-0.2.3.tar.gz.
File metadata
- Download URL: eigenlake-0.2.3.tar.gz
- Upload date:
- Size: 13.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fc4578a38f74415ad8e60c2a3372ffda647e46833141a182078027e0f4063df6
|
|
| MD5 |
7460f69c80fbdcda5e210f75c54032c8
|
|
| BLAKE2b-256 |
642603d7e5650b5944328e529ed78132c219e87400cbd9699203159a752ae34c
|
File details
Details for the file eigenlake-0.2.3-py3-none-any.whl.
File metadata
- Download URL: eigenlake-0.2.3-py3-none-any.whl
- Upload date:
- Size: 8.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ca4dc25445a6e3ba068f7f761c305718c06e452555e27a0c81837860a489949d
|
|
| MD5 |
3f6ca543a62019d9c607bdc429caf935
|
|
| BLAKE2b-256 |
23bc27d2f792979b9bd4111764940b96b6179a29901d3830c2d296828efb9a0a
|