Skip to main content

LogNerve Python SDK

Small Python SDK for tracing agentic and LLM applications with LogNerve.

pip install lognerve-py
import lognerve

lognerve.initialize(
    api_key="lnv_sk_example",
    domain="api.lognerve.ai",
    project_name="agent-examples",
    service_name="vanilla-tool-loop",
    exporter="otlp-http",
    redact_pii=True,
)

@lognerve.observe(name="workflow", type="agent")
def run_workflow(goal: str) -> str:
    return "done"

run_workflow("test tracing")

The root package intentionally exposes only lognerve.initialize, lognerve.observe, lognerve.usingAttributes, lognerve.flush, and lognerve.shutdown.

When neither otlp_endpoint nor domain is set, the SDK defaults to https://lognerve.ai/api/v1/traces. Use domain to customize (e.g. https://eu.lognerve.ai/api/v1/traces). Explicit otlp_endpoint always takes precedence.

Set LOGNERVE_REDACT_PII=true or pass redact_pii=True to redact common PII locally before span export. Default local redaction covers emails, phone numbers, credit cards, SSNs, IPv4 addresses, API keys, and bearer tokens. You can customize it with redact_pii={"entities": ["email", "api_key"], "patterns": [{"pattern": "customer-[0-9]+"}]}.

SOC 2, encryption at rest, server-side intelligent PII detection, and on-prem alerting are backend/product controls. The SDK control implemented here is local regex redaction before export.

When api_key or LOGNERVE_API_KEY is set, OTLP requests include Authorization: Bearer <api_key>. That generated authorization header takes precedence over otlp_headers={"Authorization": ...} or LOGNERVE_OTLP_HEADERS; custom non-authorization headers still pass through.

Metadata

Release files for lognerve-py 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for lognerve-py 0.1.3
File Size Uploaded Provenance Actions
lognerve_py-0.1.3.tar.gz 15.0 kB Without provenance Details for lognerve_py-0.1.3.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for lognerve-py 0.1.3
File Interpreter ABI Platform Actions
lognerve_py-0.1.3-py3-none-any.whl Python 3 none any Details for lognerve_py-0.1.3-py3-none-any.whl

Total release size: 34.1 kB

Release files / lognerve_py-0.1.3.tar.gz

Download URL lognerve_py-0.1.3.tar.gz
Size 15.0 kB
Tags Source
SHA-256 checksum
How to use checksums
3cf511937e3a237c0ee91d8352a3df3b4fb60c02589c2964851bb303a3f990be
BLAKE2b-256 checksum
How to use checksums
734ec67978c7ca27cda851db6169d873fff194c8aec9efec35eff0c039d5c915
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.6

Release files / lognerve_py-0.1.3-py3-none-any.whl

Download URL lognerve_py-0.1.3-py3-none-any.whl
Size 19.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
a9f189c03971bafa8900dc32d2edad660e22197518b0578a99bb3123e5b0d825
BLAKE2b-256 checksum
How to use checksums
9c97c542dae861d2d2895e1112de868d8f191d75019fac5b12ef8d3b3862994c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.6

Security for lognerve-py 0.1.3

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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