Skip to content

Add OTLP trace ingestion MVP#539

Draft
abidlabs wants to merge 1 commit into
mainfrom
plan-otel-span-receiver
Draft

Add OTLP trace ingestion MVP#539
abidlabs wants to merge 1 commit into
mainfrom
plan-otel-span-receiver

Conversation

@abidlabs
Copy link
Copy Markdown
Member

@abidlabs abidlabs commented Apr 27, 2026

image
  • add a minimal OTLP/HTTP protobuf receiver at /otel/v1/traces
  • route spans into Trackio projects/runs using trackio.project, trackio.run, service.name, or query params
  • convert incoming OTel/OpenInference spans into existing trackio.Trace log entries so the current Traces tab can display them
  • document exporter setup, including smolagents + OpenInference
  • add runnable examples for a manual OTLP span and a smolagents/OpenInference agent run

V1 scope

This follows the MLflow/Weave pattern of supporting standard OTel ingestion instead of framework-specific integrations. V1 is traces-only, protobuf-only, and stores converted spans through the existing metrics/logs path. A dedicated spans table, gRPC receiver, richer trace tree UI, and additional semantic convention mappings can follow separately.

Tests

  • python -m ruff check examples/otel-basic-mvp.py examples/otel-smolagents-integration.py trackio/otel.py trackio/server.py tests/unit/test_otel_ingest.py
  • python -m pytest tests/unit/test_otel_ingest.py
  • python -m pytest tests/unit/test_otel_ingest.py tests/unit/test_gradio_api_spaces.py tests/unit/test_sqlite_storage.py
  • started a local Trackio Starlette/uvicorn server, ran examples/otel-basic-mvp.py and examples/otel-smolagents-integration.py against /otel/v1/traces, and confirmed SQLite stored 1 basic trace plus 3 smolagents spans (FinalAnswerTool, Step 1, CodeAgent.run)

@gradio-pr-bot
Copy link
Copy Markdown
Contributor

gradio-pr-bot commented Apr 27, 2026

🪼 branch checks and previews

Name Status URL
🦄 Changes detected! Details

@gradio-pr-bot
Copy link
Copy Markdown
Contributor

🦄 change detected

This Pull Request includes changes to the following packages.

Package Version
trackio minor

  • Add OTLP trace ingestion MVP

‼️ Changeset not approved. Ensure the version bump is appropriate for all packages before approving.

  • Maintainers can approve the changeset by checking this checkbox.

Something isn't right?

  • Maintainers can change the version label to modify the version bump.
  • If the bot has failed to detect any changes, or if this pull request needs to update multiple packages to different versions or requires a more comprehensive changelog entry, maintainers can update the changelog file directly.

@HuggingFaceDocBuilderDev
Copy link
Copy Markdown

HuggingFaceDocBuilderDev commented Apr 27, 2026

🪼 branch checks and previews

Name Status URL
Spaces ready! Spaces preview

Install Trackio from this PR (includes built frontend)

pip install "https://huggingface.co/buckets/trackio/trackio-wheels/resolve/027a28339d1bad36ebff6ad996dafef9919a9d66/trackio-0.25.1-py3-none-any.whl"

@HuggingFaceDocBuilderDev
Copy link
Copy Markdown

The docs for this PR live here. All of your documentation changes will be reflected on that endpoint. The docs are available until 30 days after the last update.

@abidlabs abidlabs force-pushed the plan-otel-span-receiver branch 2 times, most recently from 06ec435 to 9f173f5 Compare April 27, 2026 17:59
@abidlabs abidlabs force-pushed the plan-otel-span-receiver branch from 9f173f5 to 027a283 Compare April 27, 2026 19:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants