Wink Pings

A 19.7k-star LLM evaluation framework: comprehensive metrics don't mean stable results

DeepEval packs custom metrics, agents, voice, multi-turn, RAG, MCP, and multimodal into one framework. The checklist is comprehensive, but before putting it into practice, ask: if you run the same loop several times, will tool correctness and plan adherence drift?

DeepEval

DeepEval has 19.7k stars on GitHub and is positioned as an LLM evaluation framework, with an API close to Pytest. LLM applications differ from traditional software: with the same input run multiple times, outputs may change. What an evaluation framework should do is turn this uncertainty into repeatable tests as much as possible: given input, actual output, expected output, score with metrics, then decide whether this release can pass.

In a tweet, Suercha listed DeepEval's metrics by scenario. The coverage is indeed rare: custom metrics, agents, voice agents, multi-turn conversations, RAG, MCP, multimodal, plus hallucination and summarization. Here is some context: an agent is a system that can plan its own steps and call tools; a voice agent is AI that can answer and make phone calls; RAG is retrieving materials first and then answering; MCP is a protocol that lets models call external tools and services.

The metric list can be used as an evaluation checklist. Custom metrics include JevEval, G-Eval, and DAG. JevEval is scored by Jev, answers with calibrated probabilities, and does not generate long text. G-Eval is a research-backed LLM-as-judge metric; it can evaluate against custom criteria with accuracy close to humans. DAG is a graph-structured deterministic LLM-as-judge builder. On the agent side there are task completion, tool correctness, goal accuracy, step efficiency, plan adherence, plan quality, tool use, and argument correctness. On the voice side it looks at responsiveness, turn naturalness, speech naturalness, transcription accuracy, and audio glitches. Multi-turn conversation looks at knowledge retention, conversation completeness, turn relevancy, turn faithfulness, and role adherence. RAG looks at answer relevancy, faithfulness, contextual recall, contextual precision, contextual relevancy, and RAGAS. MCP looks at task completion, MCP use, and multi-turn MCP use. Multimodal looks at text-to-image, image editing, image consistency, image helpfulness, and image reference. Other metrics include hallucination, summarization, and more.

A commenter in the replies reminded that having all the metrics is a good thing, but in practice you still need to see whether the judgments are stable. This reminder is closer to actual engineering than the checklist itself. Only if you run the same agent loop several times and tool correctness and plan adherence do not drift is it truly usable. There may be so many metrics that they are like a menu, but the ones you actually order are probably just a few. Start with two or three key metrics and get them stable, then expand to the full set; that is more practical than covering every metric from the start.

Installation is not complicated: Python >=3.10, run pip install -U deepeval. Optionally log in with deepeval login to sync test reports to the cloud. Then write a test file and run end-to-end evaluation of the LLM application as a black box. Below, G-Eval is used to judge correctness; scores range from 0 to 1, and a threshold of 0.5 determines pass/fail:

from deepeval import assert_test
from deepeval.metrics import GEval
from deepeval.test_case import LLMTestCase, SingleTurnParams

metric = GEval(
    name='Correctness',
    criteria='判断 actual output 是否符合 expected output',
    evaluation_params=[SingleTurnParams.ACTUAL_OUTPUT, SingleTurnParams.EXPECTED_OUTPUT],
    threshold=0.5,
)
case = LLMTestCase(
    input='鞋不合脚怎么办?',
    actual_output='30 天内可全额退款,不额外收费。',
    expected_output='我们提供 30 天全额退款,不额外收费。',
)
assert_test(case, [metric])

After setting the OPENAI_API_KEY environment variable, run deepeval test run test_ai_agent.py. It can also evaluate directly in a notebook without relying on Pytest. Metrics can be used standalone; after measure, get score and reason. DeepEval also supports synthesizing single-turn and multi-turn datasets, simulating voice calls, integrating with CI/CD, optimizing prompts based on evaluation results, and running benchmarks such as MMLU, HellaSwag, DROP, BIG-Bench Hard, TruthfulQA, HumanEval, and GSM8K in under 10 lines of code. Integrations cover OpenAI Agents, LangChain, LangGraph, CrewAI, LlamaIndex, Pydantic AI, Google ADK, and more, and the voice stack connects to Vapi, ElevenLabs, LiveKit, and Pipecat.

DeepEval demo

For production, there is also Confident AI. DeepEval tests what you already know you want to test; Confident AI finds failing traces for which no one has written evaluations, clusters them into failure modes, hands them to the right people for labeling, and finally turns them into goldens for the next evaluation. It provides an MCP server so you can view failing traces and datasets in Claude Code or Cursor. For teams, putting evaluation, monitoring, human labeling, and release gates into one system is easier to maintain than scattered scripts.

Confident AI MCP architecture

GitHub repository: confident-ai/deepeval, docs: deepeval.com. Comprehensive metrics do not mean stable results; first get the critical path running, then talk about coverage.

发布时间: 2026-12-01 15:30