Microsoft AI-300 Practice Exam

Microsoft Machine Learning Operations Engineer AI-300

The Microsoft AI-300 exam, Operationalizing Machine Learning and Generative AI Solutions, earns the Machine Learning Operations Engineer Associate certification. It validates the skills to run MLOps and GenAIOps on Azure with Azure Machine Learning and Microsoft Foundry. It is weighted across five domains: MLOps infrastructure at 15 to 20 percent, machine learning model lifecycle and operations at 25 to 30 percent, GenAIOps infrastructure at 20 to 25 percent, generative AI quality assurance and observability at 10 to 15 percent, and generative AI optimization at 10 to 15 percent. This practice exam mirrors that scope with single-answer and multiple-answer questions and drag-and-drop items, each with a worked explanation.

Question bank updated : questions, answers, explanations and chapters.

Certification Overview

  • Exam name: AI-300
  • Vendor: Microsoft
  • Exam code: AI-300
  • Duration: 100 minutes
  • Total questions: about 50
  • Official passing score: 700 on a scale of 1 to 1,000 (source)
  • Our practice exam pass mark: 70%

Who Should Take This Exam?

MLOps Engineer, AI Engineer, Machine Learning Engineer, Data Scientist, GenAIOps Engineer, DevOps Engineer moving into AI, Cloud AI Developer, Platform Engineer

Prerequisites

No formal prerequisite. Microsoft expects a data science background with Python, an entry-level understanding of DevOps practices such as GitHub Actions and CLIs, and experience with Azure Machine Learning, Foundry and Bicep.

Topics Covered

  • Design and implement an MLOps infrastructure
  • Implement machine learning model lifecycle and operations
  • Design and implement a GenAIOps infrastructure
  • Implement generative AI quality assurance and observability
  • Optimize generative AI systems and model performance

Question Types

  • Multiple Choice (Single Answer)
  • Multiple Choice (Multiple Answers)
  • Drag and Drop

AI-300 Practice Questions

Our question bank contains 650+ practice questions for this certification. Sample questions from each exam chapter. Expand a question to see the answer choices. With full access, you get unlimited practice exams with randomised questions from our full question bank.

Design and implement an MLOps infrastructure

Which Azure resource does an Azure Machine Learning workspace use to hold the secrets that its datastores and connections depend on?
  • A. Azure Storage account
  • B. Azure Container Registry
  • C. Application Insights
  • D. Azure Key Vault Correct answer

Option D is correct because an Azure Machine Learning workspace is created with an associated Azure Key Vault that stores the secrets behind datastores and connections. The storage account holds data and artifacts, the container registry holds images, and Application Insights collects telemetry, so none of them store secrets.

Data scientists leave compute instances running overnight and the bill keeps growing. Their working hours vary from day to day, so a fixed stop time would interrupt people mid-session. What should the engineer configure on the instances?
  • A. Idle shutdown after 60 minutes of inactivity Correct answer
  • B. A compute cluster that replaces the instances with min_instances 0 and a scale-down delay of 3600 seconds
  • C. A lower vCPU quota for the instance's VM family in the subscription
  • D. A daily schedule that stops each instance at 19:00

Option A is correct because idle shutdown stops a compute instance after a set period of inactivity, which suits variable working hours without cutting off an active session. Option D uses a fixed stop time that would interrupt late sessions, option C only caps quota and does not stop idle instances, and option B replaces instances with a cluster rather than configuring them.

Which built-in Azure role lets a data scientist submit jobs and create assets in a workspace without permission to create or delete the workspace itself?
  • A. Reader
  • B. Contributor
  • C. AzureML Compute Operator
  • D. AzureML Data Scientist Correct answer

Option D is correct because AzureML Data Scientist allows submitting jobs and creating assets in a workspace but does not allow creating or deleting the workspace. Contributor can manage the workspace resource itself, Reader is read-only, and AzureML Compute Operator only manages compute.

A platform engineer runs az ml workspace create and points the workspace at an existing storage account to serve as its default storage. The deployment is rejected because of the account's configuration. Which TWO settings of that storage account explain the rejection? (Choose two.)
  • A. General purpose v2 account kind
  • B. Locally redundant storage as the replication option
  • C. Hierarchical namespace enabled for Data Lake Storage Gen2 Correct answer
  • D. Hot as the default access tier for blobs
  • E. Premium performance tier Correct answer

Options C and E are correct because the default storage account of a workspace can't have a hierarchical namespace (Data Lake Storage Gen2) and can't be a premium account; both are supported only on non-default storage accounts. General purpose v2, locally redundant replication and the Hot access tier are all accepted for default storage, so A, B and D don't explain the rejection.

Implement machine learning model lifecycle and operations

An engineer defines an automated ML classification job in CLI v2 with AUC_weighted as the primary metric. The job should end as soon as any trial scores 0.95, instead of running all 60 trials. Which limits property delivers this?
  • A. exit_score: 0.95 Correct answer
  • B. enable_early_termination: true
  • C. trial_timeout_minutes: 20
  • D. max_concurrent_trials: 1

Option A is correct because the limits section of an automated ML job in CLI v2 accepts exit_score, which stops the experiment once any trial reaches that primary-metric value. enable_early_termination only cancels poorly performing runs, trial_timeout_minutes caps each trial's duration, and max_concurrent_trials only controls parallelism, so none of them end the job at a target score.

A sweep job tunes a gradient-boosting trainer on a GPU cluster. The search space gives learning_rate a loguniform range and max_depth a choice from 4 to 10. To control cost, the engineer wants trials that trail the best one cancelled while the sweep is running. Which sampling algorithm and early termination policy should the job use?
  • A. Random sampling with a bandit policy that uses slack_factor Correct answer
  • B. Bayesian sampling with a median stopping policy
  • C. Grid sampling with a truncation selection policy
  • D. Bayesian sampling with a bandit policy that uses slack_amount

Option A is correct because a bandit policy with slack_factor cancels trials whose metric falls outside the allowed ratio of the best trial, and it works with random sampling. Bayesian sampling does not support early termination policies, which rules out options B and D, and grid sampling does not suit a loguniform range, which rules out C.

In a CLI v2 job YAML, which top-level property holds the line python train.py --data ${{inputs.training_data}} --epochs 20?
  • A. environment
  • B. code
  • C. resources
  • D. command Correct answer

Option D is correct because the command property of a command job YAML holds the line that runs, including ${{inputs.*}} placeholders. The code property points to the source folder, environment defines the runtime image, and resources sets the instance type and count.

A training script runs as a command job. It must record the batch size so that it appears with the job's parameters, and record the final test accuracy as a number that can be charted on the job's Metrics tab. Which two calls should the script make? (Choose two.)
  • A. mlflow.log_param("batch_size", batch_size) Correct answer
  • B. mlflow.log_metric("test_accuracy", test_acc) Correct answer
  • C. mlflow.log_artifact("metrics.json")
  • D. mlflow.set_tag("batch_size", str(batch_size))
  • E. mlflow.log_text(str(test_acc), "test_accuracy.txt")

Options A and B are correct because mlflow.log_param records a one-time input such as batch_size under the job's parameters, and mlflow.log_metric records a numeric value that Azure Machine Learning can chart on the Metrics tab. Option C stores a file as an artifact, option D sets a tag rather than a parameter, and option E stores text as a file, so none of them produce a chartable metric or a parameter entry.

Design and implement a GenAIOps infrastructure

An engineer authors a Bicep template for a Microsoft Foundry resource that must accept child projects. Which TWO properties belong on the Microsoft.CognitiveServices/accounts resource? (Choose two.)
  • A. allowProjectManagement: true Correct answer
  • B. kind: 'OpenAI'
  • C. kind: 'AIServices' Correct answer
  • D. disableLocalAuth: true
  • E. publicNetworkAccess: 'Disabled'

Options A and C are correct because a Microsoft Foundry resource is a Microsoft.CognitiveServices/accounts resource of kind AIServices with allowProjectManagement set to true, which lets it hold child projects. Kind OpenAI (B) creates an Azure OpenAI resource without projects, and disableLocalAuth (D) and publicNetworkAccess (E) are security settings that do not enable project management.

A workspace for Azure Machine Learning was created in East US, and a data residency review now requires every ML asset to sit in West Europe. What should the engineer do?
  • A. Move the workspace to West Europe with Azure Resource Mover
  • B. Run az ml workspace update with a new location value
  • C. Create a storage account in West Europe and set it as the default datastore of the workspace
  • D. Deploy a new workspace in West Europe from the Bicep template and re-register the assets Correct answer

Option D is correct because an Azure Machine Learning workspace cannot be moved to another region, so the supported path is to deploy a new workspace in West Europe from the template and register the assets again. Azure Resource Mover does not cover workspaces, az ml workspace update cannot change the location, and a new default datastore moves only storage, not the workspace and its metadata.

A security standard requires every caller of a Foundry resource to authenticate with Microsoft Entra ID and the resource's API keys to stop working. Which change enforces this in the Bicep template?
  • A. Assign Cognitive Services User to each caller's identity
  • B. Rotate both keys on the account
  • C. Set disableLocalAuth to true on the account Correct answer
  • D. Set publicNetworkAccess to Disabled on the account

Option C is correct because setting disableLocalAuth to true on the account turns off key-based authentication, so only Microsoft Entra ID tokens are accepted. Rotating keys leaves them working, publicNetworkAccess controls network reachability rather than the authentication method, and the Cognitive Services User role grants rights but does not disable keys.

A GitHub Actions pipeline signs in as a service principal that holds Contributor on rg-genai-prod. A Bicep deployment creates a Foundry resource and a role assignment letting the project's identity read a storage account, and it fails at the role assignment with AuthorizationFailed. Security forbids Owner for pipelines. Which change fixes the deployment?
  • A. Assign Managed Identity Operator on the resource group
  • B. Assign Role Based Access Control Administrator on the resource group Correct answer
  • C. Assign Contributor on the subscription and re-run the deployment
  • D. Assign Owner to the pipeline identity at the resource group scope

Option B is correct because creating a role assignment needs the Microsoft.Authorization/roleAssignments/write permission, which Contributor does not hold. Role Based Access Control Administrator at the resource group scope adds exactly that without granting Owner. Managed Identity Operator only manages user-assigned identities, Contributor on the subscription still lacks the permission, and Owner is forbidden by the security rule.

Implement generative AI quality assurance and observability

An engineer's JSONL test set has the columns question, answer and passages, while GroundednessEvaluator expects query, response and context. Which parameter of evaluate() lets the engineer map the dataset columns onto the evaluator inputs?
  • A. azure_ai_project
  • B. evaluation_name
  • C. output_path
  • D. evaluator_config Correct answer

Option D is correct because evaluator_config on evaluate() takes a column_mapping per evaluator (or under default) that maps dataset columns such as question to the evaluator inputs such as query. The azure_ai_project parameter only logs results to a Foundry project, evaluation_name labels the run, and output_path writes a results file.

Which file format does evaluate() in the Azure AI Evaluation SDK read for a local test dataset?
  • A. MLTable (folder)
  • B. JSON Lines (.jsonl) Correct answer
  • C. Avro (.avro)
  • D. Parquet (.parquet)

Option B is correct because evaluate() accepts only JSON Lines data, one JSON object per row. MLTable folders, Avro and Parquet files are not read by the local evaluate() API.

Which built-in evaluator rates whether the claims in a response are supported by the retrieved context supplied with the query?
  • A. RetrievalEvaluator
  • B. GroundednessEvaluator Correct answer
  • C. RelevanceEvaluator
  • D. FluencyEvaluator

Option B is correct because GroundednessEvaluator checks whether the claims in the response are supported by the supplied context. RetrievalEvaluator scores the quality of the retrieved passages, RelevanceEvaluator scores how well the response answers the query, and FluencyEvaluator scores language quality.

A Foundry project owner builds an evaluation dataset from three weeks of logged chat conversations. Which TWO preparation steps should the engineer take? (Choose two.)
  • A. Keep the 50 most common questions from the logs
  • B. Replace customer names and account numbers in the text with placeholders Correct answer
  • C. Drop the query column to shorten the file
  • D. Convert the file to CSV because evaluate() reads that format
  • E. Remove duplicate conversations so repeated questions do not dominate the scores Correct answer

Options B and E are correct because customer names and account numbers should be replaced with placeholders before logs are shared as test data, and duplicate conversations should be removed so repeated questions do not dominate the scores. Keeping only the 50 most common questions narrows the dataset, the query column is required by evaluators, and evaluate() reads JSON Lines rather than CSV.

Optimize generative AI systems and model performance

Documents were indexed through an Azure AI Search skillset with the enrichment cache turned off. The Text Split skill used maximumPageLength 2000, and an MLOps engineer lowered it to 800 and ran the indexer. The chunks in the index did not change. What should the engineer do to re-chunk the existing documents?
  • A. Add a high-water mark change policy to the data source
  • B. Raise the indexer batchSize so more documents are read per run
  • C. Increase pageOverlapLength on the Text Split skill to 400
  • D. Reset the indexer and run it again to reprocess all documents Correct answer

Option D is correct because with the enrichment cache off, the indexer only reprocesses documents it considers changed, and editing a skill parameter does not mark existing documents as changed. Resetting the indexer clears its state so the next run re-reads every document and re-chunks it with maximumPageLength 800. A change policy (A) and batchSize (B) do not force reprocessing, and pageOverlapLength (C) only adds overlap between chunks.

Three chunk sizes were tested for a RAG index. The context budget is 4,000 tokens, and the release gate needs Retrieval and Groundedness averages of at least 4.2. Results (Retrieval, Groundedness, context tokens): 256-token chunks scored 4.1, 3.8, 1,900; 512-token chunks scored 4.4, 4.3, 3,100; 1,024-token chunks scored 4.5, 4.3, 6,200. Which configuration should the engineer deploy?
  • A. 512-token chunks Correct answer
  • B. 1,024-token chunks
  • C. 1,024-token chunks with the top 2 passages
  • D. 256-token chunks

Option A is correct because 512-token chunks are the only configuration that meets both Retrieval and Groundedness averages of 4.2 or more (4.4 and 4.3) and stay inside the 4,000-token budget at 3,100 tokens. The 256-token chunks miss the gate, and the 1,024-token chunks pass the quality gate but use 6,200 tokens, which exceeds the budget. Trimming the 1,024-token setup to the top 2 passages (C) is an untested configuration, so its scores cannot be assumed.

After a retailer swapped its embedding deployment for a Cohere Embed model from the Foundry catalog, retrieval quality dropped. The ingestion code and the query code both call the Cohere embed API route (/v1/embed) of the deployment with identical settings, yet the model documents separate input types for stored text and search text. What should the engineer configure?
  • A. Set the dimensions parameter to the vector field size on every embedding call
  • B. Set input_type to search_document for indexing and search_query for queries Correct answer
  • C. Set encoding_format to base64 on query calls and float on indexing calls
  • D. Set truncate to NONE so long chunks are rejected at indexing time

Option B is correct because the Cohere embed API takes an input_type parameter, and search_document is meant for text that is stored in the index while search_query is meant for the text a user searches with. Using one type for both degrades retrieval quality. The dimensions parameter (A), encoding_format (C) and truncate (D) do not tell the model whether text is a stored document or a query.

Answers from a RAG assistant over product manuals often fail because retrieved chunks start or end halfway through a procedure, so the model sees only some of the steps. Which two changes to the indexing pipeline reduce this? (Choose two.)
  • A. Change the vector field's similarity metric from cosine to dotProduct
  • B. Set pageOverlapLength on the Text Split skill Correct answer
  • C. Split on section headings and paragraph breaks instead of fixed token counts Correct answer
  • D. Increase k on the vector query from 5 to 50
  • E. Raise efSearch in the HNSW parameters of the vector profile

Options B and C are correct because a chunk that starts or ends mid-procedure comes from splitting at fixed positions: pageOverlapLength on the Text Split skill repeats text across neighbouring chunks, and splitting on headings and paragraph breaks keeps each procedure together. Options A, D and E tune how vectors are compared or searched, so they change which chunks are found, not where a chunk begins and ends.

Free Study Guide

Read the free Microsoft AI-300 study guide: every exam topic explained in plain English, with diagrams, exam tips and the mistakes to avoid.

More Microsoft Practice Exams

All Microsoft practice exams →

Practise with realistic mock exams to prepare for your Microsoft certification.