LLM app evaluation and monitoring — measure quality and detect hallucinations in production
Evals & ObservabilityFree
TruLens is an open-source library for evaluating and monitoring LLM-powered applications. It measures output quality using TruLens Evals (faithfulness, relevance, harmlessness, and custom metrics via LLM-as-judge), tracks experiments, and monitors production performance. Integrates with LangChain, LlamaIndex, and any Python LLM application.
Production monitoring capabilities go beyond offline evaluation — monitor LLM quality metrics in real time.
Framework-agnostic: works with LangChain, LlamaIndex, raw OpenAI calls, or any Python LLM code.
LLM-as-a-judge evaluation scales feedback functions to thousands of examples automatically.
Open source with active development; TruEra company backing ensures ongoing maintenance.
Key capabilities
Feedback functions: Pre-built and custom metrics for groundedness, relevance, harmlessness, and custom criteria.
Tracing: Automatic instrumentation of LLM calls, chains, and agent steps with inputs/outputs recorded.
Dashboard: Local or hosted dashboard for viewing evaluation results, traces, and comparing experiments.
RAG evaluation: Faithfulness, context relevance, and completeness metrics for RAG applications.
LangChain integration: Wrap LangChain chains with TruLens for automatic tracing and evaluation.
LlamaIndex integration: Evaluate LlamaIndex query engines with TruLens feedback functions.
Production monitoring: Deploy feedback functions on live production traffic for continuous quality monitoring.
A/B comparison: Compare multiple prompt versions or model configurations in the same evaluation run.
Technical notes
License: MIT (open source)
GitHub: github.com/truera/trulens (4K+ stars)
Install:pip install trulens-eval
Integrations: LangChain, LlamaIndex, OpenAI, Anthropic, and raw Python
Dashboard: Local Streamlit dashboard; TruEra Cloud for managed
Feedback LLM: OpenAI GPT (default); configurable
Company: TruEra; backed by Greylock, Sequoia; founded 2020
Ideal for
ML engineers who want comprehensive evaluation beyond RAG-specific metrics — general LLM app quality.
Teams monitoring production LLM applications for quality regression and hallucination detection.
Researchers comparing different prompts, models, or retrieval strategies with systematic evaluation.
Not ideal for
Pure RAG-specific evaluation — RAGAS has more specialized and validated RAG metrics.
Non-Python LLM applications — TruLens is Python-only.
Real-time alerting on production issues — more of an evaluation framework than an ops platform (Helicone/LangSmith for production ops).
See also
RAGAS — Focused RAG evaluation framework with specialized metrics.
LangSmith — LangChain's evaluation and monitoring platform.
Promptfoo — CLI-based LLM prompt testing and evaluation.
FAQ
What is TruLens?
TruLens is an open-source evaluation and monitoring framework for LLM applications. You instrument your LLM app with TruLens's tracing decorators, define quality metrics (feedback functions), and TruLens records every LLM call, evaluates it against your metrics, and displays results in a dashboard. It supports both offline evaluation (batch testing) and production monitoring.
Is TruLens open source?
Yes. TruLens is open source under the MIT license. GitHub: github.com/truera/trulens. TruEra (the company) offers TruEra Enterprise with additional managed hosting, team features, and enterprise support.
How does TruLens compare to RAGAS?
Both measure LLM output quality. RAGAS is focused specifically on RAG pipeline evaluation (faithfulness, context recall, etc.). TruLens is broader — it evaluates any LLM application (RAG or not), supports custom feedback functions, and provides production monitoring dashboards. For RAG-specific evaluation, RAGAS and TruLens are complementary (you can use RAGAS metrics within TruLens). TruLens for general LLM app monitoring; RAGAS for deep RAG quality metrics.
What are TruLens feedback functions?
Feedback functions are TruLens's evaluation metrics — Python functions that take LLM inputs/outputs and return a score. TruLens includes pre-built feedback functions: groundedness (is the answer factual given the context?), relevance (is the response relevant to the query?), harmlessness (does the response contain harmful content?). You can define custom feedback functions using any evaluation logic including calling GPT as a judge.
SEO, AI search (how ChatGPT, Perplexity and Google describe TruLens), UX, CRO and support from one account manager, with a monthly report. Includes a Featured launch on db.fyi. Starts with a free audit.
Founding offer: $299 a month for your first 3 months, plus a free case study.