Langfuse Overview
Langfuse is an open-source AI engineering platform (GitHub) that helps teams collaboratively debug, analyze, and iterate on their AI agent applications. All platform features are natively integrated to accelerate the development workflow. Langfuse is open, self-hostable, and extensible (why Langfuse?).
Observability
Log traces
Lowest level transparency
Understand cost and latency
Prompts
Version control and deploy
Collaborate on prompts
Test prompts and models
Evaluation
Measure output quality
Monitor production health
Test changes in development
Platform
API-first architecture
Data exports to blob storage
Enterprise security and administration
Observability
Observability is essential for understanding and debugging AI agent applications. Unlike traditional software, AI agent applications involve complex, non-deterministic interactions that can be challenging to monitor and debug. Langfuse provides comprehensive tracing capabilities that help you understand exactly what's happening in your application.
- Traces include all LLM and non-LLM calls, including retrieval, embedding, API calls, and more
- Support for tracking multi-turn conversations as sessions and user tracking
- Agents can be represented as graphs
- Capture traces via our native SDKs for Python/JS, 100+ library/framework integrations, OpenTelemetry, or via an LLM Gateway such as LiteLLM
- Based on OpenTelemetry to increase compatibility and reduce vendor lock-in
Want to see an example? Play with the interactive demo.
Want to learn more?
Watch end-to-end walkthrough of Langfuse Observability and how to integrate it with your application.
Traces allow you to track every LLM call and other relevant logic in your app.
Trace detail of a RAG answer with the generation selected. Hover the cost and token values in the generation header to see the cost and usage breakdowns, expand the collapsed chat history, then select the retrieval span in the tree to see the context it returned.
Sessions allow you to track multi-step conversations or agentic workflows.
Trace detail of one support-chat turn. Click the âsessionâ badge in the trace header to open the session: every turn of the conversation in one view, with the user and assistant messages in order. Click the last turn in the list on the left to jump to it.
Debug latency issues by inspecting the timeline view.
Trace detail of an agent trace. Switch from âTreeâ to âTimelineâ to see each step as a bar on a time axis with its duration and cost, so the slowest steps stand out. Click one of the llm.chat calls to open it, then switch back to âTreeâ.
Add your own userId to monitor costs and usage for each user. Optionally, create a deep link to this view in your systems.
Users list with each user's first and last event, trace count, tokens and cost. Click a user to open their page with total observations, tokens and cost, their traces, and the âScoresâ tab with every score on their traces.
LLM agents can be visualized as a graph to illustrate the flow of complex agentic workflows.
Trace detail of an agent trace, âGraphâ tab next to Tree and Timeline. In the default Aggregated mode, repeated steps collapse into one node such as âllm.chat (3/3)â; select it to see its observations. Switch the toggle to Expanded to see the run as it happened, click a tool call node, then switch back to Aggregated.
See quality, cost, and latency metrics in the dashboard to monitor your LLM application.
Home dashboard with traces by name, model costs and scores. Change the time range from âPast 1 dayâ to âPast 7 daysâ, then scroll through observations by level, model usage and cost, user consumption, score trends and latency percentiles.
Get notified over Slack, GitHub Actions, or Webhooks when a metric crosses a threshold with alerts.
Prompt and Skill Management
Prompt Management lets you manage and version model-call templates. Skill Management, currently in beta, brings versioning and labels to agent instructions and supporting files. Use both to connect the instructions your application receives to its behavior in traces.
- Get started with prompt management
- Create and load a skill for your agent
- Manage, version, and optimize your prompts throughout the development lifecycle
- Test prompts interactively in the LLM Playground
- Run Experiments against datasets to test new prompt versions directly within Langfuse
Want to learn more? Watch end-to-end walkthrough of Langfuse Prompt Management and how to integrate it with your application.
Create a new prompt via UI, SDKs, or API.
Prompts > âNew promptâ. Enter the name order-status-reply and a text prompt with the variables {{customer_name}} and {{order_id}}; Langfuse lists the detected variables below the editor. Keep âSet the production labelâ checked and click âCreate promptâ: version 1 opens with the production and latest labels.
Collaboratively version and edit prompts via UI, API, or SDKs.
Prompts > support-reply > âNew versionâ. Edit the system message, add the commit message âConfirm order numbersâ and click âSave new prompt versionâ. The new version appears on top of the version list with its commit message and the latest label.
Deploy prompts to production or any environment via labels - without any code changes.
Prompts > qa-answer-with-context-chat with the latest version (#12) selected. Click âAdd labelâ, tick production under âPromote to production?â and click âSave and promote to productionâ; the production label moves to #12. The video then selects #9 and promotes it back to production.
Compare latency, cost, and evaluation metrics across different versions of your prompts.
Prompts > qa-answer-with-context-chat > âMetricsâ tab: one row per version with median latency, input and output tokens, cost, generation count and score columns such as accuracy and helpfulness. Switch back with the âVersionsâ tab.
Instantly test your prompts in the playground.
Prompts > movie-critic, version 3. Click âPlaygroundâ > âFresh playgroundâ, fill the variables criticlevel (expert) and movie (Dune: Part Two) in the Variables panel and click âSubmitâ to get the model's answer in Output.
Link prompts with traces to understand how they perform in the context of your LLM application.
Trace detail with a generation that used movie-critic v3. Click the prompt badge âmovie-critic - v3â in the generation header to open the prompt, then open its âLinked Generationsâ tab and the âMetricsâ tab with latency, cost and scores per version.
Track changes to your prompts to understand how they evolve over time.
Prompts > support-reply with the latest version (#5) selected. Hover an older version in the version list and click its compare icon; the âChanges v2 â v5â dialog shows the content and config diff. Close it.
Evaluation
Evaluation is crucial for ensuring the quality and reliability of your LLM applications. Langfuse provides flexible evaluation tools that adapt to your specific needs, whether you're testing in development or monitoring production performance.
- Evaluate Production Traffic to score live production traces
- Get started with different evaluation methods: LLM-as-a-judge, code evaluators, user feedback, manual labeling, or custom pipelines
- Identify issues early by running evaluations on production traces
- Create and manage Datasets for systematic testing in development that ensure your application performs reliably across different scenarios
- Run Experiments to systematically test your LLM application
Want to learn more? Watch end-to-end walkthrough of Langfuse Evaluation and how to use it to improve your LLM application.
Plot evaluation results in the Langfuse Dashboard.
Scores > âAnalyticsâ. Pick helpfulness as the first score to see its statistics, trend over time and distribution, then pick faithfulness as the second score to compare both: means, matched pairs, correlation and a side-by-side distribution.
Collect feedback from your users. Can be captured in the frontend via our Browser SDK, server-side via the SDKs or API.
Scores page. Search name:user-feedback value:<0.5 to list the thumbs-down feedback the chat widget sent through the API, with the customer's comment such as âStill charged twice.â Click a row's trace to open the conversation in a side panel.
Run fully managed LLM-as-a-judge evaluations on production or development traces. Can be applied to any step within your application for step-wise evaluations.
Evaluators > âNew evaluatorâ > template âClassify Input Topicâ (LLM-as-a-judge). Filter the sample observations to the support chatbot, map the {{input}} variable to payload.message under âMap variables to dataâ, run the judge on one sample to see its score and reasoning, then click âCreate evaluatorâ and confirm the rule in the âEvaluator savedâ dialog.
Evaluate prompts and models on datasets directly in the user interface. No custom code is needed.
Datasets > capital-cities > âRun experimentâ > âvia User Interfaceâ > Configure. Select prompt answer-question, version 3, and model gpt-4.1, keep the dataset capital-cities, skip evaluators, name the run and click âRun Experimentâ. A toast confirms the experiment was triggered.
Baseline your evaluation workflow with human annotations via Annotation Queues.
Human Annotation > âNew queueâ: name it âError Analysisâ, add the âFirst Passâ score config and click âCreate queueâ. In Tracing, select three traces, choose âAdd to Annotation Queueâ in the selection bar and pick âError Analysisâ. Open the queue with âProcess queueâ and annotate the first item in the Annotate panel.
Add custom evaluation results, supports numeric, boolean and categorical values.
POST /api/public/scoresAdd scores via Python or JS SDK.
from langfuse import get_client
langfuse = get_client()
langfuse.create_score(
trace_id="123",
name="my_custom_evaluator",
value=0.5,
)Where to start?
Setting up the full process of online tracing, prompt management, production evaluations to identify issues, and offline evaluations on datasets requires some time. Most teams eventually end up with a process that looks like this:
If you're new to AI engineering, take a look at the Academy, where you'll find conceptual guidance on how to approach AI engineering, trade-offs, and best practices. If you already know what you want, the getting-started guides below will get you going.
Tip: let your coding agent do the setup and work with Langfuse through the Agent Skill, CLI, or MCP server. On Langfuse Cloud, you can also ask Halo, the Langfuse assistant, about your project data from inside the app.
Quickstarts
Get up and running with Langfuse in minutes. Choose the path that best fits your current needs:
Why Langfuse?
- Open source: Fully open source with public API for custom integrations
- Production optimized: Designed with minimal performance overhead
- Best-in-class SDKs: Native SDKs for Python and JavaScript
- Framework support: Integrated with popular frameworks like OpenAI SDK, LangChain, and LlamaIndex
- Multi-modal: Support for tracing text, images and other modalities
- Full platform: Suite of tools for the complete LLM application development lifecycle
Community & Contact
We actively develop Langfuse in open source together with our community:
- Contribute and vote on the Langfuse roadmap.
- Ask questions on GitHub Discussions or private support channels.
- Report bugs via GitHub Issues.
- Chat with the community on Discord.
- Join a community hour to talk to the team and ask questions live.
- Why people choose Langfuse?
Langfuse evolves quickly, check out the changelog for the latest updates. Subscribe to the mailing list to get notified about new major features:
Last updated on