Skip to main content

Create Evaluations from Templates

An evaluation template is a prebuilt evaluator for a common AI evaluation pattern. You pick a template, fill a short form, and WSO2 Integrator generates the evaluation for you, with no flow to build.

This page walks through the Tool Trajectory template, which checks that the agent calls the tools recorded in an evalset. To write your own evaluation logic instead, see Create custom evaluations.

Prerequisites

The Tool Trajectory template replays an evalset, so have at least one evalset in your project. See Create evalsets to capture or import one.

Start a new evaluation​

  1. Open the Test Explorer by clicking the test beaker icon in the activity bar.
  2. Click Add Test at the top of the Test Explorer and choose Add AI Evaluation.
Test Explorer in the Testing view with the math-tutor evalset listed under Evalsets, ready to add a new AI evaluation.Test Explorer in the Testing view with the math-tutor evalset listed under Evalsets, ready to add a new AI evaluation.
  1. In the Create New AI Evaluation form, under How would you like to build this evaluation?, select From Template.
Create New AI Evaluation form with From Template selected and a Choose Template button under Choose an evaluation template.Create New AI Evaluation form with From Template selected and a Choose Template button under Choose an evaluation template.

Choose a template​

Click Choose Template to open Browse Evaluation Templates. Templates come in two kinds:

  • Rule-based. Scored in code, with no LLM involved. Results are deterministic.
  • LLM-as-Judge. Scored by a judge model, which returns a score and its reasoning. The evaluation passes when the score reaches the configured threshold.

The badges on each card show its kind and the test input it accepts. Evalset required templates replay the conversations recorded in an evalset. Evalset or queries templates can also run on queries you enter manually. Use the search box or the filter buttons to narrow the list.

Browse Evaluation Templates dialog showing 23 templates with a search box, filter buttons for All, Rule-based, LLM-as-Judge, Evalset required, and Evalset or queries, and template cards such as Clarity, Coherence, and Contains Match.Browse Evaluation Templates dialog showing 23 templates with a search box, filter buttons for All, Rule-based, LLM-as-Judge, Evalset required, and Evalset or queries, and template cards such as Clarity, Coherence, and Contains Match.

Select Tool Trajectory. You can type tool in the search box to find it quickly.

Configuring a template​

For example, choose the Tool Trajectory evaluation template. The selected template opens in a configuration card. Tool Trajectory replays each turn in the evalset against the agent and compares the tool calls the agent makes with the tool calls recorded for that turn. A tool call matches when both the tool name and its arguments are equal.

FieldValueNotes
Target AgentmathTutorAgentThe agent under evaluation.
Evalset Filemath-tutorThe evalset to replay. Under Test input. This template always evaluates against an evalset.
Match ModeSTRICT (default)How the agent's tool calls are compared with the recorded ones. Under Optional settings; click Expand to change it.
Minimum Pass Rate (%)90The percentage of evalset threads that must pass for the run to succeed.
Tool Trajectory template configuration card with Target Agent set to mathTutorAgent, Evalset File set to math-tutor, Optional settings, and Minimum Pass Rate set to 90%.Tool Trajectory template configuration card with Target Agent set to mathTutorAgent, Evalset File set to math-tutor, Optional settings, and Minimum Pass Rate set to 90%.

If the project has no evalset yet, click Create empty evalset to create one. Open evalset opens the selected evalset in the Evalset Viewer. To pick a different template, click Change Template.

Match modes​

ModePasses when
STRICTThe agent makes exactly the recorded tool calls, in the same order.
UNORDEREDThe agent makes exactly the recorded tool calls, in any order.
SUBSETEvery tool call the agent makes is in the recorded calls. The agent does not have to make all of them.
SUPERSETThe agent makes at least all the recorded tool calls. Extra calls are allowed.
tip

Consider lowering the Minimum Pass Rate below 100%. Agent responses are non-deterministic, so a small amount of run-to-run variation is expected even when the agent is behaving correctly. A threshold around 80–90% tolerates that variance while still catching real regressions.

Save the evaluation​

Click Save. The evaluation opens in the visual designer as a single AI evaluation node that shows the template and the target agent, and it appears under evaluations in the Test Explorer. To change the template settings later, click Configure.

Visual designer showing the evaluateMathTutorAgentToolTrajectory evaluation as an AI evaluation node for the Tool Trajectory template with mathTutorAgent as the target agent.Visual designer showing the evaluateMathTutorAgentToolTrajectory evaluation as an AI evaluation node for the Tool Trajectory template with mathTutorAgent as the target agent.

The evaluation is now ready to run.

What's next​