Skip to main content

Official Python SDK for the Prometa Agentic Lifecycle Intelligence Platform

Project description

prometa-sdk (Python)

Official Python SDK for the Prometa Agentic Lifecycle Intelligence Platform.

Wraps OpenTelemetry GenAI semantic conventions with @prometa decorators that automatically emit lifecycle metadata (solution_id, stage, agent) to your Prometa instance via OTLP/JSON.

Install

pip install prometa-sdk

Quick start

import asyncio
from prometa import Prometa

prometa = Prometa(
    endpoint="https://prometa.example.com/api/v2/otlp/v1/traces",
    api_key="prm_live_...",
    solution_id="sol_abc123",
    agent_name="customer-support",
    stage="production",
)

@prometa.workflow(name="handle-ticket")
async def handle_ticket(ticket_id: str) -> str:
    @prometa.agent(name="classifier")
    async def classify() -> str:
        return "billing"

    @prometa.tool(name="kb-search")
    async def kb_search(q: str) -> list[str]:
        return ["doc1", "doc2"]

    category = await classify()
    results = await kb_search(category)
    return f"resolved {ticket_id} via {results}"

asyncio.run(handle_ticket("T-1234"))
prometa.flush()

What gets captured

Each decorated function emits a span with:

  • prometa.kindworkflow | agent | tool | task
  • prometa.solution_id, prometa.stage
  • gen_ai.agent.name, gen_ai.agent.id
  • Parent/child relationships across async/sync calls
  • Errors → span status error plus error.message

Configuration

Param Env var Default
endpoint required
api_key PROMETA_API_KEY none
solution_id none
agent_name "prometa-agent"
stage "development"
flush_interval_seconds 2.0

License

Apache-2.0

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

prometa_sdk-0.1.0.tar.gz (15.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

prometa_sdk-0.1.0-py3-none-any.whl (20.3 kB view details)

Uploaded Python 3

File details

Details for the file prometa_sdk-0.1.0.tar.gz.

File metadata

  • Download URL: prometa_sdk-0.1.0.tar.gz
  • Upload date:
  • Size: 15.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for prometa_sdk-0.1.0.tar.gz
Algorithm Hash digest
SHA256 9d2304c76a6c14f9a3739d55048d8ee3c229a80015de6ab7669aa5b43a60cad8
MD5 616e3a73227324e6a4415e5acc5287ee
BLAKE2b-256 206d038334747fdf323ab911c6185fbfe241d61a62bba059c295f6ffdda67b56

See more details on using hashes here.

Provenance

The following attestation bundles were made for prometa_sdk-0.1.0.tar.gz:

Publisher: sdk-release.yml on caglarsubas/agent-hook-v2

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file prometa_sdk-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: prometa_sdk-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 20.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for prometa_sdk-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 b19f6e1f4132c99681ede934f5ab8a5a1ed57fb5e4d28a21aa7c4976b62cf354
MD5 d276cccbdb8e43fcaf3b8af6763f2888
BLAKE2b-256 3c43234f2ed582457e49772eed253dade79197afbd94b9f2eb1780e11eef871c

See more details on using hashes here.

Provenance

The following attestation bundles were made for prometa_sdk-0.1.0-py3-none-any.whl:

Publisher: sdk-release.yml on caglarsubas/agent-hook-v2

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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