AI-300
Free AI-300 practice questions
10 questions from our AI-300 practice tests, each with the correct answer and a written explanation. Read them with the answers shown, or switch to quiz mode and answer first.
Question 1 of 10, Design and implement an MLOps infrastructure
A regulated company requires that its Azure Machine Learning workspace can reach only approved destinations, such as specific PyPI mirrors and storage accounts, while all managed compute stays in a Microsoft-managed network. Which configuration meets the requirement with the LEAST operational overhead?
- ADeploy compute into a customer-managed virtual network and route all egress through a self-managed Azure Firewall with application rules
- BDisable public network access on the workspace and allow outbound traffic only to the AzureMachineLearning service tag
- CEnable the workspace managed virtual network in Allow Internet Outbound mode and block unapproved sites with network security groups
- DEnable the workspace managed virtual network in Allow Only Approved Outbound mode and add FQDN and private endpoint outbound rules Correct answer
Answer and explanation: Allow Only Approved Outbound mode keeps compute inside the managed VNet and blocks egress except for the outbound rules you define, and Microsoft manages the underlying network and firewall. Allow Internet Outbound mode permits all egress, and you cannot attach your own NSGs to the managed network. A customer-managed VNet with your own firewall works but carries the most operational overhead. Disabling public network access controls inbound access to the workspace, not outbound access from compute.
Question 2 of 10, Design and implement an MLOps infrastructure
Your team stores training data in Azure Data Lake Storage Gen2. Security requires that no storage account keys or SAS tokens are saved in the Azure Machine Learning workspace, and each data scientist's own permissions on the data lake must govern access during interactive work. How should you configure the datastore?
- ACreate the datastore with a user delegation SAS token that is regenerated weekly by an automation runbook
- BCreate the datastore without credentials so that identity-based access uses the caller's Microsoft Entra identity Correct answer
- CCreate the datastore with a service principal secret and grant that principal Storage Blob Data Reader on the account
- DCreate the datastore with an account key and restrict network access to the workspace's managed virtual network
Answer and explanation: A credential-less datastore uses identity-based data access, so the signed-in user's (or the compute's managed identity's) RBAC on the storage account determines access and no secret is stored. A service principal secret is a stored credential and gives everyone the same principal's permissions. An account key is a stored secret regardless of network restrictions. A SAS token is also a stored credential and does not reflect each user's permissions.
Question 3 of 10, Implement machine learning model lifecycle and operations
A retailer runs a managed online endpoint with deployment blue serving 100% of traffic. A new deployment named green must be validated against real production requests without returning green's responses to callers, and then gradually receive live traffic. What should you do FIRST after creating green?
- ACreate a second endpoint for green and duplicate requests in the client app
- BMirror a small percentage of traffic to green while blue keeps all live traffic Correct answer
- CSet live traffic to 10% on green and 90% on blue, then compare both deployments' metrics
- DInvoke the endpoint with the azureml-model-deployment header set to green
Answer and explanation: Mirrored (shadow) traffic copies a percentage of live requests to green while callers still receive blue's responses, which validates green safely before shifting live traffic. Allocating 10% live traffic returns green's responses to real users before validation. Invoking green directly with the deployment header tests only the requests you send, not production traffic. A separate endpoint with client-side duplication adds application changes and overhead that mirroring avoids.
Question 4 of 10, Implement machine learning model lifecycle and operations
A data scientist trains a scikit-learn model in a command job on Azure Machine Learning and wants parameters, metrics, and the model artifact logged with minimal code changes. The workspace is already the MLflow tracking server for the job. What should the training script call?
- Amlflow.autolog() before the model is fitted Correct answer
- Bmlflow.start_run() inside a loop for every training epoch
- Cmlflow.set_tracking_uri() with the workspace's storage account URL
- Dmlflow.register_model() before the estimator is created
Answer and explanation: mlflow.autolog enables automatic logging of parameters, metrics, and the model for supported frameworks such as scikit-learn. Jobs running in Azure Machine Learning are already configured with the workspace tracking URI, and the storage account URL is not a tracking URI. Starting a run per epoch fragments the experiment into many runs. Registering a model requires an existing logged model, so calling it before training fails.
Question 5 of 10, Implement machine learning model lifecycle and operations
You run an Azure Machine Learning sweep job with Bayesian sampling over learning rate and batch size. You add a bandit early termination policy to stop poorly performing trials, but job submission fails. What is the cause?
- ABayesian sampling does not support early termination policies Correct answer
- BBandit policies need the primary metric to be logged with the goal of minimize
- CEarly termination requires max_concurrent_trials to equal max_total_trials
- DBandit policies require a grid sampling algorithm with discrete choices
Answer and explanation: Bayesian sampling chooses new samples based on previous trial results and does not support early termination, so the policy must be removed or the sampling changed to random or grid. Bandit policies work with random and grid sampling, not only grid. Concurrency settings are unrelated to termination policies. A bandit policy works with either a maximize or minimize goal.
Question 6 of 10, Design and implement a GenAIOps infrastructure
A company deploys GPT-4.1 in Microsoft Foundry for an internal chatbot. Traffic is moderate and unpredictable, and the data can be processed in any Azure region worldwide. Which deployment type is the MOST cost-effective choice that offers the highest default quota?
- AData Zone Provisioned
- BRegional Provisioned
- CGlobal Standard Correct answer
- DGlobal Batch
Answer and explanation: Global Standard is pay-per-token, routes requests across Azure's global capacity, and typically has the highest default quota, which suits variable traffic with no data residency constraint. Provisioned deployments reserve throughput and are billed for capacity whether used or not, which is wasteful for unpredictable moderate load. Global Batch is for asynchronous jobs with a 24-hour target turnaround, not an interactive chatbot.
Question 7 of 10, Design and implement a GenAIOps infrastructure
An agent in a Foundry project uses Azure AI Search as its knowledge source. The project calls Search by using its managed identity, and key access to the Search service is disabled. Queries fail with 403 errors. Which role assignment fixes the issue while following least privilege?
- ASearch Service Contributor for the project's managed identity on the search service
- BSearch Index Data Reader for the project's managed identity on the search service Correct answer
- CSearch Index Data Contributor for each developer's user account on the search service
- DCognitive Services User for the search service's managed identity on the Foundry resource
Answer and explanation: Querying an index with Entra authentication needs a data-plane role, and Search Index Data Reader grants read-only query access to the calling identity. Search Service Contributor manages the service and index definitions but does not grant data-plane query access. Developer user accounts are not the identity making the calls. A role for the search service's identity on Foundry is the reverse direction of the failing call.
Question 8 of 10, Design and implement a GenAIOps infrastructure
A customer-support application processes about 900 million tokens per day with steady traffic and strict latency expectations during business hours. Throttling on the current pay-as-you-go deployment causes intermittent 429 errors. What should you recommend?
- ACreate several Standard deployments in one region and round-robin calls between them
- BKeep the Standard deployment and add exponential retry with a longer client timeout
- CEnable a private endpoint and allow only the developers' subnet to reach the resource
- DDisable local authentication and grant developers an inference role Correct answer
Answer and explanation: Provisioned throughput units give reserved, predictable capacity and latency for high, steady volume, and reservations reduce the cost of that capacity. Retries hide but do not remove throttling and add latency. Batch deployments are asynchronous and unsuitable for interactive support. Standard deployments in the same region share the same regional quota, so splitting them does not add capacity.
Question 9 of 10, Implement generative AI quality assurance and observability
Finance asks for a daily chart of prompt and completion tokens consumed by each Azure OpenAI deployment in a Foundry resource. Which data source provides this with the LEAST effort?
- AThe Processed Prompt Tokens and Generated Completion Tokens metrics split by deployment Correct answer
- BApplication Insights traces exported to a storage account and parsed by a nightly Azure Function
- CCustom logging in the application that writes the usage field of every response to a SQL table
- DThe Cost Management export filtered by meter each day
Answer and explanation: Azure Monitor platform metrics for the resource already include prompt and completion token counts that can be split by model deployment name and charted without extra work. Parsing exported traces requires custom code. Cost Management shows charges, not token counts per deployment, and arrives with a delay. Custom logging works but adds development effort.
Question 10 of 10, Optimize generative AI systems and model performance
A RAG solution uses text-embedding-3-large with 3,072 dimensions in Azure AI Search. Index storage costs are too high, and the team accepts a small loss of recall that it can partly recover at query time. Which combination is MOST appropriate?
- AReduce dimensions with the model's dimensions parameter and use scalar quantization with rescoring Correct answer
- BSwitch to text-embedding-ada-002 and rebuild the index with an exhaustive KNN algorithm configuration
- CStore vectors as retrievable and stored fields so that they are returned with every search result
- DKeep full dimensions and move the search service to a higher tier with more partitions for storage
Answer and explanation: text-embedding-3 models support truncating output dimensions, and scalar quantization compresses vectors, while rescoring with oversampling recovers some of the lost precision. ada-002 is an older model with fixed dimensions, and exhaustive KNN increases query cost rather than reducing storage. A higher tier adds capacity but increases cost. Making vectors retrievable stores an additional copy and increases storage.