Skip to Content

How do I move my historical traces from Traceloop to Rius?

Rius does not import historical traces from Traceloop, so your existing traces stay in Traceloop and Rius starts from the first span you send it. You keep your OpenLLMetry instrumentation and change only its export settings, so new traces flow to Rius with their structure intact. Running both backends side by side lets you build up history in Rius while you still read the old traces in Traceloop.

How it works

Traceloop’s SDK is OpenLLMetry, which is plain OpenTelemetry and exports OTLP to whatever endpoint you give it. Moving to Rius is a configuration change. Nothing is copied from Traceloop, so the history you already have stays where it is, and Rius builds its own history from new spans. This is how each Traceloop concept arrives in Rius:

  • Traces and decorators. @workflow and @task spans appear as generic steps, @agent spans as agents and @tool spans as tools, each named after the decorated function.
  • LLM calls. They appear as generations with the model, token counts and cost. Rius computes cost on its side as a list-price estimate in US dollars, so you send no cost value.
  • Conversations. @conversation, set_conversation_id() and withConversation() write gen_ai.conversation.id, which Rius reads as the session.
  • Association properties. Properties such as user_id and chat_id arrive as span attributes under traceloop.association.properties.*. You can inspect and filter on them, but Rius does not treat them as users or sessions.
  • Project and environment. Rius groups traces by agent, named by service.name. Give each environment, such as production and staging, its own workspace and API key.

The Migrate from Traceloop guide covers every mapping in full, and Migrate to Rius compares the migration paths for all supported tools.

The following Traceloop features have no counterpart in Rius:

  • Monitors, evaluators and guardrails.
  • The prompt registry and playgrounds.
  • Datasets and experiments.
  • User feedback and annotation tasks.
  • Traceloop Hub, because Rius has no gateway or proxy.
  • OTLP metrics, because Rius ingests traces only.
  • Self-hosting, because Rius is a managed service only.

Set it up

  1. Create a Rius account and mint an API key. Keys start with ri_. A new organization starts on a free trial of 30 days or 500,000 spans, whichever comes first, with no card.

  2. Decide whether to keep Traceloop running while Rius collects history. Do this before you re-point anything. In Python, re-pointing to Rius turns off Traceloop’s platform client, so get_prompt(), guardrails, feedback, datasets and experiments stop working. If you use any of them, point OpenLLMetry at an OpenTelemetry Collector (set TRACELOOP_BASE_URL to the Collector’s OTLP/HTTP port, 4318, with no headers) and export to both backends. This is also the setup to use if you want to compare the two backends on the same traffic:

    receivers: otlp: protocols: http: endpoint: 0.0.0.0:4318 processors: batch: exporters: otlphttp/traceloop: endpoint: https://api.traceloop.com headers: authorization: Bearer ${env:TRACELOOP_API_KEY} otlphttp/rius: endpoint: https://ingest.eu.console.rius-glassflow.com encoding: proto compression: gzip headers: authorization: Bearer ${env:RIUS_API_KEY} service: pipelines: traces: receivers: [otlp] processors: [batch] exporters: [otlphttp/traceloop, otlphttp/rius]
  3. Otherwise, re-point OpenLLMetry at Rius directly. Remove TRACELOOP_API_KEY from your deployment, because the Rius header replaces it:

    # Before: Traceloop export TRACELOOP_API_KEY="<your Traceloop API key>" # After: Rius export TRACELOOP_BASE_URL="https://ingest.eu.console.rius-glassflow.com" export TRACELOOP_HEADERS="Authorization=Bearer%20<your Rius API key>" export TRACELOOP_METRICS_ENABLED="false" # Python SDK only, see below
  4. Check three details. In Python, leftover TRACELOOP_BASE_URL and TRACELOOP_HEADERS values override the arguments to Traceloop.init(), so remove old ones. The Python SDK also exports metrics to the same base URL, and Rius rejects them with a 404 that is logged on every export, so keep TRACELOOP_METRICS_ENABLED set to false. Use an http or https base URL, because Rius accepts OTLP over HTTP only.

  5. If you want Rius to show users, set user.id yourself, because OpenLLMetry does not. Set it inside your outermost decorated function, since Rius lists each trace under the user of its root span:

    from opentelemetry import trace trace.get_current_span().set_attribute("user.id", user_id)
  6. Send one traced request and check the trace tree, the model and token counts, the cost, and the shared session for traces with a conversation id. If you fanned out, compare the two backends for a few days, then remove the Traceloop exporter and revoke the Traceloop API key once nothing sends to it.

What you get

  • Every new trace in Rius from the moment you re-point the exporter, with your decorators, models, tokens and cost intact, and no code changes beyond settings.
  • Sessions from your existing conversation ids, plus users once you set user.id.
  • A period where Traceloop and Rius see identical spans, so you can compare trace counts, token totals and cost before you cut over.
  • A clear split: old traces remain readable in Traceloop, and new traces accumulate in Rius.

When something else fits

  • If you need to keep querying your old traces, keep your Traceloop account for as long as you need that history, because nothing is exported from it to Rius.
  • If you depend on evaluators, guardrails, the prompt registry, datasets or experiments, keep those workflows in Traceloop and use the Collector fan-out to send traces to both backends.
  • If you would rather adopt Rius-native session and user scopes, you can swap OpenLLMetry for the Rius SDK later, as the Traceloop migration guide describes.

Still stuck? Get help

Last updated on