Opik LLM Evaluation: Tracing, Testing and Monitoring in One Place

Opik LLM Evaluation: Tracing, Testing and Monitoring in One Place

Opik LLM evaluation is an open-source platform, built by Comet, that brings tracing, evaluation and monitoring of language model applications into one place. Instead of using one tool to test prompts before release and a different tool to watch them in production, Opik covers the whole lifecycle: you trace what the system does, test it against datasets, and monitor it once it is live. The central question is simple: when a language model system fails, can you see why? Opik answers it by recording every step, so a bad answer can be traced back to the prompt, the retrieved documents, or the tool call that caused it.

That visibility matters because language model failures are rarely obvious. A chatbot may give a wrong answer because the retriever found the wrong document, because the prompt was ambiguous, or because a tool returned stale data. Without a trace, you are guessing. Opik LLM evaluation gives you the trace, the test that reproduces the failure, and the dashboard that shows whether the failure is rare or common.

Key takeaways

  • Opik LLM evaluation combines tracing, datasets, experiments and monitoring in one open-source platform.
  • It records traces of language model calls, tool calls, retrieval steps and agent activity.
  • Datasets and experiments let teams test prompts and models against the same cases, repeatedly.
  • It can be self-hosted under an Apache 2.0 licence, or used as a hosted service.
  • It fits best for teams that want development testing and production monitoring in the same system.

What is Opik LLM evaluation?

Opik is an open-source platform for evaluating, testing and monitoring language model applications, built by Comet. It is designed for the full lifecycle of an LLM application, from the first trace in development to production monitoring, and it covers retrieval-augmented generation chatbots, code assistants and multi-step agent pipelines. It is licensed under Apache 2.0, and the full platform, including the server and web application, can be self-hosted without a commercial licence.

The platform has several parts that work together. Tracing records what happened during a run. Datasets store test cases. Experiments run a prompt or model against a dataset and score the results. A prompt library stores prompt versions, so a change can be compared with what came before. Dashboards show volume, latency, errors and cost for live traffic. Together, these parts mean that a failure found in production can become a test case, and a test case can be run against a new prompt before it ships.

Opik can be used in two ways. The easiest is the hosted service on Comet, which needs no setup. The other is self-hosting, by cloning the repository and running the platform with Docker Compose, or with a Helm chart for larger deployments. Self-hosting gives full control over data, which matters for teams that cannot send prompts or traces to a third party.

Tracing: seeing what the system actually did

Tracing is the foundation of Opik. A trace is a record of a single run, broken into spans: each language model call, each tool call, each retrieval step, and each agent action becomes a span with its inputs, outputs, latency and cost. For a multi-step agent, the spans form a tree, so you can see the order of events and which step produced which result.

Logging traces is deliberately easy. Opik provides integrations with many popular frameworks, including LangChain, OpenAI, Google ADK, AutoGen and CrewAI, so traces can be captured without changing application code in many cases. Where no integration exists, a function can be wrapped with a decorator, often written as @track, to log it as a span. Traces can also be annotated with feedback scores, either through the Python software development kit or through the user interface, so human judgement can be attached to the runs that matter.

Tracing is useful in development, when you are debugging a single failure, and in production, when you are looking for patterns. In development, a trace shows the exact prompt and context that produced a bad answer. In production, many traces together show whether a failure is a one-off or a pattern, and whether it started after a particular change. Our guide to LLM observability explains why this kind of visibility matters for systems that never behave the same way twice.

Datasets and experiments

Evaluation in Opik is organised around datasets and experiments. A dataset is a set of test cases, each with an input and, where relevant, an expected output. An experiment runs a prompt, model, or application against a dataset and scores each result, using code-based metrics or LLM-as-a-judge metrics. The experiment stores the scores, so experiments can be compared over time.

That structure makes prompt comparison practical. Two versions of a prompt can be run against the same dataset, and the results compared case by case, rather than by an average score alone. If a new prompt improves most cases but breaks a few, the experiment shows exactly which ones broke, and the traces for those cases show why. That is the same discipline as regression testing, applied to prompts and models.

Opik also supports online evaluation, which scores live production traces against the same metrics used in development. That closes the loop between testing and monitoring: a metric that was defined for a pre-release experiment can keep running on live traffic, so a quality drop in production is caught by the same measure that would have caught it before release. For help turning those scores into decisions, see AI evaluation scorecards, which covers how to present model scores so a team can act on them.

Prompt management and optimisation

Opik includes a prompt library, where prompt versions are stored and can be compared side by side. That matters because prompts change often, and a change that looks small can have a large effect. Storing versions means a team can roll back to a previous prompt when a new one performs worse, and can see the history of what was tried. Best for: teams that iterate on prompts frequently and need to know which version is live and why.

The platform also includes optimisation features, such as an agent optimiser that tries to improve prompts or agent behaviour based on evaluation results, and guardrails that check outputs in production. These are more advanced features, and they are best approached after the basics, tracing, datasets and experiments, are working well. A team that cannot yet see its traces will not benefit from automated optimisation.

Production monitoring

Production monitoring in Opik is built on the same traces as development. Dashboards show trace volume, latency, errors and cost, and online evaluation scores live traffic. Because Opik is designed to handle high volumes of traces, it can keep up with a busy application, rather than sampling so heavily that rare failures disappear. Best for: teams with live LLM applications that need to know, quickly, when quality, latency, or cost moves in the wrong direction.

Monitoring is also where feedback scores earn their keep. When a user marks an answer as unhelpful, or a reviewer scores a sample of traces, those scores become data that can be grouped, compared, and turned into new test cases. That turns production feedback into a growing dataset, rather than a pile of complaints that nobody acts on. See LLM production monitoring for the metrics worth tracking once a model goes live.

Comparing Opik with other tools

Tool or approach Main focus Main strength Main limitation
Opik Tracing, evaluation and monitoring in one platform Connects development evals to production data More setup than a command-line eval tool
Promptfoo Config-file evals and red teaming Fast setup, fits in continuous integration Less focused on live production tracing
DeepEval Python metrics library for LLM outputs Rich ready-made metrics, especially for RAG Python-first, no built-in tracing platform
Giskard Scanning for bias, security and performance issues Finds problems you did not think to test for Not a production monitoring platform
LangSmith and similar Hosted tracing and evaluation Polished hosted experience Hosted pricing and less control over data

Opik competes in the observability and evaluation category alongside LangSmith, Arize, Weights and Biases Weave, Langfuse and Braintrust. Its distinguishing point is that the full platform is open source and free to self-host, with no seat fees for the self-hosted version. That matters for teams that want control over their data, or that expect to scale the number of people who look at traces. For a direct comparison of tracing options, see LLM tracing tools compared.

A person tracing a branching diagram on a whiteboard with coloured markers
A trace is a tree of steps: each model call, tool call and retrieval step becomes a span, so a bad answer can be traced to the step that caused it.

When Opik is the right choice

Opik suits teams that want one system for tracing, evaluation and monitoring, rather than three separate tools that do not share data. It suits teams building agents and RAG systems, where a failure can come from any step in a chain, and where seeing the chain is the only way to diagnose it. It also suits teams that need to self-host, whether for data control, cost, or compliance.

It is less suited to teams that only need a quick pre-deployment eval and have no production system to monitor. For those teams, a command-line tool with a single configuration file is faster to set up and easier to keep running. Opik earns its setup cost when the system is live, complex, and changing, and when the team needs to see what it does in the real world.

Opik LLM evaluation checklist

  • Trace one application first, and read a few traces by hand before adding more.
  • Use integrations where they exist, and the tracking decorator where they do not.
  • Build a dataset from real failures, not only from easy cases.
  • Run experiments on the same dataset for every prompt or model change.
  • Compare experiments case by case, not only by average score.
  • Store prompt versions in the prompt library, and note why each changed.
  • Annotate traces with feedback scores from users and reviewers.
  • Set up online evaluation on live traffic with the same metrics used in development.
  • Watch latency, errors and cost on dashboards, not only quality scores.
  • Turn production failures into dataset cases, so they cannot return unnoticed.

Frequently asked questions

What is Opik LLM evaluation?

It is the practice of evaluating language model applications with Opik, an open-source platform that combines tracing, datasets, experiments, prompt management and production monitoring. It lets teams test prompts before release and watch them after release, in the same system.

Is Opik open source?

Yes. Opik is open source under the Apache 2.0 licence, built by Comet, and the full platform can be self-hosted for free. There is also a hosted service on Comet for teams that prefer not to run the platform themselves.

How is Opik different from Promptfoo or DeepEval?

Promptfoo and DeepEval focus mainly on pre-deployment evaluation, while Opik adds tracing and production monitoring in the same platform. A team might use Promptfoo or DeepEval for fast evals and Opik for tracing and monitoring, or use Opik for both.

Does Opik work with agents and RAG systems?

Yes. Opik captures multi-step traces containing language model calls, tool executions, retrieval steps and other agent activity, which makes it well suited to RAG systems and agents where a failure can come from any step.

Can I self-host Opik?

Yes. You can self-host Opik by cloning its repository and running it with Docker Compose, or with a Helm chart for larger deployments. Self-hosting gives full control over your traces and data.

What metrics does Opik use for evaluation?

Opik supports datasets, experiments, code-based metrics, LLM-as-a-judge evaluation, and online evaluation. That includes metrics for hallucination detection, moderation, and RAG assessment, as well as custom metrics a team defines for its own use case.

Latest articles

Scroll to Top