Configuring scorers
Set up evaluation metrics and scoring thresholds.
What are scorers?
Scorers define what you're measuring. When you run an experiment, each scorer examines the model's responses and produces a score, typically between 0 and 1, indicating how well the response meets that particular criterion.
Think of scorers as the rubric for your evaluation. A customer support bot might need scorers for helpfulness, accuracy and tone. A coding assistant might prioritize correctness and completeness. The scorers you choose should reflect what "good" means for your specific application.
Default scorers
LLM Evals turns on a set of built-in metrics by default based on your use case. Seven core metrics are on for every use case: answer relevancy, correctness, completeness, hallucination, instruction following, toxicity and bias. RAG projects add faithfulness, context relevancy, context precision and context recall. Multi-turn chatbot datasets add six conversational metrics. The most common ones are described below:
Answer relevancy
The most fundamental metric: does the response actually address the question? A model might generate fluent, grammatically correct text that completely misses the point. This scorer catches that.
A score of 1.0 means the response directly and completely addresses the prompt. A score near 0 means the response is off-topic or irrelevant. Most well-tuned models score above 0.7 on typical queries.
Bias detection
Identifies responses containing discriminatory or unfair content. This includes gender bias, racial bias, political bias, age discrimination and other forms of prejudicial language.
Higher scores indicate more bias detected; 0 means none was found. For user-facing applications you generally want this score close to 0. Any significant bias should trigger a review of your prompts and model selection.
Toxicity detection
Flags harmful, offensive, abusive or inappropriate language. This goes beyond bias to include threats, insults, profanity and content that could harm users or your brand.
Critical for any model that interacts with the public. Even if your model is generally well-behaved, adversarial prompts might elicit toxic responses. Regular evaluation helps catch these edge cases.
Faithfulness
Measures whether the response accurately reflects provided context. This matters most for RAG (Retrieval-Augmented Generation) systems where the model should ground its answers in retrieved documents.
A faithful response only makes claims supported by the context. An unfaithful response adds information that wasn't there or contradicts what was provided. If you're building knowledge-based applications, this scorer is crucial.
Hallucination detection
Identifies fabricated facts, unsupported claims and made-up information. Unlike faithfulness (which requires explicit context), this catches models that confidently state things that simply aren't true.
Hallucination is one of the most common failure modes in LLMs. Models can sound authoritative while being completely wrong. This scorer helps quantify how often your model makes things up.
Context relevancy
For RAG systems, this evaluates the retrieval step: was the context that got retrieved actually relevant to the question? You can have a perfectly faithful response that's still wrong because the retrieved context was irrelevant.
Low scores here indicate a retrieval problem, not a generation problem. Your model might be doing exactly what it should with the context it's given, but the wrong context leads to wrong answers.
Conversational metrics
When evaluating chatbots with multi-turn datasets, additional metrics become available. These are specifically designed to assess how well a model handles ongoing conversations rather than isolated prompts. Learn how to create multi-turn datasets in Managing datasets.
Turn relevancy
Measures whether each response in a conversation directly addresses the user's current message. Unlike general answer relevancy, this considers the conversational context. A response might be relevant to the overall topic but miss what the user just asked.
Knowledge retention
Evaluates whether the model remembers information from earlier in the conversation. If a user mentions their name in turn 1 and asks "What's my name?" in turn 5, the model should know. Low scores indicate the model is treating each turn as isolated.
Conversation coherence
Assesses the logical flow of the conversation. Does the model's response make sense given everything that came before? Incoherent responses might contradict earlier statements or suddenly change topic without reason.
Conversation helpfulness
Measures how useful the model's responses are in progressing the conversation toward the user's goal. A response can be relevant and coherent but still unhelpful if it doesn't actually assist the user.
Task completion
For goal-oriented conversations, this evaluates whether the model successfully helps the user complete their task. If someone is trying to book a flight, did the conversation end with a booking? Particularly important for customer service and assistant chatbots.
Conversation safety
A conversation-aware version of toxicity detection. This evaluates safety across the entire conversation, catching cases where the model might be manipulated through multi-turn prompting that wouldn't trigger safety filters in a single turn.
Per-turn safety evaluation
For multi-turn conversations, bias and toxicity are evaluated on each individual assistant response, not just the final output. This catches cases where a model might produce problematic content mid-conversation even if the final response is clean.
The experiment shows one combined bias score and one combined toxicity score per conversation. Open the conversation to find the turn that caused it.
Managing scorers
Navigate to the Scorers tab in your project. The table lists each scorer with its judge model, pass threshold, number of choice scores and when it last ran.
Click a row to edit the scorer, or use the menu at the end of the row to edit or delete it.
Creating a custom scorer
Need to evaluate something specific to your domain? Create a custom scorer by clicking New scorer. In the Create scorer window you'll configure the fields below, then click Save as custom scorer:
- Name: A descriptive label that appears in results (e.g., "Medical accuracy")
- Slug: An identifier generated from the name
- Judge model: The model that scores the responses
- Prompt: The instructions and messages sent to the judge. Click Add message to add more.
- Choice scores: The answers the judge can give, each mapped to a score, such as PASS = 1 and FAIL = 0. Click Add choice to add more.
- Pass threshold: The score a sample needs to pass
- Top P: Sampling setting for the judge; lower values make its answers more focused
Custom scorers and built-in metrics
Custom scorers use a judge model to score responses against your prompt and choice scores, so they can check qualities like tone or domain accuracy. Each evaluation is a call to the judge model, so they take time and cost API usage.
The built-in metrics (answer relevancy, correctness, toxicity and the others) are not managed here. You choose them per experiment on the Metrics step of the New experiment wizard.
Setting thresholds
Thresholds determine what counts as "passing." A threshold of 0.7 means any response scoring below 70% is considered a failure for that metric.
How to choose thresholds:
- Start permissive: Begin with 0.5 or 0.6 to understand your baseline. You can tighten later.
- Review failures manually: Look at responses that score just below your threshold. Are they actually bad? Adjust accordingly.
- Match your quality bar: If you wouldn't ship a response to users, it should fail. Calibrate thresholds to match your standards.
- Different thresholds for different metrics: Toxicity and bias are scored lower-is-better, so a strict setting is a low threshold such as 0.1, while relevancy might pass at 0.7.
Choosing which scorers run
Not every scorer needs to run in every experiment. To choose which custom scorers run, select them on the Scorer / Judge step of the New experiment wizard. If you select none, all of the project's scorers run.
Scorer best practices
A few lessons from teams who've built effective evaluation pipelines:
- Match scorers to your goals: Don't just enable everything. Think about what makes a response "good" for your users and configure scorers accordingly.
- Keep judge models consistent: If you're comparing experiments over time, use the same judge. Different judges may score the same response differently.
- Calibrate regularly: Periodically review scored responses manually. Are the scores matching your intuition? If not, adjust thresholds or scorer configurations.
- Document your choices: Keep notes on why you chose certain thresholds and scorers. Future you (or teammates) will thank you when debugging unexpected results.
- Start simple: Begin with the default scorers and thresholds. Add complexity only when you understand how the system behaves.
Common issues
- All scores are too low: Your expected outputs might be too specific. Judges evaluate semantic similarity, not exact matches, but if your expectations are very different from what the model produces, scores suffer.
- All scores are too high: Your dataset might be too easy, or your thresholds too permissive. Add challenging test cases and review failing examples to calibrate.
- Inconsistent scores: Use a stronger judge model, or lower Top P on custom scorers for more focused judging.
- Evaluations are slow: Each metric requires a judge call. Disable metrics you don't need, or use faster judge models for iterative testing.