One-line LLM observability for Python — a thin wrapper over OpenLLMetry that exports OTLP traces to Enlight Chakra.
Project description
enlight-chakra-observability
One-line LLM observability for Python. A thin, vendor-neutral wrapper over
OpenLLMetry (Traceloop, Apache-2.0) that
exports OTLP traces to your Enlight Chakra deployment. The single lk_… ingest key (copied from
the Enlight Chakra Instrument app page) encodes the OTLP endpoint and auth — no base64,
no endpoint URLs, no "which key goes where".
Under the hood it's OpenLLMetry → plain OTLP. You are never locked in.
Naming: the distribution is
enlight-chakra-observabilityand the import name isenlight_chakra_observability. (The earlierenlight-sdk/import enlight_chakracollided with an unrelated PyPI package, Holovizlumen.import enlight_chakrastill works as a deprecated alias when this package is installed.)
Install
# From source (works today — not yet on public PyPI):
pip install "git+https://github.com/esds/lumen.git#subdirectory=sdk/python"
# or, from a local checkout: pip install ./sdk/python
# or, from the built wheel: pip install enlight_chakra_observability-0.1.0-py3-none-any.whl
# Once published to PyPI / your private index:
pip install enlight-chakra-observability
Use
import enlight_chakra_observability as lumen
enlight_chakra.init(api_key="lk_...", app_name="checkout-api") # once, at startup
enlight_chakra.identify(user_id="u_42", session_id="s_7") # optional, per request
# your normal OpenAI / Anthropic / LangChain / LlamaIndex code is now auto-traced
For short scripts/demos, flush each span immediately:
enlight_chakra.init(api_key="lk_...", disable_batch=True)
To make traces visible in a multi-tenant Enlight Chakra, stamp your tenant as a resource
attribute (pass-through to Traceloop), or set OTEL_RESOURCE_ATTRIBUTES=tenant.id=...:
enlight_chakra.init(api_key="lk_...", resource_attributes={"tenant.id": "tnt_shiftx"})
What you get
Every request becomes a nested span tree in Enlight Chakra — retrieval, prompt assembly, the model call, tool calls, agent steps — grouped by user and session. See it under Span Explorer, RAG & Retrieval, Agents & Tools, and Sessions.
The lk_ key
lk_<base64url(endpoint|public_key|secret_key)>. It packs the OTLP endpoint and your
project's Basic-auth credentials into one token, so init() needs nothing else. It
contains a secret — treat it like any API key (env var / secrets manager; never commit).
Publishing
python -m build # → dist/enlight_chakra_observability-0.1.0-*.whl + .tar.gz
twine upload dist/* # public PyPI (or: twine upload -r <private-index> dist/*)
License
Apache-2.0.
Project details
Release history Release notifications | RSS feed
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
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 enlight_chakra_observability-0.1.0.tar.gz.
File metadata
- Download URL: enlight_chakra_observability-0.1.0.tar.gz
- Upload date:
- Size: 5.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.15 {"installer":{"name":"uv","version":"0.11.15","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":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
39fc7791e051ace6ea59bc9b9dfc897637758625b48419d107a93a2f05e16a5c
|
|
| MD5 |
da686e4b0bd63d9ff4ab75f118f1b83d
|
|
| BLAKE2b-256 |
97a38642ec8281beb666de10bc89c7eb43a6a16b355f106a8aebce2ea4a17c99
|
File details
Details for the file enlight_chakra_observability-0.1.0-py3-none-any.whl.
File metadata
- Download URL: enlight_chakra_observability-0.1.0-py3-none-any.whl
- Upload date:
- Size: 5.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: uv/0.11.15 {"installer":{"name":"uv","version":"0.11.15","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":null}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3cfe9f7879cd3d24b5fb2fb9fd72675eb0287fb118b3a3ff3371bb0303fe401b
|
|
| MD5 |
109b1122d7434564e4fecd6baabe96b6
|
|
| BLAKE2b-256 |
7af5708e6ab6c9515734a81e244502278900b158f0baf320859db91fdcc6d724
|