Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.You have an Azure Machine Learning workspace. You connect to a terminal session from the Notebooks page in Azure Machine Learning studio.You plan to add a new Jupyter kernel that will be accessible from the same terminal session.You need to perform the task that must be completed before you can add the new kernel.Solution: Create an environment.Does the solution meet the goal?
Answer(s): A
Correct: * Create an environment.Incorrect: * Delete the Python 3.6 - AzureML kernel. * Delete the Python 3.8 - AzureML kernel.Note: Before you can add a new Jupyter kernel on an Azure Machine Learning compute instance terminal, you must create a Conda environment.Required Workflow To officially provision and expose the new kernel to your Azure Machine Learning studio Notebooks, you need to execute the following full process from your terminal session: 1. Create the environment: Provision a new isolated environment (e.g., using conda create -n newenv python=3.10). 2. Activate the environment: Run conda activate newenv. 3. Install dependencies: Add the required ipykernel package using conda install ipykernel or pip install ipykernel. 4. Register the kernel: Bind the new environment configuration to the global Jupyter directory by running: python -m ipykernel install --user --name newenv --display-name "My New Kernel"
https://docs.azure.cn/en-us/machine-learning/how-to-access-terminal
HOTSPOT (Drag and Drop is not supported)A biomedical research company plans to enroll people in an experimental medical treatment trial.You create and train a binary classification model to support selection and admission of patients to the trial.The model includes the following features: Age, Gender, and Ethnicity.The model returns different performance metrics for people from different ethnic groups.You need to use Fairlearn to mitigate and minimize disparities for each category in the Ethnicity feature.Which technique and constraint should you use? To answer, select the appropriate options in the answer area.Note: Each correct selection is worth one point.Hot Area:
Box 1: Grid search To minimize disparities in a binary classification model across the categories of a sensitive feature (such as Ethnicity), the best approach within the Azure Machine Learning and Fairlearn framework is to use GridSearch combined with a Demographic Parity constraint.Technique: Grid Search (fairlearn.reductions.GridSearch) This is a reduction-based, in-processing technique. It takes your standard estimator (e.g., a classification algorithm) and optimizes it across a grid of systematically reweighted training datasets.It generates multiple candidate models, allowing you to select the model that provides the best trade-off between predictive accuracy and fairness metrics.Box 2: Demographic Parity Constraint: Demographic Parity (DemographicParity) This constraint ensures selection-rate equity.It forces the model's positive outcome prediction (e.g., admission to the medical trial) to be statistically independent of the sensitive attribute.As a result, the probability of being selected is balanced evenly across all ethnic groups.
https://fairlearn.org/v0.6.2/user_guide/mitigation.html
You are authoring a notebook in Azure Machine Learning studio.You must install packages from the notebook into the currently running kernel. The installation must be limited to the currently running kernel only.You need to install the packages.Which magic function should you use?
Answer(s): D
To target and install Python packages into the currently running kernel only, you should use the %pip line magic function.Kernel Isolation: Unlike using the shell command !pip install, which installs the package into the underlying compute instance's base environment, the %pip magic explicitly targets the specific Python executable assigned to your active notebook kernel.No Restart Needed: It automatically syncs the newly installed packages with the current session so you can import them immediately without restarting the kernel.Example Usage Simply type and run the following python line in a notebook cell:%pip install <package_name>
https://learn.microsoft.com/en-us/answers/questions/1921271/i-have-a-new-compute-instance-that-has-python3-8-a
You create a workspace by using Azure Machine Learning Studio.You must run a Python SDK v2 notebook in the workspace by using Azure Machine Learning Studio.You need to reset the state of the notebook.Which three actions should you use? Each correct answer presents a complete solution.Note: Each correct selection is worth one point.
Answer(s): B,C,D
To reset the state of a Python SDK v2 notebook in Azure Machine Learning Studio, you can perform any of the following three individual actions: Stop the current kernel Reset the compute instance Change the current kernelEach of these steps acts as a standalone solution to clear the current runtime memory, variables, and overall execution state of your notebook.
https://learn.microsoft.com/en-us/azure/machine-learning/how-to-run-jupyter-notebooks
A data science team plans to evaluate multiple hyperparameter values automatically while training a model in Azure Machine Learning.The tuning process must run multiple training trials without manually modifying the training script for each run.You need to automate hyperparameter tuning for the training job.What should you do?
To best automate hyperparameter tuning in Azure Machine Learning, you should create a Sweep Job (in SDK v2) or a HyperDrive experiment (in SDK v1).This creates a tuning job that automatically launches multiple training trials (child runs) using your single base training script without requiring manual code modifications for each run.Key Components to Automate the Job To set up this job successfully using the Azure Machine Learning Python SDK v2, you will define: Parameterized Training Script: Write your code to accept hyperparameters as command-line arguments (e.g., using Python's argparse), allowing the tuning job to pass different values to each trial.Search Space: Define the range or specific discrete/continuous choices for the values you want to test (e.g., learning rates, batch sizes).Sampling Algorithm: Choose how Azure ML should navigate your search space. Options include Random sampling, Grid sampling (testing every possible combination), or Bayesian sampling (using previous trial results to pick the next best values).Primary Metric: Specify the performance metric your script logs (like accuracy or loss) so Azure ML knows which target to optimize.Early Termination Policy: Optional policy (like a Bandit Policy) to automatically cancel poorly performing trials early, saving you compute time and cost.
https://learn.microsoft.com/en-us/python/api/azureml-train-core/azureml.train.hyperdrive
DRAG DROP (Drag and Drop is not supported)An organization is deploying generative AI solutions by using Microsoft Foundry to support multiple production workloads.The organization has the following workload requirements:-One workload must be real-time, latency-sensitive, and have predictable global usage patterns that demand consistent performance.-One workload must have variable performance and be optimized for cost-efficient operation.You need to select a global deployment type for each workload.Which type of deployment should you use for each workload requirement? To answer, move the appropriate deployment types to the correct requirements. You may use each deployment type once, more than once, or not at all. You may need to move the split bar between panes or scroll to view content.Note: Each correct selection is worth one point.Select and Place:
Box 1: Global Provisioned. Real-time, predictableThe best deployment type for this workload is Global Provisioned.Dedicated Resources for Real-Time Needs: This deployment option uses Provisioned Throughput Units (PTUs) to reserve dedicated compute capacity exclusively for your application. It eliminates "noisy neighbor" issues found in shared capacity options, ensuring the low and stable latency needed for interactive user experiences.Predictable Performance: Because the processing capacity is fixed and fully guaranteed, you avoid queueing delays and unexpected latency spikes, matching your strict requirement for consistent performance.Global Infrastructure Routing: It uses Microsoft’s global infrastructure to intelligently handle traffic without region-specific quota constraints. This provides maximum resilience and optimizes performance for predictable global usage patterns.Box 2: Global Standard Flexible, cost efficientThe Standard (or Global Standard) deployment type is best for this workload.Standard Deployment: This type utilizes a pay-per-token (consumption-based) billing model. It is specifically designed to handle variable or bursty traffic patterns cost-effectively. Because you only pay for the tokens you actively consume, you avoid the high fixed costs associated with unused capacity during low-demand periods.Performance Impact: Since standard deployments utilize multi-tenant shared infrastructure, they feature variable performance and latency fluctuations based on regional demand. This perfectly matches your requirement for a workload that must allow for variable performance.
https://learn.microsoft.com/en-us/azure/foundry/foundry-models/concepts/deployment-types
You create an Azure Machine Learning workspace. You train an MLflow-formatted regression model by using tabular structured data.You must use a Responsible AI dashboard to assess the model.You need to use the Azure Machine Learning studio UI to generate the Responsible AI dashboard.What should you do first?
The first step you must take is to register the model with the workspace.To access the no-code, guided wizard for generating a Responsible AI dashboard directly within the Azure Machine Learning studio UI, the trained model must first exist as a recognized asset inside your workspace's model registry.
https://learn.microsoft.com/en-us/azure/machine-learning/how-to-responsible-ai-dashboard
DRAG DROP (Drag and Drop is not supported)A customer-facing web application uses a foundational model deployed through Microsoft Foundry.A new model version must be introduced and validated without disrupting production traffic.You need to deploy the new version by using a safe promotion strategy.Which three actions should you perform in sequence? To answer, move the appropriate actions from the list of actions to the answer area and arrange them in the correct order.Select and Place:
To update the foundation model version safely in Microsoft Foundry without affecting live production traffic, you must implement a structured Blue-Green Deployment and continuous evaluation pipeline. This decouples the deployment of the new model from its public exposure, ensuring a zero-downtime transition.Here are the precise chronological steps you should take: 1. Disable Platform Auto-Upgrades [Skip] Before introducing any new updates, prevent the system from shifting beneath you. Pin Your Current Baseline: Modify your current deployment configurations to "Stay on this version" or "No Auto Upgrade". This ensures that Microsoft Foundry does not automatically update your production models to a new default version before you have validated it.Step 1: Deploy a new model version 2. Deploy the New Model Version in Isolation (Green Deployment) Deploy the updated model version as an entirely separate instance within the same endpoint.Create a Green Instance: Leave your original model (Blue) running at 100% traffic.Set Initial Traffic to Zero: Deploy the new model version (Green) to your Microsoft Foundry resource or online endpoint with a traffic weight of 0%.This provides a live, isolated endpoint for the new model version without routing customer traffic to it.Step 2: Validate the behavior of the new version. 3. Conduct Isolated Testing and Evaluations Validate the Green deployment's outputs against your original performance baselines.Run Evaluation Pipelines: Use Microsoft Foundry's built-in Evaluation tools or Prompt Flow to test the new model. Test against benchmark datasets to evaluate response quality, accuracy, and safety filters.Targeted Request Verification: Send targeted testing requests directly to the Green deployment using specific HTTP headers (e.g., azureml-model-deployment: green) to bypass global traffic routing rules.Step 3: Shift 100% of traffic to the new version 4. Implement Shadow Testing or Canary Routing Gradually expose the new model version to production traffic patterns.Canary Release / Traffic Splitting: Update your endpoint configurations to route a minimal portion (e.g., 90% Blue / 10% Green) of live customer requests to the new model.Shadow Mirroring (Optional): If supported by your API architecture, mirror 100% of live traffic to the Green deployment concurrently. Discard its responses to the user but log and evaluate how it handles real-world requests in real time.Incorrect: * Create an AI gateway route version Once the new model is deployed and vetted, you can then implement routing mechanisms (such as creating an AI gateway route version or configuring Azure API Management) to perform A/B testing, shadowing, or safe traffic shifting to production.
https://medium.com/@sridharcloud/azure-ai-foundry-your-gateway-to-enterprise-grade-ai-model-deployment-19ba74c81408
Post your Comments and Discuss Microsoft AI-300 exam prep with other Community members:
Our website is free, but we have to fight against AI bots and content theft. We're sorry for the inconvenience caused by these security measures. You can access the rest of the AI-300 content, but please register or login to continue.