Skip to content

Evaluators

An evaluator scores what your agent produced. You give it an agent’s output, or a whole trace, and it returns a score, a pass or fail, and the reasoning behind the call. Strands ships evaluators for four things you usually want to check, plus fast code-based checks and a base class for anything custom:

  • Quality measures whether a response is helpful, accurate, coherent, and on topic, and whether a multi-turn trajectory holds together.
  • Safety screens a response for harmful content, inappropriate refusals, and stereotyping.
  • Multimodal judges responses grounded in an image or document.
  • Agentic measures tool use, goal completion, and how an agent behaves when things fail.
  • Skill measures whether a skill-equipped agent picked the right skill and then followed its steps.
  • Deterministic evaluators run code-based checks with no model in the loop.
  • Custom evaluators cover logic the built-ins do not.

Pick evaluators along two axes: what you want to check (the six groups above) and at what granularity:

LevelScopeUse case
OUTPUT_LEVELA single responseQuality of an individual output
TOOL_LEVELA single tool callTool selection and parameter accuracy
TRACE_LEVELA single turnTurn-by-turn analysis
SESSION_LEVELA full conversationEnd-to-end goal achievement

TRACE_LEVEL, SESSION_LEVEL, and TOOL_LEVEL are the values of the SDK’s EvaluationLevel enum, set through an evaluator’s evaluation_level. Evaluators that leave it unset (OutputEvaluator, the multimodal and skill evaluators, TrajectoryEvaluator, and InteractionsEvaluator) receive the agent’s output or full result directly, so the level shown for those is their conceptual scope.

Combine several evaluators in one experiment to assess different aspects at once. Each evaluator’s page documents its parameters and scoring in full; the tables below summarize what each one checks and links to that detail.

Score whether a response is useful and well-formed, and whether a multi-turn trajectory of actions holds together.

EvaluatorLevelWhat it checks
OutputEvaluatorOUTPUT_LEVELAny subjective quality against a rubric you write
HelpfulnessEvaluatorTRACE_LEVELResponse helpfulness from the user’s perspective
FaithfulnessEvaluatorTRACE_LEVELFactual accuracy and groundedness
CorrectnessEvaluatorTRACE_LEVELFactual correctness, with optional reference comparison
CoherenceEvaluatorTRACE_LEVELLogical consistency and reasoning quality
ConcisenessEvaluatorTRACE_LEVELBrevity and freedom from unnecessary verbosity
ResponseRelevanceEvaluatorTRACE_LEVELRelevance of a response to the user’s question
TrajectoryEvaluatorSESSION_LEVELSequence of actions and tool-usage patterns
InteractionsEvaluatorSESSION_LEVELConversation patterns and interaction quality

Screen a response for content you do not want an agent to produce, or for inappropriate refusals of valid requests. Each returns a binary classification.

EvaluatorLevelWhat it checks
HarmfulnessEvaluatorTRACE_LEVELDangerous or offensive content
RefusalEvaluatorTRACE_LEVELRefusals of valid requests the agent should address
StereotypingEvaluatorTRACE_LEVELBiased or stereotypical content against groups

Judge responses that depend on an image or document, using a multimodal LLM as the judge.

EvaluatorLevelWhat it checks
MultimodalOutputEvaluatorOUTPUT_LEVELAny quality against a rubric for image or document-to-text tasks
MultimodalOverallQualityEvaluatorOUTPUT_LEVELLikert-5 overall quality across accuracy, adherence, completeness, and coherence
MultimodalCorrectnessEvaluatorOUTPUT_LEVELBinary fact-check of a response against the image content
MultimodalFaithfulnessEvaluatorOUTPUT_LEVELBinary hallucination check for claims not verifiable from the image
MultimodalInstructionFollowingEvaluatorOUTPUT_LEVELBinary constraint compliance (count, format, scope, order, style)

Measure how an agent uses tools, whether it completes the user’s goal, and how it behaves when a tool fails.

EvaluatorLevelWhat it checks
ToolSelectionAccuracyEvaluatorTOOL_LEVELWhether the correct tools were selected
ToolParameterAccuracyEvaluatorTOOL_LEVELAccuracy of the parameters passed to tools
InstructionFollowingEvaluatorTRACE_LEVELCompliance with explicit format, length, style, and content constraints
GoalSuccessRateEvaluatorSESSION_LEVELWhether the user’s goal was achieved
FailureCommunicationEvaluatorTRACE_LEVELHow clearly the agent communicates failures to the user
PartialCompletionEvaluatorTRACE_LEVELWhat fraction of a goal was achieved despite failures
RecoveryStrategyEvaluatorTRACE_LEVELQuality of recovery actions when tools fail

For agents that load skills at runtime, measure both halves of that behavior: which skill the agent picked, and whether it then followed the skill’s steps. Both read the full trajectory and return one result per invoked skill.

EvaluatorLevelWhat it checks
SkillSelectionAccuracyEvaluatorSESSION_LEVELWhether invoking each skill was an appropriate choice
SkillInstructionFollowingEvaluatorSESSION_LEVELHow fully the agent followed each invoked skill’s steps

Run fast, code-based checks with no LLM judge, for regression tests and CI. The Deterministic Evaluators page covers Equals, Contains, StartsWith, ToolCalled, StateEquals, and SkillInvoked. They operate at OUTPUT_LEVEL or SESSION_LEVEL.

When no built-in fits, extend the base Evaluator class to implement your own logic. See Custom Evaluators.

An evaluation has three parts: a task that produces the agent’s output, cases that define the inputs and what you expect, and an evaluator that scores each result. This runs the OutputEvaluator against a rubric:

from strands import Agent
from strands_evals import eval_task, Case, Experiment
from strands_evals.evaluators import OutputEvaluator
@eval_task()
def get_response():
return Agent(system_prompt="Answer accurately and concisely.")
cases = [
Case[str, str](
name="capital",
input="What is the capital of France?",
expected_output="Paris",
)
]
evaluator = OutputEvaluator(rubric="Score 1.0 if the answer is correct, else 0.0.")
report = Experiment[str, str](cases=cases, evaluators=[evaluator]).run_evaluations(
get_response
)
report.run_display()

run_display() prints each case’s score, whether it passed, and the judge’s reasoning. To run many cases concurrently, use run_evaluations_async for the same report.

The same check runs without a script through strands-evals run. --rubric wires up an OutputEvaluator automatically, and --evaluator accepts built-in shortnames such as helpfulness or correctness:

Terminal window
# Rubric-scored check, equivalent to the Python example above
strands-evals run \
--input "What is the capital of France?" \
--rubric "Score 1.0 if the answer is correct, else 0.0." \
--agent my_agent:build_agent
# Built-in evaluator by shortname
strands-evals run \
--input "Is 17 prime?" \
--evaluator helpfulness \
--agent my_agent:build_agent

See strands-evals run for the full shortname list and how --agent resolves.

  • New to evaluation? Work through the quickstart, which runs this example end to end and reads the results.
  • Ready to combine scorers? Pick the evaluators for what you want to check from the tables above, starting with OutputEvaluator for free-form quality.
  • Building your own? See Custom Evaluators.
  • Want to know why cases fail? Detectors add automatic failure detection and root cause analysis.
  • Generating traces to score? Simulators drive the conversations that evaluators assess.