OpenTelemetry tracing SDK for Helios observability
Project description
Helios Observatory Python SDK
helios-observatory-sdk adds OpenTelemetry tracing to Python applications and
exports authenticated OTLP/HTTP protobuf spans to Helios. It supports manual
agent, retrieval, tool, LLM, and workflow spans plus optional OpenAI
auto-instrumentation.
The distribution name is helios-observatory-sdk. The Python import remains
helios_sdk.
Helios is currently a production-capable hosted beta. It is not a generally available or SLA-backed service.
Installation
Install only the dependency-light legacy client:
pip install helios-observatory-sdk
Install the recommended OpenTelemetry runtime:
pip install "helios-observatory-sdk[otel]"
Install the runtime with OpenAI auto-instrumentation:
pip install "helios-observatory-sdk[openai]"
The combined and all-inclusive forms are also supported:
pip install "helios-observatory-sdk[otel,openai]"
pip install "helios-observatory-sdk[all]"
The openai extra includes the OpenTelemetry runtime it needs. Development and
test dependencies are not installed by any runtime extra.
OpenTelemetry quick start
Create a project API key in Helios with traces:ingest access, then inject it
through your local secret-management mechanism. Never commit a hel_proj_*
key, print it, or place it in browser code.
import os
from helios_sdk import Helios
helios = Helios.configure(
api_key=os.environ["HELIOS_API_KEY"],
service_name="my-agent",
endpoint=os.environ.get("HELIOS_ENDPOINT", "http://localhost:8000"),
environment="development",
)
with helios.agent("answer-question"):
with helios.retrieval("knowledge.search") as span:
span.set_attribute("retrieval.top_k", 5)
with helios.tool("policy.lookup") as span:
span.set_attribute("tool.name", "policy-engine")
flush_completed = helios.force_flush()
helios.shutdown()
if not flush_completed:
raise SystemExit(
"Export did not complete locally. Review exporter errors before retrying."
)
print(
"Export completed locally. Check Helios to confirm trace arrival. "
"Exporter errors are authoritative."
)
force_flush() confirms that the local OpenTelemetry processor completed its
work. It does not prove that the backend accepted the trace because the
OpenTelemetry batch processor does not propagate the exporter result. Verify
trace arrival in Helios before claiming successful delivery.
An invalid or revoked project key remains rejected by Helios with HTTP 401. The SDK does not retry with another credential or convert that rejection into success. OpenTelemetry exporter errors are authoritative.
Endpoint and environment configuration
Explicit arguments take precedence over Helios environment variables, which take precedence over recognized OpenTelemetry variables and defaults.
| Variable | Purpose | Default |
|---|---|---|
HELIOS_API_KEY |
Project API key used as the bearer credential | Required |
HELIOS_ENDPOINT |
Helios backend base URL | http://localhost:8000 |
HELIOS_SERVICE_NAME |
OpenTelemetry service.name |
OTEL_SERVICE_NAME, then required |
HELIOS_ENVIRONMENT |
Deployment environment resource attribute | Unset |
HELIOS_CAPTURE_CONTENT |
Opt in to prompt and response capture | false |
The SDK appends /v1/otlp/traces to a base endpoint. A full endpoint already
ending in that canonical path is accepted without duplicating it.
OpenAI instrumentation
Install the openai extra before enabling instrumentation:
import os
from helios_sdk import Helios
from openai import OpenAI
helios = Helios.configure(
api_key=os.environ["HELIOS_API_KEY"],
service_name="openai-agent",
endpoint=os.environ.get("HELIOS_ENDPOINT", "http://localhost:8000"),
)
helios.instrument_openai()
client = OpenAI()
with helios.agent("openai-agent"):
client.chat.completions.create(
model="gpt-4o-mini",
messages=[{"role": "user", "content": "Hello"}],
)
helios.force_flush()
helios.shutdown()
Prompt and completion content capture is disabled by default. Enabling
HELIOS_CAPTURE_CONTENT=true or passing capture_content=True may transmit
sensitive content. You are responsible for consent, redaction, and applicable
data-handling requirements.
Decorators and manual spans
Helios.trace() decorates synchronous or asynchronous workflow functions:
@helios.trace("answer-question")
def answer_question(question: str) -> str:
with helios.tool("policy.lookup"):
return "answer"
The runtime also exposes agent, retrieval, tool, llm, and general
span context managers. Raw OpenTelemetry access remains available through
helios.tracer.
Legacy client
The base installation retains the dependency-light HeliosClient API for the
legacy /v1/traces JSON endpoint:
from helios_sdk import HeliosClient
client = HeliosClient(
base_url="http://localhost:8000",
project_slug="example",
project_name="Example",
environment="development",
)
trace = client.create_trace(
user_query="How do I rotate a key?",
app_name="support-agent",
model="example-model",
)
with trace.span("policy.lookup", span_type="tool") as span:
span.set_output("Rotation guidance retrieved")
result = client.submit_trace(trace)
print(result["trace_id"])
HeliosConnectionError reports an unreachable backend.
HeliosAPIError reports a non-success HTTP response.
Version and compatibility
The installed distribution exposes its metadata version as
helios_sdk.__version__. Version 0.2.0 supports Python 3.10 through 3.13.
Artifact installation and SDK tests cover each advertised Python version in
ordinary CI.
The package is pure Python. OpenAI auto-instrumentation uses the upstream
opentelemetry-instrumentation-openai-v2 package and does not imply affiliation
with OpenAI or OpenTelemetry.
Project links
- Repository: https://github.com/Roshan3580/Helios
- Issues: https://github.com/Roshan3580/Helios/issues
- Documentation: https://github.com/Roshan3580/Helios/tree/main/docs
- Hosted beta: https://helios-staging-tau.vercel.app
- Python SDK example: https://github.com/Roshan3580/Helios/tree/main/examples/python_sdk_quickstart
License
Copyright 2026 Roshan Raj.
Helios Observatory Python SDK is licensed under the Apache License, Version 2.0. See https://github.com/Roshan3580/Helios/blob/main/LICENSE.
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 helios_observatory_sdk-0.2.0.tar.gz.
File metadata
- Download URL: helios_observatory_sdk-0.2.0.tar.gz
- Upload date:
- Size: 17.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
60cc5c261a1024714edde7f74a2aa1da5ec8b95293d40f764592fb22ab6f9e20
|
|
| MD5 |
c46cb526603749a8fc1df8561e37fa04
|
|
| BLAKE2b-256 |
ba813af7c8bc281c9bdd6e0e99dbc70789cd10caa3fa325c9a97231024364483
|
Provenance
The following attestation bundles were made for helios_observatory_sdk-0.2.0.tar.gz:
Publisher:
publish-python-sdk.yml on Roshan3580/Helios
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
helios_observatory_sdk-0.2.0.tar.gz -
Subject digest:
60cc5c261a1024714edde7f74a2aa1da5ec8b95293d40f764592fb22ab6f9e20 - Sigstore transparency entry: 2333679182
- Sigstore integration time:
-
Permalink:
Roshan3580/Helios@2bf93f49334d334bdfcb66d5db3e9a15d24a8c8d -
Branch / Tag:
refs/tags/python-sdk-v0.2.0 - Owner: https://github.com/Roshan3580
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-python-sdk.yml@2bf93f49334d334bdfcb66d5db3e9a15d24a8c8d -
Trigger Event:
release
-
Statement type:
File details
Details for the file helios_observatory_sdk-0.2.0-py3-none-any.whl.
File metadata
- Download URL: helios_observatory_sdk-0.2.0-py3-none-any.whl
- Upload date:
- Size: 19.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
86b99946a0036ce7215ef574496f044c767d62a8e8036bc03b52986a3b3a93e4
|
|
| MD5 |
f128177b15963d770edaf584fcd91fb5
|
|
| BLAKE2b-256 |
3cc503e878159a57418bd15a9ac664c9bfc94ee96ff5b0e0f5715bca4f3bc144
|
Provenance
The following attestation bundles were made for helios_observatory_sdk-0.2.0-py3-none-any.whl:
Publisher:
publish-python-sdk.yml on Roshan3580/Helios
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
helios_observatory_sdk-0.2.0-py3-none-any.whl -
Subject digest:
86b99946a0036ce7215ef574496f044c767d62a8e8036bc03b52986a3b3a93e4 - Sigstore transparency entry: 2333679342
- Sigstore integration time:
-
Permalink:
Roshan3580/Helios@2bf93f49334d334bdfcb66d5db3e9a15d24a8c8d -
Branch / Tag:
refs/tags/python-sdk-v0.2.0 - Owner: https://github.com/Roshan3580
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
publish-python-sdk.yml@2bf93f49334d334bdfcb66d5db3e9a15d24a8c8d -
Trigger Event:
release
-
Statement type: