Microsoft Azure AI Engineer Associate AI-102 Practice Question

You are configuring a prompt flow in Azure AI Foundry that calls the Azure OpenAI gpt-4o model to generate an ARM template snippet. The responses sometimes include explanatory sentences before the code block, which breaks downstream parsing. Which prompt change is most likely to make the model return only the template code and nothing else?

  • Raise the temperature parameter to 1.2 to make the model focus on code generation.

  • Modify the user message to read "Explain each step and then provide the ARM template."

  • Insert a system message such as "You are an assistant that returns only the requested ARM template JSON inside one markdown code block-no extra text."

  • Send the prompt as a function call message with a name like "return_template" without changing the system instructions.

Microsoft Azure AI Engineer Associate AI-102
Implement generative AI solutions
Your Score:
Settings & Objectives
Random Mixed
Questions are selected randomly from all chosen topics, with a preference for those you haven’t seen before. You may see several questions from the same objective or domain in a row.
Rotate by Objective
Questions cycle through each objective or domain in turn, helping you avoid long streaks of questions from the same area. You may see some repeat questions, but the distribution will be more balanced across topics.

Check or uncheck an objective to set which questions you will receive.

Bash, the Crucial Exams Chat Bot
AI Bot