Connect Langfuse to Rig
Rig syncs the traces, scores, datasets and experiments from one Langfuse project, so you can join LLM behaviour to product and cost data in your warehouse. You connect with a public and secret key pair from that project.
Before you start
- You need access to the Langfuse project you want to sync. API keys belong to a single project, so add one connection per project.
- Know where your project lives. Langfuse cloud uses
https://cloud.langfuse.comfor the EU region andhttps://us.cloud.langfuse.comfor the US region. Self-hosted installs use their own address.
Step 1: Create a Langfuse API key pair
- Open your project in Langfuse and go to Project Settings.
- Open API Keys and click Create new API keys.
- Name the key, keep Full access, and click Create API key.
- Copy the public key (
pk-lf-...) and the secret key (sk-lf-...). Langfuse shows the secret key once, so store it before you close the dialog.
Step 2: Connect it in Rig
Adding a source needs a workspace owner, or a role with the Manage connections permission, on a workspace where you manage your own connections. If the Connectors tab says “Data ingestion for this workspace is managed by Rig”, ask an owner or Rig support to add the source.
- In Rig, open
Connections, choose theConnectorstab and go toSources & actions. - Search for Langfuse, open the card and click
Connect. - Langfuse public key (pk-lf-...): The public key you copied.
- Langfuse secret key (sk-lf-...): The secret key you copied.
- Langfuse host: Leave it as it is for the EU cloud. For the US cloud enter
https://us.cloud.langfuse.com. For a self-hosted install enter its address. - Click
Continue. Rig checks the credentials and lists the streams it can reach, so choose the ones you want and clickConnect. - The source then syncs on its schedule, which is nightly unless you change it. To load data straight away, click
Syncon its row;Testpulls a small sample first if you want to check the connection.
What Rig pulls in
Langfuse lands in its own langfuse schema in your warehouse:
- Traces: One row per trace, with its name, tags, release and session ID.
- Observations: Every span, generation and event inside a trace. Off by default, because it is the largest table. Turn it on when you need token and cost detail.
- Scores: Evaluation scores attached to traces and observations.
- Datasets and dataset items: Your evaluation datasets and the items in them.
- Experiments: Runs of a dataset against a prompt or model.
Rig reads the current Langfuse v4 API. It has no sessions table, but every trace and observation row carries a sessionId, so you can group by it.
Good to know
- A trace row is the root observation of the trace. Its
idis the observation ID, and the trace ID sits intraceId, which is the column to join on. - Langfuse truncates metadata values longer than 200 characters when it returns observations, so very long metadata arrives shortened.
- Add a separate connection for each Langfuse project, because each key pair opens only one.
- To disconnect Langfuse, click the bin icon on the source's row under
Sources & actions. Only whoever connected the source or a workspace owner can do this, and data already synced stays in the warehouse.
What people use this for
- Analyse token cost and LLM spend
- Track latency and error rates by feature
- Measure quality scores and experiment results
- Analyse trace volume and usage by feature