Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

langfuse

Skill by TerminalSkills

Langfuse is an open-source LLM engineering platform. This skill helps an AI assistant add tracing, prompt management, output scoring and dataset experiments to LLM apps. It is aimed at developers building LLM or RAG applications.

  • Score 49
  • 218 stars
  • Apache-2.0
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install langfuse

Built from the published package, never by AI.

git clone --depth 1 https://github.com/TerminalSkills/skills /tmp/skills && mkdir -p ~/.claude/skills && cp -r /tmp/skills/skills/langfuse ~/.claude/skills/langfuse

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install langfuse in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

This skill gives an AI assistant guidance for Langfuse, an open-source LLM engineering platform. It covers recording traces of LLM calls as nested observations with model, token usage and cost, managing versioned prompts, scoring outputs, and building datasets and experiments. The examples cover Python and TypeScript instrumentation, including OpenAI and Vercel AI SDK calls.

The skill targets developers adding observability to LLM or RAG applications, whether on Langfuse Cloud or a self-hosted instance. It includes setup steps, code for the Python langfuse 5.x and @langfuse/* 6.x SDKs, and guidelines such as flushing before exit and avoiding legacy APIs. Langfuse observes and evaluates calls. It does not call models or route requests.

Written from the project's SKILL.md and checked against it.

What it can do

  • Trace Python pipelinesUses the @observe decorator to nest retriever, generation and function observations.
  • Trace TypeScript appsCreates observations and propagates user and session attributes with @langfuse/tracing.
  • Track cost and latencyRecords model, token usage and cost for LLM generations, including through the OpenAI drop-in.
  • Manage promptsFetches versioned prompts by label, with a fallback value, and links generations to prompt versions.
  • Score outputsAdds numeric, boolean or categorical scores to traces, from user feedback or evaluators.
  • Build datasets and experimentsCreates dataset items and runs experiments with evaluators to compare prompt versions.
  • Self-host guidanceDescribes the official docker-compose setup and the secret values to replace before exposing it.

What you need

  • Langfuse Cloud project or self-hosted Langfuse instance
  • LANGFUSE_PUBLIC_KEY and LANGFUSE_SECRET_KEY API keys
  • Python 3.11+ (langfuse 5.x) or Node.js 22+ (@langfuse/* 6.x)
  • Docker for self-hosting with docker-compose

Try asking

  • Add Langfuse tracing to my /ask RAG endpoint with user and session IDs
  • Fetch my support system prompt from Langfuse using the production label
  • Run a Langfuse experiment comparing two prompt versions on my QA dataset

Good to know

  • Legacy v2/v3 APIs such as langfuse.decorators and the unscoped npm packages should not be used in new code.
  • Custom or fine-tuned models need price definitions in project settings, or cost stays empty.
  • Tracing is asynchronous and batched, so scripts and serverless handlers must flush before exiting.
  • Langfuse does not call models or route requests for you.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: skills/langfuse/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Alternatives to langfuse

All alternatives →

Compare with agent-reproduce-align, google_contacts or m06-error-handling

langfuse: common questions

Does Langfuse work with the OpenAI SDK and Vercel AI SDK?

The source describes an OpenAI drop-in in Python, observeOpenAI in @langfuse/openai, and @langfuse/vercel-ai-sdk for AI SDK v7. For AI SDK versions up to 6, it says to enable experimental_telemetry in each call.

Can Langfuse be self-hosted?

Yes. The source points to the official docker-compose.yml in langfuse/langfuse, which runs the web app, a worker, Postgres, ClickHouse, Redis and MinIO. Every CHANGEME value must be replaced before exposing it.

Does Langfuse record my prompts and outputs?

By default, observations record function inputs and outputs. The source says to pass capture_input=False and capture_output=False to @observe, or to mask data in the client, for personal or secret data.

How do I install langfuse?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is langfuse free?

The code is published under the Apache-2.0 licence. The service it connects to may have its own pricing.

Is langfuse safe to use?

It scores 49 of 100. Grades: maintenance A, licence A, quality B. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to langfuse?

Similar skills: agent-reproduce-align, google_contacts, m06-error-handling, caveman.

langfuse Install

Add to stack

Loading.