LangFlow

LangFlow is an open-source visual framework that enables developers to rapidly design, prototype, and deploy custom applications powered by large language models (LLMs). Built on top of LangChain,

LangFlow users can now seamlessly observe their LLM workflows through Arize . This integration allows developers to gain granular visibility into the performance and behavior of their LangFlow applications. By leveraging Arize AI's observability platform, users can capture detailed telemetry data from their LangFlow pipelines, enabling them to identify bottlenecks, trace the flow of requests, and ensure the reliability and efficiency of their LLM-powered systems. This enhanced observability empowers teams to debug issues faster, optimize performance, and maintain high-quality user experiences across their LLM applications.

Pull LangFlow Repo

Navigate to the LangFlow GitHub repo and pull the project down

Create .env file

Navigate to the repo and create a .env file with all the Arize variables. You can use the .env.example as a template to create the .env file

Add the following environment variables to the .env file

# Arize Env Variables
ARIZE_SPACE_ID="YOUR_ARIZE_SPACE_ID"
ARIZE_API_KEY="YOUR_ARIZE_SPACE_KEY"

Start Docker Desktop

Start Docker Desktop, build the images, and run the container (this will take around 10 minutes the first time) Go into your terminal into the LangFlow directory and run the following commands:

docker compose -f docker/dev.docker-compose.yml down || true 
docker compose -f docker/dev.docker-compose.yml up --remove-orphans

Create a Flow

In this example, we'll use Simple Agent for this tutorial

Add your OpenAI Key to the Agent component in LangFlow

Go into the Playground and run the Agent

Go to Arize

Navigate to your project name (should match the name of of your LangFlow Agent name)

Inspect Traces

AgentExecutor Trace is Arize instrumentation to capture what's happening with the LangChain being ran during the LangFlow components

The other UUID trace is the native LangFlow tracing.

Last updated

Was this helpful?