Lesson 13 of 26 · see all lessons
  1. Start here: the exam, Python basics and responsible AI (skill area 1, 40-45%)

    1. 1. Start here: the AI-901 exam, the plan and what you already know
    2. 2. The Python and Azure basics AI-901 expects
    3. 3. Responsible AI: the six principles in practice
  2. AI models: how they work, choosing and deploying (skill area 1)

    1. 4. How generative AI models work
    2. 5. Choosing the right AI model for the job
    3. 6. Deploying a model: deployment options and configuration parameters
  3. AI workloads: text, speech, vision and extraction (skill area 1)

    1. 7. Common AI workloads: from chat and agents to vision and extraction
    2. 8. Text analysis: key phrases, entities, sentiment and summaries
    3. 9. Speech: recognition and synthesis
    4. 10. Computer vision and image generation
    5. 11. Extracting information from documents, images, audio and video
  4. Generative AI apps and agents in Foundry (skill area 2, 55-60%)

    1. 12. Writing system and user prompts
    2. 13. Deploying a model and chatting with it in the Foundry portal
    3. 14. Building a lightweight chat client with the Foundry SDK
    4. 15. Creating and testing a single agent in the Foundry portal
    5. 16. Building a lightweight client app for an agent
  5. Text, speech, vision and extraction apps in Foundry (skill area 2)

    1. 17. Building a text analysis app
    2. 18. Building speech apps: spoken prompts and Azure Speech
    3. 19. Building vision apps: images in prompts and generated images
    4. 20. Extracting information with Content Understanding: documents and forms
    5. 21. Content Understanding for images, audio and video, and a small extraction app
  6. Final review and four mock exams

    1. 22. Final review and exam day: every decision on one page
    2. 23. Mock exam 1
    3. 24. Mock exam 2
    4. 25. Mock exam 3
    5. 26. Mock exam 4
See the leaderboard

18 min

Deploying a model and chatting with it in the Foundry portal

Walk through creating a Foundry project, deploying a model and testing it in the playground.

By the end of this lesson you can

  • Create a Foundry project and explain what the Foundry resource is for
  • Deploy a model from the model catalog and name the deployment
  • Test prompts, parameters and guardrails in the model playground
  • Find the project endpoint and sample code for your deployment

From earlier lessons · 1 of 2

A bank's assistant must answer in formal English in every chat. Where should that rule go?

Pick one answer.

From earlier lessons · 2 of 2

You add three sample questions with ideal answers to a prompt so replies copy their style. What is this technique called?

Pick one answer.

Fernhill Travel's new system message is ready, but nobody can test it. There's no model to send it to yet. The office manager has an Azure subscription and one afternoon. By five o'clock, she wants a model answering sample customer emails in a browser tab.

[2]

Resource, project, deployment

Exam depth: know it cold.

You work in the Foundry portal at ai.azure.com. Three things stack up.

ItemWhat it isCreated when
Foundry resourceThe Azure resource that holds billing, access and models.Automatically, with your first project.
Foundry projectA workspace for your models, agents and files.You create it.
Model deploymentOne model made available to call, under a name you choose.You deploy from the catalog.

The project has one endpoint, a URL your code calls, such as https://<resource>.services.ai.azure.com/api/projects/<project>.

Your code names the deployment, not the model. By default the deployment name matches the model name, but you can change it.

[17][98][99]

Rendering diagram…
The subscription holds a resource group. It holds the Foundry resource, which holds projects. Deployments are what your code calls.

[98][99]

You open the Foundry portal for the first time. You want to deploy a chat model for Fernhill Travel. What must exist before you can deploy it?

Pick one answer.

[98][99]

The new Foundry portal and Foundry (classic)

Exam depth: recognize it.

The portal has two experiences, switched by the New Foundry toggle in the top banner. The new portal is organized into Discover, Build and Manage. Most of your work happens under Build.

Foundry (classic) is the older portal. It still holds hub-based projects, which the new portal doesn't show. Older study material says Azure AI Studio or Azure AI Foundry, and talks about hubs. Today's name is Microsoft Foundry, and new work uses Foundry projects. This course teaches the new portal.

[51][98][101]

Deploy a model from the catalog

Exam depth: know it cold.

The model catalog lists the models you can deploy. In the new portal it's under Build > Catalog > Model Catalog. Each model has a model card with its details.

Select a model, then Deploy. You get two choices:

  • Default settings: deploy now with the usual options.
  • Custom settings: choose the deployment name, the deployment type (such as Global Standard) and other options.

Models from partners and community, such as Llama, also need an Azure Marketplace subscription. Models sold by Azure, such as Azure OpenAI models, don't.

The model must be available in your project's region. You picked that region when you created the project.

[17][99]

[99]

Chat with it in the model playground

Exam depth: know it cold.

When a deployment finishes, you land in its model playground. It's a chat window for testing with no code.

You canWhat it's for
Set the system promptTest your instructions, as in lesson 12.
Change parametersTemperature, top_p, max tokens.
Add toolsWeb search, file search or code interpreter, to ground answers.
Assign a guardrailCheck what gets blocked.
Compare modelsUp to three models side by side, same prompt.
Open the Code tabSample code with your endpoint, in several languages.
Save as agentCarry the setup into the agents playground.

Older material calls it the chat playground and has an "Add your data" button. In the new portal, file search and web search tools do that grounding job.

[49][99]

Match

Match each Fernhill task to the playground feature that does it

Pick an item on the left, then its match on the right.

[49]

Step 1: deploy gpt-5-mini as "fernhill-chat". Step 2: call "gpt-5-mini" in code. Step 3: 404. Picture: Vintage instruction-manual drawing style: black line art on cream paper with numbered panels like a 1950s appliance manual.

Guardrails on the deployment

Exam depth: know it cold.

Every deployment gets the Microsoft default guardrail with no setup. It blocks hate, violence, sexual and self-harm content at medium severity or above, in prompts and replies. It also detects jailbreak attempts. Older material calls guardrails content filters.

To change the rules, create your own guardrail under Build > Guardrails > Create Guardrail. Add controls, then assign the guardrail to models or agents. You can also assign one from the playground's Guardrails section.

A new assignment takes effect at once. Test on a non-production deployment first. You can't edit Microsoft's default guardrails; you create your own.

[29][100]

For the statement, select Yes if it is true. Otherwise, select No. "A new model deployment has no content filtering until you create a guardrail for it."

Pick one answer.

[29]

Try it in the Foundry portal

You need an Azure subscription and a role that can create a Foundry resource, such as Foundry Owner.

  1. Sign in at ai.azure.com. Turn the New Foundry toggle on.
  2. Open the project selector in the upper-left corner. Select Create new project and enter a name, such as fernhill-support.
  3. Select Advanced options. Create a new resource group and pick a location near you. Select Create project.
  4. Go to Build > Catalog > Model Catalog and search for gpt-5-mini.
  5. Select Deploy > Default settings. Note the deployment name.
  6. In the playground, paste your system prompt from lesson 12. Send a sample customer email.
  7. Open the Code tab to see sample code. Copy the project endpoint from the project's home page.
  8. Clean up: in the Azure portal, delete the resource group. That removes the project, resource and deployment, so nothing keeps billing.

[17][99]

Put in order

Put Fernhill's setup steps in order

Drag, or focus an item and press Space, move with the arrow keys, then Space to drop.

  1. Create a project, with a resource group and location
  2. Test a system prompt and messages in the playground
  3. Copy the endpoint and sample code for the app
  4. Delete the resource group when you're done
  5. Open the model catalog and pick a model
  6. Select Deploy and confirm the deployment name
  7. Sign in to the Foundry portal with New Foundry on

[17]

Exam-style practice

A retailer wants to see whether a smaller model answers product questions as well as a larger one. The test must send the same prompt to both, with no code. What should you use?

Pick one answer.

[49]

A developer needs the project endpoint and a working Python sample for a deployment. Where should she look in the Foundry portal?

Pick one answer.

[17][49]

You need to deploy a model and choose its deployment type yourself. Which option do you select after Deploy?

Pick one answer.

[99]

FlashcardsIndex cardsFlashcards ⚡

Card 1 of 15

[17][49][51][98][99][100]

Worth keeping

  1. Create a project first; the Foundry resource comes with it.
  2. Deploy from Build > Catalog; your code calls the deployment name.
  3. The model playground tests prompts, parameters, tools, guardrails and model comparisons.
  4. Every deployment starts with the default guardrail; custom ones are created under Build > Guardrails.
  5. Endpoint on the project home page, sample code in the Code tab, clean up by deleting the resource group.

The playground answers Fernhill's sample emails well. But support staff won't work inside the Foundry portal. Next lesson you take the Code tab's idea further and build a small Python chat app.

Leaderboard

Loading…

50 XP for each lesson you finish, 10 for each right answer. Names show only for learners who turn on Show me on leaderboards.

Embed this practice on your site

Free for classrooms, blogs and study groups. Paste this into any page that accepts HTML.

Report a copyright problem with this lesson

Sources for this lesson (11)

Each fact in the lesson is marked with the number of the page it comes from.

  1. [2]Microsoft Learn: Study guide for Exam AI-901: Microsoft Azure AI Fundamentals
  2. [17]Microsoft Learn: Quickstart: Set up Microsoft Foundry resources
  3. [29]Microsoft Learn: Default Guardrail policies for Microsoft Foundry
  4. [49]Microsoft Learn: Microsoft Foundry Playgrounds
  5. [50]Microsoft Learn: Prompt engineering techniques
  6. [51]Microsoft Learn: What is Microsoft Foundry?
  7. [96]Microsoft Learn: Safety system messages
  8. [98]Microsoft Learn: Create a project for Microsoft Foundry
  9. [99]Microsoft Learn: Deploy Microsoft Foundry Models in the Foundry portal
  10. [100]Microsoft Learn: How to configure guardrails and controls in Microsoft Foundry
  11. [101]Microsoft Learn: Microsoft Foundry portal general availability overview