# How do I map dataset columns and generated responses to Foundry evaluator inputs?

Exam: AI-300 — Operationalizing Machine Learning and Generative AI Solutions
Knowledge domain: Implement generative AI quality assurance and observability
Updated: 2026-11-25T04:35:45.761053+00:00
HTML: https://learningpathx.com/faq/AI-300/ai300-foundry-evaluation-data-mapping.html

## Also asked as

- How do I bind dataset fields and target responses to Foundry evaluator inputs?
- When and how should I use data\_mapping to supply a Foundry evaluator's inputs?

In Microsoft Foundry cloud evaluations, map nonstandard dataset columns to the evaluator inputs they supply. For a run that invokes a target, bind the generated response in the representation the evaluator expects. A compatible evaluator can omit `data_mapping` when the dataset already uses its standard columns.

| Evaluator input | Example for a stored library-policy answer |
| --- | --- |
| `query` | `{{item.question}}` |
| `response` | `{{item.answer}}` |
| `context` | `{{item.passage}}` |
| `ground_truth` | `{{item.reference}}` |

A model or agent run generates new output. The Foundry cloud guide uses `{{sample.output_text}}` for an evaluator requiring text such as Coherence and `{{sample.output_items}}` for a structured response used by checks such as Task Adherence. Keep the question, reference, and actual context tied to the case. If a reference is accidentally bound to `response`, fix the binding and rerun affected cases even if prior scores looked plausible.

These expressions apply to the documented Foundry cloud workflow. The separate Azure AI Evaluation Python SDK `evaluate()` uses its own configuration and expression syntax. Verify the contract and inspect a few actual cases before expanding the run.

**Microsoft Learn**

* [Evaluation dataset schema in Microsoft Foundry](https://learn.microsoft.com/en-us/azure/foundry/observability/how-to/evaluation-dataset-schema)

Source: [AI-300: Preparing Evaluation Datasets and Field Mappings](https://learningpathx.com/news/ai-300-preparing-evaluation-datasets-and-field-mappings.html)
