AI-901: how to implement data annotation pipelines in Microsoft Foundry
I will teach how to implement data annotation pipelines in Microsoft Foundry, a practical skill useful for the AI-901. Data annotation is critical to train high-quality AI models and, in the Foundry context, enables managing, versioning and automating labels prior to training.
What you need to know
Data annotation refers to the process of adding metadata (labels) to files (images, text, audio) so that Machine Learning models can learn to associate inputs with outputs. In Microsoft Foundry, the goal is to create a pipeline that: ingests raw data, applies preprocessing, exposes annotation tasks (manual or model-assisted), validates and stores annotations in OneLake or in a versioned table.
Practical example: imagine you have thousands of medical images and want to annotate regions of interest (bounding boxes) to train a detection model. An annotation pipeline in Foundry automates the ingestion of images, creates annotation jobs for human annotators, applies suggestion models to speed up the work and writes the result to a versioned layer for training.
How it works (step-by-step/main components)
A typical annotation pipeline in Foundry involves these components and steps:
- Ingestion: you upload the raw files to OneLake or registries supported by Foundry. Ensuring minimal metadata (ID, date, source) facilitates traceability.
- Preprocessing: scripts to normalize formats, resize images, clean text, extract audio segments. Usually implemented in Python/Notebooks in the Foundry environment.
- Creating annotation tasks: configure the type of annotation (bounding box, segmentation, classification, entity annotation), rules and instructions. In Foundry, you can define annotation schemas and templates that annotators will see.
- Manual and assisted annotation: annotators perform the work; optionally, you use a suggestion model (a preliminary version of the model or an LLM/Vision model) to pre-annotate and reduce human effort.
- Validation and quality control: workflows for cross-review, audits or statistical sampling. Implement simple metrics (accuracy, IoU for bounding boxes) and approval rules.
- Storage and versioning: store annotations in structured format (JSON, Parquet) and create dataset versions for training/validation/testing. OneLake and Foundry’s versioning capabilities are useful here.
- Integration with training: expose the annotated dataset to training pipelines (e.g. training tasks in Foundry), ensuring metadata and splits are correct.
# Exemplo simples (pseudo-Python) de pré-processamento de imagens antes de criar tarefas
from PIL import Image
import json
def preprocess_image(input_path, output_path, size=(512,512)):
img = Image.open(input_path).convert('RGB')
img = img.resize(size)
img.save(output_path, format='JPEG')
# Gerar metadados para a tarefa de anotação
metadata = {
'id': 'img_0001',
'path': '/onelake/ingest/images/img_0001.jpg',
'source': 'scannerA',
'ingest_date': '2026-10-14'
}
with open('img_0001_meta.json','w') as f:
json.dump(metadata, f)
Practical note: in Foundry, many of these actions are encapsulated in Recipes (or Flows) and integrated Notebooks. Try to use available orchestration tools to automate task creation and versioning.
In practice — operational tips
To make an annotation pipeline efficient in Foundry follow these recommendations:
- Provide clear annotation instructions and visual examples to reduce ambiguities between annotators.
- Use stratified sampling when creating annotation batches to ensure diversity in the initially annotated data.
- Apply suggestion models for pre-annotation (active learning) and focus human effort on uncertain samples.
- Record all metadata — who annotated, when, time spent and a confidence — for later quality analysis.
- Implement cross-reviews (two-pass) in critical cases: one annotator performs the work and another validates.
Common mistakes
2–3 typical pitfalls in this competency:
- Not versioning annotations: overwriting annotations without versioning prevents tracking changes and reproducing previous trainings.
- Vague annotation instructions: without clear definitions, annotators diverge, generating noise and degrading model quality.
- Ignoring balancing and representativeness: annotating only easy examples or a dominant class creates biased models.
How to practice
To prepare for AI-901, practice implementing a simple pipeline in Foundry: ingest a small set of images/text, create annotation tasks, use a simple model for suggestions and validate annotations; export the versioned dataset and integrate it into a training pipeline. For assessing your official knowledge, use Microsoft’s OFFICIAL free Practice Assessment and consult Microsoft’s free official study guide for AI-901 — both are free and recommended resources to align with the exam. Do not use dumps or unofficial questions.
In summary
- Data annotation in Foundry organizes the creation, management and versioning of labels for model training.
- A typical pipeline includes ingestion, preprocessing, task creation, annotation (manual/assisted), validation and versioning.
- Best practices: clear instructions, suggestion models, metadata recording and cross-review.
- Practice with small projects in Foundry and use Microsoft’s official resources (Practice Assessment and study guide) to prepare.