docs/versioned_docs/version-1.9.0/Develop/integrations-openlayer.mdx
import Tabs from '@theme/Tabs'; import TabItem from '@theme/TabItem';
Openlayer is a testing and evaluation platform for LLM applications. It provides comprehensive observability, testing, and monitoring capabilities to help you ship high-quality AI systems with confidence.
You can configure Langflow to collect tracing data about your flow executions and automatically send the data to Openlayer for analysis, monitoring, and evaluation.
:::tip If you need a flow to test the Openlayer integration, see the Langflow quickstart. :::
Get your Openlayer API key from your Openlayer account.
Create an inference pipeline in Openlayer and copy the pipeline ID.
Set your Openlayer credentials as environment variables in the same environment where you run Langflow.
In the following examples, replace YOUR_API_KEY and YOUR_PIPELINE_ID with your actual Openlayer credentials.
These commands set the environment variables in a Linux or macOS terminal session:
export OPENLAYER_API_KEY="YOUR_API_KEY"
export OPENLAYER_INFERENCE_PIPELINE_ID="YOUR_PIPELINE_ID"
These commands set the environment variables in a Windows command prompt session:
set OPENLAYER_API_KEY=YOUR_API_KEY
set OPENLAYER_INFERENCE_PIPELINE_ID=YOUR_PIPELINE_ID
Start Langflow in the same environment where you set the Openlayer environment variables:
uv run langflow run
Run a flow in Langflow.
Langflow automatically collects and sends tracing data about the flow execution to Openlayer, including:
View the collected data in your Openlayer dashboard.
Each flow execution appears as a trace with a hierarchical view of all components and their nested operations.
You can configure different Openlayer inference pipelines for different flows using flow-specific environment variables:
export OPENLAYER_PIPELINE_MY_FLOW_NAME="pipeline-id-1"
export OPENLAYER_PIPELINE_ANOTHER_FLOW="pipeline-id-2"
The flow name is converted to uppercase and non-alphanumeric characters are replaced with underscores. For example, "My Flow-Name" becomes OPENLAYER_PIPELINE_MY_FLOW_NAME.
Alternatively, you can use a JSON mapping to configure multiple flows at once:
<Tabs> <TabItem value="linux-macos" label="Linux or macOS" default>export OPENLAYER_LANGFLOW_MAPPING='{"Flow Name 1":"pipeline-id-1","Flow Name 2":"pipeline-id-2"}'
set OPENLAYER_LANGFLOW_MAPPING={"Flow Name 1":"pipeline-id-1","Flow Name 2":"pipeline-id-2"}
Openlayer configuration is resolved in the following order (highest priority first):
OPENLAYER_PIPELINE_<FLOW_NAME>OPENLAYER_LANGFLOW_MAPPINGOPENLAYER_INFERENCE_PIPELINE_IDThis allows you to set a default pipeline for all flows and override it for specific flows as needed.
To disable the Openlayer integration, remove the OPENLAYER_API_KEY environment variable, and then restart Langflow.
The Openlayer integration automatically captures: