You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* azd up and deploy build docker image
* update readme
* make sh executable
* make sh executable
* update permission
* update version number
* update doc
Copy file name to clipboardExpand all lines: README.md
+11-15Lines changed: 11 additions & 15 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -237,15 +237,17 @@ You can optionally use a local development server to test app changes locally. M
237
237
```
238
238
239
239
4. Install [Node.js](https://nodejs.org/) (v20 or later).
240
+
241
+
5. Install [pnpm](https://pnpm.io/installation)
240
242
241
-
5. Navigate to the frontend directory and setup for React UI:
243
+
6. Navigate to the frontend directory and setup for React UI:
242
244
243
245
```shell
244
246
cd src/frontend
245
247
pnpm run setup
246
248
```
247
249
248
-
6. Fill in the environment variables in`.env`.
250
+
7. Fill in the environment variables in`.env`.
249
251
250
252
(Optional) if you have changes in`src/frontend`, execute:
251
253
@@ -277,13 +279,7 @@ The build output will be placed in the `../api/static/react` directory, where th
277
279
278
280
Once you've opened the project in [Codespaces](#github-codespaces) or in [Dev Containers](#vs-code-dev-containers) or [locally](#local-environment), you can deploy it to Azure following the following steps.
279
281
280
-
1. Login to Azure:
281
-
282
-
```shell
283
-
azd auth login
284
-
```
285
-
286
-
2. (Optional) If you would like to customize the deployment to [disable resources](docs/deploy_customization.md#disabling-resources), [customize resource names](docs/deploy_customization.md#customizing-resource-names), [customize the models](docs/deploy_customization.md#customizing-model-deployments) or [increase quota](docs/deploy_customization.md#setting-capacity-and-deployment-sku), you can follow those steps now.
282
+
1. (Optional) If you would like to customize the deployment to [disable resources](docs/deploy_customization.md#disabling-resources), [customize resource names](docs/deploy_customization.md#customizing-resource-names), [customize the models](docs/deploy_customization.md#customizing-model-deployments) or [increase quota](docs/deploy_customization.md#setting-capacity-and-deployment-sku), you can follow those steps now.
287
283
288
284
⚠️ **NOTE!** For optimal performance, the recommended quota is 100k tokens per minute. If you have the capacity, we recommend increasing the quota by running the following command:
289
285
@@ -293,21 +289,21 @@ Once you've opened the project in [Codespaces](#github-codespaces) or in [Dev Co
293
289
294
290
⚠️ If you do not increase your quota, you may encounter rate limit issues. If needed, you can increase the quota after deployment by editing your model in the Models and Endpoints tab of the [Azure AI Foundry Portal](https://ai.azure.com/).
295
291
296
-
3. Provision and deploy all the resources with public docker image `azdtemplate.azurecr.io/get-start-with-ai-agents:latest` by running the following in get-started-with-ai-agents directory:
292
+
2. Provision and deploy all the resources with public docker image `azdtemplate.azurecr.io/get-start-with-ai-agents:latest` by running the following in get-started-with-ai-agents directory:
297
293
298
294
```shell
299
295
azd up
300
296
```
301
297
302
-
4. You will be prompted to provide an `azd` environment name (like "azureaiapp"), select a subscription from your Azure account, and select a location which has quota for all the resources. Then, it will provision the resources in your account and deploy the latest code.
298
+
3. You will be prompted to provide an `azd` environment name (like "azureaiapp"), select a subscription from your Azure account, and select a location which has quota for all the resources. Then, it will provision the resources in your account and deploy the latest code.
303
299
304
300
- For guidance on selecting a region with quota and model availability, follow the instructions in the [quota recommendations](#quota-recommendations-optional) section and ensure that your model is available in your selected region by checking the [list of models supported by Azure AI Agent Service](https://learn.microsoft.com/azure/ai-services/agents/concepts/model-region-support)
305
301
- This deployment will take 7-10 minutes to provision the resources in your account and set up the solution with sample data.
306
302
- If you get an error or timeout with deployment, changing the location can help, as there may be availability constraints for the resources. You can do this by running `azd down` and deleting the `.azure` folder from your code, and then running `azd up` again and selecting a new region.
307
303
308
304
**NOTE!** If you get authorization failed and/or permission related errors during the deployment, please refer to the Azure account requirements in the [Prerequisites](#prerequisites) section. If you were recently granted these permissions, it may take a few minutes for the authorization to apply.
309
305
310
-
5. When `azd` has finished deploying, you'll see an endpoint URI in the command output. Visit that URI, and you should see the app! 🎉
306
+
4. When `azd` has finished deploying, you'll see an endpoint URI in the command output. Visit that URI, and you should see the app! 🎉
311
307
312
308
- From here, you can interact with the agent. Try chatting with the agent by asking for a joke, or you could try a more specific query to see the agent's citation capabilities. By default, this solution uploads two documents from the `src/files` folder. To see the agent use this information, try asking about Contoso's products.
313
309
@@ -317,13 +313,13 @@ Once you've opened the project in [Codespaces](#github-codespaces) or in [Dev Co
317
313
azd show
318
314
```
319
315
320
-
6. (Optional) Now that your app has deployed, you can view your resources in the Azure Portal and your deployments in Azure AI Foundry.
316
+
5. (Optional) Now that your app has deployed, you can view your resources in the Azure Portal and your deployments in Azure AI Foundry.
321
317
- In the [Azure Portal](https://portal.azure.com/), navigate to your environment's resource group. The name will be `rg-[your environment name]`. Here, you should see your container app, storage account, and all of the other [resources](#resources) that are created in the deployment.
322
318
- In the [Azure AI Foundry Portal](https://ai.azure.com/), select your project. If you navigate to the Agents tab, you should be able to view your new agent, named `agent-template-assistant`. If you navigate to the Models and Endpoints tab, you should see your AI Services connection with your model deployments.
323
319
324
-
7. (Optional) You can use a local development server to test app changes locally. To do so, follow the steps in [local deployment server](#local-development-server) after your app is deployed.
320
+
6. (Optional) You can use a local development server to test app changes locally. To do so, follow the steps in [local deployment server](#local-development-server) after your app is deployed.
325
321
326
-
8. (Optional) Follow this [tutorial](https://learn.microsoft.com/en-us/azure/container-registry/container-registry-tutorial-quick-task) to build your changes into a Docker image and deploy to Azure Container App.
322
+
7. (Optional) To redeploy, run `azd deploy`. This will cause new docker image rebuilt, push to Azure Container Registry, and a new revision in Azure Container App with a new docker image.
Copy file name to clipboardExpand all lines: docs/deploy_customization.md
+9-1Lines changed: 9 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,7 +9,15 @@ This document describes how to customize the deployment of the Agents Chat with
9
9
*[Customizing model deployments](#customizing-model-deployments)
10
10
11
11
## Use existing resources
12
-
Be default, this template provisions a new resource group along with other resources. If you already have provisioned Azure AI Foundry and Azure AI Foundry Project, you might reuse these resources by setting:
12
+
Be default, this template provisions a new resource group along with other resources. If you already have provisioned Azure AI Foundry and Azure AI Foundry Project (not a hub based project), you might reuse these resources by setting:
13
+
14
+
To find the value:
15
+
16
+
1. Open the azure portal
17
+
2. Navigate to the AI foundry resource
18
+
3. Select projects in the sidebar and open the desired project
19
+
4. Oo to 'Resource Management' -> 'Properties' in the sidebar
20
+
5. Copy the value from 'Resource ID'
13
21
14
22
```shell
15
23
azd env set AZURE_EXISTING_AIPROJECT_RESOURCE_ID "/subscriptions/<your-azure-subid>/resourceGroups/<your-rg>/providers/Microsoft.CognitiveServices/accounts/<your-ai-services-account-name>/projects/<your-project-name>"
0 commit comments