Additional requirements depend on the selected evaluators. For example, a
textual similarity evaluator can require
ground_truth, groundedness can
require context when query and response are strings, and an agent
evaluator can require tool_definitions. For evaluator requirements, see
Built-in evaluators.
Evaluations based on existing traces, response IDs, or
generated synthetic queries
don’t require an input dataset.
Standard columns
The standard columns depend on whether the evaluation uses model or agent interaction data or conversation simulation.Model and agent evaluation columns
Use one interaction format for each test case: either themessages column or
the separate query and response columns.
Conversation simulation columns
Messages format
Themessages column is an array. Each message identifies a role and its
content. A row can contain one exchange or a complete multi-turn conversation.
The following running example contains a short account-support interaction:
assistant role. For a model or agent target, end the messages array with a
user message. Foundry sends the messages to the target, generates the next
assistant response, and evaluates that response.
For turn-level evaluation, earlier messages provide context for the response
being scored. In this example, an evaluator can score the final
password-reset guidance by using the preceding messages as context. For
conversation-level evaluation, an evaluator scores the complete interaction.
The evaluation_level setting on the run selects the scoring level; the
messages row stays the same.
For more information, see
Choose an evaluation level.
Message structure
Each message has arole and content. The content value can be a string
or an array of typed content items. Tool-result messages also use
tool_call_id to identify the corresponding tool call.
Text messages align with the OpenAI Responses message structure.
Input messages can use input_text, and assistant output can use
output_text. Foundry evaluation also supports the text shorthand and
normalized tool_call and tool_result content items shown in this article.
Messages with content arrays
Thecontent value can also be an array of typed content items instead of a
string. This example uses the Responses API input_text and output_text
types:
Messages with tool calls
This variation of the running example includes a tool call and its result:Evaluator-specific columns
Most evaluations need only the primary interaction column. Add supporting columns when a selected evaluator requires them.Ground truth
ground_truth is a string containing the expected or reference answer.
Include it when an evaluator compares the model or agent output with a known
answer.
Tool definitions
tool_definitions describes the tools available to the agent. The messages
array shows what the agent called. tool_definitions supplies the names,
descriptions, and parameter schemas of all tools that the agent could use.
Include this column when an evaluator needs to compare tool behavior with the
tools that were available.
Context
context contains supporting information used to evaluate a response. This
column is mainly useful with string query and response values when the
needed information isn’t already represented in message history. For details
about this representation, see
Separate query and response format.
For example, a groundedness evaluator can use context as the source material
that should support the response:
Conversation simulation
A simulation seed, also called a test case scenario, describes a situation that the simulator should act out as the user.test_case_description is the
only required column. desired_num_turns is optional simulation guidance.
The following seed continues the account sign-in example:
Separate query and response format
Some evaluators and workflows use separatequery and response columns.
This format remains supported. Both columns can contain strings or message
arrays that use the same structure as messages.
Use string values for a simple single-turn test case that doesn’t need
conversation history or tool-call details:
query is a message array, it can include system instructions, previous
turns, tool calls, and tool results. Evaluators use this history as context
when scoring response.
query and response values need separate supporting
information, add a context column.
If an evaluation run calls a model or agent target, Foundry generates a new
response for each input. Any response already stored in the row is ignored.
CSV is also supported for simple string-based query and response rows. See
Evaluate a CSV dataset.
When you need a data mapping
You can omitdata_mapping when a compatible evaluator uses the standard
columns in your dataset. Add a mapping in the following cases:
- Your dataset uses a different name, such as
questioninstead ofquery. - A model or agent target generates text at run time and the evaluator
requires a text response. For example, Coherence requires the response to
map from
{{sample.output_text}}. - An agent target generates structured output and the evaluator requires tool
calls or other structured items. For example, Task Adherence requires the
response to map from
{{sample.output_items}}. - A CSV file uses nonstandard column headers.
{{item.*}} and {{sample.*}} mapping syntax with runnable examples, see
Set up evaluators and data mappings.
To choose an overall workflow, see
Run evaluations from the SDK.