|
1 | 1 | --- |
2 | 2 | title: .NET Aspire Azure OpenAI integration (Preview) |
3 | 3 | description: Learn how to use the .NET Aspire Azure OpenAI integration. |
4 | | -ms.date: 03/06/2025 |
| 4 | +ms.date: 04/03/2025 |
5 | 5 | --- |
6 | 6 |
|
7 | 7 | # .NET Aspire Azure OpenAI integration (Preview) |
@@ -83,25 +83,9 @@ If you're new to [Bicep](/azure/azure-resource-manager/bicep/overview), it's a d |
83 | 83 |
|
84 | 84 | :::code language="bicep" source="../snippets/azure/AppHost/openai.module.bicep"::: |
85 | 85 |
|
86 | | -The preceding Bicep is a module that provisions an Azure Cognitive Services resource with the following defaults: |
87 | | - |
88 | | -- `location`: The location of the resource group. |
89 | | -- `principalType`: The principal type of the Cognitive Services resource. |
90 | | -- `principalId`: The principal ID of the Cognitive Services resource. |
91 | | -- `openai`: The Cognitive Services account resource. |
92 | | - - `kind`: The kind of the resource, set to `OpenAI`. |
93 | | - - `properties`: The properties of the resource. |
94 | | - - `customSubDomainName`: The custom subdomain name for the resource, based on the unique string of the resource group ID. |
95 | | - - `publicNetworkAccess`: Set to `Enabled`. |
96 | | - - `disableLocalAuth`: Set to `true`. |
97 | | - - `sku`: The SKU of the resource, set to `S0`. |
98 | | -- `openai_CognitiveServicesOpenAIContributor`: The Cognitive Services resource owner, based on the build-in `Azure Cognitive Services OpenAI Contributor` role. For more information, see [Azure Cognitive Services OpenAI Contributor](/azure/role-based-access-control/built-in-roles/ai-machine-learning#cognitive-services-openai-contributor). |
99 | | -- `preview`: The deployment resource, based on the `preview` name. |
100 | | - - `properties`: The properties of the deployment resource. |
101 | | - - `format`: The format of the deployment resource, set to `OpenAI`. |
102 | | - - `modelName`: The model name of the deployment resource, set to `gpt-4.5-preview`. |
103 | | - - `modelVersion`: The model version of the deployment resource, set to `2025-02-27`. |
104 | | -- `connectionString`: The connection string, containing the endpoint of the Cognitive Services resource. |
| 86 | +The preceding Bicep is a module that provisions an Azure Cognitive Services resource. Additionally, role assignments are created for the Azure resource in a separate module: |
| 87 | + |
| 88 | +:::code language="bicep" source="../snippets/azure/AppHost/openai-roles.module.bicep"::: |
105 | 89 |
|
106 | 90 | The generated Bicep is a starting point and is influenced by changes to the provisioning infrastructure in C#. Customizations to the Bicep file directly will be overwritten, so make changes through the C# provisioning APIs to ensure they are reflected in the generated files. |
107 | 91 |
|
|
0 commit comments