Courseiva

CCNA Generative Ai Solutions Questions

23 of 173 questions · Page 3/3 · Generative Ai Solutions topic · Answers revealed

151
MCQmedium

Refer to the exhibit. A developer received this response from an Azure OpenAI chat completion call. The prompt was "What is the capital of France?". The finish_reason is "stop". What does this indicate?

A.The response was truncated due to content filtering.
B.The model completed the response naturally.
C.The model stopped generating before the response was complete.
D.The response reached the max_tokens limit.
AnswerB

Finish_reason 'stop' indicates normal completion.

Why this answer

The finish_reason 'stop' indicates that the model completed the response naturally, meaning it generated a complete answer to the prompt and reached a logical stopping point (e.g., the end of a sentence or the end of the generated text). This is the standard behavior for a successful completion where the model did not encounter any content filter, token limit, or other interruption.

Exam trap

Microsoft often tests the distinction between finish_reason values, and the trap here is that candidates confuse 'stop' with 'length' or assume any non-error finish_reason means truncation, when in fact 'stop' explicitly signals a natural and complete generation.

How to eliminate wrong answers

Option A is wrong because 'stop' specifically means the model finished generating on its own, not that content filtering truncated the response; content filtering would return a finish_reason of 'content_filter'. Option C is wrong because 'stop' indicates the model completed the response, not that it stopped prematurely; a premature stop would be indicated by a finish_reason of 'length' (if max_tokens hit) or 'null' (if interrupted). Option D is wrong because reaching the max_tokens limit would result in a finish_reason of 'length', not 'stop'.

152
Multi-Selecteasy

Which TWO Azure services can be used together with Azure OpenAI to implement a Retrieval-Augmented Generation (RAG) solution?

Select 2 answers
A.Azure Blob Storage
B.Azure Cosmos DB
C.Azure AI Search
D.Azure SQL Database
E.Azure Functions
AnswersB, C

Cosmos DB supports vector indexing.

Why this answer

Azure Cosmos DB is correct because it can serve as a vector database for storing and querying embeddings generated by Azure OpenAI. When combined with Azure AI Search, which provides hybrid search (vector + keyword) and indexing capabilities, it enables a complete RAG pipeline where relevant documents are retrieved and passed as context to the OpenAI model for grounded generation.

Exam trap

The trap here is that candidates often assume any storage service (like Blob Storage or SQL Database) can directly support RAG, but they overlook the need for native vector search or hybrid retrieval capabilities that only Azure AI Search and Cosmos DB (with vector support) provide.

153
MCQhard

You are building a generative AI application that uses Azure OpenAI Service. The application must handle sensitive user data and comply with GDPR. You need to ensure that the service does not store or log user prompts and completions. What should you configure?

A.Disable data logging in the Azure OpenAI Service resource
B.Deploy the resource in a GDPR-compliant region
C.Configure content filtering to block sensitive data
D.Use a custom endpoint that anonymizes data
AnswerA

Disabling data logging ensures prompts and completions are not stored.

Why this answer

Azure OpenAI Service provides a data logging toggle that, when disabled, ensures Microsoft does not store or process your prompts and completions for monitoring or improvement purposes. This is essential for GDPR compliance when handling sensitive user data, as it prevents any retention of personal data in the service's logs.

Exam trap

The trap here is that candidates often confuse regional compliance (Option B) with operational data handling, not realizing that GDPR requires explicit control over data storage and logging, which is only achieved by disabling the data logging toggle.

How to eliminate wrong answers

Option B is wrong because deploying in a GDPR-compliant region addresses data residency requirements but does not prevent the service from storing or logging prompts and completions; logging is controlled by the data logging setting, not the region. Option C is wrong because content filtering blocks harmful or sensitive content from being generated or displayed, but it does not stop the service from logging the prompts and completions that were submitted. Option D is wrong because Azure OpenAI Service does not support custom endpoints that anonymize data; the only way to prevent logging is to disable the data logging feature in the resource configuration.

154
MCQmedium

You are building a customer support chatbot using Azure OpenAI Service. The chatbot must only respond based on the company's product documentation and should not generate answers outside that scope. Which approach should you use?

A.Implement content filters to block responses not found in the documentation.
B.Fine-tune a GPT-4 model on the product documentation.
C.Use Azure OpenAI On Your Data with a search index built from the documentation.
D.Use prompt engineering with a system message instructing the model to only answer from the documentation.
AnswerC

This approach grounds the model on the indexed documents, ensuring responses are based on the documentation.

Why this answer

Azure OpenAI On Your Data allows you to ground the model's responses on a specific set of documents by connecting it to a search index (e.g., Azure Cognitive Search) built from the product documentation. This ensures the model retrieves relevant chunks from the index and generates answers solely based on that content, preventing out-of-scope responses without modifying the underlying model.

Exam trap

The trap here is that candidates often confuse fine-tuning (Option B) with retrieval-augmented generation, assuming that training on documentation will fully constrain the model's output, when in fact fine-tuning does not prevent the model from generating information outside the training data due to its generative nature and lack of explicit retrieval grounding.

How to eliminate wrong answers

Option A is wrong because content filters in Azure OpenAI Service are designed to block harmful or policy-violating content (e.g., hate speech, violence), not to restrict responses to a specific knowledge base; they cannot enforce domain-specific boundaries like 'only answer from documentation.' Option B is wrong because fine-tuning a GPT-4 model on the product documentation would adapt the model's weights to the documentation's style and facts, but it does not guarantee the model will not hallucinate or generate answers outside that scope, as fine-tuning does not provide a retrieval mechanism to constrain responses to exact source text. Option D is wrong because prompt engineering with a system message instructing the model to only answer from the documentation is unreliable; the model may still generate plausible-sounding but incorrect information not present in the documentation, as it lacks a grounded retrieval step and relies solely on its parametric knowledge.

155
Multi-Selecteasy

Which TWO statements about Azure OpenAI Service content filters are true?

Select 2 answers
A.They can be configured with severity levels (low, medium, high)
B.They only filter the output of the model
C.They cannot be customized for specific use cases
D.They are bypassed when using PTU deployments
E.They include categories such as hate, sexual, violence, and self-harm
AnswersA, E

Severity levels allow granular control over filtering.

Why this answer

Azure OpenAI Service content filters can be configured with severity levels (low, medium, high) to control the strictness of filtering for each content category. This allows administrators to fine-tune the filter sensitivity based on their application's risk tolerance and compliance requirements.

Exam trap

The trap here is that candidates often assume content filters only apply to model outputs (Option B) or that PTU deployments offer a way to bypass safety controls (Option D), but Azure enforces filters uniformly across all deployment types.

156
MCQhard

Your company uses Azure Bot Service with QnA Maker to answer HR questions. You need to migrate to Microsoft Copilot Studio to leverage generative AI capabilities. You have an existing QnA Maker knowledge base. What is the recommended migration path?

A.In Copilot Studio, use the 'Import from QnA Maker' option to directly bring in the knowledge base.
B.Create a new Copilot and manually recreate each Q&A pair.
C.Use Azure PowerShell to export the knowledge base and then upload to Copilot Studio.
D.Export the QnA Maker KB to a TSV file, then import into Azure AI Language custom question answering.
AnswerA

Copilot Studio provides built-in import from QnA Maker.

Why this answer

Copilot Studio provides a direct 'Import from QnA Maker' option that migrates the entire knowledge base automatically, preserving Q&A pairs, metadata, and synonyms. Option B is incorrect because manually recreating each Q&A pair is unnecessary and inefficient when the native import tool exists. Option C is incorrect because Azure PowerShell does not have a specific cmdlet to export a QnA Maker knowledge base for direct import into Copilot Studio; the import feature handles the migration.

Option D is incorrect because exporting to TSV and importing into Azure AI Language custom question answering is an intermediate step that doesn't directly move the KB into Copilot Studio; the simplest path is the built-in import.

157
MCQhard

Your company is using Azure OpenAI Service to generate marketing copy. The compliance team requires that all generated content be reviewed for sensitive data before delivery. You need to implement a solution that automatically scans the output for personally identifiable information (PII) and blocks it if detected. Which service should you integrate?

A.Azure AI Content Safety with a custom blocklist
B.Microsoft Purview Information Protection
C.Microsoft Defender for Cloud Apps
D.Azure AI Language PII detection
AnswerA

Content Safety can detect and block sensitive content including PII in real-time.

Why this answer

Azure AI Content Safety with a custom blocklist is the correct choice because it is specifically designed to filter and block harmful or sensitive content, including PII, in real-time. By adding a custom blocklist of PII patterns (e.g., regex for social security numbers), you can automatically block any output from Azure OpenAI that matches those patterns before delivery. This service integrates directly with Azure OpenAI Service via the content filtering system, making it the most appropriate for this use case.

Exam trap

The trap here is that candidates confuse Azure AI Language PII detection (which only identifies PII) with Azure AI Content Safety (which can both detect and block content), leading them to choose D even though it lacks the blocking capability required by the question.

How to eliminate wrong answers

Option B is wrong because Microsoft Purview Information Protection is a data classification and labeling service for files and emails, not a real-time content filter for API responses from Azure OpenAI. Option C is wrong because Microsoft Defender for Cloud Apps is a cloud access security broker (CASB) focused on monitoring and controlling cloud app usage, not scanning generative AI output for PII. Option D is wrong because Azure AI Language PII detection is a text analytics API that identifies PII in text, but it does not have built-in blocking capabilities or integration with Azure OpenAI's output pipeline to automatically block content before delivery.

158
MCQmedium

You are using Azure AI Document Intelligence to extract data from invoices. The invoices have varying layouts, and you need to build a custom model that can handle multiple document formats. Which type of model should you train?

A.Custom neural model
B.Custom template model
C.Prebuilt invoice model
D.Custom composed model
AnswerA

Neural models handle varied layouts and learn from a variety of document structures.

Why this answer

Custom neural models are designed to learn from diverse layouts without requiring manual labeling of field positions, making them ideal for invoices with varying formats. They use deep learning to understand document structure and extract fields accurately even when layouts differ significantly. This is the recommended approach for handling multiple invoice formats in Azure AI Document Intelligence.

Exam trap

The trap here is that candidates often confuse custom template models (which require fixed layouts) with custom neural models (which handle varying layouts), leading them to select the template model due to familiarity with older OCR approaches.

How to eliminate wrong answers

Option B (Custom template model) is wrong because it relies on fixed spatial patterns and requires consistent layouts, failing when invoices have varying formats. Option C (Prebuilt invoice model) is wrong because it is optimized for standard invoice layouts and cannot be retrained to handle custom or highly variable formats. Option D (Custom composed model) is wrong because it combines multiple custom models but does not inherently handle varying layouts within a single model; it requires separate models for each layout type.

159
MCQhard

You are building a generative AI solution using Azure AI Foundry. The solution must meet compliance requirements that require all model inputs and outputs to be auditable for a minimum of one year. What should you enable?

A.Azure Monitor alerts for unusual activity.
B.Azure Monitor metrics for the Azure AI Foundry resource.
C.Azure Monitor workbooks to visualize usage.
D.Diagnostic settings to capture request and response logs and store them in a storage account.
AnswerD

Diagnostic settings can log full request/response data for auditing.

Why this answer

Enabling diagnostic settings for the Azure AI Foundry resource allows you to capture detailed request and response logs for all model interactions. By routing these logs to a storage account, you retain the data for the required one-year audit period, meeting compliance needs for full traceability of inputs and outputs.

Exam trap

The trap here is that candidates confuse monitoring features (alerts, metrics, workbooks) with data retention capabilities, assuming any Azure Monitor feature can satisfy audit requirements without understanding that only diagnostic settings provide the raw log capture needed for compliance.

How to eliminate wrong answers

Option A is wrong because Azure Monitor alerts are designed to notify on unusual activity or anomalies, not to provide long-term audit storage of model inputs and outputs. Option B is wrong because Azure Monitor metrics capture aggregated performance data like latency or request counts, not the detailed request/response payloads needed for auditing. Option C is wrong because Azure Monitor workbooks are visualization tools for metrics and logs, not a storage mechanism for raw audit data.

160
MCQhard

You are deploying a generative AI solution using Azure OpenAI Service. The solution must comply with data residency requirements that mandate all data processing and storage remain within a specific geographic region. You need to configure the service to meet these requirements. What should you do?

A.Deploy the Azure OpenAI Service resource in the required region
B.Use a custom endpoint that routes traffic to the required region
C.Select a model that is only available in the required region
D.Configure content filtering to block data leaving the region
AnswerA

Deploying the resource in the required region ensures data processing and storage stay within that region.

Why this answer

Deploying the Azure OpenAI Service resource in the required region ensures that all data processing and storage occur within that geographic boundary, as Azure OpenAI Service is a regional resource that processes and stores data only in the region where it is provisioned. This directly satisfies data residency requirements because the service's infrastructure, including model inference and training data, remains within the selected Azure region. No additional routing or filtering is needed because the resource itself is bound to the region.

Exam trap

The trap here is that candidates confuse data residency with network routing or content filtering, mistakenly believing that a custom endpoint or filtering can override the regional deployment requirement, when in fact the resource's deployment region is the sole determinant of data location.

How to eliminate wrong answers

Option B is wrong because custom endpoints only control the URL used to access the service, not the physical location of data processing or storage; traffic routing does not change where the Azure OpenAI Service resource is deployed or where data resides. Option C is wrong because model availability in a region does not guarantee data residency—selecting a model available only in the required region still requires the resource itself to be deployed in that region to ensure data stays there. Option D is wrong because content filtering is a safety feature that blocks harmful content, not a mechanism to enforce geographic data boundaries; it cannot prevent data from being processed or stored outside the region if the resource is deployed elsewhere.

161
MCQmedium

You are building a multi-tenant application that uses Azure OpenAI. Each tenant has different content filtering requirements. How should you configure the solution to meet these requirements?

A.Use a single Azure OpenAI deployment and configure content filters at the application level.
B.Configure different system messages for each tenant to enforce content policies.
C.Pass the tenant ID in the API call and use a custom middleware to apply filters.
D.Create separate Azure OpenAI deployments for each tenant with their own content filter configurations.
AnswerD

Each deployment can have its own content filter settings.

Why this answer

Azure OpenAI content filters are configured at the deployment level, not at the application or API-call level. By creating separate deployments for each tenant, you can assign distinct content filter configurations (e.g., severity thresholds for hate, violence, self-harm) that are enforced server-side by Azure's content filtering service, ensuring isolation and compliance with each tenant's requirements.

Exam trap

The trap here is that candidates assume content filters can be dynamically applied per request using a tenant ID or custom middleware, but Azure OpenAI enforces filters at the deployment level only, requiring separate deployments for different filter configurations.

How to eliminate wrong answers

Option A is wrong because content filters in Azure OpenAI are not configurable at the application level; they are applied per deployment via the Azure AI Studio or ARM templates, and a single deployment shares the same filter configuration across all callers. Option B is wrong because system messages are part of the prompt and do not enforce content filtering policies; they guide model behavior but cannot override or customize the built-in content filter rules that Azure applies before returning responses. Option C is wrong because the tenant ID is not a parameter in the Azure OpenAI API call that affects content filtering; custom middleware could apply post-processing filters, but it cannot modify the pre-built Azure content filters that run server-side before the response is sent.

162
MCQeasy

Your company wants to use Azure OpenAI to generate code snippets. You need to ensure the generated code does not contain security vulnerabilities. Which approach should you take?

A.Scan the generated code with a static analysis tool after generation.
B.Include a system message that instructs the model to generate secure code following best practices.
C.Use content filters to block malicious code.
D.Fine-tune the model on a dataset of secure code examples.
AnswerB

System messages can guide the model to produce secure code.

Why this answer

Azure OpenAI's system messages allow you to set the context and behavior of the model, including instructing it to follow secure coding best practices (e.g., OWASP Top 10). This is the most direct and scalable way to influence the model's output at inference time without requiring post-processing or retraining. The system message acts as a persistent instruction that guides every response, making it the recommended approach for steering content generation.

Exam trap

Microsoft often tests the misconception that content filters can handle security vulnerabilities, but content filters are for policy compliance (e.g., hate speech, violence), not for code security flaws like injection attacks or improper error handling.

How to eliminate wrong answers

Option A is wrong because scanning generated code with a static analysis tool after generation is a reactive measure that does not prevent vulnerabilities from being created; it only catches them after the fact, and the model may still produce insecure code that requires rework. Option C is wrong because content filters in Azure OpenAI are designed to block harmful or policy-violating content (e.g., hate speech, violence), not to detect or prevent security vulnerabilities in code (e.g., SQL injection, buffer overflows). Option D is wrong because fine-tuning on a dataset of secure code examples is costly, requires significant expertise, and may not generalize well to all coding scenarios; moreover, Azure OpenAI does not currently support fine-tuning for code generation models like GPT-4 in the same way as for text models, and system messages are the simpler, supported alternative.

163
Multi-Selectmedium

You are designing a generative AI solution using Azure OpenAI Service. The solution must meet compliance requirements by preventing the model from generating sensitive personal data. Which TWO configurations should you implement? (Select TWO.)

Select 2 answers
A.Implement data loss prevention (DLP) policies using Microsoft Purview
B.Configure content filters in Azure AI Content Safety
C.Add a system message instructing the model not to generate personal data
D.Deploy the model in a specific region
E.Fine-tune the model with a dataset that excludes personal data
AnswersA, B

DLP policies provide data governance and protection.

Why this answer

Microsoft Purview DLP policies can scan and block sensitive data (e.g., PII, credit card numbers) in prompts and responses when integrated with Azure OpenAI Service, ensuring compliance by preventing data exfiltration. Azure AI Content Safety content filters allow you to configure severity thresholds to block harmful or sensitive content categories, directly preventing the model from generating personal data at the inference layer.

Exam trap

The trap here is that candidates often choose a system message (Option C) as a reliable control, but Microsoft explicitly warns that system messages are not a security boundary and can be bypassed, whereas DLP and content filters provide enforceable guardrails.

164
MCQmedium

You are deploying a generative AI model using Azure Machine Learning. The model is a large language model that requires GPU compute. You need to minimize costs while ensuring the model is always available for inference. Which compute option should you choose?

A.Managed online endpoint with a GPU VM
B.Batch endpoint with GPU
C.Serverless GPU compute
D.CPU-based inference
AnswerA

Managed online endpoints provide real-time inference with GPU, and autoscaling can help cost while keeping availability.

Why this answer

A managed online endpoint with a GPU VM is the correct choice because it provisions a dedicated GPU instance that remains always active, ensuring the model is available for real-time inference at any time. This option balances cost and availability by allowing you to choose a lower-cost GPU SKU (e.g., NCas_v4) while avoiding the cold-start latency of serverless or batch options. The managed endpoint also handles auto-scaling and load balancing, but for constant availability, a fixed minimum instance count is required.

Exam trap

Microsoft often tests the distinction between 'always available' (requiring a persistent compute instance) and 'cost-optimized' (allowing scale-to-zero), leading candidates to mistakenly choose serverless GPU compute because it sounds cheaper, but it fails the availability requirement.

How to eliminate wrong answers

Option B is wrong because batch endpoints are designed for asynchronous, large-scale inference jobs on a schedule or trigger, not for always-on, real-time availability; they incur costs only during job execution but cannot guarantee immediate response. Option C is wrong because serverless GPU compute (e.g., Azure Machine Learning serverless spark or serverless inference) typically scales to zero when idle, meaning the model may not be available for inference without a cold start, which violates the 'always available' requirement. Option D is wrong because CPU-based inference is insufficient for large language models that require GPU acceleration for acceptable latency and throughput; using CPU would result in unacceptable performance or failure to load the model.

165
Multi-Selecthard

Which THREE factors should you consider when selecting a model for a generative AI solution on Azure?

Select 3 answers
A.Cost per token and deployment options.
B.Model capability and modality (text, code, image).
C.Latency and throughput requirements.
D.Number of transformer layers in the model.
E.Training data source and licensing.
AnswersA, B, C

Cost and deployment flexibility are key considerations.

Why this answer

Cost per token directly impacts operational expenses in pay-per-use models like GPT-4 on Azure OpenAI, and deployment options (e.g., global vs. regional, provisioned throughput) affect availability and scalability. These are fundamental considerations when operationalizing a generative AI solution.

Exam trap

The trap here is that candidates confuse internal model architecture (like transformer layers) with selection criteria, when in fact Azure abstracts those details and you only need to consider cost, capability, latency, and deployment options.

166
MCQeasy

You need to generate realistic synthetic data for training a machine learning model while ensuring the data does not contain personally identifiable information (PII). Which Azure service should you use?

A.Azure AI Search
B.Azure AI Document Intelligence
C.Azure OpenAI Service
D.Azure AI Language
AnswerC

GPT models can generate realistic synthetic data without PII when properly prompted.

Why this answer

Azure OpenAI Service provides access to powerful generative AI models (e.g., GPT-4) that can create realistic synthetic data by learning patterns from training data. Crucially, these models can be configured to avoid memorizing or reproducing PII, and you can apply content filters and data masking to ensure the generated output is free of personally identifiable information.

Exam trap

The trap here is that candidates confuse Azure AI Language's text generation capabilities (e.g., summarization, question answering) with the full generative AI power of Azure OpenAI Service, but Azure AI Language does not offer the same level of flexible, high-fidelity synthetic data generation.

How to eliminate wrong answers

Option A is wrong because Azure AI Search is a search-as-a-service solution for indexing and querying data, not a generative AI service capable of creating synthetic data. Option B is wrong because Azure AI Document Intelligence (formerly Form Recognizer) is designed to extract structured information from documents (e.g., OCR, key-value pairs), not to generate new synthetic datasets. Option D is wrong because Azure AI Language provides pre-built and custom NLP capabilities (e.g., sentiment analysis, entity recognition) but does not include generative models for creating realistic synthetic data from scratch.

167
MCQhard

A financial services firm wants to use Azure OpenAI to generate investment advice summaries. They must ensure that the model does not produce any advice that could be interpreted as personalized financial advice. What is the most effective strategy?

A.Set temperature to 0 and top_p to 0 to make outputs deterministic.
B.Use a system message that instructs the model to avoid personalized advice and apply strict content filtering.
C.Provide few-shot examples of disclaimers in the prompt.
D.Fine-tune the model on a dataset of generic financial summaries.
AnswerB

System messages and content filtering directly address content restrictions.

Why this answer

Azure OpenAI's system messages allow you to set the model's behavior and constraints at the conversation level, which is the most direct and effective way to enforce a policy like avoiding personalized financial advice. Combined with Azure's content filtering (which can block harmful or restricted content), this approach provides both instruction-based and filter-based guardrails without requiring model retraining or relying solely on example-based prompting.

Exam trap

The trap here is that candidates often assume deterministic parameters (temperature=0, top_p=0) guarantee safe outputs, but they only control randomness, not content compliance—Azure's system message and content filtering are the correct tools for enforcing content policies.

How to eliminate wrong answers

Option A is wrong because setting temperature to 0 and top_p to 0 makes outputs deterministic but does not prevent the model from generating personalized financial advice; it only reduces randomness, not content compliance. Option C is wrong because few-shot examples of disclaimers in the prompt can be ignored or overridden by the model if the underlying training data biases it toward personalized responses; system messages have higher priority in the instruction hierarchy. Option D is wrong because fine-tuning on generic financial summaries requires significant labeled data and compute, and it does not guarantee the model will avoid personalized advice—it may still generate such content if the fine-tuning dataset is not carefully curated to exclude it.

168
MCQmedium

You are building a chatbot for a retail company using Azure OpenAI Service. The chatbot must provide product recommendations based on customer preferences. To ensure the chatbot does not generate harmful or inappropriate responses, you need to implement a content filtering solution. What should you use?

A.Azure AI Content Safety
B.Azure OpenAI Service content filtering
C.Azure AI Search
D.Microsoft Purview Information Protection
AnswerB

Azure OpenAI Service provides built-in content filtering that can be configured to block harmful content.

Why this answer

Azure OpenAI Service content filtering is the correct choice because it provides built-in, configurable filters that block harmful or inappropriate content at the model level, directly within the Azure OpenAI endpoint. This ensures that the chatbot's product recommendations remain safe without requiring external services, as the filtering is applied to both input prompts and output completions based on severity levels for categories like hate, violence, and self-harm.

Exam trap

The trap here is that candidates often confuse Azure AI Content Safety (a standalone moderation service) with the built-in content filtering of Azure OpenAI Service, assuming that a separate service is required for safety when the native filtering is both sufficient and more tightly integrated.

How to eliminate wrong answers

Option A is wrong because Azure AI Content Safety is a separate service for moderating user-generated content (e.g., images, text) but does not integrate natively with Azure OpenAI Service's model responses; using it would require an extra API call and custom orchestration, adding latency and complexity. Option C is wrong because Azure AI Search is a retrieval service for indexing and querying data (e.g., product catalogs) and has no content filtering capabilities for harmful or inappropriate responses. Option D is wrong because Microsoft Purview Information Protection is a data governance and classification tool for protecting sensitive information (e.g., PII, compliance labels) and does not filter model-generated content for safety or appropriateness.

169
MCQmedium

A company uses Azure OpenAI to generate code snippets. They notice that the model sometimes produces code that uses deprecated APIs. They want to minimize this without retraining the model. What should they do?

A.Fine-tune the model on a dataset of recent code.
B.Set the temperature parameter to 0 to reduce randomness.
C.Add a system message instructing the model to use only current, non-deprecated APIs.
D.Provide a few-shot example of correct code in the prompt.
AnswerC

System messages effectively guide model behavior.

Why this answer

Adding a system message in Azure OpenAI allows you to set high-level instructions that guide the model's behavior without retraining. By explicitly instructing the model to use only current, non-deprecated APIs, you leverage the system prompt's ability to influence output style and content, effectively reducing deprecated API usage in generated code snippets.

Exam trap

Microsoft often tests the distinction between prompt engineering techniques (system messages, few-shot examples, parameter tuning) and model customization (fine-tuning), and the trap here is that candidates may confuse few-shot prompting (Option D) with a system message, not realizing that a system message provides a more persistent and scalable way to enforce behavioral rules across all responses.

How to eliminate wrong answers

Option A is wrong because fine-tuning requires retraining the model on a custom dataset, which contradicts the requirement to minimize deprecated API usage without retraining. Option B is wrong because setting the temperature parameter to 0 reduces randomness and makes outputs more deterministic, but it does not prevent the model from generating deprecated APIs—it only affects creativity and variability. Option D is wrong because providing a few-shot example of correct code in the prompt can help guide the model, but it is less reliable than a system message for consistently enforcing a rule across all responses, as the model may still default to deprecated APIs in other contexts.

170
MCQhard

Your company is building a multi-tenant SaaS application using Azure AI Foundry. Each tenant (customer) should have isolated model deployments and data, but you want to share the base models across tenants to reduce costs. Which approach should you use?

A.Use a single model deployment and a shared endpoint with tenant ID in the header.
B.Create separate fine-tuned models for each tenant.
C.Deploy separate base models for each tenant.
D.Deploy one model per base model and use separate endpoints with routing logic per tenant.
AnswerD

Separate endpoints with routing isolate tenants while sharing the model.

Why this answer

Deploying one model per base model and using separate endpoints with routing logic per tenant provides tenant isolation while sharing the base model, reducing costs. Option A is incorrect because using a single deployment with a tenant ID in the header does not provide sufficient isolation and may lead to data leakage. Option B is incorrect because creating separate fine-tuned models per tenant increases costs and does not share the base model.

Option C is incorrect because deploying separate base models for each tenant also increases costs unnecessarily.

171
MCQhard

You are designing a generative AI solution that uses Azure OpenAI Service. The solution must generate code snippets in Python and JavaScript. You need to ensure the model reliably outputs code in the correct language based on user input. Which approach should you use?

A.Set the top_p parameter to a low value.
B.Use a system message to specify the desired language.
C.Fine-tune the model on a dataset of code in both languages.
D.Set the temperature to 0 to make the model deterministic.
AnswerB

System messages can instruct the model on the language to use.

Why this answer

System messages in Azure OpenAI Service allow you to set the context or behavior of the model, such as specifying the desired programming language for code generation. This approach is lightweight, requires no retraining, and reliably guides the model to output code in the correct language based on the user's request, leveraging the model's existing training on both Python and JavaScript.

Exam trap

The trap here is that candidates often confuse hyperparameters like temperature and top_p with content control mechanisms, mistakenly believing they can enforce output language, when in fact they only affect randomness and token selection probability.

How to eliminate wrong answers

Option A is wrong because setting top_p to a low value reduces the pool of tokens considered for sampling, which can make outputs more focused but does not control the language of the generated code; it is a nucleus sampling parameter, not a language selector. Option C is wrong because fine-tuning the model on a dataset of code in both languages is overkill for this requirement, as the base model already understands both languages; fine-tuning is typically used for specialized tasks or to adapt to a specific domain, not for simple language switching. Option D is wrong because setting temperature to 0 makes the model deterministic by always choosing the most likely token, but it does not enforce the output language; it can still produce code in the wrong language if the prompt is ambiguous, and it reduces creativity but does not guarantee language adherence.

172
MCQmedium

You are deploying a generative AI application. You have the JSON configuration above. You need to ensure that the model stops generating output at the end of each sentence. The current configuration uses a stop sequence of "\n". What should you do?

A.Change the stop sequence to [".", "!" , "?"]
B.Reduce the maxTokens to 500.
C.Set the topP to 0.5.
D.Set the temperature to 0.
AnswerA

These are sentence-ending punctuation marks.

Why this answer

The goal is to stop generation at the end of each sentence. A sentence can end with a period (.), exclamation mark (!), or question mark (?). The current stop sequence of "\n" only stops at newline characters, which does not guarantee sentence boundaries.

By changing the stop sequence to an array containing [".", "!", "?"], the model will halt output whenever it generates any of these punctuation marks, ensuring each sentence is complete.

Exam trap

The trap here is that candidates often confuse parameters that control output randomness (temperature, topP) or length (maxTokens) with parameters that define explicit stopping conditions, leading them to select options that do not actually enforce sentence boundaries.

How to eliminate wrong answers

Option B is wrong because reducing maxTokens to 500 limits the total number of tokens generated but does not control where generation stops relative to sentence boundaries; the model could still cut off mid-sentence. Option C is wrong because setting topP to 0.5 adjusts the nucleus sampling threshold, affecting token selection diversity, not the stopping condition; it does not enforce sentence-ending punctuation. Option D is wrong because setting temperature to 0 makes the model deterministic (greedy decoding) but does not introduce a stop condition based on sentence-ending characters; the model will still generate until maxTokens or another stop sequence is reached.

173
MCQhard

You are a senior AI engineer at a financial services company. You are building a generative AI solution to assist financial advisors with client portfolio recommendations. The solution must use Azure OpenAI Service. The following requirements must be met: 1. Responses must be based on the latest market data and client profiles stored in Azure SQL Database. 2. The solution must not generate investment advice that is not backed by the data. 3. The solution must be cost-effective and minimize API calls. 4. The system must provide citations for the data used in the response. You design a RAG pattern with Azure AI Search indexing the portfolio data. You also implement a system message instructing the model to only use provided context. However, the model occasionally generates advice that contradicts the data or invents new facts. You need to modify the solution to ensure responses are strictly grounded in the retrieved data. What should you do?

A.Set temperature to 0 in the Azure OpenAI completion request.
B.Reduce the top_k parameter in the search query to retrieve fewer documents.
C.Increase the chunk size in the index to provide more context per document.
D.Use Azure OpenAI Service on your own data integration to directly query the SQL database.
AnswerA

Temperature 0 makes output deterministic and grounded in provided context.

Why this answer

Setting the temperature to 0 makes the model deterministic, reducing its tendency to generate creative or ungrounded responses. This enforces adherence to the provided context (retrieved data) and minimizes hallucination. Option B is incorrect: reducing top_k limits the number of retrieved documents but does not force the model to rely solely on them; the model can still invent facts if the temperature is high.

Option C is incorrect: increasing chunk size provides more context per document but does not prevent the model from ignoring or contradicting that context. Option D is incorrect: Azure OpenAI Service on your own data still uses a language model that can hallucinate if not properly constrained (e.g., with low temperature); it does not directly query SQL databases in real time.

← PreviousPage 3 of 3 · 173 questions total

Ready to test yourself?

Try a timed practice session using only Generative Ai Solutions questions.