NVIDIA Certified Professional – Accelerated AI Infrastructure — Question 3

You are designing a virtual assistant that helps users check weather updates via external APIs. During testing, the agent frequently calls the incorrect tools, often hallucinating endpoints or returning incorrect formats. You suspect the prompt structure might be the root cause of these failures.
Which prompt design best supports consistent tool invocation in this agent?

Answer options

Correct answer: D

Explanation

The correct answer is D because structured prompt templates with few-shot examples provide clear guidance on how to properly use the tools, reducing ambiguity. Options A, B, and C do not offer sufficient structure or clarity, which can lead to inconsistent tool invocation and incorrect outputs.