Skip to main content

Radiant SDK

Project description

Radiant SDK

Radiant SDK is a Python package that simplifies the process of adding OpenTelemetry instrumentation to your applications, with a focus on integrating with Radiant's observability platform.

Features

  • Easy setup of OpenTelemetry tracing with Radiant
  • Automatic instrumentation of OpenAI API calls
  • Simple decorator for annotating functions with tracing

Installation

The Radiant SDK uses Poetry for dependency management and packaging. To install the SDK and its dependencies:

pip install radiant-sdk

Usage

Basic Setup

from radiant import Instrumentor

# Initialize the instrumentor with your Radiant endpoint
Instrumentor.start("https://your-radiant-endpoint.com/api/v0/ingest/submit/otel/{project_name}",", api_key="")

Error Handling

The SDK will raise a RadiantConfigurationError if the Radiant endpoint is not provided:

from radiant import Instrumentor
try:
    Instrumentor.start("https://your-radiant-endpoint.com/api/v0/ingest/submit/otel/{YOUR_APP_NAME}", "<YOUR_API_KEY>")
except RadiantConfigurationError as e:
    print(f"Failed to initialize Radiant: {e}")

If you already have a TracerProvider (`opentelemetry.sdk.trace.TracerProvider()), you can just pass that into the configuration as well.

tracer_provider = opentelemetry.sdk.trace.TracerProvider()
try:
    Instrumentor.start("http://your-radiant-endpoint.com/api/v0/ingest/submit/otel/{YOUR_APP_NAME}", "<YOUR_API_KEY>" tracer_provider)
except RadiantConfigurationError as e:
    print(f"Failed to initialize Radiant: {e}")

Contributing

Reach out to support@radiantai.com if you want to provide feedback or suggest changes.

License

This project is licensed under the MIT License.

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

radiant_sdk-0.140.0.tar.gz (2.2 kB view details)

Uploaded Source

Built Distribution

radiant_sdk-0.140.0-py3-none-any.whl (2.7 kB view details)

Uploaded Python 3

File details

Details for the file radiant_sdk-0.140.0.tar.gz.

File metadata

  • Download URL: radiant_sdk-0.140.0.tar.gz
  • Upload date:
  • Size: 2.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.12.4 Linux/6.5.0-1025-azure

File hashes

Hashes for radiant_sdk-0.140.0.tar.gz
Algorithm Hash digest
SHA256 32cab5e23e682c0214d3d05d88fd107b4ee1f67abf9c06ed7b3dea24c2d07e67
MD5 f4f7d59066644bbd3ec86bef00c04e6d
BLAKE2b-256 9615fed7ea6c2bdda125c72319be60e79910e5e988830e44df29367d9f5ac493

See more details on using hashes here.

File details

Details for the file radiant_sdk-0.140.0-py3-none-any.whl.

File metadata

  • Download URL: radiant_sdk-0.140.0-py3-none-any.whl
  • Upload date:
  • Size: 2.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.12.4 Linux/6.5.0-1025-azure

File hashes

Hashes for radiant_sdk-0.140.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7fb96d50b94a1cb5ec41ffac034219c2f6222f5daf3b9c95ca8df708040b6109
MD5 7d70546ce88ec9314c3cb0ff02118301
BLAKE2b-256 ed608bcc7818fb2605d9b1900aaabd1384543c4a6c128cbb64747daadb300506

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page