Skip to content

Commit 5b674f2

Browse files
authored
Merge pull request #1561 from sdgilley/sdg-main-update-tutorial
Update SDK tutorial
2 parents e9ac3d0 + 0a62b87 commit 5b674f2

File tree

4 files changed

+36
-28
lines changed

4 files changed

+36
-28
lines changed

articles/ai-studio/includes/create-env-file-tutorial.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ CHAT_MODEL="gpt-4o-mini"
2323
EVALUATION_MODEL="gpt-4o-mini"
2424
```
2525

26+
If you changed the name of the models you deployed, or you want to try different models, update those names in this `.env` file.
27+
2628
Find your connection string in the Azure AI Studio project you created in the [AI Studio playground quickstart](../quickstarts/get-started-playground.md). Open the project, then find the connection string on the **Overview** page. Copy the connection string and paste it into the `.env` file.
2729

2830
:::image type="content" source="../media/quickstarts/azure-ai-sdk/connection-string.png" alt-text="Screenshot shows the overview page of a project and the location of the connection string.":::

articles/ai-studio/tutorials/copilot-sdk-create-resources.md

Lines changed: 29 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title: "Part 1: Set up project and development environment to build a a custom knowledge retrieval (RAG) app"
2+
title: "Part 1: Set up project and development environment to build a custom knowledge retrieval (RAG) app"
33
titleSuffix: Azure AI Studio
44
description: Build a custom chat app using the Azure AI Foundry SDK. Part 1 of a 3-part tutorial series, which shows how to create the resources you'll need for parts 2 and 3.
55
manager: scottpolly
@@ -44,8 +44,31 @@ To create a project in [Azure AI Studio](https://ai.azure.com), follow these ste
4444
1. Go to the **Home** page of [Azure AI Studio](https://ai.azure.com).
4545
1. Select **+ Create project**.
4646
1. Enter a name for the project. Keep all the other settings as default.
47+
1. Projects are created in hubs. For this tutorial, create a new hub. If you see **Create a new hub** select it and specify a name. Then select **Next**. (If you don't see **Create new hub**, it's because a new one is being created for you.)
48+
1. Select **Customize** to specify properties of the hub.
49+
1. Use any values you want, except for **Region**. We recommend you use either **East US2** or **Sweden Central** for the region for this tutorial series.
50+
1. Select **Next**.
4751
1. Select **Create project**.
4852

53+
## Deploy models
54+
55+
You need two models to build a RAG-based chat app: an Azure OpenAI chat model (`gpt-4o-mini`) and an Azure OpenAI embedding model (`text-embedding-ada-002`). Deploy these models in your Azure AI Studio project, using this set of steps for each model.
56+
57+
These steps deploy a model to a real-time endpoint from the AI Studio [model catalog](../how-to/model-catalog-overview.md):
58+
59+
1. On the left navigation pane, select **Model catalog**.
60+
1. Select the **gpt-4o-mini** model from the list of models. You can use the search bar to find it.
61+
62+
:::image type="content" source="../media/tutorials/chat/select-model.png" alt-text="Screenshot of the model selection page." lightbox="../media/tutorials/chat/select-model.png":::
63+
64+
1. On the model details page, select **Deploy**.
65+
66+
:::image type="content" source="../media/tutorials/chat/deploy-model.png" alt-text="Screenshot of the model details page with a button to deploy the model." lightbox="../media/tutorials/chat/deploy-model.png":::
67+
68+
1. Leave the default **Deployment name**. select **Deploy**. Or, if the model isn't available in your region, a different region is selected for you and connected to your project. In this case, select **Connect and deploy**.
69+
70+
After you deploy the **gpt-4o-mini**, repeat the steps to deploy the **text-embedding-ada-002** model.
71+
4972
## Create an Azure AI Search service
5073

5174
The goal with this application is to ground the model responses in your custom data. The search index is used to retrieve relevant documents based on the user's question.
@@ -80,10 +103,13 @@ In the Azure AI Studio, check for an Azure AI Search connected resource.
80103
1. Otherwise, select **New connection** and then **Azure AI Search**.
81104
1. Find your Azure AI Search service in the options and select **Add connection**.
82105
1. Use **API key** for **Authentication**.
106+
107+
> [!NOTE]
108+
> You can instead use **Microsoft Entra ID** for **Authentication**. If you do this, you must also configure access control for the Azure AI Search service. Assign yourself the **Search Index Data Contributor** and **Search Service Contributor** roles. If you don't know how to do this, or don't have the necessary permissions, use the **API key** for **Authentication**.
109+
83110
1. Select **Add connection**.
84111

85-
> [!NOTE]
86-
> You can instead use **Microsoft Entra ID** for **Authentication**. If you do this, you must also configure access control for the Azure AI Search service. Assign yourself the **Cognitive Services OpenAI User** role. If you don't know how to do this, or don't have the necessary permissions, use the **API key** for **Authentication**.
112+
87113

88114
## <a name="installs"></a> Install the Azure CLI and sign in
89115

@@ -113,25 +139,6 @@ Create a folder for your work. Create a file called **config.py** in this folder
113139

114140
:::code language="python" source="~/azureai-samples-nov2024/scenarios/rag/custom-rag-app/config.py":::
115141

116-
## Deploy models
117-
118-
You need two models to build a RAG-based chat app: an Azure OpenAI chat model (`gpt-4o-mini`) and an Azure OpenAI embedding model (`text-embedding-ada-002`). Deploy these models in your Azure AI Studio project, using this set of steps for each model.
119-
120-
These steps deploy a model to a real-time endpoint from the AI Studio [model catalog](../how-to/model-catalog-overview.md):
121-
122-
1. Sign in to [Azure AI Studio](https://ai.azure.com).
123-
1. Studio remembers where you were last, so you should now see the project you created at the beginning of this tutorial. If you instead see a list of projects, select the one you created for this tutorial.
124-
1. Select the **gpt-4o-mini** model from the list of models. You can use the search bar to find it.
125-
126-
:::image type="content" source="../media/tutorials/chat/select-model.png" alt-text="Screenshot of the model selection page." lightbox="../media/tutorials/chat/select-model.png":::
127-
128-
1. On the model details page, select **Deploy**.
129-
130-
:::image type="content" source="../media/tutorials/chat/deploy-model.png" alt-text="Screenshot of the model details page with a button to deploy the model." lightbox="../media/tutorials/chat/deploy-model.png":::
131-
132-
1. Leave the default **Deployment name**. Select **Connect and deploy**.
133-
134-
After you deploy the **gpt-4o-mini**, repeat the steps to deploy the **text-embedding-ada-002** model.
135142

136143
## Configure environment variables
137144

articles/ai-studio/tutorials/copilot-sdk-evaluate.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ author: sdgilley
1717
In this tutorial, you use the Azure AI SDK (and other libraries) to evaluate and deploy the chat app you built in [Part 2 of the tutorial series](copilot-sdk-build-rag.md). In this part three, you learn how to:
1818

1919
> [!div class="checklist"]
20-
> - Evaluate the quality of chat app responses
21-
> - Deploy the chat app to Azure
22-
> - Verify the deployment
20+
> - Create an evaluation dataset
21+
> - Evaluate the chat app with Azure AI evaluators
22+
2323

2424
This tutorial is part three of a three-part tutorial.
2525

@@ -72,7 +72,6 @@ The script also logs the evaluation results to the cloud project so that you can
7272

7373
:::code language="python" source="~/azureai-samples-nov2024/scenarios/rag/custom-rag-app/evaluate.py" id="run_evaluation":::
7474

75-
7675
### Configure the evaluation model
7776

7877
Since the evaluation script calls the model many times, you might want to increase the number of tokens per minute for the evaluation model.
@@ -96,7 +95,7 @@ In Part 1 of this tutorial series, you created an **.env** file that specifies t
9695
1. Install the required package:
9796

9897
```bash
99-
pip install azure_ai-evaluation[remote]
98+
pip install azure_ai-evaluation[prompts]
10099
```
101100

102101
1. Now run the evaluation script:

articles/ai-studio/tutorials/deploy-chat-web-app.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ ms.custom:
88
- ignite-2023
99
- build-2024
1010
ms.topic: tutorial
11-
ms.date: 10/28/2024
11+
ms.date: 11/14/2024
1212
ms.reviewer: tgokal
1313
ms.author: sgilley
1414
author: sdgilley

0 commit comments

Comments
 (0)