Microsoft certification · Exam AI-200

AI-200 Mock Exam

Developing AI Cloud Solutions on Azure

Free AI-200 questions on Topic 3, Standalone Questions Set, each with the answer and an explanation.

20 questions · 40 minutes · free, no sign-up

Topic 3, Standalone Questions Set questions

1–10 of 38 free
Question 1
You are developing several microservices to run on Azure Container Apps. External HTTP ingress traffic has been enabled for the Microservices.
A deployed microservice must be updated to allow users to test new features. You have the following requirements:

* Enable and maintain a single URL for the updated microservice to provide to test users.
* Update the microservice that corresponds to the current microservice version.
You need to configure Azure Container Apps.

Which features should you configure? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.
Show answerHide answer

Explanation



Explanation

- Revision Label: Azure Container Apps uses revisions to manage application deployments. To provide a single, static URL for test users to access new features, you must assign a revision label (e.g., "test") to the new revision. This creates a dedicated, stable Fully Qualified Domain Name (FQDN) that always routes traffic to that specific revision, regardless of how many times you update the container image or the revision itself.

- Revision mode: The requirement to "update the microservice that corresponds to the current microservice version" implies you are managing multiple versions. Revision mode determines how revisions are handled. By setting the revision mode to Single (as opposed to Multiple), you ensure that the application always routes 100% of traffic to the latest deployed revision, allowing you to systematically update the active version while managing test versions.

Why the Other Options Are Incorrect

- Container image: This specifies the actual code/application artifact to run. While you must update the image to deploy new features, changing the image alone does not guarantee a stable URL for testers or control how revisions are activated.

- Container registry: This is the storage location for your container images. It is an infrastructure setting and does not manage URLs or traffic routing.

- Revision label vs. Revision mode (Cross-check): You cannot use "Revision label" to activate the current version (labels are for routing specific traffic to specific URLs). You cannot use "Revision mode" to provide a single URL for testers, as the default application URL always points to the latest revision.

References
- Microsoft Learn: Revisions in Azure Container Apps
Question 2 Choose 1
A RAG application ' s retrieval step is returning documents that are topically related but not precisely relevant to the user ' s question. You need to improve retrieval precision without retraining any model. What should you do?
Show answerHide answer

Correct answer: B Enable semantic ranking (re-ranking) in Azure AI Search

Explanation

Explanation

In a Retrieval-Augmented Generation (RAG) architecture, standard vector search (or keyword search) often retrieves documents that are broadly related to the topic but may lack the precise contextual nuance required to answer the specific question.

Semantic ranking (re-ranking) in Azure AI Search solves this problem without retraining any models. It uses advanced language understanding models to re-evaluate the initial set of results (from vector or keyword search) and re-orders them based on how closely the actual meaning of the document passage matches the user's query intent. This significantly improves retrieval precision.

Why the Other Options Are Incorrect

- A. Increase the embedding model's dimensionality only: Changing embedding dimensions requires generating entirely new embeddings for the entire dataset using a different model. It does not inherently guarantee better precision for nuanced queries and violates the constraint of not retraining/changing models.

- C. Disable vector search and use only keyword search: Keyword search relies on exact lexical matching and often performs worse than vector search for semantic questions (e.g., failing to match synonyms). Disabling vector search would likely decrease overall retrieval quality.

- D. Reduce the number of indexed documents: This is a destructive approach. It arbitrarily reduces the knowledge base and risks removing the exact documents needed to answer the user's question, rather than improving the ranking of the retrieved results.

References
- Microsoft Learn: Semantic ranking in Azure AI Search (Explains how it improves precision by re-ranking results using language models).
Question 3
You have an Azure Service Bus namespace that contains a topic named Topic1.
You plan to create a subscription named Sub1 to Topic1. In Sub1, you plan to filter messages from Topic1 based on their system properties and apply an action that will annotate each filtered message.
You need to configure the filtering.
How should you configure the filtering? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.
Show answerHide answer

Explanation



Explanation

- Use the SQL type: Azure Service Bus supports three filter types: Boolean, Correlation, and SQL. Since the requirement states you need to filter based on system properties, a SQL filter is required. SQL filters allow you to write expressions (e.g., sys.Label = 'Important') that evaluate against both system properties (like sys.To, sys.CorrelationId) and custom user properties. Boolean filters only check for the existence of a specific label, and Correlation filters only match against a specific set of standard properties.

- Annotate the metadata of the original message: A Service Bus rule consists of a filter and an action. The action determines what happens to a message that meets the filter criteria. The option "Annotate the metadata of the original message" aligns with the requirement to "apply an action that will annotate each filtered message." (In Service Bus terminology, SQL filter actions can use SET to add or update user properties/metadata on the message without creating a copy).

Why the Other Options Are Incorrect

- Use the Boolean type: Boolean filters (e.g., TrueFilter or FalseFilter) simply evaluate to true or false and do not allow complex filtering based on specific system property values.

- Use the Correlation type: Correlation filters are optimized for matching a fixed set of properties (like CorrelationId or MessageId) but cannot evaluate complex expressions against arbitrary system properties.

- Copy a message and update its body: Service Bus filter actions operate on metadata/properties; they cannot modify the payload (body) of the message.

- Copy a message and annotate its metadata: Filter actions modify the message in-place as it is routed to the subscription; they do not create copies.

References
- Microsoft Learn: Topic filters and actions in Azure Service Bus
Question 4 Choose 1
You store embeddings in a property named embedding in an Azure Cosmos DB for NoSQL container.
You must construct a vector similarity query that orders documents by similarity to the input embedding and returns only the top five results. You need to construct the similarity query. What should you do?
Show answerHide answer

Correct answer: B Limit the number of results.

Explanation

Explanation

In Azure Cosmos DB for NoSQL, when executing a vector similarity search (using the VectorDistance function), the database calculates the distance between the input vector and the stored vectors, then sorts the results by that distance (using ORDER BY).

To satisfy the requirement of returning only the top five results, you must use the TOP clause in your SQL query (or use the limit parameter in the SDK/query definition). For example:
SELECT TOP 5 * FROM c ORDER BY VectorDistance(c.embedding, @inputVector)

Why the Other Options Are Incorrect

- A. Group by embedding value: GROUP BY is used to aggregate data (like calculating sums or averages). It does not sort results by vector similarity nor restrict the output to a specific number.

- C. Select distinct embedding: DISTINCT is used to remove duplicate values from the result set. It does not sort by similarity or limit the number of rows returned.

- D. Use offset pagination: Offset pagination (OFFSET n LIMIT m) is used to skip a specific number of rows and then return the next set. While you could technically use OFFSET 0 LIMIT 5, TOP 5 is the direct, correct, and most efficient way to specify "return only the top N results" in Cosmos DB without unnecessary pagination overhead.

References
- Microsoft Learn: Vector similarity search in Azure Cosmos DB for NoSQL (Details using VectorDistance with TOP N for top-k results).
Question 5 Choose 2
You are creating a hazard notification system that has a single signaling server which triggers audio and visual alarms to start and stop. You implement Azure Service Bus to publish alarms, each alarm controller uses Azure Service Bus to receive alarm signals as part of a transaction Alarm events must be recorded for audit purposes Each transaction record must include information about the alarm type that was activated. You need to implement a reply-trail auditing solution Which two actions should you perform? Each correct answer presents part of the solution. NOTE: Each correct selection is worth one point.
Show answerHide answer

Correct answer: A, F Assign the value of the hazard message SessionId property to the ReplyToSessionld property. Assign the value of the hazard message MessageId property to the CorrelationId property

Explanation

Explanation

To implement a reply-trail auditing solution in Azure Service Bus, you must link the initial request (the hazard alarm) to the subsequent audit record. The standard messaging pattern for this uses two specific properties:

- 1. MessageId to CorrelationId (Option F): When the signaling server publishes the hazard alarm, it populates the MessageId. When the alarm controller processes the message and creates the audit record, it must copy that original MessageId into the CorrelationId of the new audit message. This is the fundamental way Service Bus allows you to correlate a reply or follow-up message back to the original request for auditing purposes.

- 2. SessionId to ReplyToSessionId (Option A): Because alarm events are transactional and must be processed in order for a specific alarm, Sessions are likely being used. If the original hazard message uses a SessionId, the reply/audit message must route its response to the correct session. By setting the ReplyToSessionId on the original message, the receiving controller knows exactly which session to send the audit record back to, ensuring the audit trail is grouped correctly.

Why the Other Options Are Incorrect

- B, C, D, E (Manipulating SequenceNumber or DeliveryCount): Properties like SequenceNumber and DeliveryCount are read-only, system-generated properties. You cannot manually assign application-level values (like a MessageId or SessionId) to them.

- SequenceNumber: Assigned by Service Bus to uniquely order messages.
- DeliveryCount: Incremented by Service Bus every time a message is delivered to a receiver.

References
- Microsoft Learn: Message correlation in Azure Service Bus (Explains using CorrelationId to tie replies to requests).
Question 6 Choose 2
An ACA app processes messages from an Azure Storage queue.
The app must scale automatically based on messages in a specific Azure Storage queue by using a Kubernetes Event-driven Autoscaler (KEDA) custom scale rule. You need to configure the required scale rule values.
Which two values should you configure? Each correct answer presents part of the solution. Choose two.
NOTE: Each correct selection is worth one point.
Show answerHide answer

Correct answer: B, D Trigger type Queue name

Explanation

Explanation

To configure a KEDA (Kubernetes Event-driven Autoscaler) custom scale rule in Azure Container Apps to scale based on an Azure Storage queue, you must define the specific scaler and the target it should monitor.

- Trigger type (B): You must specify the type of scaler KEDA should use. In this case, the trigger type would be `azure-queue` (or `azure-storage-queue` depending on the specific KEDA metadata implementation). This tells the autoscaler what kind of external system it is monitoring.

- Queue name (D): Because the requirement specifies scaling based on messages in a specific Azure Storage queue, you must provide the queue's name in the scaler metadata so KEDA knows exactly which queue's length to evaluate.

Why the Other Options Are Incorrect

- A. Polling interval: While you can configure how often KEDA checks the queue, this is an optional tuning parameter, not a required definition of the scale rule itself.

- C. Maximum replicas: Maximum replicas is a core scaling boundary configured at the application level (or scale definition), but it is not part of the specific custom scale rule (which defines what to monitor). The question specifically asks for values to configure the custom scale rule.

References
- Microsoft Learn: Set scaling rules in Azure Container Apps (Details how `rules` require a `type` and `metadata` like `queueName`).
Question 7 Choose 3
You are using Azure Monitor Application Insights to collect dependency data.
You must be able to:
Correlate failed requests with dependency calls during the last hour.
Calculate the average dependency duration per operation.
You need to construct the KQL query by using the minimum number of statements.
Which three operators should you use? Each correct answer presents part of the solution.
Show answerHide answer

Correct answer: B, C, D summarize join where

Explanation

Explanation

To meet both requirements using the minimum number of statements, you need to correlate two separate telemetry tables (`requests` and `dependencies`) and perform an aggregation. Here is how the three operators accomplish this:

1. where (D): You must filter both datasets to the required time window. While the KQL query itself uses a `where` clause, the `requests` and `dependencies` tables also require filtering (e.g., `where success == false` for failed requests and `where timestamp > ago(1h)`).

2. join (C): To "correlate failed requests with dependency calls," you must combine the `requests` table with the `dependencies` table. The `join` operator is essential to link a failed request to its downstream dependency call using the `operation_Id` (or `Id`/`ParentId`).

3. summarize (B): To "calculate the average dependency duration per operation," you use the `summarize` operator to group the joined results by the operation name and compute the average duration (e.g., `summarize avg(duration) by operation_Name`).

Why the Other Options Are Incorrect

A. extend: While `extend` can create calculated columns, it is not strictly necessary to perform the required correlation or averaging; the `summarize` operator can calculate the average directly.

E. distinct: `distinct` is used to return a unique list of values. It cannot perform calculations (like averages) or correlate datasets.

References

Microsoft Learn: Application Insights telemetry correlation (Explains how to correlate requests and dependencies using `join` on `operation_Id`).
Question 8
A company uses Azure Monitor Application Insights to monitor application behavior, including incoming requests and dependencies.
You must identify failed requests from the last hour. You must also calculate the average duration of failed request dependency calls, grouped by operation name.
You need to analyze telemetry in Application insights.
Which operators should you mm? To answer, select the appropriate options in the answer area NOTE: Each cot reel selection is worth one point.
Show answerHide answer

Explanation



Explanation

1. where (for the requests table): The requirement states you must identify failed requests from the last hour. The `where` operator is used to filter the `requests` table using the condition `timestamp > ago(1h) and success == false`.

2. where (for the dependencies table): When joining two tables in KQL, it is a best practice to filter the secondary table (in this case, `dependencies`) before the join to reduce the dataset size and improve performance. You use `where` to ensure you are only looking at recent dependencies (e.g., `where timestamp > ago(1h)`).

3. summarize: The requirement is to calculate the average duration of the dependency calls, grouped by operation name. The `summarize` operator is specifically designed for this. You use it with the `avg()` aggregation function (e.g., `summarize avg(depDuration) by operation_Name`).

Why the Other Options Are Incorrect

extend: This operator creates a new calculated column. While useful for adding formulas or parsing strings, it is not required to filter data or calculate aggregate averages.

project: This operator selects specific columns to include or exclude. It does not filter rows or perform aggregations.

distinct: This operator produces a table with the distinct combination of the provided columns. It cannot calculate averages or filter based on time.

render: This operator instructs the client to render a visualization (like a chart or graph). It is used at the very end of a query for display purposes and does not manipulate the data.

References

Microsoft Learn: where operator
Question 9
You plan to develop an Azure Functions app with an HTTP trigger.
The app must support the following functionality:
Event-driven scaling -
Ability to use custom Linux images for function execution
You need to identify the app ' s hosting plan and the maximum amount of time that the app function can take to respond to incoming requests.
Which configuration setting values should you use? To answer, select the appropriate values in the answer area.
NOTE: Each correct selection is worth one point.
Show answerHide answer

Explanation



Explanation

Premium (Hosting Plan): The requirement states the app must support "custom Linux images for function execution." In Azure Functions, custom containers are supported on the Premium and Dedicated (App Service) plans, but not on the Consumption plan. Between the two, the Premium plan provides "event-driven scaling" (like the Consumption plan) while still supporting custom containers, VNET integration, and pre-warmed instances. The Dedicated plan requires manual or autoscale rule-based scaling and does not offer the same event-driven model.

230 seconds (Timeout Value): For HTTP-triggered Azure Functions, the maximum allowed response timeout is limited by the Azure Load Balancer. Regardless of the hosting plan chosen (Consumption, Premium, or Dedicated), the HTTP response timeout is capped at 230 seconds. If the function takes longer than 230 seconds, the request will time out and return a 502 Bad Gateway error.

Why the Other Options Are Incorrect

Consumption: While it offers event-driven scaling, it does not support custom Linux containers.

Dedicated: While it supports custom containers, it does not provide the native, out-of-the-box event-driven scaling requested by the business requirement (it relies on standard App Service autoscale).

10 minutes / unlimited: These timeout values are available for non-HTTP triggers (like Service Bus or Queue triggers) on Premium/Dedicated plans, but they cannot be applied to an HTTP trigger due to the Load Balancer's hard limit of 230 seconds.

References

Microsoft Learn: Azure Functions hosting options (Details plan features, container support, and scaling).
Question 10
You are implementing semantic retrieval in Redis.
The solution must support low-latency, approximate nearest neighbor (ANN) vector similarity search for large-scale AI retrieval workloads.
You need to select the appropriate vector schema settings.
Which configuration values should you select? To answer, select the appropriate options in the answer area.
NOTE: Each correct selection is worth one point.
Show answerHide answer

Explanation



Explanation

Vector (Field type): To store high-dimensional embeddings and perform similarity searches in Redis, the data field must be explicitly defined as a Vector type. This tells the Redis engine to treat the data as a mathematical vector, enabling it to calculate distances (like cosine or Euclidean distance) against a query vector.

HNSW index: The requirement explicitly asks for a low-latency, approximate nearest neighbor (ANN) search. Hierarchical Navigable Small World (HNSW) is a graph-based indexing algorithm specifically designed for this. It provides extremely fast, sub-linear query times for large-scale vector datasets by navigating a multi-layered graph, which is ideal for AI retrieval workloads.

Why the Other Options Are Incorrect

Numeric / Tag: These are standard Redis data types for scalar values (like integers or labels). They cannot perform vector distance calculations.

Flat index: A Flat index performs a brute-force, exhaustive search (calculating the distance to every single vector). While it provides 100% exact results, it is very slow and resource-intensive for large-scale workloads, failing the low-latency requirement.

Metadata index: Metadata indexes are used to filter search results based on associated scalar data (e.g., category, price) after the vector search, not for the vector similarity search itself.

References

Microsoft Learn: Vector similarity search in Azure Cache for Redis (Covers Vector field types and HNSW index configuration).
Full mock exam

Sit the AI-200 exam before exam day

Full-length mocks with the same number of questions and the same time limit as the real AI-200 exam. Every attempt draws a new set of questions from the full bank, so you can keep going until you pass comfortably.

Get full AI-200 mock exam
  • 60questions per mock
  • 120 mintime limit
  • 142questions in the bank
  • Newmock on every attempt