Courseiva

Oracle Cloud Infrastructure Generative AI Professional 1Z0-1127-25 (1Z0-1127-25) — Questions 751768

768 questions total · 11pages · All types, answers revealed

Page 10

Page 11 of 11

751
MCQmedium

A prompt engineer is testing two versions of a prompt for a content generation task. They want to measure which version produces more factual and concise outputs. Which evaluation approach is BEST?

A.Use only the first output from each prompt and manually compare
B.Run A/B tests on a diverse set of inputs and score outputs based on predefined criteria
C.Ask the model to self-evaluate its outputs
D.Increase the temperature to see which prompt handles randomness better
AnswerB

A/B testing with multiple inputs and scoring criteria provides objective comparison.

Why this answer

A/B testing with clear metrics (factuality, conciseness) is the standard method for comparing prompt variants. Manual inspection on a few cases is not statistically robust; other options are not comparative.

752
MCQmedium

An administrator created the above IAM policies. A member of the GenerativeAIAdmins group reports they cannot invoke the model endpoint. Which permission is missing?

A.Permission to access the compartment
B.Permission to manage generative-ai-model
C.Permission to use or manage generative-ai-endpoint
D.Permission to read the model's training data
AnswerC

Only inspect is granted; need use or manage to invoke.

Why this answer

The error occurs because the IAM policy grants permissions for 'generative-ai-model' but not for 'generative-ai-endpoint'. Invoking a model endpoint requires the 'use' or 'manage' permission on the 'generative-ai-endpoint' resource type, as the endpoint is the runtime interface that handles inference requests. Without this permission, the API call to the endpoint is denied, even if the user has access to the underlying model.

Exam trap

The trap here is that candidates confuse the 'generative-ai-model' resource type (used for model lifecycle management) with the 'generative-ai-endpoint' resource type (required for runtime inference), leading them to select Option B instead of C.

How to eliminate wrong answers

Option A is wrong because compartment access is typically granted via a separate policy statement (e.g., 'Allow group to read compartments') and is not the specific missing permission for invoking an endpoint; the error is about resource-type permissions, not compartment-level access. Option B is wrong because 'manage generative-ai-model' allows management of the model resource (e.g., creating, updating, deleting models) but does not grant the runtime permission needed to invoke the endpoint for inference. Option D is wrong because reading the model's training data is a data-plane permission unrelated to endpoint invocation; model training data access is governed by object storage or data catalog policies, not by generative-ai-endpoint permissions.

753
MCQeasy

Which component of the Transformer architecture allows the model to weigh the importance of different tokens in the input sequence when generating each output token?

A.Feed-forward neural network
B.Multi-head attention
C.Self-attention mechanism
D.Positional encoding
AnswerC

The self-attention mechanism computes attention scores between each token and every other token, allowing the model to focus on relevant parts of the input.

Why this answer

The self-attention mechanism computes attention scores between all pairs of tokens, enabling the model to dynamically focus on relevant parts of the input. Positional encoding adds order information, multi-head attention runs multiple attention heads in parallel, and the feed-forward network processes each position independently.

754
MCQhard

An engineer configured the above index mapping for vector search. When performing a k-NN search, the results are unexpected. What is the most likely issue?

A.The space type 'cosinesimil' is not supported; it should be 'cosine'.
B.The dimension 768 does not match the embedding model's output dimension.
C.The mapping uses 'knn_vector' type with 'faiss' engine, which is incompatible.
D.The space type at the index level and mapping level are mismatched.
AnswerD

Mismatch causes incorrect distance calculations.

Why this answer

OpenSearch requires the space type to be consistently defined at both the index-level settings (method.parameters.space_type) and the field-level mapping (space_type). A mismatch between these two causes the k-NN search to behave unexpectedly, as the engine uses the index-level setting for distance computation while the mapping-level setting may be used for validation or other purposes.

Exam trap

Oracle often tests the nuance that OpenSearch requires consistency between index-level and mapping-level space_type settings, a detail that candidates overlook because they assume only the mapping-level setting matters.

How to eliminate wrong answers

Option A is wrong because 'cosinesimil' is a valid space type in OpenSearch (an abbreviation for cosine similarity), not an unsupported value. Option B is wrong because while a dimension mismatch can cause issues, the question states the mapping is configured for vector search and the results are unexpected; the dimension 768 is a common embedding size and is not inherently incorrect without evidence of mismatch. Option C is wrong because 'knn_vector' type with 'faiss' engine is fully compatible and supported in OpenSearch for vector search workloads.

755
MCQhard

A team has fine-tuned a Cohere Command R model using T-Few on a dataset of 5,000 prompt/completion pairs. After deployment, they notice the model sometimes generates off-topic responses. Which action is most likely to improve response relevance without requiring new training data?

A.Decrease the max_tokens
B.Increase the temperature to 1.5
C.Increase the frequency_penalty
D.Set a preamble override with instructions to stay on topic
AnswerD

Preamble override provides a system-level instruction that can steer the model's behavior toward relevance.

Why this answer

Preamble override allows setting a system message that guides the model's behavior, helping to keep responses on topic. Adjusting it is a low-cost intervention.

756
MCQmedium

A developer wants to use LangChain to create an agent that can perform calculations and look up information from a database. Which tools should be provided to the agent?

A.Custom tool for database queries and a vector store tool
B.Calculator tool and a custom tool for database queries
C.Calculator tool and a retriever tool
D.Web search tool and an LLM tool
AnswerB

The agent needs a calculator for math and a custom tool to run SQL queries.

Why this answer

A calculator tool handles arithmetic, and a custom tool can be created to query the database. Web search is not needed, and an LLM is not a tool but the underlying model.

757
MCQeasy

A developer wants to generate text using the OCI Generative AI service via the API. Which endpoint should they use to send a text generation request?

A./v1/chat/completions
B./v1/embeddings
C./v1/completions
D./v1/models
AnswerC

This is the correct endpoint for text generation requests.

Why this answer

The OCI Generative AI service uses the /v1/completions endpoint for text generation requests, as documented in the OCI Generative AI API reference. This endpoint accepts a prompt and generates a continuation of the text, making it the appropriate choice for general text generation tasks.

Exam trap

Oracle often tests the distinction between OCI-specific endpoints and those from other AI services like OpenAI, so candidates may mistakenly choose /v1/chat/completions if they confuse OCI Generative AI with ChatGPT's API.

How to eliminate wrong answers

Option A is wrong because /v1/chat/completions is an endpoint used by OpenAI's ChatGPT API, not by OCI Generative AI, which does not have a dedicated chat completions endpoint. Option B is wrong because /v1/embeddings is used for generating vector embeddings of text, not for generating new text completions. Option D is wrong because /v1/models is used to list available models or retrieve model metadata, not to send a text generation request.

758
MCQmedium

A user repeatedly gets the same phrase output by the model. Which parameter adjustment is MOST likely to reduce such repetitive patterns?

A.Decrease max tokens
B.Increase temperature
C.Increase frequency penalty
D.Increase top-p
AnswerC

Frequency penalty penalizes tokens that have been used, reducing repetition.

Why this answer

Frequency penalty reduces the likelihood of repeating tokens that have already appeared, directly combating repetition.

759
MCQeasy

What is the primary purpose of an embedding model in a RAG pipeline?

A.To convert text into numerical vectors.
B.To generate human-like responses.
C.To rank search results.
D.To summarize long documents.
AnswerA

Embedding models encode text semantically into vectors.

Why this answer

The primary purpose of an embedding model in a RAG pipeline is to convert text into numerical vectors (embeddings) that capture semantic meaning. These vectors enable the retrieval component to efficiently find relevant documents by measuring similarity (e.g., cosine similarity) between the query and stored document embeddings. Without this conversion, the system cannot perform semantic search over unstructured text.

Exam trap

Oracle OCI GenAI exams often test the distinction between the embedding model's role (conversion to vectors) and the LLM's role (generation), so candidates may mistakenly attribute response generation or summarization to the embedding model.

How to eliminate wrong answers

Option B is wrong because generating human-like responses is the role of the large language model (LLM) in the generation step, not the embedding model. Option C is wrong because ranking search results is typically performed by a reranker or the retrieval algorithm (e.g., using vector similarity scores), not by the embedding model itself. Option D is wrong because summarizing long documents is a task for the LLM or a dedicated summarization model, not the embedding model, which only produces vector representations.

760
MCQhard

An AI team is fine-tuning a large language model using OCI Data Science and plans to deploy the fine-tuned model using the Generative AI service's custom model deployment. What is the required format for the model artifacts?

A.A Git repository URL
B.A single .pth file
C.A Docker image with the model and inference code
D.A .zip archive containing model weights and configuration files
AnswerD

The custom model deployment requires a zip archive with all necessary files.

Why this answer

The OCI Generative AI service requires custom model artifacts to be packaged as a .zip archive containing the model weights, configuration files (e.g., config.json, tokenizer files), and any necessary inference code. This format ensures the service can extract and load the model correctly into its managed inference infrastructure, aligning with the standard Hugging Face model repository structure.

Exam trap

The trap here is that candidates may confuse OCI Generative AI's custom model deployment with OCI Data Science model deployment, which does support Docker images, leading them to incorrectly select Option C.

How to eliminate wrong answers

Option A is wrong because a Git repository URL is not a supported artifact format for OCI Generative AI custom model deployment; the service expects a static artifact file, not a live repository reference. Option B is wrong because a single .pth file contains only PyTorch model weights without the required configuration files (e.g., config.json, tokenizer.json) and inference code, making it incomplete for deployment. Option C is wrong because OCI Generative AI custom model deployment does not accept Docker images; it uses a serverless, managed inference environment that expects a .zip archive of model artifacts, not a containerized application.

761
MCQhard

A team fine-tuned a Cohere Command R model in OCI GenAI and validated it. They now need to deploy it for production inference with a dedicated endpoint. What is the correct sequence of steps?

A.Create an endpoint, deploy the model, then provision a Dedicated AI Cluster
B.Deploy the model to a shared endpoint, then provision a Dedicated AI Cluster for scaling
C.Create an endpoint, then provision a Dedicated AI Cluster, then deploy the model
D.Provision a Dedicated AI Cluster, deploy the model to the cluster, then create an endpoint
AnswerD

Correct. This is the proper sequence: provision the cluster, deploy the model, then create the endpoint.

Why this answer

In OCI Generative AI, the correct sequence for deploying a fine-tuned model to a dedicated endpoint is: first provision a Dedicated AI Cluster (which provides the isolated compute infrastructure), then deploy the model to that cluster, and finally create an endpoint that exposes the deployed model for inference. This ensures the model is hosted on dedicated resources before the endpoint is created.

Exam trap

The trap here is that candidates often confuse the order of provisioning infrastructure versus deploying the model, mistakenly thinking the endpoint can be created first and then attached to a cluster later, but OCI GenAI requires the cluster to exist and the model to be deployed before the endpoint can be created.

How to eliminate wrong answers

Option A is wrong because it attempts to create an endpoint before the Dedicated AI Cluster is provisioned, which would fail as the endpoint requires an existing cluster to attach to. Option B is wrong because it incorrectly suggests deploying to a shared endpoint first, which is not the intended path for dedicated production inference; dedicated endpoints require a Dedicated AI Cluster, not a shared one. Option C is wrong because it creates an endpoint before the Dedicated AI Cluster is provisioned and before the model is deployed, which is invalid since the endpoint must reference an already deployed model on an existing cluster.

762
MCQeasy

A retail company uses OCI Generative AI Service to build a RAG chatbot for product recommendations. The chatbot should consider both the user's query and the retrieved product descriptions. Which component of the RAG pipeline is responsible for combining these inputs before sending to the LLM?

A.Reranker
B.Document retriever
C.Embedding model
D.Prompt template
AnswerD

Merges user query and context into a single prompt.

Why this answer

The prompt template is the component in a RAG pipeline that structures the final input to the LLM by combining the user's query with the retrieved product descriptions. It defines the format and instructions (e.g., 'Based on these product descriptions, recommend...') that the LLM uses to generate a coherent response. Without a prompt template, the raw query and documents would be sent without context, leading to poor or irrelevant outputs.

Exam trap

Oracle often tests the misconception that the embedding model or retriever handles input combination, when in fact those components only deal with vector representation and retrieval, not prompt assembly.

How to eliminate wrong answers

Option A is wrong because a reranker reorders retrieved documents based on relevance scores after initial retrieval, but it does not combine inputs with the user query for the LLM. Option B is wrong because the document retriever fetches relevant documents from the vector store using similarity search, but it does not merge them with the query into a single prompt. Option C is wrong because the embedding model converts text into vector representations for search, but it plays no role in assembling the final input to the LLM.

763
MCQeasy

Which LangChain document loader would be most appropriate to load content from a public website for inclusion in a knowledge base?

A.PDFLoader
B.CSVLoader
C.TextLoader
D.WebBaseLoader
AnswerD

WebBaseLoader fetches content from a given URL and loads it as a Document.

Why this answer

WebBaseLoader is specifically designed to load documents from web URLs, fetching the HTML content and converting it to LangChain Document objects. PDFLoader, CSVLoader, and TextLoader are for local files of specific formats.

764
MCQeasy

A company is building a chatbot using OCI Generative AI service. They want to ensure that the model responses are grounded in their internal knowledge base. Which approach should they use?

A.Prompt engineering with few-shot examples
B.Fine-tuning the model on the internal knowledge base
C.Model distillation to compress the knowledge base
D.Retrieval-Augmented Generation (RAG)
AnswerD

RAG retrieves relevant documents from a knowledge base and uses them to generate grounded responses.

Why this answer

Retrieval-Augmented Generation (RAG) is the correct approach because it retrieves relevant documents from the company's internal knowledge base at inference time and provides them as context to the LLM, ensuring the model's responses are grounded in verifiable, up-to-date information without modifying the model itself. This directly addresses the requirement to ground responses in an internal knowledge base while avoiding the cost and complexity of retraining.

Exam trap

The trap here is that candidates often confuse fine-tuning (Option B) as the only way to incorporate proprietary data, overlooking that RAG provides a more flexible, cost-effective, and updatable method for grounding responses in a dynamic knowledge base without altering model weights.

How to eliminate wrong answers

Option A is wrong because prompt engineering with few-shot examples only provides a handful of static examples in the prompt, which cannot dynamically retrieve or incorporate the full breadth of an internal knowledge base, leading to hallucinations on unseen or specific internal data. Option B is wrong because fine-tuning the model on the internal knowledge base would embed that data into the model's weights, making it expensive to update, prone to catastrophic forgetting, and unable to guarantee factual grounding for new or changing documents without retraining. Option C is wrong because model distillation compresses a larger model into a smaller one for efficiency, but it does not introduce external knowledge retrieval; it merely replicates the behavior of the teacher model, which still lacks access to the internal knowledge base.

765
MCQeasy

A developer is using OCI GenAI to generate structured data. They often get responses that include additional commentary or markdown. Which prompt engineering technique should they use to ensure only JSON output?

A.Set top_p to 0.1.
B.Use a model with a larger context window.
C.Add 'Return only JSON' at the end of the prompt.
D.Increase the temperature to 1.5.
AnswerC

Correct: Direct instruction enforces format.

Why this answer

Explicitly instructing the model to 'Return only JSON' directly constrains the output format, reducing the likelihood of extraneous commentary or markdown. This technique leverages prompt engineering to guide the model's behavior without altering inference parameters like temperature or top_p, which control randomness rather than output structure.

Exam trap

Oracle often tests the misconception that adjusting sampling parameters (like temperature or top_p) can enforce output format, when in fact these parameters control randomness and diversity, not structural constraints—leading candidates to overlook the direct prompt engineering solution.

How to eliminate wrong answers

Option A is wrong because setting top_p to 0.1 reduces the nucleus sampling threshold, making the model more deterministic but not preventing it from generating additional text or markdown; it controls token selection diversity, not output format. Option B is wrong because a larger context window allows the model to process more input tokens but does not enforce a specific output structure; it addresses memory limitations, not format constraints. Option D is wrong because increasing temperature to 1.5 raises randomness, which can actually increase the likelihood of unpredictable or verbose responses, including unwanted commentary, rather than ensuring strict JSON output.

766
MCQmedium

A company wants to build a customer service chatbot that answers questions about their internal policy documents. The documents are updated monthly, and the team cannot afford to retrain a model each time. Which approach is MOST appropriate?

A.Train a custom model from scratch on the policy documents each month
B.Use a larger foundation model with a longer context window and paste all documents into each prompt
C.Use Retrieval-Augmented Generation (RAG) with the policy documents indexed in a vector store
D.Fine-tune a base LLM on the policy documents monthly
AnswerC

RAG retrieves relevant document chunks at query time, ensuring the chatbot always answers from the latest uploaded documents without any model retraining.

Why this answer

RAG (Retrieval-Augmented Generation) allows the LLM to retrieve relevant document sections at inference time, so knowledge stays current without retraining. The other options either require expensive retraining for each update or lack document grounding.

767
MCQhard

An OCI Generative AI user notices that a model generates repetitive phrases when summarizing technical articles. Which parameter adjustment is MOST likely to reduce this repetition?

A.Decrease max tokens
B.Increase the frequency penalty
C.Set top-p to 0.95
D.Increase temperature to 0.9
AnswerB

Frequency penalty penalizes tokens that have already appeared, discouraging the model from repeating phrases.

Why this answer

Frequency penalty reduces the likelihood of repeating tokens that have already appeared, directly targeting repetition. Presence penalty also helps but frequency penalty is stronger for repeated phrases.

768
MCQmedium

A team has deployed a generative AI model and needs to monitor inference performance and set up alerts for increased error rates. Which OCI service should they integrate with?

A.OCI Monitoring
B.OCI Cloud Guard
C.OCI Events
D.OCI Logging
AnswerA

Correct: Monitoring provides metrics and alerting for inference endpoints.

Why this answer

OCI Monitoring is the correct service because it provides metrics and alarms for tracking inference performance (e.g., latency, throughput) and error rates from deployed generative AI models. It allows you to set up threshold-based alerts on custom or predefined metrics, enabling proactive incident response. This directly addresses the requirement to monitor inference performance and alert on increased error rates.

Exam trap

Oracle often tests the distinction between monitoring (metrics/alarms) and logging (raw events) — candidates mistakenly choose OCI Logging because they think 'error rates' require log analysis, but OCI Monitoring is designed for metric-based alerting with thresholds.

How to eliminate wrong answers

Option B is wrong because OCI Cloud Guard is a security posture management service that detects misconfigurations and security threats, not a real-time performance monitoring or alerting tool for inference metrics. Option C is wrong because OCI Events is a notification service that reacts to state changes in OCI resources (e.g., object creation, instance termination) but does not natively track or alert on time-series performance metrics like error rates. Option D is wrong because OCI Logging collects and stores log data for audit and troubleshooting, but it lacks built-in metric-based alerting capabilities for monitoring inference performance trends or setting threshold alarms.

Page 10

Page 11 of 11

All pages