Databricks Generative AI Engineer Associate Question 125
Single answerYou are building a chatbot using a generative AI model deployed on Databricks. The chatbot needs to provide tailored responses based on user input. A user asks, 'Can you recommend a hotel in New York City with free Wi-Fi and a gym?' How would you augment the prompt to ensure the model accurately understands the user's intent and generates a relevant response?
- A
Include the user's location, 'New York City,' as part of the prompt and specify the desired amenities, 'free Wi-Fi and a gym.'
- B
Replace 'New York City' in the prompt with a generic location, such as 'in any city,' to make the response more general-purpose.
- C
Add an additional instruction to the model to prioritize responses related to travel and hospitality.
- D
Ignore the user's mention of 'free Wi-Fi and a gym' and focus solely on providing a list of hotels in New York City.
Show answer and explanation
Correct answer: A
Explanation
To effectively augment a prompt, it is crucial to extract and incorporate key fields, terms, and intents from the user's input. In this case, including 'New York City' and the desired amenities ('free Wi-Fi and a gym') enables the model to generate a highly contextual and relevant response tailored to the user's needs.
- A. Correct.
This is correct because augmenting the prompt with specific user-provided details, such as location and desired amenities, ensures the model can generate a response that directly addresses the user's query.
- B. Incorrect.
This is incorrect because replacing the location with a generic one disregards the user's specific requirement, leading to less relevant responses.
- C. Incorrect.
This is incorrect because while adding instructions might be helpful, it does not fully leverage the user's specific context or intent in the query.
- D. Incorrect.
This is incorrect because ignoring key details about amenities would result in an incomplete response that does not address the user's full intent.